/* ═══════════════════════════════════════════
   TOKENS — Deep Ocean (from _tokens.scss)
═══════════════════════════════════════════ */
:root {
  --font-ui: 'Manrope', sans-serif;
  --font-code: 'Source Code Pro', monospace;
  --sp-xs: 4px; --sp-sm: 8px; --sp-md: 16px; --sp-lg: 24px;
  --sp-xl: 32px; --sp-2xl: 48px; --sp-3xl: 64px;
  --r-sm: 4px; --r-md: 8px; --r-lg: 12px; --r-xl: 16px; --r-full: 9999px;
  --focus-ring: 0 0 0 3px rgba(56, 189, 248, 0.15);
  --accent-glow: 0 0 24px rgba(56, 189, 248, 0.25);
}

/* ── Dark (default) ── */
html, [data-theme="dark"] {
  --bg-primary: #0F172A;
  --bg-secondary: #1E293B;
  --bg-tertiary: #334155;
  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  --accent: #38BDF8;
  --accent-hover: #7DD3FC;
  --accent-subtle: rgba(56, 189, 248, 0.08);
  --success: #34D399;
  --success-bg: rgba(52, 211, 153, 0.15);
  --warning: #FBBF24;
  --warning-bg: rgba(251, 191, 36, 0.15);
  --error: #F87171;
  --error-bg: rgba(248, 113, 113, 0.15);
  --purple: #A78BFA;
  --purple-bg: rgba(167, 139, 250, 0.12);
  --border: rgba(255, 255, 255, 0.1);
  --border-subtle: rgba(255, 255, 255, 0.05);
  --sidebar-bg: #0B1120;
  --card-bg: rgba(30, 41, 59, 0.6);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
  --glass-bg: linear-gradient(145deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.6));
  --glass-border: 1px solid rgba(255, 255, 255, 0.08);
  --input-bg: rgba(15, 23, 42, 0.6);
  --hero-glow: radial-gradient(ellipse 600px 400px at 50% 30%, rgba(56, 189, 248, 0.04) 0%, transparent 100%);
}

/* ── Light ── */
[data-theme="light"] {
  --bg-primary: #F8FAFC;
  --bg-secondary: #E2E8F0;
  --bg-tertiary: #CBD5E1;
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  --accent: #0284C7;
  --accent-hover: #0369A1;
  --accent-subtle: rgba(2, 132, 199, 0.06);
  --success: #059669;
  --success-bg: rgba(5, 150, 105, 0.12);
  --warning: #D97706;
  --warning-bg: rgba(217, 119, 6, 0.12);
  --error: #DC2626;
  --error-bg: rgba(220, 38, 38, 0.12);
  --purple: #7C3AED;
  --purple-bg: rgba(124, 58, 237, 0.1);
  --border: rgba(0, 0, 0, 0.1);
  --border-subtle: rgba(0, 0, 0, 0.05);
  --sidebar-bg: #FFFFFF;
  --card-bg: rgba(255, 255, 255, 0.8);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.15);
  --glass-bg: linear-gradient(145deg, rgba(255, 255, 255, 0.8), rgba(248, 250, 252, 0.7));
  --glass-border: 1px solid rgba(0, 0, 0, 0.08);
  --input-bg: #FFFFFF;
  --focus-ring: 0 0 0 3px rgba(14, 165, 233, 0.2);
  --accent-glow: none;
  --hero-glow: radial-gradient(ellipse 600px 400px at 50% 30%, rgba(2, 132, 199, 0.04) 0%, transparent 100%);
}

/* ═══════════════════════════════════════════
   BASE
═══════════════════════════════════════════ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-ui);
  background: var(--bg-primary);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 0.3s ease, color 0.3s ease;
  line-height: 1.6;
}

/* ═══════════════════════════════════════════
   NAV — matches dashboard header
═══════════════════════════════════════════ */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  padding: 0 var(--sp-xl);
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.3s ease, border-color 0.3s ease;
}

.nav-wordmark {
  font-family: var(--font-ui);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-primary);
  text-decoration: none;
}

.theme-toggle {
  width: 36px; height: 36px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 150ms ease-out;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
.theme-toggle svg { width: 16px; height: 16px; }

[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }
[data-theme="light"] .icon-moon { display: block; }

/* ═══════════════════════════════════════════
   LAYOUT
═══════════════════════════════════════════ */
.page { padding-top: 56px; }

section {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 var(--sp-xl);
}

.section-sep {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 var(--sp-xl);
  height: 1px;
}
.section-sep::after {
  content: '';
  display: block;
  height: 1px;
  background: var(--border-subtle);
}

/* ═══════════════════════════════════════════
   OVERLINE — monospace, uppercase, matches dashboard
═══════════════════════════════════════════ */
.overline {
  font-family: var(--font-code);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--sp-md);
}

/* ═══════════════════════════════════════════
   HERO
═══════════════════════════════════════════ */
.hero {
  min-height: calc(100vh - 56px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding-top: var(--sp-3xl);
  padding-bottom: var(--sp-3xl);
  position: relative;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--hero-glow);
  pointer-events: none;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-sm);
  padding: 5px 14px;
  border-radius: var(--r-full);
  border: 1px solid var(--border);
  font-family: var(--font-code);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 auto var(--sp-2xl);
  animation: fadeUp 0.6s ease both;
}
.badge-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}

.hero h1 {
  font-family: var(--font-ui);
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: var(--sp-lg);
  animation: fadeUp 0.6s ease 0.1s both;
}

.hero h1 .accent {
  color: var(--accent);
}

.hero-sub {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto var(--sp-2xl);
  animation: fadeUp 0.6s ease 0.2s both;
}

