/*
  MARA GAMES public site. One stylesheet, tokens from the design (design/export/*.png) in :root, mobile first.
  Sections: fonts, tokens, base, typography, layout, buttons, cards, header and menu, footer, utilities, shell pages.
*/

/* ---------- Fonts (self-hosted, see fonts/LICENSES.md) ---------- */

@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/outfit-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/outfit-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;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/inter-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/inter-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;
}

/* Share Tech Mono has no latin-ext subset: letters such as "ě" fall back to the next font of the stack. */
@font-face {
  font-family: "Share Tech Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/share-tech-mono-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;
}

@font-face {
  font-family: "Saira Condensed";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-ext-400.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: "Saira Condensed";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-400.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: "Saira Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-ext-600.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: "Saira Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-600.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: "Saira Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-ext-700.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: "Saira Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/saira-condensed-latin-700.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;
}

/* ---------- Design tokens ---------- */

:root {
  /* Colours (sampled from the design exports) */
  --color-bg: #0b0c0e;
  --color-surface: #12141a;
  --color-surface-raised: #171a21;
  --color-border: #2a2d33;
  --color-border-strong: #5a5e66;
  --color-text: #f4f5f6;
  --color-text-2: #b6bac1;
  --color-muted: #8a8f99;
  --color-accent: #ff7518;
  --color-accent-hover: #ff8a3a;
  --color-on-accent: #0b0c0e;
  --color-overlay: rgb(11 12 14 / 72%);

  /* Cookie consent (design/export/Cookie-spec.md); a microsite maps them to its theme in microsite.css */
  --ck-line: var(--color-border);
  --ck-neutral: #e8eaee;
  --ck-neutral-hover: #fff;
  --ck-neutral-active: #c9ccd3;
  --ck-on-neutral: var(--color-bg);
  --ck-accent-active: #e5650f;
  --ck-toggle-off: #6b707a;
  --ck-toggle-locked: #3a3e47;
  --ck-overlay: rgb(5 6 10 / 70%);
  /* Height of the sticky "Get the game" bar of a classic project on phones (the consent bar stacks above it) */
  --cta-bar-h: calc(73px + env(safe-area-inset-bottom, 0px));

  /* Fonts */
  --font-body: "Outfit", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-ui: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Share Tech Mono", ui-monospace, "Cascadia Mono", Consolas, "Courier New", monospace;
  --font-display-condensed: "Saira Condensed", "Arial Narrow", sans-serif;

  /* Type scale */
  --fs-xs: 0.75rem;
  --fs-label: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-lg: 1.125rem;
  --fs-h3: 1.5rem;
  --fs-h2: 2.125rem;
  --fs-h1: clamp(2.5rem, 1.5rem + 4vw, 4rem);

  /* Space and shape */
  --gutter: 20px;
  --wrap: 1312px;
  --section-y: 64px;
  --header-h: 76px;
  --radius: 2px;
  --gap: 24px;
  --tap: 44px;
}

@media (min-width: 640px) {
  :root {
    --gutter: 32px;
    --section-y: 80px;
  }
}

@media (min-width: 900px) {
  :root {
    --gutter: 64px;
    --section-y: 96px;
    --header-h: 112px;
    --fs-label: 0.8125rem;
    --fs-h2: 3.25rem;
  }
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  font-weight: 300;
  line-height: 1.6;
  overflow-wrap: break-word;
}

main {
  flex: 1 0 auto;
}

main:focus {
  outline: none;
}

img,
svg,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

::selection {
  background: var(--color-accent);
  color: var(--color-on-accent);
}

/* ---------- Typography ---------- */

.h1,
.h2 {
  font-weight: 200;
  line-height: 1.25;
  letter-spacing: 0;
}

.h1 {
  font-size: var(--fs-h1);
}

.h2 {
  font-size: var(--fs-h2);
}

.h3 {
  font-size: var(--fs-h3);
  font-weight: 400;
  line-height: 1.25;
}

.h1 + .lead,
.h2 + .lead {
  margin-top: 20px;
}

.lead {
  max-width: 60ch;
  color: var(--color-text-2);
  font-size: var(--fs-lg);
  line-height: 1.6;
}

.mono {
  font-family: var(--font-mono);
  font-weight: 400;
  letter-spacing: 0.08em;
}

/* Small uppercase label: dates, platforms, strip captions. */
.label {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* Section marker such as "01 / GAMES". */
.eyebrow {
  margin-bottom: 16px;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-accent);
}

.text-muted {
  color: var(--color-muted);
}

/* Text link with an arrow, e.g. "Details". */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: var(--tap);
  color: var(--color-accent);
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: none;
}

.link-arrow::after {
  content: "→";
}

.link-arrow:hover {
  color: var(--color-accent-hover);
}

/* Rich text from the administration (descriptions, news, pages). */
.prose {
  max-width: 70ch;
  color: var(--color-text-2);
}

.prose > * + * {
  margin-top: 1em;
}

.prose h2,
.prose h3,
.prose h4 {
  margin-top: 1.75em;
  color: var(--color-text);
  font-weight: 400;
  line-height: 1.25;
}

.prose h2 {
  font-size: 1.75rem;
}

.prose h3 {
  font-size: 1.375rem;
}

.prose a {
  color: var(--color-accent);
  text-underline-offset: 3px;
}

.prose a:hover {
  color: var(--color-accent-hover);
}

.prose ul,
.prose ol {
  padding-left: 1.4em;
}

.prose ul {
  list-style: disc;
}

.prose ol {
  list-style: decimal;
}

.prose li + li {
  margin-top: 0.35em;
}

