@font-face {
  font-family: "Jersey 10";
  src: url("/fonts/jersey-10-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Pixelify Sans";
  src: url("/fonts/pixelify-sans-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Pixelify Sans";
  src: url("/fonts/pixelify-sans-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  --bg: #0b0820;
  --bg-2: #120c2c;
  --panel: #1a1238;
  --line: #3a2a6e;
  --text: #ece6ff;
  --muted: #a99cd6;
  --pink: #ff4f9a;
  --pink-dark: #b3245f;
  --cyan: #59e3ff;
  --gold: #ffc35a;
  --ember: #ff8a3d;
  --px: 4px;
  --display: "Jersey 10", ui-monospace, monospace;
  --body: "Pixelify Sans", ui-monospace, "Courier New", monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 1.15rem;
  line-height: 1.55;
  overflow-x: hidden;
}
img, video { max-width: 100%; height: auto; display: block; }

a { color: var(--cyan); }
a:hover { color: #fff; }
:focus-visible { outline: var(--px) solid var(--gold); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1; margin: 0; letter-spacing: 0.01em; }
h2 { font-size: clamp(2.6rem, 6.5vw, 4.4rem); margin-bottom: 1.4rem; text-transform: uppercase; text-shadow: 0 4px 0 #000; }
h2 em, h1 em { font-style: normal; color: var(--pink); }
h3 { font-size: 2rem; margin-bottom: 0.6rem; }
p { margin: 0 0 1rem; }

/* Silver pixel heading, like the Steam page section headers. */
.px-heading {
  text-transform: uppercase;
  color: #f2f3f7;
  background: linear-gradient(#ffffff 0 45%, #b9bccb 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(3px 3px 0 #000);
}

.skip {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  background: var(--gold); color: var(--bg); padding: 0.5rem 1rem; font-family: var(--display); font-size: 1.3rem;
}
.skip:focus { top: 1rem; }

.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }

/* Pixel-notched box: the 4 shadows draw the border and leave the corners cut. */
.card, .video, .stat, .mail, .feature-media, .gallery a {
  box-shadow:
    0 calc(var(--px) * -1) 0 0 var(--bc, var(--line)),
    0 var(--px) 0 0 var(--bc, var(--line)),
    calc(var(--px) * -1) 0 0 0 var(--bc, var(--line)),
    var(--px) 0 0 0 var(--bc, var(--line));
}

/* ---------- Buttons ---------- */
/* Pixel buttons: notched corners (clip-path), a lit top edge and a shaded bottom edge. */
.btn {
  --fill: var(--pink); --fill-hover: #ff6aa9;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem;
  font-family: var(--display); font-size: 1.5rem; line-height: 1; letter-spacing: 0.04em;
  text-decoration: none; text-transform: uppercase; color: #fff; text-shadow: 0 2px 0 rgba(0, 0, 0, 0.28);
  background: var(--fill); border: 0; cursor: pointer;
  padding: 0.75rem 1.35rem 0.9rem;
  clip-path: polygon(4px 0, calc(100% - 4px) 0, 100% 4px, 100% calc(100% - 4px), calc(100% - 4px) 100%, 4px 100%, 0 calc(100% - 4px), 0 4px);
  box-shadow: inset 0 4px 0 rgba(255, 255, 255, 0.22), inset 0 -5px 0 rgba(0, 0, 0, 0.28);
  transition: transform 80ms steps(2), background-color 80ms steps(2);
}
.btn svg { width: 14px; height: 14px; flex: none; }
.btn:hover { color: #fff; background: var(--fill-hover); transform: translateY(-2px); }
.btn:active { transform: translateY(1px); box-shadow: inset 0 4px 0 rgba(0, 0, 0, 0.2); }
.btn-ghost { --fill: rgba(236, 230, 255, 0.1); --fill-hover: rgba(236, 230, 255, 0.2); box-shadow: inset 0 0 0 2px rgba(236, 230, 255, 0.55), inset 0 -5px 0 rgba(0, 0, 0, 0.25); backdrop-filter: blur(3px); }
.btn-sm { font-size: 1.25rem; padding: 0.5rem 0.95rem 0.65rem; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.6rem max(16px, calc((100% - 1120px) / 2));
  background: linear-gradient(to bottom, rgba(11, 8, 32, 0.85), rgba(11, 8, 32, 0));
  transition: background-color 150ms;
}
.nav.scrolled { background: rgba(11, 8, 32, 0.95); border-bottom: var(--px) solid var(--bg-2); }
.brand {
  display: flex; align-items: center; gap: 0.65rem; text-decoration: none; color: #ece4ce;
  font-family: var(--display); font-size: 1.6rem; line-height: 1; text-transform: uppercase; letter-spacing: 0.04em;
}
.brand-mark { width: 40px; height: 40px; image-rendering: pixelated; }
.nav ul { display: flex; gap: 1.8rem; list-style: none; margin: 0; padding: 0; }
.nav nav a { font-family: var(--display); font-size: 1.4rem; text-transform: uppercase; color: var(--text); text-decoration: none; text-shadow: 0 2px 0 #000; }
.nav nav a:hover { color: var(--gold); }
@media (max-width: 860px) { .nav nav { display: none; } }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center;
  padding: 100px max(16px, calc((100% - 1120px) / 2)) 80px;
  overflow: hidden; isolation: isolate; background: #140c2e;
}
.hero-art { position: absolute; inset: 0; z-index: -2; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 50%; }
.hero::before { /* darken the left so the copy reads */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(11, 8, 32, 0.92) 0%, rgba(11, 8, 32, 0.72) 32%, rgba(11, 8, 32, 0.05) 62%),
    linear-gradient(to bottom, rgba(11, 8, 32, 0) 70%, var(--bg) 100%);
}
.sparkle { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; image-rendering: pixelated; }
.hero-inner { max-width: 660px; }
.eyebrow {
  font-family: var(--display); font-size: 1.5rem; text-transform: uppercase; color: var(--cyan);
  letter-spacing: 0.12em; margin-bottom: 0.4rem; text-shadow: 0 2px 0 #000;
}
.logo-title { margin: 0 0 0.6rem; }
.logo-title img { width: min(100%, 470px); image-rendering: pixelated; filter: drop-shadow(0 6px 0 rgba(0, 0, 0, 0.55)); margin-left: -6px; }
.tagline { font-family: var(--display); font-size: clamp(1.7rem, 3.2vw, 2.3rem); line-height: 1.1; text-transform: uppercase; text-shadow: 0 3px 0 #000; margin-bottom: 0.4rem; }
.tagline strong, .release strong { color: var(--gold); font-weight: 400; }
.release { font-family: var(--display); font-size: 1.5rem; text-transform: uppercase; color: var(--muted); text-shadow: 0 2px 0 #000; margin-bottom: 1.8rem; }

.cta { display: flex; flex-wrap: wrap; gap: 0.8rem 1.1rem; }

.scroll-hint { position: absolute; bottom: 24px; left: 50%; translate: -50% 0; color: var(--text); animation: bob 1.6s steps(2) infinite; }
.scroll-hint svg { width: 28px; height: 16px; display: block; }
@keyframes bob { 50% { transform: translateY(6px); } }

@media (max-width: 760px) {
  .hero { display: block; min-height: 0; padding: 0 16px 56px; background: var(--bg); }
  .hero-art { position: relative; inset: auto; margin: 0 -16px; aspect-ratio: 16 / 10; }
  .hero-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(11, 8, 32, 0.5) 0, rgba(11, 8, 32, 0) 30%, rgba(11, 8, 32, 0) 60%, var(--bg) 100%); }
  .hero-art img { object-position: 50% 50%; }
  .hero::before, .sparkle, .scroll-hint { display: none; }
  .hero-inner { margin-top: -3.5rem; position: relative; text-align: center; }
  .logo-title img { margin: 0 auto; width: min(86%, 380px); }
  .cta { justify-content: center; }
}

/* ---------- Marquee ---------- */
.marquee {
  background: var(--pink); color: #fff; overflow: hidden; white-space: nowrap;
  border-block: var(--px) solid var(--pink-dark);
  font-family: var(--display); font-size: 1.5rem; line-height: 1; text-transform: uppercase; padding: 0.6rem 0 0.7rem;
}
.marquee { display: flex; }
.marquee-group {
  flex: none; min-width: 100%; display: flex; justify-content: space-around; gap: 1.6rem; padding-right: 1.6rem;
  animation: marquee 96s linear infinite;
}
.marquee .star { color: var(--gold); }
@keyframes marquee { to { transform: translateX(-100%); } }

/* ---------- Sections ---------- */
.section { padding: clamp(4rem, 9vw, 7rem) 0; position: relative; }
.section-alt { background: var(--bg-2); }
.section-alt::before, .section-alt::after { /* stepped pixel edges */
  content: ""; position: absolute; left: 0; right: 0; height: 12px;
  background:
    linear-gradient(90deg, var(--bg-2) 50%, transparent 0) 0 0 / 24px 4px repeat-x,
    linear-gradient(90deg, transparent 25%, var(--bg-2) 25% 75%, transparent 0) 0 4px / 24px 4px repeat-x;
}
.section-alt::before { top: -8px; }
.section-alt::after { bottom: -8px; transform: scaleY(-1); }

.prompt { font-family: var(--display); font-size: 1.35rem; color: var(--cyan); margin-bottom: 0.6rem; }
.prompt::after { content: "_"; animation: blink 1s steps(1) infinite; margin-left: 2px; }
@keyframes blink { 50% { opacity: 0; } }
.lead { font-size: 1.3rem; color: var(--text); max-width: 52ch; }

/* ---------- Features ---------- */
.features { display: grid; gap: clamp(3rem, 7vw, 5rem); margin-top: clamp(2.5rem, 6vw, 4.5rem); }
.feature { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.feature:nth-child(even) .feature-media { order: 2; }
.feature-media { --bc: var(--line); margin: var(--px); background: #000; line-height: 0; }
.feature-media video { width: 100%; image-rendering: pixelated; }
.feature-copy h3 { font-size: clamp(2.2rem, 4.5vw, 3.2rem); margin-bottom: 0.8rem; }
.feature-copy p { color: var(--muted); font-size: 1.2rem; max-width: 40ch; }
@media (max-width: 820px) {
  .feature { grid-template-columns: 1fr; }
  .feature:nth-child(even) .feature-media { order: 0; }
}

/* ---------- Gallery ---------- */
.gallery { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 1.4rem; }
.gallery a { --bc: var(--line); display: block; margin: var(--px); line-height: 0; overflow: hidden; background: #000; }
.gallery img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; transition: transform 160ms steps(3), opacity 160ms; opacity: 0.92; }
.gallery a:hover { --bc: var(--pink); }
.gallery a:hover img { transform: scale(1.04); opacity: 1; }

.lightbox { border: 0; padding: 0; background: transparent; max-width: min(96vw, 1600px); max-height: 92vh; overflow: visible; }
.lightbox::backdrop { background: rgba(5, 3, 15, 0.9); }
.lightbox img { max-height: 88vh; width: auto; box-shadow: 0 0 0 var(--px) var(--line); }
.lightbox-close {
  position: absolute; top: -48px; right: 0; width: 40px; height: 40px; border: 0; cursor: pointer;
  background: var(--pink); color: #fff; font-family: var(--display); font-size: 2rem; line-height: 1;
}

/* ---------- Trailer ---------- */
.video { --bc: var(--pink); position: relative; aspect-ratio: 16 / 9; background: #000; margin: var(--px) var(--px) 1.2rem; overflow: hidden; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-poster { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; padding: 0; cursor: pointer; display: grid; place-items: center; color: #fff; background: #000; }
.video-poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; filter: brightness(0.82); transition: filter 120ms; }
.video-poster:hover img { filter: brightness(0.95); }
.play {
  position: relative; display: grid; place-items: center; width: 96px; height: 96px; background: var(--pink);
  box-shadow: 0 -6px 0 #ffd1e5, 0 6px 0 var(--pink-dark), -6px 0 0 #ffd1e5, 6px 0 0 var(--pink-dark);
  transition: transform 100ms steps(2);
}
.play svg { width: 36px; height: 36px; margin-left: 6px; }
.video-poster:hover .play { transform: scale(1.08); }
.video-caption { position: absolute; left: 1.2rem; bottom: 0.8rem; font-family: var(--display); font-size: 1.4rem; text-transform: uppercase; color: #fff; text-shadow: 0 2px 0 #000; }
.video-alt { font-size: 1rem; margin-bottom: 3.5rem; }

.steam-card {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: stretch;
  background: linear-gradient(135deg, #21174d, #120c2c); margin: var(--px);
  box-shadow: 0 -4px 0 var(--line), 0 4px 0 var(--line), -4px 0 0 var(--line), 4px 0 0 var(--line);
}
.steam-capsule { display: block; line-height: 0; overflow: hidden; }
.steam-capsule img { width: 100%; height: 100%; object-fit: cover; transition: transform 200ms steps(4); }
.steam-capsule:hover img { transform: scale(1.03); }
.steam-info { padding: clamp(1.4rem, 3vw, 2.2rem); display: flex; flex-direction: column; justify-content: center; }
.steam-kicker { font-family: var(--display); font-size: 1.2rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--cyan); margin: 0 0 0.3rem; }
.steam-info h3 { font-size: clamp(2.2rem, 4vw, 2.8rem); }
.steam-info p { color: var(--muted); }
.tags { display: flex; flex-wrap: wrap; gap: 0.45rem; list-style: none; padding: 0; margin: 0 0 1.4rem; }
.tags li { font-family: var(--display); font-size: 1.1rem; line-height: 1; text-transform: uppercase; color: var(--text); background: rgba(236, 230, 255, 0.08); padding: 0.35rem 0.6rem 0.4rem; }
.steam-buy { display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem 1rem; }
.release-pill { font-family: var(--display); font-size: 1.35rem; text-transform: uppercase; color: var(--gold); }
@media (max-width: 860px) { .steam-card { grid-template-columns: 1fr; } }

/* ---------- Studio ---------- */
.studio { display: grid; grid-template-columns: auto 1fr; gap: clamp(2rem, 6vw, 5rem); align-items: center; }
.studio-logo { width: clamp(150px, 22vw, 260px); image-rendering: pixelated; }
.studio p:not(.lead):not(.prompt) { color: var(--muted); max-width: 58ch; }
.stats { display: flex; flex-wrap: wrap; gap: 1rem 1.4rem; margin: 1.8rem 0 0; }
.stat { background: var(--panel); padding: 0.6rem 1rem 0.7rem; margin: var(--px); }
.stat dt { font-family: var(--display); font-size: 1.1rem; line-height: 1; text-transform: uppercase; color: var(--muted); }
.stat dd { margin: 0.2rem 0 0; font-family: var(--display); font-size: 1.6rem; line-height: 1; color: var(--gold); }
@media (max-width: 760px) {
  .studio { grid-template-columns: 1fr; }
  .studio-logo { width: 150px; }
}

/* ---------- Contact ---------- */
.contact { text-align: center; background: radial-gradient(ellipse at 50% 100%, rgba(255, 79, 154, 0.16), transparent 65%); }
.contact .lead { margin-inline: auto; }
.mail { --bc: var(--line); background: var(--panel); padding: 2rem 1.5rem; margin: 2rem auto 0; max-width: 720px; }
.mail-address {
  display: inline-block; font-family: var(--display); font-size: clamp(1.7rem, 5.5vw, 2.8rem); line-height: 1.1; color: var(--gold);
  text-decoration: none; word-break: break-all; margin-bottom: 1.4rem; text-shadow: 0 3px 0 #5a3b00;
}
.mail-address:hover { color: #fff; }
.mail-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.6rem 1rem; }

.community { margin: 3rem auto 0; max-width: 720px; }
.community h3 { font-size: 2.4rem; }
.community p { color: var(--muted); }
.btn-discord { --fill: #5865f2; --fill-hover: #6d78ff; }
.btn-steam { --fill: #5ba32b; --fill-hover: #6cbc35; }
.btn svg[viewBox="0 0 9 7"] { width: 18px; height: 14px; }

/* ---------- Footer ---------- */
.footer { border-top: var(--px) solid var(--bg-2); padding: 1.6rem 0; font-size: 1rem; color: var(--muted); }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }
.footer p { margin: 0; }
.footer-brand { display: flex; align-items: center; gap: 0.6rem; }
.footer-brand img { width: 28px; height: 28px; image-rendering: pixelated; }
.footer ul { display: flex; gap: 1.4rem; list-style: none; margin: 0; padding: 0; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--text); }

@media (max-width: 520px) {
  body { font-size: 1.05rem; }
  .lead { font-size: 1.15rem; }
  .btn { font-size: 1.35rem; padding: 0.65rem 1rem 0.75rem; }
  .play { width: 72px; height: 72px; }
  .brand span { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .marquee-group, .scroll-hint, .prompt::after { animation: none; }
}

/* ---------- 404 ---------- */
.lost { min-height: 100vh; display: grid; place-items: center; text-align: center; padding: 2rem 16px; position: relative; isolation: isolate; }
.lost .scene { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; image-rendering: pixelated; }
.lost h1 { font-size: clamp(6rem, 22vw, 12rem); color: #fff3fa; text-shadow: 0 0.05em 0 var(--pink), 0 0.1em 0 var(--pink-dark); margin-bottom: 1rem; }
.lost .tagline { margin-bottom: 2rem; }
