/* Coldshift Racing: the game's tourist road map. Paper, brown ink and the red CR badge by day (ui/ui_style.gd's
   LIGHT); its night palette in the dark. Bebas Neue for titles, Barlow Condensed for labels, Caveat for the
   captions written on the photos. */
@font-face { font-family: 'Bebas Neue'; src: url('/fonts/BebasNeue-Regular.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'Barlow Condensed'; src: url('/fonts/BarlowCondensed-Bold.ttf') format('truetype'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Caveat'; src: url('/fonts/Caveat.ttf') format('truetype'); font-weight: 400 700; font-display: swap; }

:root {
  --paper: #fbf3df; --edge: #d9c49a; --ink: #3b2f25; --dim: #7d6a55; --red: #d8443a; --red-fill: #d8443a;
  --card: #f4e8c8; --card-hover: #efe0b8; --field: #fffaf0; --on-red: #fff; --shadow: rgba(59, 47, 37, .18);
  --band: #f6ecd2;
  --title: 'Bebas Neue', 'Barlow Condensed', Impact, sans-serif;
  --label: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --hand: 'Caveat', 'Bradley Hand', cursive;
  --body: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1b2030; --edge: #3d4764; --ink: #ece3d0; --dim: #a39e92; --red: #ee6558; --red-fill: #c8372f;
    --card: #262e45; --card-hover: #313b58; --field: #2f3956; --on-red: #fff; --shadow: rgba(0, 0, 0, .4);
    --band: #20263a;
  }
  /* brown ink to cream, the red badge kept red */
  .wordmark { filter: invert(.9) hue-rotate(180deg) saturate(1.3); }
  .card { border-color: transparent; box-shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 8px 24px var(--shadow); }
  body::before { opacity: .09; }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.55 var(--body); }
/* The paper's grain, over everything and under nothing you can click */
body::before { content: ''; position: fixed; inset: 0; z-index: 20; pointer-events: none; opacity: .06; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
h1, h2, h3 { font-family: var(--title); font-weight: 400; letter-spacing: .02em; line-height: 1; margin: 0 0 .4em; }
h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); }
h2 { font-size: clamp(2rem, 4vw, 2.8rem); }
h3 { font-size: 1.6rem; }
p { margin: 0 0 1em; }
code, .mono { font-family: ui-monospace, Menlo, monospace; }
.small { font-size: .88rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }

.shell { width: min(1120px, 100% - 32px); margin-inline: auto; }
.narrow { max-width: 760px; }
.page { padding-block: 48px 72px; }
.eyebrow, .meta, .tag, .button, .site-nav a, .stamp-name, .stamp-tag, summary { font-family: var(--label); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.eyebrow { color: var(--red); font-size: .9rem; margin-bottom: .5em; }
.meta { color: var(--dim); font-size: .85rem; }
.lede { font-size: 1.15rem; color: var(--dim); max-width: 46em; }
.tag { display: inline-block; font-size: .8rem; padding: .15em .6em; border: 2px solid var(--red); color: var(--red); border-radius: 3px; vertical-align: middle; }

/* Header: the map's title strip */
.site-head { border-bottom: 3px double var(--edge); background: var(--paper); position: sticky; top: 0; z-index: 5; }
.head-row { display: flex; align-items: center; gap: 24px; min-height: 64px; }
.brand { margin-right: auto; }
.wordmark { height: 38px; width: auto; }
.site-nav { display: flex; gap: 22px; }
.head-cta { white-space: nowrap; }
/* The Sound and Music switches, as small chips (only with JavaScript: they do nothing without it) */
.switches { display: none; gap: 6px; }
.js .switches { display: flex; }
.switch { font: 700 .8rem var(--label); text-transform: uppercase; letter-spacing: .08em; color: var(--ink); background: var(--card); border: 1.5px solid var(--edge); border-radius: 999px; padding: 4px 10px; cursor: pointer; white-space: nowrap; }
.switch b { color: var(--red); }
.switch[aria-pressed="false"] b { color: var(--dim); }
.switch.waiting b { color: var(--red); animation: blink 1.4s infinite; }
.switch:hover { border-color: var(--red); }
@media (max-width: 720px) { .switch .word { display: none; } }
.site-nav a { color: var(--ink); text-decoration: none; font-size: 1.05rem; padding: 4px 0; border-bottom: 3px solid transparent; }
.site-nav a:hover, .site-nav a[aria-current] { border-color: var(--red); }
.menu-toggle { display: none; }
@media (max-width: 720px) {
  .js .menu-toggle { display: block; font: 700 1rem var(--label); text-transform: uppercase; letter-spacing: .08em; background: none; border: 2px solid var(--ink); color: var(--ink); border-radius: 4px; padding: 6px 12px; }
  .js .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; gap: 0; background: var(--paper); border-bottom: 3px double var(--edge); padding: 8px 16px 16px; }
  .js .site-nav.open { display: flex; }
  .site-nav { gap: 14px; flex-wrap: wrap; }
  .js .site-nav a { padding: 10px 0; }
}

