/* Dirtbike Dash — the game's woodland palette, pixel frames and lettering. */

/* Silkscreen (SIL Open Font License, assets/fonts/OFL.txt), served from this
   site so visitors' browsers never contact a third-party font host. */
@font-face {
  font-family: "Silkscreen"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("/assets/fonts/silkscreen-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Silkscreen"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("/assets/fonts/silkscreen-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
:root {
  --forest-950: #0d211a;
  --forest-900: #12291f;
  --forest-800: #19382e;
  --forest-700: #25483a;
  --forest-600: #34543b;
  --border: #789583;
  --sky: #cbd8c9;
  --gold: #edbf58;
  --gold-deep: #e0a93a;
  --cream: #f3f5e9;
  --muted: #c3d1bd;
  --ink-dark: #1e3023;
  --shadow: #081510;
  --pixel: "Silkscreen", ui-monospace, Menlo, monospace;
  --body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1160px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--forest-800);
  color: var(--cream);
  font: 400 1.0625rem/1.6 var(--body);
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--gold); }
/* Pixel lettering: Silkscreen at its regular weight (its bold W reads as a
   U), in capitals as in the game's HUD. */
h1, h2, h3, .btn, .badge, .chip, .topbar__nav a, .eyebrow, .hero__tagline, .ride__toggle {
  text-transform: uppercase;
}
h1, h2, h3 { margin: 0; font-family: var(--pixel); font-weight: 700; line-height: 1.12; letter-spacing: 0; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); text-wrap: balance; }
h3 { font-size: 1.35rem; }
p { margin: 0; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 14px; background: var(--gold); color: var(--ink-dark); font-family: var(--pixel); text-decoration: none; }
.skip:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* Pixel art keeps its hard edges at every scale. */
.pixel, .hero__title img, .topbar__brand img, .pillar__icon, .place img, .finale__rider, .footer img {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 24px;
  padding: 12px var(--gutter);
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
  background: rgba(18, 41, 31, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 2px solid var(--shadow);
}
.topbar__brand img { width: 144px; height: auto; image-rendering: pixelated; }
.topbar__nav { display: flex; gap: 22px; margin-left: auto; }
.topbar__nav a { font-family: var(--pixel); font-weight: 600; font-size: 1.1rem; color: var(--cream); text-decoration: none; }
.topbar__nav a:hover { color: var(--gold); }
.topbar__nav a[aria-current="page"] { color: var(--gold); box-shadow: 0 3px 0 var(--gold); }
.chip {
  font-family: var(--pixel); font-weight: 600; font-size: 0.95rem; color: var(--ink-dark);
  background: var(--gold); padding: 5px 10px; border: 2px solid var(--shadow);
}
/* Phones: the links move to a second row that scrolls sideways. */
@media (max-width: 760px) {
  .topbar { flex-wrap: wrap; gap: 10px 18px; padding-top: 10px; padding-bottom: 0; }
  .topbar__nav {
    order: 3; width: 100%; margin-left: 0; gap: 20px;
    overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
    padding: 4px 2px 10px;
  }
  .topbar__nav::-webkit-scrollbar { display: none; }
  .topbar__nav a { flex: none; font-size: 1rem; }
}

/* Hero: the game's title scene */
.hero {
  position: relative;
  min-height: min(88vh, 820px);
  display: grid; place-items: center;
  padding: 72px var(--gutter) 120px;
  background: var(--sky) url("/assets/art/ui-title-title-scene.png") center bottom / cover no-repeat;
  image-rendering: pixelated;
  border-bottom: 4px solid var(--shadow);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(13, 33, 26, 0) 55%, rgba(13, 33, 26, 0.35) 100%);
  pointer-events: none;
}
.hero__inner { position: relative; z-index: 1; text-align: center; max-width: 880px; }
.hero__title img { width: min(86vw, 760px); height: auto; margin: 0 auto; }
/* A light, framed panel in the style of the game's dialogs keeps the copy
   readable over the busy forest at every width. */
