/* ---------- design tokens ---------- */
:root {
  color-scheme: light;
  --page:            #f9f9f7;
  --surface-1:       #fcfcfb;
  --text-primary:    #0b0b0b;
  --text-secondary:  #52514e;
  --text-muted:      #898781;
  --gridline:        #e1e0d9;
  --border:          rgba(11,11,11,0.10);
  --accent:          #2a78d6;
  --shadow: 0 1px 3px rgba(11,11,11,.06), 0 1px 2px rgba(11,11,11,.04);
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--text-primary);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
}
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 22px; }
.wrap-narrow { max-width: 720px; }
a { color: inherit; }
h1, h2, h3 { font-weight: 700; letter-spacing: -0.01em; }
.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;
}

/* Offset in-page anchor targets so the sticky nav doesn't cover them on jump. */
#top, #waitlist, #proof, #how-it-works, #faq { scroll-margin-top: 72px; }

/* ---------- top nav ---------- */
.topnav {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--surface-1) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.topnav-inner { display: flex; align-items: center; gap: 20px; height: 56px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; text-decoration: none; }
.topnav-links { display: flex; gap: 20px; margin-left: 36px; font-size: 13.5px; }
.topnav-links a { text-decoration: none; color: var(--text-secondary); }
.topnav-links a:hover { color: var(--text-primary); }
.topnav-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.btn-ghost {
  font-size: 13.5px; font-weight: 600; text-decoration: none; color: #fff;
  background: var(--accent); padding: 8px 16px; border-radius: 999px; white-space: nowrap;
}

