/* MapAnimate site. Design rules and tokens: DESIGN.md. Light by default; dark via [data-theme="dark"]. */
:root {
  --page: #f5f5f2;
  --surface: #ffffff;
  --surface-2: #fafaf8;
  --fill: #eeeeea;
  --line: #e3e3de;
  --line-strong: #cfcfc8;
  --ink: #18191b;
  --ink-2: #45474c;
  --muted: #6a6c71;
  --on-ink: #ffffff;
  --route: #e0482a;
  --route-ink: #b93216;
  --route-soft: #fce9e4;
  --marker: #c27400;
  --positive: #1e8a57;
  --float: 0 1px 2px rgba(0, 0, 0, .06), 0 12px 32px -12px rgba(0, 0, 0, .22);
  --r-xs: 4px;
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --wrap: 1200px;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --page: #111213;
  --surface: #1a1b1d;
  --surface-2: #202124;
  --fill: #2a2b2f;
  --line: #2c2d31;
  --line-strong: #3d3e43;
  --ink: #ececea;
  --ink-2: #c3c4c0;
  --muted: #8f9196;
  --on-ink: #111213;
  --route: #ff6b4a;
  --route-ink: #ff9479;
  --route-soft: #3a211b;
  --marker: #f2b13a;
  --positive: #3fcf95;
  --float: 0 1px 2px rgba(0, 0, 0, .4), 0 16px 40px -12px rgba(0, 0, 0, .7);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1px; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { font-family: var(--sans); font-weight: 680; line-height: 1.08; letter-spacing: -.02em; margin: 0 0 .5em; font-variation-settings: "wdth" 85; text-wrap: balance; }
h1 { font-size: clamp(2.4rem, 5vw, 4.2rem); font-weight: 700; line-height: 1.02; letter-spacing: -.028em; font-variation-settings: "wdth" 80; }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); }
h3 { font-size: 1.2rem; font-weight: 650; letter-spacing: -.01em; line-height: 1.25; font-variation-settings: "wdth" 90; }
:focus-visible { outline: 2px solid var(--route); outline-offset: 2px; border-radius: var(--r-xs); }
::selection { background: var(--route-soft); color: var(--ink); }

.wrap { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }
.narrow { width: min(100% - 32px, 760px); margin-inline: auto; }
.mono { font-family: var(--mono); font-size: .8rem; font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 100; background: var(--ink); color: var(--on-ink); padding: 10px 16px; border-radius: var(--r-sm); }
.icon { width: 1.15em; height: 1.15em; flex: none; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Buttons: ink primary, bordered secondary. No lift, no glow. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 40px; padding: .55em 1.05em; border-radius: var(--r-sm); border: 1px solid transparent;
  font: 600 .95rem/1.1 var(--sans); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn-sm { min-height: 34px; padding: .4em .8em; font-size: .88rem; }
.btn-lg { min-height: 48px; padding: .7em 1.35em; font-size: 1.02rem; }
.btn-primary { background: var(--ink); color: var(--on-ink); }
.btn-primary:hover { background: color-mix(in srgb, var(--ink) 84%, var(--page)); }
.btn-signal { background: var(--route); color: #fff; }
.btn-signal:hover { background: var(--route-ink); }
:root[data-theme="dark"] .btn-signal:hover { background: color-mix(in srgb, var(--route) 85%, #000); }
.btn-ghost { background: var(--surface); border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink-2); }
.btn .icon { width: 1.1em; height: 1.1em; }
.text-link { display: inline-flex; align-items: center; gap: .35em; font-weight: 600; text-decoration: underline; text-decoration-color: var(--line-strong); }
.text-link:hover { text-decoration-color: currentColor; }
.text-link .icon { width: 1em; height: 1em; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--page); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-word { font: 700 1.2rem/1 var(--sans); letter-spacing: -.02em; font-variation-settings: "wdth" 85; }
.brand-word em { font-style: normal; }
.main-nav { display: flex; gap: 2px; margin-left: 4px; }
.main-nav a { padding: 8px 10px; text-decoration: none; font-weight: 550; color: var(--ink-2); font-size: .95rem; border-radius: var(--r-sm); }
.main-nav a:hover { color: var(--ink); background: var(--fill); }
.main-nav a[aria-current] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--route); border-radius: 0; }
.header-cta { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.theme-btn {
  width: 38px; height: 38px; display: grid; place-items: center; border-radius: var(--r-sm);
  border: 1px solid transparent; background: none; color: var(--ink-2); cursor: pointer;
}
.theme-btn:hover { background: var(--fill); color: var(--ink); }
.theme-btn .icon { width: 20px; height: 20px; }
.theme-btn .when-dark, :root[data-theme="dark"] .theme-btn .when-light { display: none; }
:root[data-theme="dark"] .theme-btn .when-dark { display: block; }
.menu { display: none; position: relative; }
.menu summary { list-style: none; cursor: pointer; width: 38px; height: 38px; display: grid; place-items: center; border-radius: var(--r-sm); border: 1px solid var(--line-strong); }
.menu summary::-webkit-details-marker { display: none; }
.menu summary .icon { width: 20px; height: 20px; }
.menu-panel { position: absolute; right: 0; top: 46px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--float); padding: 6px; display: grid; min-width: 220px; }
.menu-panel a { padding: 10px 12px; border-radius: var(--r-sm); text-decoration: none; font-weight: 550; }
.menu-panel a:hover { background: var(--fill); }

/* Breadcrumbs */
.crumbs { padding-top: 20px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; font-size: .88rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--line-strong); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }

