/* ---------- Fonts (self-hosted, SIL OFL) ---------- */
@font-face { font-family: "Big Shoulders Display"; font-weight: 800; font-style: normal; font-display: swap;
  src: url("/static/fonts/big-shoulders-display-latin-800-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Big Shoulders Display"; font-weight: 800; font-style: normal; font-display: swap;
  src: url("/static/fonts/big-shoulders-display-latin-ext-800-normal.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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Schibsted Grotesk"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("/static/fonts/schibsted-grotesk-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Schibsted Grotesk"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("/static/fonts/schibsted-grotesk-latin-ext-400-normal.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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Schibsted Grotesk"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("/static/fonts/schibsted-grotesk-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Schibsted Grotesk"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("/static/fonts/schibsted-grotesk-latin-ext-700-normal.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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ---------- Tokens ---------- */
:root {
  --cabinet: #2A1640;
  --cabinet-2: #3A2156;
  --lamp: #FFC21A;
  --paper: #FAF9FC;
  --surface: #FFFFFF;
  --ink: #1E1630;
  --muted: #5E5770;
  --line: #E3DEEA;
  --display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --body: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 32px);
  --r-tile: 10px;
  --r-stage: 14px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--body);
}
img, iframe { max-width: 100%; }
a { color: inherit; text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid var(--lamp);
  outline-offset: 3px;
  border-radius: 4px;
}
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.skip { position: absolute; left: -999px; top: 8px; background: var(--lamp); color: var(--ink); padding: 8px 14px; z-index: 10; }
.skip:focus { left: 8px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

h1, h2 { font-family: var(--display); font-weight: 800; line-height: 0.98; letter-spacing: 0.005em; margin: 0; }
h1 { font-size: clamp(2.6rem, 6vw, 4.25rem); }
h2 { font-size: clamp(1.75rem, 3.2vw, 2.25rem); }
h3 { font-size: 1.0625rem; font-weight: 700; margin: 1.6em 0 0.5em; }
.lead { font-size: 1.1875rem; line-height: 1.55; color: var(--ink); max-width: 62ch; }
.quiet { color: var(--muted); }

/* ---------- Header / footer ---------- */
.site-head { background: var(--cabinet); color: var(--paper); }
.head-row { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--display); font-weight: 800; font-size: 1.75rem; letter-spacing: 0.01em;
  text-decoration: none; color: var(--paper);
}
.logo-mark { display: inline-grid; grid-template-columns: repeat(3, 6px); gap: 3px; height: 22px; }
.logo-mark i { background: var(--lamp); border-radius: 2px; }
.site-head nav { display: flex; gap: 22px; }
.site-head nav a { color: var(--paper); text-decoration: none; font-weight: 700; padding: 6px 0; border-bottom: 3px solid transparent; }
.site-head nav a:hover { border-bottom-color: rgba(255, 194, 26, 0.5); }
.site-head nav a[aria-current="page"] { border-bottom-color: var(--lamp); }

.site-foot { background: var(--cabinet); color: rgba(250, 249, 252, 0.86); margin-top: 96px; padding: 48px 0 28px; font-size: 0.9375rem; }
.site-foot .quiet { color: rgba(250, 249, 252, 0.6); }
.foot-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 40px; }
.foot-grid p { max-width: 60ch; }
.logo-foot { font-size: 1.5rem; }
.foot-h { font-family: var(--body); font-size: 1rem; font-weight: 700; margin: 0 0 10px; color: var(--paper); }
.site-foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.site-foot a { color: rgba(250, 249, 252, 0.86); }
.foot-base { margin-top: 32px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, 0.12); display: flex; align-items: center; gap: 12px; color: rgba(250, 249, 252, 0.6); }
.age { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 2px solid var(--lamp); border-radius: 50%; color: var(--lamp); font-weight: 700; font-size: 0.8125rem; }

/* ---------- Intro / breadcrumbs ---------- */
.intro { padding-top: 48px; padding-bottom: 8px; }
.intro .lead { margin: 16px 0 0; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 8px; padding: 0; margin: 20px 0 0; font-size: 0.9375rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line); }
.crumbs a { color: var(--muted); }

/* ---------- Catalogue toolbar ---------- */
.catalogue { margin-top: 32px; }
.catalogue > h2 { margin-bottom: 20px; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-bottom: 22px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font: 700 0.9375rem/1 var(--body); color: var(--ink);
  background: var(--surface); border: 1.5px solid var(--line); border-radius: 999px;
  padding: 9px 14px; cursor: pointer;
}
.chip { text-decoration: none; }
.chip:hover { border-color: var(--ink); }
.chip[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c); }
.chip .count { font-weight: 400; opacity: 0.7; }
.search input {
  font: 400 1rem var(--body); color: var(--ink);
  width: min(280px, 100%); padding: 10px 14px;
  border: 1.5px solid var(--line); border-radius: 8px; background: var(--surface);
}
.search input:focus { border-color: var(--ink); }
.empty { color: var(--muted); padding: 24px 0; }

/* ---------- Tiles: cover art + title; the mini grid shows the reel layout ---------- */
.tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 16px; }
.tile {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
  aspect-ratio: 4 / 3.4; padding: 14px 16px 13px; overflow: hidden;
  background-color: var(--c); color: #fff; border-radius: var(--r-tile); text-decoration: none;
  isolation: isolate;
}
.tile-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.tile::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(30, 14, 44, 0) 38%, rgba(30, 14, 44, 0.82) 78%, rgba(30, 14, 44, 0.94) 100%);
}
.tile:hover .tile-art { filter: brightness(1.12) saturate(1.08); }
.tile:focus-visible { outline-offset: 3px; }
.tile-name {
  margin: 0; font-family: var(--display); font-weight: 800; font-size: clamp(1.6rem, 2.4vw, 1.95rem);
  line-height: 0.95; letter-spacing: 0.01em; text-wrap: balance; text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}
