/*
 * TripHub landing page — the ONLY stylesheet, and the only subresource of any
 * kind this page loads.
 *
 * ⚠ CONSTRAINTS THAT ARE ENFORCED, NOT ASPIRATIONAL:
 *
 *  - NO @import, NO url() to another origin, NO webfont. The landing site's CSP
 *    (infra/caddy/sites.d/landing.caddyfile.example) is
 *    `default-src 'none'; style-src 'self'; font-src 'none'; script-src 'none'`,
 *    so a CDN font or a remote background image is dropped by the browser with
 *    nothing but a console entry. The type stack below is therefore the system
 *    stack, which also means zero requests and no layout shift.
 *
 *  - NO JavaScript anywhere on this page, so the dark theme is driven by
 *    `prefers-color-scheme` ONLY. This is deliberately DIFFERENT from the app,
 *    which uses a `.dark` class toggled by React (apps/web/src/index.css). The
 *    landing page cannot read the app's stored preference — it is a different
 *    origin with a different localStorage — so it follows the OS instead of
 *    pretending to know.
 *
 * ── THE PALETTE, AND WHY IT HAS A HUE (DEC-0251) ────────────────────────────
 *
 * This file used to copy the app's slate tokens verbatim, which made the page
 * entirely neutral: there was NO accent colour anywhere in it. Two things
 * followed, and the second one was reported as a bug.
 *
 *   1. It read as unfinished — a wireframe someone forgot to skin.
 *   2. The primary button in dark mode was `--btn-primary-bg: #f1f5f9` on a
 *      `#020617` page. That is a near-WHITE rectangle. It passed every contrast
 *      check (its label was legible), it was semantically a link, and it still
 *      did not read as a button, because in a page with no colour at all there
 *      was nothing to mark it as the one thing you are meant to press. It was
 *      reported as "a white square, not a button". THE DESIGN WAS THE DEFECT —
 *      not the CSS delivery, not the CSP, not a missing custom property.
 *
 * So the page now has its own brand hue: a deep ocean teal, warmed by a single
 * amber accent used sparingly. Teal because this is a travel product and it is
 * NOT the generic SaaS indigo; one warm accent because a page in a single hue
 * is only marginally less monotonous than a page in none. The neutrals stay in
 * the slate/navy family so the page still looks related to the app it fronts.
 *
 * ⚠ THE PRIMARY BUTTON IS A COLOURED FILL IN BOTH THEMES, and that is the fix.
 * Dark mode uses a BRIGHT teal fill with near-black text rather than the
 * light-mode teal, because a dark-on-dark button is invisible and a white one
 * is what caused the original report. Do not "simplify" the two themes back to
 * one neutral value.
 *
 * ⚠ EVERY COLOUR PAIR BELOW IS MEASURED, NOT EYEBALLED.
 * `apps/landing/test/contrast.test.js` parses THIS FILE, resolves the tokens and
 * asserts the WCAG 2.2 ratios on every CI run — normal text ≥ 4.5:1 (1.4.3),
 * UI boundaries and graphics ≥ 3:1 (1.4.11). It also asserts the ROLE of the
 * primary button — that `--btn-primary-bg` is CHROMATIC (channel spread ≥ 40)
 * and is not simply `--fg` — because contrast alone is exactly what the
 * white-square defect passed, with flying colours, in both themes.
 * If you change a hex here, run `pnpm --filter @triphub/landing test`.
 *
 * ⚠ TOKENS MUST STAY LITERAL HEX. The test resolves `--name: #rrggbb` and
 * refuses anything else (a `var()` or a `color-mix()` would make it measure a
 * string instead of a colour, and pass). Computed colours are fine in RULES,
 * just not in the two token blocks. The parser anchors on `:root {` at the
 * start of a line and on the dark media query written exactly as it is below —
 * reformatting either one fails the test loudly rather than silently measuring
 * nothing.
 */

