/* CARIVANE — main stylesheet. Tokens and rules follow docs/WEBSITE-SPEC.md §5.
   Composition follows the approved Option A wireframe (docs/VISUAL-REFINEMENT.md). */

/* ---------- Fonts (self-hosted, Latin subset, SIL OFL — see assets/fonts/OFL-Geist.txt) ---------- */
@font-face {
  font-family: "Geist";
  src: url("../fonts/geist-latin.v1.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("../fonts/geistmono-latin.v1.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  color-scheme: light;

  --bg: #f7f5f2;
  --bg-2: #efebe5;
  --surface: #ffffff;
  --ink: #141414;
  --ink-2: #3d3a36;       /* supporting paragraphs: 10.39:1 on bg, 9.52:1 on bg-2 */
  --muted: #5c5852;       /* labels, meta, footer */
  --line: #e2ded8;
  --line-strong: #8a847c;
  --accent: #6b2d3f;
  --accent-hover: #55222f;

  /* Dark band (closing CTA) */
  --dark: #1a1816;
  --on-dark: #f7f5f2;        /* 16.27:1 */
  --on-dark-muted: #b3ada4;  /* 7.95:1 */
  --accent-on-dark: #d7a6b3; /* 8.43:1 */
  --line-on-dark: #3a3631;   /* decorative only */

  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --fs-display: clamp(2.75rem, 6vw, 5rem);
  --fs-h2: clamp(1.875rem, 3.2vw, 2.75rem);
  --fs-h3: 1.1875rem;
  --fs-body: clamp(1.0625rem, 0.6vw + 0.9rem, 1.1875rem);
  --fs-lead: clamp(1.125rem, 1.3vw, 1.25rem);
  --fs-small: 0.9375rem;
  --fs-label: 0.8125rem;

  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;

  --gutter: 20px;
  --container: 1200px;
  --measure: 60ch;
  --section-pad: clamp(4rem, 9vw, 7.5rem);
  --radius: 12px;
}

@media (min-width: 768px) {
  :root { --gutter: 32px; }
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.1;
  text-wrap: balance;
}

h1 {
  font-size: var(--fs-display);
  letter-spacing: -0.035em;
  line-height: 1.02;
}

h2 {
  font-size: var(--fs-h2);
  letter-spacing: -0.025em;
}

h3 {
  font-size: var(--fs-h3);
  letter-spacing: -0.01em;
  line-height: 1.3;
}

p, li, dd { text-wrap: pretty; }

img, svg { display: block; }

a {
  color: var(--accent);
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color 150ms ease-out, text-decoration-thickness 150ms ease-out;
}
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

::selection { background: var(--accent); color: #fff; }

/* Skip-link target receives programmatic focus only. */
main:focus { outline: none; }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Unresolved business inputs. Must not exist at launch (spec §10.4). */
.todo {
  background: #fff3c4;
  color: #4a3b00;
  outline: 1px dashed #8a6d00;
  padding: 0 0.25em;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  line-height: 1.6;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 30;
  padding: var(--s-3) var(--s-4);
  background: var(--ink);
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
}
.skip-link:focus { top: var(--s-3); }

.section { padding-block: var(--section-pad); }

/* Background rhythm: bg → bg-2 → bg → bg-2 → bg → dark. */
.band-alt { background: var(--bg-2); }

.band-dark {
  background: var(--dark);
  color: var(--on-dark);
}
.band-dark :focus-visible { outline-color: var(--on-dark); }

/* Split section header: number left, heading right on wide screens. */
.section-head {
  display: grid;
  gap: var(--s-3);
  margin-bottom: clamp(2.25rem, 5vw, 3.5rem);
}

.section-num {
  font-size: clamp(2.25rem, 4vw, 3.25rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--line-strong);
}

.section-label {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: var(--s-3);
}

.section-intro {
  max-width: var(--measure);
  margin-top: var(--s-4);
  font-size: var(--fs-lead);
  line-height: 1.55;
  color: var(--ink-2);
}

@media (min-width: 1024px) {
  .section-head {
    grid-template-columns: 2fr 10fr;
    column-gap: var(--s-6);
    align-items: start;
  }
}

.prose > * { max-width: var(--measure); }
.prose > * + * { margin-top: var(--s-4); }
.prose p { color: var(--ink-2); line-height: 1.6; }
.prose h2 { margin-top: var(--s-7); }
.prose h2:first-child { margin-top: 0; }
.prose--legal h2 { font-size: clamp(1.375rem, 2.2vw, 1.75rem); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  min-height: 48px;
  padding: 0 1.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out, transform 150ms ease-out;
}
.btn:active { transform: translateY(1px); }

.btn__arrow { transition: transform 150ms ease-out; }
.btn:hover .btn__arrow--right { transform: translateX(3px); }
.btn:hover .btn__arrow--down { transform: translateY(2px); }

.btn--primary {
  background: var(--accent);
  color: #fff;
}
.btn--primary:hover { background: var(--accent-hover); }

.btn--secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--secondary:hover { border-color: var(--ink); }

/* Primary action on the dark band: plum on dark is only 1.75:1, so the fill inverts (spec D21). */
.btn--on-dark {
  background: var(--on-dark);
  color: var(--dark);
}
.btn--on-dark:hover { background: #e6e1da; }

.btn--compact {
  min-height: 44px;
  padding: 0 1.25rem;
  font-size: 0.9375rem;
}

.btn--block { width: 100%; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}

/* ---------- Header ---------- */
.site-header { border-bottom: 1px solid var(--line); }

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  min-height: 72px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--ink);
  font-weight: 600;
  font-size: 1.0625rem;
  letter-spacing: 0.14em;
  text-decoration: none;
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: var(--s-4);
}

.site-nav ul {
  display: flex;
  gap: var(--s-2);
  list-style: none;
  padding: 0;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 var(--s-3);
  color: var(--ink);
  font-size: var(--fs-small);
  text-decoration: none;
}
.site-nav a:hover {
  text-decoration: underline;
  text-underline-offset: 0.3em;
}

/* Mobile menu: native <details> disclosure — keyboard and screen-reader accessible without JavaScript. */
.menu { position: relative; }

.menu summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.menu summary::-webkit-details-marker { display: none; }
.menu summary:hover { background: var(--bg-2); }

.menu .icon-close { display: none; }
.menu[open] .icon-open { display: none; }
.menu[open] .icon-close { display: block; }

.menu__panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  z-index: 20;
  width: min(280px, calc(100vw - 2 * var(--gutter)));
  padding: var(--s-3);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgb(20 20 20 / 0.10);
}

