/* Carvico — one design system for every page on the site.
 *
 * There used to be two: a dark app-marketing sheet for the homepage and guides,
 * and a white reference sheet for the 1,900 car pages. A visitor moving between
 * them saw two different companies. This file replaces both.
 *
 * The base is light because that is what the site mostly is: long-form guides
 * and dense fuel-economy tables, both of which are read, not skimmed. The app
 * pitch gets exactly one dark band (.band) and the App Store badge. If a new
 * section wants its own colour scheme, the answer is no.
 *
 * One accent (--accent, deep forest green) for links and figures. --warm and
 * --crimson are for meaning only: a warning, a bad verdict. Never decoration.
 *
 * The neutrals are warm rather than blue-grey: --tint is a sand, not a pale
 * grey, and the rules are mixed towards it. On a page that is 90% white with
 * hairlines and small type, a cool grey reads as unfinished screen default and
 * a warm one reads as paper. The dark band takes the same treatment from the
 * other end — near-black with green in it, not neutral #0c0d10.
 */

/* ---- tokens ---------------------------------------------------------- */

:root {
  --paper: #ffffff;
  --tint: #f6f4ef;
  --tint-2: #ece8de;
  --ink: #14171a;
  --ink-2: #43474c;
  --ink-3: #767b82;
  --rule: #e5e2db;
  --rule-strong: #c9c5bc;

  --accent: #0e6b3f;
  --accent-deep: #0a5230;
  --accent-line: rgba(14, 107, 63, 0.3);
  --accent-wash: rgba(14, 107, 63, 0.055);

  --warm: #b4531a;
  --crimson: #b4232a;
  --blue: #1f4fb0;

  --dark: #0b1210;
  --dark-2: #121a17;
  --dark-ink: #f4f6f2;
  --dark-ink-2: #a3b0a9;
  --dark-rule: rgba(244, 246, 242, 0.14);
  /* The band's link/hover colour. The ink green is far too dark to sit on
     near-black, so the dark surfaces get their own tint of the same hue. */
  --dark-accent: #6fd79b;

  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---- base ------------------------------------------------------------ */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
::selection { background: var(--accent); color: #fff; }

.wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }
.wrap-data { max-width: 980px; margin: 0 auto; padding: 0 24px; }
.wrap-wide { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* The one recurring typographic device: a small mono label in caps. Used for
   section headings on data pages, stat labels, kickers and breadcrumbs. */
.kicker,
.meta,
.crumbs,
.fig u,
.calc label,
th {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink-3);
}
.section .kicker, .hero .kicker { display: block; margin-bottom: 12px; }

/* ---- chrome: identical on every page --------------------------------- */

header.site {
  border-bottom: 1px solid var(--rule);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  position: sticky;
  top: 0;
  z-index: 20;
}
header.site .wrap-wide {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 58px;
}
.wordmark {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.06rem;
  letter-spacing: -0.02em;
}
.wordmark:hover { text-decoration: none; }
.wordmark span {
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
}
header.site nav { display: flex; gap: 22px; font-size: 0.9rem; }
header.site nav a { color: var(--ink-2); }
header.site nav a:hover { color: var(--accent); text-decoration: none; }
header.site nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }

footer.site {
  border-top: 1px solid var(--rule);
  margin-top: 64px;
  padding: 28px 0 48px;
  font-size: 0.85rem;
  color: var(--ink-3);
}
footer.site .wrap-wide {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  align-items: baseline;
  justify-content: space-between;
}
footer.site a { color: var(--ink-3); }
footer.site nav { display: flex; flex-wrap: wrap; gap: 18px; }

.crumbs { color: var(--ink-3); padding: 20px 0 0; }
.crumbs a { color: var(--ink-3); }
.crumbs a:hover { color: var(--accent); }
.crumbs i,
.crumbs span { font-style: normal; padding: 0 7px; color: var(--rule-strong); }

/* ---- the dark band: app pitch only ----------------------------------- */

.band {
  background: var(--dark);
  color: var(--dark-ink);
  border-block: 1px solid var(--dark-rule);
}
.band h1, .band h2, .band h3, .band strong { color: var(--dark-ink); }
.band p { color: var(--dark-ink-2); }
.band a { color: var(--dark-accent); }
.band .kicker { color: var(--dark-ink-2); }
.band .rule { border-color: var(--dark-rule); }

/* ---- page head ------------------------------------------------------- */