:root {
  color-scheme: light dark;

  /* Surfaces, lightest to deepest. */
  --bg: #ffffff;
  --bg-alt: #f2f7f8;
  --card: #ffffff;
  --panel: #e9f1f3;

  /* Ink. */
  --fg: #0a1a21;
  --fg-muted: #4c5f69;

  /* Brand: ocean teal. `--brand` is the link/graphic colour and passes 4.5:1
   * as TEXT on every surface above, so it can be used for prose links too. */
  --brand: #0a6a75;
  --brand-strong: #075058;
  --brand-tint: #ddf0f2;

  /* The one warm accent. Used for the eyebrow dot and the "Plan B" chip and
   * essentially nowhere else — its scarcity is what makes it work. */
  --accent: #a2510b;
  --accent-tint: #fdf0e3;

  /* Lines. `--border` is decorative (card edges, rules). `--border-strong` is
   * the one that has to clear 3:1 against the page, because it is the visible
   * BOUNDARY of the ghost button — a control whose only outline it is. */
  --border: #d3e1e5;
  --border-strong: #5f7a87;

  /* Controls. */
  --btn-primary-bg: #0a6a75;
  --btn-primary-fg: #ffffff;
  --btn-primary-bg-hover: #075058;
  --focus: #0a6a75;

  --shadow: 0 1px 2px rgb(10 26 33 / 5%), 0 10px 30px -12px rgb(10 26 33 / 18%);
  --shadow-lift: 0 2px 4px rgb(10 26 33 / 6%), 0 18px 40px -16px rgb(10 26 33 / 26%);

  /* Translucent sticky header. Contrast is unaffected in practice: every
   * surface that can scroll underneath it is `--bg`, `--bg-alt` or `--card`,
   * and the muted text passes 4.5:1 on all three. */
  --header-bg: rgb(255 255 255 / 82%);

  /* Decorative hero wash. The alphas are not arbitrary — text was measured
   * against the COMPOSITE of each glow over `--bg-alt`, not against `--bg-alt`
   * alone, and `--fg-muted` still clears 4.5:1 at these values (5.36 teal /
   * 5.55 warm). Raising them is a contrast change, not a taste change. */
  --glow-brand: rgb(10 106 117 / 10%);
  --glow-warm: rgb(162 81 11 / 8%);

  --shell: 72rem;
  --radius: 0.875rem;
  --radius-sm: 0.5rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #05141a;
    --bg-alt: #08202a;
    --card: #0b2934;
    --panel: #0b2934;

    --fg: #e6f1f4;
    --fg-muted: #9db3bd;

    --brand: #55d3dd;
    --brand-strong: #7ee0e8;
    --brand-tint: #103b47;

    --accent: #f2a95c;
    --accent-tint: #3a2611;

    --border: #1a3c48;
    --border-strong: #537f90;

    /* ⚠ NOT a near-white fill. See the header comment: this is the exact token
     * that produced the "white square, not a button" report. A bright teal on
     * near-black text reads unambiguously as a control. */
    --btn-primary-bg: #3fc3ce;
    --btn-primary-fg: #04181d;
    --btn-primary-bg-hover: #6bd8e1;
    --focus: #55d3dd;

    --shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 10px 30px -12px rgb(0 0 0 / 60%);
    --shadow-lift: 0 2px 4px rgb(0 0 0 / 45%), 0 18px 40px -16px rgb(0 0 0 / 70%);

    --header-bg: rgb(5 20 26 / 82%);

    --glow-brand: rgb(85 211 221 / 12%);
    --glow-warm: rgb(242 169 92 / 9%);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    'Noto Sans',
    sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3 {
  line-height: 1.15;
  letter-spacing: -0.022em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

p {
  margin: 0 0 1em;
  text-wrap: pretty;
}

a {
  color: inherit;
}

abbr[title] {
  text-decoration: underline dotted;
  cursor: help;
}

svg {
  display: block;
}

/* ── Focus: visible on every interactive element, in both themes ──────────── */
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 0.25rem;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 10;
  padding: 0.75rem 1rem;
  background: var(--btn-primary-bg);
  color: var(--btn-primary-fg);
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 600;
}

.skip-link:focus {
  left: 0;
}

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* ── The brand rule ───────────────────────────────────────────────────────────
 * A 3px full-bleed gradient hairline above the header. It is the cheapest
 * possible "this page has a brand": one element, no request, and it is the only
 * place on the page where both hues touch.
 */
.brand-rule {
  height: 3px;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand) 45%, var(--accent) 100%);
}