.menu__panel ul {
  list-style: none;
  padding: 0;
  margin-bottom: var(--s-3);
}

.menu__panel li + li { border-top: 1px solid var(--line); }

.menu__panel ul a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 var(--s-3);
  color: var(--ink);
  text-decoration: none;
}

.site-nav,
.site-header__cta { display: none; }

@media (min-width: 768px) {
  .site-nav,
  .site-header__cta { display: inline-flex; }
  .menu { display: none; }
}

/* ---------- Hero ---------- */
.hero { padding-block: clamp(2.5rem, 7vw, 5.5rem) 0; }

/* ---------- Brand lockup ---------- */
/* CARIVANE │ Digital systems, built to work. — text-based (no logo asset exists). Identical in header and footer.
   The wordmark (home link) dominates; the tagline is secondary. */
.lockup {
  display: flex;
  align-items: center;
  column-gap: 0.75rem;
  min-width: 0;
}

.lockup__tag {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.8125rem;
  letter-spacing: 0;
  white-space: nowrap;
}

.lockup__tag::before {
  content: "";
  width: 1px;
  height: 1.3em;
  background: var(--line-strong);
}

/* Header shows the tagline only where it has real room; otherwise the wordmark alone
   (on phones the hero headline directly below carries the same line). */
@media (max-width: 439.98px), (min-width: 768px) and (max-width: 899.98px) {
  .site-header .lockup__tag { display: none; }
}

/* Footer: on very narrow screens the lockup wraps instead of overflowing. */
@media (max-width: 379.98px) {
  .site-footer .lockup { flex-wrap: wrap; row-gap: var(--s-1); }
  .site-footer .lockup__tag { white-space: normal; }
  .site-footer .lockup__tag::before { display: none; }
}

