/* Carva — public site.
   Mobile-first, no framework, no webfont fetch. One stylesheet so the page
   paints on one round trip over mobile data. */
:root {
  --bg: #070a0e;
  --bg-2: #0b1016;
  --card: #0f151b;
  --line: #1b232c;
  --line-soft: #141b23;
  --text: #f6f8fa;
  --muted: #9aa6b1;
  --muted-2: #6f7b86;
  --lime: #A3E635;
  --lime-ink: #07100b;
  --max: 1120px;
  --pad: 22px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

/* Visible focus for keyboard users -- never removed, only styled. */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
  border-radius: 6px;
}

.shell { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 20;
  background: rgba(7, 10, 14, .82);
  backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.site-head .shell { display: flex; align-items: center; gap: 16px; height: 64px; }
/* The logo is a link, so its tappable box -- not just the image -- has to
   reach 44px. Padding on the anchor does that without enlarging the mark. */
.site-head .brand-link { display: inline-flex; align-items: center; min-height: 44px; padding: 12px 4px; margin-left: -4px; }
.site-head img { height: 20px; width: auto; }
.site-head nav { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.site-head nav a { color: var(--muted); text-decoration: none; font-size: 14px;
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; }
.site-head nav a:hover { color: var(--text); }
@media (max-width: 620px) { .site-head nav .hide-sm { display: none; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 26px; border-radius: 999px;
  font-size: 15px; font-weight: 700; text-decoration: none;
  border: 1px solid transparent; cursor: pointer; font-family: inherit;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--lime); color: var(--lime-ink); }
.btn-primary:hover { background: #c6ff5e; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--muted-2); }
/* 44px is the accessibility floor for a touch target, so the compact
   variant shrinks horizontally only. */
.btn-sm { min-height: 44px; padding: 0 20px; font-size: 14px; }

/* ---------- type ---------- */
.eyebrow {
  font-size: 11.5px; font-weight: 800; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--lime); margin: 0 0 14px;
}
.eyebrow.muted { color: var(--muted-2); }
h1 {
  margin: 0; font-size: clamp(34px, 8.4vw, 68px); line-height: 1.04;
  letter-spacing: -.035em; font-weight: 800;
}
h2 {
  margin: 0 0 14px; font-size: clamp(26px, 5vw, 40px); line-height: 1.12;
  letter-spacing: -.028em; font-weight: 800;
}
h3 { margin: 0 0 6px; font-size: 17px; letter-spacing: -.01em; font-weight: 700; }
.lede { color: var(--muted); font-size: clamp(16px, 2.4vw, 19px); line-height: 1.6; margin: 18px 0 0; }
p { margin: 0 0 14px; color: var(--muted); }
.measure { max-width: 60ch; }

/* ---------- sections ---------- */
section { padding: clamp(64px, 11vw, 120px) 0; }
.section-head { max-width: 640px; margin-bottom: clamp(32px, 5vw, 52px); }

/* ---------- hero ---------- */
.hero { padding-top: clamp(48px, 9vw, 96px); padding-bottom: 0; position: relative; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: -20% -30% auto -30%; height: 60%;
  background: radial-gradient(60% 60% at 50% 0%, rgba(163, 230, 53,.10), transparent 70%);
  pointer-events: none;
}
.hero-grid { position: relative; display: grid; gap: 44px; align-items: center; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-note { font-size: 13px; color: var(--muted-2); margin-top: 16px; }
.hero-shot {
  border-radius: 22px; border: 1px solid var(--line);
  overflow: hidden; background: var(--card);
  box-shadow: 0 30px 80px -30px rgba(0,0,0,.9);
}
.hero-shot img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 5; }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.05fr .95fr; gap: 60px; }
}

/* ---------- capability grid ---------- */
.caps { display: grid; gap: 14px; }
@media (min-width: 640px) { .caps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .caps { grid-template-columns: repeat(4, 1fr); gap: 18px; } }
.cap {
  background: var(--card); border: 1px solid var(--line-soft);
  border-radius: 18px; padding: 22px 20px 24px;
  transition: border-color .2s ease, transform .2s ease;
}
.cap:hover { border-color: var(--line); transform: translateY(-2px); }
.cap img { width: 52px; height: 52px; margin-bottom: 16px; }
.cap p { font-size: 14.5px; line-height: 1.55; margin: 0; }