.tile-meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 0.8125rem; font-weight: 700; color: rgba(255, 255, 255, 0.88); }
.tile-figs { display: inline-flex; align-items: center; white-space: nowrap; }
.tile-figs b { color: var(--lamp); font-weight: 700; margin-left: 6px; }
.mini-grid {
  display: inline-block; width: 16px; height: 13px; margin-right: 5px; border-radius: 2px;
  background-image:
    linear-gradient(180deg, rgba(30, 14, 44, 0.9) 0 1px, transparent 1px),
    linear-gradient(90deg, transparent 0 14%, rgba(255, 255, 255, 0.85) 14% 86%, transparent 86%);
  background-size: 100% calc(100% / var(--rows)), calc(100% / var(--cols)) 100%;
}

/* ---------- Home provider strip ---------- */
.prov-strip { margin-top: 72px; }
.prov-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.prov-list a {
  display: block; padding: 16px 18px; text-decoration: none;
  background: var(--surface); border: 1.5px solid var(--line); border-left: 8px solid var(--c); border-radius: 8px;
}
.prov-list a:hover { border-color: var(--ink); border-left-color: var(--c); }
.prov-name { display: block; font-family: var(--display); font-weight: 800; font-size: 1.5rem; line-height: 1; }
.prov-sub { display: block; margin-top: 6px; color: var(--muted); font-size: 0.9375rem; }
.prov-blurb { display: block; margin-top: 10px; font-size: 0.9375rem; line-height: 1.5; color: var(--ink); }
.prov-body { margin-top: 56px; }

/* ---------- Game page ---------- */
.game-head { padding: 18px 0 28px; }
.byline { margin: 12px 0 0; color: var(--muted); font-size: 1.0625rem; }
.byline a { color: var(--ink); font-weight: 700; text-decoration-color: var(--c); text-decoration-thickness: 3px; }

.stage-wrap { background: var(--cabinet); color: var(--paper); padding: 28px 0 0; }
.stage {
  position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-stage); overflow: hidden;
  background: var(--c); isolation: isolate;
}
.stage-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.stage-cover {
  position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; text-align: center; padding: 16px;
  background: radial-gradient(60% 55% at 50% 52%, rgba(30, 14, 44, 0.55), rgba(30, 14, 44, 0.15) 70%, rgba(30, 14, 44, 0.35));
}
.stage-note { margin: 0; font-size: 0.9375rem; color: rgba(250, 249, 252, 0.92); text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7); }
.play {
  display: inline-block; font: 800 1.5rem/1 var(--display); letter-spacing: 0.02em;
  background: var(--lamp); color: var(--ink); border: 0; border-radius: 8px;
  padding: 16px 30px; cursor: pointer; text-decoration: none;
  box-shadow: 0 0 0 6px rgba(255, 194, 26, 0.18);
}
.play:hover { box-shadow: 0 0 0 9px rgba(255, 194, 26, 0.24); }
.stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.stage:fullscreen { border-radius: 0; aspect-ratio: auto; }
.stage-bar { display: flex; justify-content: flex-end; gap: 12px; min-height: 12px; padding-top: 12px; }
.ghost {
  font: 700 0.9375rem var(--body); color: var(--paper); background: transparent;
  border: 1.5px solid rgba(250, 249, 252, 0.4); border-radius: 8px; padding: 8px 14px; cursor: pointer;
}
.ghost:hover { border-color: var(--paper); }
.cta { font: 800 1.125rem/1 var(--display); background: var(--paper); color: var(--ink); border-radius: 8px; padding: 10px 16px; text-decoration: none; }

.meters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 16px 0 0; border-top: 1px solid rgba(255, 255, 255, 0.14); }
.meters div { padding: 18px 16px 22px; border-left: 1px solid rgba(255, 255, 255, 0.14); }
.meters div:first-child { border-left: 0; padding-left: 0; }
.meters dt { font-size: 0.875rem; color: rgba(250, 249, 252, 0.7); }
.meters dd { margin: 4px 0 0; font: 800 clamp(1.6rem, 3vw, 2.25rem)/1 var(--display); color: var(--lamp); font-variant-numeric: tabular-nums; }

