/* Self-hosted Instrument Sans (one variable file per subset) and IBM Plex Mono, both SIL OFL (see OFL-*.txt).
   Latin and latin-ext only, as Google serves them; other scripts use the system fallback in --font. */
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 400 600; font-display: swap; src: url('/fonts/instrument-sans-v4-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Instrument Sans'; font-style: normal; font-weight: 400 600; font-display: swap; src: url('/fonts/instrument-sans-v4-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/ibm-plex-mono-v23-latin-ext-400.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/ibm-plex-mono-v23-latin-400.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-v23-latin-ext-500.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-v23-latin-500.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* GENERATED by scripts/gen-tokens.mjs from shared/tokens.json. Do not edit; run `npm run tokens`.
   EarthPane design tokens. City Lights: Earth's night side from orbit, sodium amber for
   selection, atmosphere-limb blue for live activity. Every raw value in the UI lives here; feature CSS
   uses var(--…) only. Mirrored for TypeScript in tokens.ts, and for SwiftUI/Compose in native/. */
:root {
  /* colour: surfaces */
  --bg: #0b0f13;
  --surface: rgba(18, 23, 28, 0.94);
  --surface-solid: #12171c;
  --surface-sunken: rgba(0, 0, 0, 0.25);
  --scrim: rgba(4, 6, 9, 0.6);
  --raise: rgba(200, 215, 230, 0.06);
  --line: rgba(200, 215, 230, 0.1);
  --line-strong: rgba(200, 215, 230, 0.22);
  --raise-hi: rgba(255, 255, 255, 0.06);
  --raise-lo: rgba(255, 255, 255, 0.04);
  --toast-bg: #e8ecef;
  --switch-off: #39424c;
  --switch-knob: #cfd6dc;
  --approx-fill: rgba(90, 160, 224, 0.18);
  --approx-line: rgba(90, 160, 224, 0.7);
  --approx-label-bg: rgba(11, 15, 19, 0.7);
  --now-quake-bg: rgba(240, 138, 93, 0.18);
  --now-lightning-bg: rgba(242, 197, 65, 0.16);
  --now-space-bg: rgba(127, 212, 255, 0.14);
  --now-emergency-bg: rgba(240, 109, 109, 0.16);
  --now-news-bg: rgba(143, 180, 255, 0.16);
  --now-markets-bg: rgba(111, 211, 160, 0.16);
  --now-social-bg: rgba(215, 154, 242, 0.16);
  /* colour: text */
  --text: #e8ecef;
  --text-dim: #c3cad1;
  --muted: #8f99a3;
  --toast-text: #11161b;
  --toast-undo: #9a5a08;
  --approx-label: #bcd9f2;
  /* colour: roles */
  --accent: #f2a541;
  --accent-ink: #1a1206;
  --accent-soft: rgba(242, 165, 65, 0.14);
  --accent-press: rgba(242, 165, 65, 0.18);
  --accent-ghost: rgba(242, 165, 65, 0.45);
  --live: #7fd4ff;
  --good: #57c28a;
  --warn: #e7c24a;
  --bad: #ef5b5b;
  --bad-soft: rgba(239, 91, 91, 0.16);
  --clear: #7fd99a;
  --now-quake: #f08a5d;
  --now-lightning: #f2c541;
  --now-space: #7fd4ff;
  --now-emergency: #f06d6d;
  --now-news: #8fb4ff;
  --now-markets: #6fd3a0;
  --now-social: #d79af2;

  /* type */
  --font: 'Instrument Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --fs-2xs: 10.5px;
  --fs-xs: 11.5px;
  --fs-sm: 12.5px;
  --fs-md: 13px;
  --fs-lg: 14px;
  --fs-xl: 15px;
  --fs-2xl: 18px;
  --fs-count: 12px;
  --fs-toast: 14.5px;
  --fs-lead: 16.5px;
  --fs-title: 20px;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-bold: 600;
  --fw-heavy: 700;

  /* space (4px grid, plus the panel gutter) */
  --s-1: 4px;
  --s-2: 6px;
  --s-3: 8px;
  --s-4: 10px;
  --s-5: 12px;
  --s-6: 14px;
  --s-8: 16px;
  --gap: 12px;

  /* shape */
  --r-xs: 3px;
  --r-sm: 4px;
  --r-md: 6px;
  --r-lg: 8px;
  --r-sheet: 14px;
  --r-pill: 999px;
  --r-sheet-lg: 24px;

  /* size */
  --control: 40px;
  --control-sm: 32px;
  --touch: 44px;
  --target-min: 24px;
  --panel-w: 320px;
  --side-w: 320px;
  --rail-w: 64px;
  --dialog-w: 560px;
  --sheet-peek: 140px;
  --bp-phone: 720px;
  --sheet-inset: 14px;
  --round-btn: 52px;
  --tools-btn: 56px;
  --row-h: 60px;
  --icon-tile: 38px;

  /* elevation and glass */
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  --blur: blur(14px) saturate(1.2);

  /* motion */
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-fast: 0.12s;
  --dur: 0.16s;
  --dur-slow: 0.22s;
  --dur-eq: 0.9s;
  --dur-hint: 1.6s;
}

/* Web-only tokens, hand-written: appended to the generated tokens.css by scripts/gen-tokens.mjs. */
:root {
  /* layers */
  --z-map-ui: 2;
  --z-panel: 3;
  --z-bar: 4;
  --z-sheet: 5; /* over the bar: a full-height phone sheet covers its second row */
  --z-nav: 6; /* the phone's Tools button: over the map controls */
  --z-tooltip: 7;
  --z-ask: 8;
  --z-skip: 10;
  --z-notice: 11;

  /* device: safe areas (notch, home indicator, Android cutouts); 0 on desktop */
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  /* where panels start under the top bar */
  --top-offset: calc(var(--safe-top) + var(--gap) + var(--control) + var(--gap));

  /* the marketing pages (site/): display type, section rhythm and reading widths */
  --fs-3xl: 21px;
  --fs-form-title: 26px;
  /* Google's and Apple's own light buttons */
  --sso: #fff;
  --sso-ink: #1f1f1f;
  --fs-4xl: clamp(26px, 3.4vw, 34px);
  --fs-display: clamp(38px, 6.4vw, 68px);
  --s-12: 24px;
  --s-16: 32px;
  --s-24: 48px;
  --s-32: 72px;
  --site-w: 1160px;
  --prose-w: 660px;

  --nav-h: 56px;
  --home-bar: env(safe-area-inset-bottom, 0px);
  --fs-field: 16px;

  color-scheme: dark;
}

/* Android GPUs redo a backdrop blur on every frame the map moves under it, which makes panning
   stutter on mid-range phones. There, glass surfaces are opaque instead (platform.ts sets this). */
:root[data-fx="lite"] {
  --blur: none;
  --surface: var(--surface-solid);
}

@media (max-width: 720px) {
  /* No bottom bar (the Tools button floats, touch-layout.css), so "safe" is just the home indicator. */
  :root { --gap: 8px; --sheet-peek: 196px; --safe-bottom: var(--home-bar); }
}

/* EarthPane primitives. Tokens only (ds/tokens.css). Feature CSS adds position and layout on top;
   it does not restyle these. Every interactive primitive grows to --touch on coarse pointers. */

/* ---- base ------------------------------------------------------------------------------- */
* { box-sizing: border-box; }
html, body {
  margin: 0; height: 100%; background: var(--bg); color: var(--text); overflow: hidden;
  font: var(--fw-regular) var(--fs-md)/1.45 var(--font); -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; color: inherit; }
h2, h3 { margin: 0; }
.ds-num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
/* touch: no grey tap flash, no double-tap zoom delay */
button, a, input, select, summary, [role='button'] { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
input[type='checkbox'], input[type='range'] { accent-color: var(--accent); }
input[type='checkbox'] { margin: 0; width: 15px; height: 15px; }

/* ---- glass surface: every floating panel, bar control and sheet ---------------------------- */
.ds-glass {
  background: var(--surface); border: 1px solid var(--line);
  backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur);
}
.ds-card { border-radius: var(--r-lg); box-shadow: var(--shadow); }
/* Panels sit over a map that redraws many times a second, and a blurred backdrop is re-blurred on each of
   those frames. Their surface is 94% opaque, so the blur added nothing you could see: chips and bars keep it. */
.ds-glass.ds-card { backdrop-filter: none; -webkit-backdrop-filter: none; }
.ds-popover { background: var(--surface-solid); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow); }

/* ---- chip: 40px top-bar control --------------------------------------------------------- */
.ds-chip {
  display: flex; align-items: center; gap: 7px; height: var(--control); padding: 0 var(--s-5) 0 13px; border-radius: var(--r-md);
  color: var(--text); text-decoration: none; cursor: pointer; font-weight: var(--fw-medium);
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.ds-chip[aria-expanded='true'] { border-color: var(--line-strong); }
.ds-chip:active { transform: scale(0.97); }
@media (hover: hover) { .ds-chip:hover { border-color: var(--line-strong); } }
/* quiet: no box, just icon and label over the map (top-bar tools). The text shadow keeps it legible on
   bright imagery; hover and open get a faint fill rather than a border. */
.ds-chip--quiet { background: none; border: 0; color: var(--text-dim); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9); }
.ds-chip--quiet[aria-expanded='true'] { color: var(--accent); background: var(--surface-solid); text-shadow: none; }
@media (hover: hover) { .ds-chip--quiet:hover { color: var(--text); background: var(--raise); } }
/* a mode the chip turned on is still running (e.g. a drawing tool is armed) */
.ds-chip--on, .ds-chip--on:hover { border-color: var(--accent-ghost); background: var(--accent-soft); color: var(--accent); }

/* ---- badge: small count ------------------------------------------------------------------ */
.ds-badge {
  min-width: 18px; padding: 0 var(--s-1); border-radius: var(--r-xs); background: var(--accent); color: var(--accent-ink);
  font: var(--fw-medium) 11px/16px var(--font-mono); text-align: center; font-variant-numeric: tabular-nums; text-shadow: none;
}
.ds-badge:empty { display: none; }

/* ---- dot: a layer's colour --------------------------------------------------------------- */
.ds-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--dot, var(--accent)); }