.head { padding: 12px 0 22px; border-bottom: 1px solid var(--rule); }
h1 {
  font-size: clamp(1.75rem, 4vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.028em;
  line-height: 1.12;
}
/* Base headings, so a plain document page (privacy, terms, support) looks
   right without wrapping its prose in anything. */
h2 {
  font-size: clamp(1.3rem, 3vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.022em;
  line-height: 1.22;
  margin: 40px 0 12px;
  scroll-margin-top: 78px;
}
h3 { font-size: 1.08rem; font-weight: 700; letter-spacing: -0.015em; margin: 26px 0 8px; }
main.wrap { padding-top: 40px; padding-bottom: 16px; }
main.wrap > h1:first-child { margin-bottom: 6px; }
main.wrap > h2:first-of-type { margin-top: 34px; }

.head .kicker { color: var(--ink-3); margin-top: 9px; }
.lede, .standfirst {
  color: var(--ink-2);
  margin-top: 14px;
  max-width: 66ch;
  font-size: 1.08rem;
}
.masthead { padding: 20px 0 32px; border-bottom: 1px solid var(--rule); }
.masthead h1 { margin-bottom: 14px; }
.meta {
  color: var(--ink-3);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 18px;
}
.meta span + span::before { content: "·"; color: var(--rule-strong); margin-right: 12px; }

/* ---- car photo: recognition, not decoration -------------------------- */

/* The photo sits between the lede and the figures, where it answers "is this
   the car I meant" before any number has to be read. It is capped rather than
   full-bleed because it is evidence, not a hero — the numbers are the page. */
.carshot { margin: 22px 0 0; }
.carshot img {
  display: block;
  width: 100%;
  max-width: 520px;
  height: auto;
  border-radius: 10px;
  background: var(--tint);
}
.carshot figcaption {
  font-size: 0.72rem;
  color: var(--ink-3);
  margin-top: 8px;
  max-width: 520px;
}
/* The shoot year, set apart because it contradicts the page as often as it
   confirms it: a 2018 photo above a table that starts in 1984. */
.carshot .shot { color: var(--ink-3); white-space: nowrap; }
.carshot .shot::before { content: "·"; color: var(--rule-strong); margin: 0 6px; }

/* Thumbnail in a make's model table. Fixed box so rows stay on their baseline
   whether or not a model has a photo yet. */
.scroll td.model { display: flex; align-items: center; gap: 10px; }
.rowshot {
  flex: none;
  width: 52px;
  height: 34px;
  border-radius: 5px;
  overflow: hidden;
  background: var(--tint);
}
.rowshot img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- stat row: hairlines between figures, never boxes ---------------- */

.figures {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
  border-bottom: 1px solid var(--rule);
}
.fig { padding: 20px 20px 20px 0; border-right: 1px solid var(--rule); }
.fig:last-child { border-right: none; }
.fig b {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.fig b i {
  font-style: normal;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-3);
  letter-spacing: 0;
  margin-left: 3px;
}
.fig u { display: block; text-decoration: none; color: var(--ink-3); margin-top: 10px; }
.fig s { display: block; text-decoration: none; font-size: 0.8rem; color: var(--ink-3); }

/* ---- prose ----------------------------------------------------------- */

p { margin-bottom: 14px; max-width: 72ch; color: var(--ink-2); }
p strong, li strong { color: var(--ink); font-weight: 600; }
code {
  font-family: var(--mono);
  font-size: 0.86em;
  color: var(--ink);
  background: var(--tint);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1px 5px;
}

article { padding-bottom: 24px; }
article h2 {
  font-size: clamp(1.3rem, 3vw, 1.6rem);
  font-weight: 700;
  letter-spacing: -0.022em;
  line-height: 1.2;
  margin: 48px 0 14px;
  padding-top: 22px;
  border-top: 1px solid var(--rule);
  scroll-margin-top: 78px;
  color: var(--ink);
}
article h3 { font-size: 1.1rem; font-weight: 700; margin: 30px 0 10px; letter-spacing: -0.015em; }
article p { margin-bottom: 18px; }
article p.lead { font-size: 1.08rem; color: var(--ink-2); }
article a { border-bottom: 1px solid var(--accent-line); }
article a:hover { text-decoration: none; border-bottom-color: var(--accent); }
article ul, article ol { margin: 0 0 20px 22px; color: var(--ink-2); max-width: 72ch; }
article li { margin-bottom: 8px; }
article hr { border: none; border-top: 1px solid var(--rule); margin: 40px 0; }
article blockquote {
  border-left: 2px solid var(--accent);
  padding: 2px 0 2px 18px;
  margin: 0 0 20px;
  color: var(--ink-2);
}

/* Data pages set body.portal: section headings there are labels, not titles. */
body.portal h2 {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 600;
  margin: 40px 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
  border-top: none;
  padding-top: 0;
}

/* ---- tables ---------------------------------------------------------- */

/* .scroll = dense numeric table (data pages). Right-aligned, tabular figures. */
.scroll { overflow-x: auto; margin-bottom: 10px; }
.scroll table { width: 100%; border-collapse: collapse; font-size: 0.88rem; min-width: 480px; }
.scroll th, .scroll td {
  text-align: right;
  padding: 9px 14px 9px 0;
  border-bottom: 1px solid var(--rule);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.scroll th:first-child, .scroll td:first-child { text-align: left; }
/* A ranked list puts the position in the first column, so the name it belongs
   to is no longer the cell the two rules above are aiming at. */
.scroll th.model, .scroll td.model { text-align: left; }
.scroll th { font-size: 0.65rem; letter-spacing: 0.1em; color: var(--ink-3); border-bottom-color: var(--rule-strong); }
.scroll td { color: var(--ink-2); }
.scroll td:first-child { color: var(--ink); font-weight: 600; }
.scroll tbody tr:hover td { background: var(--tint); }
.index-table td:first-child a, .index-table td.model a { font-weight: 600; }

/* .table-wrap = prose comparison table (guides). Left-aligned, wraps. */
.table-wrap { overflow-x: auto; margin: 0 0 26px; border: 1px solid var(--rule); }
.table-wrap table { width: 100%; border-collapse: collapse; font-size: 0.92rem; min-width: 520px; }
.table-wrap th, .table-wrap td {
  text-align: left;
  padding: 11px 16px;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
.table-wrap tr:last-child td { border-bottom: none; }
.table-wrap th { color: var(--ink-3); background: var(--tint); font-size: 0.66rem; }
.table-wrap td { color: var(--ink-2); }
.table-wrap tbody tr:hover td { background: var(--tint); }

.good { color: var(--accent); font-weight: 700; }
.mid { color: var(--warm); font-weight: 700; }
.bad { color: var(--crimson); font-weight: 700; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.note { font-size: 0.82rem; color: var(--ink-3); margin-bottom: 26px; max-width: 72ch; }

/* ---- components ------------------------------------------------------ */

.toc { border: 1px solid var(--rule); background: var(--tint); padding: 20px 24px; margin: 32px 0; }
.toc h2 {
  font-family: var(--mono);
  font-size: 0.68rem !important;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 12px !important;
  padding: 0 !important;
  border: none !important;
  color: var(--ink-3);
  font-weight: 600;
}
.toc ol { margin: 0 0 0 20px; }
.toc li { margin-bottom: 6px; }
.toc a { color: var(--ink); border-bottom: none; font-size: 0.95rem; }
.toc a:hover { color: var(--accent); }

.callout {
  background: var(--tint);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  padding: 18px 22px;
  margin: 0 0 24px;
}
.callout.warn { border-left-color: var(--crimson); }
.callout.note { border-left-color: var(--blue); }
.callout h3 {
  margin: 0 0 8px;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}
.callout.warn h3 { color: var(--crimson); }
.callout.note h3 { color: var(--blue); }
.callout p:last-child { margin-bottom: 0; }

.formula {
  background: var(--tint);
  border: 1px solid var(--rule);
  padding: 22px 24px;
  margin: 0 0 24px;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.98rem;
  color: var(--ink);
  line-height: 1.9;
}
.formula em { color: var(--accent); font-style: normal; }

.checklist { list-style: none; margin: 0 0 24px !important; display: grid; gap: 0; border-top: 1px solid var(--rule); }
.checklist li {
  border-bottom: 1px solid var(--rule);
  padding: 14px 18px 14px 40px;
  position: relative;
  margin: 0;
}
.checklist li::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 19px;
  width: 13px;
  height: 13px;
  border: 1.5px solid var(--rule-strong);
  border-radius: 2px;
}
.checklist li b { display: block; color: var(--ink); }
.checklist li small { color: var(--ink-3); font-size: 0.9rem; }

.faq details { border-bottom: 1px solid var(--rule); padding: 16px 0; }
.faq details:first-of-type { border-top: 1px solid var(--rule); }
.faq summary { font-weight: 600; cursor: pointer; color: var(--ink); list-style-position: outside; }
.faq summary::marker { color: var(--rule-strong); }
.faq details p { margin: 10px 0 0; color: var(--ink-2); font-size: 0.95rem; }

.sources { font-size: 0.88rem; color: var(--ink-3); }
.sources li { margin-bottom: 7px; }
.sources a { color: var(--ink-3); }

/* cards: a list with rules, not a grid of boxes */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 0 32px; margin-bottom: 26px; border-top: 1px solid var(--rule); }
.card {
  padding: 20px 0;
  border-bottom: 1px solid var(--rule);
  display: block;
  color: var(--ink);
}
.card:hover { text-decoration: none; }
.card:hover h3 { color: var(--accent); }
.card .kicker { color: var(--ink-3); display: block; margin-bottom: 8px; }
.card h3 { font-size: 1.04rem; font-weight: 700; margin: 0 0 6px; letter-spacing: -0.015em; }
.card p { color: var(--ink-3); font-size: 0.92rem; margin: 0; }

/* ---- forms and calculators ------------------------------------------- */

.calc { border-bottom: 1px solid var(--rule); padding-bottom: 20px; margin-bottom: 20px; }
.calc h3 { margin: 0 0 4px; font-size: 1.04rem; }
.calc .hint { color: var(--ink-3); font-size: 0.9rem; margin-bottom: 18px; }
.calc .fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(155px, 1fr)); gap: 14px 20px; }
.calc label { display: block; color: var(--ink-3); }
.calc input, .calc select {
  display: block;
  width: 100%;
  margin-top: 6px;
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  border-radius: 2px;
  padding: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  font-variant-numeric: tabular-nums;
}
.calc select { padding: 7px 4px; }
.calc input:focus, .calc select:focus { border-color: var(--accent); outline: none; }
.calc .out {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
}
.calc .out div span {
  display: block;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.calc .out div b {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
}
.calc .out div b.muted { color: var(--ink); }

/* ---- portal two-column shell ------------------------------------------ */

/* Content left, sidebar right, on every /car page. The sidebar is narrow on
   purpose: it is a way out of the page, not a second page. */
.portal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 264px;
  gap: 0 48px;
  align-items: start;
}
.portal-main { min-width: 0; }
.portal-side { position: sticky; top: 24px; padding-top: 4px; }

.side-box { border: 1px solid var(--rule); margin-bottom: 20px; }
/* Outranks `body.portal h2`, which turns section headings into mono caps
   labels. In the sidebar the heading is the top of a box, not a label over a
   rule, so it takes the sans face back. */
body.portal .side-box h2 {
  margin: 0;
  padding: 11px 14px;
  font-family: var(--sans);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--ink);
  background: var(--tint);
  border-bottom: 1px solid var(--rule);
}
.side-body { padding: 14px; }
.side-body label { display: block; color: var(--ink-3); font-size: 0.8rem; margin-bottom: 10px; }
.side-body select {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 7px 6px;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--rule-strong);
  border-radius: 2px;
}
.side-body select:focus { border-color: var(--accent); outline: none; }
.side-body button { width: 100%; padding: 9px 12px; margin-top: 4px; }
.side-body button.secondary {
  margin-top: 8px;
  background: transparent;
  color: var(--ink);
  border-color: var(--rule-strong);
}
.side-body button.secondary:hover { background: transparent; color: var(--accent); border-color: var(--accent); }
.side-body button:disabled, .side-body button:disabled:hover {
  background: transparent;
  color: var(--ink-3);
  border-color: var(--rule);
  cursor: default;
}
.side-note { font-size: 0.78rem; color: var(--ink-3); margin: 12px 0 0; }
.side-links { list-style: none; margin: 0; padding: 0; }
.side-links li { padding: 7px 0; border-bottom: 1px solid var(--rule); font-size: 0.9rem; }
.side-links li:last-child { border-bottom: 0; padding-bottom: 0; }
.side-links li:first-child { padding-top: 0; }