/* ═══════════════════════════════════════════
   FORM
═══════════════════════════════════════════ */
.signup-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-sm);
  animation: fadeUp 0.6s ease 0.3s both;
}

.signup-form {
  display: flex;
  gap: var(--sp-sm);
  width: 100%;
  max-width: 420px;
}

.signup-form input[type="email"] {
  flex: 1;
  height: 44px;
  padding: 0 var(--sp-md);
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--text-primary);
  font-family: var(--font-ui);
  font-size: 14px;
  outline: none;
  transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1);
}
.signup-form input[type="email"]::placeholder { color: var(--text-muted); }
.signup-form input[type="email"]:focus {
  border-color: var(--accent);
  box-shadow: var(--focus-ring);
}

.hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }

.btn-primary {
  height: 44px;
  padding: 0 20px;
  border-radius: var(--r-md);
  border: none;
  background: var(--accent);
  color: #0F172A;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 150ms ease-out;
  white-space: nowrap;
  box-shadow: var(--accent-glow);
}
.btn-primary:hover { background: var(--accent-hover); }

.form-note {
  font-size: 12px;
  color: var(--text-muted);
}

.form-success {
  display: none;
  align-items: center;
  gap: var(--sp-sm);
  color: var(--success);
  font-weight: 600;
  font-size: 14px;
}
.form-success.show { display: flex; }

/* ═══════════════════════════════════════════
   CONTENT SECTIONS
═══════════════════════════════════════════ */
.content-section {
  padding-top: var(--sp-3xl);
  padding-bottom: var(--sp-3xl);
}

.content-section h2 {
  font-family: var(--font-ui);
  font-size: clamp(24px, 3.5vw, 32px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: var(--sp-md);
}

.content-section .body-text {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ═══════════════════════════════════════════
   PAIN POINTS — left-border accent cards (like dashboard)
═══════════════════════════════════════════ */
.pain-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-md);
  margin-top: var(--sp-xl);
}

.pain-item {
  padding: var(--sp-md) var(--sp-lg);
  border-left: 3px solid var(--border);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  background: var(--card-bg);
  transition: border-color 0.2s ease;
}
.pain-item:hover { border-left-color: var(--accent); }

.pain-item.warn { border-left-color: var(--warning); }
.pain-item.err  { border-left-color: var(--error); }
.pain-item.purp { border-left-color: var(--purple); }

.pain-item h3 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: var(--sp-xs);
}
.pain-item p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ═══════════════════════════════════════════
   PIPELINE
═══════════════════════════════════════════ */
.pipeline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-top: var(--sp-xl);
  padding: var(--sp-xl) var(--sp-lg);
  background: var(--card-bg);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
}

.pipeline-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.pipeline-tag {
  font-family: var(--font-code);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
}
.pipeline-tag.you  { color: var(--accent); border-color: rgba(56, 189, 248, 0.3); background: var(--accent-subtle); }
.pipeline-tag.agent { color: var(--purple); border-color: rgba(167, 139, 250, 0.3); background: var(--purple-bg); }
.pipeline-tag.weft  { color: var(--success); border-color: rgba(52, 211, 153, 0.3); background: var(--success-bg); }

.pipeline-label {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-code);
}

.pipeline-arrow {
  color: var(--text-muted);
  font-family: var(--font-code);
  font-size: 16px;
  padding: 0 12px;
  margin-bottom: 18px;
}

/* ═══════════════════════════════════════════
   QUOTE
═══════════════════════════════════════════ */
blockquote {
  padding: var(--sp-md) var(--sp-lg);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  background: var(--accent-subtle);
  margin: var(--sp-xl) 0;
}
blockquote p {
  font-size: 16px;
  font-style: italic;
  line-height: 1.6;
  color: var(--text-primary);
  font-weight: 500;
}

/* ═══════════════════════════════════════════
   STATS — monospace numbers like dashboard
═══════════════════════════════════════════ */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-md);
  margin-top: var(--sp-xl);
}

.stat {
  text-align: center;
  padding: var(--sp-lg) var(--sp-sm);
}

.stat-val {
  font-family: var(--font-code);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  margin-bottom: var(--sp-xs);
}

.stat-lbl {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-code);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ═══════════════════════════════════════════
   LINK
═══════════════════════════════════════════ */
.text-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-sm);
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: all 150ms ease-out;
}
.text-link:hover { color: var(--accent-hover); }
.text-link svg { width: 14px; height: 14px; transition: transform 0.2s ease; }
.text-link:hover svg { transform: translateX(2px); }

/* ═══════════════════════════════════════════
   BOTTOM CTA
═══════════════════════════════════════════ */
.bottom-cta {
  text-align: center;
  padding-top: var(--sp-3xl);
  padding-bottom: var(--sp-3xl);
}

.bottom-cta h2 {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: var(--sp-xs);
}
.bottom-cta p {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: var(--sp-xl);
}
.bottom-cta .signup-wrap { align-items: center; }

/* ═══════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════ */
footer {
  max-width: 640px;
  margin: 0 auto;
  padding: var(--sp-lg) var(--sp-xl);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-muted);
}
footer a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s ease;
}
footer a:hover { color: var(--accent); }

/* ═══════════════════════════════════════════
   ANIMATIONS
═══════════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.vis { opacity: 1; transform: translateY(0); }

/* ═══════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════ */
@media (max-width: 540px) {
  .signup-form { flex-direction: column; }
  .signup-form .btn-primary { width: 100%; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .pipeline-arrow { display: none; }
  .pipeline { flex-wrap: wrap; gap: var(--sp-sm); }
  nav { padding: 0 var(--sp-md); }
  section { padding: 0 var(--sp-md); }
}