/* Buttons: the red badge */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4em; }
.button { display: inline-block; background: var(--red-fill); color: var(--on-red); text-decoration: none; font-size: 1.05rem; padding: .6em 1.3em; border-radius: 999px; border: 2px solid var(--red-fill); cursor: pointer; }
.button:hover { filter: brightness(1.08); }
.button.ghost { background: transparent; color: var(--red); }
.button.ghost.light { color: #fff; border-color: rgba(255, 255, 255, .85); }
.button.ghost.light:hover { background: rgba(255, 255, 255, .12); }
.button.small { font-size: .9rem; padding: .4em 1em; }

/* Pico's pace-note card, as the eyebrow of a section */
.note { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 6px 14px 6px 10px; background: #fbf3df; color: #3b2f25; border: 2px solid #d8443a; border-radius: 4px; box-shadow: 0 3px 0 rgba(59, 47, 37, .18); transform: rotate(-1deg); }
.note svg { width: 30px; height: 30px; fill: none; stroke: #3b2f25; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.note b { font: 400 2.2rem/1 var(--title); color: #d8443a; }
.note span { display: flex; flex-direction: column; font: 700 1rem/1.1 var(--label); text-transform: uppercase; letter-spacing: .08em; }
.note small { font-size: .78rem; color: #7d6a55; letter-spacing: .04em; text-transform: none; }

/* Snapshots pinned to the map */
.snapshot { margin: 0; background: #fffdf7; padding: 10px 10px 4px; box-shadow: 0 6px 18px var(--shadow); transform: rotate(var(--tilt, 0deg)); position: relative; color: #3b2f25; }
.snapshot::before { content: ''; position: absolute; top: -12px; left: 50%; width: 90px; height: 24px; margin-left: -45px; background: rgba(234, 216, 170, .8); transform: rotate(-3deg); box-shadow: 0 1px 2px rgba(0, 0, 0, .1); }
.snapshot img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.snapshot figcaption { font: 700 1.5rem/1.2 var(--hand); padding: 6px 2px 4px; text-align: center; }

/* Hero: the key art, full width, with the lockup over its open side */
.hero { position: relative; min-height: min(86vh, 860px); display: flex; align-items: center; overflow: hidden; background: #2a2018; color: #fff; isolation: isolate; }
.hero-art, .hero-art img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-art { z-index: -2; }
.hero-art img { object-fit: cover; object-position: 70% 50%; }
.hero::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(28, 20, 14, .82) 0%, rgba(28, 20, 14, .55) 34%, rgba(28, 20, 14, 0) 62%), linear-gradient(0deg, rgba(28, 20, 14, .55), rgba(28, 20, 14, 0) 30%); }
.hero-copy { padding-block: 72px; }
.hero-copy > * { max-width: 520px; }
/* the lockup as the game has it, its tan glow (behind the brown only) baked in: the picture is 1.25 times the lockup's
   width, so it's drawn that much wider and pulled left and up by the glow's margin, to line up with the copy */
.hero-lockup { width: min(375px, 80%); margin: -24px 0 -4px -53px; max-width: none; }
.pitch { font: 400 clamp(2rem, 3.6vw, 2.9rem)/1.02 var(--title); letter-spacing: .02em; text-shadow: 0 2px 12px rgba(0, 0, 0, .5); margin-bottom: .5em; }
.hero-text { font-size: 1.08rem; text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }
.hero .actions { margin-top: 1.2em; }
.hero .button:not(.ghost) { box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
.chips { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 8px; font: 700 .85rem var(--label); text-transform: uppercase; letter-spacing: .08em; }
.chips li { border: 1.5px solid rgba(255, 255, 255, .7); border-radius: 4px; background: rgba(28, 20, 14, .35); }
.chips a { display: block; padding: 3px 10px; color: #fff; text-decoration: none; }
.chips .soon { border-color: rgba(255, 255, 255, .35); }
.chips .soon a { color: rgba(255, 255, 255, .7); }
.chips .free { padding: 3px 10px; background: #d8443a; border-color: #d8443a; color: #fff; }
@media (max-aspect-ratio: 4/5) {
  .hero { align-items: flex-start; min-height: min(100svh, 920px); }
  .hero-art img { object-position: 50% 100%; }
  .hero::after { background: linear-gradient(180deg, rgba(28, 20, 14, .8) 0%, rgba(28, 20, 14, .45) 45%, rgba(28, 20, 14, 0) 65%); }
  .hero-copy { padding-block: 40px; }
}
@media (max-width: 520px) {
  .hero-lockup { width: 188px; margin: -12px 0 -2px -26px; }
  .pitch { font-size: 1.75rem; }
  .hero-text, .hero .chips { display: none; }
  .head-cta { display: none; }
}

/* Bands */
.band { padding-block: 64px; border-top: 3px double var(--edge); }
.band.paper { background: var(--band); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 24px; } }


.card { background: var(--card); border: 2px solid var(--edge); border-radius: 10px; padding: 22px 24px; }
.features { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.feature { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.feature-pic { aspect-ratio: 16 / 9; background: #e9dcbc; overflow: hidden; border-bottom: 2px solid var(--edge); position: relative; }
.feature-pic svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.feature-pic polyline { fill: none; stroke: #d8443a; stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.feature-pic > img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.feature:hover .feature-pic > img { transform: scale(1.04); }
.feature-pic .still-forest { object-position: 50% 10%; }
.feature-pic .still-seahorse { object-position: 50% 42%; }
.mini-stamps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4%; align-items: center; height: 100%; padding: 0 6%; background: #f1e4c2; }
.mini-stamps img { width: 100%; aspect-ratio: 1; object-fit: contain; }
.mini-stamps img:nth-child(odd) { transform: rotate(-7deg); }
.mini-stamps img:nth-child(even) { transform: rotate(5deg) translateY(8%); }
.mini-stamps img.round { object-fit: cover; border-radius: 50%; border: 3px solid var(--red); }
.feature-body { padding: 18px 22px 22px; }
.features h3 { color: var(--red); }
#features-title .aside { font-size: .55em; color: var(--dim); white-space: nowrap; }
.features p { margin: 0; }

/* On the road: the race screen in phones, upright as it's played */
.play .lede { margin-bottom: 28px; }
.phones { list-style: none; padding: 0 0 8px; margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 22px; }
.phone { margin: 0; }
.phone .screen { background: #141414; border-radius: 26px; padding: 9px; box-shadow: 0 0 0 2px #3a3a3a inset, 0 14px 30px var(--shadow); }
.phone img { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 18px; }
.phone figcaption { font: 700 1.35rem/1.15 var(--hand); text-align: center; margin-top: 10px; }
.phones li:nth-child(even) { transform: translateY(26px); }
@media (max-width: 900px) {
  .phones { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 58%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 16px; }
  .phones li { scroll-snap-align: center; }
  .phones li:nth-child(even) { transform: none; }
}
.trailer-frame { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 12px; margin-bottom: 36px; box-shadow: 0 12px 30px var(--shadow); background: #000; }
.trailer { position: relative; display: block; margin-bottom: 36px; border-radius: 12px; overflow: hidden; color: #fff; text-decoration: none; box-shadow: 0 12px 30px var(--shadow); }
.trailer img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.play-icon { position: absolute; left: 50%; top: 50%; width: 84px; height: 84px; margin: -42px; border-radius: 50%; background: #d8443a; box-shadow: 0 6px 20px rgba(0, 0, 0, .4); }
.play-icon::after { content: ''; position: absolute; left: 34px; top: 26px; border-left: 24px solid #fff; border-block: 16px solid transparent; }
.trailer-label { position: absolute; left: 20px; bottom: 16px; font: 400 2rem/1 var(--title); text-shadow: 0 2px 8px rgba(0, 0, 0, .6); }
.trailer-label small { display: block; font: 700 .85rem var(--label); text-transform: uppercase; letter-spacing: .08em; }

/* Who's who: snapshots of the cast */
.cast { list-style: none; padding: 0; margin: 32px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 36px 28px; }
.cast .snapshot { margin-bottom: 16px; }
.cast .eyebrow { margin-bottom: .2em; }
.cast p:last-child { margin: 0; }

/* The garage: the cars side on, on the showroom floor */
.cars { list-style: none; padding: 0; margin: 0; display: grid; gap: 28px; }
.car img { width: 100%; filter: drop-shadow(0 14px 10px rgba(59, 47, 37, .28)); }
.car h3 { margin: 10px 0 .2em; }
.car p { margin: 0 0 .5em; }
.paint { display: flex; gap: 6px; }
.paint i { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--edge); }
.tags { list-style: none; padding: 0; margin: 0 0 24px; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { font: 700 .9rem var(--label); text-transform: uppercase; letter-spacing: .06em; padding: 3px 10px; border: 2px dashed var(--edge); border-radius: 4px; }
.screen-shot { margin: 0; }
.screen-shot img { border-radius: 10px; border: 2px solid var(--edge); box-shadow: 0 8px 20px var(--shadow); }


/* Live on VisTok: Angie, the booth and the race TV */
.vistok { background: linear-gradient(135deg, #0d4a55, #12343f); color: #eef6f4; border-top: 0; }
.vistok-row { display: grid; grid-template-columns: 1fr 1.15fr; gap: 56px; align-items: center; }
.vistok h2 { font-size: clamp(2.4rem, 5vw, 3.6rem); color: #fff; }
.vistok a:not(.button) { color: #ffd34d; }
.vistok .button.ghost { color: #fff; border-color: rgba(255, 255, 255, .8); }
.live { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 4px 12px; border-radius: 4px; background: #e8413a; color: #fff; font: 700 .9rem var(--label); text-transform: uppercase; letter-spacing: .1em; }
.live i { width: 9px; height: 9px; border-radius: 50%; background: #fff; animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .live i { animation: none; } }
.booth-lines { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 8px; font-size: .95rem; color: #c9dcd8; }
.booth-lines li { padding-left: 12px; border-left: 3px solid #2aa3a0; }
.booth-lines b { display: block; font: 700 .8rem var(--label); text-transform: uppercase; letter-spacing: .08em; color: #8fe0d8; }
.race-tv { position: relative; margin: 0; padding: 0 0 0 0; }
.tv { background: #111; border-radius: 14px; padding: 10px; box-shadow: 0 0 0 2px #2c2c2c inset, 0 18px 40px rgba(0, 0, 0, .45); }
.tv img { border-radius: 6px; width: 100%; }
.tv-angie { position: absolute; width: 30%; right: -7%; bottom: 6%; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, .45)); transform: rotate(4deg); }
.tv-logo { position: absolute; width: 15%; left: -4%; top: -17%; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .4)); transform: rotate(6deg); }
.race-tv figcaption { font: 700 1.3rem var(--hand); text-align: right; margin-top: 10px; color: #c9dcd8; }
@media (max-width: 860px) {
  .vistok-row { grid-template-columns: 1fr; gap: 40px; }
  .tv-angie { right: -2%; width: 28%; }
  .tv-logo { left: 0; }
}

/* The last band: the coast road, and the way out to the downloads */
.finale { position: relative; isolation: isolate; color: #fff; padding-block: 120px; overflow: hidden; background: #2a2018; }
.finale-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 40% 60%; z-index: -2; }
.finale::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(28, 20, 14, .85), rgba(28, 20, 14, .35) 60%, rgba(28, 20, 14, .1)); }
.finale-copy > * { max-width: 520px; }
.finale h2 { font-size: clamp(2.6rem, 6vw, 4rem); text-shadow: 0 2px 12px rgba(0, 0, 0, .5); }
.finale p { text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }

/* Areas as passport stamps */
.stamps { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 24px; margin-top: 24px; }
.stamp { display: flex; flex-direction: column; align-items: center; text-align: center; text-decoration: none; color: var(--ink); padding: 12px; border-radius: 12px; }
.stamp:hover { background: var(--card); }
.stamp img { width: 140px; height: 140px; object-fit: contain; transition: transform .2s; }
.stamp:hover img { transform: rotate(-6deg) scale(1.05); }
.stamp-name { font-size: 1.3rem; margin-top: 8px; color: var(--accent); }
.stamp-tag { font-size: .8rem; color: var(--dim); }

/* The car radio: a head unit with its display, and a preset button per station */
.head-unit { background: #22201d; border-radius: 16px; padding: 18px; box-shadow: 0 0 0 2px #3c3833 inset, 0 14px 30px var(--shadow); color: #ece3d0; }
.lcd { margin: 0 0 16px; padding: 10px 14px; border-radius: 6px; background: #1a2a22; box-shadow: 0 0 0 2px #0e1712 inset; color: #8ff0b4; font: 700 1rem/1.25 var(--label); text-transform: uppercase; letter-spacing: .1em; display: flex; flex-direction: column; min-height: 3.6em; text-shadow: 0 0 6px rgba(143, 240, 180, .5); }
.lcd span { font-size: .85rem; opacity: .8; }
.lcd.on b::before { content: '\25B6\FE0E  '; }
.radio { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.station { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; padding: 10px 6px; border-radius: 10px; background: #2e2b27; box-shadow: 0 3px 0 #141311; color: #ece3d0; text-decoration: none; height: 100%; }
.station:hover { background: #38342f; }
.station[aria-pressed="true"] { background: #38342f; box-shadow: 0 0 0 2px var(--accent) inset, 0 1px 0 #141311; transform: translateY(2px); }
.radio img { width: 72px; height: 72px; object-fit: contain; }
.radio b { font: 700 .95rem var(--label); text-transform: uppercase; letter-spacing: .05em; }
.radio span { font-size: .8rem; color: #a39e92; }
@media (max-width: 480px) { .radio { grid-template-columns: repeat(2, 1fr); } }

/* Page heads */
.page-head { margin-bottom: 36px; }
.page-head .lede { margin: 0; }
.dim { color: var(--dim); }
img.round { object-fit: cover; border-radius: 50%; border: 4px solid var(--accent, var(--red)); }

/* Areas: a tab per area, its stamp and name, under the header */
.area-tabs { background: var(--band); border-bottom: 3px double var(--edge); }
.area-tabs .shell { display: flex; gap: 6px; overflow-x: auto; padding-block: 10px; scrollbar-width: none; }
.area-tabs a { display: flex; align-items: center; gap: 8px; flex: none; padding: 6px 14px 6px 8px; border-radius: 999px; color: var(--ink); text-decoration: none; font: 700 1rem var(--label); text-transform: uppercase; letter-spacing: .06em; border: 2px solid transparent; }
.area-tabs a:first-child { padding-left: 14px; }
.area-tabs a:hover { background: var(--card); }
.area-tabs a[aria-current] { background: var(--card); border-color: var(--accent, var(--red)); color: var(--accent, var(--red)); }
.area-tabs img { width: 34px; height: 34px; object-fit: contain; }
.area-tabs img.round { border-width: 2px; }

/* The overview: an area per card, its map above */
.trip { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; counter-reset: stop; }
.trip-stop { padding: 0; overflow: hidden; transition: transform .2s, box-shadow .2s; }
.trip-stop:hover { transform: translateY(-3px); box-shadow: 0 12px 26px var(--shadow); }
.trip-stop a { color: inherit; text-decoration: none; display: block; height: 100%; }
.trip-map { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-bottom: 2px solid var(--edge); background: #e9dcbc; }
.trip-map img { width: 100%; height: 100%; object-fit: cover; }
.trip-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.trip-map polyline, .map-frame polyline { fill: none; stroke: #d8443a; stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.trip-map polyline { stroke-width: 3; }
.trip-body { display: flex; gap: 16px; padding: 18px 20px 20px; align-items: flex-start; }
.trip-body > img { width: 76px; height: 76px; object-fit: contain; flex: none; margin-top: -52px; transform: rotate(-6deg); filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .25)); }
.trip-body h2 { color: var(--accent); margin: 0 0 .1em; font-size: 2.2rem; }
.trip-body p { margin: 0 0 .5em; }
.trip-body .meta:first-child { margin: 0; }
.trip-more { font: 700 .95rem var(--label); text-transform: uppercase; letter-spacing: .06em; color: var(--red); }

/* An area's page: the map as its hero, the title on it like a map's cartouche */
.area-hero { padding-top: 24px; }
.map-wrap { position: relative; width: min(1400px, 100% - 32px); margin-inline: auto; }
.map-frame { position: relative; border: 2px solid var(--edge); border-radius: 12px; overflow: hidden; box-shadow: 0 10px 28px var(--shadow); }
.map-frame img { width: 100%; }
.map-frame svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.area-hero > p { margin-top: 8px; }
.cartouche { position: absolute; left: 20px; top: 20px; display: flex; gap: 14px; align-items: center; background: #fbf3df; color: #3b2f25; border: 2px solid #3b2f25; outline: 2px solid #fbf3df; border-radius: 6px; padding: 12px 22px 12px 12px; box-shadow: 0 8px 20px rgba(59, 47, 37, .3); }
.cartouche img { width: 84px; height: 84px; object-fit: contain; transform: rotate(-5deg); }
.cartouche h1 { color: var(--accent); margin: 0; font-size: clamp(2.2rem, 4vw, 3.4rem); }
.cartouche .meta { margin: 0; color: #7d6a55; }
.cartouche-tag { margin: 0; font: 700 1.3rem/1.1 var(--hand); }
.sight { position: absolute; display: flex; align-items: center; gap: 5px; transform: translate(-11px, -50%); pointer-events: none; }
.sight.left { flex-direction: row-reverse; transform: translate(calc(-100% + 11px), -50%); }
.sight i { pointer-events: auto; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #3b2f25; color: #fbf3df; border: 2px solid #fffaf0; flex: none; font: 700 .75rem/1 var(--label); font-style: normal; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .15s, background .15s; }
.sight span { font: 700 1.15rem/1 var(--hand); color: #3b2f25; text-shadow: 0 0 3px #fffaf0, 0 0 3px #fffaf0, 0 0 6px #fffaf0; white-space: nowrap; }
.sight.lit i { background: #d8443a; transform: scale(1.35); }
.area-body { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; padding-block: 48px 24px; }
.glance { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin: 24px 0 0; }
.glance div { background: var(--card); border: 2px solid var(--edge); border-radius: 10px; padding: 10px 14px; }
.glance dt { font: 700 .8rem var(--label); text-transform: uppercase; letter-spacing: .08em; color: var(--dim); }
.glance dd { margin: 0; font: 400 1.9rem/1.1 var(--title); color: var(--accent); }
.pois { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.pois li { display: flex; gap: 14px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; transition: background .15s; }
.pois li:hover, .pois li.lit { background: var(--card); }
.pois b { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--paper); font: 700 .9rem var(--label); flex: none; }
.pois li.lit b { background: var(--red-fill); color: #fff; }
.pois h3 { font-size: 1.4rem; margin: 2px 0 .15em; }
.pois p { margin: 0; color: var(--dim); }
.area-roads { padding-block: 24px 16px; }
.roads { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.road h3 { margin-bottom: .2em; }
.road p:last-child { margin: 0; }
.road-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; }
.road-tags span { font: 700 .8rem var(--label); text-transform: uppercase; letter-spacing: .06em; padding: 2px 8px; border-radius: 4px; border: 1.5px solid var(--edge); color: var(--dim); }
.road-tags span:first-child { border-color: var(--accent); color: var(--accent); }
.next-stop { display: flex; justify-content: space-between; gap: 16px; padding-block: 40px 72px; }
.next-stop a { display: flex; flex-direction: column; font: 400 2rem/1 var(--title); color: var(--ink); text-decoration: none; padding: 14px 20px; border: 2px solid var(--edge); border-radius: 10px; }
.next-stop a:hover { border-color: var(--red); color: var(--red); }
.next-stop .next { text-align: right; margin-left: auto; }
.next-stop .next::after { content: ' \2192'; }
.next-stop .prev::before { content: '\2190 '; }
@media (max-width: 860px) { .area-body { grid-template-columns: 1fr; gap: 32px; } }
@media (max-width: 720px) {
  .sight span { display: none; }
  .sight i { width: 18px; height: 18px; font-size: .65rem; }
  .map-wrap { width: 100%; }
  .map-frame { border-radius: 0; border-inline: 0; }
  .cartouche { position: static; margin: -28px 16px 0; padding: 10px 16px 10px 10px; }
  .cartouche img { width: 60px; height: 60px; }
  .area-hero > p { padding-inline: 0; }
}

/* Mods */
.install { margin-bottom: 56px; }
.how { list-style: none; padding: 0; margin: 20px 0 16px; display: grid; grid-template-columns: 1fr 1.6fr 1fr; gap: 16px; }
.how li { position: relative; padding-top: 30px; }
.how li > b { position: absolute; top: -16px; left: 18px; font: 400 2.4rem/1 var(--title); color: #d8443a; background: #fbf3df; border: 2px solid #d8443a; border-radius: 4px; padding: 2px 12px; transform: rotate(-2deg); }
.how p { margin: 0 0 .6em; }
@media (max-width: 860px) { .how { grid-template-columns: 1fr; gap: 28px; } }
.address { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; background: var(--field); border: 2px dashed var(--edge); border-radius: 8px; padding: 10px 12px; margin: 4px 0 0; }
.address code { font-size: .9rem; overflow-wrap: anywhere; flex: 1 1 220px; }
.address .button { display: none; }
.js .address .button { display: inline-block; }
.packs { list-style: none; padding: 0; margin: 0 0 48px; display: grid; gap: 20px; }
.pack { display: grid; grid-template-columns: 160px 1fr; gap: 24px; }
.pack-pic img { width: 160px; height: 160px; object-fit: contain; }
.pack details { margin-top: 10px; }
.pack summary { cursor: pointer; font-size: .85rem; color: var(--dim); }
.pack .mono { overflow-wrap: anywhere; }
@media (max-width: 600px) { .pack { grid-template-columns: 1fr; } .pack-pic img { width: 120px; height: 120px; } }

/* Downloads: the race screen beside the title, a card per platform */
.dl-head { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center; margin-bottom: 32px; }
.dl-phones { display: flex; justify-content: center; gap: 18px; }
.dl-phones .phone { width: 42%; max-width: 200px; }
.dl-phones .phone:first-child { transform: rotate(-5deg) translateY(10px); }
.dl-phones .phone:last-child { transform: rotate(4deg) translateY(-10px); }
@media (max-width: 760px) { .dl-head { grid-template-columns: 1fr; } .dl-phones { display: none; } }
.builds { list-style: none; padding: 0; margin: 0 0 32px; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.group { font-size: 1.8rem; margin-top: 8px; scroll-margin-top: 84px; }
.build { position: relative; }
.build .device { width: 40px; height: 40px; fill: none; stroke: var(--red); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 8px; }
.build h2 { font-size: 2rem; margin-bottom: .1em; }
.build.soon .tag { transform: rotate(-3deg); }
.build .mono { overflow-wrap: anywhere; color: var(--dim); }
.build summary { cursor: pointer; font-size: .9rem; color: var(--dim); }

/* Credits, support, privacy, 404 */
.credits { list-style: none; padding: 0; margin: 24px 0; }
.credits li { display: flex; flex-direction: column; padding: 12px 0; border-bottom: 1px dashed var(--edge); }
.credits b { font: 700 1.2rem var(--label); }
.credits span { color: var(--dim); }
.support-row { display: grid; grid-template-columns: 1.6fr 1fr; gap: 48px; align-items: start; }
.faq { display: grid; gap: 12px; }
.faq details { padding: 0; }
.faq summary { cursor: pointer; padding: 16px 20px; font: 700 1.2rem var(--label); text-transform: none; letter-spacing: .02em; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; color: var(--red); font-size: 1.4rem; line-height: 1; }
.faq details[open] summary::after { content: '\2212'; }
.faq details p { margin: 0; padding: 0 20px 18px; }
.help .snapshot { max-width: 300px; margin: 8px auto 28px; }
.help .card h2 { font-size: 1.8rem; }
.help .card p { margin: 0; }
@media (max-width: 760px) { .support-row { grid-template-columns: 1fr; } }
.narrow > .card { margin-top: 40px; }
.prose h2 { margin-top: 1.4em; font-size: 2rem; }
.prose li { margin-bottom: .6em; }
.lost { display: grid; grid-template-columns: 280px 1fr; gap: 48px; align-items: center; }
@media (max-width: 640px) { .lost { grid-template-columns: 1fr; } .lost .snapshot { max-width: 260px; } }

/* Footer */
.site-foot { border-top: 3px double var(--edge); background: var(--band); padding-block: 40px; }
.foot-row { display: flex; gap: 20px 40px; align-items: center; flex-wrap: wrap; }
.sponsor { display: flex; gap: 12px; align-items: center; color: var(--ink); text-decoration: none; }
.sponsor img { width: 56px; height: auto; }
.sponsor span { display: flex; flex-direction: column; font: 700 1rem/1.2 var(--label); max-width: 12em; }
.sponsor small { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); }
.sponsor:hover span { color: var(--red); }
.studio { display: flex; gap: 14px; align-items: center; color: var(--ink); text-decoration: none; }
.studio img { width: 84px; height: 84px; }
.studio strong { display: block; font: 700 1.15rem var(--label); text-transform: uppercase; letter-spacing: .06em; }
.studio small { font: 700 1.25rem var(--hand); color: var(--dim); }
.studio:hover strong { color: var(--red); }
.site-foot .dim { color: var(--dim); }
.site-foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; font: 700 1rem var(--label); text-transform: uppercase; letter-spacing: .06em; }
.site-foot nav a { color: var(--ink); text-decoration: none; }
.site-foot nav a:hover { color: var(--red); }
.site-foot .small { margin: 8px 0 0; }
