/* ══════════════════════════════════════════════════════════════
   VIROPOP — product page
   nkprod design tokens + the game's own palette. Self-contained:
   no dependency on style.css, no JavaScript.
   ══════════════════════════════════════════════════════════════ */

:root {
  color-scheme: dark;

  /* surfaces — site ink + the game's navy field */
  --ink:    #07070a;
  --navy:   #0e1220;
  --navy-2: #131a2c;
  --line:   rgba(255,255,255,.09);
  --line-2: rgba(255,255,255,.16);

  /* type */
  --paper: #f1efea;
  --dim:   rgba(241,239,234,.64);
  --mute:  rgba(241,239,234,.4);

  /* antidote families — same hexes as the game config */
  --cy: #46bfee;  --cy-d: #2c88af;
  --yl: #fdff00;  --yl-d: #a8a800;
  --or: #db851c;  --or-d: #8a5411;
  --pk: #ea82e5;  --pk-d: #9b4f97;
  --rd: #e03a2f;
  --cy-rgb: 70,191,238;

  --display: "Bricolage Grotesque", "Inter", system-ui, sans-serif;
  --pixel:   "Silkscreen", "JetBrains Mono", ui-monospace, monospace;
  --serif:   "Instrument Serif", Georgia, serif;
  --body:    "Inter", system-ui, -apple-system, sans-serif;
  --mono:    "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --gutter: clamp(20px, 5vw, 80px);
  --max:    1240px;
  --ease:   cubic-bezier(.22,1,.36,1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 1.5rem; overflow-x: clip; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; }
p { margin: 0; }

::selection { background: rgba(var(--cy-rgb), .35); color: #fff; }
:focus-visible { outline: 2px solid var(--cy); outline-offset: 4px; border-radius: 3px; }

.skip {
  position: absolute; left: 1rem; top: -6rem; z-index: 100;
  background: var(--navy-2); color: var(--paper);
  padding: .6rem 1rem; border-radius: 8px;
}
.skip:focus { top: 1rem; }

/* pixel sprites read crisply at any size */
.px { display: inline-block; flex: 0 0 auto; }
.px svg { display: block; width: 100%; height: 100%; shape-rendering: crispEdges; }
.f-cy { --vc: var(--cy); --vd: var(--cy-d); }
.f-yl { --vc: var(--yl); --vd: var(--yl-d); }
.f-or { --vc: var(--or); --vd: var(--or-d); }
.f-pk { --vc: var(--pk); --vd: var(--pk-d); }
.f-rd { --vc: var(--rd); --vd: #96251d; }

/* ═══ ambient ════════════════════════════════════════════════ */

.field-glow {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 44% at 72% 18%, rgba(var(--cy-rgb), .16), transparent 65%),
    radial-gradient(ellipse 44% 36% at 12% 78%, rgba(234,130,229,.07), transparent 70%);
}
.field-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 75%);
}

/* ═══ chrome ═════════════════════════════════════════════════ */

.site-top {
  position: relative; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  max-width: var(--max);
  margin: 0 auto;
  padding: 20px var(--gutter);
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--display); font-weight: 800;
  font-size: 1.15rem; letter-spacing: -.04em;
}
.brand:hover { color: var(--cy); }
.brand small {
  font-family: var(--mono); font-weight: 400; font-size: .62rem;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--mute);
  border-left: 1px solid var(--line-2);
  padding-left: 12px;
}
.top-links { display: flex; align-items: center; gap: 1.4rem; font-size: .86rem; }
.top-links a { color: var(--dim); }
.top-links a:hover { color: var(--paper); }
.languages { display: flex; gap: .9rem; font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; }
.languages a { color: var(--mute); text-transform: uppercase; }
.languages a:hover { color: var(--paper); }
.languages [aria-current] { color: var(--cy); }

/* ═══ hero ═══════════════════════════════════════════════════ */

.hero {
  position: relative; z-index: 1;
  overflow-x: clip;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(28px, 6vh, 72px) var(--gutter) clamp(48px, 8vh, 96px);
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: clamp(40px, 6vw, 90px);
  align-items: center;
  min-height: min(88svh, 980px);
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono);
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--mute);
}
.eyebrow i {
  width: 6px; height: 6px;
  background: var(--cy);
  box-shadow: 0 0 10px rgba(var(--cy-rgb), .9);
}