/* Below this the sidebar cannot be a column without squeezing the tables, so it
   becomes a footer block instead — same boxes, side by side while they fit. */
@media (max-width: 900px) {
  .portal-layout { display: block; }
  .portal-side { position: static; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin-top: 40px; }
  .side-box { margin-bottom: 0; }
}

/* 1-5 star control on the contribute form. The row is reversed so the DOM can
   run 5 down to 1, which is what lets a checked radio reach its lower-valued
   siblings with ~ and fill every star to its left. No script anywhere in it. */
.stars-input {
  border: 1px solid var(--rule);
  padding: 14px 16px;
  margin: 0 0 20px;
  background: var(--tint);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 16px;
}
.stars-legend { color: var(--ink-2); font-size: 0.9rem; }
.stars-input .hint {
  margin: 0;
  flex-basis: 100%;
  font-size: 0.78rem;
  color: var(--ink-3);
}
.stars-row { display: inline-flex; flex-direction: row-reverse; justify-content: flex-end; }
.stars-row input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.stars-row label {
  cursor: pointer;
  font-size: 1.6rem;
  line-height: 1;
  padding: 2px 3px;
  color: var(--rule-strong);
}
/* The word is for a screen reader; the star is drawn here so the glyph never
   has to survive a copy-paste through the build. */
