@import url('https://fonts.googleapis.com/css2?family=Silkscreen:wght@400;700&family=Space+Mono:wght@400;700&display=swap');

:root {
  --bg: #FF924F;
  --bg-dark: #E8884A;
  --text: #2D1810;
  --text-soft: #5A3828;
  --text-muted: rgba(45, 24, 16, 0.5);
  --white: #DFFFCF;
  --accent: #1A1A1A;
  --link: #2D1810;
  --link-hover: #FF6B2B;
}

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

body {
  margin: 0;
  font-family: 'Space Mono', monospace;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--bg);
  -webkit-text-size-adjust: 100%;
  min-height: 100vh;
}

/* ══════════ PIXEL NOISE OVERLAY ══════════ */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='1' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1000;
}

/* ══════════ LANDING PAGE ══════════ */
.landing {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
  position: relative;
}

.logo-container {
  position: relative;
  margin-bottom: 2rem;
}

.logo-container img,
.logo-container canvas {
  width: 200px;
  height: 200px;
  display: block;
  cursor: pointer;
  image-rendering: pixelated;
}

.studio-name {
  font-family: 'Silkscreen', cursive;
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin: 0;
  text-align: center;
}

.studio-tagline {
  font-family: 'Space Mono', monospace;
  font-size: clamp(0.75rem, 2vw, 0.95rem);
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  margin-top: 0.5rem;
  text-align: center;
}

.landing-footer {
  position: absolute;
  bottom: 2rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.landing-footer a {
  color: var(--text-soft);
  text-decoration: none;
  border-bottom: 1px solid rgba(45, 24, 16, 0.3);
  transition: border-color 0.2s;
}

.landing-footer a:hover {
  border-color: var(--text);
}


/* ══════════ POLICY PAGE ══════════ */
.page {
  max-width: 68ch;
  padding: 3rem 1.5rem;
  margin: 0 auto;
}

.page .back-link {
  display: inline-block;
  margin-bottom: 2rem;
  font-family: 'Silkscreen', cursive;
  font-size: 0.85rem;
  color: var(--text-soft);
  text-decoration: none;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}

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

.page h1 {
  font-family: 'Silkscreen', cursive;
  font-size: clamp(1.5rem, 4vw, 2rem);
  color: var(--accent);
  margin: 0 0 0.5rem 0;
  line-height: 1.3;
}

.page h2 {
  font-family: 'Silkscreen', cursive;
  font-size: 1.1rem;
  color: var(--accent);
  margin: 2.5rem 0 0.75rem 0;
  line-height: 1.3;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid rgba(45, 24, 16, 0.1);
}

.page h3 {
  font-family: 'Silkscreen', cursive;
  font-size: 0.95rem;
  color: var(--text);
  margin: 1.5rem 0 0.5rem 0;
  line-height: 1.4;
}

.page p {
  margin: 0 0 1rem 0;
  color: var(--text-soft);
}

.page ul {
  margin: 0.25rem 0 1rem 1.25rem;
  padding: 0;
  color: var(--text-soft);
}

.page li {
  margin: 0.4rem 0;
}

.page a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid rgba(45, 24, 16, 0.3);
  transition: all 0.2s;
}

.page a:hover {
  color: var(--link-hover);
  border-color: var(--link-hover);
}

.policy-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 2.5rem;
}

.policy-section {
  margin-bottom: 0.5rem;
}

.third-party-list {
  list-style: disc;
}

.third-party-list li {
  margin: 0.4rem 0;
}

.updated {
  margin-top: 3rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  padding-top: 1.5rem;
  border-top: 2px solid rgba(45, 24, 16, 0.08);
}

/* ══════════ GAME OVERLAY ══════════ */
#game-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
}

#game-canvas {
  width: 640px;
  height: 576px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  border: 4px solid #041A04;
  border-radius: 4px;
  background: #000;
}

#game-close {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: #E0F8CF;
  font-size: 2.5rem;
  cursor: pointer;
  font-family: 'Silkscreen', cursive;
  line-height: 1;
  z-index: 1000;
}

#game-close:hover {
  color: #FF924F;
}

@media (max-width: 700px) {
  #game-canvas {
    width: calc(160px * 2);
    height: calc(144px * 2);
  }
}

@media (max-width: 380px) {
  #game-canvas {
    width: 160px;
    height: 144px;
  }
}

/* ══════════ RESPONSIVE ══════════ */
@media (max-width: 480px) {
  .logo-container img {
    width: 150px;
    height: 150px;
  }

  .page {
    padding: 2rem 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}