.wordmark {
  margin: 22px 0 10px;
  font-family: var(--pixel);
  font-weight: 700;
  font-size: clamp(3.1rem, 8.6vw, 7.6rem);
  line-height: .94;
  letter-spacing: -.02em;
  color: var(--cy);
  text-shadow:
    .045em .045em 0 #9b4df0,
    .09em .09em 0 rgba(0,0,0,.55);
}

.tagline {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.5rem, 3vw, 2.3rem);
  letter-spacing: -.01em;
  color: var(--paper);
}

.lead {
  margin-top: 18px;
  max-width: 46ch;
  font-size: clamp(.98rem, 1.3vw, 1.12rem);
  color: var(--dim);
}
.lead b { color: var(--paper); font-weight: 600; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.btn {
  position: relative;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 26px;
  border-radius: 999px;
  font-size: .92rem; font-weight: 500;
  overflow: hidden;
  transition: transform .4s var(--ease), border-color .3s, color .3s;
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.btn-solid { background: var(--cy); color: #07131c; font-weight: 600; }
.btn-solid:hover { background: #7cd4f5; }
.btn-ghost { border: 1px solid var(--line-2); color: var(--dim); }
.btn-ghost:hover { border-color: var(--cy); color: var(--paper); }

.status-line {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px;
  margin-top: 26px;
}
.pill {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 14px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  font-family: var(--mono); font-size: .68rem;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--dim);
}
.pill i {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--yl);
  box-shadow: 0 0 10px rgba(253,255,0,.8);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: .35; } }
.status-note { font-family: var(--mono); font-size: .68rem; letter-spacing: .08em; color: var(--mute); }

.hero-meta {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 34px;
}
.hero-meta li {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--mono); font-size: .62rem;
  letter-spacing: .07em;
  color: var(--dim);
}

/* — hero stage: phone + stray viruses — */
.stage {
  position: relative;
  display: flex; justify-content: center;
  min-height: 480px;
}
.stage::before {
  content: "";
  position: absolute; inset: -12% -18%;
  background: radial-gradient(ellipse at 50% 55%, rgba(var(--cy-rgb), .28), transparent 68%);
  filter: blur(40px);
  z-index: -1;
}
.stray {
  position: absolute; z-index: 3;
  animation: drift 7s ease-in-out infinite;
}
.stray.s1 { width: 44px; left: 2%;  top: 6%;   animation-delay: -1.2s; }
.stray.s2 { width: 58px; right: 0%; top: 22%;  animation-delay: -3.4s; animation-duration: 8.5s; }
.stray.s3 { width: 36px; left: 6%;  bottom: 18%; animation-delay: -5.1s; animation-duration: 6.2s; }
.stray.s4 { width: 30px; right: 8%; bottom: 6%; animation-delay: -2.6s; animation-duration: 9.4s; }
@keyframes drift {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50%      { transform: translateY(-14px) rotate(5deg); }
}

.phone {
  position: relative; z-index: 2;
  width: clamp(210px, 21vw, 300px);
  aspect-ratio: 1242 / 2688;
  border-radius: 13% / 6%;
  padding: 2.6%;
  background: linear-gradient(150deg, #6c6f7a 0%, #23252c 26%, #3d4048 52%, #1b1d22 78%, #5c5f69 100%);
  box-shadow:
    0 30px 70px -22px rgba(0,0,0,.92),
    0 0 0 1px rgba(0,0,0,.6);
  transform: rotate(3deg);
}
.phone-screen {
  position: relative; height: 100%;
  border-radius: 11% / 5.2%;
  overflow: hidden;
  background: var(--navy);
}
.phone-screen img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.phone-island {
  position: absolute; left: 50%; top: 1.6%;
  transform: translateX(-50%);
  width: 31%; height: 3.1%;
  border-radius: 999px;
  background: #05060a;
  z-index: 3;
}

/* pure-CSS crossfade: each shot holds a third of the 9s loop.
   The incoming image fades in over the outgoing one; the wrap-around
   is hidden under the last image's own fade-out. */
.shots img { opacity: 0; animation: shotCycle 9s ease-in-out infinite; }
.shots img:nth-of-type(1) { animation-delay: 0s; }
.shots img:nth-of-type(2) { animation-delay: 3s; }
.shots img:nth-of-type(3) { animation-delay: 6s; }
@keyframes shotCycle {
  0%   { opacity: 0; }
  6%   { opacity: 1; }
  33%  { opacity: 1; }
  39%  { opacity: 0; }
  100% { opacity: 0; }
}

/* ═══ spec marquee ═══════════════════════════════════════════ */

.specbar {
  position: relative; z-index: 1;
  border-block: 1px solid var(--line);
  overflow: hidden;
  padding: 14px 0;
  background: rgba(14,18,32,.5);
}
.spec-track {
  display: flex; width: max-content;
  animation: spec 26s linear infinite;
}
.spec-track span {
  display: flex; align-items: center; gap: 26px;
  padding-right: 26px;
  font-family: var(--pixel); font-size: .72rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--mute);
  white-space: nowrap;
}
.spec-track b { color: var(--cy); font-weight: 400; }
@keyframes spec { to { transform: translateX(-50%); } }