.prose blockquote {
  margin-left: 0;
  padding-left: 1em;
  border-left: 2px solid var(--color-accent);
  color: var(--color-text);
}

.prose img {
  border-radius: var(--radius);
}

/* ---------- Layout ---------- */

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: calc(var(--section-y) - 8px) var(--section-y);
}

.section--line {
  border-top: 1px solid var(--color-border);
}

.section--alt {
  background: var(--color-surface);
}

/* Heading row of a section: title left, "all ..." link right. */
.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 24px;
  margin-bottom: 40px;
}

.section-head .eyebrow {
  flex-basis: 100%;
  margin-bottom: 0;
}

.grid {
  display: grid;
  gap: var(--gap);
}

@media (min-width: 640px) {
  .grid--2,
  .grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1000px) {
  .grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Header of an inner page (list, news, text page): eyebrow, title, intro. */
.page-head {
  padding-block: 40px 0;
}

.page-head .lead {
  margin-top: 20px;
}

@media (min-width: 900px) {
  .page-head {
    padding-top: 56px;
  }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 26px;
  border: 2px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.btn--primary {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--color-on-accent);
  font-weight: 600;
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
}

.btn--outline {
  border-color: var(--color-border-strong);
  background: rgb(11 12 14 / 40%);
}

.btn--outline:hover {
  border-color: var(--color-text-2);
}

.btn--accent-outline {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.btn--accent-outline:hover {
  background: var(--color-accent);
  color: var(--color-on-accent);
}

.btn--block {
  display: flex;
  width: 100%;
}

.btn--sm {
  min-height: var(--tap);
  padding: 0 20px;
}

/* Line icons of YouTube, Patreon, Google Play and the App Store in front of the label (app/Site/BrandIcons.php). */
.btn__icon,
.social-icon {
  flex: none;
  fill: none;
  stroke: currentcolor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn__icon {
  width: 20px;
  height: 20px;
}

.social-icon {
  width: 16px;
  height: 16px;
}

/* The Patreon symbol is the official picture (img/brands/patreon-symbol.png) painted in the colour of the text. */
.btn__icon--patreon,
.social-icon--patreon {
  display: inline-block;
  background: currentcolor;
  -webkit-mask: url("../img/brands/patreon-symbol.png") center / contain no-repeat;
  mask: url("../img/brands/patreon-symbol.png") center / contain no-repeat;
}

/* Official store badges, shown unchanged: Google Play (the file has its own clear space) is 1.5 times as high as the App Store one. */
.store-badge {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  border-radius: 8px;
}

.store-badge img {
  width: auto;
}

.store-badge--google img {
  height: 63px;
  margin-block: -7px;
}

.store-badge--apple img {
  height: 42px;
}

.btn-row--stack .store-badge {
  align-self: flex-start;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (min-width: 900px) {
  .btn {
    min-height: 48px;
    font-size: 0.9375rem;
  }

  .btn-row {
    gap: 14px;
  }
}

/* ---------- Cards ---------- */

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 0;
}

.card--link {
  transition: border-color 0.15s;
}

.card--link:hover,
.card--link:focus-within {
  border-color: var(--color-border-strong);
}

.card__media {
  position: relative;
  aspect-ratio: 350 / 190;
  overflow: hidden;
  background: linear-gradient(160deg, #2a1608 0%, var(--color-surface) 70%);
}

.card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: 18px;
}

.card__title {
  font-size: var(--fs-h3);
  font-weight: 300;
  line-height: 1.25;
}

.card__text {
  color: var(--color-text-2);
  font-size: 0.9375rem;
  line-height: 1.5;
}

@media (min-width: 640px) {
  .card__media {
    aspect-ratio: 421 / 220;
  }

  .post-card .card__media {
    aspect-ratio: 421 / 170;
  }

  .card__body {
    gap: 10px;
    padding: 22px;
  }

  .card__title {
    font-size: 1.625rem;
  }

  .post-card .card__body {
    gap: 8px;
  }
}

/* A card whose whole area is the link of its title. */
.card__title a {
  text-decoration: none;
}

.card__title a::after {
  content: "";
  position: absolute;
  inset: 0;
}

/* ---------- Header and menu ---------- */

.site-header {
  position: relative;
  z-index: 50;
  background: var(--color-bg);
}

/* Pages that start with an image: the header floats over it. */
.has-hero .site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: transparent;
}

.site-header__bar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
}

.logo {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
}

.logo img {
  width: auto;
  height: 42px;
}

.nav-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  margin-right: -10px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.nav-toggle__bars,
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-text);
  transition: transform 0.2s, background-color 0.2s;
}

.nav-toggle__bars {
  position: relative;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav-toggle__bars::before {
  top: -7px;
}

.nav-toggle__bars::after {
  top: 7px;
}

.menu-open .nav-toggle__bars {
  background: transparent;
}

.menu-open .nav-toggle__bars::before {
  transform: translateY(7px) rotate(45deg);
}

.menu-open .nav-toggle__bars::after {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile: full-screen menu below the bar (logo and toggle stay on top of it). */
.site-menu {
  position: fixed;
  z-index: -1;
  inset: 0;
  display: none;
  padding: calc(var(--header-h) + 22px) var(--gutter) 40px;
  overflow-y: auto;
  background: var(--color-bg);
}

.menu-open {
  overflow: hidden;
}

.menu-open .site-menu {
  display: block;
}

.menu-open .site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--color-bg);
}

.site-nav li {
  border-bottom: 1px solid var(--color-border);
}

.site-nav a {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 82px;
  text-decoration: none;
}

.site-nav__num {
  width: 14px;
  color: var(--color-accent);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
}