/* Kicker above a heading: plain, small, sentence case. */
.eyebrow { display: block; font-size: .95rem; font-weight: 600; color: var(--route-ink); margin-bottom: 12px; letter-spacing: 0; }
.section { padding: clamp(56px, 8vw, 104px) 0; border-top: 1px solid var(--line); }
.section-head { max-width: 680px; margin-bottom: 36px; }
.section-head p { font-size: 1.08rem; color: var(--ink-2); }
.section-head.center { margin-inline: auto; text-align: center; }
.lede { font-size: clamp(1.08rem, 1.5vw, 1.22rem); color: var(--ink-2); max-width: 62ch; }

/* Side-by-side section: heading column + content column. */
.side { display: grid; grid-template-columns: minmax(220px, 1fr) 2.4fr; gap: clamp(24px, 5vw, 72px); align-items: start; }
.side > :first-child { position: sticky; top: 96px; }
.side h2 { margin-bottom: .4em; }
.side-note { color: var(--ink-2); font-size: 1rem; }

/* Home hero: a big headline, then a real export playing next to its itinerary. */
.hero { padding: clamp(32px, 5vw, 64px) 0 clamp(48px, 6vw, 80px); }
.hero-title { font-size: clamp(2.6rem, 6.2vw, 5.4rem); line-height: .96; letter-spacing: -.035em; font-variation-settings: "wdth" 75; margin-bottom: 28px; }
.hero-title span { display: block; animation: rise .7s cubic-bezier(.2, .7, .2, 1) both; }
.hero-title span + span { animation-delay: .08s; }
.hero-intro { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px 48px; align-items: end; }
.hero-intro .lede { margin: 0; animation: rise .7s .16s cubic-bezier(.2, .7, .2, 1) both; }
.hero-intro .hero-actions { margin: 0; animation: rise .7s .22s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 28px 0 0; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 6px 24px; padding: 0; margin: 20px 0 0; list-style: none; color: var(--muted); font-size: .93rem; }
.hero-facts li { display: inline-flex; align-items: center; gap: 7px; }
.hero-facts .icon { color: var(--ink-2); width: 1.05em; height: 1.05em; }