@media (min-width: 1024px) {
  .lockup { column-gap: 1rem; }
  .lockup__tag { gap: 1rem; font-size: 0.875rem; }
}

.site-header__cta { white-space: nowrap; }

/* 768–1023px: lockup, nav and CTA share one row, so tighten the nav padding. */
@media (min-width: 768px) and (max-width: 1023.98px) {
  .site-nav a { padding: 0 0.5rem; }
  .site-header__actions { gap: var(--s-3); }
}

.hero h1 { max-width: 14ch; }
.hero h1 .accent { color: var(--accent); }

.hero .lede {
  max-width: 52ch;
  margin-top: var(--s-5);
  font-size: var(--fs-lead);
  line-height: 1.55;
  color: var(--ink-2);
}

.hero .btn-row { margin-top: var(--s-6); }

/* Hero system diagram: decorative, desktop only (≥1024px). Inline SVG — no request, no JS. */
.hero__visual { display: none; }

.sys-dot { fill: var(--line); }
.sys-mark { fill: none; stroke: var(--line-strong); stroke-width: 1; }
.sys-line { fill: none; stroke: var(--line-strong); stroke-width: 1; }
.sys-detail { fill: none; stroke: var(--line); stroke-width: 1.5; stroke-linecap: round; }
.sys-box { fill: var(--surface); stroke: var(--line-strong); stroke-width: 1; }
.sys-box--accent { stroke: var(--accent); stroke-width: 1.5; }
.sys-cell { fill: var(--line-strong); }
.sys-node { fill: var(--bg); stroke: var(--line-strong); stroke-width: 1; }
.sys-accent { fill: none; stroke: var(--accent); stroke-width: 1.5; }
.sys-accent-node { fill: var(--accent); }

@media (min-width: 1024px) {
  .hero__grid {
    display: grid;
    grid-template-columns: 7fr 5fr;
    column-gap: var(--s-7);
    align-items: center;
  }
  .hero__visual { display: block; }
  .hero__visual svg { width: 100%; height: auto; max-width: 520px; margin-left: auto; }
}

/* Spec strip: three approved facts, separated by thin rules. */
.hero-strip {
  display: grid;
  padding: 0;
  list-style: none;
  margin-top: clamp(2.5rem, 6vw, 4rem);
  border-top: 1px solid var(--line);
}

.hero-strip > li {
  display: grid;
  align-content: start;
  grid-template-columns: 28px 1fr;
  column-gap: var(--s-4);
  padding: var(--s-5) 0;
}
.hero-strip > li + li { border-top: 1px solid var(--line); }

.hero-strip svg {
  grid-row: span 2;
  width: 28px;
  height: 28px;
  color: var(--accent);
}

.hero-strip__label {
  font-size: var(--fs-label);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hero-strip__value {
  margin-top: var(--s-1);
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: 1.5;
}

@media (min-width: 768px) {
  .hero-strip { grid-template-columns: repeat(3, 1fr); }
  .hero-strip > li { padding: var(--s-6) var(--s-5); }
  .hero-strip > li:first-child { padding-left: 0; }
  .hero-strip > li + li { border-top: 0; border-left: 1px solid var(--line); }
}

/* ---------- Offer ---------- */
.offer {
  padding: clamp(1.5rem, 4.5vw, 3rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.offer__head {
  display: grid;
  gap: var(--s-5);
  padding-bottom: var(--s-6);
  border-bottom: 1px solid var(--line);
}

.offer__head p {
  max-width: var(--measure);
  color: var(--ink-2);
  line-height: 1.6;
}
.offer__head p + p { margin-top: var(--s-3); }

@media (min-width: 1024px) {
  .offer__head { grid-template-columns: 1fr auto; column-gap: var(--s-8); align-items: start; }
}

.offer__body {
  display: grid;
  gap: var(--s-6);
  margin-top: var(--s-6);
}

.offer h3 {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: var(--s-3);
}

.ticks {
  list-style: none;
  padding: 0;
}

.ticks li {
  position: relative;
  padding: var(--s-2) 0 var(--s-2) 1.5rem;
  break-inside: avoid;
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 0.125rem;
  top: 1.05em;
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: 50%;
  background: var(--accent);
}

@media (min-width: 768px) {
  .ticks--cols { columns: 2; column-gap: var(--s-7); }
}

/* "Scoped separately": a quieter, secondary panel. */
.scoped {
  padding: var(--s-5);
  background: var(--bg);
  border-radius: 8px;
}

.scoped ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-6);
  list-style: none;
  padding: 0;
  color: var(--ink-2);
  font-size: var(--fs-small);
}

.scoped li::before {
  content: "—";
  margin-right: var(--s-2);
  color: var(--line-strong);
}

.offer__footer {
  display: grid;
  gap: var(--s-5);
  margin-top: var(--s-6);
}

@media (min-width: 768px) {
  .offer__footer { grid-template-columns: 1fr auto; column-gap: var(--s-6); align-items: center; justify-items: start; }
}

/* ---------- What we fix ---------- */
.problems {
  display: grid;
  padding: 0;
  list-style: none;
  counter-reset: problem;
  border-bottom: 1px solid var(--line);
}

/* Mobile: numbered rows. */
.problem {
  counter-increment: problem;
  display: grid;
  grid-template-columns: 2.25rem 1fr;
  padding: var(--s-5) 0;
  border-top: 1px solid var(--line);
}

.problem::before {
  content: counter(problem, decimal-leading-zero);
  grid-row: span 2;
  padding-top: 0.2em;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--accent);
}