.site-nav__label {
  font-size: 2.0625rem;
  font-weight: 300;
  line-height: 1.2;
}

.site-nav__arrow {
  margin-left: auto;
  color: var(--color-muted);
  font-size: 1.25rem;
}

.site-nav a:hover .site-nav__label,
.site-nav a[aria-current] .site-nav__label {
  color: var(--color-accent);
}

.site-menu__cta {
  min-height: 52px;
  margin-top: 32px;
}

.site-menu__links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 24px;
  margin-top: 8px;
  color: var(--color-muted);
  font-size: var(--fs-xs);
}

.site-menu__links a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  text-decoration: none;
}

.site-menu__links a:hover {
  color: var(--color-text);
}

/* Without JavaScript the toggle does nothing: css/nojs.css shows the menu inline instead. */
@media (min-width: 900px) {
  .site-header__bar {
    gap: 32px;
  }

  .logo img {
    height: 52px;
  }

  .nav-toggle,
  .site-menu__links {
    display: none;
  }

  .menu-open {
    overflow: visible;
  }

  /* The menu parts become direct children of the bar: logo, nav and button spread over its width. */
  .site-menu,
  .menu-open .site-menu {
    display: contents;
  }

  .site-nav ol {
    display: flex;
    gap: 40px;
  }

  .site-nav li {
    border: 0;
  }

  .site-nav a {
    min-height: var(--tap);
    color: var(--color-text-2);
  }

  .site-nav a:hover,
  .site-nav a[aria-current] {
    color: var(--color-text);
  }

  .site-nav__num,
  .site-nav__arrow {
    display: none;
  }

  .site-nav__label,
  .site-nav a:hover .site-nav__label,
  .site-nav a[aria-current] .site-nav__label {
    color: inherit;
    font-size: 0.9375rem;
    font-weight: 400;
  }

  .site-menu__cta {
    width: auto;
    min-height: var(--tap);
    margin-top: 0;
    padding: 0 22px;
    background: transparent;
    border-color: var(--color-accent);
    color: var(--color-accent);
    font-weight: 500;
  }

  .site-menu__cta:hover {
    background: var(--color-accent);
    color: var(--color-on-accent);
  }
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg);
}

.site-footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding-block: 48px;
  text-align: center;
}

.site-footer .logo img {
  height: 44px;
}

.site-footer__nav ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 24px;
}

.site-footer__nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--color-text-2);
  font-size: var(--fs-sm);
  text-decoration: none;
}

.site-footer__nav a:hover {
  color: var(--color-text);
}

.site-footer__social {
  margin-top: 0;
}

.site-footer__social a {
  gap: 8px;
}

.site-footer__social a {
  color: var(--color-muted);
  font-size: var(--fs-xs);
}

.site-footer__copy {
  color: var(--color-muted);
  font-size: var(--fs-xs);
}

@media (min-width: 900px) {
  .site-footer__inner {
    flex-direction: row;
    justify-content: space-between;
    gap: 32px;
    padding-block: 40px;
    text-align: left;
  }

  .site-footer .logo img {
    height: 45px;
  }

  .site-footer__nav ul {
    gap: 0 28px;
  }

  .site-footer__nav a {
    color: var(--color-muted);
  }

  .site-footer__nav a:hover {
    color: var(--color-text);
  }
}

/* ---------- Utilities ---------- */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 100;
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 12px 20px;
  background: var(--color-accent);
  color: var(--color-on-accent);
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: none;
}

/* Draft preview (only a signed-in administrator sees it): a fixed note in a corner, outside the page layout. */
.preview-banner {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 120;
  display: grid;
  gap: 2px;
  max-width: min(420px, calc(100% - 32px));
  padding: 10px 16px;
  border: 2px solid #0b0c0e;
  border-radius: 6px;
  background: #ffd23f;
  color: #0b0c0e;
  font-size: 14px;
  line-height: 1.4;
  box-shadow: 0 8px 24px rgb(0 0 0 / 45%);
}

.preview-banner__title {
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.has-cta-bar .preview-banner {
  bottom: 92px;
}

@media (min-width: 900px) {
  .has-cta-bar .preview-banner {
    bottom: 16px;
  }
}

/* ---------- Shell pages ---------- */

.error-page .lead {
  margin-block: 20px 32px;
}

/* ---------- Home page ---------- */

.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: var(--radius);
  background: var(--color-accent);
  color: var(--color-on-accent);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Hero: darkened screenshot with a circuit overlay; the header floats over its top (body.has-hero). */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--color-bg);
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* The gradient keeps the text above 4.5:1 even over a pure white pixel (checked: light text on 76 % dark = 7:1 or more). */
.hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgb(11 12 14 / 85%) 0%, rgb(11 12 14 / 76%) 40%, rgb(11 12 14 / 80%) 70%, var(--color-bg) 100%);
}

.hero__circuit {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: url("../img/circuit.svg") center / 960px auto repeat;
  opacity: 0.3;
}

.hero__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: calc(var(--header-h) + 40px);
  text-align: center;
}

.hero__logo {
  width: min(260px, 72%);
  height: auto;
}

.hero__eyebrow {
  margin-top: 20px;
  color: var(--color-text-2);
  font-size: var(--fs-xs);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.hero__eyebrow + .h1 {
  margin-top: 12px;
}

.hero__inner .h1 {
  margin-top: 28px;
  font-size: 1.625rem;
  line-height: 1.2;
  letter-spacing: 0;
}

.hero__line {
  max-width: 34ch;
  margin-top: 14px;
  color: var(--color-text);
  font-size: var(--fs-xs);
  letter-spacing: 0.2em;
  line-height: 1.8;
  text-transform: uppercase;
}

.hero .btn-row {
  width: 100%;
  max-width: 420px;
  flex-direction: column;
  margin-top: 32px;
}

.hero .btn {
  width: 100%;
}

/* Strip under the hero: who, what, how, support. */
.home-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 20px;
  margin-top: 48px;
  padding-block: 28px 40px;
  border-top: 1px solid var(--color-border);
}

