@font-face {
  font-family: 'Lexend';
  src: url(assets/fonts/lexend-latin.woff2) format('woff2');
  font-weight: 400 700;
  font-display: swap;
}

/* A light, daytime page: each game brings its own world and colours, so the valley itself stays plain paper and ink */
:root {
  --font: 'Lexend', ui-rounded, 'SF Pro Rounded', system-ui, sans-serif;
  --paper: #f6f3ec;
  --ink: #1e2a3f;
  --muted: #5d6679;
  --accent: #1e7466;
  --focus: #e9a93b;
  --gap: clamp(16px, 4vw, 48px);
  /* the text grows with the screen: 16 px on a phone, about 21 px on a laptop */
  font-size: clamp(16px, 0.6vw + 11px, 22px);
}
html.large { font-size: calc(1.18 * clamp(16px, 0.6vw + 11px, 22px)); }
@media (prefers-reduced-motion: no-preference) { html:not(.still) { scroll-behavior: smooth; } }

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--paper); }
body {
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.5;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

h1, h2, h3, h4 { margin: 0; line-height: 1.12; font-weight: 700; }
p { margin: 0; }
a { color: var(--accent); text-underline-offset: 0.2em; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus { outline: none; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; border-radius: 6px; }
.note { color: var(--muted); font-size: 0.9rem; }

/* ---------- the top line ---------- */

.top {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1.4rem;
  max-width: 76rem; margin: 0 auto;
  padding: max(14px, env(safe-area-inset-top)) var(--gap) 0;
}
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 1.05rem; }
.brand img { height: 1.15rem; width: auto; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 1.2rem; font-size: 0.9rem; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; }
.nav button { font-weight: 600; color: var(--muted); }
.nav button[aria-pressed="true"] { color: var(--ink); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.3em; }
.langs { display: inline-flex; gap: 0.8rem; }

/* ---------- the opening ---------- */

main { max-width: 76rem; margin: 0 auto; padding: 0 var(--gap); }
.hero { padding: clamp(2.5rem, 9vh, 6rem) 0 clamp(2rem, 6vh, 4rem); max-width: 46rem; }
.overline { color: var(--accent); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.8rem; }
.hero h1 { font-size: clamp(2.6rem, 5.5vw, 4.4rem); letter-spacing: -0.01em; margin: 0.6rem 0 1rem; }
.lead { font-size: clamp(1.15rem, 1.6vw, 1.45rem); color: var(--ink); }
.promise-line { margin-top: 0.8rem; color: var(--muted); font-size: 1.05rem; }

/* ---------- the games: a numbered tile each, its own picture, the whole tile opens it ---------- */

.games h2, .grownups h2 { font-size: 1.6rem; margin-bottom: 1.2rem; }
.tiles {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 2rem 1.6rem;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr));
}
.tile { display: flex; flex-direction: column; gap: 0.35rem; color: var(--ink); text-decoration: none; }
.tile img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 14px; margin-bottom: 0.55rem; }
.num { color: var(--muted); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: 0.06em; font-size: 0.85rem; }
.skill { color: var(--accent); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 0.75rem; }
.tile h3 { font-size: 1.35rem; }
.tile .about { color: var(--muted); }
.tile .go { margin-top: 0.3rem; font-weight: 700; color: var(--accent); }
.tile .go span { color: var(--muted); font-weight: 500; }
.tile:hover h3, .tile:focus-visible h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.2em; }

.making { margin-top: 3rem; }
.making h3 { font-size: 1.15rem; }
.making ol {
  list-style: none; margin: 1rem 0 0; padding: 0;
  display: grid; gap: 1rem 1.6rem;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
}
.making li { display: grid; gap: 0.1rem; }
.making strong { font-size: 1.05rem; }

/* ---------- for grown-ups ---------- */

.grownups { padding: clamp(3rem, 9vh, 6rem) 0 1rem; }
.columns { display: grid; gap: 1rem 3rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.grownups h3 { font-size: 1.1rem; margin: 1.4rem 0 0.6rem; }
.promise { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.45rem; }
.results { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.1rem; }
.result h4 { font-size: 1rem; }
.result dl { display: grid; grid-template-columns: auto 1fr; gap: 0.15rem 1rem; margin: 0.35rem 0; }
.result dt { color: var(--muted); }
.result dd { margin: 0; font-weight: 600; }
.result .note { margin-top: 0.1rem; }
.behind { margin: 0; display: grid; gap: 0.2rem 2rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr)); }
.behind div { padding: 0.5rem 0; }
.behind dt { font-weight: 700; }
.behind dd { margin: 0.1rem 0 0; color: var(--muted); }
.grownups > .note { margin-top: 1.6rem; }

/* ---------- O&Z ---------- */

.foot {
  max-width: 76rem; margin: 0 auto;
  padding: 3rem var(--gap) max(2rem, env(safe-area-inset-bottom));
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1rem; color: var(--muted); font-size: 0.9rem;
}
.oz { height: 1.2rem; width: auto; }
.slogan { font-style: italic; }