/* ---- equalizer: three bars bouncing while audio plays (colour from --eq, default live blue) ---- */
.ds-eq { display: inline-flex; align-items: flex-end; gap: 2px; width: 12px; height: 12px; flex: none; color: var(--eq, var(--live)); }
.ds-eq i { flex: 1; height: 100%; border-radius: 1px; background: currentColor; transform-origin: bottom; animation: ds-eq var(--dur-eq) var(--ease) infinite alternate; }
.ds-eq i:nth-child(2) { animation-delay: calc(var(--dur-eq) / -3); }
.ds-eq i:nth-child(3) { animation-delay: calc(var(--dur-eq) / -1.5); }
@keyframes ds-eq { from { transform: scaleY(0.25); } to { transform: scaleY(1); } }

/* ---- button ------------------------------------------------------------------------------ */
.ds-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2); height: var(--control-sm); padding: 0 var(--s-5);
  border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: none; color: var(--text);
  text-decoration: none; cursor: pointer; font-weight: var(--fw-medium);
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.ds-btn:hover { border-color: var(--accent); color: var(--accent); }
.ds-btn:active { transform: scale(0.97); }
.ds-btn:disabled { opacity: 0.5; cursor: default; }
.ds-btn--primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.ds-btn--primary:hover { color: var(--accent-ink); filter: brightness(1.08); }