.home-strip li {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.home-strip .label {
  color: var(--color-text-2);
  font-size: var(--fs-xs);
}

.home-strip__value {
  font-size: 1.125rem;
  font-weight: 200;
  line-height: 1.2;
}

.home-strip__text {
  color: var(--color-text-2);
  font-size: var(--fs-xs);
  line-height: 1.5;
}

@media (min-width: 900px) {
  .hero__inner {
    padding-top: calc(var(--header-h) + 57px);
  }

  .hero__logo {
    width: 440px;
  }

  .hero__inner .h1 {
    margin-top: 40px;
    font-size: 2rem;
  }

  .hero__eyebrow + .h1 {
    margin-top: 14px;
  }

  .hero__line {
    max-width: none;
    margin-top: 12px;
  }

  .hero .btn-row {
    width: auto;
    max-width: none;
    flex-direction: row;
    justify-content: center;
    margin-top: 48px;
  }

  .hero .btn {
    width: auto;
  }

  .home-strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0 32px;
    margin-top: 154px;
    padding-block: 22px 40px;
  }

  .home-strip .label {
    font-size: var(--fs-label);
    letter-spacing: 2px;
  }

  .home-strip__value {
    font-size: 1.5rem;
  }

  .home-strip__text {
    font-size: var(--fs-sm);
    font-weight: 300;
  }
}

/* Latest news on the alternate surface: raised cards without a border (design: #171A21). */
.section--alt .post-card {
  border-color: transparent;
  background: var(--color-surface-raised);
}

/* Project and post cards. */
.card__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.card__num {
  color: var(--color-accent);
}

.card__year {
  margin-left: auto;
}

.card__meta {
  margin-top: -2px;
  font-size: 0.6875rem;
}

@media (min-width: 640px) {
  .card__meta {
    font-size: var(--fs-xs);
  }
}

.card__more {
  margin-top: auto;
  min-height: 0;
  padding-top: 4px;
}

.card__title--sm {
  font-size: 1.25rem;
  font-weight: 400;
}

@media (min-width: 640px) {
  .card__title--sm {
    font-size: 1.3125rem;
  }
}

/* Section 02: text with the button on the left, "What supporters get" on the right. */
.support {
  display: grid;
  gap: 32px;
  align-items: center;
}

.support__main .eyebrow {
  margin-bottom: 20px;
}

.support__main .lead {
  max-width: 560px;
  margin-bottom: 20px;
  font-size: var(--fs-base);
}

.support__card {
  padding: 20px;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  border-radius: var(--radius);
}

.support__card .label {
  display: block;
  padding-bottom: 12px;
  letter-spacing: 2px;
  border-bottom: 1px solid var(--color-border);
}

.support__card li {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 48px;
  color: var(--color-text);
  font-size: var(--fs-base);
}

.support__card li + li {
  border-top: 1px solid var(--color-border);
}

.icon {
  flex: none;
  fill: none;
  stroke: var(--color-accent);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Section 03: on a phone the posts are a swipeable row, the "All news" link sits under it. */
.section-foot__all {
  margin-top: 16px;
}

.section-head__all {
  display: none;
}

@media (max-width: 639.98px) {
  .post-grid {
    display: flex;
    margin-inline: calc(-1 * var(--gutter));
    padding-inline: var(--gutter);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }

  .post-grid::-webkit-scrollbar {
    display: none;
  }

  .post-grid > .card {
    flex: 0 0 82%;
    scroll-snap-align: start;
  }
}

@media (min-width: 640px) {
  .section-head__all {
    display: inline-flex;
  }

  .section-foot__all {
    display: none;
  }
}

/* Section 04: statement on the left, text, buttons and the publishers block on the right. */
.about {
  display: grid;
  gap: 32px;
}

.about__main .h2 {
  max-width: 18em;
  font-size: 2rem;
  line-height: 1.15;
}

@media (min-width: 900px) {
  .about__main .h2 {
    font-size: 2.75rem;
  }

}

.about__intro {
  margin-bottom: 24px;
  color: var(--color-text-2);
  font-size: var(--fs-base);
}

@media (min-width: 900px) {
  .about__intro {
    font-size: var(--fs-lg);
  }
}

.about__side .btn-row {
  flex-direction: column;
}

.about__press {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
  color: var(--color-text-2);
  font-size: var(--fs-sm);
}

/* The label is a link to the press page: underlined, light text, a 44px tap target. */
.about__press-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--color-text);
  text-decoration: underline;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 4px;
}

.about__press-link:hover {
  color: var(--color-accent-hover);
}

@media (min-width: 640px) {
  .about__side .btn-row {
    flex-direction: row;
  }
}

@media (min-width: 1000px) {
  .support {
    grid-template-columns: minmax(0, 752fr) minmax(0, 480fr);
    gap: 80px;
  }

  .support__card {
    padding: 28px;
  }

  .support__card .label {
    padding-bottom: 8px;
    font-size: var(--fs-xs);
  }

  .support__card li {
    gap: 16px;
    min-height: 59px;
    font-size: var(--fs-lg);
  }

  .support__card .icon {
    width: 22px;
    height: 22px;
  }

  .support__main .lead {
    font-size: var(--fs-lg);
  }

  .about {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 80px;
  }
}

/* ---------- Project page (classic) ---------- */

