@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=JetBrains+Mono:wght@400;500;600&display=swap");

:root {
  --bg: #080c12;
  --bg-elevated: #0f1520;
  --card: #101820;
  --card-hover: #162030;
  --border: #243044;
  --border-light: #2f3f56;
  --ink: #eef3f8;
  --muted: #a0b4c8; /* ≥4.5:1 on --card (#101820) */
  --accent: #33e0c8;
  --accent-dim: #1fa89a;
  --accent-glow: rgba(51, 224, 200, 0.14);
  --signal-down: #ff5c5c; /* downside / short / loss only */
  --signal-up: #3ecf8e;   /* gains only */
  --ok: var(--signal-up);
  --warn: #f0b429;
  --err: var(--signal-down);
  --gold: #d4a853;        /* premium tiers only */
  --font: "DM Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --radius: 6px;
  --radius-sm: 4px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --nav-h: 56px;
  --max-w: 1120px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  min-height: 100vh;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
}

/* Engineering grid + faint top glow */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 45% at 50% -8%, rgba(51, 224, 200, 0.06), transparent 70%),
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: auto, 32px 32px, 32px 32px;
  pointer-events: none;
  z-index: 0;
}

a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: #6aedd9; }

.num,
output,
.stat-card .value,
.p0,
.brackets .val,
.conv-num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── Nav ── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  background: rgba(8, 12, 18, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.site-nav .logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 400;
  font-size: 1.05rem;
  color: var(--ink);
  letter-spacing: -0.02em;
  flex-shrink: 0;
  text-decoration: none;
}

.site-nav .logo:hover { color: var(--ink); }

.logo-mark {
  width: 28px;
  height: 28px;
  color: var(--accent);
  flex-shrink: 0;
  display: block;
}

.logo-word {
  display: inline-flex;
  align-items: baseline;
  line-height: 1;
}

.logo-short {
  font-weight: 400;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.logo-safe {
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--ink);
}

.site-nav .logo span { color: inherit; }

/* Hamburger — mobile only */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  margin-left: auto;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle-bar {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--ink);
  border-radius: 1px;
  transition: transform 0.2s, opacity 0.2s;
}
.nav-toggle.open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Drawer layout */
.nav-drawer {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.site-nav a.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 500;
  padding: 7px 14px;
  border-radius: 3px;
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}

.site-nav a.nav-link:hover,
.site-nav a.nav-link.active {
  color: var(--ink);
  background: var(--accent-glow);
}

.site-nav a.nav-link.active {
  color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(51, 224, 200, 0.28);
}

.nav-link-icon {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  opacity: 0.9;
}
.nav-link-icon svg { width: 16px; height: 16px; display: block; }

.nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.nav-auth {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Language picker */
.lang-picker { position: relative; }

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.lang-btn:hover { border-color: var(--accent); background: var(--accent-glow); }

.lang-code { font-family: var(--font-mono); letter-spacing: 0.04em; font-variant-numeric: tabular-nums; }

.lang-caret {
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid var(--muted);
  margin-left: 2px;
}

.lang-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 168px;
  padding: 6px;
  background: var(--card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  z-index: 200;
}

.lang-opt {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font-size: 0.84rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}
.lang-opt:hover { background: var(--accent-glow); }
.lang-opt.active { background: var(--accent-glow); color: var(--accent); }
.lang-opt .lang-name { flex: 1; }
.lang-check { color: var(--accent); font-size: 0.75rem; }

/* Logged-in user chip */
.nav-user {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 4px 4px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-elevated);
  color: var(--ink);
  max-width: 180px;
  transition: border-color 0.15s, background 0.15s;
}
.nav-user:hover {
  border-color: var(--accent);
  background: var(--accent-glow);
  color: var(--ink);
}

.nav-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: #061014;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.nav-user-info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
  overflow: hidden;
}