/* ---- icon button ------------------------------------------------------------------------- */
.ds-icon-btn {
  width: 26px; height: 26px; flex: none; display: grid; place-items: center; padding: 0; border: 0; border-radius: 6px; background: none;
  color: var(--muted); font-size: var(--fs-xl); line-height: 1; cursor: pointer;
}
.ds-icon-btn:hover { background: var(--raise); color: var(--text); }
.ds-icon-btn[hidden] { display: none; }
.ds-icon-btn--danger { width: 24px; height: 24px; font-size: 17px; }
.ds-icon-btn--danger:hover { background: var(--bad-soft); color: var(--bad); }
/* the × that closes a panel or sheet */
.ds-close { width: 28px; height: 28px; margin: -4px -6px -4px 0; border-radius: var(--r-sm); font-size: 20px; }

/* ---- link button ------------------------------------------------------------------------- */
.ds-link {
  background: none; border: 0; padding: 0; color: var(--accent); cursor: pointer; font-size: var(--fs-sm);
  transition: color var(--dur) var(--ease);
}
.ds-link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---- fold: a link in a row's status line that unfolds a key or a filter under the row -------
   <button class="ds-link ds-fold" aria-expanded aria-controls> naming what is inside or the current
   choice; data-default mutes it while a filter is at its default. The body carries [hidden]. */
.ds-fold { position: relative; font: inherit; font-family: var(--font); font-size: var(--fs-sm); font-variant-numeric: normal; text-align: start; outline-offset: -2px; }
.ds-fold[data-default] { color: var(--muted); }
@media (hover: hover) { .ds-fold[data-default]:hover { color: var(--text); } }
.ds-fold:active { color: var(--text); }
.ds-fold:disabled { opacity: 0.55; cursor: default; }
.ds-fold::after { content: '▾'; display: inline-block; margin-inline-start: var(--s-2); font-size: var(--fs-lg); line-height: 1; }
.ds-fold[aria-expanded='true']::after { content: '▴'; }
.ds-layer-row .lr-blurb:has(.ds-fold) { display: flex; flex-wrap: wrap; align-items: center; column-gap: var(--s-5); overflow-x: clip; }
/* The dot hangs in the gap, so it is clipped away when the words wrap to a line of their own. */
.st:not(:empty) + .ds-fold::before { content: '·'; position: absolute; right: 100%; width: var(--s-5); text-align: center; color: var(--muted); }

/* ---- pill: small selectable option (radius, view, compare) -------------------------------- */
.ds-pill {
  padding: 3px var(--s-4); border-radius: var(--r-pill); border: 1px solid var(--line-strong); background: none;
  color: var(--muted); font-size: 12px; cursor: pointer; white-space: nowrap;
}
.ds-pill:hover { color: var(--text); }
.ds-pill.sel, .ds-pill[aria-pressed='true'], .ds-pill[aria-checked='true'] { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

/* ---- tool: an icon over a short label, one of a row of modes (draw tools) ------------------ */
.ds-tool {
  display: grid; justify-items: center; align-content: center; gap: var(--s-1); min-width: 0; min-height: 56px; padding: var(--s-3) var(--s-1);
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-sunken); color: var(--muted);
  font-size: var(--fs-xs); font-weight: var(--fw-medium); line-height: 1.15; text-align: center; cursor: pointer;
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.ds-tool svg { width: 20px; height: 20px; flex: none; }
@media (hover: hover) { .ds-tool:hover { border-color: var(--line-strong); color: var(--text); } }
.ds-tool:active { transform: scale(0.96); }
.ds-tool:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.ds-tool[aria-pressed='true'] { border-color: var(--accent-ghost); background: var(--accent-soft); color: var(--accent); }
.ds-tool:disabled { opacity: 0.5; cursor: default; }

/* ---- input ------------------------------------------------------------------------------- */
.ds-input {
  width: 100%; height: 34px; padding: 0 var(--s-4); border-radius: var(--r-sm); border: 1px solid var(--line);
  background: var(--surface-sunken); color: var(--text); outline: none;
}
.ds-input:focus { border-color: var(--accent); }
.ds-input:focus-visible { outline-offset: 0; }
.ds-input::placeholder { color: var(--muted); }

/* ---- select: a .ds-input that picks one option; the browser's own chrome is replaced by a drawn caret ---- */
.ds-select {
  appearance: none; -webkit-appearance: none; padding-right: calc(var(--s-4) * 2 + var(--s-3)); cursor: pointer;
  text-overflow: ellipsis; white-space: nowrap;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: right calc(var(--s-4) + var(--s-1)) center, right var(--s-4) center;
  background-size: var(--s-1) var(--s-1); background-repeat: no-repeat;
  transition: border-color var(--dur-fast) var(--ease);
}
@media (hover: hover) { .ds-select:hover { border-color: var(--line-strong); } }
.ds-select:focus { border-color: var(--accent); }
.ds-select:disabled { opacity: 0.5; cursor: default; }
.ds-select option { background: var(--surface-solid); color: var(--text); }

/* ---- menu: pick one of a few from a link (native popover) -----------------------------------
   <div class="ds-menu" popover role="menu"> of button.ds-menu-item[role=menuitemradio][aria-checked]:
   .ds-menu-dot, label, .ds-menu-end (a count). Placed by its opener; a bottom sheet on phones. */
.ds-menu {
  position: fixed; inset: auto; margin: 0; padding: var(--s-1); min-width: 240px; max-width: calc(100vw - var(--s-8)); max-height: 60vh; overflow: auto;
  border: 1px solid var(--line-strong); border-radius: var(--r-md); background: var(--surface-solid); color: var(--text); box-shadow: var(--shadow);
}
.ds-menu-item {
  display: grid; grid-template-columns: var(--s-5) var(--s-3) 1fr auto; align-items: center; gap: var(--s-3); width: 100%; min-height: var(--control-sm);
  padding: 0 var(--s-3); border: 0; border-radius: var(--r-sm); background: none; color: inherit; font: inherit; font-size: var(--fs-md); text-align: start; cursor: pointer;
}
.ds-menu-item::before { content: ''; }
.ds-menu-item[aria-checked='true']::before { content: '✓'; }
.ds-menu-item[aria-checked='true'] { background: var(--accent-soft); color: var(--accent); }
@media (hover: hover) { .ds-menu-item:hover:not([aria-checked='true']) { background: var(--raise); } }
.ds-menu-item:active { background: var(--accent-press); }
.ds-menu-item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.ds-menu-item:disabled { opacity: 0.5; cursor: default; }
.ds-menu-item--note { grid-template-columns: var(--s-5) 1fr; padding-block: var(--s-2); }
.ds-menu-item small { display: block; color: var(--muted); font-size: var(--fs-sm); }
.ds-menu-title { display: none; padding: 0 var(--s-3) var(--s-3); font-weight: var(--fw-medium); }
.ds-menu-dot { width: var(--s-3); height: var(--s-3); border-radius: 50%; }
.ds-menu-end { color: var(--muted); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
@media (max-width: 720px) {
  /* !important: over the opener's inline placement */
  .ds-menu {
    inset: auto 0 0 !important; width: auto; max-width: none; padding: var(--s-4) var(--s-4) calc(var(--s-4) + var(--safe-bottom));
    border-width: 1px 0 0; border-radius: var(--r-sheet) var(--r-sheet) 0 0;
  }
  .ds-menu::backdrop { background: var(--scrim); }
  .ds-menu-item { min-height: var(--touch); }
  .ds-menu-title { display: block; }
}

/* ---- segmented: one choice from a few, all visible (radio inputs inside labels) ------------ */
.ds-segmented {
  display: flex; margin: 0; padding: 2px; min-width: 0; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-sunken);
}
.ds-segmented label {
  position: relative; flex: 1; display: grid; place-items: center; height: 28px; padding: 0 var(--s-3); border-radius: var(--r-xs);
  color: var(--muted); font-size: var(--fs-sm); font-weight: var(--fw-medium); white-space: nowrap; cursor: pointer;
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.ds-segmented input { position: absolute; opacity: 0; pointer-events: none; }
@media (hover: hover) { .ds-segmented label:hover { color: var(--text); } }
.ds-segmented label:has(:checked) { background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent-ghost); }
.ds-segmented label:has(:focus-visible) { outline: 2px solid var(--accent); outline-offset: 1px; }
.ds-segmented label:active { transform: scale(0.97); }
.ds-segmented label:has(:disabled) { opacity: 0.5; cursor: default; transform: none; }
@media (hover: hover) { .ds-segmented label:has(:disabled):hover { color: var(--muted); } }

/* ---- switch: an on/off checkbox drawn as a track and knob ---------------------------------- */
/* input.ds-switch outranks the plain checkbox size above */
input.ds-switch {
  appearance: none; -webkit-appearance: none; position: relative; flex: none; width: 34px; height: 20px; margin: 0;
  border-radius: var(--r-pill); background: var(--line-strong); cursor: pointer; transition: background-color var(--dur) var(--ease);
}
.ds-switch::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--text);
  transition: transform var(--dur) var(--ease);
}
.ds-switch:checked { background: var(--accent); }
.ds-switch:checked::after { transform: translateX(14px); background: var(--accent-ink); }
.ds-switch:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ds-switch:disabled { opacity: 0.5; cursor: default; }