/* Player: the hero video and its itinerary as one object. */
.player {
  margin: clamp(36px, 5vw, 56px) 0 0; display: grid; grid-template-columns: minmax(0, 1fr) 300px;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-lg); box-shadow: var(--float); overflow: hidden;
  animation: rise .8s .28s cubic-bezier(.2, .7, .2, 1) both;
}
.player-screen { position: relative; background: #2a8ccf; aspect-ratio: 16 / 9; }
.player-screen video { display: block; width: 100%; height: 100%; object-fit: cover; }
.player-toggle {
  position: absolute; left: 14px; bottom: 16px; width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer;
  display: grid; place-items: center; background: rgba(17, 18, 19, .72); color: #fff; opacity: 0; transition: opacity .15s;
}
.player-screen:hover .player-toggle, .player-toggle:focus-visible, .player.is-paused .player-toggle { opacity: 1; }
.player-toggle .icon { width: 18px; height: 18px; }
.player-toggle .when-paused, .player.is-paused .player-toggle .when-playing { display: none; }
.player.is-paused .player-toggle .when-paused { display: block; }
.player-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(255, 255, 255, .35); }
.player-bar i { display: block; height: 100%; width: 100%; background: var(--route); transform-origin: 0 50%; transform: scaleX(var(--t, 0)); }
.itinerary { display: flex; flex-direction: column; gap: 18px; padding: 22px 22px 20px; border-left: 1px solid var(--line); }
.itinerary-head h2 { font-size: 1.35rem; margin: 10px 0 4px; }
.itinerary-head p { display: flex; align-items: center; gap: 7px; margin: 0; color: var(--muted); font-size: .9rem; }
.itinerary-head p .icon { color: var(--ink-2); }
.live { display: inline-flex; align-items: center; gap: 7px; font-size: .82rem; font-weight: 600; color: var(--route-ink); }
.live i { width: 8px; height: 8px; border-radius: 50%; background: var(--route); animation: blink 1.6s ease-in-out infinite; }
.player.is-paused .live i { animation: none; opacity: .4; }
@keyframes blink { 50% { opacity: .35; } }
.itin-stops { --fill: 0; list-style: none; margin: 0; padding: 0; position: relative; flex: 1; display: flex; flex-direction: column; justify-content: space-between; min-height: 230px; }
.itin-stops::before, .itin-stops::after { content: ""; position: absolute; left: 6px; top: var(--line-top, 14px); bottom: var(--line-bottom, 14px); width: 2px; background: var(--line-strong); }
.itin-stops::after { background: var(--route); transform-origin: 50% 0; transform: scaleY(var(--fill)); }
.itin-stops li { position: relative; z-index: 1; display: flex; justify-content: space-between; gap: 12px; padding: 1px 0 1px 26px; color: var(--muted); font-weight: 550; transition: color .25s; }
.itin-stops li::before { content: ""; position: absolute; left: 0; top: 50%; translate: 0 -50%; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line-strong); transition: border-color .25s, background-color .25s; }
.itin-stops li.is-reached { color: var(--ink); }
.itin-stops li.is-reached::before { border-color: var(--route); }
.itin-stops li.is-current::before { background: var(--route); box-shadow: 0 0 0 4px var(--route-soft); }
.itin-stops .mono { color: var(--muted); }
.player-caption { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 20px; padding: 12px 18px; border-top: 1px solid var(--line); font-size: .86rem; color: var(--muted); background: var(--surface-2); }

/* Four moves, drawn as a line with four stations. */
.line-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); position: relative; }
.line-steps::before { content: ""; position: absolute; left: 7px; right: 0; top: 7px; height: 2px; background: var(--route); transform-origin: 0 50%; transition: transform 1.4s cubic-bezier(.4, 0, .2, 1); }
.line-steps li { position: relative; padding: 34px 28px 0 0; }
.line-steps li::before { content: ""; position: absolute; left: 0; top: 0; width: 16px; height: 16px; border-radius: 50%; background: var(--page); border: 2px solid var(--route); transition: opacity .3s; }
.line-steps li:first-child::before, .line-steps li:last-child::before { background: var(--route); }
.line-steps h3 { font-size: 1.35rem; margin-bottom: 8px; }
.line-steps p { color: var(--ink-2); font-size: .98rem; margin: 0 0 12px; }
.line-steps .mono { color: var(--muted); }
.line-steps.is-waiting::before { transform: scaleX(0); }
.line-steps.is-waiting li::before { opacity: 0; }
.line-steps li:nth-child(2)::before { transition-delay: .4s; }
.line-steps li:nth-child(3)::before { transition-delay: .8s; }
.line-steps li:nth-child(4)::before { transition-delay: 1.2s; }

