/* RideBook — shared styles.
   Palette locked to the app so the site and the product feel like one thing. */

:root {
  --bg: #0f1b2d;
  --bg-deep: #0a1320;
  --surface: #16263d;
  --surface-2: #1d3350;
  --line: #23395a;
  --primary: #00d9c0;
  --primary-dim: #00b8a3;
  --on-primary: #0f1b2d;
  --text: #f2f5f7;
  --muted: #9db0c7;
  --faint: #6b7f99;
  --good: #3ddc97;
  --warn: #ffb020;
  --bad: #ff5a5f;
  --radius: 16px;
  --radius-lg: 24px;
  --max: 1140px;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dim); }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------------------------------------------------------------- header */

header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(15, 27, 45, .82);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
header.scrolled { border-bottom-color: var(--line); }

.nav { display: flex; align-items: center; gap: 28px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); letter-spacing: -.2px; }
.brand img { width: 32px; height: 32px; border-radius: 9px; }
.nav-links { margin-left: auto; display: flex; gap: 26px; align-items: center; }
.nav-links a { color: var(--muted); font-size: 14.5px; font-weight: 500; }
.nav-links a:hover { color: var(--text); }
.nav-toggle { display: none; margin-left: auto; background: none; border: 0; color: var(--text); font-size: 22px; cursor: pointer; }

/* ------------------------------------------------------------------- ui */

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 24px; border-radius: 999px;
  font-weight: 600; font-size: 15px; border: 1px solid transparent;
  transition: transform .2s var(--ease), box-shadow .3s var(--ease), background .2s;
  cursor: pointer;
}
.btn-primary { background: var(--primary); color: var(--on-primary); box-shadow: 0 8px 30px rgba(0, 217, 192, .22); }
.btn-primary:hover { color: var(--on-primary); transform: translateY(-2px); box-shadow: 0 14px 40px rgba(0, 217, 192, .34); }
.btn-ghost { border-color: var(--line); color: var(--text); background: transparent; }
.btn-ghost:hover { border-color: var(--primary); color: var(--text); transform: translateY(-2px); }

.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 999px;
  background: rgba(0, 217, 192, .10); border: 1px solid rgba(0, 217, 192, .28);
  color: var(--primary); font-size: 13px; font-weight: 600; letter-spacing: .2px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); animation: pulse 2s infinite; }
@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0, 217, 192, .55); }
  50% { opacity: .75; box-shadow: 0 0 0 7px rgba(0, 217, 192, 0); }
}

h1, h2, h3 { letter-spacing: -.8px; line-height: 1.14; font-weight: 700; }
h1 { font-size: clamp(2.4rem, 5.6vw, 4rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.12rem; letter-spacing: -.2px; }
.lead { color: var(--muted); font-size: clamp(1.02rem, 1.6vw, 1.18rem); }
.eyebrow { color: var(--primary); font-size: 12.5px; font-weight: 700; letter-spacing: 1.6px; text-transform: uppercase; }

section { padding: 96px 0; position: relative; }

/* ----------------------------------------------------------------- hero */

.hero { padding: 76px 0 60px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero h1 { margin: 20px 0 18px; }
.hero h1 .accent {
  background: linear-gradient(100deg, var(--primary), #7af5e4);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-cta { display: flex; gap: 14px; margin-top: 30px; flex-wrap: wrap; }
.hero-note { margin-top: 18px; color: var(--faint); font-size: 13.5px; }

.glow {
  position: absolute; border-radius: 50%; filter: blur(90px); pointer-events: none; z-index: 0;
}
.glow-1 { width: 520px; height: 520px; background: rgba(0, 217, 192, .13); top: -180px; right: -120px; }
.glow-2 { width: 420px; height: 420px; background: rgba(0, 120, 200, .10); bottom: -200px; left: -140px; }
.wrap, .hero-grid { position: relative; z-index: 1; }

/* phone frames */
.phones { display: flex; justify-content: center; gap: 18px; perspective: 1400px; }
.phone {
  border-radius: 30px; border: 1px solid var(--line); overflow: hidden;
  background: var(--surface);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55);
  transition: transform .5s var(--ease);
}
.phone img { display: block; width: 100%; height: auto; }
.phone-main { width: 246px; transform: rotateY(-8deg) rotateX(2deg); }
.phone-side { width: 210px; margin-top: 44px; transform: rotateY(-14deg) rotateX(2deg); opacity: .93; }
.phones:hover .phone-main { transform: rotateY(-4deg) translateY(-8px); }
.phones:hover .phone-side { transform: rotateY(-9deg) translateY(-4px); }
.float { animation: float 7s ease-in-out infinite; }
.float-2 { animation: float 7s ease-in-out infinite reverse; }
@keyframes float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -14px; }
}

/* ------------------------------------------------- live speedometer mock */

.mock { background: var(--bg); padding: 14px 14px 16px; }
.mock-bar {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; font-weight: 600; color: var(--text);
  font-variant-numeric: tabular-nums; margin-bottom: 6px;
}
.mock-bar .gps { color: var(--good); font-size: 10.5px; font-weight: 500; display: flex; align-items: center; gap: 4px; }
.mock-bar .gps::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--good); box-shadow: 0 0 8px var(--good); }

