/* ============================================================
   Settle Mood — Shared Design System
   Link from any tool page with:
     <link rel="stylesheet" href="/style.css" />
   Then inject the nav/footer snippets shown at the bottom.
   ============================================================ */

/* ── RESET & BASE ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Backgrounds */
  --bg:      #08080f;
  --bg2:     #0f0f1a;
  --bg3:     #14141f;

  /* Borders */
  --border:  rgba(255, 255, 255, 0.07);

  /* Text */
  --text:    #e8e8f0;
  --muted:   #6b6b80;

  /* Accents */
  --accent:       #7c6af7;   /* purple */
  --accent-light: #9b8af8;
  --accent2:      #5af0c4;   /* teal */

  /* Component tokens */
  --card-hover:   rgba(124, 106, 247, 0.08);
  --radius-card:  12px;
  --radius-btn:   10px;
  --radius-sm:    7px;

  /* Layout */
  --page-pad: clamp(1.5rem, 5vw, 4rem);
  --max-w:    1100px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* push footer to bottom on short pages */
main { flex: 1; }

img, svg { display: block; }

/* ── NAVIGATION ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--page-pad);
  height: 64px;
  background: rgba(8, 8, 15, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 1px;
  text-decoration: none;
}

.brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #fff 30%, var(--accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.brand-tag {
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--text); }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 2rem var(--page-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-brand {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
}

.footer-brand span { color: var(--text); }

.footer-note {
  font-size: 0.78rem;
  color: var(--muted);
}

/* ── PAGE HEADER (tool pages use this instead of hero) ── */
.page-header {
  padding: clamp(3rem, 7vw, 5rem) var(--page-pad) clamp(2rem, 4vw, 3rem);
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 60% at 0% 0%, rgba(124, 106, 247, 0.12) 0%, transparent 65%),
    radial-gradient(ellipse 35% 40% at 100% 80%, rgba(90, 240, 196, 0.05) 0%, transparent 60%);
  pointer-events: none;
}

.page-header-inner {
  position: relative;
  max-width: var(--max-w);
  margin: 0 auto;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  margin-bottom: 1.25rem;
  transition: color 0.2s;
}

.back-link:hover { color: var(--text); }
.back-link svg { width: 14px; height: 14px; }

.page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent2);
  margin-bottom: 0.75rem;
  padding: 0.3rem 0.8rem;
  border: 1px solid rgba(90, 240, 196, 0.2);
  border-radius: 99px;
  background: rgba(90, 240, 196, 0.05);
}

.page-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  background: linear-gradient(170deg, #ffffff 0%, rgba(255, 255, 255, 0.7) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.75rem;
}

.page-subtitle {
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  color: var(--muted);
  max-width: 520px;
  line-height: 1.65;
}

/* ── TOOL CONTENT AREA ── */
.tool-wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--page-pad) clamp(3rem, 6vw, 5rem);
}

/* ── SECTION HEADERS ── */
.section-header { margin-bottom: 2rem; }

.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.4rem;
}

.section-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

/* ── CARDS ── */
.card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 1.5rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
}

.tool-card {
  background: var(--bg2);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: background 0.25s;
  position: relative;
  overflow: hidden;
}

.tool-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--card-hover);
  opacity: 0;
  transition: opacity 0.25s;
  pointer-events: none;
}

.tool-card:hover { background: var(--bg3); }
.tool-card:hover::after { opacity: 1; }

.tool-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.tool-name {
  font-size: 1rem;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -0.01em;
}

.tool-desc {
  font-size: 0.845rem;
  color: var(--muted);
  line-height: 1.55;
  flex: 1;
}

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius-btn);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, opacity 0.2s;
  line-height: 1;
}

.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  color: #fff;
  box-shadow: 0 0 0 0 rgba(124, 106, 247, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(124, 106, 247, 0.35);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: var(--bg3);
  border-color: rgba(255, 255, 255, 0.14);
}

.btn-teal {
  background: rgba(90, 240, 196, 0.08);
  color: var(--accent2);
  border: 1px solid rgba(90, 240, 196, 0.2);
}

.btn-teal:hover {
  background: rgba(90, 240, 196, 0.14);
  border-color: rgba(90, 240, 196, 0.4);
}

/* the small "Open Tool →" style links */
.tool-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent2);
  text-decoration: none;
  margin-top: 0.25rem;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(90, 240, 196, 0.2);
  border-radius: var(--radius-sm);
  background: rgba(90, 240, 196, 0.04);
  width: fit-content;
  transition: background 0.2s, border-color 0.2s, gap 0.2s;
}

.tool-link:hover {
  background: rgba(90, 240, 196, 0.1);
  border-color: rgba(90, 240, 196, 0.4);
  gap: 0.65rem;
}

.tool-link svg { width: 13px; height: 13px; }

/* ── FORM CONTROLS ── */
label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.4rem;
}

input[type="text"],
input[type="number"],
input[type="range"],
select,
textarea {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  padding: 0.55rem 0.85rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s;
}

input[type="text"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
  border-color: rgba(124, 106, 247, 0.5);
}

input[type="range"] {
  padding: 0;
  accent-color: var(--accent);
  cursor: pointer;
}

/* file upload drop zone */
.upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-card);
  padding: 2.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.upload-zone:hover,
.upload-zone.drag-over {
  border-color: rgba(124, 106, 247, 0.45);
  background: rgba(124, 106, 247, 0.04);
}

.upload-zone p {
  color: var(--muted);
  font-size: 0.875rem;
}

.upload-zone strong { color: var(--text); }

/* ── DIVIDER ── */
hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

/* ── BADGE ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.25rem 0.65rem;
  border-radius: 99px;
}

.badge-purple {
  background: rgba(124, 106, 247, 0.12);
  color: var(--accent-light);
  border: 1px solid rgba(124, 106, 247, 0.2);
}

.badge-teal {
  background: rgba(90, 240, 196, 0.08);
  color: var(--accent2);
  border: 1px solid rgba(90, 240, 196, 0.2);
}

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .nav-links { gap: 1.25rem; }
  .card-grid { grid-template-columns: 1fr; }
  footer { flex-direction: column; align-items: flex-start; }
  .page-header { padding-top: 2.5rem; }
}

/* ================================================================
   USAGE — copy this snippet into each tool page's <body>:

   <nav>
     <a href="/" class="brand">
       <span class="brand-name">Settle Mood</span>
       <span class="brand-tag">Simple, Easy, Vibe</span>
     </a>
     <ul class="nav-links">
       <li><a href="/">Home</a></li>
       <li><a href="/#tools">Tools</a></li>
       <li><a href="/#about">About</a></li>
     </ul>
   </nav>

   <footer>
     <p class="footer-brand"><span>Settle Mood</span> — Free tools for creators</p>
     <p class="footer-note">No backend. No frameworks. No paywalls.</p>
   </footer>

   And a typical tool page header:

   <header class="page-header">
     <div class="page-header-inner">
       <a href="/" class="back-link">
         <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"
              stroke-linecap="round" stroke-linejoin="round">
           <path d="M19 12H5M12 5l-7 7 7 7"/>
         </svg>
         All Tools
       </a>
       <span class="page-eyebrow">Tool Name</span>
       <h1 class="page-title">Your Tool Title</h1>
       <p class="page-subtitle">Short description of what this tool does.</p>
     </div>
   </header>

   <main class="tool-wrap">
     ... tool content ...
   </main>
================================================================ */