/* Formats: text, a 9:16 clip and a 1:1 clip side by side. */
.formats { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .75fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: center; }
.formats h2 { margin-bottom: .4em; }
.spec-compact { margin: 24px 0; }
.spec.spec-compact > div { grid-template-columns: 110px 1fr; padding: 11px 0; }
.clip { margin: 0; }
.clip video { display: block; width: 100%; height: auto; border-radius: var(--r-md); border: 1px solid var(--line-strong); background: #0b0d10; box-shadow: var(--float); }
.clip-tall video { aspect-ratio: 9 / 16; }
.clip-square video { aspect-ratio: 1; }
.clip figcaption { margin-top: 12px; font-size: .9rem; color: var(--muted); display: grid; }
.clip figcaption b { color: var(--ink); font-weight: 650; }

.hero-shot { margin: 0; }
.shot { border-radius: var(--r-md); border: 1px solid var(--line-strong); overflow: hidden; background: var(--surface); box-shadow: var(--float); }
.shot img { width: 100%; height: auto; }
.shot .when-dark, :root[data-theme="dark"] .shot .when-light { display: none; }
:root[data-theme="dark"] .shot .when-dark { display: block; }
/* Spec list: what → specifics, as rows. */
.spec { margin: 0; border-top: 1px solid var(--line); }
.spec > div { display: grid; grid-template-columns: 190px 1fr; gap: 6px 28px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.spec dt { font-weight: 650; font-variation-settings: "wdth" 90; }
.spec dd { margin: 0; color: var(--ink-2); }
.spec dd strong { color: var(--ink); font-weight: 600; }

/* Legend of transports, like the key on a printed map. */
.legend { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 0 28px; border-top: 1px solid var(--line); }
.legend a { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); text-decoration: none; font-weight: 550; }
.legend a:hover span { text-decoration: underline; text-underline-offset: .2em; }
.legend svg { width: 44px; height: 12px; flex: none; overflow: visible; }
.legend .icon { color: var(--ink-2); width: 18px; height: 18px; }

/* Plain list of rows with a thumbnail (routes, guides). */
.rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.rows a { display: grid; grid-template-columns: 112px 1fr auto; align-items: center; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.rows a:hover h3 { text-decoration: underline; text-underline-offset: .2em; }
.rows .route-sketch { width: 112px; height: 70px; border-radius: var(--r-sm); border: 1px solid var(--line); }
.rows h3 { margin: 0 0 2px; font-size: 1.08rem; }
.rows p { margin: 0; color: var(--muted); font-size: .93rem; }
.rows .mono { color: var(--muted); white-space: nowrap; }
.rows-2 { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }

/* Steps (inner pages still use these): a numbered list, not cards. */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; padding: 0; margin: 0; list-style: none; border-top: 1px solid var(--line); }
.step { padding: 20px 24px 8px 0; }
.step + .step { padding-left: 24px; border-left: 1px solid var(--line); }
.step-num { font: 500 .85rem var(--mono); color: var(--route-ink); margin-bottom: 10px; }
.step h3 { margin-bottom: 6px; }
.step p { color: var(--ink-2); margin: 0; font-size: .97rem; }
.step-link { display: none; }

/* Cards and grids */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  overflow: hidden; text-decoration: none; display: flex; flex-direction: column;
  transition: border-color .15s;
}
a.card:hover { border-color: var(--ink-2); }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card-body h3 { margin: 0; font-size: 1.08rem; }
.card-body p { margin: 0; color: var(--ink-2); font-size: .93rem; }
.card-meta { font-size: .85rem; color: var(--muted); }
.card .theme-preview, .card .route-sketch { width: 100%; height: auto; aspect-ratio: 16 / 10; border-bottom: 1px solid var(--line); }
.swatches { display: flex; gap: 4px; margin-top: auto; padding-top: 10px; }
.swatches i { width: 16px; height: 16px; border-radius: var(--r-xs); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .14); }