/* ---------- alternating rows ---------- */
.row { display: grid; gap: 28px; align-items: center; }
.row + .row { margin-top: clamp(56px, 9vw, 96px); }
@media (min-width: 900px) {
  .row { grid-template-columns: 1fr 1fr; gap: 64px; }
  .row.flip .row-media { order: -1; }
}
.row-media {
  background: linear-gradient(160deg, var(--bg-2), var(--card));
  border: 1px solid var(--line-soft); border-radius: 22px;
  padding: 40px; display: flex; align-items: center; justify-content: center;
  min-height: 220px;
}
.row-media img { width: clamp(96px, 22vw, 132px); height: auto; }
.row ul { margin: 18px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.row li { color: var(--muted); font-size: 15px; padding-left: 22px; position: relative; line-height: 1.5; }
.row li::before {
  content: ''; position: absolute; left: 0; top: 8px;
  width: 7px; height: 7px; border-radius: 50%; background: var(--lime);
}

/* ---------- trust ---------- */
.trust { background: var(--bg-2); border-block: 1px solid var(--line-soft); }
.trust-grid { display: grid; gap: 16px; margin-top: 34px; }
@media (min-width: 760px) { .trust-grid { grid-template-columns: repeat(3, 1fr); } }
.trust-item { border-left: 2px solid var(--lime); padding-left: 16px; }
.trust-item h3 { font-size: 15.5px; }
.trust-item p { font-size: 14px; margin: 0; }

/* ---------- closing cta ---------- */
.close-cta { text-align: center; }
.close-cta .btn { margin-top: 26px; }

/* ---------- small print rows ---------- */
.mini {
  display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: baseline;
  padding: 22px 0; border-top: 1px solid var(--line-soft);
}
.mini b { font-size: 15px; }
.mini span { color: var(--muted); font-size: 14.5px; }
.mini a { color: var(--lime); text-decoration: none;
  display: inline-flex; align-items: center; min-height: 44px; }
.mini a:hover { text-decoration: underline; }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line-soft); padding: 44px 0 56px; }
.foot-grid { display: flex; flex-wrap: wrap; gap: 24px 40px; align-items: flex-start; }
footer img { height: 18px; width: auto; opacity: .8; }
.foot-links { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-left: auto; }
.foot-links a { color: var(--muted); text-decoration: none; font-size: 14px;
  min-height: 44px; display: inline-flex; align-items: center; }
.foot-links a:hover { color: var(--text); }
.foot-legal { color: var(--muted-2); font-size: 13px; margin: 26px 0 0; }

/* Inline text links that act as a primary next step still need a real tap
   box -- a 17px line of text is not one. */
.link-cta {
  display: inline-flex; align-items: center; min-height: 44px;
  color: var(--lime); text-decoration: none; font-size: 15px; font-weight: 600;
}
.link-cta:hover { text-decoration: underline; }

/* ============================================================
   MOBILE NAVIGATION
   The old header simply hid its links under 620px, so on a phone
   the site had no navigation at all. This is a real menu.
   ============================================================ */
