@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

/* ── ZX Spectrum Design Tokens ─────────────────────────────── */
:root {
  /* Authentic ZX Spectrum palette */
  --spec-blue:    #0000D7;
  --spec-bright-blue:    #0000FF;
  --spec-bright-red:     #FF0000;
  --spec-bright-magenta: #FF00FF;
  --spec-bright-green:   #00FF00;
  --spec-bright-cyan:    #00FFFF;
  --spec-bright-yellow:  #FFFF00;

  /* Site tokens mapped to Spectrum */
  --bg-0: #000000;
  --bg-1: #000000;
  --bg-2: #000000;
  --bg-3: #0000D7;
  --bg-4: #111111;

  --purple:       #D700D7;
  --purple-light: #FF00FF;
  --purple-glow:  rgba(255, 0, 255, 0.2);
  --cyan:         #00FFFF;
  --cyan-glow:    rgba(0, 255, 255, 0.15);

  --text-1: #FFFFFF;
  --text-2: #FFFF00;
  --text-3: #00FFFF;

  --border:       #FFFFFF;
  --border-hover: #FFFF00;

  --nav-h: 56px;
  --radius: 0px;
  --radius-sm: 0px;
  --transition: 0.05s;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Courier New', Courier, monospace;
  background: var(--bg-0);
  color: var(--text-1);
  min-height: 100vh;
  line-height: 1.65;
  overflow-x: hidden;
}

/* CRT scanlines overlay */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0px,
    transparent 3px,
    rgba(0, 0, 0, 0.18) 3px,
    rgba(0, 0, 0, 0.18) 4px
  );
  pointer-events: none;
  z-index: 9999;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

/* ── Layout ────────────────────────────────────────────────── */
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 80px 0;
}

/* ── Navigation ────────────────────────────────────────────── */
nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  background: #0000D7;
  border-bottom: 3px solid #FFFF00;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
}

.nav-logo {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.6rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: #FFFF00;
  transition: none;
}
.nav-logo:hover { color: #FFFFFF; }
.nav-logo span { color: #00FFFF; }

.nav-links {
  display: flex;
  gap: 2rem;
}
.nav-links a {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.5rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #FFFFFF;
  transition: none;
  position: relative;
}
.nav-links a:hover { color: #FFFF00; }
.nav-links a.active { color: #FFFF00; }
.nav-links a.active::before { content: '> '; }
.nav-links a::after { display: none; }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #FFFF00;
  transition: transform var(--transition), opacity var(--transition);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.55rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  cursor: pointer;
  border: 2px solid #FFFFFF;
  transition: none;
  white-space: nowrap;
  text-transform: uppercase;
}

.btn-primary {
  background: #FFFF00;
  color: #000000;
  border-color: #FFFF00;
}
.btn-primary:hover {
  background: #000000;
  color: #FFFF00;
  border-color: #FFFF00;
}

.btn-ghost {
  background: transparent;
  color: #FFFFFF;
  border-color: #FFFFFF;
}
.btn-ghost:hover {
  background: #FFFFFF;
  color: #000000;
}

.btn-sm {
  padding: 0.45rem 0.9rem;
  font-size: 0.5rem;
}

/* ── Badges & Tags ─────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid;
}
.badge-dev {
  background: #0000D7;
  color: #00FFFF;
  border-color: #00FFFF;
}
.badge-released {
  background: #00D700;
  color: #000000;
  border-color: #000000;
}

.tag {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  background: #000000;
  border: 1px solid #FFFFFF;
  font-family: 'Courier New', monospace;
  font-size: 0.7rem;
  color: #00FFFF;
  letter-spacing: 0.04em;
}

/* ── Section Headers ───────────────────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 3rem;
}
.section-title {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(0.9rem, 2.5vw, 1.3rem);
  font-weight: 400;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  line-height: 1.8;
}
.section-title span { color: #FFFF00; }
.section-subtitle {
  font-family: 'Courier New', monospace;
  color: #00FFFF;
  font-size: 0.95rem;
}

.section-footer {
  text-align: center;
  margin-top: 2.5rem;
}

/* ── Hero ──────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: var(--nav-h);
  background: #000000;
}

/* Subtle Spectrum attribute-cell grid */
.hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 0, 215, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 215, 0.07) 1px, transparent 1px);
  background-size: 32px 32px;
}
.hero-bg::after { display: none; }

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 820px;
  padding: 0 1.5rem;
  animation: fadeInUp 0.5s step-end both;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  background: #0000D7;
  border: 2px solid #00FFFF;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.45rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #00FFFF;
  margin-bottom: 2rem;
}
.hero-badge::after {
  content: '_';
  animation: blink 1s step-end infinite;
}