/* Style swatch book: map previews with captions, no boxes. */
.swatchbook { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px 20px; }
.swatchbook a { text-decoration: none; display: grid; gap: 10px; align-content: start; }
.swatchbook .theme-preview { width: 100%; height: auto; aspect-ratio: 16 / 10; border-radius: var(--r-sm); border: 1px solid var(--line); transition: border-color .15s; }
.swatchbook a:hover .theme-preview { border-color: var(--ink-2); }
.swatchbook img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--r-sm); border: 1px solid var(--line); transition: border-color .15s; }
.swatchbook a:hover img { border-color: var(--ink-2); }
.swatchbook strong { display: block; font-weight: 650; }
.swatchbook span { display: block; color: var(--muted); font-size: .9rem; line-height: 1.4; }

/* Features (inner pages) */
.feature { padding: 20px 0 0; border-top: 1px solid var(--line); }
.feature-icon { width: auto; height: auto; margin-bottom: 10px; color: var(--route-ink); background: none; }
.feature-icon .icon { width: 22px; height: 22px; }
.feature h3 { font-size: 1.12rem; margin-bottom: 6px; }
.feature p { margin: 0; color: var(--ink-2); font-size: .97rem; }
.feature-row { display: grid; grid-template-columns: 220px 1fr; gap: 28px; padding: 36px 0; border-top: 1px solid var(--line); }

/* Transport chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 9px; padding: 5px 12px 5px 5px; border-radius: var(--r-sm);
  background: var(--surface); border: 1px solid var(--line); text-decoration: none; font-weight: 550; font-size: .95rem;
  transition: border-color .15s;
}
.chip:hover { border-color: var(--ink-2); }
.chip-badge { width: 28px; height: 28px; border-radius: var(--r-xs); display: grid; place-items: center; color: #fff; }
.chip-badge .icon { width: 17px; height: 17px; }

/* Former dark band: now just a section. */
.band { background: none; }

/* Support block */
.support { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(24px, 5vw, 72px); align-items: start; }
.support h2 { font-size: clamp(1.75rem, 3vw, 2.4rem); }
.support-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.support-list li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.support-list b { color: var(--ink); font-weight: 600; }

/* Prose */
.prose { font-size: 1.06rem; max-width: 70ch; }
.prose h2 { font-size: 1.65rem; margin-top: 1.8em; }
.prose h3 { margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--muted); }
.prose a { color: var(--route-ink); }
.prose strong { font-weight: 650; }
.prose code { font: .9em var(--mono); background: var(--fill); padding: .1em .35em; border-radius: var(--r-xs); }
.answer { border-left: 3px solid var(--route); padding: 4px 0 4px 20px; margin: 0 0 32px; }
.answer .mono { color: var(--muted); display: block; margin-bottom: 6px; font-family: var(--sans); font-size: .9rem; font-weight: 600; }
.answer p { margin: 0; font-size: 1.12rem; color: var(--ink); }
.steps-list { counter-reset: s; list-style: none; padding: 0; margin: 0 0 36px; border-top: 1px solid var(--line); }
.steps-list li { counter-increment: s; position: relative; padding: 14px 0 14px 48px; border-bottom: 1px solid var(--line); }
.steps-list li::before { content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: 15px; font: 500 .9rem var(--mono); color: var(--route-ink); }

