:root {
  --bg: #050403;
  --bg-soft: #0c0907;
  --orange: #ff8a00;
  --orange-bright: #ffb000;
  --gold: #ffd33d;
  --cream: #fff1b8;
  --text: #fff8e8;
  --muted: #d7c6ad;
  --border: rgba(255, 154, 0, .42);
  --shadow: 0 22px 70px rgba(0,0,0,.55);
  --font-body: "Pixelify Sans", "Trebuchet MS", monospace;
  --font-pixel: "Press Start 2P", "Pixelify Sans", monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 0, rgba(130, 55, 0, .18), transparent 36rem),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.45;
  overflow-x: hidden;
}

a { color: inherit; }
img { display: block; max-width: 100%; }

.hero {
  min-height: 100svh;
  position: relative;
  display: grid;
  place-items: center;
  isolation: isolate;
  background-image: url("assets/hero.jpg");
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero__shade {
  position: absolute;
  inset: 0;
  z-index: -3;
  background:
    linear-gradient(180deg, rgba(0,0,0,.18) 0%, rgba(0,0,0,.18) 38%, rgba(0,0,0,.68) 80%, #050403 100%),
    radial-gradient(circle at 50% 50%, transparent 28%, rgba(0,0,0,.22) 68%, rgba(0,0,0,.66) 100%);
}

.hero__glow {
  position: absolute;
  z-index: -2;
  width: 26rem;
  aspect-ratio: 1;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .2;
  pointer-events: none;
}
.hero__glow--left { left: -10rem; bottom: 10%; background: #ff7600; }
.hero__glow--right { right: -10rem; top: 6%; background: #ffba00; }

.hero__content {
  width: min(1050px, 92vw);
  text-align: center;
  padding: 6rem 1rem 5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero__logo {
  width: min(940px, 88vw);
  filter: drop-shadow(0 18px 34px rgba(0,0,0,.75));
}

.hero__subtitle {
  margin: 1.25rem 0 1.8rem;
  font-size: clamp(1.2rem, 2.2vw, 1.7rem);
  letter-spacing: .05em;
  color: #fff5db;
  text-shadow: 0 3px 13px #000;
}

.download-button {
  display: inline-block;
  width: min(650px, 86vw);
  transform-origin: center;
  filter: drop-shadow(0 18px 28px rgba(0,0,0,.6));
  transition: transform .16s ease, filter .16s ease;
}
.download-button:hover {
  transform: translateY(-4px) scale(1.02);
  filter: drop-shadow(0 22px 35px rgba(255, 120, 0, .25)) drop-shadow(0 18px 28px rgba(0,0,0,.65));
}
.download-button:active { transform: translateY(1px) scale(.985); }
.download-button:focus-visible { outline: 3px solid var(--gold); outline-offset: 8px; border-radius: 10px; }

.hero__hint {
  margin: .95rem 0 0;
  font-size: 1rem;
  color: rgba(255,255,255,.78);
  text-shadow: 0 2px 8px #000;
}

.scroll-cue {
  position: absolute;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  text-decoration: none;
  font-size: 2.2rem;
  color: var(--gold);
  animation: bob 1.8s ease-in-out infinite;
  text-shadow: 0 0 12px rgba(255, 140, 0, .5);
}

.section-inner { width: min(1180px, 92vw); margin: 0 auto; }

.features {
  padding: 5.5rem 0 5rem;
  background: linear-gradient(180deg, #050403 0%, #0c0704 100%);
}
.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.feature {
  position: relative;
  min-height: 330px;
  padding: 2rem 1.6rem 1.8rem;
  border: 1px solid rgba(255,145,0,.2);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(73, 31, 4, .56), rgba(16, 9, 4, .82)),
    radial-gradient(circle at 50% 0, rgba(255, 140, 0, .16), transparent 55%);
  box-shadow: inset 0 1px rgba(255,255,255,.03), var(--shadow);
  text-align: center;
  overflow: hidden;
}
.feature::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 196, 49, .09);
  pointer-events: none;
}
.feature img {
  height: 150px;
  width: 150px;
  object-fit: contain;
  margin: 0 auto .6rem;
  filter: drop-shadow(0 12px 22px rgba(0,0,0,.52));
}
.feature h2 {
  margin: .5rem 0 .8rem;
  font-family: var(--font-pixel);
  font-size: clamp(.95rem, 1.2vw, 1.15rem);
  line-height: 1.45;
  color: #ffd86a;
}
.feature p {
  margin: 0 auto;
  max-width: 30ch;
  color: #e4d4be;
  font-size: 1.15rem;
  line-height: 1.5;
}

.instruction {
  padding: 4rem 0 6rem;
  background:
    radial-gradient(circle at 50% 25%, rgba(255, 117, 0, .10), transparent 28rem),
    #0c0704;
}

.instruction__panel {
  position: relative;
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: clamp(2.8rem, 4.8vw, 4.8rem) clamp(2.1rem, 4vw, 3.2rem) clamp(3rem, 5vw, 4.4rem);
  border-radius: 26px;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 28px 80px rgba(0,0,0,.6);
}
.instruction__panel::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background: url("assets/panel.png") center / 100% 100% no-repeat;
}
.instruction__panel::after {
  content: "";
  position: absolute;
  inset: 26px;
  z-index: -1;
  border-radius: 18px;
  background: rgba(7,7,7,.44);
  backdrop-filter: blur(2px);
}

.instruction__header {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  margin-bottom: 2.2rem;
}
.instruction__header img {
  width: 110px;
  height: 110px;
  object-fit: contain;
  flex: 0 0 auto;
}
.eyebrow {
  display: block;
  color: #ffb426;
  text-transform: uppercase;
  letter-spacing: .16em;
  font-family: var(--font-pixel);
  font-size: clamp(.6rem, .7vw, .72rem);
  margin-bottom: .7rem;
}
.instruction h2 {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: clamp(1.2rem, 2.4vw, 2.2rem);
  line-height: 1.35;
  color: #fff0c7;
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 1rem;
}
.steps li {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 1.15rem;
  padding: .95rem 1rem;
  border-radius: 16px;
  background: rgba(0,0,0,.28);
  border: 1px solid rgba(255, 150, 0, .18);
  box-shadow: inset 0 1px rgba(255,255,255,.02);
}
.steps li > span {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(180deg, #ffd13c, #ff7800);
  color: #2b0e00;
  font-family: var(--font-pixel);
  font-size: .95rem;
  line-height: 1;
  box-shadow: inset 0 2px rgba(255,255,255,.4), 0 5px 14px rgba(0,0,0,.4);
}
.steps p {
  margin: 0;
  line-height: 1.45;
  color: #eadfce;
  font-size: clamp(1.1rem, 1.7vw, 1.45rem);
}
.steps strong { color: #fff1bf; font-weight: 700; }

.instruction__download {
  display: block;
  width: min(650px, 84vw);
  margin: 2.35rem auto 0;
  filter: drop-shadow(0 18px 28px rgba(0,0,0,.55));
  transition: transform .16s ease, filter .16s ease;
}
.instruction__download:hover {
  transform: translateY(-4px) scale(1.02);
  filter: drop-shadow(0 22px 35px rgba(255, 120, 0, .25)) drop-shadow(0 18px 28px rgba(0,0,0,.65));
}
.instruction__download:active { transform: translateY(1px) scale(.985); }
.instruction__download:focus-visible { outline: 3px solid var(--gold); outline-offset: 8px; border-radius: 10px; }
.instruction__download img {
  width: 100%;
  height: auto;
}

.good-game {
  margin: 2.2rem 0 1rem;
  padding-bottom: .4rem;
  text-align: center;
  color: #ffd063;
  font-family: var(--font-pixel);
  font-size: clamp(1.1rem, 2vw, 1.7rem);
  line-height: 1.4;
  letter-spacing: .04em;
}

.final-banner {
  position: relative;
  background: #050403;
  padding: 0 0 1.2rem;
}
.final-banner img { width: 100%; height: auto; }
.final-banner__overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 35px 45px #050403;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@keyframes bob {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 7px); }
}

@media (max-width: 850px) {
  .hero { min-height: 88svh; }
  .hero__content { padding-top: 4rem; }
  .features__grid { grid-template-columns: 1fr; }
  .feature { min-height: 0; }
  .instruction__panel {
    padding: 2.5rem 1.75rem 3rem;
  }
  .instruction__panel::after { inset: 18px; }
  .instruction__header { align-items: flex-start; }
  .instruction__header img { width: 82px; height: 82px; }
  .steps li { grid-template-columns: 50px 1fr; }
  .steps li > span { width: 50px; height: 50px; font-size: .8rem; }
}

@media (max-width: 560px) {
  .hero { background-position: 58% center; }
  .hero__subtitle { max-width: 24ch; }
  .hero__hint { font-size: .92rem; }
  .features { padding-top: 4rem; }
  .feature img { width: 120px; height: 120px; }
  .feature p { font-size: 1.05rem; }
  .instruction { padding: 2rem 0 4rem; }
  .instruction__panel {
    padding: 2rem 1.2rem 2.6rem;
  }
  .instruction__panel::after { inset: 14px; }
  .instruction__header { gap: .85rem; }
  .instruction__header img { width: 64px; height: 64px; }
  .eyebrow {
    line-height: 1.5;
    margin-bottom: .6rem;
  }
  .instruction h2 {
    font-size: clamp(1rem, 6vw, 1.35rem);
    line-height: 1.5;
  }
  .steps li {
    grid-template-columns: 42px 1fr;
    gap: .7rem;
    padding: .72rem;
  }
  .steps li > span {
    width: 42px;
    height: 42px;
    font-size: .65rem;
    border-radius: 8px;
  }
  .steps p {
    font-size: 1rem;
    line-height: 1.4;
  }
  .instruction__download {
    width: min(100%, 560px);
    margin-top: 1.8rem;
  }
  .good-game {
    margin-top: 1.5rem;
    font-size: clamp(.95rem, 5vw, 1.15rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .scroll-cue { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .download-button, .instruction__download { transition: none; }
}
