:root {
  color-scheme: dark;
  --bg: #07071a;
  --panel: rgba(17, 18, 48, 0.76);
  --panel-strong: rgba(28, 31, 78, 0.92);
  --text: #f7f7ff;
  --muted: #b9bbdf;
  --cyan: #45f3ff;
  --pink: #ff4edb;
  --green: #80ff72;
  --yellow: #ffe66d;
  --line: rgba(255, 255, 255, 0.14);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 10%, rgba(255, 78, 219, 0.24), transparent 28rem),
    radial-gradient(circle at 80% 20%, rgba(69, 243, 255, 0.2), transparent 26rem),
    linear-gradient(135deg, #07071a 0%, #111036 52%, #05050f 100%);
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 78%);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.95) 1px, transparent 1.5px),
    radial-gradient(circle, rgba(69, 243, 255, 0.8) 1px, transparent 1.5px);
  background-position: 0 0, 32px 32px;
  background-size: 96px 96px;
  opacity: 0.24;
  animation: starDrift 22s linear infinite;
}

@keyframes starDrift {
  to { transform: translate3d(-96px, 96px, 0); }
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem 1.25rem;
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #06071a;
  background: linear-gradient(135deg, var(--cyan), var(--pink));
  border-radius: 14px;
  box-shadow: 0 0 30px rgba(69, 243, 255, 0.35);
}