.hero-title {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(1rem, 3.5vw, 2rem);
  font-weight: 400;
  line-height: 1.7;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
}
.hero-title span { color: #FFFF00; }

.hero-subtitle {
  font-family: 'Courier New', monospace;
  font-size: clamp(0.85rem, 1.5vw, 1rem);
  color: #FFFF00;
  margin-bottom: 2.5rem;
  line-height: 2;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: #00FFFF;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  animation: fadeInUp 0.5s 0.3s step-end both;
}
.scroll-line {
  width: 1px;
  height: 32px;
  background: #00FFFF;
  animation: scrollPulse 1s step-end infinite;
}
@keyframes scrollPulse {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* ── Game Cards ────────────────────────────────────────────── */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 4px;
}

.game-card {
  background: #000000;
  border: 2px solid #FFFFFF;
  overflow: hidden;
  transition: none;
}
.game-card:hover {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
}

/* Game card art — Spectrum attribute colours */
.game-card-art {
  height: 180px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-card-art.lords {
  background: #0000D7;
}
.game-card-art.lords::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to right,
    transparent 0px,
    transparent 24px,
    rgba(0, 215, 215, 0.25) 24px,
    rgba(0, 215, 215, 0.25) 32px
  );
}

.game-card-art.gol {
  background: #000000;
  border-bottom: 2px solid #00D700;
}
.game-card-art.gol::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      to right,
      transparent 0px, transparent 15px,
      rgba(0, 215, 0, 0.15) 15px, rgba(0, 215, 0, 0.15) 16px
    ),
    repeating-linear-gradient(
      to bottom,
      transparent 0px, transparent 15px,
      rgba(0, 215, 0, 0.15) 15px, rgba(0, 215, 0, 0.15) 16px
    );
}
.game-card-art.gol::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px),
    radial-gradient(circle, #00FF00 2px, transparent 2px);
  background-size: 16px 16px;
  background-position:
    32px 48px, 48px 48px, 64px 48px,
    32px 64px, 64px 64px,
    32px 80px, 48px 80px, 64px 80px;
  background-repeat: no-repeat;
  animation: golPulse 1.5s step-end infinite;
}
@keyframes golPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.game-card-art.magik {
  background: #D700D7;
}
.game-card-art.magik::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to right,
    transparent 0px,
    transparent 24px,
    rgba(255, 255, 0, 0.3) 24px,
    rgba(255, 255, 0, 0.3) 32px
  );
  animation: magikPulse 1s step-end infinite;
}
@keyframes magikPulse {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

.game-icon {
  position: relative;
  z-index: 1;
  font-size: 3rem;
  color: #FFFF00;
  text-shadow: 2px 2px 0 #000000;
  filter: none;
  opacity: 1;
}

.game-card-body {
  padding: 1.25rem;
  border-top: 2px solid #FFFFFF;
}
.game-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.game-engine {
  font-family: 'Courier New', monospace;
  font-size: 0.7rem;
  color: #00FFFF;
  letter-spacing: 0.06em;
}
.game-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
  line-height: 1.8;
  color: #FFFF00;
}
.game-desc {
  font-family: 'Courier New', monospace;
  font-size: 0.88rem;
  color: #FFFFFF;
  line-height: 1.75;
  margin-bottom: 1rem;
}
.game-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-bottom: 1rem;
}