.stars-row label span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.stars-row label::before { content: '★'; }
.stars-row input:checked ~ label,
.stars-row label:hover,
.stars-row label:hover ~ label { color: var(--warm); }
.stars-row input:focus-visible + label { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Published owner ratings. Only ever rendered for a car that has enough of
   them — see scripts/lib/ratings.mjs. */
.rating { display: flex; gap: 34px; flex-wrap: wrap; align-items: flex-start; margin-bottom: 14px; }
.score-big b {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.038em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.score-big span { color: var(--ink-3); font-size: 0.9rem; margin-left: 6px; }
.score-big .glyphs { color: var(--warm); font-size: 1.15rem; margin-top: 6px; letter-spacing: 0.06em; }
.score-big .n { color: var(--ink-3); font-size: 0.82rem; margin-top: 4px; }
.rating .spread { list-style: none; margin: 0; padding: 0; min-width: 240px; flex: 1; max-width: 380px; }
.rating .spread li { display: flex; align-items: center; gap: 10px; padding: 2px 0; }
.rating .spread .score { color: var(--ink-3); font-size: 0.8rem; width: 26px; }
.rating .spread .bar { flex: 1; height: 6px; background: var(--tint-2); border-radius: 3px; overflow: hidden; }
.rating .spread .bar i { display: block; height: 100%; background: var(--warm); }
.rating .spread .n {
  color: var(--ink-3);
  font-size: 0.8rem;
  width: 22px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.answer { padding: 4px 0 24px; }
.answer .big { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.answer .big b {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.038em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  color: var(--accent);
}
.answer .big span {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.answer p { margin: 14px 0 0; }

button, .btn {
  display: inline-block;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
  border-radius: 2px;
  padding: 10px 22px;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
}
button:hover, .btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; text-decoration: none; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn.ghost:hover { background: transparent; color: var(--accent); border-color: var(--accent); }
.band .btn.ghost { color: var(--dark-ink); border-color: var(--dark-rule); }
.band .btn.ghost:hover { color: var(--dark-accent); border-color: var(--dark-accent); }
.form-note { font-size: 0.82rem; color: var(--ink-3); margin: 11px 0 0; }

/* ---- app pitch: the one dark thing ----------------------------------- */

.cta {
  background: var(--dark);
  color: var(--dark-ink);
  padding: 32px;
  margin: 44px 0 0;
}
.cta h2 {
  margin: 0 0 12px !important;
  padding: 0 !important;
  border: none !important;
  font-size: 1.3rem !important;
  color: var(--dark-ink);
  font-weight: 700;
}
.cta p { color: var(--dark-ink-2); max-width: 58ch; margin: 0 0 22px; }

/* Dark pill on white; inverts inside the dark band and the .cta block. */
.appstore-badge {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  background: var(--ink);
  color: #fff;
  border: 1px solid var(--ink);
  padding: 10px 20px;
  text-decoration: none;
}
.appstore-badge:hover { text-decoration: none; opacity: 0.88; }
.appstore-badge .badge-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  font-weight: 700;
  font-size: 1.02rem;
  text-align: left;
}
.appstore-badge .badge-text small { font-size: 0.64rem; font-weight: 500; letter-spacing: 0.04em; color: #c9cbd0; }
.band .appstore-badge, .cta .appstore-badge { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.band .appstore-badge .badge-text small, .cta .appstore-badge .badge-text small { color: var(--ink-3); }

.dl {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--rule-strong);
  padding: 12px 18px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  margin: 0 10px 12px 0;
}
.dl:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.dl small { display: block; font-weight: 400; color: var(--ink-3); font-size: 0.78rem; }

/* ---- homepage -------------------------------------------------------- */

/* The hero was one column in a 1120px band: a 56ch paragraph on the left and
   half the width empty on the right, with the phone strip underneath. It is a
   two-column grid from 960px up — copy left, the screenshots as a 2×2 block
   right — so the pitch and the proof of it are on screen together and the band
   is not mostly background. Below 960 it stacks back to what it was. */
.hero { padding: 72px 0 80px; }
.hero h1 { font-size: clamp(2.1rem, 5.4vw, 3.1rem); max-width: 15ch; }
.hero p { font-size: 1.13rem; max-width: 52ch; margin: 20px 0 28px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 14px 20px; align-items: center; }

@media (min-width: 960px) {
  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
    gap: 0 56px;
    align-items: center;
  }
}

/* Second path out of the hero. Half this site is the car database and the
   hero used to offer no way into it at all. */
.hero-link {
  font-weight: 600;
  font-size: 0.94rem;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.hero-link::after { content: "→"; transition: transform 0.15s ease; }
.hero-link:hover { text-decoration: none; }
.hero-link:hover::after { transform: translateX(3px); }

/* The four claims that decide whether the download is worth a tap, in the one
   place a visitor is still reading. Mono caps, so it reads as a spec line
   rather than marketing. */
.proof {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 30px;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dark-ink-2);
}
.proof span { display: inline-flex; align-items: center; gap: 8px; }
.proof span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--dark-accent);
  flex: none;
}

.section { padding: 56px 0; border-bottom: 1px solid var(--rule); }
/* Alternating ground. Seven sections of identical white separated by hairlines
   read as one undifferentiated page; the sand tells you a new subject started
   without adding a second colour to the site. */
.section.tinted { background: var(--tint); border-bottom-color: var(--tint-2); }
.section.tinted + .section { border-top: 0; }
.section h2 {
  font-size: clamp(1.5rem, 3.4vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.026em;
  margin-bottom: 12px;
}
.section > p { font-size: 1.05rem; max-width: 62ch; }
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.more { font-size: 0.9rem; white-space: nowrap; font-weight: 600; }
.more:hover { text-decoration: none; color: var(--accent-deep); }

/* a plain list of links with rules — the workhorse of the homepage */
.rows { border-top: 1px solid var(--rule); margin-top: 24px; }
/* Was flex + space-between, which pinned the title to the left edge and its
   description to the right one: at 1120px that is 400px of gap between a thing
   and the sentence explaining it, and the eye does not make the trip. Two
   columns, both left-aligned, so the pair reads as a pair. The row is also the
   click target, so it gets a hover ground and the padding sits inside a
   negative margin — the rules stay flush with the rest of the page. */
.row {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  align-items: baseline;
  gap: 4px 32px;
  padding: 16px 14px;
  margin: 0 -14px;
  border-bottom: 1px solid var(--rule);
  color: var(--ink);
  transition: background 0.12s ease;
}
.row:hover { text-decoration: none; background: var(--accent-wash); }
.row:hover b { color: var(--accent); }
.row b { font-weight: 600; font-size: 1rem; letter-spacing: -0.01em; }
.row i { font-style: normal; color: var(--ink-3); font-size: 0.9rem; }
@media (max-width: 720px) {
  .row { grid-template-columns: 1fr; gap: 3px; }
}
.row s {
  text-decoration: none;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}

/* Make chips. These were a four-column grid of bare underlined text, which is
   what a table of contents looks like, not sixteen separate destinations —
   nothing about them said "tap me". Now they are actual chips. */
.chips { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 24px; }
.chips a {
  display: inline-flex;
  align-items: center;
  padding: 8px 15px;
  border: 1px solid var(--rule-strong);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-2);
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}
.chips a:hover {
  color: var(--accent);
  border-color: var(--accent-line);
  background: var(--accent-wash);
  text-decoration: none;
}

.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 40px; margin-top: 28px; }
/* Each feature gets its own rule rather than sharing one long hairline across
   the row, and an accent tick on top of it — the same mark the page heads use.
   Six paragraphs then read as six items. */
.feat { padding: 24px 0; border-top: 1px solid var(--rule); position: relative; }
.feat::before {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  width: 34px;
  height: 3px;
  background: var(--accent);
}
.feat h3 { font-size: 1rem; font-weight: 700; margin: 0 0 6px; letter-spacing: -0.015em; }
.feat p { font-size: 0.93rem; color: var(--ink-3); margin: 0; }

/* A single phone screenshot inside a guide. The article column is ~65ch and
   these shots are 640x1390, so unconstrained they render as a tower taller than
   the section they illustrate. Capped at phone size, floated out of the reading
   flow on wide screens, stacked on narrow ones. */
.guideshot { margin: 28px 0; max-width: 260px; }
.guideshot img { border: 1px solid var(--rule); display: block; width: 100%; height: auto; }
.guideshot figcaption { font-size: 0.85rem; color: var(--ink-3); margin-top: 8px; line-height: 1.45; }
@media (min-width: 900px) {
  .guideshot { float: right; margin: 6px 0 20px 32px; max-width: 220px; }
}

.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-top: 28px; }
.shots img { border: 1px solid var(--rule); display: block; width: 100%; }
.band .shots img { border-color: var(--dark-rule); }
/* Four phone screenshots at full container width would be 600px tall each and
   push the whole site below the fold. Keep the strip to phone size — a row
   under the copy on narrow screens, a 2×2 block beside it on wide ones. */