/* Hero of a project: same darkened picture as the home hero, text on the left. */
.hero--project .hero__inner {
  align-items: flex-start;
  padding-top: calc(var(--header-h) + 24px);
  padding-bottom: 48px;
  text-align: left;
}

.hero--project .hero__inner .h1 {
  margin-top: 8px;
  font-size: clamp(2rem, 1.1rem + 4vw, 4.75rem);
  line-height: 1.05;
}

.hero--project .lead {
  max-width: 48ch;
  margin-top: 16px;
}

.hero--project .btn-row {
  width: 100%;
  max-width: none;
  flex-direction: column;
  justify-content: flex-start;
  margin-top: 28px;
}

.hero--project .btn {
  width: 100%;
}

@media (min-width: 640px) {
  .hero--project .btn-row {
    width: auto;
    flex-direction: row;
  }

  .hero--project .btn {
    width: auto;
  }
}

@media (min-width: 900px) {
  .hero--project {
    min-height: 600px;
  }

  .hero--project .hero__inner {
    padding-top: calc(var(--header-h) + 74px);
    padding-bottom: 88px;
  }

  .hero--project .lead {
    font-size: 1.25rem;
  }
}

.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 12px;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-muted);
}

.crumbs li + li::before {
  content: "/";
  margin-right: 12px;
}

.crumbs a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--color-text);
}

.crumbs [aria-current] {
  color: var(--color-text-2);
}

/* Over a hero picture the muted grey would fall below 4.5:1 on a light picture (tools/a11y-check.php): one step lighter. */
.hero .crumbs ol {
  color: var(--color-text-2);
}

.hero .crumbs [aria-current] {
  color: var(--color-text);
}

.hero__badge {
  margin-top: 4px;
}

.badge--inline {
  position: static;
  display: inline-block;
}

/* Content: trailer, about, facts card, details, screenshots and news. The card sits beside the blocks on wide screens. */
.project {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  padding-block: 40px var(--section-y);
}

.project__block {
  grid-column: 1;
  margin-top: 56px;
}

.project > :first-child {
  margin-top: 0;
}

.project__aside {
  grid-column: 1;
  margin-top: 48px;
}

.project--single {
  max-width: 880px;
}

@media (min-width: 1100px) {
  .project {
    grid-template-columns: minmax(0, 1fr) 380px;
    column-gap: 64px;
    padding-top: 40px;
  }

  .project--single {
    grid-template-columns: minmax(0, 1fr);
  }

  .project__aside {
    grid-column: 2;
    grid-row: 1 / span 6;
    align-self: start;
    margin-top: 0;
  }
}

/* The news row sits next to the card, so it fits as many columns as there is room for. */
.project .post-grid {
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

.prose--lead {
  max-width: 70ch;
  font-size: var(--fs-lg);
}

/* Trailer: poster and play button, replaced by the player on click (js/trailer.js). */
.trailer {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  background: var(--color-surface);
}

@media (min-width: 900px) {
  .trailer {
    aspect-ratio: 868 / 440;
  }
}

.trailer__play {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.trailer__poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.trailer__play::after {
  content: "";
  position: absolute;
  inset: 0;
  /* Darker at the top, where the label sits: light text keeps 4.5:1 even over a white pixel (tools/a11y-check.php). */
  background: linear-gradient(180deg, rgb(11 12 14 / 80%) 0%, rgb(11 12 14 / 60%) 20%, rgb(11 12 14 / 10%) 45%, rgb(11 12 14 / 20%) 100%);
}

.trailer__label {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 1;
  color: var(--color-text);
}

.trailer__icon {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  margin: -36px 0 0 -36px;
  border-radius: 50%;
  background: var(--color-accent);
  color: var(--color-on-accent);
  transition: background-color 0.15s, transform 0.15s;
}

.trailer__icon svg {
  fill: currentcolor;
  margin-left: 3px;
}

.trailer__play:hover .trailer__icon {
  background: var(--color-accent-hover);
  transform: scale(1.06);
}

.trailer__play:focus-visible {
  outline-offset: -4px;
}

.trailer__player {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
  object-fit: contain;
}

.trailer__link {
  position: absolute;
  right: 12px;
  bottom: 8px;
  z-index: 2;
}

/* Card beside the content: get the game, facts, links. */
.side-card {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 28px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 4px;
}

.side-card .eyebrow {
  margin-bottom: 0;
}

.side-card__buy {
  display: none;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--color-border);
}

.btn-row--stack {
  flex-direction: column;
}

@media (min-width: 1100px) {
  .side-card__buy {
    display: block;
  }
}

.facts > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-block: 9px;
}

.facts dt {
  color: var(--color-muted);
  font-size: 0.9375rem;
}

.facts dd {
  margin: 0;
  text-align: right;
  font-size: 0.9375rem;
  font-weight: 400;
}

.side-card__links {
  padding-top: 20px;
  border-top: 1px solid var(--color-border);
}

.side-card__links .link-arrow {
  color: var(--color-text);
}

.side-card__links .link-arrow:hover {
  color: var(--color-accent-hover);
}

/* "The game in detail": a title and a text per row, then the feature list. */
.detail {
  border-bottom: 1px solid var(--color-border);
}

.detail__row {
  display: grid;
  gap: 8px 32px;
  padding-block: 20px;
  border-top: 1px solid var(--color-border);
}

.detail__title {
  font-size: var(--fs-lg);
  font-weight: 400;
}

.detail__text {
  color: var(--color-text-2);
  font-size: 0.9375rem;
}

.features {
  margin-top: 32px;
  border-bottom: 1px solid var(--color-border);
}