#gauge svg { width: 100%; height: auto; display: block; }
.g-track { fill: none; stroke: rgba(157, 176, 199, .18); stroke-width: 9; stroke-linecap: round; }
.g-progress {
  fill: none; stroke: var(--primary); stroke-width: 9; stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(0, 217, 192, .55));
  transition: stroke-dasharray .08s linear;
}
.g-tick { stroke: rgba(157, 176, 199, .45); stroke-width: 1.4; stroke-linecap: round; }
.g-tick.major { stroke: rgba(157, 176, 199, .85); stroke-width: 2.2; }
.g-label { fill: var(--faint); font-size: 9px; text-anchor: middle; font-family: inherit; }
.g-needle { stroke: var(--primary); stroke-width: 3; stroke-linecap: round; }
.g-hub { fill: var(--primary); }
.g-hub-in { fill: var(--bg); }
.g-speed { fill: var(--text); font-size: 40px; font-weight: 600; text-anchor: middle; font-family: inherit; font-variant-numeric: tabular-nums; }
.g-unit { fill: var(--faint); font-size: 10px; text-anchor: middle; letter-spacing: 1.6px; font-family: inherit; }

.mock-stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px;
  background: var(--surface); border-radius: 12px; padding: 10px 4px; margin-top: 4px;
}
.mock-stats div { text-align: center; }
.mock-stats b { display: block; font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.mock-stats i { display: block; font-size: 8px; color: var(--faint); font-style: normal; }
.mock-stats span { display: block; font-size: 9px; color: var(--muted); margin-top: 1px; }
.mock-btn {
  margin-top: 10px; text-align: center; padding: 10px; border-radius: 999px;
  background: var(--bad); color: #fff; font-size: 12.5px; font-weight: 600;
}

/* ----------------------------------------------------------- stat strip */

.strip {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; margin-top: 64px;
}
.strip div { background: var(--bg); padding: 22px 18px; text-align: center; }
.strip b { display: block; font-size: 1.7rem; color: var(--primary); letter-spacing: -1px; }
.strip span { font-size: 12.5px; color: var(--faint); }

/* Faint grid behind the hero. Gives the dark background some depth without
   competing with anything on top of it. */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(35, 57, 90, .35) 1px, transparent 1px),
    linear-gradient(90deg, rgba(35, 57, 90, .35) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 65% at 50% 30%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 90% 65% at 50% 30%, #000 20%, transparent 78%);
}

/* -------------------------------------------------------------- feature */

.section-head { max-width: 660px; margin-bottom: 52px; }
.section-head h2 { margin: 12px 0 14px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
  transition: transform .35s var(--ease), border-color .3s, background .3s;
}
.card { position: relative; overflow: hidden; }
/* A teal line that draws itself across the top on hover — cheap, and it makes
   the grid feel responsive rather than static. */
.card::after {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--primary), transparent);
  transform: scaleX(0); transform-origin: left;
  transition: transform .45s var(--ease);
}
.card:hover::after { transform: scaleX(1); }
.card:hover { transform: translateY(-5px); border-color: rgba(0, 217, 192, .42); background: var(--surface-2); }
.card:hover .ico { background: rgba(0, 217, 192, .2); }
.card .ico { transition: background .3s; }
.card .ico {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(0, 217, 192, .12); color: var(--primary); margin-bottom: 16px;
}
.card .ico svg { width: 21px; height: 21px; }
.card p { color: var(--muted); font-size: 14.5px; margin-top: 8px; }

