/* Pit Captain — website brand system.
   Lifted 1:1 from the app/launcher :root vars (see ios/PitCaptain/Theme.swift and
   pit_captain_launcher.html) so the site matches the product exactly. */
:root {
  --navy:   #0b0f17;
  --navy-2: #121a2a;
  --panel:  rgba(20,28,44,0.55);
  --card:   rgba(28,38,58,0.50);
  --card-2: rgba(34,46,70,0.62);
  --border: rgba(120,140,175,0.16);
  --border-2: rgba(120,140,175,0.28);
  --red:    #e4030f;
  --red-hi: #ff2634;
  --blue:   #1f6fe0;
  --blue-2: #0050ac;
  --orange: #ff6a00;
  --text:   #f5f7fb;
  --muted:  #8b9bb8;
  --faint:  #5d6b86;
  --live:   #24e07a;
  --display: 'Rajdhani', system-ui, sans-serif;
  --mono:    'IBM Plex Mono', ui-monospace, monospace;
  --body:    'Inter', -apple-system, system-ui, 'Segoe UI', Roboto, sans-serif;
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px; --r-xl: 22px;
  --sh-2: 0 4px 16px rgba(0,0,0,0.35);
  --sh-3: 0 10px 34px rgba(0,0,0,0.45);
  --glow-red:  0 6px 26px rgba(228,3,15,0.38);
  --glow-blue: 0 6px 26px rgba(31,111,224,0.36);
  --maxw: 1080px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--navy); color: var(--text);
  font-family: var(--body); font-size: 16px; line-height: 1.6;
  letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100%; overflow-x: hidden;
}
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--red-hi); }
img { max-width: 100%; display: block; }

/* Ambient race-night backdrop: radial glows + vignette, no external image needed. */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 40% at 78% 8%, rgba(31,111,224,0.16), transparent 60%),
    radial-gradient(55% 40% at 12% 4%, rgba(228,3,15,0.14), transparent 62%),
    linear-gradient(180deg, #0b0f17 0%, #0a0e16 100%);
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.eyebrow {
  font-family: var(--body); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.16em; color: var(--faint);
}
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.rule { width: 46px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--red), var(--red-hi)); margin: 16px 0 26px; }

/* ── Nav ─────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: rgba(11,15,23,0.72); border-bottom: 1px solid var(--border);
}
.nav-inner { max-width: var(--maxw); margin: 0 auto; padding: 13px 22px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand .mark { height: 26px; width: auto; flex: none; }
.brand b { font-family: var(--display); font-weight: 700; font-size: 20px;
  letter-spacing: 0.02em; color: var(--text); }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--muted); font-weight: 500; font-size: 14.5px; }
.nav-links a:hover { color: var(--text); }
@media (max-width: 640px) { .nav-links a:not(.btn) { display: none; } }

/* ── Buttons ─────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--body); font-weight: 600; font-size: 15px;
  padding: 12px 22px; border-radius: var(--r-md); border: 1px solid transparent;
  cursor: pointer; transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-red { background: linear-gradient(180deg, var(--red-hi), var(--red)); color: #fff;
  box-shadow: var(--glow-red); }
.btn-red:hover { color: #fff; }
.btn-ghost { background: rgba(120,140,175,0.08); color: var(--text); border-color: var(--border-2); }
.btn-ghost:hover { color: var(--text); background: rgba(120,140,175,0.14); }
.btn-block { width: 100%; }

/* ── Hero ────────────────────────────────────────── */
.hero { text-align: center; padding: 72px 0 64px; }
.hero-logo { width: min(340px, 74vw); margin: 0 auto 30px; display: block;
  filter: drop-shadow(0 6px 22px rgba(0,0,0,0.5)) drop-shadow(0 0 40px rgba(228,3,15,0.28)); }
.hero .pill {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px;
  padding: 7px 14px; border-radius: 999px; border: 1px solid var(--border-2);
  background: rgba(120,140,175,0.07); color: var(--muted);
  font-size: 12.5px; font-weight: 600; letter-spacing: 0.02em;
}
.hero .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live);
  box-shadow: 0 0 10px var(--live); }
