:root {
  --bg: #07080f;
  --bg-2: #0c0e1a;
  --panel: rgba(18, 21, 38, 0.72);
  --line: rgba(120, 140, 255, 0.16);
  --text: #e8ebff;
  --muted: #9aa1c7;
  --cyan: #22e3ff;
  --magenta: #ff2bd6;
  --display: "Orbitron", "Segoe UI", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  --maxw: 1160px;
  --gutter: clamp(16px, 4vw, 40px);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 700px at 85% -10%, rgba(255, 43, 214, 0.13), transparent 60%),
    radial-gradient(1000px 700px at 0% 10%, rgba(34, 227, 255, 0.12), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, dl, dd, ul { margin: 0; padding: 0; }
ul { list-style: none; }

:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--cyan); color: #00131a; padding: 10px 14px; border-radius: 6px;
  font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }

#bg { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -2; pointer-events: none; }

.scanlines {
  position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: 0.35;
  background: repeating-linear-gradient(to bottom, transparent 0 3px, rgba(0, 0, 0, 0.22) 3px 4px);
}

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px var(--gutter);
  transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(7, 8, 15, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--display); font-weight: 700; letter-spacing: 0.14em; font-size: 0.95rem;
  text-decoration: none; color: var(--text);
}
.brand b { color: var(--cyan); font-weight: 700; margin-left: 0.3em; }
.brand img { filter: drop-shadow(0 0 8px rgba(34, 227, 255, 0.5)); }

.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a {
  font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.12em; text-transform: uppercase;
  text-decoration: none; color: var(--muted); transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }
.nav-links .nav-cta {
  color: var(--cyan); border: 1px solid rgba(34, 227, 255, 0.45); padding: 8px 14px; border-radius: 6px;
}
.nav-links .nav-cta:hover { background: rgba(34, 227, 255, 0.1); color: var(--cyan); }

.nav-toggle {
  display: none; width: 44px; height: 44px; padding: 11px 9px;
  background: transparent; border: 1px solid var(--line); border-radius: 8px; cursor: pointer;
  flex-direction: column; justify-content: space-between;
}
.nav-toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: transform 0.25s, opacity 0.25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  max-width: var(--maxw); margin: 0 auto;
  padding: 120px var(--gutter) 96px;
}

.eyebrow, .kicker {
  font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--cyan);
}
.eyebrow { display: flex; align-items: center; gap: 10px; margin-bottom: 22px; }
.dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--cyan);
  box-shadow: 0 0 12px var(--cyan); animation: pulse 1.8s ease-in-out infinite;
}