.site-nav {
  display: flex;
  gap: 0.5rem;
  padding: 0.45rem;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.site-nav a {
  padding: 0.72rem 1rem;
  color: var(--muted);
  border-radius: 999px;
  transition: 0.25s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.nav-toggle {
  display: none;
  color: var(--text);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.65rem 0.8rem;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) 360px;
  gap: 3rem;
  align-items: center;
  min-height: calc(100vh - 84px);
  max-width: 1180px;
  margin: 0 auto;
  padding: 5rem 1.25rem 6rem;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.planet,
.pixel-cloud,
.ship {
  position: absolute;
  display: block;
}

.planet {
  border-radius: 50%;
  filter: drop-shadow(0 0 30px currentColor);
}

.planet-a {
  top: 14%;
  right: 18%;
  width: 120px;
  height: 120px;
  color: rgba(255, 78, 219, 0.65);
  background: radial-gradient(circle at 35% 30%, #fff, var(--pink) 22%, #6e2cff 68%);
  animation: float 6s ease-in-out infinite;
}

.planet-b {
  bottom: 12%;
  left: 4%;
  width: 72px;
  height: 72px;
  color: rgba(69, 243, 255, 0.65);
  background: radial-gradient(circle at 35% 30%, #fff, var(--cyan) 24%, #1780ff 70%);
  animation: float 7s ease-in-out infinite reverse;
}

.ship {
  top: 28%;
  left: 46%;
  width: 72px;
  height: 32px;
  background: linear-gradient(90deg, transparent 0 14px, var(--yellow) 14px 54px, transparent 54px), linear-gradient(135deg, var(--cyan), var(--pink));
  clip-path: polygon(0 50%, 68% 0, 100% 50%, 68% 100%);
  filter: drop-shadow(0 0 18px rgba(255, 230, 109, 0.8));
  animation: cruise 8s ease-in-out infinite;
}

.pixel-cloud {
  width: 128px;
  height: 34px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 28px 18px 0 rgba(255, 255, 255, 0.08), 68px -12px 0 rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

.cloud-a { top: 22%; left: 8%; animation: float 9s ease-in-out infinite; }
.cloud-b { right: 4%; bottom: 28%; animation: float 8s ease-in-out infinite reverse; }

@keyframes float {
  50% { transform: translateY(-22px); }
}

@keyframes cruise {
  50% { transform: translate(34px, -26px) rotate(8deg); }
}

.hero-content,
.hero-card,
.mini-game,
.page-hero,
.contact-panel,
.section,
.game-grid,
.timeline {
  position: relative;
  z-index: 1;
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--cyan);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 780px;
  margin-bottom: 1.4rem;
  font-size: clamp(3rem, 8vw, 6.8rem);
  line-height: 0.9;
  letter-spacing: -0.08em;
}

h2 {
  font-size: clamp(2rem, 4vw, 3.7rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

h3 {
  font-size: 1.35rem;
}

.hero-copy,
.page-hero p,
.contact-panel p,
.section p {
  max-width: 680px;
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.btn,
.mini-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 1.25rem;
  color: var(--text);
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.mini-btn:hover {
  transform: translateY(-3px) scale(1.02);
}

.btn.primary {
  color: #06071a;
  background: linear-gradient(135deg, var(--cyan), var(--green));
  box-shadow: 0 18px 50px rgba(69, 243, 255, 0.3);
}

.btn.ghost,
.mini-btn {
  background: rgba(255, 255, 255, 0.08);
}

.hero-card,
.mini-game,
.feature-card,
.game-card,
.info-card,
.timeline article,
.contact-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.hero-card {
  padding: 1.25rem;
  border-radius: 34px;
  transform-style: preserve-3d;
}

.mini-game {
  overflow: hidden;
  padding: 1rem;
  border-radius: 34px;
}

.mini-game-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.85rem;
  color: var(--muted);
  font-weight: 800;
}

.mini-game-head strong {
  color: var(--text);
}

.game-stage {
  position: relative;
  height: 330px;
  overflow: hidden;
  cursor: pointer;
  background:
    radial-gradient(circle at 18% 22%, rgba(69, 243, 255, 0.22), transparent 7rem),
    radial-gradient(circle at 80% 78%, rgba(255, 78, 219, 0.2), transparent 8rem),
    linear-gradient(160deg, rgba(10, 13, 43, 0.95), rgba(20, 16, 56, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 26px;
  box-shadow: inset 0 0 50px rgba(69, 243, 255, 0.08);
}

.game-stage.is-paused {
  pointer-events: none;
}

.game-stage.is-paused .game-overlay {
  pointer-events: auto;
}

.game-stage::before {
  position: absolute;
  inset: 0;
  content: "";
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.65) 1px, transparent 1.5px);
  background-size: 34px 34px;
  opacity: 0.22;
}

.runner-player,
.obstacle-lane,
.runner-obstacle,
.runner-goal,
.runner-ground {
  position: absolute;
  display: block;
  pointer-events: none;
}

.runner-stage {
  user-select: none;
}

.runner-player {
  left: 42px;
  bottom: 50px;
  z-index: 3;
  width: 40px;
  height: 46px;
  background:
    radial-gradient(circle at 50% 28%, #fff 0 12%, transparent 13%),
    linear-gradient(135deg, var(--cyan), var(--green));
  border-radius: 14px 14px 10px 10px;
  filter: drop-shadow(0 0 18px rgba(69, 243, 255, 0.9));
  transform: translateY(var(--jump-y, 0));
  transition: transform 0.08s linear;
}

.runner-player::before,
.runner-player::after {
  position: absolute;
  bottom: -9px;
  width: 10px;
  height: 12px;
  content: "";
  background: var(--yellow);
  border-radius: 0 0 999px 999px;
}

.runner-player::before { left: 7px; }
.runner-player::after { right: 7px; }

.obstacle-lane {
  left: 0;
  right: 0;
  bottom: 50px;
  z-index: 2;
  height: 100px;
  animation: obstacleRun var(--obstacle-speed, 2.8s) linear infinite;
}

.runner-obstacle {
  bottom: 0;
  z-index: 2;
  width: var(--obstacle-width, 32px);
  height: var(--obstacle-height, 52px);
  background: linear-gradient(180deg, var(--pink), #752cff);
  border-radius: 10px 10px 6px 6px;
  box-shadow: 0 0 18px rgba(255, 78, 219, 0.7);
}

.runner-obstacle::before {
  position: absolute;
  inset: -12px 8px auto;
  height: 16px;
  content: "";
  background: var(--yellow);
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

.runner-goal {
  right: 20px;
  top: 20px;
  z-index: 2;
  color: var(--yellow);
  font-size: 2rem;
  text-shadow: 0 0 18px rgba(255, 230, 109, 0.9);
  animation: tokenPulse 1.2s ease-in-out infinite;
}

.runner-ground {
  left: 0;
  right: 0;
  bottom: 38px;
  z-index: 1;
  height: 12px;
  background: linear-gradient(90deg, var(--cyan), var(--pink), var(--green));
  box-shadow: 0 0 22px rgba(69, 243, 255, 0.38);
}

.runner-stage.win {
  animation: winFlash 0.5s ease;
}

.game-stage.hit {
  animation: dangerFlash 0.3s ease;
}

.game-overlay {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  background: rgba(5, 6, 20, 0.7);
  backdrop-filter: blur(8px);
}

.game-overlay-card {
  display: grid;
  gap: 0.75rem;
  justify-items: center;
  max-width: 260px;
  padding: 1.25rem 1.1rem;
  text-align: center;
  background: rgba(13, 16, 44, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 22px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.32);
}

.game-overlay-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.game-overlay-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.game-overlay-button {
  min-width: 150px;
}

.game-overlay.is-win .game-overlay-title {
  color: var(--green);
}

.game-overlay.is-fail .game-overlay-title {
  color: var(--pink);
}

.game-overlay.is-idle .game-overlay-title {
  color: var(--cyan);
}

.game-help {
  margin: 0.85rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

@keyframes tokenPulse {
  50% { transform: scale(1.18) rotate(10deg); }
}

@keyframes obstacleRun {
  from { transform: translateX(390px); }
  to { transform: translateX(-460px); }
}

@keyframes dangerFlash {
  50% { box-shadow: inset 0 0 70px rgba(255, 78, 219, 0.38), 0 0 42px rgba(255, 78, 219, 0.3); }
}

@keyframes winFlash {
  50% { box-shadow: inset 0 0 80px rgba(128, 255, 114, 0.34), 0 0 50px rgba(128, 255, 114, 0.28); }
}

.card-top,
.stats {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
}

.avatar-bot {
  position: relative;
  width: 190px;
  height: 150px;
  margin: 2rem auto;
  background: linear-gradient(135deg, #24275e, #111332);
  border: 4px solid rgba(255, 255, 255, 0.12);
  border-radius: 42px 42px 54px 54px;
  box-shadow: inset 0 -20px 30px rgba(0, 0, 0, 0.22), 0 0 60px rgba(255, 78, 219, 0.18);
}

.avatar-bot::before,
.avatar-bot::after {
  position: absolute;
  content: "";
}

.avatar-bot::before {
  top: -28px;
  left: 50%;
  width: 4px;
  height: 28px;
  background: var(--cyan);
  transform: translateX(-50%);
}

.avatar-bot::after {
  top: -40px;
  left: 50%;
  width: 18px;
  height: 18px;
  background: var(--pink);
  border-radius: 50%;
  box-shadow: 0 0 22px var(--pink);
  transform: translateX(-50%);
}

.bot-eye {
  position: absolute;
  top: 56px;
  width: 34px;
  height: 34px;
  background: var(--cyan);
  border-radius: 50%;
  box-shadow: 0 0 20px var(--cyan);
  animation: blink 3s infinite;
}

.bot-eye.left { left: 48px; }
.bot-eye.right { right: 48px; }

@keyframes blink {
  0%, 88%, 100% { transform: scaleY(1); }
  92%, 96% { transform: scaleY(0.12); }
}

.stats span {
  display: grid;
  gap: 0.2rem;
}

.stats b {
  color: var(--text);
  font-size: 1.3rem;
}

.section,
.page-main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 4rem 1.25rem;
}

.section-heading {
  margin-bottom: 2rem;
}

.feature-grid,
.game-grid,
.timeline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.feature-card,
.game-card,
.timeline article,
.info-card {
  position: relative;
  overflow: hidden;
  padding: 1.4rem;
  border-radius: 28px;
}

.feature-card::before,
.game-card::before,
.timeline article::before {
  position: absolute;
  inset: -1px;
  pointer-events: none;
  content: "";
  background: radial-gradient(circle at var(--x, 50%) var(--y, 50%), rgba(69, 243, 255, 0.25), transparent 12rem);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.feature-card:hover::before,
.game-card:hover::before,
.timeline article:hover::before {
  opacity: 1;
}

.icon {
  font-size: 2rem;
}

.feature-card p,
.game-card p,
.timeline p,
.info-card dd {
  color: var(--muted);
  line-height: 1.7;
}

.split {
  display: grid;
  grid-template-columns: 1fr 260px;
  align-items: center;
  gap: 2rem;
}

.energy-core {
  position: relative;
  width: 220px;
  height: 220px;
  margin: auto;
  cursor: pointer;
  background: radial-gradient(circle, var(--cyan) 0 22%, #151847 23% 54%, transparent 55%);
  border: 0;
  border-radius: 50%;
  box-shadow: 0 0 70px rgba(69, 243, 255, 0.45), inset 0 0 40px rgba(255, 255, 255, 0.18);
  animation: pulse 2.8s ease-in-out infinite;
}

.energy-core span,
.energy-core::before,
.energy-core::after {
  position: absolute;
  inset: 22px;
  content: "";
  border: 2px dashed rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  animation: spin 10s linear infinite;
}

.energy-core::after {
  inset: 50px;
  border-color: rgba(255, 78, 219, 0.55);
  animation-direction: reverse;
}

.energy-core.charged {
  box-shadow: 0 0 100px rgba(128, 255, 114, 0.75), 0 0 160px rgba(255, 78, 219, 0.35);
}

@keyframes pulse {
  50% { transform: scale(1.05); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.page-main {
  min-height: calc(100vh - 260px);
}

.page-hero {
  padding: 4rem 0 3rem;
}

.game-card {
  min-height: 440px;
}

.game-art {
  height: 210px;
  margin-bottom: 1.4rem;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.runner {
  background:
    radial-gradient(circle at 70% 20%, var(--yellow), transparent 16%),
    linear-gradient(135deg, rgba(69, 243, 255, 0.8), rgba(11, 19, 55, 0.4)),
    repeating-linear-gradient(120deg, transparent 0 24px, rgba(255, 255, 255, 0.12) 25px 28px);
}

.island {
  background:
    radial-gradient(ellipse at 50% 66%, #7cff9c 0 20%, #7b4cff 21% 28%, transparent 29%),
    radial-gradient(circle at 28% 28%, var(--pink), transparent 18%),
    linear-gradient(145deg, #14225c, #371044);
}

.arena {
  background:
    conic-gradient(from 45deg, rgba(128, 255, 114, 0.4), rgba(69, 243, 255, 0.25), rgba(255, 78, 219, 0.35), rgba(128, 255, 114, 0.4)),
    radial-gradient(circle, #151847, #05050f);
}

.neon-blue { --x: 20%; --y: 18%; }
.neon-pink { --x: 70%; --y: 20%; }
.neon-green { --x: 50%; --y: 80%; }

.timeline article span {
  color: var(--pink);
  font-size: 3rem;
  font-weight: 900;
}

.contact-panel {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 430px);
  gap: 2rem;
  padding: 2rem;
  border-radius: 34px;
}

.info-card {
  background: var(--panel-strong);
}

.info-card dl {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 1rem;
  margin: 0;
}

.info-card dt {
  color: var(--cyan);
  font-weight: 800;
}

.info-card dd {
  margin: 0;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
  max-width: 1180px;
  margin: 3rem auto 0;
  padding: 2rem 1.25rem 3rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.site-footer strong {
  color: var(--text);
}

.site-footer address {
  max-width: 560px;
  margin-left: auto;
  font-style: normal;
  line-height: 1.8;
  text-align: right;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  flex-basis: 100%;
  justify-content: center;
  padding-top: 1rem;
  margin-top: 1rem;
  border-top: 1px solid var(--line);
}

.footer-links a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--cyan);
}

.footer-links span {
  color: var(--line);
}

.cursor-orb {
  position: fixed;
  z-index: 100;
  width: 28px;
  height: 28px;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.9), rgba(69, 243, 255, 0.35), transparent 70%);
  border-radius: 50%;
  mix-blend-mode: screen;
  transform: translate(-50%, -50%);
}

.loot {
  position: fixed;
  z-index: 80;
  pointer-events: none;
  font-size: 1.6rem;
  animation: lootDrop 1.2s ease forwards;
}

@keyframes lootDrop {
  to { transform: translateY(90px) rotate(25deg); opacity: 0; }
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: 0.75s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: absolute;
    top: 76px;
    right: 1.25rem;
    display: none;
    flex-direction: column;
    width: min(260px, calc(100vw - 2.5rem));
    border-radius: 22px;
  }

  .site-nav.open { display: flex; }

  .hero,
  .split,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 3rem;
  }

  .hero-card {
    max-width: 420px;
  }

  .mini-game {
    max-width: 460px;
  }

  .feature-grid,
  .game-grid,
  .timeline {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-direction: column;
  }

  .site-footer address {
    align-self: flex-end;
    text-align: right;
  }

  .footer-links {
    justify-content: flex-start;
    padding-top: 0.75rem;
    margin-top: 0.75rem;
  }
}

@media (max-width: 520px) {
  h1 { font-size: 3.35rem; }

  .hero-actions,
  .btn {
    width: 100%;
  }

  .info-card dl {
    grid-template-columns: 1fr;
  }

  .cursor-orb {
    display: none;
  }
}