.hero h1 {
  font-family: var(--display); font-weight: 700; letter-spacing: -0.01em;
  font-size: clamp(40px, 7vw, 74px); line-height: 1.02; margin: 0 auto 20px; max-width: 15ch;
}
.hero h1 .accent { background: linear-gradient(90deg, var(--red-hi), var(--orange));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { color: var(--muted); font-size: clamp(16px, 2.4vw, 20px);
  max-width: 60ch; margin: 0 auto 34px; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero .fine { margin-top: 18px; color: var(--faint); font-size: 13px; }

/* ── Sections ────────────────────────────────────── */
section { padding: 60px 0; }
.section-head { text-align: center; margin-bottom: 44px; }
.section-head h2 { font-family: var(--display); font-weight: 700;
  font-size: clamp(28px, 4.4vw, 40px); letter-spacing: -0.01em; }
.section-head p { color: var(--muted); max-width: 56ch; margin: 12px auto 0; }

.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .grid-3 { grid-template-columns: 1fr; } .grid-2 { grid-template-columns: 1fr; } }

.card-tile {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 26px 24px; box-shadow: var(--sh-2);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.card-tile .ico { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center;
  margin-bottom: 16px; background: rgba(31,111,224,0.14); border: 1px solid rgba(31,111,224,0.3); }
.card-tile.red .ico { background: rgba(228,3,15,0.14); border-color: rgba(228,3,15,0.34); }
.card-tile svg { width: 22px; height: 22px; stroke: var(--blue); fill: none; stroke-width: 1.9;
  stroke-linecap: round; stroke-linejoin: round; }
.card-tile.red svg { stroke: var(--red-hi); }
.card-tile h3 { font-family: var(--display); font-weight: 600; font-size: 21px; margin-bottom: 8px; }
.card-tile p { color: var(--muted); font-size: 15px; }

/* Steps */
.steps { counter-reset: step; display: grid; gap: 16px; max-width: 760px; margin: 0 auto; }
.step { display: flex; gap: 18px; align-items: flex-start;
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--r-md); padding: 20px 22px; }
.step .n { counter-increment: step; font-family: var(--display); font-weight: 700; font-size: 22px;
  width: 40px; height: 40px; flex: none; border-radius: 10px; display: grid; place-items: center;
  color: #fff; background: linear-gradient(180deg, var(--blue), var(--blue-2)); box-shadow: var(--glow-blue); }
.step .n::before { content: counter(step); }
.step h3 { font-family: var(--display); font-weight: 600; font-size: 19px; margin-bottom: 3px; }
.step p { color: var(--muted); font-size: 15px; }

/* ── Beta form ───────────────────────────────────── */
.beta { padding: 20px 0 80px; }
.beta-card {
  max-width: 620px; margin: 0 auto; padding: 34px 30px;
  background: linear-gradient(180deg, rgba(28,38,58,0.62), rgba(18,26,42,0.62));
  border: 1px solid var(--border-2); border-radius: var(--r-xl); box-shadow: var(--sh-3);
}
.beta-card h2 { font-family: var(--display); font-weight: 700; font-size: 30px; text-align: center; }
.beta-card .sub { color: var(--muted); text-align: center; margin: 8px auto 26px; max-width: 46ch; }
.field { margin-bottom: 16px; }
.field label { display: block; font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 7px; }
.field input, .field select, .field textarea {
  width: 100%; font-family: var(--body); font-size: 15.5px; color: var(--text);
  background: rgba(11,15,23,0.6); border: 1px solid var(--border-2); border-radius: var(--r-md);
  padding: 13px 14px; outline: none; transition: border-color .12s ease, box-shadow .12s ease;
}
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--blue); box-shadow: 0 0 0 3px rgba(31,111,224,0.18); }
.field textarea { resize: vertical; min-height: 84px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 520px) { .row { grid-template-columns: 1fr; } }
.form-msg { margin-top: 14px; text-align: center; font-size: 14.5px; font-weight: 500; min-height: 20px; }
.form-msg.ok { color: var(--live); }
.form-msg.err { color: var(--red-hi); }
.beta-fine { text-align: center; color: var(--faint); font-size: 12.5px; margin-top: 14px; }

/* Success panel */
.beta-done { display: none; text-align: center; padding: 10px 0; }
.beta-done.show { display: block; }
.beta-done .check { width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(36,224,122,0.14); border: 1px solid rgba(36,224,122,0.4); }
.beta-done .check svg { width: 32px; height: 32px; stroke: var(--live); fill: none; stroke-width: 2.4;
  stroke-linecap: round; stroke-linejoin: round; }
.beta-done h2 { font-family: var(--display); font-weight: 700; font-size: 28px; }
.beta-done p { color: var(--muted); margin-top: 8px; }

/* ── Legal / content pages ───────────────────────── */
.doc { max-width: 780px; margin: 0 auto; padding: 54px 22px 90px; }
.doc h1 { font-family: var(--display); font-weight: 700; font-size: 38px; letter-spacing: -0.01em; margin-bottom: 4px; }
.doc .updated { font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; color: var(--faint); }
.doc h2 { font-family: var(--display); font-weight: 600; font-size: 23px; color: var(--text); margin: 38px 0 10px; }
.doc p, .doc li { color: var(--muted); margin-bottom: 10px; }
.doc strong { color: var(--text); }
.doc ul { padding-left: 22px; }
.doc li { margin-bottom: 8px; }
.doc .card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 20px 24px; margin: 22px 0; }
.faq-q { font-family: var(--display); font-weight: 600; font-size: 19px; color: var(--text); margin: 26px 0 6px; }

/* ── Footer ──────────────────────────────────────── */
.footer { border-top: 1px solid var(--border); padding: 40px 0 60px; margin-top: 40px; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center; }
.footer .brand b { font-size: 18px; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a { color: var(--muted); font-size: 14px; }
.footer-links a:hover { color: var(--text); }
.footer .legal { color: var(--faint); font-size: 12.5px; margin-top: 18px; line-height: 1.6; }