/* showcase rows */
.show { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; margin-bottom: 104px; }
.show:last-child { margin-bottom: 0; }
.show.flip .show-text { order: 2; }
.show-shot { display: flex; justify-content: center; }
.show-shot .phone { width: 268px; }
.show ul { list-style: none; margin-top: 20px; }
.show li { color: var(--muted); font-size: 14.8px; padding-left: 26px; position: relative; margin-bottom: 11px; }
.show li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 9px; height: 9px; border-radius: 3px; background: var(--primary); opacity: .85;
}

/* honesty block */
.honest {
  border: 1px solid var(--line); border-left: 3px solid var(--primary);
  background: var(--surface); border-radius: 0 var(--radius) var(--radius) 0;
  padding: 26px 28px;
}
.honest h3 { margin-bottom: 8px; }
.honest p { color: var(--muted); font-size: 14.6px; }
.honest + .honest { margin-top: 16px; }

/* ------------------------------------------------------------------ cta */

.cta {
  background: linear-gradient(150deg, var(--surface) 0%, var(--bg-deep) 100%);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 60px 44px; text-align: center; position: relative; overflow: hidden;
}
.cta h2 { margin-bottom: 14px; }
.cta p { color: var(--muted); max-width: 560px; margin: 0 auto 28px; }

/* --------------------------------------------------------------- forms */

.form { display: grid; gap: 18px; max-width: 620px; }
label { font-size: 13px; font-weight: 600; color: var(--muted); display: block; margin-bottom: 7px; letter-spacing: .2px; }
input, textarea, select {
  width: 100%; padding: 13px 15px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--line);
  color: var(--text); font: inherit; font-size: 15px;
  transition: border-color .2s, box-shadow .2s;
}
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 217, 192, .14);
}
textarea { min-height: 140px; resize: vertical; }
.hp { position: absolute; left: -9999px; opacity: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; }
.choice span {
  display: inline-block; padding: 9px 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 14px; color: var(--muted); cursor: pointer; transition: all .2s;
}
.choice input:checked + span { border-color: var(--primary); color: var(--primary); background: rgba(0, 217, 192, .10); }
.form-note { color: var(--faint); font-size: 13px; }

/* --------------------------------------------------------------- legal */

.legal { max-width: 780px; }
.legal h2 { margin: 44px 0 14px; font-size: 1.5rem; }
.legal h3 { margin: 26px 0 8px; }
.legal p, .legal li { color: var(--muted); font-size: 15.2px; }
.legal ul { margin: 12px 0 12px 22px; }
.legal li { margin-bottom: 8px; }
.legal strong { color: var(--text); }
.updated { color: var(--faint); font-size: 13.5px; }

table.data { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 14.4px; }
table.data th, table.data td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.data th { color: var(--text); font-size: 12.5px; text-transform: uppercase; letter-spacing: .8px; }
table.data td { color: var(--muted); }

/* accordion */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  padding: 20px 0; cursor: pointer; font-weight: 600; list-style: none;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--primary); font-size: 22px; font-weight: 400; transition: transform .25s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq p { color: var(--muted); font-size: 14.8px; padding-bottom: 22px; max-width: 720px; }

/* -------------------------------------------------------------- footer */

footer { border-top: 1px solid var(--line); padding: 48px 0 40px; margin-top: 40px; }
.foot { display: flex; gap: 28px; align-items: center; flex-wrap: wrap; }
.foot-links { margin-left: auto; display: flex; gap: 22px; flex-wrap: wrap; }
.foot-links a { color: var(--muted); font-size: 14px; }
.foot-links a:hover { color: var(--primary); }
.copy { color: var(--faint); font-size: 13px; margin-top: 22px; }

/* ------------------------------------------------------------- reveals */

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ----------------------------------------------------------- responsive */

@media (max-width: 900px) {
  .hero-grid, .show, .show.flip .show-text { grid-template-columns: 1fr; order: 0; }
  .show { gap: 34px; margin-bottom: 72px; }
  .cards { grid-template-columns: 1fr; }
  .strip { grid-template-columns: repeat(2, 1fr); }
  .field-row { grid-template-columns: 1fr; }
  .nav-links {
    display: none; position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 15px 24px; width: 100%; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: block; }
  section { padding: 68px 0; }
  .cta { padding: 44px 24px; }
  .phone-side { display: none; }
  .phone-main { transform: none; }
}