.nav-user-name {
  font-size: 0.8rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-user-plan {
  font-size: 0.68rem;
  color: var(--muted);
}

.site-nav .btn-nav {
  font-size: 0.84rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #061014;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
}

.site-nav .btn-nav:hover { background: var(--accent-dim); color: #061014; }

.site-nav .btn-nav.outline {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--ink);
}

.site-nav .btn-nav.outline:hover {
  border-color: var(--accent);
  background: var(--accent-glow);
}

/* ── Layout ── */
.page {
  position: relative;
  z-index: 1;
  flex: 1;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 40px 24px 64px;
}

.page-narrow { max-width: 440px; }

.page-center {
  min-height: calc(100vh - var(--nav-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
}

/* ── Cards ── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}

.card-glow {
  border-color: var(--border-light);
  background: linear-gradient(145deg, var(--card) 0%, var(--bg-elevated) 100%);
}

.card h1, .card h2, .card h3 { letter-spacing: -0.02em; }

/* ── Typography ── */
h1 { font-size: 1.75rem; font-weight: 700; margin-bottom: 6px; }
h2 { font-size: 1.15rem; font-weight: 600; }
.sub, .lead {
  color: var(--muted);
  font-size: 0.92rem;
  margin-bottom: 24px;
}

.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--accent-glow);
  padding: 4px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
}

/* ── Forms ── */
label {
  display: block;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 14px;
}

input, select, textarea {
  width: 100%;
  padding: 11px 14px;
  margin-top: 5px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}

input, select, textarea { min-height: 44px; }

input:focus, select:focus, textarea:focus,
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

input[type=range] {
  min-height: 44px;
  accent-color: var(--accent);
  padding: 0;
}

button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 20px;
  min-height: 44px;
  background: var(--accent);
  color: #061014;
  border: none;
  border-radius: var(--radius-sm);
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s, opacity 0.15s;
}

button:hover, .btn:hover { background: var(--accent-dim); color: #061014; }
button:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
button:active, .btn:active { transform: scale(0.98); }
button:disabled, .btn:disabled { opacity: 0.45; cursor: not-allowed; }

button.sec, .btn.sec {
  background: var(--border);
  color: var(--ink);
}

button.sec:hover, .btn.sec:hover { background: var(--border-light); }

button.block, .btn.block { width: 100%; margin-top: 8px; }

button.tertiary, .btn.tertiary,
a.btn.tertiary {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
button.tertiary:hover, .btn.tertiary:hover,
a.btn.tertiary:hover {
  background: var(--accent-glow);
  color: var(--ink);
  border-color: rgba(51, 224, 200, 0.35);
}

.err {
  color: var(--err);
  font-size: 0.85rem;
  margin-top: 10px;
  min-height: 1.2em;
}

.foot {
  margin-top: 22px;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
}

/* ── Site footer (legal) ── */
.site-footer {
  position: relative;
  z-index: 2;
  margin-top: auto;
  padding: 36px 20px 44px;
  border-top: 1px solid var(--border);
  background: rgba(8, 12, 18, 0.95);
}

.site-footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  text-align: center;
}

.site-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px 10px;
  margin-bottom: 14px;
  font-size: 0.88rem;
}

.site-footer-links .sep,
.site-footer-social .sep {
  color: var(--border-light);
  user-select: none;
}

.site-footer-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px 12px;
  margin: 0 0 16px;
  font-size: 0.85rem;
}

.site-footer-social .social-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.site-footer-social .social-link:hover {
  color: var(--accent);
}

.site-footer-social .social-link svg {
  display: block;
  flex-shrink: 0;
  opacity: 0.85;
}

.site-footer-copy,
.site-footer-tm {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.6;
}

.site-footer-tm {
  margin-top: 6px;
}

.site-footer-tm a {
  margin-left: 6px;
  white-space: nowrap;
}

/* ── Legal pages ── */
.legal-page {
  max-width: 720px;
  padding-bottom: 24px;
}

.legal-page h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  margin: 8px 0 16px;
}

.legal-page .lead {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 32px;
}

.legal-updated {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 28px;
}

.legal-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
}

.legal-card h2 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--accent);
}

.legal-dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 20px;
  font-size: 0.92rem;
}

.legal-dl dt {
  color: var(--muted);
  font-weight: 500;
}

.legal-dl dd {
  margin: 0;
}

.legal-section {
  margin-bottom: 28px;
}

.legal-section h2 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--ink);
}