.features li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 4px 16px;
  align-items: baseline;
  padding-block: 18px;
  border-top: 1px solid var(--color-border);
}

.features .icon {
  align-self: center;
  fill: none;
  stroke: var(--color-accent);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.features__title {
  font-size: var(--fs-lg);
  font-weight: 400;
}

.features__text {
  grid-column: 2;
  color: var(--color-text-2);
  font-size: var(--fs-base);
}

.detail__text > * + *,
.features__text > * + * {
  margin-top: 0.75em;
}

@media (min-width: 640px) {
  .detail__row {
    grid-template-columns: 200px minmax(0, 1fr);
  }

  .features li {
    grid-template-columns: 20px 200px minmax(0, 1fr);
  }

  .features__text {
    grid-column: auto;
  }
}

/* Screenshots: a grid on wide screens, a swipeable row on phones. */
.shots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.shot {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  transition: border-color 0.15s;
}

.shot:hover {
  border-color: var(--color-border-strong);
}

/* The ring is drawn inside: in a sideways scrolling row (phones, carousel) an outer one would be cut off. */
.shot:focus-visible {
  outline-offset: -3px;
}

.shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* A portrait screenshot is shown whole at a capped height, centered in its cell (no crop). */
.shot.shot--portrait {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: auto;
}

.shot--portrait img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 560px;
  object-fit: contain;
}

@media (max-width: 639.98px) {
  .shots {
    display: flex;
    margin-inline: calc(-1 * var(--gutter));
    padding-inline: var(--gutter);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }

  .shots::-webkit-scrollbar {
    display: none;
  }

  .shots li {
    flex: 0 0 78%;
    scroll-snap-align: start;
  }
}

/* Sticky "Get the game" bar on phones. */
.cta-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom, 0px));
  background: rgb(11 12 14 / 96%);
  border-top: 1px solid var(--color-border);
}

.cta-bar__title {
  display: -webkit-box;
  overflow: hidden;
  font-size: var(--fs-sm);
  font-weight: 500;
  line-height: 1.3;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.cta-bar .btn {
  flex: none;
  min-width: 160px;
}

.has-cta-bar {
  padding-bottom: 76px;
}

@media (min-width: 900px) {
  .cta-bar {
    display: none;
  }

  .has-cta-bar {
    padding-bottom: 0;
  }
}

/* Lightbox (js/lightbox.js). */
.lightbox-open {
  overflow: hidden;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  background: rgb(5 6 7 / 95%);
}

.lightbox[hidden],
.lightbox__btn[hidden],
.lightbox__counter[hidden] {
  display: none;
}

.lightbox__stage {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 0;
  margin: 0;
  padding: 72px 12px 96px;
}

.lightbox__img {
  max-width: 100%;
  max-height: calc(100vh - 180px);
  width: auto;
  object-fit: contain;
  border: 1px solid var(--color-border-strong);
}

.lightbox__caption {
  max-width: 70ch;
  color: var(--color-text-2);
  font-size: var(--fs-sm);
  text-align: center;
}

.lightbox__counter {
  position: absolute;
  top: 28px;
  left: var(--gutter);
}

.lightbox__btn {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 2px solid var(--color-border-strong);
  border-radius: var(--radius);
  background: rgb(11 12 14 / 80%);
  color: var(--color-text);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox__btn:hover {
  border-color: var(--color-text-2);
}

.lightbox__close {
  top: 16px;
  right: 16px;
}

.lightbox__prev,
.lightbox__next {
  bottom: 24px;
}

.lightbox__prev {
  left: 16px;
}

.lightbox__next {
  right: 16px;
}

@media (min-width: 900px) {
  .lightbox__stage {
    padding: 72px 96px;
  }

  .lightbox__prev,
  .lightbox__next {
    top: 50%;
    bottom: auto;
    margin-top: -24px;
  }

  .lightbox__prev {
    left: 24px;
  }

  .lightbox__next {
    right: 24px;
  }
}

/* ---------- News and static pages ---------- */

/* Text of an article or page: a comfortable reading width. */
.prose--article {
  max-width: 68ch;
  font-size: 1.0625rem;
  line-height: 1.7;
}

.page-body {
  padding-top: 40px;
}

.h1__sub {
  display: block;
  margin-top: 8px;
  color: var(--color-accent);
  font-size: var(--fs-h3);
  line-height: 1.2;
}

/* Filter chips above the news list. */
.chips {
  margin-top: 32px;
}

.chips ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 18px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius);
  color: var(--color-text-2);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}

.chip:hover {
  border-color: var(--color-text-2);
  color: var(--color-text);
}

.chip[aria-current] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--color-on-accent);
}

.news-list {
  padding-top: 40px;
}

/* Page links under the news list. */
.pagination {
  margin-top: 48px;
}

.pagination ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pagination__num,
.pagination__step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: var(--tap);
  min-height: var(--tap);
  padding: 0 14px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius);
  color: var(--color-text-2);
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}

.pagination__num:hover,
.pagination__step:hover {
  border-color: var(--color-text-2);
  color: var(--color-text);
}

.pagination__num[aria-current] {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.pagination__gap {
  color: var(--color-muted);
}

/* One post. */
.post__head .lead {
  max-width: 68ch;
}

.post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  margin-bottom: 16px;
}

/* Project tag of a post: the extra hit area keeps the tap target at about 44px without a tall pill. */
.tag {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius);
  color: var(--color-accent);
  text-decoration: none;
}

.tag::after {
  content: "";
  position: absolute;
  inset: -8px -4px;
}

.tag:hover {
  background: var(--color-accent);
  color: var(--color-on-accent);
}