.hero .shots { grid-template-columns: repeat(4, 1fr); max-width: 760px; gap: 16px; margin-top: 44px; }
/* A 640×1390 phone shot is 2.2 times as tall as it is wide, so a 2×2 block of
   them at any readable width is a 900px hero. Each tile is cropped to the top
   of its screen instead — the part that carries the caption and the content —
   which keeps four screens in the band and the band under one viewport. */
.hero .shots img {
  aspect-ratio: 640 / 840;
  object-fit: cover;
  object-position: top center;
}
@media (min-width: 960px) {
  .hero .shots {
    grid-template-columns: repeat(2, 1fr);
    max-width: 430px;
    gap: 18px;
    margin-top: 0;
    margin-left: auto;
  }
}

/* Two plans, two cards. As flush-left text blocks under a shared rule these
   read as more prose; Pro is what a reader is deciding about, so it is the one
   with the accent border and the ground. */
.price-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; margin-top: 28px; }
.price { padding: 24px; border: 1px solid var(--rule); background: var(--paper); border-radius: 3px; }
/* Both cards stay white — the section ground behind them is sand, and a wash
   card on a sand section is just a muddier sand. Pro is marked by its border
   and its accent tick instead. */
.price.pro { border-color: var(--accent-line); box-shadow: inset 0 3px 0 var(--accent); }
.price b { display: block; font-size: 1.7rem; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.price.pro b { color: var(--accent); }
.price u { display: block; text-decoration: none; font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); margin-top: 8px; }
.price p { font-size: 0.92rem; color: var(--ink-3); margin: 10px 0 0; }
/* What each plan actually gives you, one line each — the paragraph version of
   this made a reader diff two blocks of prose to find the difference. */