.legal-section p {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

.legal-section code {
  background: var(--bg-elevated);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85em;
}

.legal-link {
  margin-top: 8px;
  font-size: 0.88rem;
}

.about-intro-card {
  margin-bottom: 28px;
}

.about-intro-card p {
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.65;
  margin-bottom: 10px;
}

.about-tm {
  font-size: 0.85rem !important;
  color: var(--muted) !important;
}

/* ── About (revolutionary) ── */
.about-page h1 {
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  font-weight: 700;
  line-height: 1.15;
  background: linear-gradient(135deg, var(--ink) 20%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 20px;
}

.about-badge {
  color: var(--gold) !important;
  border-color: rgba(212, 168, 83, 0.35);
  background: rgba(212, 168, 83, 0.08);
}

.about-lead {
  font-size: 1.08rem;
  line-height: 1.7;
}

.about-p2 {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 36px;
}

.about-block {
  margin-bottom: 28px;
  padding-left: 16px;
  border-left: 3px solid var(--accent-dim);
}

.about-block h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 10px;
}

.about-block p {
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.65;
}

/* ── Home landing (terminal composition) ── */
.page-home .page-home-inner {
  max-width: 1120px;
  padding-top: 24px;
}

.page-home .hero {
  padding: 4px 0 0;
}

/* Brand + promise first — one tight block */
.page-home .hero-intro {
  max-width: 40rem;
  margin-bottom: 18px;
}

.page-home .hero h1 {
  font-size: clamp(3rem, 8vw, 4.6rem);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 0.92;
  color: var(--ink);
  background: none;
  -webkit-text-fill-color: unset;
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 0.18em;
}

.page-home .hero h1 .brand-mark {
  width: 0.72em;
  height: 0.72em;
  color: var(--accent);
  flex-shrink: 0;
}

.page-home .hero h1 .logo-short { font-weight: 400; }
.page-home .hero h1 .logo-safe { font-weight: 800; }

.page-home .hero .lead {
  margin: 0 0 12px;
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  line-height: 1.4;
  color: var(--ink);
  max-width: 36rem;
}

.page-home .hero .sub-lead {
  margin: 0 0 22px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  border-left: 2px solid var(--accent);
  padding-left: 10px;
}

.page-home .hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.page-home .hero-actions .btn {
  border-radius: 3px;
  letter-spacing: 0.01em;
}

/* Waitlist — measurement funnel (email ≪ account) */
.page-home .waitlist {
  margin: 48px 0 8px;
  padding: 28px 0 8px;
  border-top: 1px solid var(--border);
  max-width: 36rem;
}
.page-home .waitlist-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 10px;
}
.page-home .waitlist h2 {
  font-size: clamp(1.35rem, 2.8vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
  color: var(--ink);
}
.page-home .waitlist-lead {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}
.page-home .waitlist-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: stretch;
}
.page-home .waitlist-form input[type="email"] {
  flex: 1 1 220px;
  min-height: 44px;
  margin: 0;
  border-radius: var(--radius-sm);
  background: rgba(8, 12, 18, 0.65);
  border: 1px solid var(--border);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.88rem;
}
.page-home .waitlist-form input[type="email"]:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 2px var(--accent-glow);
}
.page-home .waitlist-form button {
  flex: 0 0 auto;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}