/* ── Header ───────────────────────────────────────────────────────────────── */

.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--header-bg);
  position: sticky;
  top: 0;
  z-index: 5;
}

/* Progressive: browsers without backdrop-filter get the translucent colour and
 * a slightly busier scroll, which is a cosmetic difference, not a broken page. */
@supports (backdrop-filter: blur(12px)) or (-webkit-backdrop-filter: blur(12px)) {
  .site-header {
    -webkit-backdrop-filter: blur(12px) saturate(140%);
    backdrop-filter: blur(12px) saturate(140%);
  }
}

.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.5rem;
  min-height: 4rem;
  padding-block: 0.75rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 650;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
  text-decoration: none;
}

/* The mark sits in a tinted brand chip rather than floating as a bare glyph —
 * it gives the wordmark something to sit against at 375px, where the header is
 * otherwise a line of undifferentiated text. */
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  flex: none;
  border-radius: 0.625rem;
  background: var(--brand-tint);
  color: var(--brand);
}

.brand-mark svg {
  width: 1.25rem;
  height: 1.25rem;
}

.brand-mark-sm {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 0.4375rem;
}

.brand-mark-sm svg {
  width: 0.9375rem;
  height: 0.9375rem;
}

.brand-name {
  white-space: nowrap;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.25rem;
  margin-inline-start: auto;
}

.site-nav a {
  color: var(--fg-muted);
  text-decoration: none;
  padding: 0.5rem 0;
  font-size: 0.9375rem;
  font-weight: 500;
}

.site-nav a:hover {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 0.3em;
}

.site-nav .button {
  color: var(--btn-primary-fg);
}

.site-nav .button:hover {
  color: var(--btn-primary-fg);
  text-decoration: none;
}

/* ── Buttons ──────────────────────────────────────────────────────────────── */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem; /* 44px — pointer target floor (WCAG 2.2 AA, 2.5.8) */
  padding: 0.625rem 1.125rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  transition:
    background-color 140ms ease-out,
    border-color 140ms ease-out,
    box-shadow 140ms ease-out,
    transform 140ms ease-out;
}

.button-primary {
  background: var(--btn-primary-bg);
  color: var(--btn-primary-fg);
  box-shadow: 0 1px 2px rgb(10 26 33 / 12%);
}

.button-primary:hover {
  background: var(--btn-primary-bg-hover);
}

/* Ghost buttons are outlined controls whose ONLY visual boundary is the border,
 * so it uses `--border-strong` (≥3:1 against both `--bg` and `--bg-alt`, WCAG
 * 1.4.11) rather than the decorative `--border` used on card edges. */
.button-ghost {
  border-color: var(--border-strong);
  color: var(--fg);
  background: transparent;
}

.button-ghost:hover {
  background: var(--panel);
  border-color: var(--brand);
  color: var(--brand);
}

.button-lg {
  min-height: 3rem;
  padding: 0.75rem 1.5rem;
  font-size: 1.0625rem;
}

.cta-row .button-primary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

/* ── Hero ─────────────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: clamp(3rem, 8vw, 6rem);
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

/*
 * The wash. Two soft radial glows plus a fade back to the page colour at the
 * bottom edge, so the hero dissolves into the next section instead of ending
 * on a hard band. Purely decorative and behind everything (`z-index: -1`), and
 * the text above it was measured against the composite — see `--glow-brand`.
 */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(60rem 28rem at 12% -10%, var(--glow-brand), transparent 60%),
    radial-gradient(42rem 24rem at 92% 8%, var(--glow-warm), transparent 62%),
    linear-gradient(180deg, transparent 55%, var(--bg) 100%);
}