/* ── Games Page — Full Cards ───────────────────────────────── */
.game-full {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: #000000;
  border: 2px solid #FFFFFF;
  overflow: hidden;
  margin-bottom: 4px;
  transition: none;
}
.game-full:hover {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
}
.game-full-art {
  min-height: 300px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.game-full-art.gol { background: #000000; border-right: 2px solid #00D700; }
.game-full-art.gol::before { background-image: repeating-linear-gradient(to right, transparent 0px, transparent 15px, rgba(0,215,0,0.12) 15px, rgba(0,215,0,0.12) 16px), repeating-linear-gradient(to bottom, transparent 0px, transparent 15px, rgba(0,215,0,0.12) 15px, rgba(0,215,0,0.12) 16px); position: absolute; inset: 0; content: ''; }

.game-full-art .game-icon {
  font-size: 5rem;
  opacity: 1;
}
.game-full-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 2px solid #FFFFFF;
}
.game-full-title {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(0.7rem, 1.5vw, 1rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
  color: #FFFF00;
  line-height: 1.8;
}
.game-full-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.game-full-desc {
  font-family: 'Courier New', monospace;
  color: #FFFFFF;
  font-size: 0.9rem;
  line-height: 1.75;
  margin-bottom: 1.25rem;
}
.game-full-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-bottom: 1.25rem;
}
.game-full-features {
  margin-bottom: 1.5rem;
}
.game-full-features h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.5rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #00FFFF;
  margin-bottom: 0.75rem;
}
.game-full-features ul {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.game-full-features li {
  font-family: 'Courier New', monospace;
  font-size: 0.88rem;
  color: #FFFFFF;
  padding-left: 1.25rem;
  position: relative;
}
.game-full-features li::before {
  content: '>';
  position: absolute;
  left: 0;
  color: #FFFF00;
}

/* ── About Teaser (Homepage) ───────────────────────────────── */
.about-teaser {
  background: #0000D7;
  border-top: 3px solid #FFFF00;
  border-bottom: 3px solid #FFFF00;
}
.about-teaser-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  align-items: center;
}
.about-teaser-text h2 {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(0.75rem, 2vw, 1rem);
  font-weight: 400;
  line-height: 2.2;
  margin-bottom: 1rem;
  color: #FFFFFF;
}
.about-teaser-text h2 span { color: #FFFF00; }
.about-teaser-text p {
  font-family: 'Courier New', monospace;
  color: #00FFFF;
  font-size: 0.9rem;
  line-height: 1.75;
  margin-bottom: 1.5rem;
  max-width: 520px;
}
.about-teaser-stats {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat {
  text-align: center;
  padding: 1rem 1.5rem;
  background: #000000;
  border: 2px solid #FFFF00;
}
.stat-num {
  display: block;
  font-family: 'Press Start 2P', monospace;
  font-size: 1.5rem;
  font-weight: 400;
  color: #FFFF00;
  line-height: 1;
  margin-bottom: 0.4rem;
}
.stat-label {
  font-family: 'Courier New', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #00FFFF;
}

/* ── About Page ────────────────────────────────────────────── */
.about-hero {
  padding-top: calc(var(--nav-h) + 80px);
  padding-bottom: 80px;
  text-align: center;
  background: #000000;
}
.about-hero h1 {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(0.9rem, 2.5vw, 1.6rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 1.25rem;
  line-height: 1.8;
}
.about-hero h1 span { color: #FFFF00; }
.about-hero p {
  font-family: 'Courier New', monospace;
  color: #FFFF00;
  font-size: 1rem;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.75;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 4px;
}

.about-card {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 1.75rem;
  transition: none;
}
.about-card:hover {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
}
.about-card-icon {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
}
.about-card h2 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
  color: #FFFF00;
  line-height: 1.8;
}
.about-card p {
  font-family: 'Courier New', monospace;
  font-size: 0.88rem;
  color: #FFFFFF;
  line-height: 1.75;
}

.about-full {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 2rem;
  margin-bottom: 4px;
}
.about-full h2 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
  color: #00FFFF;
  line-height: 1.8;
}
.about-full p {
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  color: #FFFFFF;
  line-height: 1.8;
  margin-bottom: 1rem;
}
.about-full p:last-child { margin-bottom: 0; }

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 2px;
  margin-top: 1rem;
}
.tool-chip {
  background: #0000D7;
  border: 1px solid #00FFFF;
  padding: 0.5rem 0.75rem;
  font-family: 'Courier New', monospace;
  font-size: 0.78rem;
  color: #FFFF00;
  text-align: center;
  transition: none;
}
.tool-chip:hover {
  background: #FFFF00;
  color: #000000;
  border-color: #FFFF00;
}

/* ── Page Header (non-hero pages) ──────────────────────────── */
.page-header {
  padding-top: calc(var(--nav-h) + 56px);
  padding-bottom: 56px;
  text-align: center;
}
.page-header h1 {
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(0.9rem, 2.5vw, 1.6rem);
  font-weight: 400;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
  line-height: 1.8;
}
.page-header h1 span { color: #FFFF00; }
.page-header p {
  font-family: 'Courier New', monospace;
  color: #00FFFF;
  font-size: 0.95rem;
}

/* ── Divider ───────────────────────────────────────────────── */
.divider {
  height: 3px;
  background: #FFFF00;
  margin: 0;
}

/* ── Footer ────────────────────────────────────────────────── */
footer {
  background: #0000D7;
  border-top: 3px solid #FFFF00;
  padding: 2.5rem 0 1.25rem;
}
.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.footer-brand .nav-logo {
  display: inline-block;
  margin-bottom: 0.5rem;
}
.footer-brand p {
  font-family: 'Courier New', monospace;
  font-size: 0.8rem;
  color: #FFFFFF;
}
.footer-links,
.footer-social {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.footer-links a,
.footer-social a {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #FFFFFF;
  transition: none;
}
.footer-links a:hover { color: #FFFF00; }
.footer-social a { color: #FFFF00; }
.footer-social a:hover { color: #00FFFF; }
.footer-bottom {
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 0, 0.3);
  text-align: center;
}
.footer-bottom p {
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  color: #00FFFF;
}

/* ── Spectrum Loader ───────────────────────────────────────── */
#spectrum-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Pilot tone: solid cyan. JS switches to data-flash class after 600ms */
  background: #00FFFF;
}

#spectrum-loader.loader-data {
  animation: loaderBorderFlash 0.09s step-end infinite;
}

@keyframes loaderBorderFlash {
  0%   { background: #00FFFF; }
  50%  { background: #FFFF00; }
}

.loader-screen {
  /* 4:3 ratio — authentic Spectrum 256×192 display proportion */
  width: min(72vw, 576px);
  aspect-ratio: 4 / 3;
  background: #000000;
  position: relative;
  overflow: hidden;
}

/* Stripes fill from top to bottom — height animated by JS */
.loader-stripes {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 0%;
  background: repeating-linear-gradient(
    to bottom,
    #00FFFF 0px,
    #00FFFF 2px,
    #FFFF00 2px,
    #FFFF00 4px
  );
}

.loader-text {
  position: absolute;
  bottom: 12%;
  left: 0;
  right: 0;
  z-index: 2;
  text-align: center;
  font-family: 'Press Start 2P', monospace;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.loader-title {
  font-size: 0.5rem;
  color: #FFFFFF;
  letter-spacing: 0.15em;
  text-shadow: 2px 2px 0 #000000;
}

.loader-program {
  font-size: 0.75rem;
  color: #FFFF00;
  letter-spacing: 0.04em;
  text-shadow: 2px 2px 0 #000000;
}

.loader-bytes {
  font-size: 0.45rem;
  color: #00FFFF;
  letter-spacing: 0.08em;
  text-shadow: 2px 2px 0 #000000;
}

/* ── Animations ────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.fade-in {
  animation: fadeInUp 0.4s step-end both;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 0 1rem; }

  .nav-toggle { display: flex; }

  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: #0000D7;
    border-bottom: 3px solid #FFFF00;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 0;
    transform: translateY(-110%);
    transition: transform 0.2s;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links li { width: 100%; }
  .nav-links a {
    display: block;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 0, 0.25);
    font-size: 0.55rem;
  }

  .section { padding: 56px 0; }

  .games-grid { grid-template-columns: 1fr; }

  .game-full { grid-template-columns: 1fr; }
  .game-full-art { min-height: 200px; }
  .game-full-body {
    border-left: none;
    border-top: 2px solid #FFFFFF;
  }

  .about-teaser-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-teaser-stats {
    flex-direction: row;
    justify-content: center;
  }
  .stat { padding: 0.75rem 1.25rem; }

  .about-grid { grid-template-columns: 1fr; }

  .footer-inner { flex-direction: column; gap: 1.5rem; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 0.85rem; }
  .hero-cta { flex-direction: column; align-items: center; }
  .btn { width: 100%; justify-content: center; }
  .hero-cta .btn { max-width: 280px; }
}

/* ── Mobile Touch States ───────────────────────────────────── */
/* Mirror existing hover styles exactly; transition: 0.05s step-end for snappy response */
.btn-primary:active {
  background: #000000;
  color: #FFFF00;
  border-color: #FFFF00;
  transition: 0.05s step-end;
}
.btn-ghost:active {
  background: #FFFFFF;
  color: #000000;
  transition: 0.05s step-end;
}
.game-card:active {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
  transition: 0.05s step-end;
}
.game-full:active {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
  transition: 0.05s step-end;
}
.about-card:active {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
  transition: 0.05s step-end;
}

/* ── Press Page ────────────────────────────────────────────── */
.press-studio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 4px;
}

.press-games-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin-bottom: 4px;
}

.press-placeholder {
  border: 2px dashed #FFFFFF;
  background: #000000;
  min-height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  color: #00FFFF;
  letter-spacing: 0.06em;
  text-align: center;
}

.press-boilerplate {
  border: 2px solid #00FFFF;
  background: #000000;
  padding: 1rem 1.25rem;
  margin-top: 1rem;
}

.press-boilerplate .press-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  color: #00FFFF;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 0.75rem;
}

.press-boilerplate p {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #FFFFFF;
  line-height: 1.75;
}

.press-facts {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 1.75rem;
}

.press-facts h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #FFFF00;
  margin-bottom: 1rem;
  line-height: 1.8;
}

.press-facts dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1rem;
}

.press-facts dt {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  color: #00FFFF;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding-top: 0.2rem;
}

.press-facts dd {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #FFFFFF;
}

.press-bio {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 1.75rem;
}

.press-bio h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #FFFF00;
  margin-bottom: 1rem;
  line-height: 1.8;
}