/* ---- row: a tappable line in a list ------------------------------------------------------- */
.ds-row {
  width: 100%; border: 0; border-radius: var(--r-sm); background: none; color: inherit; text-align: left; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.ds-row:hover { background: var(--raise); }

/* ---- layer row: lead · name · blurb · trailing control (a switch or ×) ----------------------
   <label class="ds-layer-row"> so the whole row flips its switch. Children: .lr-lead (swatch),
   .lr-name, .lr-blurb (one plain-language line), .lr-end (control + status). */
.ds-layer-row {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: var(--s-4); row-gap: 1px; align-items: center;
  padding: var(--s-3) var(--s-4); border-radius: var(--r-sm); cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
@media (hover: hover) { .ds-layer-row:hover { background: var(--raise); } }
.ds-layer-row:active { background: var(--accent-press); }
.ds-layer-row:has(:focus-visible) { outline: 2px solid var(--accent); outline-offset: -2px; }
.ds-layer-row .lr-lead { grid-row: 1 / span 2; display: grid; place-items: center; width: 16px; }
.ds-layer-row .lr-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: var(--fw-medium); }
.ds-layer-row .lr-blurb { grid-column: 2; min-width: 0; color: var(--muted); font-size: var(--fs-sm); line-height: 1.35; }
.ds-layer-row .lr-end { grid-column: 3; grid-row: 1 / span 2; display: flex; align-items: center; gap: var(--s-3); }
.ds-layer-row:has(input:disabled) { cursor: default; opacity: 0.55; }
.ds-layer-row:has(input:disabled):active { background: none; }

/* ---- tabs: one view from several, as a scrolling row of text (buttons with aria-selected) ---- */
.ds-tabs { flex: none; display: flex; gap: var(--s-1); overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); }
.ds-tabs::-webkit-scrollbar { display: none; }
.ds-tab {
  flex: none; height: var(--control-sm); padding: 0 var(--s-4); border: 0; background: none; color: var(--muted); cursor: pointer;
  font-weight: var(--fw-medium); white-space: nowrap; transition: color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
@media (hover: hover) { .ds-tab:hover { color: var(--text); } }
.ds-tab[aria-selected='true'] { color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); }
.ds-tab:focus-visible { outline-offset: -2px; }

/* ---- dialog: a centred modal for browsing many things (a <dialog> opened with showModal) ----
   Phones get the same content as a full-height bottom sheet. Children: .ds-dialog-head, a body
   that scrolls (.ds-dialog-body). */