.problem h3 { font-size: 1.125rem; }

.problem p {
  max-width: 46ch;
  margin-top: var(--s-1);
  color: var(--ink-2);
  font-size: 1rem;
  line-height: 1.6;
}

/* Wider: two columns, number above the title. */
@media (min-width: 768px) {
  .problems {
    grid-template-columns: repeat(2, 1fr);
    column-gap: var(--s-8);
  }
  .problems { border-bottom: 1px solid var(--line); }
  .problem {
    display: block;
    padding: var(--s-6) 0 var(--s-7);
  }
  .problem h3 { font-size: 1.25rem; }
  .problem p { max-width: none; font-size: 1.0625rem; margin-top: var(--s-2); }
  #problems { padding-bottom: clamp(4rem, 7vw, 6rem); }
  .problem::before {
    display: block;
    margin-bottom: var(--s-2);
  }
}

/* ---------- Process ---------- */
.steps {
  display: grid;
  gap: var(--s-2);
  padding: 0;
  list-style: none;
  counter-reset: step;
}

/* Mobile: a clean vertical sequence of compact rows. */
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 2.25rem 1fr;
  padding: var(--s-4) var(--s-5);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
}

.steps li::before {
  content: counter(step, decimal-leading-zero);
  grid-row: span 2;
  padding-top: 0.2em;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--accent);
}

.steps h3 { font-size: 1.125rem; }
.steps p { margin-top: var(--s-1); color: var(--ink-2); font-size: 1rem; line-height: 1.6; }