.hero__panel {
  margin: 26px auto 0; max-width: 740px;
  padding: 22px clamp(18px, 4vw, 34px) 26px;
  background: rgba(243, 245, 233, 0.92);
  border: 3px solid var(--shadow);
  box-shadow: 0 0 0 2px #fff inset, 6px 6px 0 rgba(8, 21, 16, 0.75);
}
.hero__tagline {
  font-family: var(--pixel); font-weight: 700;
  font-size: clamp(1.25rem, 3vw, 1.9rem);
  color: var(--ink-dark);
}
.hero__lede {
  margin: 10px auto 0; max-width: 34em;
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  color: #2c4434;
}
.hero__actions { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; align-items: center; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px;
  padding: 12px 22px;
  font-family: var(--pixel); font-weight: 700; font-size: 1.2rem; text-decoration: none;
  border: 3px solid var(--shadow);
  box-shadow: 4px 4px 0 var(--shadow);
  transition: transform 80ms ease, box-shadow 80ms ease;
}
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--shadow); }
.btn--gold { background: var(--gold); color: var(--ink-dark); }
.btn--gold:hover { background: #f4cb6c; }
.badge {
  display: inline-flex; align-items: center; gap: 8px; min-height: 48px;
  padding: 10px 18px;
  font-family: var(--pixel); font-weight: 600; font-size: 1.1rem;
  background: var(--forest-800); color: var(--cream);
  border: 3px solid var(--shadow);
  box-shadow: 4px 4px 0 var(--shadow);
}
@media (max-width: 520px) {
  .hero { padding-top: 48px; }
  .hero__actions { flex-direction: column; align-items: stretch; }
  .btn, .badge { justify-content: center; font-size: 1rem; }
}

/* Pixel frame shared by video and screenshots, after the game's dialogs. */
.frame {
  margin: 0;
  position: relative;
  background: var(--forest-950);
  border: 4px solid var(--shadow);
  box-shadow: 0 0 0 2px var(--border) inset, 6px 6px 0 var(--shadow);
  padding: 4px;
}
.frame img, .frame video { width: 100%; height: auto; }

/* Gameplay reel */
.ride {
  max-width: var(--max); margin: -88px auto 0; padding: 0 var(--gutter);
  position: relative; z-index: 2;
}
.ride__toggle {
  position: absolute; right: 14px; bottom: 14px;
  font-family: var(--pixel); font-weight: 600; font-size: 1rem;
  padding: 8px 12px; min-height: 40px; min-width: 64px;
  background: rgba(18, 41, 31, 0.88); color: var(--cream);
  border: 2px solid var(--border); cursor: pointer;
}
.ride__toggle:hover { border-color: var(--gold); color: var(--gold); }
.ride__caption { margin-top: 14px; text-align: center; color: var(--muted); font-size: 0.95rem; }

/* Pillars */
.pillars {
  max-width: var(--max); margin: 72px auto 0; padding: 0 var(--gutter);
  display: grid; gap: 20px; grid-template-columns: repeat(3, minmax(0, 1fr));
}
.pillar {
  background: var(--forest-700);
  border: 3px solid var(--shadow);
  box-shadow: 0 0 0 2px var(--forest-600) inset;
  padding: 24px 22px 26px;
}
.pillar__icon { height: 48px; width: auto; margin-bottom: 16px; }
.pillar h3 { color: var(--gold); font-size: 1.6rem; margin-bottom: 8px; }
.pillar p { color: var(--muted); }
@media (max-width: 820px) { .pillars { grid-template-columns: 1fr; } }

/* Feature rows */
.feature {
  max-width: var(--max); margin: 96px auto 0; padding: 0 var(--gutter);
  display: grid; gap: clamp(28px, 5vw, 64px); align-items: center;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
}
.feature--flip .feature__media { order: 2; }
.eyebrow {
  font-family: var(--pixel); font-weight: 600; font-size: 1rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 10px;
}
.feature h2 { margin-bottom: 22px; }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.ticks li { position: relative; padding-left: 28px; color: var(--muted); }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 0.5em;
  width: 12px; height: 12px; background: var(--gold); box-shadow: 2px 2px 0 var(--shadow);
}
.ticks strong { color: var(--cream); font-weight: 700; }
@media (max-width: 900px) {
  .feature { grid-template-columns: 1fr; margin-top: 72px; }
  .feature--flip .feature__media { order: 0; }
}

/* Places */
.section-head { max-width: 46em; margin-bottom: 30px; }
.section-head h2 { margin-bottom: 12px; }
.section-head p:not(.eyebrow) { color: var(--muted); }
.places { max-width: var(--max); margin: 110px auto 0; padding: 0 var(--gutter); }
.places__grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 16px; grid-template-columns: repeat(4, minmax(0, 1fr));
}
.place {
  background: var(--forest-700);
  border: 3px solid var(--shadow);
  overflow: hidden;
}
.place img { width: 100%; aspect-ratio: 512 / 112; object-fit: cover; object-position: left bottom; border-bottom: 3px solid var(--shadow); }
.place div { padding: 12px 14px 14px; }
.place h3 { font-size: 1.25rem; }
.place p { margin-top: 2px; font-size: 0.9rem; color: var(--muted); }
@media (max-width: 980px) { .places__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .places__grid { grid-template-columns: 1fr; } }