/* ═══ sections ═══════════════════════════════════════════════ */

section.block {
  position: relative; z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(60px, 10vh, 120px) var(--gutter) 0;
}
.sec-head { max-width: 640px; margin-bottom: clamp(28px, 4vw, 48px); }
.sec-num { font-family: var(--mono); font-size: .7rem; letter-spacing: .2em; color: var(--cy); }
.sec-title {
  margin-top: 12px;
  font-family: var(--display); font-weight: 800;
  font-size: clamp(2.1rem, 5vw, 3.8rem);
  line-height: .98; letter-spacing: -.04em;
}
.sec-title em {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  color: var(--cy);
}
.sec-note { margin-top: 16px; color: var(--dim); max-width: 52ch; }

/* — steps — */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.step {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(170deg, var(--navy-2), var(--navy));
  padding: 22px;
  overflow: hidden;
}
.step::after {
  content: attr(data-n);
  position: absolute; right: 14px; top: 10px;
  font-family: var(--pixel); font-size: 2rem;
  color: rgba(255,255,255,.05);
}
.step-icon { width: 44px; height: 44px; margin-bottom: 16px; }
.step h3 { font-family: var(--display); font-size: 1.06rem; letter-spacing: -.02em; margin-bottom: 8px; }
.step p { font-size: .86rem; color: var(--dim); }
.step p b { color: var(--paper); font-weight: 600; }

/* — score cards — */
.score-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}
.score-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(170deg, var(--navy-2), var(--navy));
  padding: 22px;
}
.score-card:nth-child(1), .score-card:nth-child(2) { grid-column: span 3; }
.score-card:nth-child(3), .score-card:nth-child(4), .score-card:nth-child(5) { grid-column: span 2; }
.score-big {
  font-family: var(--pixel);
  font-size: clamp(1.5rem, 2.6vw, 2.2rem);
  color: var(--cy);
  margin-bottom: 10px;
}
.score-big em { font-style: normal; color: var(--yl); }
.score-big small { font-size: .5em; color: var(--mute); }
.score-card h3 { font-family: var(--display); font-size: 1.02rem; letter-spacing: -.02em; margin-bottom: 6px; }
.score-card p { font-size: .86rem; color: var(--dim); }
.score-card .px { width: 40px; height: 40px; margin-bottom: 12px; }

/* — screenshots — */
.shots-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 3vw, 34px);
}
.shot {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--navy);
  overflow: hidden;
  transition: transform .5s var(--ease), border-color .3s;
}
.shot:hover { transform: translateY(-6px); border-color: rgba(var(--cy-rgb), .5); }
.shot img { width: 100%; height: auto; }
.shot figcaption {
  padding: 14px 18px;
  border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: .68rem;
  letter-spacing: .06em; color: var(--dim);
}
.shot figcaption b { color: var(--cy); font-weight: 500; }

/* — craft grid — */
.craft-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.craft {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
  background: linear-gradient(170deg, var(--navy-2), var(--navy));
}
.craft h3 {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--display); font-size: 1.02rem;
  letter-spacing: -.02em; margin-bottom: 8px;
}
.craft h3 .k {
  font-family: var(--mono); font-size: .62rem;
  color: var(--cy); letter-spacing: .1em;
  border: 1px solid rgba(var(--cy-rgb), .4);
  border-radius: 6px; padding: 3px 7px;
}
.craft p { font-size: .86rem; color: var(--dim); }

