:root {
  color-scheme: dark;
  --ink: #080417;
  --paper: #fffdf3;
  --muted: #c5bdd7;
  --lime: #baff3c;
  --gold: #ffc52e;
  --cyan: #15ddff;
  --pink: #f000ff;
  --line: rgba(255, 255, 255, .16);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  min-height: 100svh;
  margin: 0;
  overflow-x: hidden;
  background: var(--ink);
  color: var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; }
img { display: block; max-width: 100%; }
.skip-link { position: fixed; top: -5rem; left: 1rem; z-index: 100; padding: .7rem 1rem; border-radius: 999px; background: var(--paper); color: var(--ink); }
.skip-link:focus { top: 1rem; }

.backdrop { position: fixed; inset: 0; z-index: -3; overflow: hidden; }
.backdrop img { width: 100%; height: 100%; object-fit: cover; object-position: center; transform: scale(1.04); animation: drift 14s ease-in-out infinite alternate; }
.backdrop-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(5,2,18,.97) 0%, rgba(7,3,21,.88) 35%, rgba(6,3,22,.28) 68%, rgba(5,2,18,.62) 100%), linear-gradient(0deg, rgba(5,2,18,.94), transparent 42%); }
.noise { position: fixed; inset: 0; z-index: -2; pointer-events: none; opacity: .12; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E"); }

header {
  position: relative;
  z-index: 10;
  width: min(calc(100% - 2rem), 1280px);
  margin: 0 auto;
  padding: 1.2rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: .7rem; font-weight: 950; letter-spacing: -.045em; }
.brand img { width: 46px; height: 46px; border: 1px solid rgba(255,255,255,.22); border-radius: .85rem; object-fit: cover; box-shadow: 0 0 28px rgba(20,221,255,.18); }
.twitch-link { display: flex; align-items: center; gap: .55rem; padding: .7rem 1rem; border: 1px solid var(--line); border-radius: 999px; background: rgba(8,4,23,.55); backdrop-filter: blur(18px); font-size: .88rem; font-weight: 850; }
.pulse { width: .6rem; height: .6rem; border-radius: 50%; background: #746c85; box-shadow: 0 0 0 5px rgba(116,108,133,.16); }

main {
  width: min(calc(100% - 2rem), 1280px);
  min-height: calc(100svh - 146px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(420px, .95fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 6rem);
  padding: 2rem 0 3rem;
}
.teaser-copy { max-width: 720px; }
.eyebrow, .micro { margin: 0 0 1rem; color: var(--lime); font-size: .76rem; font-weight: 950; letter-spacing: .2em; }
h1 { margin: 0; font-size: clamp(4.8rem, 8.6vw, 8.7rem); line-height: .78; letter-spacing: -.085em; text-transform: uppercase; text-shadow: 0 18px 60px rgba(0,0,0,.55); }
h1 span { color: transparent; -webkit-text-stroke: 2px var(--paper); text-shadow: 0 0 35px rgba(20,221,255,.16); }
.intro { max-width: 520px; margin: 1.5rem 0 0; color: var(--muted); font-size: clamp(1rem, 1.5vw, 1.18rem); line-height: 1.6; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.button { min-height: 3.15rem; display: inline-flex; align-items: center; justify-content: center; padding: .8rem 1.2rem; border-radius: .9rem; border: 0; cursor: pointer; font-weight: 900; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.button:hover { transform: translateY(-3px); }
.button-main { background: linear-gradient(135deg, var(--lime), var(--gold)); color: #180e22; box-shadow: 0 15px 42px rgba(186,255,60,.22); }
.button-quiet { border: 1px solid var(--line); background: rgba(255,255,255,.07); backdrop-filter: blur(12px); }
.domain { margin-top: 2.7rem; color: #978da9; font-size: .76rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.domain span { margin: 0 .45rem; color: var(--pink); }

.game-card { padding: 1rem; border: 1px solid rgba(255,255,255,.19); border-radius: 1.65rem; background: linear-gradient(145deg, rgba(21,11,48,.88), rgba(7,3,22,.79)); box-shadow: 0 30px 90px rgba(0,0,0,.46), 0 0 80px rgba(127,54,255,.13); backdrop-filter: blur(24px) saturate(140%); transform: rotate(1deg); transition: transform .4s cubic-bezier(.2,.8,.2,1), box-shadow .4s ease; }
.game-card.focused { transform: rotate(0) scale(1.02); box-shadow: 0 35px 100px rgba(0,0,0,.48), 0 0 90px rgba(20,221,255,.24); }
.game-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .35rem .4rem 1rem; }
.game-head .micro { margin-bottom: .25rem; font-size: .65rem; }
h2 { margin: 0; font-size: clamp(1.45rem, 2.3vw, 2rem); letter-spacing: -.05em; }
.timer { min-width: 68px; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: .8rem; text-align: center; background: rgba(255,255,255,.055); }
.timer span, .score-badge span { display: block; color: var(--muted); font-size: .62rem; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.timer strong { display: block; font-size: 1.3rem; }
.arena { position: relative; min-height: 420px; overflow: hidden; border: 1px solid rgba(20,221,255,.2); border-radius: 1.15rem; background: radial-gradient(circle at 50% 92%, rgba(186,255,60,.22), transparent 38%), radial-gradient(circle at 85% 15%, rgba(240,0,255,.22), transparent 32%), #0d0823; cursor: crosshair; }
.grid { position: absolute; inset: 0; opacity: .24; background-image: linear-gradient(rgba(20,221,255,.15) 1px, transparent 1px), linear-gradient(90deg, rgba(20,221,255,.15) 1px, transparent 1px); background-size: 38px 38px; mask-image: linear-gradient(to bottom, black, transparent 85%); }
.score-badge { position: absolute; z-index: 2; top: .8rem; left: .8rem; min-width: 68px; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: .75rem; background: rgba(8,4,23,.68); text-align: center; backdrop-filter: blur(10px); }
.score-badge strong { display: block; color: var(--lime); font-size: 1.35rem; }
.monsta { position: absolute; width: min(295px, 72%); left: 50%; bottom: -62px; transform: translateX(-50%); border-radius: 50%; filter: drop-shadow(0 25px 48px rgba(0,0,0,.5)); transition: transform .13s ease; }
.monsta.chomp { transform: translateX(-50%) scale(1.09) rotate(-2deg); }
.fruit { position: absolute; z-index: 4; width: 4rem; height: 4rem; padding: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.96); box-shadow: 0 0 0 8px rgba(186,255,60,.12), 0 12px 30px rgba(0,0,0,.38); font-size: 2rem; cursor: pointer; animation: fruit-in .16s ease-out; }
.fruit:hover { transform: scale(1.08); }
.fruit:focus-visible { outline: 3px solid var(--cyan); outline-offset: 4px; }
.game-message { position: absolute; z-index: 3; left: 50%; bottom: .8rem; width: max-content; max-width: calc(100% - 1.6rem); margin: 0; padding: .5rem .75rem; transform: translateX(-50%); border: 1px solid var(--line); border-radius: 999px; background: rgba(8,4,23,.76); color: #ded7e9; font-size: .75rem; font-weight: 800; text-align: center; backdrop-filter: blur(12px); }
.game-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem .35rem .2rem; }
.best { color: var(--muted); font-size: .8rem; font-weight: 800; }
.best strong { margin-left: .35rem; color: var(--paper); font-size: 1.15rem; }
.play-button { min-height: 2.8rem; padding: .7rem 1rem; border: 0; border-radius: .8rem; background: var(--paper); color: var(--ink); cursor: pointer; font-weight: 950; }
.play-button:disabled { opacity: .65; cursor: default; }

footer { width: min(calc(100% - 2rem), 1280px); margin: 0 auto; padding: 1rem 0 1.4rem; display: flex; justify-content: space-between; gap: 1rem; color: #81778f; font-size: .75rem; }
footer a:hover { color: var(--lime); }

@keyframes drift { to { transform: scale(1.09) translate3d(-1%, -.5%, 0); } }
@keyframes fruit-in { from { opacity: 0; transform: scale(.35) rotate(-20deg); } }

@media (max-width: 920px) {
  body { overflow-y: auto; }
  .backdrop img { object-position: 64% center; }
  .backdrop-shade { background: linear-gradient(180deg, rgba(5,2,18,.25), rgba(5,2,18,.9) 43%, rgba(5,2,18,.98)); }
  main { grid-template-columns: 1fr; min-height: auto; padding-top: 4rem; }
  .teaser-copy { padding-top: 3rem; }
  h1 { font-size: clamp(4.4rem, 15vw, 7.5rem); }
  .game-card { width: min(100%, 650px); margin: 0 auto 2rem; transform: none; }
}

@media (max-width: 560px) {
  header { padding-top: .75rem; }
  .brand img { width: 40px; height: 40px; }
  .brand span { font-size: .88rem; }
  .twitch-link { padding: .62rem .78rem; font-size: .78rem; }
  main { width: min(calc(100% - 1rem), 1280px); gap: 2.5rem; padding-top: 1.5rem; }
  .teaser-copy { padding: 1.5rem .5rem 0; }
  h1 { font-size: clamp(3.6rem, 18.5vw, 5.2rem); }
  h1 span { -webkit-text-stroke-width: 1px; }
  .intro { font-size: 1rem; }
  .actions { display: grid; }
  .domain { margin-top: 1.8rem; }
  .game-card { padding: .7rem; border-radius: 1.25rem; }
  .arena { min-height: 390px; }
  .monsta { width: 255px; }
  .game-message { border-radius: .65rem; }
  footer { flex-direction: column; align-items: center; padding-top: 1.5rem; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