/* Page hero (inner pages) */
.page-hero { padding: 30px 0 40px; }
.page-hero h1 { font-size: clamp(2.2rem, 4.4vw, 3.6rem); max-width: 900px; }
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.figure { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.figure svg { width: 100%; height: auto; }

/* Facts table */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0; border-block: 1px solid var(--line); margin: 24px 0; }
.facts div { padding: 14px 18px 14px 0; }
.facts div + div { padding-left: 18px; border-left: 1px solid var(--line); }
.facts dt { font-size: .85rem; color: var(--muted); margin-bottom: 2px; }
.facts dd { margin: 0; font-weight: 650; font-size: 1.08rem; font-variant-numeric: tabular-nums; }
.facts a { color: var(--route-ink); }
.fact-list { display: grid; gap: 0; border-top: 1px solid var(--line); margin: 0; }
.fact-list > div { display: grid; grid-template-columns: 220px 1fr; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.fact-list dt { font-weight: 650; }
.fact-list dd { margin: 0; color: var(--ink-2); }

/* Stops list: a route line with stations, like a transit diagram. */
.stops { list-style: none; padding: 0; margin: 0; position: relative; }
.stops::before { content: ""; position: absolute; left: 7px; top: 18px; bottom: 18px; width: 2px; background: var(--route); }
.stops li { position: relative; padding: 8px 0 8px 32px; font-weight: 600; }
.stops li::before { content: ""; position: absolute; left: 1px; top: 50%; translate: 0 -50%; width: 14px; height: 14px; border-radius: 50%; background: var(--page); border: 2px solid var(--route); }
.stops li:first-child::before, .stops li:last-child::before { background: var(--route); }
.stops .mono { color: var(--muted); font-weight: 400; margin-left: 8px; }

/* FAQ */
.faq { display: grid; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 0; font-weight: 600; font-size: 1.08rem; line-height: 1.35; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 400 1.4rem/1 var(--sans); color: var(--muted); transition: rotate .2s; }
.faq summary:hover::after { color: var(--ink); }
.faq details[open] summary::after { rotate: 45deg; }
.faq details > div { padding: 0 0 20px; color: var(--ink-2); max-width: 70ch; }
.faq details > div p:last-child { margin: 0; }
.faq a { color: var(--route-ink); }

/* Line style demo on transport pages */
.line-demo { padding: 26px; display: grid; place-items: center; background: var(--surface-2); }
.badge-xl { width: 96px; height: 96px; border-radius: var(--r-md); display: grid; place-items: center; color: #fff; box-shadow: 0 0 0 4px var(--surface-2); }
.badge-xl .icon { width: 52px; height: 52px; }

/* Changelog */
.release { display: grid; grid-template-columns: 180px 1fr; gap: 24px; padding: 28px 0; border-top: 1px solid var(--line); }
.release ul { margin: 0; padding-left: 1.2em; }

/* Donate */
.donate-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0; }
.note { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px 18px; color: var(--ink-2); }
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line); }
.tier { padding: 22px 24px 8px 0; }
.tier + .tier { padding-left: 24px; border-left: 1px solid var(--line); }
.tier h3 { display: flex; align-items: center; gap: 10px; }
.tier h3 .icon { color: var(--route-ink); }
.tier ul { padding-left: 1.1em; margin: 12px 0 0; color: var(--ink-2); }

/* CTA strip */
.cta-strip {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px;
  border-block: 1px solid var(--line); padding: 28px 0; margin: 56px 0 0;
}
.cta-strip h2 { margin: 0; font-size: 1.6rem; }
.cta-strip p { margin: 4px 0 0; color: var(--ink-2); }

/* Footer */
.site-footer { background: var(--surface-2); border-top: 1px solid var(--line); color: var(--ink-2); margin-top: clamp(64px, 9vw, 120px); font-size: .95rem; }
.footer-contours { display: none; }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; padding: 56px 0 40px; }
.footer-brand p { margin: 14px 0 18px; max-width: 320px; }
.site-footer h2 { font-size: .85rem; font-weight: 650; color: var(--ink); margin: 6px 0 12px; letter-spacing: 0; font-variation-settings: normal; }
.site-footer nav { display: grid; align-content: start; gap: 8px; }
.site-footer nav a { text-decoration: none; color: var(--ink-2); }
.site-footer nav a:hover { color: var(--ink); text-decoration: underline; }
.footer-sponsors { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; padding: 18px 0; border-top: 1px solid var(--line); }
.footer-sponsors img { filter: grayscale(1); opacity: .75; }
:root[data-theme="dark"] .footer-sponsors img { filter: grayscale(1) invert(1); }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 18px 0 28px; border-top: 1px solid var(--line); font-size: .88rem; color: var(--muted); }
.footer-base .mono { font-size: .78rem; }

