@font-face {
  font-family: "Bricolage";
  src: url("/assets/fonts/bricolage-grotesque-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
}

@font-face {
  font-family: "Fraunces";
  src: url("/assets/fonts/fraunces-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #f4f6f1;
  --surface: #fffef9;
  --surface-soft: #e9efe8;
  --ink: #173f36;
  --ink-soft: #53635f;
  --line: #d5ddd5;
  --line-strong: #b9c8bf;
  --primary: #173f36;
  --primary-ink: #fffef9;
  --coral: #ef705d;
  --mint: #73b7a5;
  --gold: #f4c563;
  --violet: #7657d8;
  --shadow: 0 22px 60px rgba(24, 54, 47, 0.08);
  --shadow-small: 0 10px 28px rgba(24, 54, 47, 0.08);
  --shell: 1180px;
  --header-h: 77px;
  --sans: "Bricolage", system-ui, sans-serif;
  --serif: "Fraunces", Georgia, serif;
}

:root[data-theme="night"],
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #10231f;
  --surface: #17302a;
  --surface-soft: #1e3932;
  --ink: #edf5ed;
  --ink-soft: #afc1ba;
  --line: #315048;
  --line-strong: #46685e;
  --primary: #edf5ed;
  --primary-ink: #173f36;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.18);
  --shadow-small: 0 10px 28px rgba(0, 0, 0, 0.18);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --bg: #10231f;
    --surface: #17302a;
    --surface-soft: #1e3932;
    --ink: #edf5ed;
    --ink-soft: #afc1ba;
    --line: #315048;
    --line-strong: #46685e;
    --primary: #edf5ed;
    --primary-ink: #173f36;
    --shadow: 0 22px 60px rgba(0, 0, 0, 0.18);
    --shadow-small: 0 10px 28px rgba(0, 0, 0, 0.18);
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h, 77px) + 12px);
}

body {
  margin: 0;
  padding-top: var(--header-h, 77px);
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

button,
input,
select,
textarea {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.shell {
  width: min(calc(100% - 40px), var(--shell));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 10px;
  left: 10px;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--surface);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: fixed;
  z-index: 90;
  top: 0;
  right: 0;
  left: 0;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 75%, transparent);
  backdrop-filter: blur(16px);
}

.header-inner {
  position: relative;
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  position: relative;
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 3px;
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}

.brand-mark i {
  display: block;
  border-radius: 50%;
}

.brand-mark i:nth-child(1) { background: var(--gold); }
.brand-mark i:nth-child(2) { background: var(--coral); }
.brand-mark i:nth-child(3) { grid-column: 1 / -1; width: 14px; justify-self: center; background: var(--mint); }

.brand-copy {
  display: grid;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.08;
}

.brand-copy small {
  margin-top: 3px;
  color: var(--ink-soft);
  font-family: var(--sans);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-nav {
  position: absolute;
  top: calc(100% + 1px);
  right: 0;
  left: 0;
  display: none;
  padding: 12px 20px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-small);
}

.site-nav[data-open="true"] {
  display: grid;
}

.site-nav a {
  display: flex;
  min-height: 48px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  font-weight: 650;
  text-decoration: none;
}

.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.header-actions {
  display: flex;
  gap: 8px;
}

.icon-button {
  display: inline-grid;
  width: 44px;
  height: 44px;
  place-items: center;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  cursor: pointer;
}

.icon-button svg,
.button svg,
.circle-link svg,
.cover-action svg,
.toolbar-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-toggle:hover {
  background: var(--surface-soft);
}

.hero {
  overflow: hidden;
  padding: 58px 0 78px;
}

.hero-grid {
  display: grid;
  gap: 54px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow i {
  width: 8px;
  height: 8px;
  background: var(--coral);
  border-radius: 50%;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
}

.hero h1 {
  max-width: 760px;
  margin: 18px 0 24px;
  font-size: clamp(53px, 14vw, 108px);
}

.hero h1 em {
  color: var(--coral);
  font-weight: 450;
}

.hero-copy > p {
  max-width: 650px;
  margin-bottom: 30px;
  color: var(--ink-soft);
  font-size: 18px;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
}

.button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 20px;
  border: 1px solid var(--primary);
  border-radius: 999px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease, color 160ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--primary);
  color: var(--primary-ink);
}

.button-secondary {
  background: transparent;
  color: var(--ink);
}

.button-secondary:hover {
  background: var(--surface-soft);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding-block: 10px;
  color: var(--ink);
  font-weight: 700;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 5px;
}

.text-link svg {
  width: 15px;
  height: 15px;
  flex: none;
}

.text-link:hover {
  text-decoration-color: var(--coral);
}

.hero-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  max-width: 540px;
  margin: 40px 0 0;
  border-top: 1px solid var(--line);
}

.hero-facts div {
  padding: 16px 8px 0 0;
}

.hero-facts div + div {
  padding-left: 14px;
  border-left: 1px solid var(--line);
}

.hero-facts dt {
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 650;
}

.hero-facts dd {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
}

.hero-feature {
  display: block;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  color: var(--ink);
  text-decoration: none;
  transform: rotate(1.5deg);
  transition: transform 220ms ease;
}

.hero-feature:hover {
  transform: rotate(0deg) translateY(-4px);
}

.hero-feature > img {
  width: 100%;
  height: auto;
  aspect-ratio: 8 / 5;
  object-fit: cover;
}

.hero-feature-copy {
  display: flex;
  min-height: 94px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
}

.hero-feature-copy > span {
  display: grid;
}

.hero-feature-copy small {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero-feature-copy strong {
  font-family: var(--serif);
  font-size: 31px;
}

.hero-feature-copy > i {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  background: var(--coral);
  border-radius: 50%;
  color: #fff;
}

.hero-feature-copy svg {
  width: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.section {
  padding: 72px 0;
}

.section-tinted {
  background: var(--surface-soft);
  border-block: 1px solid var(--line);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
}

.section-heading h2,
.curation-grid h2 {
  max-width: 780px;
  margin: 10px 0 0;
  font-size: clamp(38px, 8vw, 64px);
}

.game-grid {
  display: grid;
  gap: 30px;
}

.game-card {
  min-width: 0;
}

.game-card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--surface-soft);
  border-radius: 20px;
}

.game-card-cover img {
  width: 100%;
  height: auto;
  aspect-ratio: 8 / 5;
  object-fit: cover;
  transition: transform 300ms ease;
}

.game-card-cover:hover img {
  transform: scale(1.025);
}

.cover-kicker {
  position: absolute;
  top: 14px;
  left: 14px;
  max-width: calc(100% - 28px);
  padding: 7px 10px;
  color: #f7faf4;
  background: rgba(14, 47, 42, 0.86);
  border: 1px solid rgba(247, 250, 244, 0.28);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.1;
  text-transform: uppercase;
}

.cover-action {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow-small);
}

.game-card-body {
  padding: 18px 2px 0;
}

.card-meta,
.device-line {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 18px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.game-card h3 {
  margin: 9px 0;
  font-size: 30px;
}

.game-card h3 a {
  text-decoration: none;
}

.game-card h3 a:hover {
  color: var(--coral);
}

.game-card p {
  min-height: 3.2em;
  margin-bottom: 18px;
  color: var(--ink-soft);
}

.gameplay-summary {
  display: grid;
  gap: 5px;
}

.gameplay-summary span {
  color: var(--ink);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.device-line {
  padding-top: 13px;
  border-top: 1px solid var(--line);
  font-size: 10px;
}

.collection-grid {
  display: grid;
  gap: 16px;
}

.collection-card {
  display: flex;
  min-height: 260px;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 22px;
}

.collection-puzzle { background: color-mix(in srgb, var(--gold) 24%, var(--surface)); }
.collection-arcade { background: color-mix(in srgb, var(--mint) 26%, var(--surface)); }
.collection-action { background: color-mix(in srgb, var(--coral) 20%, var(--surface)); }

.collection-card h3 {
  margin: 14px 0 10px;
  font-size: 36px;
}

.collection-card p {
  max-width: 330px;
  margin-bottom: 0;
  color: var(--ink-soft);
}

.circle-link {
  display: grid;
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 50%;
  text-decoration: none;
  transition: transform 160ms ease;
}

.circle-link:hover {
  transform: translate(3px, -3px);
}

.curation-grid {
  display: grid;
  gap: 30px;
}

.curation-copy {
  max-width: 610px;
}

.curation-copy > p {
  margin-bottom: 28px;
  color: var(--ink-soft);
  font-size: 18px;
}

.page-hero {
  padding: 68px 0 54px;
}

.page-hero h1,
.game-title-grid h1 {
  margin: 16px 0 20px;
  font-size: clamp(52px, 12vw, 94px);
}

.page-hero p,
.game-title-grid > div > p {
  max-width: 740px;
  color: var(--ink-soft);
  font-size: 18px;
}

.narrow-left {
  max-width: var(--shell);
}

.section-listing {
  padding-top: 24px;
}

.filter-bar {
  display: grid;
  gap: 8px;
  margin-bottom: 40px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
}

.filter-bar label {
  font-size: 13px;
  font-weight: 700;
}

.search-wrap {
  position: relative;
}

.search-wrap svg {
  position: absolute;
  top: 50%;
  left: 15px;
  width: 20px;
  transform: translateY(-50%);
  fill: none;
  stroke: var(--ink-soft);
  stroke-width: 1.6;
}

.search-wrap input {
  width: 100%;
  min-height: 52px;
  padding: 12px 16px 12px 45px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  font-size: 16px;
}

.filter-bar > p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 32px;
  color: var(--ink-soft);
  font-size: 13px;
}

.breadcrumbs span + span::before {
  margin-right: 7px;
  content: "/";
}

.breadcrumbs a {
  text-underline-offset: 4px;
}

.game-intro {
  padding: 38px 0 44px;
}

.game-title-grid {
  display: grid;
  gap: 30px;
}

.game-title-grid h1 {
  max-width: 850px;
}

.game-quick-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-self: end;
  margin: 0;
  border-top: 1px solid var(--line);
}