.page-home .waitlist-hint {
  margin: 12px 0 0;
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.4;
}
.page-home .waitlist-hint a { color: var(--accent); }
.page-home .waitlist-msg {
  margin: 10px 0 0;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  min-height: 1.2em;
}
.page-home .waitlist-msg.ok { color: var(--up, #3ecf8e); }
.page-home .waitlist-msg.err { color: var(--err); }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Full-width payoff plane — the product, not a card */
.page-home .hero-payoff {
  margin: 0 -8px;
  padding: 0;
  background: transparent;
  border: none;
}

.page-home .payoff-caption {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 0 8px 8px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.page-home .payoff-caption .num {
  color: var(--accent);
  letter-spacing: 0.08em;
}

.page-home .payoff-diagram {
  width: 100%;
  height: auto;
  display: block;
}

.page-home .plot-bed {
  fill: rgba(8, 12, 18, 0.55);
  stroke: var(--border);
  stroke-width: 1;
}

.page-home .plot-grid line {
  stroke: rgba(255, 255, 255, 0.035);
  stroke-width: 1;
}

.page-home .axis {
  stroke: #3a4d66;
  stroke-width: 1.25;
}

.page-home .zero-line {
  stroke: rgba(160, 180, 200, 0.4);
  stroke-width: 1;
  stroke-dasharray: 4 5;
}

.page-home .payoff-path {
  fill: none;
  stroke: #d6e2ee;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1100;
  stroke-dashoffset: 1100;
  animation: draw-payoff 1.45s cubic-bezier(0.22, 1, 0.36, 1) 0.1s forwards;
}

.page-home .cap-plateau {
  fill: none;
  stroke: var(--accent);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 380;
  stroke-dashoffset: 380;
  animation: draw-payoff 0.85s ease-out 1.05s forwards;
  filter: drop-shadow(0 0 8px rgba(51, 224, 200, 0.55));
}

.page-home .path-uncapped {
  fill: none;
  stroke: var(--signal-down);
  stroke-width: 1.75;
  stroke-dasharray: 6 5;
  opacity: 1;
}

.page-home .mark-zero {
  fill: var(--ink);
  opacity: 1;
}
.page-home .mark-cap {
  fill: var(--accent);
  opacity: 1;
}

.page-home .cap-bracket {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.25;
  opacity: 0.7;
}

.page-home .tick {
  font-family: var(--font-mono);
  font-size: 11px;
  fill: var(--muted);
  font-variant-numeric: tabular-nums;
}

.page-home .label-up {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  fill: var(--signal-up);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 1;
}

.page-home .label-down {
  font-family: var(--font-mono);
  font-size: 10px;
  fill: var(--signal-down);
  letter-spacing: 0.04em;
  opacity: 1;
}

.page-home .label-accent {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  fill: var(--accent);
  letter-spacing: 0.05em;
  opacity: 1;
}

@keyframes draw-payoff {
  to { stroke-dashoffset: 0; }
}
@keyframes fade-in {
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .page-home .payoff-path,
  .page-home .cap-plateau {
    stroke-dasharray: none;
    stroke-dashoffset: 0;
    animation: none;
  }
  .page-home .path-uncapped,
  .page-home .label-up,
  .page-home .label-down,
  .page-home .label-accent,
  .page-home .mark-zero,
  .page-home .mark-cap {
    opacity: 1;
    animation: none;
  }
}

/* Proof strip — terminal ticker */
.page-home .proof-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 0;
  margin: 22px 0 32px;
  overflow: hidden;
}

.page-home .proof-item {
  background: rgba(8, 12, 18, 0.7);
  padding: 12px 16px;
  border-right: 1px solid var(--border);
}
.page-home .proof-item:last-child { border-right: 0; }

.page-home .proof-item .proof-val {
  font-family: var(--font-mono) !important;
  font-variant-numeric: tabular-nums;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.page-home .proof-item .proof-label {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.35;
}

@media (max-width: 640px) {
  .page-home .proof-strip { grid-template-columns: 1fr; }
  .page-home .proof-item {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  .page-home .proof-item:last-child { border-bottom: 0; }
}

/* Home tiles — denser terminal menu */
.page-home .home-tiles {
  gap: 10px;
}
.page-home .home-tiles .tile {
  border-radius: 3px;
  padding: 16px;
  background: rgba(8, 12, 18, 0.55);
  box-shadow: none;
}
.page-home .tile-k {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: none;
  padding: 0;
  margin: 0 0 5px;
  border-radius: 0;
}
.page-home .home-tiles .tile h2 {
  color: var(--ink);
  font-size: 0.98rem;
  margin-bottom: 5px;
}
.page-home .home-tiles .tile .icon {
  width: 24px;
  height: 24px;
  margin-bottom: 8px;
  color: var(--muted);
}
.page-home .home-tiles .tile .icon svg { width: 22px; height: 22px; }
.page-home .home-tiles .tile:hover .icon { color: var(--accent); }
.page-home .home-tiles .tile:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  transition: border-color 150ms, transform 150ms;
}

/* Sharper nav on home only — kept in sync with global */
.page-home .site-nav .nav-links {
  border-radius: 4px;
}
.page-home .site-nav a.nav-link {
  border-radius: 3px;
}

/* Legacy hero fallbacks */
.hero { padding: 36px 0 28px; }
.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 12px;
}
.hero .lead { max-width: 36rem; margin: 0 0 10px; font-size: 1.08rem; color: var(--ink); }
.hero .sub-lead {
  max-width: 36rem; margin: 0 0 24px;
  font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted);
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.tile {
  display: block;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 150ms, transform 150ms, box-shadow 150ms;
}
.tile:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  color: var(--ink);
}
.tile:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tile .icon {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; margin-bottom: 12px; color: var(--accent);
}
.tile .icon svg { width: 24px; height: 24px; display: block; }
.tile h2 { font-size: 1rem; color: var(--accent); margin-bottom: 6px; }
.tile p { font-size: 0.84rem; color: var(--muted); margin: 0; line-height: 1.5; }

/* ── Dashboard ── */
.dash-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 28px;
}