/*
 * ⚠ NO `max-width` ON THIS ELEMENT. It sits ON the `.shell`, so a narrower
 * max-width would re-centre the hero inside the page and leave its left edge
 * indented relative to every section below it (measured, before the redesign:
 * the h1 started at x=292 while every `<h2>` started at x=164 on a 1440px
 * viewport). The line length is constrained by `.lede` / `.hero-note` instead.
 */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2.5rem, 5vw, 3.5rem);
  align-items: center;
}

@media (min-width: 64rem) {
  .hero-grid {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  }
}

/* A grid item defaults to `min-width: auto`, which lets an unbreakable string
 * push the column wider than its track and skew the two-column hero. */
.hero-copy {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--fg-muted);
}

/* The eyebrow as a bordered pill gives the hero a place to start; the dot is
 * the smallest possible use of the warm accent. */
.eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem 0.375rem 0.625rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--card);
  color: var(--fg-muted);
}

.eyebrow-dot {
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

.hero h1 {
  font-size: clamp(2.125rem, 5.6vw, 3.5rem);
  margin-bottom: 1rem;
}

.lede {
  font-size: clamp(1.0625rem, 2.2vw, 1.25rem);
  color: var(--fg-muted);
  max-width: 46ch;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-block: 2rem 1.25rem;
}

.hero-note {
  margin: 0;
  color: var(--fg-muted);
  font-size: 0.9375rem;
  max-width: 46ch;
}

/* ── Hero preview card ──────────────────────────────────────────────────────
 * Built from the same card / chip / dual-time vocabulary as the rest of the
 * page, deliberately: it is a small piece of the product rather than a picture
 * of one, so it re-themes and re-flows with everything else and cannot go
 * stale. `aria-hidden` in the markup — see the note there.
 */

.hero-preview {
  display: flex;
  justify-content: center;
}

.preview-card {
  width: 100%;
  max-width: 26rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  padding: 1.25rem;
  animation: rise 520ms ease-out both;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(0.75rem);
  }
}

.preview-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--border);
}

.preview-title {
  font-weight: 650;
  letter-spacing: -0.01em;
}

.preview-dates {
  font-size: 0.8125rem;
  color: var(--fg-muted);
  white-space: nowrap;
}

.preview-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.25rem;
}

.preview-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-block: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.preview-row:last-child {
  border-bottom: 0;
}

.row-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: none;
  border-radius: var(--radius-sm);
  background: var(--brand-tint);
  color: var(--brand);
}

.row-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.row-body {
  display: grid;
  gap: 0.125rem;
  min-width: 0;
}

.row-title {
  font-weight: 600;
  font-size: 0.9375rem;
}

.row-meta {
  font-size: 0.8125rem;
  color: var(--fg-muted);
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 0.125rem 0.5rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.chip-accent {
  background: var(--accent-tint);
  color: var(--accent);
}

.preview-foot {
  margin-top: 0.875rem;
  padding-top: 0.875rem;
  border-top: 1px dashed var(--border);
}

.dual-time {
  display: grid;
  gap: 0.125rem;
}

.dual-primary {
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.dual-secondary {
  font-size: 0.8125rem;
  color: var(--fg-muted);
  font-variant-numeric: tabular-nums;
}

/* ── Bands ────────────────────────────────────────────────────────────────── */

.band {
  padding-block: clamp(3.5rem, 7vw, 5.5rem);
  border-bottom: 1px solid var(--border);
}

.band-alt {
  background: var(--bg-alt);
}

.band h2 {
  font-size: clamp(1.75rem, 3.6vw, 2.375rem);
}

/* A short brand-coloured kicker above each section heading. It is what gives
 * the page a rhythm at a glance instead of eight identical text blocks. */
.section-eyebrow {
  margin: 0 0 0.625rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--brand);
}

.section-eyebrow::before {
  content: '';
  width: 1.5rem;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
  flex: none;
}

.section-lede {
  color: var(--fg-muted);
  max-width: 56ch;
  margin-bottom: 2.5rem;
  font-size: 1.0625rem;
}

/* ── Cards ────────────────────────────────────────────────────────────────── */

.cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
}