.game-quick-facts div {
  padding: 15px 8px 15px 16px;
}

.game-quick-facts div + div {
  border-left: 1px solid var(--line);
}

.game-quick-facts dt {
  color: var(--ink-soft);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.game-quick-facts dd {
  margin: 3px 0 0;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}

.operation-brief {
  display: grid;
  gap: 16px;
  margin-top: 28px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--coral);
  border-radius: 16px;
  box-shadow: var(--shadow-small);
}

.operation-brief > div {
  display: grid;
  gap: 12px;
}

.operation-brief p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.55;
}

.operation-brief strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.play-section {
  padding-bottom: 34px;
}

.play-shell {
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.play-toolbar {
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}

.play-toolbar > div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}

.play-toolbar strong {
  font-size: 13px;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: var(--mint);
  border-radius: 50%;
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--mint) 18%, transparent);
}

.toolbar-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.toolbar-button:disabled {
  cursor: not-allowed;
  opacity: .45;
}

.play-shell:fullscreen {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.play-shell:fullscreen .play-viewport {
  flex: 1;
  min-height: 0;
}

.play-shell:fullscreen .play-placeholder {
  height: 100%;
}

.play-shell:fullscreen .community-game-frame {
  height: 100%;
}

.play-viewport {
  position: relative;
  min-height: 520px;
  background: #e7eee8;
}

.play-placeholder {
  position: relative;
  min-height: 520px;
  overflow: hidden;
}

.play-placeholder > img {
  width: 100%;
  min-height: 520px;
  object-fit: cover;
  filter: saturate(.78);
  transform: scale(1.02);
}

.play-placeholder::after {
  position: absolute;
  inset: 0;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  content: "";
  backdrop-filter: blur(7px);
}

.play-overlay {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  width: min(520px, calc(100% - 36px));
  padding: 28px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  text-align: center;
  transform: translate(-50%, -50%);
}

.play-overlay h2 {
  margin: 10px 0 12px;
  font-size: clamp(38px, 9vw, 58px);
}

.play-overlay p {
  color: var(--ink-soft);
}

.button-play {
  min-width: 180px;
}

.community-game-frame {
  --frame-h: 680px;
  width: 100%;
  height: min(var(--frame-h), calc(100vh - 160px));
  height: min(var(--frame-h), calc(100svh - 160px));
  background: #fff;
  border: 0;
}

.frame-oh-hi { --frame-h: 720px; }
.frame-2048 { --frame-h: 720px; }
.frame-solitaire { --frame-h: 760px; }
.frame-javascript-tetris { --frame-h: 660px; }
.frame-tower-building { --frame-h: 760px; }
.frame-radius-raid { --frame-h: 680px; }
.frame-pixel-hop-twins { --frame-h: 650px; }

.play-message {
  margin: 0;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 12px;
  text-align: center;
}

.article-layout {
  display: grid;
  gap: 42px;
}

.game-guide > section {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 14px;
  padding: 30px 0;
  border-top: 1px solid var(--line);
}

.section-number {
  color: var(--coral);
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 700;
}

.game-guide h2,
.source-card h2,
.prose h2 {
  margin-bottom: 16px;
  font-size: 34px;
}

.game-guide h3 {
  margin: 0 0 8px;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.game-guide p,
.game-guide li {
  color: var(--ink-soft);
}

.game-guide ol,
.game-guide ul {
  padding-left: 22px;
}

.game-guide li + li {
  margin-top: 9px;
}

.control-grid {
  display: grid;
  gap: 14px;
}

.control-grid > div {
  padding: 18px;
  background: var(--surface-soft);
  border-radius: 14px;
}

.control-grid p {
  margin: 0;
}

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-list details {
  border-bottom: 1px solid var(--line);
}

.faq-list summary {
  min-height: 56px;
  padding: 15px 34px 15px 0;
  font-weight: 700;
  cursor: pointer;
}

.faq-list p {
  padding: 0 0 18px;
}

.source-card {
  align-self: start;
  padding: 26px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 20px;
}

.source-card dl {
  margin: 24px 0;
  border-top: 1px solid var(--line-strong);
}

.source-card dl div {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-strong);
}

.source-card dt {
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
}

.source-card dd {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.source-card > p {
  color: var(--ink-soft);
  font-size: 14px;
}

.prose {
  max-width: 800px;
}

.prose h2 {
  margin-top: 46px;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose p,
.prose li {
  color: var(--ink-soft);
  font-size: 17px;
}

.prose a {
  font-weight: 700;
  text-underline-offset: 4px;
}

.contact-form {
  display: grid;
  gap: 9px;
  margin-top: 26px;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
}

.contact-form label {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 700;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  font-size: 16px;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form .button {
  justify-self: start;
  margin-top: 16px;
}

.form-status {
  margin: 8px 0 0;
  font-size: 13px !important;
}

.site-footer {
  padding: 56px 0 24px;
  background: var(--surface);
  border-top: 1px solid var(--line);
}

.footer-main {
  display: grid;
  gap: 38px;
}

.footer-intro > p {
  max-width: 410px;
  margin: 20px 0 0;
  color: var(--ink-soft);
}

.footer-links {
  display: grid;
}

.footer-links a {
  display: flex;
  min-height: 46px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  font-weight: 650;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--coral);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  margin-top: 42px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 12px;
}

.footer-bottom p {
  margin: 0;
}

@media (min-width: 720px) {
  .shell {
    width: min(calc(100% - 72px), var(--shell));
  }

  .hero {
    padding: 86px 0 100px;
  }

  .game-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .game-grid .game-card-featured {
    grid-column: 1 / -1;
  }

  .game-card-featured {
    display: grid;
    grid-template-columns: 1.35fr .65fr;
    gap: 26px;
    align-items: center;
  }

  .game-card-featured .game-card-body {
    padding: 20px 0;
  }

  .game-card-featured h3 {
    font-size: 42px;
  }

  .collection-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collection-card:last-child {
    grid-column: 1 / -1;
  }

  .filter-bar {
    grid-template-columns: auto minmax(260px, 520px) 1fr;
    align-items: center;
    gap: 18px;
    padding: 14px 18px;
  }

  .filter-bar > p {
    justify-self: end;
  }

  .control-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-main {
    grid-template-columns: 1.1fr .9fr;
  }
}

@media (min-width: 980px) {
  :root {
    --header-h: 87px;
  }

  .header-inner {
    min-height: 86px;
  }

  .site-nav {
    position: static;
    display: flex;
    margin-left: auto;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
    gap: 4px;
  }

  .site-nav a {
    position: relative;
    min-height: 44px;
    padding: 0 17px;
    border: 0;
  }

  .site-nav a[aria-current="page"]::after {
    position: absolute;
    right: 17px;
    bottom: 5px;
    left: 17px;
    height: 2px;
    background: var(--coral);
    content: "";
  }

  .nav-toggle {
    display: none;
  }

  .hero-grid {
    grid-template-columns: 1.07fr .93fr;
    align-items: center;
    gap: 68px;
  }

  .hero h1 {
    font-size: clamp(72px, 7.2vw, 108px);
  }

  .section {
    padding: 100px 0;
  }

  .section-heading {
    margin-bottom: 44px;
  }

  .game-grid,
  .game-grid-all {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 34px 24px;
  }

  .game-grid .game-card-featured {
    grid-column: auto;
  }

  .game-card-featured {
    display: block;
  }

  .game-card-featured .game-card-body {
    padding: 18px 2px 0;
  }

  .game-card-featured h3 {
    font-size: 30px;
  }

  .collection-grid,
  .collection-grid-large {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .collection-card:last-child {
    grid-column: auto;
  }

  .curation-grid {
    grid-template-columns: 1.1fr .9fr;
    align-items: start;
    gap: 80px;
  }

  .page-hero {
    padding: 96px 0 70px;
  }

  .narrow-left {
    width: min(780px, 100%);
    margin-left: max(0px, calc((100% - var(--shell)) / 2));
  }

  .shell.narrow-left {
    width: min(780px, calc(100% - 72px));
  }

  .game-title-grid {
    grid-template-columns: 1fr 360px;
    align-items: end;
    gap: 70px;
  }

  .article-layout {
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 90px;
  }

  .source-card {
    position: sticky;
    top: 112px;
  }

  .game-guide > section {
    grid-template-columns: 56px 1fr;
    gap: 24px;
    padding: 40px 0;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Arcade cabinet visual system ------------------------------------------------ */
:root,
:root[data-theme="night"],
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #070912;
  --surface: #10182c;
  --surface-soft: #18223b;
  --ink: #f5f7ff;
  --ink-soft: #aeb9d4;
  --line: #293858;
  --line-strong: #49628c;
  --primary: #75f6d7;
  --primary-ink: #061015;
  --coral: #ff4d8d;
  --mint: #31d6fc;
  --gold: #ffd166;
  --violet: #9f6cff;
  --shadow: 8px 8px 0 #03050a, 0 0 0 1px #30466e, 0 0 32px rgba(49, 214, 252, .13);
  --shadow-small: 4px 4px 0 #03050a, 0 0 0 1px #30466e;
  --shell: 1220px;
  --sans: "Bricolage", system-ui, sans-serif;
  --serif: "Bricolage", system-ui, sans-serif;
  --pixel: ui-monospace, "Cascadia Code", "Courier New", monospace;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #e9edf9;
  --surface: #ffffff;
  --surface-soft: #dce5f7;
  --ink: #10182c;
  --ink-soft: #50617f;
  --line: #bfcae2;
  --line-strong: #8194ba;
  --primary: #057d75;
  --primary-ink: #f6ffff;
  --coral: #d92366;
  --mint: #0069b7;
  --gold: #bc7700;
  --violet: #6638bf;
  --shadow: 8px 8px 0 #9eabc6, 0 0 0 1px #8194ba;
  --shadow-small: 4px 4px 0 #a9b4cc, 0 0 0 1px #8194ba;
}

html {
  scrollbar-color: var(--primary) var(--bg);
  scrollbar-width: auto;
}

html::-webkit-scrollbar { width: 15px; height: 15px; }
html::-webkit-scrollbar-track { background: var(--bg); border-left: 1px solid var(--line); }
html::-webkit-scrollbar-thumb { background: var(--primary); border: 3px solid var(--bg); border-radius: 0; box-shadow: inset 0 0 0 1px var(--ink); }
html::-webkit-scrollbar-thumb:hover { background: var(--coral); }
html::-webkit-scrollbar-corner { background: var(--bg); }

body {
  min-width: 320px;
  background-color: var(--bg);
  background-image: linear-gradient(rgba(117, 246, 215, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(117, 246, 215, .045) 1px, transparent 1px), radial-gradient(circle at 50% -10%, rgba(68, 72, 186, .28), transparent 42rem);
  background-size: 28px 28px, 28px 28px, auto;
  font-family: var(--sans);
  cursor: url("/assets/cursors/arcade-crosshair.svg") 16 16, crosshair;
}

body::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,.018) 0 1px, transparent 1px 4px);
  content: "";
  pointer-events: none;
}

a,
button,
summary,
select,
input,
textarea { cursor: url("/assets/cursors/arcade-pointer.svg") 4 2, pointer; }

button:disabled { cursor: not-allowed; }

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }

.shell { width: min(calc(100% - 32px), var(--shell)); }

.site-header {
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  border-bottom: 2px solid var(--line-strong);
  box-shadow: 0 5px 0 rgba(3, 5, 10, .68);
  backdrop-filter: blur(18px);
}

.header-inner { min-height: 76px; }

.brand { gap: 10px; }
.brand-mark {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
  padding: 0;
  border: 0;
  border-radius: 0;
  filter: drop-shadow(3px 3px 0 #03050a);
}
.brand-copy {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -.055em;
  line-height: .9;
  text-transform: uppercase;
}
.brand-copy small {
  margin-top: 5px;
  color: var(--primary);
  font-family: var(--pixel);
  font-size: 7px;
  font-weight: 700;
  letter-spacing: .05em;
}

.site-nav { background: var(--surface); border: 2px solid var(--line-strong); box-shadow: var(--shadow-small); }
.site-nav a {
  min-height: 52px;
  color: var(--ink);
  font-family: var(--pixel);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.site-nav a::before { color: var(--primary); content: ">"; opacity: 0; transform: translateX(-6px); transition: opacity 160ms ease, transform 160ms ease; }
.site-nav a:hover::before,
.site-nav a[aria-current="page"]::before { opacity: 1; transform: translateX(0); }
.site-nav a[aria-current="page"] { color: var(--primary); }

.icon-button {
  width: 44px;
  height: 44px;
  background: var(--surface);
  border: 2px solid var(--line-strong);
  border-radius: 6px;
  box-shadow: 3px 3px 0 #03050a;
}
.icon-button:hover { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); transform: translate(-1px, -1px); box-shadow: 5px 5px 0 #03050a; }
.icon-button:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 #03050a; }

.hero { padding: 38px 0 62px; }
.hero-grid { gap: 30px; }
.hero-copy { position: relative; }
.hero-copy::after {
  display: block;
  width: min(210px, 64%);
  height: 7px;
  margin-top: 28px;
  background: repeating-linear-gradient(90deg, var(--coral) 0 11px, transparent 11px 18px);
  content: "";
}
.eyebrow { color: var(--primary); font-family: var(--pixel); font-size: 10px; font-weight: 800; letter-spacing: .11em; }
.eyebrow i { width: 9px; height: 9px; border-radius: 0; background: var(--coral); box-shadow: 2px 2px 0 var(--gold); }
h1,h2,h3 { font-family: var(--sans); font-weight: 800; letter-spacing: -.065em; line-height: .91; }
.hero h1 { max-width: 800px; margin: 16px 0 22px; font-size: clamp(52px, 15vw, 112px); line-height: .83; text-transform: uppercase; text-shadow: 5px 5px 0 #03050a; }
.hero h1 em { color: var(--primary); font-style: normal; text-shadow: 5px 5px 0 #115c66; }
.hero-copy > p { max-width: 590px; color: var(--ink-soft); font-size: 17px; }

.button {
  min-height: 48px;
  padding: 12px 18px;
  border: 2px solid var(--primary);
  border-radius: 0;
  box-shadow: 4px 4px 0 #03050a;
  font-family: var(--pixel);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
  transition: transform 130ms steps(2), box-shadow 130ms steps(2), background-color 130ms steps(2);
}
.button:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 #03050a; }
.button:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 #03050a; }
.button-primary { background: var(--primary); color: var(--primary-ink); }
.button-primary:hover { background: var(--gold); border-color: var(--gold); }
.button-secondary { border-color: var(--line-strong); background: var(--surface); }
.button-secondary:hover { background: var(--coral); border-color: var(--coral); color: #fff; }
.text-link { color: var(--primary); font-family: var(--pixel); font-size: 12px; text-decoration: none; text-transform: uppercase; }
.text-link::after { margin-left: 7px; content: "↗"; }
.text-link:hover { color: var(--gold); }

.hero-facts { max-width: 600px; margin-top: 34px; border: 2px solid var(--line-strong); background: rgba(16, 24, 44, .68); }
.hero-facts div { padding: 14px 10px; }
.hero-facts div + div { border-left: 2px solid var(--line-strong); }
.hero-facts dt { color: var(--gold); font-family: var(--pixel); font-size: 20px; font-weight: 800; }
.hero-facts dd { color: var(--ink-soft); font-family: var(--pixel); font-size: 9px; letter-spacing: .05em; text-transform: uppercase; }

.hero-feature {
  border: 3px solid var(--primary);
  border-radius: 12px 12px 32px 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transform: none;
}
.hero-feature:hover { border-color: var(--gold); transform: translate(-3px, -3px) rotate(-.4deg); }
.hero-feature > img { filter: saturate(1.16) contrast(1.06); }
.hero-feature-copy { min-height: 92px; padding: 14px 18px; border-top: 2px solid var(--line-strong); }
.hero-feature-copy small { color: var(--primary); font-family: var(--pixel); font-size: 9px; }
.hero-feature-copy strong { font-family: var(--sans); font-size: 34px; font-weight: 800; letter-spacing: -.06em; text-transform: uppercase; }
.hero-feature-copy > i { width: 44px; height: 44px; background: var(--coral); border-radius: 5px; box-shadow: 3px 3px 0 #03050a; }

.section { padding: 62px 0; }
.section-tinted { background: rgba(16, 24, 44, .66); border-block: 2px solid var(--line-strong); }
.section-heading { margin-bottom: 30px; }
.section-heading h2,.curation-grid h2,.page-hero h1,.game-intro h1 { text-transform: uppercase; }
.section-heading h2 { font-size: clamp(34px, 7vw, 60px); }

.game-grid { gap: 26px; }
.game-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 2px solid var(--line-strong);
  border-radius: 10px;
  box-shadow: var(--shadow-small);
}
.game-card::before { position: absolute; z-index: 2; top: 0; left: 0; width: 100%; height: 5px; background: linear-gradient(90deg, var(--coral) 0 33%, var(--gold) 33% 66%, var(--primary) 66%); content: ""; }
.game-card-cover { border-radius: 0; background: #03050a; }
.game-card-cover::after { position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(255,255,255,.10) 0 1px, transparent 1px 4px); content: ""; opacity: .26; pointer-events: none; }
.game-card-cover img { filter: saturate(1.18) contrast(1.06); transition: transform 220ms ease, filter 220ms ease; }
.game-card-cover:hover img { transform: scale(1.06); filter: saturate(1.35) contrast(1.12); }
.cover-kicker { top: 15px; left: 14px; padding: 6px 8px; background: var(--bg); border: 1px solid var(--primary); border-radius: 0; color: var(--primary); font-family: var(--pixel); font-size: 9px; letter-spacing: .06em; text-transform: uppercase; }
.cover-action { right: 12px; bottom: 12px; padding: 8px 10px; background: var(--coral); border-radius: 0; color: #fff; font-family: var(--pixel); font-size: 10px; text-transform: uppercase; }
.game-card-body { padding: 18px 17px 16px; }
.card-meta,.device-line { font-family: var(--pixel); font-size: 9px; letter-spacing: .04em; text-transform: uppercase; }
.game-card h3 { margin: 10px 0 11px; font-size: 29px; text-transform: uppercase; }
.game-card h3 a:hover { color: var(--primary); }
.game-card p { color: var(--ink-soft); font-size: 14px; }
.gameplay-summary span { color: var(--gold); font-family: var(--pixel); font-size: 9px; letter-spacing: .06em; text-transform: uppercase; }
.device-line { border-top: 1px dashed var(--line-strong); color: var(--primary); }

.collection-card { min-height: 260px; padding: 26px; border: 2px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow-small); }
.collection-puzzle { background: linear-gradient(135deg, rgba(159,108,255,.35), var(--surface)); }
.collection-arcade { background: linear-gradient(135deg, rgba(49,214,252,.28), var(--surface)); }
.collection-action { background: linear-gradient(135deg, rgba(255,77,141,.30), var(--surface)); }
.collection-card h3 { font-size: 36px; text-transform: uppercase; }
.circle-link { border-radius: 6px; background: var(--bg); border: 2px solid var(--primary); box-shadow: 3px 3px 0 #03050a; }
.circle-link:hover { background: var(--primary); color: var(--primary-ink); }

.page-hero,.game-intro { padding: 54px 0 42px; border-bottom: 2px solid var(--line-strong); background: linear-gradient(120deg, rgba(16,24,44,.86), transparent); }
.page-hero h1,.game-intro h1 { font-size: clamp(46px, 10vw, 82px); text-shadow: 4px 4px 0 #03050a; }
.page-hero p,.game-intro p { color: var(--ink-soft); }
.breadcrumbs { font-family: var(--pixel); font-size: 10px; letter-spacing: .04em; }
.breadcrumbs a { color: var(--primary); }
.filter-bar,.operation-brief,.source-card,.contact-form { border: 2px solid var(--line-strong); border-radius: 7px; box-shadow: var(--shadow-small); }
.filter-bar { background: var(--surface); }
.search-wrap input,.contact-form input,.contact-form select,.contact-form textarea { border: 2px solid var(--line-strong); border-radius: 4px; background: var(--bg); }
.search-wrap input:focus,.contact-form input:focus,.contact-form select:focus,.contact-form textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 25%, transparent); outline: 0; }

.game-quick-facts { border: 2px solid var(--line-strong); background: var(--surface); box-shadow: var(--shadow-small); }
.game-quick-facts div + div { border-top: 1px dashed var(--line-strong); }
.game-quick-facts dt { color: var(--primary); font-family: var(--pixel); font-size: 10px; text-transform: uppercase; }
.game-quick-facts dd { font-family: var(--pixel); font-size: 12px; }
.operation-brief { background: linear-gradient(90deg, rgba(49,214,252,.13), var(--surface)); }
.operation-brief strong { color: var(--gold); font-family: var(--pixel); font-size: 10px; letter-spacing: .05em; text-transform: uppercase; }

.play-section { padding: 34px 0; }
.play-shell { border: 3px solid var(--line-strong); border-radius: 14px; background: var(--surface); box-shadow: 10px 10px 0 #03050a, 0 0 0 1px var(--primary); }
.play-toolbar { background: #0b1120; border-bottom: 2px solid var(--line-strong); font-family: var(--pixel); font-size: 11px; text-transform: uppercase; }
.status-dot { border-radius: 0; background: var(--primary); box-shadow: 0 0 10px var(--primary); }
.toolbar-button { border: 1px solid var(--primary); border-radius: 3px; color: var(--primary); font-family: var(--pixel); text-transform: uppercase; }
.toolbar-button:hover { background: var(--primary); color: var(--primary-ink); }
.play-viewport { background: #03050a; }
.play-placeholder::after { background: rgba(3,5,10,.68); backdrop-filter: blur(4px); }
.play-overlay { background: rgba(16,24,44,.95); border: 2px solid var(--primary); border-radius: 6px; box-shadow: 7px 7px 0 #03050a; }
.play-overlay h2 { color: var(--primary); font-size: clamp(38px, 9vw, 58px); text-transform: uppercase; }
.play-message { border-top: 2px solid var(--line-strong); font-family: var(--pixel); font-size: 10px; }

.game-guide > section { border-top: 2px solid var(--line); }
.section-number { color: var(--coral); font-family: var(--pixel); font-size: 13px; }
.game-guide h2,.source-card h2,.prose h2 { font-size: 32px; text-transform: uppercase; }
.control-grid > div { border: 1px solid var(--line-strong); border-radius: 4px; background: var(--surface); }
.faq-list { border-top: 2px solid var(--line); }
.faq-list details { border-bottom: 2px solid var(--line); }
.faq-list summary { color: var(--primary); font-family: var(--pixel); font-size: 12px; text-transform: uppercase; }
.source-card { background: var(--surface); }
.source-card dl { border-top: 2px solid var(--line-strong); }
.source-card dl div { border-bottom: 1px dashed var(--line-strong); }
.source-card dt { font-family: var(--pixel); }
.prose code { padding: 2px 5px; background: var(--surface-soft); color: var(--primary); }

.site-footer { background: #05070d; border-top: 3px solid var(--primary); }
.footer-links a { font-family: var(--pixel); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
.footer-links a:hover { color: var(--primary); }
.footer-bottom { font-family: var(--pixel); font-size: 10px; }

@media (min-width: 720px) {
  .shell { width: min(calc(100% - 56px), var(--shell)); }
  .hero { padding: 68px 0 82px; }
}

@media (min-width: 980px) {
  .header-inner { min-height: 82px; }
  .site-nav { border: 0; box-shadow: none; }
  .site-nav a { min-height: 44px; padding: 0 12px; }
  .site-nav a[aria-current="page"]::after { right: 12px; bottom: 3px; left: 12px; height: 3px; background: var(--primary); }
  .hero-grid { gap: 52px; }
  .section { padding: 88px 0; }
}

/* Cartridge gallery visual system ------------------------------------------ */
:root,
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f6efdf;
  --surface: #fffaf0;
  --surface-soft: #e7ddd0;
  --ink: #1d2a44;
  --ink-soft: #5f6980;
  --line: #d4c7b4;
  --line-strong: #9aadc1;
  --primary: #316d92;
  --primary-ink: #fffaf0;
  --coral: #d95b4e;
  --mint: #5b98b1;
  --gold: #d89e2f;
  --violet: #7a6b9d;
  --shadow: 0 16px 30px rgba(45, 58, 78, .13), 0 2px 0 rgba(255,255,255,.8) inset;
  --shadow-small: 0 8px 18px rgba(45, 58, 78, .11), 0 1px 0 rgba(255,255,255,.88) inset;
  --shell: 1180px;
  --sans: "Bricolage", system-ui, sans-serif;
  --serif: "Fraunces", Georgia, serif;
  --pixel: "Bricolage", system-ui, sans-serif;
}

:root[data-theme="night"],
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #20283a;
  --surface: #2c364a;
  --surface-soft: #364158;
  --ink: #f7f0df;
  --ink-soft: #c3c8d2;
  --line: #4b5870;
  --line-strong: #73839f;
  --primary: #8dc3d3;
  --primary-ink: #17233a;
  --coral: #ef9278;
  --mint: #86b7c8;
  --gold: #edc663;
  --violet: #b6a8d8;
  --shadow: 0 17px 34px rgba(0,0,0,.25), 0 1px 0 rgba(255,255,255,.08) inset;
  --shadow-small: 0 9px 19px rgba(0,0,0,.22), 0 1px 0 rgba(255,255,255,.07) inset;
}

html { scrollbar-color: var(--coral) var(--surface-soft); }
html::-webkit-scrollbar { width: 14px; height: 14px; }
html::-webkit-scrollbar-track { background: var(--surface-soft); border-left: 2px solid var(--line); }
html::-webkit-scrollbar-thumb { background: var(--coral); border: 3px solid var(--surface-soft); border-radius: 12px; box-shadow: inset 0 -3px rgba(86, 40, 42, .24); }
html::-webkit-scrollbar-thumb:hover { background: var(--gold); }
html::-webkit-scrollbar-corner { background: var(--surface-soft); }

body {
  background-color: var(--bg);
  background-image: radial-gradient(circle at 1px 1px, rgba(29,42,68,.11) 1px, transparent 1.5px), radial-gradient(circle at 86% 8%, rgba(217,91,78,.15), transparent 22rem), radial-gradient(circle at 5% 61%, rgba(91,152,177,.14), transparent 19rem);
  background-size: 14px 14px, auto, auto;
  color: var(--ink);
  cursor: url("/assets/cursors/arcade-crosshair.svg") 4 4, default;
}
body::before { background: none; }
a,button,summary,select,input,textarea { cursor: url("/assets/cursors/arcade-pointer.svg") 4 2, pointer; }
button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible { outline-color: var(--coral); }

.shell { width: min(calc(100% - 34px), var(--shell)); }
.site-header { background: color-mix(in srgb, var(--bg) 89%, transparent); border-bottom: 1px solid var(--line); box-shadow: 0 3px 18px rgba(45,58,78,.08); }
.header-inner { min-height: 76px; }
.brand { gap: 10px; }
.brand-mark { width: 42px; height: 42px; flex-basis: 42px; border: 0; border-radius: 0; filter: drop-shadow(0 3px 2px rgba(29,42,68,.18)); }
.brand-copy { color: var(--ink); font-family: var(--sans); font-size: 18px; font-weight: 800; letter-spacing: -.055em; line-height: .94; text-transform: none; }
.brand-copy small { margin-top: 4px; color: var(--coral); font-family: var(--sans); font-size: 8px; font-weight: 800; letter-spacing: .08em; }
.site-nav { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-small); }
.site-nav a { min-height: 50px; color: var(--ink-soft); font-family: var(--sans); font-size: 13px; font-weight: 750; letter-spacing: 0; text-transform: none; }
.site-nav a::before { display: none; }
.site-nav a:hover,.site-nav a[aria-current="page"] { color: var(--primary); }
.icon-button { background: var(--surface); border: 1px solid var(--line-strong); border-radius: 14px; box-shadow: 0 3px 0 color-mix(in srgb, var(--line-strong) 70%, transparent); }
.icon-button:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); transform: translateY(-1px); box-shadow: 0 4px 0 color-mix(in srgb, var(--gold) 40%, var(--ink)); }
.icon-button:active { transform: translateY(2px); box-shadow: none; }

.hero { padding: 44px 0 72px; overflow: visible; }
.hero-grid { gap: 40px; }
.hero-copy { z-index: 1; }
.hero-copy::after { width: 136px; height: 12px; margin-top: 30px; border-radius: 0 20px 20px 0; background: repeating-linear-gradient(90deg, var(--coral) 0 18px, transparent 18px 27px); }
.eyebrow { color: var(--primary); font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: .1em; }
.eyebrow i { width: 9px; height: 9px; border-radius: 50%; background: var(--coral); box-shadow: 10px 0 var(--gold); }
h1,h2,h3 { font-family: var(--serif); font-weight: 650; letter-spacing: -.045em; line-height: .98; }
.hero h1 { margin: 18px 0 22px; color: var(--ink); font-size: clamp(52px, 14vw, 105px); line-height: .89; text-shadow: none; text-transform: none; }
.hero h1 em { color: var(--coral); font-style: italic; text-shadow: none; }
.hero-copy > p { max-width: 575px; color: var(--ink-soft); font-size: 18px; }
.button { min-height: 50px; padding: 12px 20px; border: 1px solid var(--primary); border-radius: 14px; box-shadow: 0 4px 0 color-mix(in srgb, var(--primary) 38%, var(--ink)); font-family: var(--sans); font-size: 13px; font-weight: 800; letter-spacing: 0; text-transform: none; transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease; }
.button:hover { transform: translateY(-2px) rotate(-.35deg); box-shadow: 0 6px 0 color-mix(in srgb, var(--primary) 38%, var(--ink)); }
.button:active { transform: translateY(3px); box-shadow: none; }
.button-primary { background: var(--primary); color: var(--primary-ink); }
.button-primary:hover { border-color: var(--coral); background: var(--coral); color: #fffaf0; }
.button-secondary { background: var(--surface); color: var(--ink); }
.button-secondary:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.text-link { color: var(--coral); font-family: var(--sans); font-size: 13px; font-weight: 800; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--coral) 35%, transparent); text-decoration-thickness: 2px; text-transform: none; }
.text-link::after { content: " →"; }
.text-link:hover { color: var(--primary); }
.hero-facts { max-width: 545px; border: 1px solid var(--line); border-radius: 18px; background: color-mix(in srgb, var(--surface) 86%, transparent); box-shadow: var(--shadow-small); }
.hero-facts div { padding: 15px 13px; }
.hero-facts div + div { border-left: 1px solid var(--line); }
.hero-facts dt { color: var(--coral); font-family: var(--serif); font-size: 25px; font-weight: 700; }
.hero-facts dd { color: var(--ink-soft); font-family: var(--sans); font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.hero-feature { position: relative; border: 1px solid var(--line-strong); border-radius: 26px; background: var(--surface); box-shadow: var(--shadow); transform: rotate(1.1deg); }
.hero-feature::before { position: absolute; z-index: 2; top: 13px; right: 13px; width: 11px; height: 11px; border-radius: 50%; background: var(--coral); box-shadow: -18px 0 var(--gold); content: ""; }
.hero-feature:hover { border-color: var(--primary); transform: rotate(0) translateY(-5px); }
.hero-feature > img { filter: saturate(.93) contrast(1.02); }
.hero-feature-copy { min-height: 88px; padding: 15px 20px; border-top: 1px solid var(--line); }
.hero-feature-copy small { color: var(--coral); font-family: var(--sans); font-size: 10px; font-weight: 800; }
.hero-feature-copy strong { font-family: var(--serif); font-size: 34px; font-weight: 700; letter-spacing: -.045em; text-transform: none; }
.hero-feature-copy > i { width: 45px; height: 45px; border-radius: 50%; background: var(--gold); color: var(--ink); box-shadow: 0 3px 0 color-mix(in srgb, var(--gold) 40%, var(--ink)); }

.section { padding: 70px 0; }
.section-tinted { background: rgba(231,221,208,.56); border-block: 1px solid var(--line); }
.section-heading { margin-bottom: 36px; }
.section-heading h2,.curation-grid h2,.page-hero h1,.game-intro h1 { text-transform: none; }
.section-heading h2 { font-size: clamp(38px, 7vw, 64px); }
.game-grid { gap: 28px 22px; }
.game-card { overflow: hidden; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); box-shadow: var(--shadow-small); }
.game-card::before { z-index: 2; width: 100%; height: 7px; background: linear-gradient(90deg, var(--coral) 0 34%, var(--gold) 34% 67%, var(--mint) 67%); }
.game-card-cover { background: var(--surface-soft); border-radius: 0; }
.game-card-cover::after { background: linear-gradient(180deg, transparent 57%, rgba(29,42,68,.22)); opacity: 1; }
.game-card-cover img { filter: saturate(.96); }
.game-card-cover:hover img { transform: scale(1.045); filter: saturate(1.1); }
.cover-kicker { top: 17px; left: 15px; padding: 6px 9px; border: 0; border-radius: 999px; background: var(--surface); color: var(--primary); font-family: var(--sans); font-size: 10px; font-weight: 800; letter-spacing: .03em; text-transform: none; }
.cover-action { right: 13px; bottom: 13px; padding: 8px 11px; border-radius: 999px; background: var(--coral); color: #fffaf0; font-family: var(--sans); font-size: 11px; font-weight: 800; text-transform: none; }
.game-card-body { padding: 19px 18px 18px; }
.card-meta,.device-line { font-family: var(--sans); font-size: 11px; font-weight: 750; letter-spacing: .01em; text-transform: none; }
.game-card h3 { margin: 11px 0; font-family: var(--serif); font-size: 31px; text-transform: none; }
.game-card h3 a:hover { color: var(--coral); }
.game-card p { color: var(--ink-soft); font-size: 14px; }
.gameplay-summary span { color: var(--coral); font-family: var(--sans); font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.device-line { border-top: 1px dashed var(--line); color: var(--primary); }
.collection-card { min-height: 250px; padding: 27px; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-small); }
.collection-puzzle { background: linear-gradient(140deg, #e4d9f1, var(--surface)); }
.collection-arcade { background: linear-gradient(140deg, #c9e4ea, var(--surface)); }
.collection-action { background: linear-gradient(140deg, #f3d3ca, var(--surface)); }
.collection-card h3 { font-family: var(--serif); font-size: 38px; text-transform: none; }
.circle-link { border: 0; border-radius: 50%; background: var(--gold); box-shadow: 0 3px 0 color-mix(in srgb, var(--gold) 36%, var(--ink)); }
.circle-link:hover { background: var(--coral); color: #fff; }

.page-hero,.game-intro { border-bottom: 1px solid var(--line); background: linear-gradient(125deg, rgba(91,152,177,.1), transparent 58%); }
.page-hero h1,.game-intro h1 { font-size: clamp(47px, 10vw, 84px); text-shadow: none; }
.breadcrumbs { font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: 0; }
.breadcrumbs a { color: var(--coral); }
.filter-bar,.operation-brief,.source-card,.contact-form { border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-small); }
.filter-bar { background: var(--surface); }
.search-wrap input,.contact-form input,.contact-form select,.contact-form textarea { border: 1px solid var(--line-strong); border-radius: 10px; background: color-mix(in srgb, var(--surface) 70%, var(--bg)); }
.search-wrap input:focus,.contact-form input:focus,.contact-form select:focus,.contact-form textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 16%, transparent); }
.game-quick-facts { border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-small); }
.game-quick-facts div + div { border-top: 1px dashed var(--line); }
.game-quick-facts dt { color: var(--coral); font-family: var(--sans); font-size: 10px; font-weight: 800; text-transform: uppercase; }
.game-quick-facts dd { font-family: var(--sans); font-size: 13px; }
.operation-brief { background: linear-gradient(90deg, rgba(91,152,177,.16), var(--surface)); }
.operation-brief strong { color: var(--coral); font-family: var(--sans); font-size: 11px; font-weight: 800; letter-spacing: .02em; text-transform: none; }
.play-shell { border: 1px solid var(--line-strong); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow); }
.play-toolbar { background: #e4d9c7; border-bottom: 1px solid var(--line); color: #1d2a44; font-family: var(--sans); font-size: 12px; font-weight: 800; text-transform: none; }
:root[data-theme="night"] .play-toolbar,:root[data-theme="dark"] .play-toolbar { background: #3a4458; color: var(--ink); }
.status-dot { border-radius: 50%; background: var(--coral); box-shadow: none; }
.toolbar-button { border: 1px solid var(--line-strong); border-radius: 10px; color: var(--primary); font-family: var(--sans); font-weight: 800; text-transform: none; }
.toolbar-button:hover { background: var(--primary); color: var(--primary-ink); }
.play-placeholder::after { background: rgba(29,42,68,.58); backdrop-filter: blur(4px); }
.play-overlay { border: 1px solid var(--surface); border-radius: 20px; background: rgba(255,250,240,.94); box-shadow: var(--shadow); }
:root[data-theme="night"] .play-overlay,:root[data-theme="dark"] .play-overlay { background: rgba(44,54,74,.96); }
.play-overlay h2 { color: var(--ink); font-family: var(--serif); font-size: clamp(38px, 9vw, 59px); text-transform: none; }
.play-message { border-top: 1px solid var(--line); font-family: var(--sans); font-size: 12px; }
.game-guide > section { border-top: 1px solid var(--line); }
.section-number { color: var(--coral); font-family: var(--sans); font-size: 13px; font-weight: 800; }
.game-guide h2,.source-card h2,.prose h2 { font-family: var(--serif); font-size: 35px; text-transform: none; }
.control-grid > div { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { color: var(--primary); font-family: var(--sans); font-size: 14px; font-weight: 800; text-transform: none; }
.source-card { background: var(--surface); }
.source-card dl { border-top: 1px solid var(--line); }
.source-card dl div { border-bottom: 1px dashed var(--line); }
.source-card dt { font-family: var(--sans); font-weight: 800; }
.prose code { border-radius: 4px; background: var(--surface-soft); color: var(--coral); }
.site-footer { border-top: 5px solid var(--coral); background: #253249; }
.site-footer,.site-footer .brand { color: #f7f0df; }
.site-footer .brand-copy small { color: #edc663; }
.footer-intro > p,.footer-bottom { color: #d2d7de; }
.footer-links a { border-color: rgba(255,255,255,.18); font-family: var(--sans); font-size: 13px; font-weight: 750; letter-spacing: 0; text-transform: none; }
.footer-links a:hover { color: #edc663; }

@media (min-width: 720px) { .shell { width: min(calc(100% - 64px), var(--shell)); } .hero { padding: 70px 0 88px; } }
@media (min-width: 980px) { .header-inner { min-height: 82px; } .site-nav { border: 0; border-radius: 0; box-shadow: none; } .site-nav a { min-height: 44px; padding: 0 15px; } .site-nav a[aria-current="page"]::after { right: 15px; bottom: 3px; left: 15px; height: 3px; border-radius: 3px; background: var(--coral); } .section { padding: 94px 0; } }

/* Midnight playfield: the black canvas stays consistent in both theme modes. */
:root,
:root[data-theme="light"] {
  color-scheme: dark;
  --bg: #05070d;
  --surface: #111827;
  --surface-soft: #172235;
  --ink: #f4efe3;
  --ink-soft: #b7c0d1;
  --line: #293752;
  --line-strong: #526583;
  --primary: #82c4de;
  --primary-ink: #091019;
  --coral: #f07b65;
  --mint: #78aebb;
  --gold: #e5bd5d;
  --violet: #9d91c7;
  --shadow: 0 18px 42px rgba(0,0,0,.35), 0 1px 0 rgba(255,255,255,.06) inset;
  --shadow-small: 0 10px 24px rgba(0,0,0,.28), 0 1px 0 rgba(255,255,255,.055) inset;
}

:root[data-theme="night"],
:root[data-theme="dark"] {
  --bg: #020308;
  --surface: #0d1421;
  --surface-soft: #131d2e;
  --ink: #f5f0e6;
  --ink-soft: #aab6ca;
  --line: #25334e;
  --line-strong: #455979;
  --primary: #8ecce2;
  --coral: #f28a72;
  --mint: #86b9c5;
  --gold: #edca70;
}

html { scrollbar-color: var(--coral) #0c1320; }
html,body { overflow-x: hidden; }
html::-webkit-scrollbar-track { background: #0c1320; border-left-color: var(--line); }
html::-webkit-scrollbar-thumb { background: linear-gradient(var(--coral), #c95254); border-color: #0c1320; box-shadow: inset 0 -3px rgba(0,0,0,.24); }
html::-webkit-scrollbar-thumb:hover { background: var(--gold); }

body {
  position: relative;
  isolation: isolate;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 1px 1px, rgba(191,222,255,.23) 1px, transparent 1.5px),
    radial-gradient(circle at 1px 1px, rgba(240,123,101,.17) 1px, transparent 1.4px),
    radial-gradient(ellipse at 15% 15%, rgba(66,112,150,.2), transparent 28rem),
    radial-gradient(ellipse at 90% 34%, rgba(171,92,91,.16), transparent 26rem),
    radial-gradient(ellipse at 47% 100%, rgba(90,70,133,.18), transparent 33rem);
  background-size: 74px 74px, 121px 121px, 100% 100%, 100% 100%, 100% 100%;
  background-position: 0 0, 35px 22px, -9vw -8vh, 105vw 8vh, 50% 112vh;
  animation: midnight-drift 20s ease-in-out infinite alternate;
}

body::before { display: none; }

@keyframes midnight-drift {
  0% { background-position: 0 0, 35px 22px, -9vw -8vh, 105vw 8vh, 50% 112vh; }
  50% { background-position: 20px 38px, 5px 72px, -1vw 4vh, 97vw 18vh, 43% 105vh; }
  100% { background-position: 44px 70px, 57px 14px, 8vw -2vh, 90vw 4vh, 54% 96vh; }
}

/* The hand is reserved for every action that can launch, open, or play. */
a[href],
button:not(:disabled),
summary,
input[type="submit"],
input[type="button"],
select { cursor: url("/assets/cursors/arcade-pointer.svg") 13 3, pointer; }

.site-header { background: color-mix(in srgb, var(--bg) 86%, transparent); border-bottom-color: var(--line); box-shadow: 0 4px 20px rgba(0,0,0,.3); }
.site-nav { background: color-mix(in srgb, var(--surface) 94%, transparent); }
.icon-button { background: var(--surface); border-color: var(--line-strong); }
.icon-button:hover { background: var(--gold); }

.hero { position: relative; overflow: clip; }
@supports not (overflow: clip) { .hero { overflow: hidden; } }
.hero::before,
.hero::after {
  position: absolute;
  z-index: -1;
  width: clamp(150px, 23vw, 360px);
  aspect-ratio: 1;
  border: 1px solid rgba(130,196,222,.23);
  border-radius: 50%;
  content: "";
  filter: blur(.1px);
  pointer-events: none;
}
.hero::before { top: 4%; right: -7%; box-shadow: 0 0 0 24px rgba(130,196,222,.025), 0 0 0 50px rgba(130,196,222,.018); animation: orbit-bob 9s ease-in-out infinite; }
.hero::after { bottom: 3%; left: -9%; border-color: rgba(240,123,101,.22); box-shadow: 0 0 0 18px rgba(240,123,101,.025); animation: orbit-bob 12s ease-in-out -4s infinite reverse; }
@keyframes orbit-bob { 50% { transform: translateY(-18px) scale(1.04); opacity: .72; } }

.hero-copy > p,.page-hero p,.game-intro p { color: var(--ink-soft); }
.hero h1 { color: var(--ink); }
.hero h1 em { color: var(--coral); }
.hero-facts { background: color-mix(in srgb, var(--surface) 86%, transparent); }
.hero-feature { background: var(--surface); border-color: var(--line-strong); }
.section-tinted { position: relative; overflow: hidden; background: linear-gradient(110deg, rgba(15,24,39,.92), rgba(19,29,46,.62)); border-block-color: var(--line); }
.section-tinted::before { position: absolute; z-index: 0; inset: 0; background: radial-gradient(circle at 78% 10%, rgba(130,196,222,.11), transparent 24rem), radial-gradient(circle at 18% 96%, rgba(240,123,101,.09), transparent 21rem); content: ""; animation: section-glow 14s ease-in-out infinite alternate; pointer-events: none; }
.section-tinted > .shell { position: relative; z-index: 1; }
@keyframes section-glow { to { transform: scale(1.08) translate3d(1.5%, -1.5%, 0); opacity: .72; } }

.game-card,.collection-card,.filter-bar,.operation-brief,.source-card,.contact-form,.game-quick-facts { background-color: var(--surface); border-color: var(--line-strong); }
.shelf-summary {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  padding: 20px 22px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--surface);
}
.shelf-summary p { margin: 6px 0 0; color: var(--ink-soft); }
.shelf-summary strong { flex: 0 0 auto; color: var(--ink); font-family: var(--sans); font-size: 18px; font-weight: 800; }
.collection-puzzle { background: linear-gradient(145deg, rgba(115,96,158,.54), var(--surface) 66%); }
.collection-arcade { background: linear-gradient(145deg, rgba(54,113,143,.54), var(--surface) 66%); }
.collection-action { background: linear-gradient(145deg, rgba(148,76,79,.5), var(--surface) 66%); }
.collection-card p { color: var(--ink-soft); }
.cover-kicker { background: color-mix(in srgb, var(--surface) 92%, transparent); }
.play-toolbar { background: #101b2b; color: var(--ink); }
.play-overlay { background: color-mix(in srgb, var(--surface) 95%, transparent); border-color: var(--line-strong); }
.section-number,.gameplay-summary span { color: var(--coral); }
.site-footer { background: #070b13; }

@media (prefers-reduced-motion: reduce) {
  body,.hero::before,.hero::after,.section-tinted::before { animation: none !important; }
}

/* Flat actions: buttons lift through color and position, never a drop shadow. */
:where(
  button,
  .button,
  .icon-button,
  .toolbar-button,
  .circle-link,
  .cover-action,
  .hero-feature-copy > i
) {
  box-shadow: none !important;
}

@media (max-width: 720px) {
  .shelf-summary { align-items: flex-start; flex-direction: column; }
}

/* Arcade sky: a falling pixel starfield and drifting sprites behind the shelf. */
.fx-sky {
  position: fixed;
  z-index: -1;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.fx-stars {
  position: absolute;
  left: 0;
  width: 100%;
  height: calc(100% + var(--fx-shift));
  top: calc(-1 * var(--fx-shift));
  background-color: var(--ink);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 140 140' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M8,14h3v3h-3zM52,40h4v4h-4zM96,22h3v3h-3zM120,68h4v4h-4zM30,86h3v3h-3zM74,108h4v4h-4zM132,120h3v3h-3zM4,120h2v2h-2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 140 140' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M8,14h3v3h-3zM52,40h4v4h-4zM96,22h3v3h-3zM120,68h4v4h-4zM30,86h3v3h-3zM74,108h4v4h-4zM132,120h3v3h-3zM4,120h2v2h-2z'/%3E%3C/svg%3E");
  -webkit-mask-repeat: repeat;
  mask-repeat: repeat;
  animation: fx-fall 44s linear infinite;
}

.fx-stars-far {
  --fx-shift: 140px;
  -webkit-mask-size: 140px 140px;
  mask-size: 140px 140px;
  opacity: .09;
}

.fx-stars-near {
  --fx-shift: 96px;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 96 96' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M6,10h2v2h-2zM38,30h3v3h-3zM70,14h2v2h-2zM20,58h3v3h-3zM84,70h2v2h-2zM54,84h3v3h-3z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 96 96' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M6,10h2v2h-2zM38,30h3v3h-3zM70,14h2v2h-2zM20,58h3v3h-3zM84,70h2v2h-2zM54,84h3v3h-3z'/%3E%3C/svg%3E");
  -webkit-mask-size: 96px 96px;
  mask-size: 96px 96px;
  opacity: .15;
  animation-duration: 30s;
}

@keyframes fx-fall {
  from { transform: translateY(calc(-1 * var(--fx-shift))); }
  to { transform: translateY(0); }
}

.fx-sprite {
  position: absolute;
  background-color: var(--ink);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  opacity: .16;
}

.fx-invader {
  top: 26%;
  left: 2%;
  width: 77px;
  aspect-ratio: 11 / 8;
  background-color: var(--primary);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 11 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M1,0h1v1h-1zM9,0h1v1h-1zM2,1h1v1h-1zM8,1h1v1h-1zM2,2h7v1h-7zM1,3h2v1h-2zM4,3h3v1h-3zM8,3h2v1h-2zM0,4h11v1h-11zM0,5h1v1h-1zM2,5h7v1h-7zM10,5h1v1h-1zM0,6h1v1h-1zM2,6h1v1h-1zM7,6h1v1h-1zM10,6h1v1h-1zM3,7h2v1h-2zM6,7h2v1h-2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 11 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M1,0h1v1h-1zM9,0h1v1h-1zM2,1h1v1h-1zM8,1h1v1h-1zM2,2h7v1h-7zM1,3h2v1h-2zM4,3h3v1h-3zM8,3h2v1h-2zM0,4h11v1h-11zM0,5h1v1h-1zM2,5h7v1h-7zM10,5h1v1h-1zM0,6h1v1h-1zM2,6h1v1h-1zM7,6h1v1h-1zM10,6h1v1h-1zM3,7h2v1h-2zM6,7h2v1h-2z'/%3E%3C/svg%3E");
  animation: fx-drift-a 11s ease-in-out infinite alternate;
}

.fx-ghost {
  top: 56%;
  right: 2.5%;
  width: 64px;
  aspect-ratio: 1;
  background-color: var(--coral);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M2,0h4v1h-4zM1,1h6v1h-6zM0,2h8v1h-8zM0,3h2v1h-2zM3,3h2v1h-2zM6,3h2v1h-2zM0,4h2v1h-2zM3,4h2v1h-2zM6,4h2v1h-2zM0,5h8v1h-8zM0,6h8v1h-8zM0,7h2v1h-2zM3,7h2v1h-2zM6,7h2v1h-2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M2,0h4v1h-4zM1,1h6v1h-6zM0,2h8v1h-8zM0,3h2v1h-2zM3,3h2v1h-2zM6,3h2v1h-2zM0,4h2v1h-2zM3,4h2v1h-2zM6,4h2v1h-2zM0,5h8v1h-8zM0,6h8v1h-8zM0,7h2v1h-2zM3,7h2v1h-2zM6,7h2v1h-2z'/%3E%3C/svg%3E");
  animation: fx-drift-b 13s ease-in-out -5s infinite alternate;
}

.fx-coin {
  bottom: 9%;
  left: 7%;
  width: 56px;
  aspect-ratio: 1;
  background-color: var(--gold);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M2,0h4v1h-4zM1,1h6v1h-6zM0,2h4v1h-4zM5,2h3v1h-3zM0,3h4v1h-4zM5,3h3v1h-3zM0,4h4v1h-4zM5,4h3v1h-3zM0,5h4v1h-4zM5,5h3v1h-3zM1,6h6v1h-6zM2,7h4v1h-4z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Cpath fill='%23000' d='M2,0h4v1h-4zM1,1h6v1h-6zM0,2h4v1h-4zM5,2h3v1h-3zM0,3h4v1h-4zM5,3h3v1h-3zM0,4h4v1h-4zM5,4h3v1h-3zM0,5h4v1h-4zM5,5h3v1h-3zM1,6h6v1h-6zM2,7h4v1h-4z'/%3E%3C/svg%3E");
  animation: fx-drift-a 9s ease-in-out -3.5s infinite alternate-reverse;
}

@keyframes fx-drift-a {
  to { transform: translateY(-18px) rotate(-6deg); }
}

@keyframes fx-drift-b {
  to { transform: translateY(16px) translateX(-12px) rotate(6deg); }
}

@media (max-width: 719px) {
  .fx-sprite { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .fx-stars,
  .fx-sprite { animation: none !important; }
}

/* Header polish: tri-color hairline, tilted brand mark, segmented nav pills. */
.site-header::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--coral) 0 33%, var(--gold) 33% 66%, var(--mint) 66%);
  content: "";
  opacity: .5;
}

.brand-mark {
  transition: transform 200ms ease;
}

.brand:hover .brand-mark {
  transform: rotate(-8deg);
}

.site-nav a {
  transition: color 160ms ease, background-color 160ms ease;
}

@media (min-width: 980px) {
  .site-nav {
    gap: 3px;
    padding: 5px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface) 72%, transparent);
    box-shadow: none;
  }

  .site-nav a {
    min-height: 38px;
    padding: 0 17px;
    border-radius: 999px;
  }

  .site-nav a:hover {
    color: var(--primary);
    background: color-mix(in srgb, var(--primary) 10%, transparent);
  }

  .site-nav a[aria-current="page"] {
    color: var(--primary-ink);
    background: var(--primary);
    box-shadow: 0 3px 0 color-mix(in srgb, var(--primary) 45%, var(--ink));
  }

  .site-nav a[aria-current="page"]::after {
    display: none;
  }
}

/* Collections page: tabs filter the game grid in place. */
.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 18px;
}

.category-tab {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14.5px;
  font-weight: 750;
  cursor: pointer;
  transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.category-tab:hover {
  color: var(--primary);
  border-color: var(--primary);
  transform: translateY(-1px);
}

.category-tab:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.category-tab-count {
  padding: 2px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 8%, transparent);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 800;
}

.category-tab[aria-pressed="true"] {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--primary-ink);
}

.category-tab[aria-pressed="true"] .category-tab-count {
  background: color-mix(in srgb, var(--primary-ink) 22%, transparent);
  color: var(--primary-ink);
}

.category-status {
  margin: 0 0 26px;
  color: var(--ink-soft);
  font-size: 14.5px;
}

[data-game-card][hidden] {
  display: none;
}

/* Header Home button: icon + label. */
.site-nav a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.site-nav a svg {
  width: 14px;
  height: 14px;
  flex: none;
  fill: currentColor;
}

/* Home: staff picks, features, guide, notes. */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg, 18px);
  padding: 26px 24px 28px;
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  color: var(--primary);
  margin-bottom: 18px;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card h3 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  color: var(--ink);
}

.feature-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}

.feature-foot {
  margin: 26px 0 0;
  text-align: right;
}

.step-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  counter-reset: step;
}

.step-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg, 18px);
  padding: 24px 24px 26px;
}

.step-num {
  display: block;
  margin-bottom: 14px;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--primary);
}

.step-num::after {
  content: "";
  display: block;
  width: 34px;
  height: 3px;
  margin-top: 10px;
  background: var(--primary);
  border-radius: 2px;
}

.step-card h3 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  color: var(--ink);
}

.step-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}

.note-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.note-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg, 18px);
  padding: 24px 24px 26px;
}

.note-date {
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--gold) 55%, transparent);
  color: var(--gold);
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.note-card h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}

.note-card p {
  margin: 0;
  flex: 1;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}

@media (max-width: 979px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .step-list,
  .note-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 619px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }
}

/* Local favorites: a lightweight shelf saved in the current browser. */
.game-card { position: relative; }
/* Visually hidden, still read by screen readers. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.favorite-toggle {
  --heart: #e04b4b;
  position: absolute;
  z-index: 4;
  top: 14px;
  right: 14px;
  display: inline-grid;
  width: 40px;
  height: 40px;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 999px;
  background: color-mix(in srgb, #050912 62%, transparent);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  box-shadow: 0 4px 14px rgba(3,6,14,.35);
  color: #fff;
  cursor: pointer;
  transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}
.favorite-toggle svg { width: 20px; height: 20px; fill: transparent; transition: fill 160ms ease, transform 160ms ease; }
.favorite-toggle:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); box-shadow: 0 6px 18px rgba(3,6,14,.45); }
.favorite-toggle:hover svg { transform: scale(1.08); }
.favorite-toggle:active { transform: scale(.9); }
.favorite-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.favorite-toggle.is-favorite { border-color: var(--heart); background: var(--heart); color: #fff; box-shadow: 0 4px 16px color-mix(in srgb, var(--heart) 55%, transparent); animation: favorite-pop 320ms ease; }
.favorite-toggle.is-favorite svg { fill: currentColor; }
.favorite-toggle.is-favorite:hover { border-color: var(--heart); background: color-mix(in srgb, var(--heart) 86%, #fff); color: #fff; }
.favorite-toggle.is-favorite:hover svg { transform: none; }
@keyframes favorite-pop {
  0% { transform: scale(.86); }
  55% { transform: scale(1.12); }
  100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .favorite-toggle.is-favorite { animation: none; }
}
.favorite-toggle-large {
  position: static;
  flex: 0 0 auto;
  width: auto;
  min-width: 98px;
  height: 44px;
  grid-auto-flow: column;
  gap: 8px;
  padding: 0 15px;
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  white-space: nowrap;
}
.favorite-toggle-large.is-favorite { color: #fff; }
.game-heading-row { display: flex; align-items: center; gap: 18px; }
.game-heading-row h1 { margin-bottom: 0; }
.favorites-summary { align-items: center; }
.favorites-summary .button:disabled { cursor: not-allowed; opacity: .45; }
.favorites-grid [data-game-card][hidden] { display: none; }
.empty-state {
  display: grid;
  max-width: 620px;
  margin: 0 auto 32px;
  padding: 54px 28px;
  border: 1px dashed var(--line-strong);
  border-radius: 20px;
  background: color-mix(in srgb, var(--surface) 72%, transparent);
  text-align: center;
  justify-items: center;
}
.empty-state[hidden] { display: none; }
.empty-state h2 { margin: 10px 0; font-family: var(--serif); font-size: clamp(30px, 4vw, 46px); }
.empty-state p { max-width: 40ch; color: var(--ink-soft); }
.empty-state .button { margin-top: 18px; }
@media (max-width: 719px) {
  .game-heading-row { align-items: flex-start; flex-direction: column; gap: 12px; }
  .favorite-toggle-large { align-self: flex-start; }
}