.glitch {
  position: relative;
  font-family: var(--display); font-weight: 900;
  font-size: clamp(2.5rem, 10.5vw, 7.5rem);
  line-height: 0.98; letter-spacing: 0.03em;
  background: linear-gradient(100deg, #fff 10%, var(--cyan) 55%, var(--magenta) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: 0 0 60px rgba(34, 227, 255, 0.25);
}
.glitch::before, .glitch::after {
  content: attr(data-text);
  position: absolute; inset: 0;
  background: none; -webkit-background-clip: border-box; background-clip: border-box;
  text-shadow: none; pointer-events: none; opacity: 0.75;
}
.glitch::before { color: var(--cyan); animation: glitch-a 4.5s infinite steps(1); }
.glitch::after { color: var(--magenta); animation: glitch-b 5.5s infinite steps(1); }

.tagline {
  max-width: 34rem; margin-top: 26px;
  font-size: clamp(1.02rem, 2.2vw, 1.25rem); color: var(--muted);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 12px 24px; border-radius: 8px;
  font-family: var(--mono); font-size: 0.88rem; letter-spacing: 0.08em; text-transform: uppercase;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(100deg, var(--cyan), #7c8cff 60%, var(--magenta));
  color: #05060c; font-weight: 500;
  box-shadow: 0 0 0 rgba(34, 227, 255, 0);
}
.btn-primary:hover { box-shadow: 0 8px 34px rgba(34, 227, 255, 0.35); }
.btn-ghost { background: rgba(255, 255, 255, 0.03); border-color: var(--line); color: var(--text); }
.btn-ghost:hover { border-color: rgba(34, 227, 255, 0.6); background: rgba(34, 227, 255, 0.07); }

.stats {
  display: grid; grid-template-columns: repeat(3, auto); gap: 14px 44px;
  margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line);
}
.stats dt { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.stats dd { font-family: var(--display); font-weight: 700; font-size: 1.15rem; margin-top: 4px; }
.blink { color: var(--cyan); }
.blink::after { content: "_"; animation: caret 1s steps(1) infinite; }

.scroll-cue {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%);
  width: 26px; height: 42px; border: 1px solid var(--line); border-radius: 14px;
}
.scroll-cue span {
  position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px;
  background: var(--cyan); border-radius: 2px; animation: wheel 1.8s ease-in-out infinite;
}

/* ---------- Sections ---------- */
.section { max-width: var(--maxw); margin: 0 auto; padding: clamp(64px, 10vw, 120px) var(--gutter); }
.section-head { margin-bottom: clamp(28px, 5vw, 52px); }
.section h2 {
  font-family: var(--display); font-weight: 700;
  font-size: clamp(1.7rem, 4.6vw, 2.9rem); line-height: 1.12; letter-spacing: 0.02em;
  margin-top: 12px;
}
.lede { color: var(--muted); margin-top: 12px; max-width: 36rem; font-size: 1.05rem; }

/* ---------- Game cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); }

.card {
  --accent: var(--cyan); --accent2: var(--magenta);
  position: relative; display: flex; flex-direction: column;
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  transition: transform 0.3s ease, border-color 0.3s, box-shadow 0.3s;
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
}
.card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--accent2), transparent);
}
.card:hover {
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow: 0 18px 60px -20px color-mix(in srgb, var(--accent) 60%, transparent);
}

.card-art {
  position: relative; aspect-ratio: 16 / 10; display: grid; place-items: center;
  color: var(--accent);
  background:
    radial-gradient(circle at 50% 60%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 62%),
    linear-gradient(color-mix(in srgb, var(--accent) 12%, transparent) 1px, transparent 1px) 0 0 / 100% 22px,
    linear-gradient(90deg, color-mix(in srgb, var(--accent) 12%, transparent) 1px, transparent 1px) 0 0 / 22px 100%,
    #0a0c18;
  border-bottom: 1px solid var(--line);
}
.card-art svg {
  width: 46%; max-width: 150px;
  filter: drop-shadow(0 0 14px color-mix(in srgb, var(--accent) 80%, transparent));
  transition: transform 0.5s ease;
}
.card:hover .card-art svg { transform: scale(1.08) rotate(-3deg); }

.card-body { padding: 22px 22px 26px; display: flex; flex-direction: column; gap: 8px; }
.card-body h3 { font-family: var(--display); font-weight: 700; font-size: 1.22rem; letter-spacing: 0.02em; line-height: 1.25; }
.genre { font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.card-body p:last-child { color: var(--muted); font-size: 0.97rem; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.chip {
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--text);
}
.chip-live { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.chip-live::before {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); margin-right: 7px; vertical-align: 1px; animation: pulse 1.8s ease-in-out infinite;
}

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(24px, 5vw, 64px); align-items: start; }
.about-copy p { font-size: clamp(1.05rem, 2vw, 1.22rem); color: #c9cdea; }
.about-copy p + p { margin-top: 18px; }

.pillars { display: grid; gap: 14px; }
.pillars li {
  position: relative; padding: 18px 20px 18px 66px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
}
.pillar-num {
  position: absolute; left: 18px; top: 18px; width: 34px; height: 34px; display: grid; place-items: center;
  font-family: var(--display); font-weight: 700; color: var(--cyan);
  border: 1px solid rgba(34, 227, 255, 0.4); border-radius: 8px;
}
.pillars h3 { font-family: var(--display); font-size: 1rem; font-weight: 700; letter-spacing: 0.03em; }
.pillars p { color: var(--muted); font-size: 0.95rem; margin-top: 2px; }

/* ---------- Contact ---------- */
.contact {
  position: relative; text-align: center; overflow: hidden;
  padding: clamp(36px, 7vw, 80px) clamp(20px, 5vw, 60px);
  border: 1px solid var(--line); border-radius: 20px;
  background:
    radial-gradient(600px 300px at 50% 0%, rgba(34, 227, 255, 0.14), transparent 70%),
    radial-gradient(600px 300px at 50% 100%, rgba(255, 43, 214, 0.12), transparent 70%),
    var(--panel);
}
.contact .lede { margin-left: auto; margin-right: auto; }
.contact-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 30px; }
.contact-actions .btn-primary { text-transform: none; letter-spacing: 0.02em; font-size: clamp(0.82rem, 3.4vw, 1rem); overflow-wrap: anywhere; }
.copy-status { min-height: 1.4em; margin-top: 14px; font-family: var(--mono); font-size: 0.8rem; color: var(--cyan); }