/* ---------- hero ---------- */
.hero {
  background: radial-gradient(ellipse 900px 500px at 50% -10%, #16324f 0%, transparent 60%), #0b0b0b;
  color: #fff;
  padding: 80px 0 76px;
  border-bottom: 3px solid var(--accent);
  text-align: center;
}
.hero-inner { max-width: 680px; margin: 0 auto; }
.eyebrow {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  color: #86b6ef; opacity: .9; margin: 0 0 18px;
}
.hero h1 { margin: 0; font-size: clamp(32px, 5vw, 48px); line-height: 1.12; }
.hero-sub { margin: 20px auto 0; color: #b7c4d6; font-size: 16.5px; max-width: 560px; }
.hero-cta { margin-top: 34px; }
.hero-microcopy { margin: 10px 0 0; font-size: 12.5px; color: #7f93a8; }

/* ---------- waitlist form ---------- */
.waitlist-form { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.waitlist-form input[type="email"] {
  font: inherit; font-size: 14.5px; padding: 12px 18px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface-1); color: var(--text-primary);
  width: 280px; max-width: 100%;
}
.waitlist-form.on-dark input[type="email"] {
  background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.18); color: #fff;
}
.waitlist-form.on-dark input[type="email"]::placeholder { color: #7f93a8; }
.waitlist-form button {
  font: inherit; font-size: 14.5px; font-weight: 600; padding: 12px 22px; border-radius: 999px;
  border: none; background: var(--accent); color: #fff; cursor: pointer; white-space: nowrap;
}
.waitlist-form button:disabled { opacity: .6; cursor: default; }

/* ---------- sections ---------- */
.section { padding: 72px 0; border-bottom: 1px solid var(--border); }
.section-eyebrow {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
  font-weight: 700; margin: 0 0 8px;
}
.section h2 { font-size: clamp(24px, 3.4vw, 32px); margin: 0 0 12px; }
.section-sub { color: var(--text-secondary); font-size: 15px; max-width: 620px; margin: 0 0 36px; }

/* ---------- leaderboard preview ---------- */
.lb-preview { display: flex; flex-direction: column; gap: 10px; max-width: 720px; }
.lb-row {
  display: grid; grid-template-columns: 40px 1fr 120px; gap: 16px; align-items: center;
  padding: 14px 16px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-1);
}
.lb-row.win {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, var(--surface-1));
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 30%, transparent);
}
.medal {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--page); color: var(--text-muted);
  font-family: ui-monospace, monospace; font-weight: 700; font-size: 13px;
  border: 1px solid var(--border);
}
.medal.gold { background: #eda100; color: #3a2900; border-color: transparent; }
.lb-model { font-family: ui-monospace, monospace; font-size: 14.5px; font-weight: 600; margin-bottom: 8px; word-break: break-all; }
.lb-bar-track { height: 8px; background: var(--gridline); border-radius: 0 4px 4px 0; overflow: hidden; }
.lb-bar { height: 100%; border-radius: 0 4px 4px 0; }
.lb-metric { text-align: right; }
.lb-metric-val { font-family: ui-monospace, monospace; font-size: 20px; font-weight: 700; line-height: 1; }
.lb-row.win .lb-metric-val { color: var(--accent); }
.lb-metric-lab { font-size: 10.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; margin-top: 3px; }
.lb-more { margin: 14px 2px 0; font-size: 13px; color: var(--text-muted); }

/* ---------- steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 56px; }
.step {
  padding: 22px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-1);
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px;
  border-radius: 50%; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent);
  font-weight: 700; font-size: 13.5px; margin-bottom: 14px;
}
.step h3 { font-size: 15.5px; margin: 0 0 6px; }
.step p { font-size: 13.5px; color: var(--text-secondary); margin: 0; }

/* ---------- features ---------- */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feature-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.feature h3 { font-size: 16px; margin: 0 0 8px; }
.feature p { font-size: 14px; color: var(--text-secondary); margin: 0; line-height: 1.6; }

/* ---------- FAQ ---------- */
.faq-list { display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  border: 1px solid var(--border); border-radius: 12px; background: var(--surface-1); padding: 4px 20px;
}
.faq-item summary {
  cursor: pointer; padding: 16px 0; font-weight: 600; font-size: 15px; list-style: none;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; font-size: 20px; font-weight: 400; color: var(--text-muted); flex: none;
}
.faq-item[open] summary::after { content: "\2212"; }
.faq-item p { margin: 0 0 18px; color: var(--text-secondary); font-size: 14px; line-height: 1.65; }

/* ---------- CTA band ---------- */
.cta-band {
  background: radial-gradient(ellipse 700px 400px at 50% 0%, #16324f 0%, transparent 65%), #0b0b0b;
  padding: 64px 0; color: #fff; text-align: center;
}
.cta-inner { max-width: 560px; margin: 0 auto; }
.cta-band h2 { font-size: clamp(22px, 3vw, 28px); margin: 0 0 10px; }
.cta-band p { color: #b7c4d6; font-size: 15px; margin: 0 0 28px; }

/* ---------- footer ---------- */
.foot { padding: 36px 0; }
.foot-inner { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.foot-tagline { color: var(--text-muted); font-size: 13px; margin: 0; }

/* ---------- waitlist modal ---------- */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(11,11,11,.5);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  opacity: 0; visibility: hidden; transition: opacity .18s ease;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
  position: relative; width: 100%; max-width: 400px;
  background: var(--surface-1); border-radius: 16px; padding: 34px 28px 28px;
  text-align: center; box-shadow: 0 24px 60px rgba(11,11,11,.28);
  transform: translateY(10px) scale(.97); transition: transform .18s ease;
}
.modal-overlay.open .modal { transform: translateY(0) scale(1); }
.modal-close {
  position: absolute; top: 14px; right: 14px; width: 30px; height: 30px;
  border: none; background: transparent; color: var(--text-muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center; border-radius: 999px;
}
.modal-close:hover { background: var(--page); color: var(--text-primary); }
.modal-icon {
  width: 52px; height: 52px; border-radius: 50%; margin: 0 auto 18px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  display: flex; align-items: center; justify-content: center;
}
.modal h3 { font-size: 19px; margin: 0 0 10px; }
.modal p { font-size: 14.5px; color: var(--text-secondary); line-height: 1.6; margin: 0 0 26px; }
.modal-btn {
  font: inherit; font-size: 14.5px; font-weight: 600; padding: 11px 28px; border-radius: 999px;
  border: none; background: var(--accent); color: #fff; cursor: pointer;
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .features { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .topnav-links { display: none; }
  .steps { grid-template-columns: 1fr; }
  .lb-row { grid-template-columns: 34px 1fr; grid-auto-rows: auto; }
  .lb-metric { grid-column: 2; text-align: left; margin-top: 6px; }
  .section { padding: 52px 0; }
  .hero { padding: 56px 0 48px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