.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition:
    transform 160ms ease-out,
    box-shadow 160ms ease-out,
    border-color 160ms ease-out;
}

/* Hover is an affordance-free flourish here — these cards are not links — so it
 * stays subtle and does nothing a keyboard user is missing. */
.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lift);
  border-color: var(--border-strong);
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 1rem;
  border-radius: var(--radius-sm);
  background: var(--brand-tint);
  color: var(--brand);
}

.card-icon svg {
  width: 1.375rem;
  height: 1.375rem;
}

.card h3 {
  font-size: 1.0625rem;
  margin-bottom: 0.5rem;
}

.card p {
  margin: 0;
  color: var(--fg-muted);
  font-size: 0.9375rem;
}

/* The "what it is not" trio: no fill, no shadow, no hover — visually quieter
 * than the feature grid on purpose, because it is a list of absences. */
.card-plain {
  box-shadow: none;
  background: transparent;
  border-style: dashed;
}

.card-plain:hover {
  transform: none;
  box-shadow: none;
  border-color: var(--border);
}

.card-cross {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.875rem;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--fg-muted);
}

.card-cross svg {
  width: 1rem;
  height: 1rem;
}

.cards-3 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr));
}

/* ── Split sections ───────────────────────────────────────────────────────── */

.split {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  align-items: start;
}

@media (min-width: 56rem) {
  .split {
    grid-template-columns: 1.25fr 1fr;
    gap: 3.5rem;
  }
}

.split p {
  color: var(--fg-muted);
  max-width: 60ch;
}

.split-copy h2 {
  font-size: clamp(1.75rem, 3.6vw, 2.375rem);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.panel-label {
  margin: 0 0 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.6875rem;
  font-weight: 700;
  color: var(--fg-muted);
}

.panel-primary {
  margin: 0 0 0.25rem;
  font-size: 1.625rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.panel-secondary {
  margin: 0;
  color: var(--fg-muted);
  font-size: 0.9375rem;
}

/* ── The boarding-pass panel ────────────────────────────────────────────────
 * The dual-clock demo is the single most on-message thing on this page, so it
 * is drawn as a ticket rather than as a paragraph: a tear line with two punched
 * notches, and the two clocks stacked below it. The notches are coloured with
 * `--bg-alt` because this panel only ever sits inside `.band-alt`.
 */
.panel-ticket {
  position: relative;
  overflow: hidden;
}

.ticket-tear {
  position: relative;
  margin-block: 1.25rem;
  border-top: 2px dashed var(--border);
}

.ticket-tear::before,
.ticket-tear::after {
  content: '';
  position: absolute;
  top: -0.6875rem;
  width: 1.375rem;
  height: 1.375rem;
  border-radius: 50%;
  background: var(--bg-alt);
  border: 1px solid var(--border);
}

.ticket-tear::before {
  left: -2.1875rem;
}

.ticket-tear::after {
  right: -2.1875rem;
}

.clock-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.clock-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.clock-label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: var(--fg-muted);
}

.clock-value {
  font-variant-numeric: tabular-nums;
  font-size: 0.9375rem;
  color: var(--fg-muted);
}

/* On the trip's start date the destination clock becomes the headline — this is
 * the state the panel is showing. */
.clock-row-lead .clock-value {
  color: var(--fg);
  font-weight: 650;
}

.clock-row-lead .clock-label {
  color: var(--brand);
}

.spec-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.625rem;
  font-size: 0.9375rem;
  color: var(--fg-muted);
}