.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 10px;
  background: transparent; border: 1px solid var(--line); cursor: pointer;
}
.nav-toggle span { display: block; width: 17px; height: 1.5px; background: var(--text); position: relative; }
.nav-toggle span::before, .nav-toggle span::after {
  content: ''; position: absolute; left: 0; width: 17px; height: 1.5px; background: var(--text);
  transition: transform .2s ease, top .2s ease;
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

@media (max-width: 800px) {
  .nav-toggle { display: flex; margin-left: auto; }
  .site-head nav {
    position: fixed; inset: 64px 0 auto 0; margin: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px var(--pad) 20px; max-height: calc(100dvh - 64px); overflow-y: auto;
  }
  .site-head nav[hidden] { display: none; }
  .site-head nav a { min-height: 52px; padding: 0 4px; font-size: 16px; border-bottom: 1px solid var(--line-soft); }
  .site-head nav a.btn { margin-top: 14px; border-bottom: 0; justify-content: center; }
}
@media (min-width: 801px) {
  .site-head nav { display: flex !important; }
}

/* ============================================================
   DEVICE FRAME + PRODUCT ILLUSTRATION
   These are illustrations of Carva's real interface built from the
   app's own design tokens and real feature names -- not captured
   screenshots, and never presented as such. Real captures drop into
   .device-screen later without touching any surrounding layout.
   ============================================================ */
.device {
  position: relative; width: min(280px, 78vw); margin: 0 auto;
  border-radius: 40px; padding: 10px;
  background: linear-gradient(160deg, #262f39, #11171e);
  box-shadow: 0 40px 90px -34px rgba(0,0,0,.95), 0 0 0 1px rgba(255,255,255,.05);
}
.device-screen {
  border-radius: 31px; overflow: hidden; background: var(--bg);
  aspect-ratio: 9 / 19.5; position: relative;
  display: flex; flex-direction: column; padding: 20px 15px;
  gap: 11px; font-size: 11px;
}
.device-notch {
  position: absolute; top: 8px; left: 50%; transform: translateX(-50%);
  width: 78px; height: 20px; border-radius: 12px; background: #05080b; z-index: 2;
}
/* A real captured screen: no illustration padding, the photo fills the frame. */
.device-screen--shot { padding: 0; gap: 0; }
/* .device-screen's height comes from `aspect-ratio`, but as a flex column
   its single child (<picture>) sizes to its own content by default, and a
   percentage height on <picture> or the <img> inside it can't resolve
   against that (percentages only resolve against a containing block with
   an explicit height, which a content-sized flex child doesn't have) -- it
   silently falls back to the image's raw 1558px intrinsic height, blowing
   the phone frame open and showing only a zoomed-in sliver of the actual
   screen with the site's global `img { max-width: 100% }` reset squashing
   the width to match. Absolutely positioning picture/img against
   .device-screen's own `position: relative` sidesteps that chain entirely:
   inset: 0 resolves against .device-screen's definite padding-box size
   (set by `aspect-ratio` above), not through any intermediate flex sizing. */
/* Inset from the top by the notch's own footprint (8px top + 20px tall)
   plus a small buffer, so the notch sits over the phone bezel's dead zone
   instead of the screenshot's real header row -- the gap this opens above
   the image is filled by .device-screen's own background, which matches
   the app's dark theme closely enough to read as bezel, not a seam. */
.device-screen--shot picture { position: absolute; top: 30px; right: 0; bottom: 0; left: 0; display: block; }
.device-screen--shot img { position: absolute; top: 30px; right: 0; bottom: 0; left: 0; width: 100%; height: calc(100% - 30px); object-fit: cover; object-position: top; }
.dv-top { display: flex; justify-content: space-between; color: var(--muted-2); font-size: 9.5px; padding-top: 14px; }
.dv-h { font-size: 17px; font-weight: 800; letter-spacing: -.02em; margin: 6px 0 2px; }
.dv-sub { color: var(--muted-2); font-size: 10px; }
.dv-card { background: var(--card); border: 1px solid var(--line-soft); border-radius: 13px; padding: 11px 12px; }
.dv-row { display: flex; align-items: center; gap: 9px; }
.dv-label { color: var(--muted); font-size: 9.5px; }
.dv-val { font-weight: 800; font-size: 15px; letter-spacing: -.02em; }
.dv-val.lime { color: var(--lime); }
.dv-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.dv-ring {
  width: 46px; height: 46px; border-radius: 50%; flex: none;
  background: conic-gradient(var(--lime) 0 78%, #1c242d 78% 100%);
  display: grid; place-items: center;
}
.dv-ring i { width: 36px; height: 36px; border-radius: 50%; background: var(--card);
  display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 12px; }
.dv-bar { height: 5px; border-radius: 3px; background: #1c242d; overflow: hidden; }
.dv-bar b { display: block; height: 100%; background: var(--lime); }
.dv-chip { display: inline-block; padding: 3px 8px; border-radius: 999px; font-size: 8.5px;
  font-weight: 800; letter-spacing: .5px; background: rgba(163, 230, 53,.14); color: var(--lime); }
.dv-msg { border-radius: 12px; padding: 9px 11px; font-size: 10px; line-height: 1.45; }
.dv-msg.me { background: rgba(163, 230, 53,.13); color: var(--text); margin-left: 34px; }
.dv-msg.ai { background: var(--card); border: 1px solid var(--line-soft); color: var(--muted); margin-right: 20px; }
.dv-map { flex: 1; border-radius: 13px; background:
  radial-gradient(120% 90% at 20% 20%, #16202a, #0a0f14);
  border: 1px solid var(--line-soft); position: relative; overflow: hidden; }
.dv-route { position: absolute; inset: 0; }
.dv-tabs { display: flex; justify-content: space-around; padding-top: 8px; border-top: 1px solid var(--line-soft); margin-top: auto; }
.dv-tabs i { width: 15px; height: 15px; border-radius: 4px; background: #1c242d; display: block; }
.dv-tabs i.on { background: var(--lime); }

.device-caption { text-align: center; color: var(--muted-2); font-size: 12px; margin-top: 16px; }

/* ============================================================
   SUPPORTING BLOCKS
   ============================================================ */
.pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.pill { border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; font-size: 13px; color: var(--muted); }

.stat-band { display: grid; gap: 22px; }
@media (min-width: 720px) { .stat-band { grid-template-columns: repeat(3, 1fr); } }
.stat-band .n { font-size: clamp(26px, 4vw, 34px); font-weight: 800; letter-spacing: -.03em; color: var(--text); }
.stat-band p { font-size: 14px; margin: 6px 0 0; }

.note-band { background: var(--bg-2); border-block: 1px solid var(--line-soft); }

/* Skip link -- keyboard users should not have to tab the whole header. */
.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--lime); color: var(--lime-ink); padding: 12px 18px;
  border-radius: 0 0 10px 0; font-weight: 700; text-decoration: none;
}
.skip:focus { left: 0; }

/* ============================================================
   INLINE LINKS IN PROSE
   WCAG 2.5.8 exempts links inline in a sentence from the 44px target
   rule -- you cannot make a mid-paragraph link 44px tall without
   destroying the paragraph. The right answer is to make them
   unmistakable and give them room, not to inflate them.
   ============================================================ */
.body p, .body li { line-height: 1.75; }
.body a, p a:not(.btn):not(.link-cta) {
  color: var(--lime);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  padding: 2px 0;               /* a little vertical room without reflowing */
}
.body a:hover, p a:not(.btn):not(.link-cta):hover { text-decoration-thickness: 2px; }
.foot-legal a { color: var(--muted-2); text-decoration: underline; text-underline-offset: 3px; padding: 4px 0; }
.foot-legal a:hover { color: var(--text); }

/* Legal pages: comfortable reading measure and rhythm. */
.body h2 { font-size: 19px; margin: 30px 0 10px; letter-spacing: -.015em; }
.body { font-size: 15.5px; }