.post__main {
  padding-block: 40px 0;
}

.post__figure {
  max-width: 960px;
  margin: 0 0 40px;
}

.post__cover {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

.post__more {
  margin-top: 32px;
}

/* Older / newer post under the article. */
.post-nav {
  display: grid;
  gap: var(--gap);
  padding-block: 56px var(--section-y);
}

.post-nav__link {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  text-decoration: none;
  transition: border-color 0.15s;
}

.post-nav__link:hover {
  border-color: var(--color-border-strong);
}

.post-nav__title {
  color: var(--color-text);
  font-size: var(--fs-lg);
  line-height: 1.3;
}

@media (min-width: 640px) {
  .post-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .post-nav__link--prev {
    grid-column: 1;
  }

  .post-nav__link--next {
    grid-column: 2;
    text-align: right;
  }
}

/* Press kit downloads. */
.downloads {
  max-width: 68ch;
  margin-top: 56px;
}

.downloads__list {
  margin-top: 16px;
  border-top: 1px solid var(--color-border);
}

.downloads__list li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 16px;
  min-height: 56px;
  border-bottom: 1px solid var(--color-border);
}

.downloads__link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--color-accent);
  text-underline-offset: 3px;
}

.downloads__link:hover {
  color: var(--color-accent-hover);
}

/* Contact card under the page text. */
.contact {
  max-width: 68ch;
  margin-top: 48px;
}

.contact__mail {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--color-accent);
  font-size: var(--fs-lg);
  text-underline-offset: 3px;
}

.contact__profiles {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
}

.contact__profiles a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  color: var(--color-text-2);
  text-underline-offset: 3px;
}

.contact__profiles a:hover {
  color: var(--color-text);
}

/* ---------- Cookie consent (app/Site/views/partials/consent.php, js/consent.js, design/export/Cookie-spec.md) ---------- */

/* The bar and the dialog stay hidden until consent.js shows them (the rules below would otherwise override [hidden]). */
.consent-bar[hidden],
.consent-dialog[hidden],
.footer-consent[hidden] {
  display: none;
}

/* Phones: a bottom sheet over the page (fixed, so nothing shifts), at most 40% of the screen. */
.consent-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 60;
  max-height: 40vh;
  overflow-y: auto;
  padding: 20px 0 calc(12px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--ck-line);
  border-radius: 10px 10px 0 0;
  background: var(--color-surface);
  box-shadow: 0 -8px 32px rgb(0 0 0 / 60%);
  animation: consent-in 0.2s ease-out;
}

@keyframes consent-in {
  from {
    transform: translateY(100%);
  }

  to {
    transform: none;
  }
}

/* A classic project page has the sticky "Get the game" bar on phones: the consent bar sits above it. */
.has-cta-bar .consent-bar {
  bottom: var(--cta-bar-h);
}

.menu-open .consent-bar {
  visibility: hidden;
}

/* Keyboard focus is never hidden behind the open bar. */
.consent-open {
  scroll-padding-bottom: 260px;
}

.consent-dialog-open {
  overflow: hidden;
}

.consent-bar__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "copy copy"
    "reject accept"
    "privacy settings";
  gap: 10px;
}

.consent-bar__copy {
  grid-area: copy;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.consent-bar__texts {
  display: contents;
}

.consent-icon {
  flex: none;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--color-accent);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.consent-bar__title {
  color: var(--color-text);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
}

.consent-bar__text {
  grid-column: 1 / -1;
  color: var(--color-text-2);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.consent-bar__privacy,
.consent-bar__privacy-row,
.consent-dialog__privacy-link {
  color: var(--color-accent);
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.consent-bar__privacy {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
}

.consent-bar__privacy-row,
.consent-dialog__privacy-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
}

.consent-bar__privacy-row {
  grid-area: privacy;
  justify-self: start;
}

.consent-bar__privacy:hover,
.consent-bar__privacy-row:hover,
.consent-dialog__privacy-link:hover {
  color: var(--color-accent-hover);
}

.consent-desktop {
  display: none;
}

.consent-bar__actions {
  display: contents;
}

.consent-bar__settings {
  grid-area: settings;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 0 0 12px;
  border: 0;
  border-radius: var(--radius);
  background: none;
  color: var(--color-text-2);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  transition: color 0.12s;
}

.consent-bar__settings:hover,
.consent-bar__settings:active {
  color: var(--color-text);
}

.consent-bar__actions [data-consent-reject] {
  grid-area: reject;
}

.consent-bar__actions [data-consent-accept] {
  grid-area: accept;
}

/* Accept and Reject: solid, same size and weight (equal prominence). */
.consent-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.12s, border-color 0.12s, color 0.12s;
}

.consent-btn--accent {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--color-on-accent);
}

.consent-btn--accent:hover {
  border-color: var(--color-accent-hover);
  background: var(--color-accent-hover);
}

.consent-btn--accent:active {
  border-color: var(--ck-accent-active);
  background: var(--ck-accent-active);
}

.consent-btn--neutral {
  border-color: var(--ck-neutral);
  background: var(--ck-neutral);
  color: var(--ck-on-neutral);
}

.consent-btn--neutral:hover {
  border-color: var(--ck-neutral-hover);
  background: var(--ck-neutral-hover);
}

.consent-btn--neutral:active {
  border-color: var(--ck-neutral-active);
  background: var(--ck-neutral-active);
}

.consent-btn--outline {
  border-color: var(--color-accent);
  background: transparent;
  color: var(--color-accent);
}

.consent-btn--outline:hover {
  background: color-mix(in srgb, var(--color-accent) 12%, transparent);
}

.consent-btn--outline:active {
  background: color-mix(in srgb, var(--color-accent) 20%, transparent);
}