/* — privacy band — */
.privacy {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr);
  gap: clamp(24px, 4vw, 60px);
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: clamp(26px, 4vw, 44px);
  background:
    radial-gradient(ellipse 80% 120% at 100% 0%, rgba(var(--cy-rgb), .1), transparent 60%),
    linear-gradient(170deg, var(--navy-2), var(--navy));
}
.privacy h2 { font-family: var(--display); font-size: clamp(1.5rem, 3vw, 2.2rem); letter-spacing: -.03em; margin-bottom: 12px; }
.privacy p { color: var(--dim); font-size: .95rem; max-width: 52ch; }
.privacy-links { display: flex; flex-direction: column; gap: 10px; }
.privacy-links a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  padding: 14px 18px;
  font-family: var(--mono); font-size: .74rem;
  letter-spacing: .08em;
  color: var(--paper);
  transition: border-color .3s, gap .3s var(--ease);
}
.privacy-links a:hover { border-color: var(--cy); gap: 18px; }
.privacy-links a svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.8; flex: 0 0 auto; }

/* — status / availability — */
.status {
  display: flex; align-items: center; gap: clamp(24px, 4vw, 48px);
  border: 1px solid rgba(var(--cy-rgb), .35);
  border-radius: 26px;
  padding: clamp(28px, 5vw, 52px);
  background:
    radial-gradient(ellipse 90% 140% at 0% 50%, rgba(var(--cy-rgb), .14), transparent 60%),
    linear-gradient(170deg, var(--navy-2), var(--navy));
  margin-bottom: clamp(60px, 10vh, 120px);
}
.status-icon {
  width: clamp(84px, 10vw, 128px);
  height: auto;
  border-radius: 24%;
  box-shadow: 0 18px 40px -14px rgba(0,0,0,.8), 0 0 0 1px rgba(255,255,255,.1);
  flex: 0 0 auto;
}
.status h2 { font-family: var(--display); font-size: clamp(1.6rem, 3.4vw, 2.6rem); letter-spacing: -.035em; }
.status h2 em { font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--cy); }
.status p { margin-top: 10px; color: var(--dim); max-width: 56ch; }
.status .pill { margin-top: 18px; }
.status-mail {
  display: inline-block; margin-top: 16px;
  font-family: var(--mono); font-size: .76rem; letter-spacing: .06em;
  color: var(--paper); border-bottom: 1px solid var(--line-2); padding-bottom: 3px;
}
.status-mail:hover { color: var(--cy); border-color: var(--cy); }

/* ═══ footer ═════════════════════════════════════════════════ */

.site-foot {
  position: relative; z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: 26px var(--gutter) 34px;
  border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between;
  gap: 12px 28px;
  color: var(--mute);
  font-size: .82rem;
}
.site-foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-foot a { color: var(--dim); }
.site-foot a:hover { color: var(--cy); }

/* ═══ responsive ═════════════════════════════════════════════ */

@media (max-width: 1020px) {
  .hero { grid-template-columns: minmax(0, 1fr); min-height: 0; gap: 56px; }
  .stage { min-height: 0; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .score-grid { grid-template-columns: repeat(2, 1fr); }
  .score-card { grid-column: auto !important; }
  .craft-grid { grid-template-columns: repeat(2, 1fr); }
  .privacy { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .brand small { display: none; }
  .top-links { gap: 1rem; }
  .top-links .back { display: none; }
  .steps, .craft-grid, .score-grid, .shots-row { grid-template-columns: 1fr; }
  .shots-row { max-width: 340px; margin-inline: auto; }
  .status { flex-direction: column; align-items: flex-start; }
  .wordmark { font-size: clamp(1.75rem, 9.5vw, 4.6rem); }
}

/* ═══ reduced motion ═════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .shots img { animation: none; }
  .shots img:first-of-type { opacity: 1; }
  .stray, .pill i { animation: none; }
  .spec-track { animation: none; flex-wrap: wrap; width: auto; }
  .spec-track span.dupe { display: none; }
  .btn:hover, .shot:hover { transform: none; }
}