.price ul { list-style: none; margin: 14px 0 0; padding: 0; }
.price li { font-size: 0.92rem; color: var(--ink-2); padding: 5px 0 5px 22px; position: relative; }
.price li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.85rem;
}

.leadform { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; max-width: 520px; }
.leadform input {
  flex: 1 1 240px;
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--rule-strong);
  border-radius: 2px;
  padding: 11px 12px;
  font-size: 0.98rem;
  font-family: inherit;
}
.leadform input:focus { border-color: var(--accent); outline: none; }
.band .leadform input { background: var(--dark-2); color: var(--dark-ink); border-color: var(--dark-rule); }
.band button { background: var(--dark-ink); color: var(--dark); border-color: var(--dark-ink); }
.band button:hover { background: var(--dark-accent); border-color: var(--dark-accent); color: var(--dark); }
.status { font-size: 0.88rem; margin-top: 10px; }

/* ---- standalone pages: switch, privacy, terms, support, press -------- */

/* Aliases kept so the hand-written pages did not all need rewriting. */
.lead, .sub { font-size: 1.08rem; color: var(--ink-2); max-width: 66ch; }
.band .lead, .band .sub { color: var(--dark-ink-2); }

/* The switch pages separate their sections with a bare <section>. */
main > section:not(.section):not(.band):not(.final-cta) {
  padding: 48px 0;
  border-bottom: 1px solid var(--rule);
}
main > section > .wrap > h2:first-child { margin-top: 0; }

