/*
 * game.css – visual base for all game pages (SEO pages + overviews).
 * World/season look comes from CSS variables, set by CBGamePage from skin.json.
 */
:root {
  --cb-font: 'Fredoka', system-ui, sans-serif;
  --cb-font-head: var(--cb-font);
  --cb-bg: #faf7f2;
  --cb-bg-bottom: #f1e8da;
  --cb-text: #333333;
  --cb-accent: #c0602a;
  --cb-radius: 16px;
  /* Page = darkened skin colors → focus on the game. Override per skin: skin.json → page.bg / page.bgBottom */
  --cb-page-bg: color-mix(in srgb, var(--cb-bg-bottom) 40%, #0b0d14);
  --cb-page-bg-bottom: color-mix(in srgb, var(--cb-bg) 22%, #05060a);
  --cb-page-text: #ffffff;
  --cb-page-link: color-mix(in srgb, var(--cb-accent) 45%, #ffffff);
}

html { background: var(--cb-page-bg-bottom); }
body {
  margin: 0;
  font: 400 17px/1.55 var(--cb-font);
  color: var(--cb-page-text);
  background: linear-gradient(var(--cb-page-bg), var(--cb-page-bg-bottom));
  min-height: 100vh;
  min-height: 100dvh;
}
main { max-width: 720px; margin: 0 auto; padding: 12px 16px; }
h1 { font-family: var(--cb-font-head); font-weight: 700; font-synthesis: none; font-size: clamp(1.5rem, 6vw, 2.1rem);
  line-height: 1.15; margin: .25em 0 .45em; text-align: center; }
a { color: var(--cb-page-link); }

.cb-icon { width: 1.1em; height: 1.1em; vertical-align: -0.18em; fill: currentColor; }
.cb-back { display: inline-flex; align-items: center; gap: .35em; text-decoration: none; font-weight: 600; }
.cb-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.cb-lang { font-size: .9rem; opacity: .85; }
.cb-lang a { text-decoration: none; }

.cb-game { display: block; aspect-ratio: 480 / 800; height: auto; margin: 0 auto; border: 0;
  /* exactly the game's aspect ratio → no black bars; fits the screen height below nav + title */
  width: min(100%, 480px, calc((100vh - 140px) * 0.6));
  width: min(100%, 480px, calc((100dvh - 140px) * 0.6));
  border-radius: var(--cb-radius); background: transparent;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .45); }
main > p { max-width: 480px; margin: 1.2em auto; }

.cb-list { list-style: none; padding: 0; display: grid; gap: 12px; }
.cb-list a { display: block; padding: 14px 18px; border-radius: var(--cb-radius); background: rgba(255, 255, 255, .12); color: #fff;
  text-decoration: none; font-family: var(--cb-font-head); font-weight: 600; font-size: 1.25rem; }
.cb-list a:hover { background: rgba(255, 255, 255, .22); }

footer { font-size: .85rem; opacity: .75; text-align: center; padding: 24px 16px; }
footer a { color: inherit; }