.user-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 16px;
  font-size: 0.85rem;
}

.user-pill .avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-dim));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #061014;
}

.user-pill .meta { color: var(--muted); font-size: 0.78rem; }
.user-pill .plan-tag {
  color: var(--gold);
  font-weight: 600;
  font-size: 0.8rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}

.stat-card .label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 8px;
}

.stat-card .value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
}

.stat-card .hint { font-size: 0.8rem; color: var(--muted); margin-top: 4px; }

.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  margin-bottom: 20px;
}

.panel h2 {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 16px;
}

.form-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.form-row label {
  display: flex;
  flex-direction: column;
  font-size: 0.75rem;
  margin-bottom: 0;
  min-width: 100px;
}

.form-row input, .form-row select {
  margin-top: 3px;
  padding: 7px 10px;
  font-size: 0.85rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

th, td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
}

th { color: var(--muted); font-weight: 600; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; }
tr:hover td { background: rgba(51, 224, 200, 0.04); }

.quota { font-size: 0.82rem; color: var(--muted); margin-bottom: 4px; }

#log {
  font-family: "Consolas", "Monaco", monospace;
  font-size: 0.75rem;
  color: var(--muted);
  max-height: 140px;
  overflow-y: auto;
  margin-top: 12px;
  padding: 10px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  margin-bottom: 16px;
}

.alert-warn {
  background: rgba(240, 180, 41, 0.1);
  border: 1px solid rgba(240, 180, 41, 0.3);
  color: var(--warn);
}

/* ── Pricing ── */
.pricing-header { text-align: center; margin-bottom: 36px; }
.pricing-header h1 { font-size: 2rem; }

.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
}

.plan-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s, transform 0.2s;
}

.plan-card:hover { border-color: var(--border-light); }
.plan-card.featured {
  border-color: var(--accent);
  background: linear-gradient(160deg, var(--card) 0%, rgba(51, 224, 200, 0.06) 100%);
  transform: scale(1.02);
}

.plan-card .plan-name { font-size: 1.1rem; font-weight: 600; }
.plan-card .price {
  font-size: 2.2rem;
  font-weight: 700;
  margin: 14px 0 6px;
  color: var(--ink);
}
.plan-card .price small { font-size: 0.85rem; font-weight: 400; color: var(--muted); }
.plan-card .desc { color: var(--muted); font-size: 0.85rem; flex: 1; margin-bottom: 16px; }
.plan-card ul { font-size: 0.82rem; color: var(--muted); margin-bottom: 20px; padding-left: 18px; }
.plan-card ul li { margin-bottom: 5px; }
.plan-card ul li::marker { color: var(--accent); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }

  .nav-drawer {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex: none;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 16px 20px 20px;
    background: rgba(15, 21, 32, 0.98);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
    display: none;
  }

  .nav-drawer.open { display: flex; }

  .nav-links {
    flex-direction: column;
    border-radius: var(--radius-sm);
    padding: 6px;
    gap: 4px;
  }

  .site-nav a.nav-link {
    width: 100%;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.92rem;
  }

  .nav-end {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 12px;
  }

  .lang-picker { width: 100%; }
  .lang-btn { width: 100%; justify-content: center; }
  .lang-panel {
    position: static;
    margin-top: 6px;
    width: 100%;
    box-shadow: none;
  }
  .lang-panel[hidden] { display: none; }
  .lang-panel:not([hidden]) { display: block; }

  .nav-auth {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }

  .nav-auth .btn-nav,
  .nav-auth .nav-user {
    width: 100%;
    justify-content: center;
    text-align: center;
    max-width: none;
  }

  .nav-user { padding: 10px 14px; border-radius: var(--radius-sm); }
}

@media (max-width: 600px) {
  .site-nav { padding: 0 14px; gap: 8px; }
  .hero { padding: 32px 0 24px; }
}