.hero-page { padding: 56px 0 44px; border-bottom: 1px solid var(--rule); }
.hero-page h1 { margin-bottom: 16px; }
.hero-page .appstore-badge { margin-top: 26px; }

/* Was a decorative chequered flag. Now a single accent rule — it marks the
   start of a page without pretending to be a race. */
.flag-strip { width: 44px; height: 3px; background: var(--accent); margin: 0 0 22px; }
.band .flag-strip { background: var(--dark-accent); }

.hud-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 22px;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.hud-row span + span::before { content: "·"; color: var(--rule-strong); margin-right: 12px; }
.band .hud-row { color: var(--dark-ink-2); }

.steps { counter-reset: step; border-top: 1px solid var(--rule); margin: 24px 0; max-width: 720px; }
.step { border-bottom: 1px solid var(--rule); padding: 22px 0 22px 46px; position: relative; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 22px;
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
}
.step h3 { font-size: 1.02rem; font-weight: 700; margin-bottom: 6px; letter-spacing: -0.015em; }
.step p { color: var(--ink-2); font-size: 0.95rem; margin: 0; }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 40px; border-top: 1px solid var(--rule); margin-top: 24px; }
.grid .card { padding: 22px 0; border-bottom: 1px solid var(--rule); }
.grid .card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 6px; }
.grid .card p { font-size: 0.93rem; color: var(--ink-3); margin: 0; }