.ds-dialog {
  width: min(var(--dialog-w), calc(100vw - 2 * var(--gap))); max-width: none; max-height: 80vh; max-height: 80dvh; padding: 0;
  border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface-solid); color: var(--text); box-shadow: var(--shadow);
}
.ds-dialog[open] { display: flex; flex-direction: column; animation: ds-dialog-in var(--dur-slow) var(--ease); }
.ds-dialog::backdrop { background: var(--scrim); }
.ds-dialog-head { flex: none; display: flex; align-items: center; gap: var(--s-3); padding: var(--s-5) var(--s-5) var(--s-3) var(--s-8); }
.ds-dialog-head h2 { flex: 1; font-size: var(--fs-2xl); font-weight: var(--fw-bold); letter-spacing: -0.01em; }
.ds-dialog-body { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: var(--s-2) var(--s-3) var(--s-5); }
@keyframes ds-dialog-in { from { opacity: 0; transform: translateY(8px) scale(0.99); } }
@media (max-width: 720px) {
  .ds-dialog {
    width: 100%; height: 92vh; height: 92dvh; max-height: none; margin: auto 0 0;
    border-radius: var(--r-sheet) var(--r-sheet) 0 0; border-bottom: 0; padding-bottom: var(--safe-bottom);
  }
  .ds-dialog[open] { animation-name: ds-sheet-in; }
  .ds-dialog-head { padding-left: var(--s-6); }
}

/* ---- a key on the keyboard, in a hint or the shortcut sheet --------------------------------- */
.ds-kbd {
  display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 var(--s-2);
  border: 1px solid var(--line-strong); border-radius: var(--r-xs); background: var(--surface-sunken);
  color: var(--text-dim); font: var(--fw-medium) var(--fs-xs)/1 var(--font); white-space: nowrap;
}

/* ---- section label ----------------------------------------------------------------------- */
.ds-label { font-size: 12px; font-weight: var(--fw-medium); color: var(--muted); }
.ds-empty { margin: 0; color: var(--muted); font-size: var(--fs-sm); }
/* the next step from an empty state: one or two buttons under the sentence */
.ds-empty-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-3); margin-top: var(--s-5); }

/* ---- spinner ----------------------------------------------------------------------------- */
.ds-spinner {
  display: inline-block; width: 11px; height: 11px; flex: none; border-radius: 50%;
  border: 1.5px solid var(--line-strong); border-top-color: var(--accent); animation: ds-spin 0.8s linear infinite;
}
@keyframes ds-spin { to { transform: rotate(360deg); } }

/* ---- skeleton: a block the size of what is coming; the feature sizes it ---------------------- */
.ds-skeleton { display: block; max-width: 100%; border-radius: var(--r-sm); background: var(--line); animation: ds-skeleton var(--dur-eq) ease-in-out infinite alternate; }
@keyframes ds-skeleton { to { opacity: 0.45; } }

/* ---- sheet: a side panel on desktop, a bottom sheet on phones ------------------------------
   Desktop placement is the feature's job. On phones every .ds-sheet docks to the bottom edge,
   clears the home indicator and shows a grab handle. The doubled class outranks feature CSS;
   !important beats the inline position a dragged desktop panel leaves behind. A feature sets
   --sheet-pad-b for its own bottom padding. */
@media (max-width: 720px) {
  .ds-sheet.ds-sheet {
    position: fixed; top: auto !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    background: var(--surface-solid); backdrop-filter: none; -webkit-backdrop-filter: none;
    /* the middle height (half): as tall as the content, up to half the screen (audit item 6) */
    width: auto !important; height: auto !important; max-height: 50vh !important; max-height: 50dvh !important; resize: none;
    border-radius: var(--r-sheet) var(--r-sheet) 0 0; border-bottom: 0;
    padding-bottom: calc(var(--sheet-pad-b, 0px) + var(--safe-bottom)); animation: ds-sheet-in var(--dur-slow) var(--ease);
  }
  /* the grab handle; sheet.ts makes the top strip tap- and drag-able between three heights:
     half (how every sheet opens: its content's height, up to half the screen; the details sheet opens at summary), full, and peek */
  .ds-sheet::before {
    /* a 4px pill in a 12px box, so the swipe-up hint has room to bend it into an arrow */
    content: ''; display: block; flex: none; width: 36px; height: 12px; margin: calc(var(--s-2) - 4px) auto -4px; background: var(--line-strong);
    clip-path: inset(4px 0 round 2px); cursor: grab;
  }
  /* The swipe-up hint (spec 2026-11-28 "Swipe-up hint"): the handle bends into a shallow arrow, eases back to a straight
     line as it rises, and settles; twice. A feature opts in with `animation: ds-grab-hint` on its sheet's ::before. */
  @keyframes ds-grab-hint {
    0%, 36%, 50%, 86%, 100% { clip-path: polygon(1px 4px, 18px 4px, 35px 4px, 36px 5px, 36px 7px, 35px 8px, 18px 8px, 1px 8px, 0 7px, 0 5px); }
    12%, 62% { clip-path: polygon(1px 6.5px, 18px 1.5px, 35px 6.5px, 36px 7.5px, 36px 9.5px, 35px 10.5px, 18px 5.5px, 1px 10.5px, 0 9.5px, 0 7.5px); background: var(--muted); }
    0%, 12%, 50%, 62%, 100% { transform: translateY(0); }
    36%, 86% { transform: translateY(-4px); }
    0%, 50%, 100% { background: var(--line-strong); }
  }
  .ds-sheet.ds-sheet[data-snap='peek'] { height: auto !important; max-height: var(--sheet-peek) !important; overflow: hidden; }
  .ds-sheet.ds-sheet[data-snap='full'] { height: 90vh !important; height: 90dvh !important; max-height: none !important; }
  /* summary: the details sheet's middle height (sheet.ts SUMMARY_CAP). Sized by its content, up to 40% of the screen, so the map keeps the rest. */
  .ds-sheet.ds-sheet[data-snap='summary'] { height: auto !important; max-height: 40vh !important; max-height: 40dvh !important; overflow: hidden; }
  @keyframes ds-sheet-in { from { transform: translateY(24px); opacity: 0; } }
}