.press-bio p {
  font-family: 'Courier New', monospace;
  font-size: 0.88rem;
  color: #FFFFFF;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.press-game-col {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 1.5rem;
}

.press-game-col:hover {
  border-color: #FFFF00;
  box-shadow: 4px 4px 0 #FFFF00;
}

.press-game-col h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65rem;
  font-weight: 400;
  color: #FFFF00;
  margin-bottom: 0.75rem;
  line-height: 1.8;
}

.press-game-col .game-card-meta {
  margin-bottom: 0.75rem;
}

.press-game-col p {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #FFFFFF;
  line-height: 1.75;
  margin-bottom: 1rem;
}

.press-screenshots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin: 0.75rem 0;
}

.press-contact-box {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 2rem;
  margin-bottom: 4px;
}

.press-contact-box h3 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #00FFFF;
  margin-bottom: 1.25rem;
  line-height: 1.8;
}

.press-contact-box p {
  font-family: 'Courier New', monospace;
  font-size: 0.88rem;
  color: #FFFFFF;
  line-height: 1.8;
  margin-bottom: 0.5rem;
}

.press-contact-box a {
  color: #FFFF00;
}

.press-contact-box a:hover {
  color: #00FFFF;
}

.press-assets-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 4px;
}

.press-asset-panel {
  background: #000000;
  border: 2px solid #FFFFFF;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.press-asset-panel h4 {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.55rem;
  color: #FFFF00;
  letter-spacing: 0.06em;
}

/* Game screenshots strip inside .game-full cards */
.game-screenshots {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  border-top: 2px solid #FFFFFF;
  padding: 4px;
  background: #000000;
}

/* Button group for side-by-side buttons */
.game-full-cta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Press contact response note */
.press-response-note {
  color: #00FFFF;
  margin-top: 1rem;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  letter-spacing: 0.1em;
}

/* Press facts link colour */
.press-facts a {
  color: #FFFF00;
  font-family: 'Courier New', monospace;
}

@media (max-width: 768px) {
  .press-studio-grid { grid-template-columns: 1fr; }
  .press-games-grid { grid-template-columns: 1fr; }
  .press-assets-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .game-screenshots { grid-template-columns: 1fr; }
  .press-screenshots { grid-template-columns: 1fr; }
}

/* ── Accessibility Utilities ───────────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  z-index: 99999;
  padding: 0.5rem 1rem;
  background: #FFFF00;
  color: #000000;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.5rem;
  letter-spacing: 0.05em;
  text-decoration: none;
}
.skip-link:focus {
  top: 0;
}

:focus-visible {
  outline: 2px solid var(--spec-bright-yellow);
  outline-offset: 3px;
}

.reveal-pending {
  opacity: 0;
}

/* ── Reduced Motion ─────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