/* Gallery */
.gallery { max-width: var(--max); margin: 110px auto 0; padding: 0 var(--gutter); }
.gallery__row { display: grid; gap: 22px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 720px) {
  .gallery__row {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 86%;
    overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 14px;
    margin-right: calc(-1 * var(--gutter)); padding-right: var(--gutter);
  }
  .gallery__row .frame { scroll-snap-align: start; }
}

/* Finale */
.finale {
  margin-top: 120px;
  padding: 72px var(--gutter) 84px;
  text-align: center;
  background: var(--forest-900);
  border-top: 4px solid var(--shadow);
}
.finale__rider { width: 144px; height: auto; margin: 0 auto 18px; }
.finale h2 { color: var(--gold); }
.finale p { margin: 14px auto 0; max-width: 32em; color: var(--muted); }

/* Footer */
.footer {
  display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: center; justify-content: space-between;
  padding: 26px var(--gutter) calc(26px + env(safe-area-inset-bottom));
  background: var(--forest-950);
  color: var(--muted); font-size: 0.9rem;
}
.footer img { width: 120px; height: auto; }

h1, h2, h3, .btn, .badge, .chip, .topbar__nav a, .eyebrow, .hero__tagline, .ride__toggle, .pillar h3, .place h3 {
  font-weight: 400;
}

/* Reading pages: privacy and support */
.page { max-width: 760px; margin: 0 auto; padding: 56px var(--gutter) 96px; }
.page h1 { font-size: clamp(2rem, 5vw, 3rem); color: var(--gold); }
.page .updated { margin-top: 10px; color: var(--muted); font-size: 0.95rem; }
.page .summary {
  margin-top: 28px; padding: 18px 22px;
  background: var(--forest-700); border: 3px solid var(--shadow);
  box-shadow: 0 0 0 2px var(--forest-600) inset;
}
.page h2 { margin-top: 44px; font-size: clamp(1.25rem, 2.6vw, 1.6rem); }
.page p, .page ul { margin-top: 14px; color: var(--muted); }
.page ul { padding-left: 22px; }
.page li { margin-top: 6px; }
.page strong { color: var(--cream); }
.footer__links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer__links a { color: var(--muted); }
.footer__links a:hover { color: var(--gold); }

/* Multi-page layout */
.hero--short { min-height: min(72vh, 680px); padding-bottom: 110px; }
.pillar--link { display: block; color: inherit; text-decoration: none; transition: transform 80ms ease, box-shadow 80ms ease; }
.pillar--link:hover { transform: translate(-2px, -2px); box-shadow: 0 0 0 2px var(--gold) inset, 4px 4px 0 var(--shadow); }
.pillar__more { display: inline-block; margin-top: 14px; font-family: var(--pixel); text-transform: uppercase; color: var(--gold); }
.strip {
  max-width: var(--max); margin: 56px auto 72px; padding: 18px var(--gutter);
  display: flex; align-items: center; justify-content: center; gap: 18px; text-align: left;
  color: var(--muted);
}
.strip__rider { width: 72px; height: auto; image-rendering: pixelated; }
.strip strong { color: var(--gold); font-family: var(--pixel); font-weight: 400; text-transform: uppercase; }
.page-intro { max-width: var(--max); margin: 0 auto; padding: 48px var(--gutter) 0; }
.page-intro h1 { font-size: clamp(1.9rem, 4.2vw, 3rem); color: var(--cream); text-wrap: balance; }
.page-intro__lede { margin-top: 14px; max-width: 46em; color: var(--muted); font-size: 1.1rem; }
.feature--page { margin-top: 36px; }
.pair { max-width: var(--max); margin: 36px auto 0; padding: 0 var(--gutter); display: grid; gap: 22px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 720px) { .pair { grid-template-columns: 1fr; } }
.places--page { margin-top: 32px; }
.ride--page { margin: 32px auto 0; z-index: auto; }
.gallery--page { margin-top: 36px; }
.next-link { max-width: var(--max); margin: 40px auto 72px; padding: 0 var(--gutter); }

/* Short pages keep the footer at the bottom of the window. */
body { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
body > main { flex: 1 0 auto; }