/* ---- coarse pointers: everything tappable is at least --touch ------------------------------ */
@media (pointer: coarse) {
  .ds-chip, .ds-input { min-height: var(--touch); }
  .ds-btn { min-height: var(--touch); padding: 0 var(--s-6); }
  .ds-icon-btn, .ds-link { min-width: var(--touch); min-height: var(--touch); }
  .ds-pill { min-height: 36px; padding: 0 var(--s-5); }
  .ds-row, .ds-layer-row { min-height: var(--touch); }
  .ds-tab { height: var(--touch); }
  .ds-segmented label { height: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  /* One pass, not a 0.01 ms loop: endless animations (spinners, pulses) would strobe. */
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
  /* still bars instead of a flicker */
  .ds-eq i { animation: none; }
  .ds-eq i:nth-child(1) { transform: scaleY(0.6); }
  .ds-eq i:nth-child(3) { transform: scaleY(0.4); }
}

/* earthpane.com pages (site/build.mjs). Loaded after ds/tokens.css and ds/components.css; tokens
   only. The app pins the body to the viewport for the map; these pages scroll. */

html { scroll-padding-top: calc(var(--control) + var(--s-12)); } /* the sticky bar */
html, body { height: auto; overflow: visible; overflow-x: clip; }
body { font-size: var(--fs-xl); line-height: 1.6; color: var(--text-dim); }
h1, h2, h3 { color: var(--text); font-weight: var(--fw-bold); line-height: 1.15; letter-spacing: -0.01em; margin: 0; }
p { margin: 0 0 var(--s-8); }
a { color: var(--accent); }
strong { color: var(--text); font-weight: var(--fw-medium); }
img { display: block; max-width: 100%; height: auto; }
.muted { color: var(--muted); }

.wrap { width: 100%; max-width: var(--site-w); margin: 0 auto; padding: 0 var(--s-12); }
@media (max-width: 720px) { .wrap { padding: 0 var(--s-8); } }

.skip { position: absolute; left: var(--s-3); top: calc(-1 * var(--s-32)); z-index: var(--z-skip); padding: var(--s-3) var(--s-5); background: var(--accent); color: var(--accent-ink); border-radius: var(--r-sm); }
.skip:focus { top: var(--s-3); }

/* ---- top bar ---------------------------------------------------------------------------- */
.bar { position: sticky; top: 0; z-index: var(--z-bar); background: var(--surface); border-bottom: 1px solid var(--line); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); padding-top: var(--safe-top); }
.bar-in { display: flex; align-items: center; gap: var(--s-12); min-height: calc(var(--control) + var(--s-8)); }
.logo { display: inline-flex; align-items: center; gap: var(--s-3); color: var(--text); text-decoration: none; font-weight: var(--fw-bold); font-size: var(--fs-2xl); letter-spacing: -0.035em; } /* the app's wordmark */
.nav { display: flex; gap: var(--s-1); margin-right: auto; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a { display: inline-flex; align-items: center; height: var(--control-sm); padding: 0 var(--s-4); border-radius: var(--r-sm); color: var(--muted); text-decoration: none; font-size: var(--fs-lg); font-weight: var(--fw-medium); white-space: nowrap; transition: color var(--dur) var(--ease), background-color var(--dur) var(--ease); }
.nav a[aria-current='page'] { color: var(--text); background: var(--raise); }
@media (hover: hover) { .nav a:hover { color: var(--text); } }
/* The same page in other languages: one menu in the desktop bar, a list in the footer. */
.langs { display: flex; gap: var(--s-1); flex-wrap: wrap; margin: 0 calc(-1 * var(--s-3)); }
.langs a, .lang-list a { display: flex; align-items: center; min-height: var(--control-sm); padding: 0 var(--s-3); border-radius: var(--r-sm); color: var(--muted); text-decoration: none; font-size: var(--fs-lg); white-space: nowrap; }
.langs a[aria-current='true'], .lang-list a[aria-current='true'] { color: var(--text); background: var(--raise); }
@media (hover: hover) { .langs a:hover, .lang-list a:hover { color: var(--text); } }
@media (pointer: coarse) { .langs a, .lang-list a { min-height: var(--touch); } }
.lang-menu { position: relative; flex: none; order: 2; }
.lang-menu summary { display: flex; align-items: center; gap: var(--s-2); height: var(--control); padding: 0 var(--s-4); border: 1px solid var(--line); border-radius: var(--r-md); color: var(--text-dim); font-size: var(--fs-lg); cursor: pointer; list-style: none; }
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary::after { content: '▾'; color: var(--muted); }
.lang-list { position: absolute; right: 0; top: calc(100% + var(--s-1)); min-width: 100%; padding: var(--s-2); border: 1px solid var(--line-strong); border-radius: var(--r-md); background: var(--surface-solid); box-shadow: var(--shadow); }
.cta-sm { flex: none; }
.bar-main { display: contents; }
.bar .logo { order: 0; } .nav { order: 1; } .bar .cta-sm { order: 3; }
.foot-langs { grid-column: 1 / -1; }
/* Phones: only the logo row sticks, with no topic row under it. */
@media (max-width: 720px) {
  .bar, .bar-in { display: contents; }
  .bar-main { position: sticky; top: 0; z-index: var(--z-bar); display: flex; align-items: center; justify-content: space-between; min-height: calc(var(--control) + var(--s-8) + var(--safe-top)); padding: var(--safe-top) var(--s-8) 0; background: var(--surface-solid); border-bottom: 1px solid var(--line); }
  /* the topic links were cut off in a scrolling row above the hero; the page and the footer list them all */
  .nav { display: none; }
  .lang-menu { display: none; }
}

/* ---- hero ------------------------------------------------------------------------------- */
.hero { padding-top: var(--s-32); text-align: center; }
.hero--topic { padding-top: var(--s-16); }
.hero h1 { font-size: var(--fs-display); max-width: 14em; margin: 0 auto var(--s-12); letter-spacing: -0.025em; }
.hero--topic h1 { font-size: var(--fs-4xl); max-width: 22em; margin-bottom: var(--s-8); }
.lede { font-size: var(--fs-3xl); line-height: 1.5; max-width: var(--prose-w); margin: 0 auto var(--s-12); color: var(--text-dim); }
.hero--topic .lede { font-size: var(--fs-2xl); }
.live-dot { width: var(--s-3); height: var(--s-3); flex: none; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 0 var(--live); animation: pulse 2s var(--ease) infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 var(--live); } 70%, 100% { box-shadow: 0 0 0 var(--s-2) transparent; } }
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-5); }
.cta { height: var(--touch); padding: 0 var(--s-12); font-size: var(--fs-xl); border-radius: var(--r-md); }
.fine { margin: var(--s-8) 0 0; color: var(--muted); font-size: var(--fs-sm); }
.frame { margin: var(--s-24) 0 0; border: 1px solid var(--line-strong); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); background: var(--surface-solid); }