.spec-list li {
  display: grid;
  grid-template-columns: 6rem 1fr;
  gap: 0.75rem;
  align-items: baseline;
}

.spec-list span {
  color: var(--brand);
  font-weight: 700;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ── Closer ───────────────────────────────────────────────────────────────── */

.closer {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: clamp(3.5rem, 7vw, 5.5rem);
  background: var(--bg-alt);
}

.closer::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(46rem 22rem at 50% 120%, var(--glow-brand), transparent 65%),
    radial-gradient(30rem 16rem at 8% -20%, var(--glow-warm), transparent 60%);
}

.closer-inner {
  max-width: 44rem;
  text-align: center;
}

.cta-row-center {
  justify-content: center;
}

/* ── The 404 page ───────────────────────────────────────────────────────────
 * Reuses `.closer` so the error page is unmistakably the same site, rather than
 * the unstyled default that a 404 usually is. `closer-page` just gives it the
 * full viewport it has to fill on its own.
 */
.closer-page {
  display: flex;
  align-items: center;
  min-height: 70vh;
}

.code-mark {
  margin: 0 0 0.75rem;
  font-size: clamp(2.75rem, 9vw, 4.5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  color: var(--brand);
}

/* h1 as well as h2: the 404 page reuses this section as its whole body, and its
 * heading is the document's h1. */
.closer h1,
.closer h2 {
  font-size: clamp(1.75rem, 3.6vw, 2.375rem);
}

.closer p {
  color: var(--fg-muted);
  margin-bottom: 1.75rem;
}

/* ── Footer ───────────────────────────────────────────────────────────────── */

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg);
  padding-block: 2.5rem;
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.75rem 2rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  font-weight: 650;
}

.footer-note {
  margin: 0;
  color: var(--fg-muted);
  font-size: 0.875rem;
  max-width: 48ch;
}

.footer-nav {
  margin-inline-start: auto;
}

.footer-nav a {
  color: var(--brand);
  font-size: 0.875rem;
  font-weight: 600;
  text-underline-offset: 0.25em;
}

/* ── Motion ───────────────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── Narrow screens (375px is the reference width) ────────────────────────── */

@media (max-width: 26rem) {
  .site-header {
    position: static; /* a sticky header eats too much of a 667px-tall viewport */
  }

  .header-row {
    gap: 0.5rem;
  }

  .site-nav {
    width: 100%;
    margin-inline-start: 0;
    justify-content: space-between;
    gap: 0.75rem;
  }

  .site-nav .button {
    padding-inline: 0.875rem;
  }

  .cta-row .button {
    width: 100%;
  }

  .spec-list li {
    grid-template-columns: 1fr;
    gap: 0;
  }

  /* The ticket notches hang outside the panel; at 375px the panel is close
   * enough to the viewport edge that they would be clipped asymmetrically, so
   * the tear line becomes a plain dashed rule. */
  .ticket-tear::before,
  .ticket-tear::after {
    display: none;
  }

  .preview-card {
    padding: 1rem;
  }

  .footer-nav {
    margin-inline-start: 0;
  }
}

/* ── Forced colors (Windows high contrast) ────────────────────────────────────
 * In forced-colors the entire palette above is replaced by the user's own, so
 * everything that carried meaning through COLOUR has to re-acquire it through a
 * border. The decorative washes are removed outright — a `radial-gradient` is
 * not re-mapped, so it survives as an arbitrary colour behind system-coloured
 * text, which is the one thing this mode exists to prevent.
 */
@media (forced-colors: active) {
  .card,
  .panel,
  .button,
  .card-icon,
  .row-icon,
  .brand-mark,
  .eyebrow-pill,
  .chip {
    border: 1px solid CanvasText;
  }

  .hero::before,
  .closer::before,
  .brand-rule {
    display: none;
  }

  .site-header {
    background: Canvas;
  }
}