/* Focus ring in the text colour: the accent ring would vanish on the accent buttons. */
.consent-btn:focus-visible,
.consent-bar__settings:focus-visible,
.consent-close:focus-visible,
.consent-switch:focus-visible,
.footer-consent:focus-visible {
  outline: 2px solid var(--color-text);
  outline-offset: 2px;
}

/* Settings dialog. Phones: a full-height sheet; from 640px: a centred dialog over a dimmed page. */
.consent-dialog {
  position: fixed;
  inset: 0;
  z-index: 210;
  display: flex;
  background: var(--color-surface);
}

.consent-dialog__panel {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  background: var(--color-surface);
}

.consent-dialog__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 12px 12px 20px;
  border-bottom: 1px solid var(--ck-line);
}

.consent-dialog__title {
  color: var(--color-text);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.2;
}

.consent-close {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: none;
  color: var(--color-text-2);
  cursor: pointer;
  transition: background-color 0.12s, color 0.12s;
}

.consent-close svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.consent-close:hover {
  background: var(--color-surface-raised);
  color: var(--color-text);
}

.consent-close:active {
  background: var(--ck-line);
}

.consent-dialog__body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 20px 0;
}

.consent-dialog__intro {
  margin-bottom: 12px;
  color: var(--color-text-2);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.consent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--ck-line);
}

.consent-row__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.consent-row__name {
  color: var(--color-text);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.3;
}

.consent-row__desc {
  color: var(--color-text-2);
  font-size: var(--fs-sm);
  line-height: 1.45;
}

.consent-row__control {
  display: flex;
  flex: none;
  align-items: center;
  gap: 12px;
}

.consent-row__state {
  color: var(--color-muted);
  font-size: var(--fs-xs);
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Switch: a 48x28 track; the ::after area makes the touch target 44px high. */
.consent-switch {
  position: relative;
  display: inline-block;
  flex: none;
  width: 48px;
  height: 28px;
  padding: 3px;
  border: 0;
  border-radius: 14px;
  background: var(--ck-toggle-off);
  cursor: pointer;
  transition: background-color 0.12s;
}

.consent-switch::after {
  content: "";
  position: absolute;
  inset: -8px 0;
}

.consent-switch__knob {
  display: block;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-text);
  transition: transform 0.12s;
}

.consent-switch:hover {
  background: color-mix(in srgb, var(--ck-toggle-off) 92%, #fff);
}

.consent-switch[aria-checked="true"] {
  background: var(--color-accent);
}

.consent-switch[aria-checked="true"]:hover {
  background: color-mix(in srgb, var(--color-accent) 92%, #fff);
}

.consent-switch[aria-checked="true"] .consent-switch__knob {
  background: var(--color-bg);
  transform: translateX(20px);
}

.consent-switch--locked,
.consent-switch--locked:hover,
.consent-switch--locked[aria-checked="true"] {
  background: var(--ck-toggle-locked);
  cursor: default;
}

.consent-switch--locked .consent-switch__knob,
.consent-switch--locked[aria-checked="true"] .consent-switch__knob {
  background: var(--color-muted);
  transform: translateX(20px);
}

.consent-dialog__privacy {
  padding-block: 8px;
}

.consent-dialog__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 20px calc(24px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--ck-line);
}

/* Phones list the buttons as designed: Accept all, Reject all, Save choice. */
.consent-dialog__accept {
  order: 1;
}

.consent-dialog__reject {
  order: 2;
}

.consent-dialog__save {
  order: 3;
}

/* Footer "Cookie settings": a button that looks like the footer links. */
.footer-consent {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0;
  border: 0;
  background: none;
  color: var(--color-text-2);
  font-family: inherit;
  font-size: var(--fs-sm);
  cursor: pointer;
}

.footer-consent:hover {
  color: var(--color-text);
}

@media (min-width: 640px) {
  .consent-dialog {
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: var(--ck-overlay);
  }

  .consent-dialog__panel {
    width: min(560px, 100%);
    height: auto;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    padding: 32px;
    border: 1px solid var(--ck-line);
    border-radius: 4px;
    box-shadow: 0 16px 48px rgb(0 0 0 / 70%);
  }

  .consent-dialog__head {
    margin: -6px -10px 8px 0;
    padding: 0;
    border: 0;
  }

  .consent-dialog__title {
    font-size: 26px;
  }

  .consent-dialog__body {
    flex: none;
    overflow: visible;
    padding: 0;
  }

  .consent-dialog__actions {
    flex-direction: row;
    gap: 12px;
    padding: 8px 0 0;
    border: 0;
  }

  .consent-dialog__actions .consent-btn {
    flex: 1 1 0;
    order: 0;
    padding-inline: 12px;
  }
}

@media (min-width: 900px) {
  .consent-bar {
    max-height: none;
    padding: 22px 0;
    border-radius: 0;
  }

  .has-cta-bar .consent-bar {
    bottom: 0;
  }

  .consent-open {
    scroll-padding-bottom: 140px;
  }

  .consent-bar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
  }

  .consent-bar__copy {
    display: flex;
    align-items: flex-start;
    gap: 16px;
  }

  .consent-bar__texts {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .consent-icon {
    width: 22px;
    height: 22px;
  }

  .consent-bar__title {
    font-size: 17px;
  }

  .consent-desktop {
    display: inline;
  }

  .consent-mobile {
    display: none;
  }

  .consent-bar__actions {
    display: flex;
    flex: none;
    align-items: center;
    gap: 12px;
  }

  .consent-bar__settings {
    padding: 0 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .consent-bar {
    animation: none;
  }
}