/* Home: the living globe (site/hero-globe.js) fills the right; copy sits on the left. The canvas is square and
   wider than the globe, so the orbits and the air glow have room. Without scripts, the picture in its noscript. */
.hero--home { position: relative; overflow: hidden; padding: 0; text-align: left; }
.hero-copy { position: relative; display: flex; flex-direction: column; justify-content: center; min-height: min(660px, 76svh); padding-block: var(--s-16); }
.hero--home h1 { max-width: 9.5em; margin: 0 0 var(--s-8); }
.hero--home .lede { max-width: 24em; margin: 0 0 var(--s-12); }
.hero--home .actions { justify-content: flex-start; }
.hero-globe { position: absolute; top: 50%; left: max(50%, calc(50% + var(--site-w) / 2 - 640px)); width: min(700px, calc(76svh + 140px)); max-width: none; aspect-ratio: 1; transform: translateY(-50%); } /* the globe is 72% of the canvas: it fits the hero's height */
.hero-globe canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; }
.hero-globe canvas:active { cursor: grabbing; }
.hero-globe img { width: 100%; height: 100%; mask-image: radial-gradient(closest-side, #000 91%, transparent); }
/* Phones: the globe first, whole, as the app opens; the copy under it. */
@media (max-width: 720px) {
  .hero-globe { position: relative; display: block; top: auto; left: 50%; width: min(104vw, 50svh); margin: calc(-1 * var(--s-8)) 0 calc(-1 * var(--s-16)); transform: translateX(-50%); }
  .hero-copy { min-height: 0; padding-block: var(--s-8); } .hero--home .lede { font-size: var(--fs-2xl); margin-bottom: var(--s-8); }
}
@media (min-width: 721px) and (max-width: 1100px) {
  .hero-globe { left: 52%; width: 580px; }
  .hero--home h1 { max-width: 7em; }
  .hero--home .lede { max-width: 17em; }
}

/* ---- the app's section label and its Watch row ------------------------------------------- */
.label, .sec:has(> .rows) > h2 { font: var(--fw-medium) var(--fs-sm)/1.4 var(--font-mono); letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim); }
.label { display: flex; align-items: center; gap: var(--s-3); margin: 0 0 var(--s-5); color: var(--muted); }
.icon { flex: none; }
.watches { display: flex; flex-wrap: wrap; gap: var(--s-3); }
.watch { display: inline-flex; align-items: center; gap: var(--s-3); min-height: var(--control); padding: 0 var(--s-5); border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface-solid); color: var(--text-dim); font-size: var(--fs-lg); font-weight: var(--fw-medium); text-decoration: none; white-space: nowrap; transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.watch--all { color: var(--text); }
@media (hover: hover) { .watch:hover { color: var(--text); border-color: var(--line-strong); } }
.watch--on, .watch--on:hover { color: var(--accent); border-color: var(--accent-ghost); background: linear-gradient(var(--accent-soft), var(--accent-soft)) var(--surface-solid); }
.watch:active { transform: translateY(1px); }
.watch:focus-visible, .row:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (pointer: coarse) { .watch { min-height: var(--touch); } }
/* Phones: one row that scrolls sideways, edge to edge, like the globe's. */
@media (max-width: 720px) {
  .watches { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 calc(-1 * var(--s-8)); padding: var(--s-1) var(--s-8); }
  .watches::-webkit-scrollbar { display: none; }
  .watch { flex: none; }
}

/* ---- sections --------------------------------------------------------------------------- */
.sec { padding-top: var(--s-32); }
.sec h2 { font-size: var(--fs-4xl); margin-bottom: var(--s-5); }
.sub { color: var(--muted); margin-bottom: var(--s-16); }
.sec > h2 + .faq, .sec > h2 + .layers, .sec > h2 + .steps { margin-top: var(--s-12); }
.end { text-align: center; padding-bottom: var(--s-8); }
.end h2 { margin-bottom: var(--s-12); }

.split { display: grid; grid-template-columns: 1fr 1.4fr; gap: var(--s-24); align-items: center; }
.split .frame { margin: 0; }
@media (max-width: 720px) { .split { grid-template-columns: 1fr; gap: var(--s-12); } }
/* a phone screenshot beside its words: narrow, in a phone-shaped frame */
.split--phone { grid-template-columns: auto 1fr; }
.phone-frame { margin: 0; width: 280px; max-width: 100%; border: 6px solid var(--line-strong); border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); background: var(--surface-solid); }
.phone-frame img { display: block; width: 100%; height: auto; }
@media (max-width: 720px) { .split--phone { grid-template-columns: 1fr; justify-items: center; } .split--phone > div { justify-self: stretch; } }

