:root {
  --void: #050814;
  --space: #0b1024;
  --space2: #131a3a;
  --panel: rgba(255,255,255,.075);
  --panel2: rgba(255,255,255,.105);
  --line: rgba(108, 231, 255, .20);
  --line2: rgba(255, 215, 115, .24);
  --text: #eef7ff;
  --muted: #a9b7cf;
  --cyan: #6ce7ff;
  --blue: #7a8cff;
  --violet: #9a5cff;
  --pink: #ff5fd2;
  --gold: #ffd873;
  --gold2: #ffae39;
  --green: #79ffc2;
  --red: #ff7373;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  background:
    radial-gradient(circle at 50% 8%, rgba(108,231,255,.16), transparent 26%),
    radial-gradient(circle at 14% 16%, rgba(154,92,255,.22), transparent 20%),
    radial-gradient(circle at 86% 18%, rgba(255,95,210,.14), transparent 22%),
    radial-gradient(circle at 17% 86%, rgba(255,216,115,.10), transparent 24%),
    radial-gradient(circle at 82% 84%, rgba(122,140,255,.14), transparent 22%),
    linear-gradient(135deg, #050814 0%, #101735 45%, #070a18 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(circle, rgba(255,255,255,.55) 1px, transparent 1px),
    radial-gradient(circle, rgba(108,231,255,.42) 1px, transparent 1px);
  background-size: 90px 90px, 140px 140px;
  background-position: 0 0, 35px 42px;
  opacity: .20;
}

.nebula {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.nebula span {
  position: absolute;
  border-radius: 999px;
  filter: blur(26px);
  opacity: .42;
  animation: drift 12s ease-in-out infinite;
}

.n1 { width: 320px; height: 320px; left: -110px; top: 12%; background: #7a5cff; }
.n2 { width: 360px; height: 360px; right: -130px; bottom: 8%; background: #00d8ff; animation-delay: 2s; }
.n3 { width: 250px; height: 250px; left: 42%; bottom: -90px; background: #ff5fd2; animation-delay: 4s; }
.n4 { width: 180px; height: 180px; right: 26%; top: 10%; background: #ffd873; opacity: .24; animation-delay: 1s; }

.main-game {
  position: relative;
  z-index: 2;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  min-height: calc(100vh - 96px);
  display: grid;
  place-items: center;
  padding: 28px 0 14px;
}

.game-card {
  width: 100%;
  border-radius: 40px;
  padding: clamp(18px, 3vw, 34px);
  background: linear-gradient(180deg, rgba(255,255,255,.095), rgba(255,255,255,.045));
  border: 1px solid rgba(108,231,255,.16);
  box-shadow:
    0 40px 130px rgba(0,0,0,.44),
    0 0 90px rgba(108,231,255,.08),
    inset 0 0 0 1px rgba(255,255,255,.035);
  backdrop-filter: blur(15px);
}

.game-layout {
  display: grid;
  grid-template-columns: minmax(570px, 1fr) 350px;
  gap: clamp(22px, 3vw, 36px);
  align-items: stretch;
}

.play-area {
  display: grid;
  gap: 20px;
}

.scene {
  min-height: 330px;
  border-radius: 34px;
  background:
    radial-gradient(circle at 50% 43%, rgba(108,231,255,.20), transparent 28%),
    radial-gradient(circle at 50% 92%, rgba(255,216,115,.09), transparent 24%),
    linear-gradient(180deg, rgba(0,0,0,.24), rgba(0,0,0,.16));
  border: 1px solid rgba(255,255,255,.09);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  box-shadow: inset 0 0 70px rgba(0,0,0,.25);
}

.scene::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background:
    conic-gradient(from 40deg, rgba(108,231,255,.0), rgba(108,231,255,.30), rgba(154,92,255,.12), rgba(255,216,115,.20), rgba(108,231,255,.0));
  animation: rotateSlow 18s linear infinite;
  opacity: .60;
}

.scene::after {
  content: "";
  position: absolute;
  inset: 34px;
  border-radius: 30px;
  border: 1px dashed rgba(108,231,255,.18);
  opacity: .65;
}

.core {
  position: relative;
  z-index: 2;
  width: min(260px, 62%);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 35% 30%, #ffffff, var(--cyan) 20%, rgba(122,140,255,.60) 48%, rgba(10,13,28,.82) 72%);
  border: 5px solid rgba(108,231,255,.45);
  box-shadow:
    0 0 50px rgba(108,231,255,.28),
    0 0 100px rgba(154,92,255,.20),
    inset 0 0 60px rgba(255,255,255,.28);
  animation: corePulse 2.8s ease-in-out infinite;
}

.core.activated {
  background:
    radial-gradient(circle at 35% 30%, #ffffff, var(--gold) 22%, rgba(255,174,57,.80) 48%, rgba(108,231,255,.55) 72%);
  border-color: rgba(255,216,115,.75);
  box-shadow:
    0 0 70px rgba(255,216,115,.45),
    0 0 130px rgba(108,231,255,.24),
    inset 0 0 70px rgba(255,255,255,.34);
}

.core-symbol {
  font-size: 104px;
  line-height: 1;
  filter: drop-shadow(0 0 24px rgba(255,255,255,.45));
}

.orbit {
  position: absolute;
  inset: -24px;
  border: 1px solid rgba(108,231,255,.32);
  border-radius: 50%;
  animation: rotateSlow 8s linear infinite;
}

.orbit::before, .orbit::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 18px rgba(255,216,115,.65);
}

.orbit::before { left: 24px; top: 28px; }
.orbit::after { right: 20px; bottom: 35px; background: var(--cyan); }

.room-head {
  padding: 18px 20px;
  border-radius: 28px;
  background: rgba(0,0,0,.22);
  border: 1px solid rgba(255,255,255,.09);
}

.room-head h1 {
  margin: 0 0 8px;
  color: var(--cyan);
  font-size: clamp(32px, 4.6vw, 58px);
  line-height: 1.02;
  letter-spacing: -.9px;
}

.room-head p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.5;
}

.door-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.door-card {
  min-height: 275px;
  cursor: pointer;
  border-radius: 30px;
  padding: 20px;
  color: var(--text);
  background:
    radial-gradient(circle at 50% 0%, rgba(108,231,255,.13), transparent 35%),
    linear-gradient(180deg, rgba(255,255,255,.09), rgba(255,255,255,.045));
  border: 1px solid rgba(255,255,255,.11);
  box-shadow: 0 22px 60px rgba(0,0,0,.28);
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
  display: grid;
  grid-template-rows: auto auto 1fr;
  gap: 12px;
}

.door-card:hover {
  transform: translateY(-6px);
  border-color: rgba(108,231,255,.54);
}

.door-card.revealed {
  cursor: default;
  pointer-events: none;
}

.door-card.selected {
  border-color: rgba(255,216,115,.68);
}

.door-icon {
  font-size: clamp(68px, 7vw, 104px);
  line-height: 1;
  text-align: center;
  filter: drop-shadow(0 14px 18px rgba(0,0,0,.30));
}

.door-card h2 {
  margin: 0;
  text-align: center;
  font-size: 22px;
  color: var(--text);
}

.door-card p {
  margin: 0;
  color: var(--muted);
  text-align: center;
  line-height: 1.42;
  font-size: 15px;
}

.relics {
  min-height: 112px;
  border-radius: 28px;
  padding: 16px;
  background: rgba(0,0,0,.20);
  border: 1px dashed rgba(108,231,255,.24);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.relics-title {
  width: 100%;
  text-align: center;
  color: var(--muted);
  font-weight: 900;
  font-size: 13px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.relic {
  min-width: 68px;
  height: 68px;
  padding: 0 10px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-size: 36px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 12px 28px rgba(0,0,0,.22);
  animation: popIn .22s ease;
}

.side-panel {
  min-height: 100%;
  border-radius: 32px;
  padding: 22px;
  background: rgba(0,0,0,.24);
  border: 1px solid rgba(255,255,255,.11);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 15px;
}

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.stat {
  padding: 14px 12px;
  border-radius: 20px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.10);
  text-align: center;
  color: var(--muted);
  font-weight: 900;
  font-size: 13px;
}

.stat strong {
  display: block;
  margin-top: 6px;
  color: var(--text);
  font-size: 25px;
}

.message {
  min-height: 205px;
  display: grid;
  align-content: center;
  text-align: center;
  line-height: 1.48;
  font-size: 18px;
}

.message strong { color: var(--cyan); }
.message .small { display: block; margin-top: 9px; color: var(--muted); font-size: 13px; }
.good { color: var(--green); font-weight: 950; }
.bad { color: var(--red); font-weight: 950; }
.gold { color: var(--gold); font-weight: 950; }
.heat { color: #ff9b73; font-weight: 950; }

.actions { display: grid; gap: 11px; }

.btn, button {
  border: none;
  cursor: pointer;
  border-radius: 999px;
  padding: 15px 24px;
  font-size: 17px;
  font-weight: 950;
  color: #07101a;
  background: linear-gradient(135deg, var(--cyan), #78ffcf);
  text-decoration: none;
  text-align: center;
  box-shadow: 0 16px 36px rgba(108,231,255,.18);
  transition: transform .16s ease, opacity .16s ease;
}

.btn:hover, button:hover { transform: translateY(-2px); }

.btn.secondary, button.secondary {
  background: rgba(255,255,255,.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: none;
}

.activate-nova {
  padding: 20px 30px;
  font-size: 24px;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: #160f05;
  background: linear-gradient(135deg, #fff3b0, var(--gold) 46%, var(--gold2));
  box-shadow:
    0 24px 58px rgba(255,216,115,.24),
    inset 0 0 0 1px rgba(255,255,255,.22);
}

.bottom-brand {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  text-align: center;
  color: var(--cyan);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 950;
  letter-spacing: .4px;
  text-shadow: 0 14px 38px rgba(0,0,0,.34);
}

.footer {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 34px;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.footer a {
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
  font-weight: 900;
}

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

.content-wrap {
  position: relative;
  z-index: 2;
  width: min(900px, calc(100% - 32px));
  margin: 34px auto 60px;
}

.content-card {
  padding: 34px;
  border-radius: 32px;
  background: linear-gradient(180deg, rgba(255,255,255,.095), rgba(255,255,255,.045));
  border: 1px solid rgba(108,231,255,.16);
  box-shadow: 0 24px 80px rgba(0,0,0,.28);
  color: var(--muted);
  line-height: 1.72;
  backdrop-filter: blur(12px);
}

.content-card h1, .content-card h2 { color: var(--text); }
.content-card h1 { margin-top: 0; font-size: clamp(32px, 4vw, 48px); }
.content-card a { color: var(--cyan); font-weight: 900; }

@keyframes popIn { from { transform: scale(.5); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes drift { 0%,100% { transform: translate(0,0); } 50% { transform: translate(40px,-18px); } }
@keyframes rotateSlow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes corePulse { 0%,100% { transform: scale(.98); } 50% { transform: scale(1.04); } }

@media (max-width: 1040px) {
  .game-layout { grid-template-columns: 1fr; }
  .side-panel { min-height: auto; }
}

@media (max-width: 760px) {
  .door-grid { grid-template-columns: 1fr; }
  .door-card { min-height: 225px; }
  .door-icon { font-size: 86px; }
  .scene { min-height: 270px; }
  .core-symbol { font-size: 84px; }
}