.game-body { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 56px; margin-top: 48px; align-items: start; }
.prose { max-width: 68ch; }
.prose .lead { margin-top: 0; }
.prose h2 { margin: 1.5em 0 0.45em; }
.prose p, .prose li { color: #2B2340; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 0.4em 0; }
.prose li::marker { color: var(--muted); }
.prose a { font-weight: 700; }

.faq { border-top: 1.5px solid var(--line); margin-top: 12px; }
.faq details { border-bottom: 1.5px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 16px 36px 16px 0; font-weight: 700; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 10px; font: 800 1.6rem/1 var(--display); color: var(--muted); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 18px; }

.side { display: grid; gap: 28px; position: sticky; top: 20px; }
.side h2 { font-size: 1.75rem; margin-bottom: 12px; }
.specs { background: var(--surface); border: 1.5px solid var(--line); border-radius: 12px; padding: 22px 22px 18px; }
.specs table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
.specs th, .specs td { text-align: left; vertical-align: top; padding: 8px 0; border-bottom: 1px solid var(--line); }
.specs th { color: var(--muted); font-weight: 400; width: 42%; padding-right: 12px; }
.specs td { font-weight: 700; }
.specs td small { display: block; font-weight: 400; color: var(--muted); font-size: 0.8125rem; margin-top: 2px; }
.specs h3 { font-size: 0.9375rem; margin: 18px 0 8px; }
.tags { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { font-size: 0.8125rem; padding: 4px 10px; border-radius: 999px; background: #F1EEF6; }

.more ul { list-style: none; padding: 0; margin: 0; }
.more li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.more li a { font-weight: 700; }
.more li span { color: var(--muted); font-size: 0.9375rem; white-space: nowrap; }
.all-link { display: inline-block; margin-top: 12px; font-weight: 700; }

.related { margin-top: 72px; }
.related h2 { margin-bottom: 20px; }

/* ---------- Provider pages ---------- */
.prov-head { padding-top: 28px; }
.prov-head h1 { text-decoration: underline; text-decoration-color: var(--c); text-decoration-thickness: 0.12em; text-underline-offset: 0.14em; margin-bottom: 18px; }
.prov-text p { max-width: 66ch; }
.prov-facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  margin: 28px 0 0; background: var(--cabinet); color: var(--paper);
  border-radius: 12px; border-top: 6px solid var(--c); padding: 4px 0;
}
.prov-facts div { padding: 16px 22px 18px; border-left: 1px solid rgba(255, 255, 255, 0.14); }
.prov-facts div:first-child { border-left: 0; }
.prov-facts dt { font-size: 0.875rem; color: rgba(250, 249, 252, 0.7); }
.prov-facts dd { margin: 4px 0 0; font: 800 clamp(1.5rem, 2.4vw, 1.9rem)/1.05 var(--display); color: var(--lamp); }

.compare { margin-top: 48px; }
.table-scroll { overflow-x: auto; }
.compare table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; min-width: 560px; }
.compare th, .compare td { text-align: left; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line); }
.compare thead th { font-weight: 700; color: var(--muted); border-bottom: 1.5px solid var(--ink); }
.compare tbody th { font-weight: 700; }
.compare td { font-variant-numeric: tabular-nums; }
.prov-table tbody th { box-shadow: inset 6px 0 0 var(--c); padding-left: 18px; }
.prov-table tbody th a { font-family: var(--display); font-weight: 800; font-size: 1.4rem; text-decoration: none; }
.prov-table tbody th small { display: block; font-weight: 400; color: var(--muted); margin-top: 4px; }

.notfound .play { margin-top: 12px; font-size: 1.25rem; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .game-body { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .side { position: static; }
  .meters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .meters div:nth-child(4) { border-left: 0; padding-left: 0; }
  .meters div:nth-child(n + 4) { border-top: 1px solid rgba(255, 255, 255, 0.14); }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .stage { aspect-ratio: 4 / 5; }
  .stage-wrap { padding-top: 16px; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .tile { padding: 10px 11px 10px; aspect-ratio: 4 / 3.9; gap: 6px; }
  .tile-name { font-size: 1.35rem; }
  .tile-meta { flex-direction: column; align-items: flex-start; gap: 2px; font-size: 0.75rem; }
  .tile-figs b { margin-left: 4px; }
  .meters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meters div, .meters div:nth-child(4) { border-left: 0; padding-left: 0; border-top: 1px solid rgba(255, 255, 255, 0.14); }
  .meters div:nth-child(even) { padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, 0.14); }
  .meters div:first-child, .meters div:nth-child(2) { border-top: 0; }
  .foot-grid { grid-template-columns: minmax(0, 1fr); }
  .search { width: 100%; }
  .search input { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* Original game covers: keep embedded titles and logos visible. */
.tile { aspect-ratio: auto; padding: 0; gap: 0; background: #21152e; }
.tile-art { position: static; display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; z-index: auto; }
.tile::after { display: none; }
.tile-name { padding: 12px 14px 0; font-size: clamp(1.45rem, 2.4vw, 1.8rem); }
.tile-meta { padding: 10px 14px 14px; }
.stage-art { object-fit: contain; background: #21152e; }