/* Comparison pages: a sourced table that scrolls sideways inside its box on phones, never the page. */
.split--even { grid-template-columns: 1fr 1fr; align-items: start; }
@media (max-width: 720px) { .split--even { grid-template-columns: 1fr; } }
.compare-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface-solid); }
.compare { width: 100%; min-width: 34em; border-collapse: collapse; font-size: var(--fs-lg); }
.compare th, .compare td { padding: var(--s-6) var(--s-8); border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: 0; }
.compare thead th { color: var(--text); font-weight: var(--fw-bold); }
.compare tbody th { color: var(--text-dim); font-weight: var(--fw-medium); width: 34%; }
.compare td { color: var(--muted); }
.compare td:nth-child(2) { color: var(--text); }
/* Phones: both answers under the feature's name, each saying whose it is. */
@media (max-width: 560px) {
  .compare { min-width: 0; }
  .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: auto; }
  .compare thead { display: none; }
  .compare tr { padding: var(--s-5) var(--s-8); border-bottom: 1px solid var(--line); }
  .compare tbody tr:last-child { border-bottom: 0; }
  .compare tbody th, .compare td { width: auto; padding: 0; border: 0; }
  .compare tbody th { color: var(--text); }
  .compare td { margin-top: var(--s-2); }
  .compare td::before { content: attr(data-who); display: block; color: var(--muted); font-size: var(--fs-md); }
}
.ticks { margin: 0; padding-left: 1.2em; color: var(--text-dim); }
.ticks li { margin-bottom: var(--s-4); }
.sources-list { padding-left: 1.2em; }

.crumbs { display: flex; gap: var(--s-3); padding-top: var(--s-12); font-size: var(--fs-md); color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; }
@media (hover: hover) { .crumbs a:hover { color: var(--text); } }

/* ---- lists of pages: panels with the app's icon, a name and one line --------------------- */
.rows { list-style: none; margin: 0 0 var(--s-12); padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, var(--side-w)), 1fr)); gap: var(--s-3); }
.row { display: grid; grid-template-columns: auto minmax(0, 1fr); align-content: center; column-gap: var(--s-5); height: 100%; min-height: var(--touch); padding: var(--s-5) var(--s-6); border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface-solid); text-decoration: none; transition: border-color var(--dur) var(--ease); }
.row .icon { grid-row: span 2; align-self: start; margin-top: var(--s-1); color: var(--accent); }
.row-name { grid-column: 2; color: var(--text); font-weight: var(--fw-medium); }
.row-line { grid-column: 2; color: var(--muted); font-size: var(--fs-lg); line-height: 1.4; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.row-n { color: var(--muted); font: var(--fw-regular) var(--fs-sm) var(--font-mono); font-variant-numeric: tabular-nums; }
@media (hover: hover) { .row:hover { border-color: var(--line-strong); } }
.row:active { background: var(--raise); }
.sources { max-width: 52em; color: var(--text-dim); line-height: 1.9; }

/* ---- layer rows ------------------------------------------------------------------------- */
.layers { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.layer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: var(--s-1) var(--s-12); padding: var(--s-8) 0; border-bottom: 1px solid var(--line); }
.layer-name { color: var(--text); font-weight: var(--fw-medium); }
.layer-blurb { color: var(--text-dim); }
.layer-meta { grid-column: 2; display: flex; align-items: center; gap: var(--s-3); color: var(--muted); font-size: var(--fs-md); }
.layer-meta .live-dot { animation: none; width: var(--s-2); height: var(--s-2); }
@media (max-width: 720px) { .layer { grid-template-columns: 1fr; } .layer-meta { grid-column: 1; } }

/* ---- steps and questions ---------------------------------------------------------------- */
.steps { counter-reset: step; list-style: none; margin: 0 0 var(--s-12); padding: 0; display: grid; gap: var(--s-8); max-width: var(--prose-w); }
.steps li { counter-increment: step; position: relative; padding-left: var(--s-24); min-height: var(--control-sm); }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: var(--control-sm); height: var(--control-sm); border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: var(--fw-bold); font-size: var(--fs-lg); }

.faq { max-width: calc(var(--prose-w) + var(--s-32)); border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: var(--s-8); min-height: var(--touch); padding: var(--s-6) 0; cursor: pointer; color: var(--text); font-weight: var(--fw-medium); list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; flex: none; color: var(--accent); font-size: var(--fs-2xl); transition: transform var(--dur) var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 var(--s-8); max-width: var(--prose-w); }

.prose { text-align: left; max-width: calc(var(--prose-w) + var(--s-24)); }
.prose h1, .prose .lede { margin-left: 0; }
.prose h2 { font-size: var(--fs-3xl); margin: var(--s-16) 0 var(--s-5); }

/* ---- footer ----------------------------------------------------------------------------- */
.foot { margin-top: var(--s-32); padding: var(--s-24) 0 calc(var(--s-24) + var(--safe-bottom)); border-top: 1px solid var(--line); background: var(--surface-sunken); font-size: var(--fs-lg); }
.foot-in { display: grid; grid-template-columns: 1.2fr 2fr 1fr; gap: var(--s-16); }
.foot h2 { font: var(--fw-medium) var(--fs-sm)/1.4 var(--font-mono); text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); margin-bottom: var(--s-5); }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot nav:first-of-type ul { columns: 2; column-gap: var(--s-12); }
.foot li { margin-bottom: var(--s-2); break-inside: avoid; }
/* finger-sized footer links on touch screens (the audit found a third of the phone's links under 32 px) */
@media (pointer: coarse) { .foot li { margin-bottom: 0; } .foot li a { display: flex; align-items: center; min-height: var(--touch); } .crumbs a { display: inline-flex; align-items: center; min-height: var(--touch); } }
.foot li a { color: var(--text-dim); text-decoration: none; }
@media (hover: hover) { .foot li a:hover { color: var(--accent); } }
.foot .logo { margin-bottom: var(--s-5); }
@media (max-width: 720px) { .foot-in { grid-template-columns: 1fr; } }
@media (pointer: coarse) { .foot li a { display: inline-block; padding: var(--s-2) 0; } }