@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(2, 1fr); gap: var(--s-4); }
  .steps li {
    display: block;
    padding: var(--s-5);
    border-radius: var(--radius);
  }
  .steps li::before {
    display: block;
    margin-bottom: var(--s-3);
  }
}
@media (min-width: 1024px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- About ---------- */
.about {
  display: grid;
  gap: var(--s-6);
}

.about__inner {
  display: grid;
  gap: var(--s-6);
}

.about__text p {
  max-width: var(--measure);
  color: var(--ink-2);
  line-height: 1.6;
}
.about__text p + p { margin-top: var(--s-4); }

/* Lead paragraph gives the main column presence; the card stays secondary. */
.about__text .about__lead {
  color: var(--ink);
  font-size: clamp(1.1875rem, 1.75vw, 1.5rem);
  line-height: 1.45;
  letter-spacing: -0.01em;
}
.about__text .about__lead + p { margin-top: var(--s-5); }

.person {
  padding: var(--s-6);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  align-self: start;
}

.person > * + * { margin-top: var(--s-3); }

.person__role {
  color: var(--muted);
  font-size: var(--fs-small);
}

.person p:not(.person__role) { color: var(--ink-2); line-height: 1.6; font-size: 1rem; }

.person .btn { margin-top: var(--s-5); }

@media (min-width: 1024px) {
  .about { grid-template-columns: 2fr 10fr; column-gap: var(--s-6); }
  .about__inner { grid-column: 2; grid-template-columns: 7fr 5fr; gap: var(--s-7); }
}

/* ---------- Closing CTA (dark band) ---------- */
.cta-final { padding-block: clamp(3.5rem, 7vw, 5.5rem); }

.cta-final__grid {
  display: grid;
  gap: var(--s-3);
}

.cta-final .section-num { color: var(--on-dark-muted); }
.cta-final .section-label { color: var(--on-dark-muted); }

.cta-final__inner {
  display: grid;
  gap: var(--s-6);
}

.cta-final__text > * + * { margin-top: var(--s-4); }
.cta-final__text h2 { margin-top: 0; font-size: clamp(1.875rem, 2.8vw, 2.5rem); }
.cta-final p { color: var(--on-dark); line-height: 1.6; max-width: 52ch; }

.cta-final__action > * + * { margin-top: var(--s-5); }

.cta-final .ticks li { color: var(--on-dark); }
.cta-final .ticks li::before { background: var(--accent-on-dark); }

.cta-final .cta-final__alt,
.cta-final__alt a { color: var(--on-dark-muted); font-size: var(--fs-small); }
.cta-final__alt a:hover { color: var(--on-dark); }

@media (min-width: 1024px) {
  .cta-final__grid { grid-template-columns: 2fr 10fr; column-gap: var(--s-6); }
  .cta-final__inner { grid-template-columns: 7fr 4fr; column-gap: var(--s-8); align-items: center; }
}

/* ---------- Page head (privacy) ---------- */
.page-head { padding-block: clamp(2.5rem, 8vw, 6rem) var(--s-7); }

.page-head .lede {
  max-width: 52ch;
  margin-top: var(--s-5);
  color: var(--ink-2);
}

/* ---------- Store review form (/review/) ---------- */
.review { padding-bottom: var(--section-pad); }

.form {
  display: grid;
  gap: var(--s-5);
  max-width: 36rem;
}

.field { display: grid; gap: var(--s-2); }

.field label { font-weight: 500; }

.field__hint {
  font-size: var(--fs-small);
  color: var(--muted);
}

.field input,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 1rem; /* 16px keeps iOS from zooming on focus */
  line-height: 1.4;
}
.field textarea { min-height: 8rem; resize: vertical; }
.field input:focus-visible,
.field textarea:focus-visible { outline-offset: 1px; border-color: var(--accent); }

/* Spam trap: hidden from people and assistive tech, still submitted by naive bots. */
.form__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.form__note {
  font-size: var(--fs-small);
  color: var(--muted);
  line-height: 1.5;
}

@media (min-width: 480px) {
  .form .btn--primary { justify-self: start; }
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: var(--s-6);
  font-size: var(--fs-small);
}

.site-footer__row {
  display: grid;
  gap: var(--s-4);
}

/* Footer brand uses the shared .lockup. */

.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  column-gap: var(--s-5);
  list-style: none;
  padding: 0;
}

.site-footer__links li {
  display: flex;
  align-items: center;
}

.site-footer__links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.site-footer__legal { color: var(--muted); }

@media (min-width: 1024px) {
  .site-footer__row {
    grid-template-columns: 1fr auto auto;
    column-gap: var(--s-7);
    align-items: center;
  }
}

/* ---------- 404 ---------- */
.not-found { padding-block: clamp(4rem, 14vw, 10rem); }

.not-found p {
  margin-top: var(--s-4);
  color: var(--ink-2);
}

.not-found .btn-row,
.page-head .btn-row { margin-top: var(--s-6); }

/* ---------- Motion ---------- */
/* Restrained: a short settle of the hero on load. Transform only, so contrast is never reduced mid-animation. */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  @keyframes settle {
    from { transform: translateY(10px); }
    to { transform: none; }
  }

  .hero .container > * {
    animation: settle 600ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }
  .hero .container > :nth-child(2) { animation-delay: 40ms; }
  .hero .container > :nth-child(3) { animation-delay: 80ms; }
  .hero .container > :nth-child(4) { animation-delay: 120ms; }
  .hero .container > :nth-child(5) { animation-delay: 160ms; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}