.final-cta { background: var(--dark); color: var(--dark-ink); padding: 56px 0; margin-top: 56px; }
.final-cta h2 { color: var(--dark-ink); font-size: 1.6rem; font-weight: 700; letter-spacing: -0.026em; margin-bottom: 10px; }
.final-cta p, .final-cta .lead { color: var(--dark-ink-2); }
.final-cta .flag-strip { background: var(--dark-accent); }
.final-cta .appstore-badge { background: var(--paper); color: var(--ink); border-color: var(--paper); margin-top: 22px; }
.final-cta .appstore-badge .badge-text small { color: var(--ink-3); }
.cta-note { display: block; font-size: 0.85rem; color: var(--ink-3); margin-top: 14px; }
/* The closing band already is the bottom of the page: the footer's own top
   margin, and the last section's padding above it, would sit it in the middle
   of two white gaps. */
.section + .final-cta { margin-top: 0; }
main:has(> .final-cta:last-child) + footer.site { margin-top: 0; border-top: 0; }
.final-cta .cta-note, .band .cta-note { color: var(--dark-ink-2); }

.updated {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 10px 0 28px;
}

.contact-card { border: 1px solid var(--rule); background: var(--tint); padding: 24px; margin: 20px 0 8px; }
.contact-card p { margin-bottom: 6px; }
.contact-card .note { font-size: 0.9rem; margin: 8px 0 0; }

.factsheet td:first-child { color: var(--ink); font-weight: 600; white-space: nowrap; }
.shots span {
  display: block;
  padding: 8px 0;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-3);
}
body:not(.band-page) .shots img { border-color: var(--rule); }

/* Related cars — two columns of plain rows, so a long list of neighbouring
   models reads as a reference list rather than as navigation furniture. */
.related {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 28px;
  margin: 4px 0 18px;
}
.related li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--rule);
}
.related span {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}

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

@media (max-width: 700px) {
  .related { grid-template-columns: 1fr; }
  header.site .wrap-wide { height: auto; padding-block: 12px; flex-wrap: wrap; gap: 8px 16px; }
  header.site nav { gap: 16px; font-size: 0.85rem; }
  .hero { padding: 48px 0 56px; }
  .section { padding: 42px 0; }
  article h2 { margin-top: 38px; }
  .cta { padding: 24px 20px; }
  .chips a { width: 50%; }
  .hero .shots { grid-template-columns: repeat(2, 1fr); }
  .figures { grid-template-columns: 1fr 1fr; }
  .fig { padding: 14px 0; }
  .fig:nth-child(odd) { border-right: 1px solid var(--rule); padding-right: 16px; }
  .fig:nth-child(even) { border-right: none; }
  .row { flex-direction: column; gap: 4px; }
  .row i { text-align: left; }
}

@media print {
  header.site, footer.site, .cta, .toc, .crumbs, .band { display: none; }
  body { background: #fff; color: #000; }
  a { color: #000; }
}
