/* Routes catalogue site. Brand = the app's Tailwind v4 palette. Design language: Flighty formula
   (huge near-black display type on white, floating cards, layered shadows, dark contrast band). */
:root {
  /* Tailwind v4 colour tokens (exact values from tailwindcss v4, matching the app's Palette.swift) */
  --color-blue-50: #EFF6FF; --color-blue-100: #DBEAFE; --color-blue-400: #51A2FF;
  --color-blue-500: #2B7FFF; --color-blue-600: #155DFC; --color-blue-700: #1447E6;
  --color-blue-800: #193CB8; --color-blue-900: #1C398E;
  --color-slate-50: #F8FAFC; --color-slate-100: #F1F5F9; --color-slate-200: #E2E8F0;
  --color-slate-300: #CAD5E2; --color-slate-400: #90A1B9; --color-slate-500: #62748E;
  --color-slate-600: #45556C; --color-slate-700: #314158; --color-slate-800: #1D293D;
  --color-slate-900: #0F172B;
  --color-amber-500: #FE9A00; --color-red-500: #FB2C36; --color-red-800: #9F0712;
  --color-green-600: #00A63E; --color-emerald-600: #009966;
  /* Tailwind radius + spacing scale (v4: --radius-xl=12, 2xl=16, 3xl=24; spacing unit 4px) */
  --radius-lg: 8px; --radius-xl: 12px; --radius-2xl: 16px; --radius-3xl: 24px;
  --spacing-1: 4px; --spacing-2: 8px; --spacing-3: 12px; --spacing-4: 16px;
  --spacing-5: 20px; --spacing-6: 24px; --spacing-8: 32px; --spacing-10: 40px;

  /* Legacy aliases (existing rules reference these) */
  --blue-50: var(--color-blue-50); --blue-400: var(--color-blue-400); --blue-500: var(--color-blue-500);
  --blue-600: var(--color-blue-600); --blue-700: var(--color-blue-700); --blue-800: var(--color-blue-800);
  --blue-900: var(--color-blue-900);
  --slate-100: var(--color-slate-100); --slate-200: var(--color-slate-200); --slate-300: var(--color-slate-300);
  --slate-400: var(--color-slate-400); --slate-500: var(--color-slate-500); --slate-600: var(--color-slate-600);
  --slate-700: var(--color-slate-700); --slate-800: var(--color-slate-800);
  --ink: #0B1220; --paper: #FFFFFF; --page: #FFFFFF; --night: #0C1222;
  --r-l: var(--radius-3xl); --r-m: var(--radius-2xl); --r-s: var(--radius-xl);
  --shadow-card: 0 1px 2px rgba(11,18,32,0.04), 0 2px 8px rgba(11,18,32,0.04), 0 0 0 1px rgba(11,18,32,0.06);
  --shadow-lift: 0 2px 4px rgba(11,18,32,0.05), 0 10px 28px rgba(11,18,32,0.10), 0 0 0 1px rgba(11,18,32,0.07);
  --shadow-float: 0 2px 6px rgba(11,18,32,0.07), 0 18px 44px rgba(11,18,32,0.14);
  --font-sans: 'Geist', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --display: var(--font-sans);
}
@font-face {
  font-family: 'Geist';
  src: url('/geist-vf.woff2') format('woff2-variations');
  font-weight: 100 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Geist Mono';
  src: url('/geist-mono-vf.woff2') format('woff2-variations');
  font-weight: 100 900; font-style: normal; font-display: swap;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font: 17px/1.62 var(--font-sans);
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--blue-100, #DBEAFE); color: var(--blue-900); }
.wrap { max-width: 1060px; margin: 0 auto; padding: 0 22px; }
a { color: var(--blue-700); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, .btn:focus-visible { outline: 3px solid var(--blue-400); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.12; letter-spacing: -0.028em; text-wrap: balance; margin: 0 0 10px; font-weight: 800; }
h1 { font-size: clamp(30px, 5.4vw, 56px); }
.page-title { font-size: clamp(30px, 4.4vw, 42px); }
h2 { font-size: 26px; margin-top: 52px; }
h3 { font-size: 18px; font-weight: 700; }
p { margin: 0 0 14px; text-wrap: pretty; }
ul { padding-left: 22px; }

/* Header / footer */
@font-face {
  font-family: 'Stack Sans Headline';
  src: url('/stack-sans-headline-vf.woff2') format('woff2-variations');
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}
.brand-name { font-family: 'Stack Sans Headline', var(--display); font-weight: 720; letter-spacing: -0.015em; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -48px; z-index: 50; background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 999px; font-weight: 640; transition-property: top; transition-duration: 0.15s; }
.skip-link:focus-visible { top: 12px; }
.site-header { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,0.82); -webkit-backdrop-filter: saturate(1.8) blur(14px); backdrop-filter: saturate(1.8) blur(14px); border-bottom: 1px solid rgba(11,18,32,0.07); }
.header-row { display: flex; align-items: center; justify-content: space-between; height: 62px; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-family: var(--display); font-weight: 800; font-size: 19.5px; }
.brand:hover { text-decoration: none; }
.logo-mark { width: 31px; height: 31px; border-radius: 9px; }
.site-nav { display: flex; align-items: center; gap: 20px; font-weight: 560; font-size: 15.5px; }
.site-nav a { color: var(--slate-700); }
.site-nav a.btn, .site-nav a.btn:hover { color: #fff; }
.site-footer { margin-top: 84px; background: var(--paper); border-top: 1px solid var(--slate-200); padding: 40px 0 30px; }
.footer-grid { display: flex; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.footer-tag { color: var(--slate-500); max-width: 420px; font-size: 15px; margin-top: 10px; }
.footer-links { display: grid; gap: 7px; font-size: 15px; align-content: start; }
.footer-legal { color: var(--slate-500); font-size: 13px; margin-top: 24px; }
.footer-legal a { color: var(--slate-500); }

/* Buttons + chips */
.btn { display: inline-block; white-space: nowrap; background: var(--slate-100); color: var(--ink); font-weight: 640; padding: 12px 22px; border-radius: 999px; transition-property: transform, background, box-shadow; transition-duration: 0.14s; transition-timing-function: cubic-bezier(0.2,0,0,1); }
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(0.96); }
.btn-primary { background: var(--ink); color: #fff; box-shadow: 0 2px 10px rgba(11,18,32,0.22); }
.btn-primary:hover { background: #1b2740; }
.btn-ghost { background: var(--paper); border: 1px solid var(--slate-200); }
.btn-light { background: #fff; color: var(--ink); box-shadow: 0 2px 12px rgba(0,0,0,0.25); }
.btn-small { padding: 8px 16px; font-size: 14.5px; background: var(--ink); color: #fff; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 4px; }
.chip { display: inline-flex; align-items: center; gap: 7px; background: var(--paper); box-shadow: 0 1px 2px rgba(11,18,32,0.06), 0 0 0 1px rgba(11,18,32,0.07); padding: 7px 14px; border-radius: 999px; font-size: 14.5px; font-weight: 570; color: var(--slate-700); }
.chip-soft { background: var(--blue-50); box-shadow: none; color: var(--blue-800); }
.chip-icon { background: #FFF6DD; box-shadow: none; color: #8a5a00; }
.chip-link { color: var(--blue-700); }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.icon-star { color: #d99a00; }
.count { color: var(--slate-400); font-weight: 560; font-size: 0.8em; }

/* Cards (concentric: outer 24, inner media 16, padding 8) */
.card { background: var(--paper); border-radius: var(--r-l); box-shadow: var(--shadow-card); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 16px; margin-top: 18px; }
.road-card { display: block; background: var(--paper); border-radius: var(--r-l); padding: 0; overflow: hidden; color: var(--ink); box-shadow: var(--shadow-card); transition-property: transform, box-shadow; transition-duration: 0.16s; transition-timing-function: cubic-bezier(0.2,0,0,1); }
.road-card:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.road-card:active { transform: scale(0.96); }
.road-card-map { background: transparent; border-radius: 0; }
.road-card-map.sat { position: relative; overflow: hidden; }
.road-card-map.sat img { display: block; width: 100%; height: auto; }
.road-card-map.sat svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.road-card-map svg { display: block; width: 100%; height: auto; }
.road-card-body { padding: 11px 14px 12px; }
.road-card-body h3 { margin: 0 0 3px; font-size: 16.5px; }
.road-card-meta { margin: 0; color: var(--slate-600); font-size: 13.5px; display: flex; align-items: center; gap: 6px; }
.road-card-meta + .road-card-meta { margin-top: 3px; }
.road-card-meta .away { color: var(--slate-400); margin-left: 4px; }
.shield { display: inline-block; font-size: 11px; font-weight: 700; font-family: var(--font-mono); letter-spacing: 0.02em; padding: 2px 7px; border-radius: 6px; }

/* Hero (the Flighty formula: white, huge ink type, floating cards + device) */
.hero { background: #fff; padding: 84px 0 24px; text-align: center; overflow: hidden; }
.hero h1 { max-width: 800px; margin: 0 auto 14px; }
.hero-sub { font-size: 19.5px; max-width: 620px; margin: 0 auto; color: var(--slate-500); }
.hero-ctas { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; justify-content: center; }
.trust-row { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 26px; color: var(--slate-500); font-size: 14.5px; font-weight: 580; }
.tdot { width: 4px; height: 4px; border-radius: 50%; background: var(--slate-300); }

.hero-stage { position: relative; max-width: 980px; margin: 44px auto -10px; height: 560px; }
.phone { position: relative; z-index: 1; width: 320px; height: 560px; margin: 0 auto; background: #0d0d10; border-radius: 54px; padding: 10px; box-shadow: 0 8px 18px rgba(11,18,32,0.18), 0 34px 80px rgba(11,18,32,0.28), inset 0 0 0 2px #2a2a30; }
.phone::before { content: ""; position: absolute; top: 22px; left: 50%; transform: translateX(-50%); width: 96px; height: 26px; background: #0d0d10; border-radius: 14px; z-index: 2; }
.phone-screen { width: 100%; height: 100%; background: #fff; border-radius: 44px; overflow: hidden; display: flex; flex-direction: column; }
.phone-top { padding: 58px 18px 6px; text-align: left; }
.phone-app { display: block; font-family: var(--display); font-weight: 800; font-size: 21px; letter-spacing: -0.02em; }
.phone-sub { display: block; color: var(--slate-500); font-size: 12.5px; margin-top: 2px; }
.phone-map { flex: 1; margin: 8px 12px; background: linear-gradient(180deg, #F3F8FF, #E8F1FE); border-radius: 18px; box-shadow: inset 0 0 0 1px rgba(0,0,0,0.05); display: flex; align-items: center; }
.phone-map svg { width: 100%; height: auto; }
.phone-chips { display: flex; gap: 6px; padding: 4px 12px 18px; justify-content: center; flex-wrap: wrap; }
.phone-chips .chip { font-size: 11.5px; padding: 5px 10px; }

.float-card { position: absolute; z-index: 3; display: flex; gap: 11px; align-items: center; background: #fff; border-radius: 18px; padding: 13px 17px; box-shadow: var(--shadow-float); text-align: left; max-width: 290px; }
.float-card strong { display: block; font-size: 15px; letter-spacing: -0.01em; }
.float-card span:not(.fc-emoji) { display: block; color: var(--slate-500); font-size: 13.5px; }
.fc-emoji { font-size: 22px; }
.fc-dim { opacity: 0.45; filter: saturate(0.8); }
.fc-1 { left: 2%; top: 16%; transform: rotate(-2deg); }
.fc-2 { left: 6%; top: 62%; transform: rotate(1.5deg); }
.fc-3 { right: 2%; top: 24%; transform: rotate(2deg); }
.fc-4 { right: 5%; top: 68%; transform: rotate(-1.5deg); }

.page-sub, .section-sub { color: var(--slate-500); max-width: 680px; }

/* Road page */
.breadcrumbs { font-size: 14px; color: var(--slate-400); margin: 24px 0 8px; }
.breadcrumbs a { color: var(--slate-500); }
.road-page h1 { margin-top: 6px; font-size: clamp(32px, 5vw, 48px); }
.road-sub { color: var(--slate-500); font-size: 18px; margin-top: -2px; }
.road-hero { margin: 24px 0 8px; }
.road-hero-map { background: linear-gradient(180deg, #F3F8FF, #E8F1FE); border-radius: var(--r-l); box-shadow: var(--shadow-card), inset 0 0 0 1px rgba(0,0,0,0.04); padding: 10px; overflow: hidden; }
.road-hero-map svg { display: block; width: 100%; height: auto; }
/* When MapLibre takes over, the container becomes the live map canvas at a fixed visual height. */
.road-hero-map.live { padding: 0; height: 480px; }
.road-hero-map.live .hero-map-fallback { display: none; }
.road-hero-map.live .maplibregl-canvas { border-radius: var(--r-l); }
.sat-toggle { position: absolute; top: 10px; left: 10px; z-index: 5; background: #fff; border: 0; border-radius: 10px; padding: 8px 13px; font: 640 13.5px var(--body-stack, system-ui); color: var(--ink); box-shadow: 0 1px 4px rgba(11,18,32,0.2); cursor: pointer; }
.sat-toggle:hover { background: var(--slate-100); }
.sat-toggle:focus-visible { outline: 2px solid var(--blue-600, #1447E6); outline-offset: 2px; }
.map-dot { width: 16px; height: 16px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 1px 4px rgba(11,18,32,0.35); }
@media (max-width: 640px) { .road-hero-map.live { height: 360px; } }
.road-hero-chips { margin-top: 14px; padding: 0 2px; position: relative; }
.road-hero-chips .chip { box-shadow: 0 3px 10px rgba(11,18,32,0.10), 0 0 0 1px rgba(11,18,32,0.06); background: #fff; }
.road-hero-chips .chip-soft { background: var(--blue-50); }
.road-hero-chips .chip-icon { background: #FFF6DD; }
.road-hero figcaption { color: var(--slate-400); font-size: 13px; padding: 14px 8px 0; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 26px 0 8px; }
.stat { background: var(--paper); border-radius: var(--r-m); padding: 16px 18px; box-shadow: var(--shadow-card); }
.stat-n { display: block; font-family: var(--display); font-weight: 800; font-size: 24px; font-variant-numeric: tabular-nums; letter-spacing: -0.015em; }
.stat-l { color: var(--slate-500); font-size: 13.5px; }
.prose { max-width: 720px; margin-top: 22px; }
.lede { font-size: 21px; font-weight: 560; letter-spacing: -0.012em; line-height: 1.5; }
.editors-note { background: var(--blue-50); border-radius: var(--r-m); padding: 20px 22px; margin: 20px 0; }
.editors-note h2 { margin-top: 0; font-size: 17px; color: var(--blue-800); }
.editors-note p { margin: 0; color: var(--slate-700); }
.elev-card { padding: 12px; border-radius: var(--r-m); }
.elev-card svg { display: block; width: 100%; height: auto; }
.hazard-list li, .poi-list li { margin-bottom: 6px; }
.poi-kind { display: inline-block; background: var(--blue-50); color: var(--blue-800); font-size: 12.5px; font-weight: 620; border-radius: 7px; padding: 1px 8px; margin-right: 6px; }
.see-all { margin-top: 14px; font-weight: 570; }

/* Country + collection grids */
.country-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(196px, 1fr)); gap: 12px; margin-top: 18px; }
.country-card { display: flex; align-items: center; gap: 11px; background: var(--paper); border-radius: var(--r-m); padding: 14px 16px; color: var(--ink); font-weight: 620; box-shadow: var(--shadow-card); transition-property: transform, box-shadow; transition-duration: 0.14s; }
.country-card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.country-card:active { transform: scale(0.96); }
.country-flag { font-size: 25px; }
.country-count { margin-left: auto; color: var(--slate-500); font-weight: 560; font-size: 13.5px; }
.collection-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(244px, 1fr)); gap: 16px; margin-top: 18px; }
/* Collection card: satellite of the headline road, the collection hue on the route line.
   Same white-card family as road cards; the hue is an accent, never a field. */
.collection-card { --cc: #1447E6; display: block; background: var(--paper); color: var(--ink); border-radius: var(--r-l); overflow: hidden; box-shadow: var(--shadow-card); transition-property: transform, box-shadow; transition-duration: 0.16s; transition-timing-function: cubic-bezier(0.2,0,0,1); }
.collection-card:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.collection-card:active { transform: scale(0.96); }
.cc-media { position: relative; aspect-ratio: 320 / 150; overflow: hidden; }
.cc-media img { display: block; width: 100%; height: 100%; object-fit: cover; outline: 1px solid rgba(0,0,0,0.08); outline-offset: -1px; }
.cc-media svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cc-media-plain { background: linear-gradient(150deg, var(--cc), color-mix(in srgb, var(--cc) 72%, #000 8%)); display: flex; align-items: center; }
.cc-media-plain svg { position: static; opacity: 0.9; }
.cc-body { padding: 12px 14px 13px; }
.cc-body h3 { margin: 0 0 3px; font-size: 16.5px; display: flex; align-items: center; gap: 8px; }
.cc-body h3::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cc); flex: 0 0 auto; }
.cc-body p { margin: 0 0 6px; color: var(--slate-600); font-size: 13.5px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cc-body .count { font-size: 12.5px; }

/* Collection page: wide satellite hero with every member road overlaid */
.col-hero { margin: 22px 0 4px; position: relative; border-radius: var(--r-l); overflow: hidden; box-shadow: var(--shadow-card); }
.col-hero img { display: block; width: 100%; height: auto; outline: 1px solid rgba(0,0,0,0.08); outline-offset: -1px; border-radius: inherit; }
.col-hero svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.collection-page .spec-strip { margin-top: 18px; }

/* Eyebrow: quiet section label (sentence case, never uppercase) */
.eyebrow { display: flex; align-items: center; gap: 7px; color: var(--slate-500); font-size: 13.5px; font-weight: 640; margin: 44px 0 2px; }
.eyebrow + h2, .eyebrow + .page-title, .eyebrow + .road-head h1, .eyebrow + h1 { margin-top: 4px; }
.eyebrow + .road-head { margin-top: 0; }
.eyebrow + .road-head h1, .breadcrumbs + .eyebrow + .road-head h1 { margin-top: 2px; }
.eyebrow-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--cc, var(--blue-600)); }
.breadcrumbs + .eyebrow { margin-top: 18px; }
main > section .eyebrow, main > .wrap .eyebrow { margin-bottom: 0; }
section .eyebrow + h2 { margin-top: 2px; }
.road-link-list { columns: 3 220px; column-gap: 28px; padding-left: 20px; margin-top: 8px; }
.road-link-list li { margin-bottom: 5px; break-inside: avoid; }

/* Grand Tours */
.tour-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin-top: 18px; }
.tour-card { --cc: #1447E6; position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 250px; color: #fff; border-radius: var(--r-l); padding: 18px 20px 18px; background: linear-gradient(155deg, var(--cc), color-mix(in srgb, var(--cc) 64%, #0C1222 36%)); box-shadow: var(--shadow-card); overflow: hidden; transition-property: transform, box-shadow; transition-duration: 0.16s; transition-timing-function: cubic-bezier(0.2,0,0,1); }
.tour-card:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.tour-card:hover .tc-sat { transform: scale(1.03); }
.tour-card:active { transform: scale(0.96); }
/* Satellite variant: full-bleed imagery, day-coloured lines, text on a bottom scrim */
.tc-sat { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s cubic-bezier(0.2,0,0,1); }
.tc-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tc-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,12,22,0.30) 0%, rgba(8,12,22,0.02) 32%, rgba(8,12,22,0.06) 52%, rgba(8,12,22,0.82) 100%); pointer-events: none; }
.tour-card .tour-kicker-row, .tour-card .tc-content { position: relative; z-index: 1; }
.tc-content { margin-top: auto; }
.tour-kicker { display: block; font-size: 13px; font-weight: 640; color: rgba(255,255,255,0.86); }
.tour-card h3 { color: #fff; font-size: 22px; margin-bottom: 5px; text-shadow: 0 1px 8px rgba(8,12,22,0.35); }
.tour-card p { color: rgba(255,255,255,0.92); font-size: 14.5px; line-height: 1.45; margin-bottom: 10px; text-shadow: 0 1px 6px rgba(8,12,22,0.4); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tour-meta { color: rgba(255,255,255,0.85); font-size: 13.5px; font-weight: 580; text-shadow: 0 1px 6px rgba(8,12,22,0.4); }

/* Day jump nav on tour pages */
.day-nav { display: flex; gap: 8px; overflow-x: auto; padding: 16px 0 4px; scrollbar-width: none; }
.day-nav::-webkit-scrollbar { display: none; }
.day-nav a { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 8px; background: var(--paper); box-shadow: 0 1px 2px rgba(11,18,32,0.06), 0 0 0 1px rgba(11,18,32,0.07); border-radius: 999px; padding: 7px 15px 7px 7px; font-size: 14px; font-weight: 600; color: var(--ink); white-space: nowrap; }
.day-nav a:hover { text-decoration: none; box-shadow: 0 2px 6px rgba(11,18,32,0.1), 0 0 0 1px rgba(11,18,32,0.1); }
.day-nav-n { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; color: #fff; font-family: var(--display); font-weight: 800; font-size: 13px; }
.tour-day { scroll-margin-top: 86px; }
.tour-day { margin-top: 14px; }
.tour-day-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 40px; }
.tour-day-head h2 { margin: 0; }
.tour-day-n { color: #fff; font-family: var(--display); font-weight: 800; font-size: 14px; padding: 6px 13px; border-radius: 999px; box-shadow: 0 2px 8px rgba(11,18,32,0.18); }
.tour-day-note { color: var(--slate-500); max-width: 720px; margin-top: 10px; }
.tour-fallback svg { max-height: 420px; }
.tour-sat-fallback { position: relative; border-radius: calc(var(--r-l) - 8px); overflow: hidden; }
.tour-sat-fallback img { display: block; width: 100%; height: auto; }
.tour-sat-fallback svg { position: absolute; inset: 0; width: 100%; height: 100%; max-height: none; }

/* App CTA: the dark contrast band */
.app-cta { display: flex; align-items: center; justify-content: space-between; gap: 26px; flex-wrap: wrap; background: radial-gradient(120% 160% at 10% 0%, #16203a 0%, var(--night) 58%); color: #fff; border-radius: var(--r-l); padding: 34px 36px; margin: 56px 0 8px; box-shadow: 0 18px 50px rgba(11,18,32,0.28); }
.app-cta h2 { color: #fff; margin: 0 0 7px; font-size: 23px; }
.app-cta p { margin: 0; color: rgba(255,255,255,0.78); max-width: 560px; font-size: 15.5px; }
/* Homepage split feature: copy left, full-bleed satellite editorial right */
.feature-split { display: grid; grid-template-columns: 1fr 1.05fr; gap: 36px; align-items: center; margin-top: 64px; }
.fs-copy h2 { margin-top: 2px; }
.why-list { list-style: none; padding: 0; margin: 18px 0 24px; display: grid; gap: 16px; }
.why-list li { padding-left: 18px; border-left: 3px solid var(--color-blue-600); }
.why-list strong { display: block; font-size: 16.5px; letter-spacing: -0.012em; margin-bottom: 2px; }
.why-list span { color: var(--slate-500); font-size: 15px; line-height: 1.55; }
.fs-feature { position: relative; display: block; border-radius: var(--r-l); overflow: hidden; box-shadow: var(--shadow-card); aspect-ratio: 4 / 3; }
.fs-feature img { width: 100%; height: 100%; object-fit: cover; display: block; outline: 1px solid rgba(0,0,0,0.08); outline-offset: -1px; border-radius: inherit; transition: transform 0.5s cubic-bezier(0.2,0,0,1); }
.fs-feature:hover img { transform: scale(1.03); }
.fs-feature svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.fs-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 44px 20px 16px; color: #fff; background: linear-gradient(180deg, transparent, rgba(8,12,22,0.78)); }
.fs-cap strong { display: block; font-size: 19px; letter-spacing: -0.015em; }
.fs-cap span { font-size: 13.5px; color: rgba(255,255,255,0.88); }
@media (max-width: 880px) { .feature-split { grid-template-columns: 1fr; gap: 22px; } }

main > .wrap > section:first-of-type h2, main.wrap h1 { margin-top: 28px; }
@media (max-width: 880px) {
  .fc-2, .fc-4 { display: none; }
  .fc-1 { left: -4%; top: 6%; }
  .fc-3 { right: -4%; top: 58%; }
}
@media (max-width: 640px) {
  .site-nav { gap: 12px; font-size: 14px; }
  .site-nav a:not(.btn) { display: none; }
  .hero { padding: 56px 0 16px; }
  .hero-stage { height: 480px; margin-top: 30px; }
  .phone { width: 270px; height: 470px; }
  .float-card { max-width: 200px; padding: 10px 13px; }
  .fc-1 { left: 6px; top: 4%; }
  .fc-3 { right: 6px; top: 60%; }
  .road-hero-chips { margin-top: 12px; }
  /* A nowrap button with a long label ("Download Routes on the App Store") inside the
     padded CTA band forced a ~450px minimum page width: every page clipped on phones. */
  .btn { white-space: normal; text-align: center; }
  .app-cta { padding: 26px 22px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .road-card, .country-card, .collection-card { transition: none; }
}

/* Pro badging (tours are a Pro app feature; web stays an open shop window) */
.pro-pill { display: inline-flex; align-items: center; background: #1447E6; color: #fff; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; letter-spacing: 0.01em; }
.tour-card .pro-pill { background: rgba(255,255,255,0.24); }
.tour-kicker-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.chip-pro { background: #1447E6; color: #fff; box-shadow: none; }
.hero-photo { display: block; width: 320px; max-width: 86%; height: auto; margin: 0 auto; }
.hero-stage.has-photo { display: flex; align-items: center; justify-content: center; }

/* Roads directory (/roads/) */
.dir-tools { position: sticky; top: 62px; z-index: 9; background: rgba(255,255,255,0.88); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); padding: 12px 0 10px; margin: 4px 0 6px; border-bottom: 1px solid var(--color-slate-200); }
.dir-search { width: 100%; max-width: 460px; font: 600 16px/1 var(--font-sans); color: var(--ink); background: var(--color-slate-100); border: 0; border-radius: 999px; padding: 13px 20px; }
.dir-search:focus-visible { outline: 3px solid var(--color-blue-400); outline-offset: 2px; }
.dir-search::placeholder { color: var(--color-slate-400); }
.dir-jump { display: flex; gap: 8px; overflow-x: auto; padding: 10px 0 2px; scrollbar-width: none; }
.dir-jump::-webkit-scrollbar { display: none; }
.dir-jump a { flex: 0 0 auto; font-size: 13.5px; font-weight: 640; color: var(--color-slate-700); background: var(--color-slate-100); border-radius: 999px; padding: 7px 13px; }
.dir-jump a:hover { background: var(--color-blue-50); text-decoration: none; }
.dir-country { margin-top: 44px; }
.dir-country-head { display: flex; align-items: baseline; gap: 10px; }
.dir-country-head .count { color: var(--color-slate-400); font-weight: 640; font-size: 15px; }
.dir-country-head .all-link { margin-left: auto; font-size: 14.5px; font-weight: 640; white-space: nowrap; }
.dir-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 4px 18px; margin-top: 14px; }
.dir-road { display: flex; align-items: center; gap: 8px; padding: 9px 10px; border-radius: var(--radius-xl); color: var(--ink); font-weight: 560; font-size: 15px; }
.dir-road:hover { background: var(--color-blue-50); text-decoration: none; }
.dir-road .shield { flex: 0 0 auto; }
/* Single-line rows: long names ellipsise (full name in the title attr), so the
   grid keeps an even rhythm instead of ragged two-line wraps. */
.dir-road .dir-name { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dir-road .dir-meta { flex: 0 0 auto; margin-left: auto; color: var(--color-slate-400); font-size: 12.5px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.dir-none { color: var(--color-slate-500); padding: 24px 0; display: none; }
/* Hero photo (Simon's framed screenshot replaces the CSS phone) */
.hero-stage.has-photo .phone { display: none; }
.hero-photo { display: block; width: 330px; max-width: 82%; height: auto; margin: 0 auto; filter: drop-shadow(0 24px 60px rgba(11,18,32,0.28)); }
@media (max-width: 640px) { .hero-photo { width: 270px; } .dir-tools { top: 56px; } }

/* App-Store-style spec strip (mirrors the app's statsRow) */
.spec-strip { display: flex; align-items: stretch; background: var(--paper); border-radius: var(--r-m); box-shadow: var(--shadow-card); padding: 16px 6px 13px; margin-top: 16px; }
.spec { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 0 8px; text-align: center; min-width: 0; }
.spec + .spec { border-left: 1px solid var(--color-slate-200); }
.spec-label { font-size: 12.5px; font-weight: 620; letter-spacing: 0.01em; color: var(--color-slate-500); white-space: nowrap; }
.spec-value { font-family: var(--display); font-weight: 760; font-size: 22px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; white-space: nowrap; display: inline-flex; align-items: center; gap: 7px; }
.spec-diff { font-size: 18px; }
.spec-sub { font-size: 12px; color: var(--color-slate-500); white-space: nowrap; }
.character h2 { margin-top: 44px; }
/* App-style tag chips: neutral fill, coloured glyph, primary text */
.tag-rows { margin-top: 12px; }
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; }
.seasons-row { margin-top: 12px; }
.tag-chip { display: inline-flex; align-items: center; gap: 7px; background: var(--color-slate-100); border-radius: 999px; padding: 8px 14px; font-size: 14.5px; font-weight: 620; color: var(--ink); white-space: nowrap; }
.tag-chip svg { width: 15px; height: 15px; flex: 0 0 auto; }
@media (max-width: 560px) {
  .spec-value { font-size: 18px; }
  .spec-diff { font-size: 15px; }
  .spec-label { font-size: 11.5px; }
  /* 4-up strips overflow a phone: wrap to a 2x2 grid and drop the dividers */
  .spec-strip { display: grid; grid-template-columns: 1fr 1fr; row-gap: 14px; padding: 14px 6px 12px; }
  .spec + .spec { border-left: 0; }
  .spec:nth-child(even) { border-left: 1px solid var(--color-slate-200); }
}
/* Country cards: never wrap the name */
.country-card { white-space: nowrap; }
.country-card .country-name { overflow: hidden; text-overflow: ellipsis; font-size: 15px; }

/* Five-phone deck fan: centre upright, pairs stepped down + rotated, bottoms
   grounded past the stage edge. Entrance rise animates the separate `translate`
   property so it composes with each phone's static rotate. */
.hero-stage.fan { display: flex; align-items: flex-start; justify-content: center; height: 600px; max-width: 1180px; margin: 56px auto 0; overflow: hidden; }
.fan-phone { flex: 0 0 auto; height: auto; filter: drop-shadow(0 16px 34px rgba(11,18,32,0.24)); }
.fp-c { width: 320px; z-index: 5; position: relative; }
.fp-2 { width: 264px; z-index: 4; margin-right: -40px; transform: rotate(-5deg) translateY(92px); }
.fp-3 { width: 264px; z-index: 4; margin-left: -40px; transform: rotate(5deg) translateY(92px); }
.fp-1 { width: 220px; z-index: 3; margin-right: -36px; transform: rotate(-9deg) translateY(192px); }
.fp-4 { width: 220px; z-index: 3; margin-left: -36px; transform: rotate(9deg) translateY(192px); }
@media (prefers-reduced-motion: no-preference) {
  .fan-phone { animation: fanrise 0.7s cubic-bezier(0.2, 0, 0, 1) both; }
  .fp-2, .fp-3 { animation-delay: 0.09s; }
  .fp-1, .fp-4 { animation-delay: 0.18s; }
  @keyframes fanrise { from { opacity: 0; translate: 0 38px; } to { opacity: 1; translate: 0 0; } }
}
@media (max-width: 880px) {
  .hero-stage.fan { height: 520px; }
  .fp-c { width: 280px; }
  .fp-2, .fp-3 { width: 228px; margin-right: -32px; transform: rotate(-5deg) translateY(86px); }
  .fp-3 { margin-right: 0; margin-left: -32px; transform: rotate(5deg) translateY(86px); }
  .fp-1, .fp-4 { display: none; }
}
@media (max-width: 640px) {
  .hero-stage.fan { height: 440px; margin-top: 36px; }
  .fp-c { width: 238px; }
  .fp-2, .fp-3 { width: 190px; margin-right: -26px; transform: rotate(-5deg) translateY(74px); }
  .fp-3 { margin-right: 0; margin-left: -26px; transform: rotate(5deg) translateY(74px); }
}

/* Photo hero: full device, breathing room, real-UI float shots */
.hero-stage.has-photo { display: block; position: relative; height: auto; max-width: 980px; margin: 64px auto 0; text-align: center; }
.hero-stage.has-photo .hero-photo { position: relative; z-index: 1; width: 340px; max-width: 78%; margin: 0 auto; }
.float-shot { position: absolute; z-index: 3; height: auto; border-radius: 18px; box-shadow: var(--shadow-float); background: #fff; }
.fs-1 { width: 195px; left: 5%; top: 5%; transform: rotate(-3deg); }
.fs-2 { width: 250px; right: 3%; top: 16%; transform: rotate(2deg); }
.fs-3 { width: 300px; left: 2%; top: 56%; transform: rotate(2deg); }
.fs-4 { width: 295px; right: 4%; top: 72%; transform: rotate(-2deg); }
@media (max-width: 880px) {
  .fs-1 { width: 160px; left: 1%; }
  .fs-2 { width: 205px; right: 0; }
  .fs-3 { width: 240px; left: 0; top: 58%; }
  .fs-4 { display: none; }
}
@media (max-width: 640px) {
  .hero-stage.has-photo { margin-top: 44px; }
  .hero-stage.has-photo .hero-photo { width: 265px; }
  .fs-1 { width: 130px; top: 2%; }
  .fs-2 { width: 165px; top: 14%; }
  .fs-3 { width: 195px; top: 60%; }
}

/* ---- World-class pass: Vercel/Stripe surface language ---- */
/* Dotted grid backdrop behind the hero, fading out (Vercel motif) */
.hero { position: relative; }
.hero::before { content: ""; position: absolute; inset: -40px 0 0; z-index: -1;
  background-image: radial-gradient(circle, var(--color-slate-300) 1px, transparent 1px);
  background-size: 22px 22px; opacity: 0.5;
  -webkit-mask-image: radial-gradient(ellipse 70% 65% at 50% 35%, #000 0%, transparent 70%);
  mask-image: radial-gradient(ellipse 70% 65% at 50% 35%, #000 0%, transparent 70%); }
/* Section rhythm: hairline top borders + eyebrow labels read as a system */
main > .wrap > section + section, .home-section + .home-section { border-top: 1px solid var(--color-slate-100); }
/* Refined link + button micro-interactions */
.btn-primary { background: linear-gradient(180deg, #16202F, #0B1220); box-shadow: 0 1px 2px rgba(11,18,32,0.3), inset 0 1px 0 rgba(255,255,255,0.08); }
.btn-primary:hover { background: linear-gradient(180deg, #1B2740, #101A2C); }
.btn-ghost:hover { border-color: var(--color-slate-300); background: var(--color-slate-50); }
/* Footer: quiet, structured, Stripe-calm */
.site-footer { background: var(--color-slate-50); border-top: 1px solid var(--color-slate-200); }
.footer-links a { color: var(--color-slate-600); }
.footer-links a:hover { color: var(--ink); text-decoration: none; }
/* Selection + focus tuned to brand */
::selection { background: var(--color-blue-100); color: var(--color-blue-900); }
/* Tabular numerals on all stats and metas */
.spec-value, .dir-meta, .country-count, .road-card-meta { font-variant-numeric: tabular-nums; }
/* Headings: tighter optical rhythm above sections */
section > h2 { letter-spacing: -0.025em; }
.section-sub { margin-top: -4px; }
/* Images get the standards-grade hairline (pure black alpha, per the interface guide) */
.road-card-map.sat img, .hero-photo { outline: 1px solid rgba(0,0,0,0.08); outline-offset: -1px; border-radius: inherit; }