/* 404 */
.lost { text-align: center; padding: 60px 0 20px; }
.lost svg { width: min(100%, 420px); margin: 0 auto 28px; }

/* Responsive */
@media (max-width: 1080px) {
  .player { grid-template-columns: 1fr; }
  .itinerary { border-left: 0; border-top: 1px solid var(--line); }
  .itin-stops { min-height: 0; gap: 8px; }
  .formats { grid-template-columns: 1fr 1fr; }
  .formats-text { grid-column: 1 / -1; }
  .main-nav { display: none; }
  .menu { display: block; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step:nth-child(3) { padding-left: 0; border-left: 0; }
  .grid-4, .swatchbook { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .hero-intro { grid-template-columns: 1fr; }
  .line-steps { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .line-steps::before { display: none; }
  .rows-2 { grid-template-columns: 1fr; }
  .split, .support, .side { grid-template-columns: 1fr; }
  .side > :first-child { position: static; }
  .grid-3, .grid-4, .swatchbook { grid-template-columns: repeat(2, 1fr); }
  .tiers { grid-template-columns: 1fr; }
  .tier + .tier { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .release { grid-template-columns: 1fr; gap: 8px; }
  .fact-list > div, .spec > div, .feature-row { grid-template-columns: 1fr; gap: 4px; }
  .feature-row { gap: 16px; }
}
@media (max-width: 600px) {
  .line-steps { grid-template-columns: 1fr; row-gap: 28px; }
  .line-steps li:not(:last-child)::after { content: ""; position: absolute; left: 7px; top: 16px; bottom: -28px; width: 2px; background: var(--route); }
  .line-steps li { padding: 0 0 0 36px; }
  .formats { grid-template-columns: 1fr; }
  .clip-tall { max-width: 300px; }
  .player-caption { padding: 10px 14px; }
  .player-toggle { opacity: 1; }
  body { font-size: 16px; }
  .hide-sm { display: none; }
  .header-inner { gap: 10px; }
  .steps, .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .step + .step { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .facts div + div { padding-left: 0; border-left: 0; }
  .facts div { border-bottom: 1px solid var(--line); }
  .facts div:last-child { border-bottom: 0; }
  .hero-actions .btn { flex: 1 1 100%; }
  .rows a { grid-template-columns: 84px 1fr; }
  .rows .route-sketch { width: 84px; height: 54px; }
  .rows .mono { display: none; }
  .swatchbook { gap: 22px 14px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .card, .chip { transition: none; }
  .hero-title span, .hero-intro .lede, .hero-intro .hero-actions, .player { animation: none; }
  .live i { animation: none; }
  .line-steps::before, .line-steps li::before { transition: none; }
}

/* Logo follows the theme: an ink tile in light, a light tile in dark. */
.lm-tile { fill: var(--ink); }
.lm-ink { stroke: var(--page); }
.lm-ink-fill { fill: var(--page); }
.lost .ink-stroke { stroke: var(--ink); }
.lost .ink-fill { fill: var(--ink); }
.lost .muted-fill { fill: var(--muted); }
.lost .page-stroke { stroke: var(--page); }
.lost .page-fill { fill: var(--page); }
.feature-row h2 { font-size: 1.5rem; display: flex; gap: 10px; align-items: center; margin: 0; }
.feature-row h2 .icon { color: var(--route-ink); width: 22px; height: 22px; }
.feature-row dl { margin: 0; gap: 20px 32px; }
.feature-row dt { font-weight: 650; }
.feature-row dd { margin: 4px 0 0; color: var(--ink-2); }