/* ---------- Footer ---------- */
.footer {
  max-width: var(--maxw); margin: 0 auto; padding: 28px var(--gutter) 40px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px;
  border-top: 1px solid var(--line); color: var(--muted); font-size: 0.85rem;
}

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.js .reveal.in { opacity: 1; transform: none; }
.js .card.reveal.in { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); }
.cards .reveal:nth-child(2), .pillars .reveal:nth-child(2) { transition-delay: 0.1s; }
.cards .reveal:nth-child(3), .pillars .reveal:nth-child(3) { transition-delay: 0.2s; }

/* ---------- Animations ---------- */
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.45; transform: scale(0.8); } }
@keyframes caret { 50% { opacity: 0; } }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 80%, 100% { transform: translateY(16px); opacity: 0; } }
@keyframes glitch-a {
  0%, 91%, 100% { clip-path: inset(0 0 100% 0); transform: none; }
  92% { clip-path: inset(12% 0 62% 0); transform: translate(-5px, -1px); }
  94% { clip-path: inset(58% 0 18% 0); transform: translate(4px, 1px); }
  96% { clip-path: inset(34% 0 44% 0); transform: translate(-3px, 0); }
}
@keyframes glitch-b {
  0%, 88%, 100% { clip-path: inset(0 0 100% 0); transform: none; }
  89% { clip-path: inset(70% 0 8% 0); transform: translate(5px, 1px); }
  91% { clip-path: inset(22% 0 60% 0); transform: translate(-4px, -1px); }
  93% { clip-path: inset(46% 0 30% 0); transform: translate(3px, 0); }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards .card:last-child { grid-column: 1 / -1; }
  .cards .card:last-child .card-art { aspect-ratio: 16 / 6; }
  .cards .card:last-child .card-art svg { width: 22%; }
  .about { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(7, 8, 15, 0.96); border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 18px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 14px 4px; font-size: 0.95rem; border-bottom: 1px solid var(--line); }
  .nav-links .nav-cta { margin-top: 14px; text-align: center; border-bottom: 1px solid rgba(34, 227, 255, 0.45); }
  .nav.menu-open { background: rgba(7, 8, 15, 0.96); }

  .cards { grid-template-columns: 1fr; }
  .cards .card:last-child { grid-column: auto; }
  .cards .card:last-child .card-art { aspect-ratio: 16 / 10; }
  .cards .card:last-child .card-art svg { width: 46%; }

  .hero { padding-top: 104px; }
  .hero-actions .btn, .contact-actions .btn { flex: 1 1 100%; }
  .stats { grid-template-columns: 1fr 1fr; gap: 16px 24px; width: 100%; }
  .scroll-cue { display: none; }
  .footer { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .glitch::before, .glitch::after { display: none; }
  .js .reveal { opacity: 1; transform: none; }
}
