/* =========================
   DREAM ARCADE - CLEAN STABLE CSS
   Replace your whole arcade.css with this file.
========================= */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  font-family: "Courier New", monospace;
  background: #05010a;
  color: white;
}

@media screen and (min-width: 1025px) {
  * {
    cursor: none !important;
  }
}

@media screen and (max-width: 1024px) {
  * {
    cursor: auto !important;
  }

  .custom-cursor {
    display: none !important;
  }
}

button,
a,
.hotspot,
.jungle-zone,
.arrow {
  cursor: pointer;
  font-family: inherit;
}

/* =========================
   CUSTOM CURSOR
========================= */

.custom-cursor {
  position: fixed;
  left: 0;
  top: 0;
  width: 22px;
  height: 28px;
  z-index: 9999999;
  pointer-events: none;
  background: white;
  clip-path: polygon(
    0 0,
    0 100%,
    35% 70%,
    55% 100%,
    75% 90%,
    55% 60%,
    100% 60%
  );
  filter: drop-shadow(0 0 6px rgba(255,255,255,0.75));
}

body:has(.arcade-room) .custom-cursor {
  background: #ff66d9;
  filter: drop-shadow(0 0 8px rgba(255,0,200,0.9));
}

body:has(.jungle-room) .custom-cursor {
  background: #b8ff7a;
  filter: drop-shadow(0 0 8px rgba(184,255,122,0.9));
}

body:has(.rhythm-room) .custom-cursor {
  background: #ffcf7a;
  filter: drop-shadow(0 0 8px rgba(255,180,80,0.9));
}

body:has(.alien-room) .custom-cursor {
  background: #7dff9e;
  filter: drop-shadow(0 0 8px rgba(0,255,120,0.9));
}

body:has(.depth-room) .custom-cursor {
  background: #8fd3ff;
  filter: drop-shadow(0 0 8px rgba(120,190,255,0.9));
}

/* =========================
   SHARED EFFECTS
========================= */

.scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0.05) 0px,
    rgba(255,255,255,0.05) 1px,
    transparent 2px,
    transparent 4px
  );
  pointer-events: none;
  z-index: 20;
  opacity: 0.35;
}

.pixel-noise {
  position: absolute;
  inset: 0;
  z-index: 21;
  pointer-events: none;
  opacity: 0.18;
  background-image:
    repeating-radial-gradient(circle, rgba(255,255,255,0.08) 0 1px, transparent 1px 4px);
  mix-blend-mode: screen;
}

.back-button {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 60;
  color: #b8ff7a;
  text-decoration: none;
  font-size: 0.9rem;
  background: rgba(0,0,0,0.65);
  border: 2px solid #b8ff7a;
  padding: 0.6rem 0.9rem;
  box-shadow: 0 0 15px rgba(184,255,122,0.5);
  transition: 0.25s ease;
}

.back-button:hover {
  background: rgba(184,255,122,0.15);
  box-shadow: 0 0 20px rgba(184,255,122,0.8);
}

/* =========================
   MAIN ARCADE ROOM
========================= */

.arcade-room {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background:
    radial-gradient(circle at center, rgba(255,0,180,0.25), transparent 35%),
    linear-gradient(to top, #110019, #05010a 70%);
}

.arcade-room::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at center, rgba(255,0,200,0.22), transparent 35%),
    radial-gradient(circle at bottom, rgba(0,255,255,0.12), transparent 45%);
  pointer-events: none;
  z-index: 1;
}

.arcade-room::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -5%;
  width: 100%;
  height: 35%;
  background:
    linear-gradient(rgba(255,255,255,0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.07) 1px, transparent 1px);
  background-size: 55px 55px;
  transform: perspective(450px) rotateX(60deg);
  transform-origin: bottom;
  opacity: 0.35;
  z-index: 2;
  pointer-events: none;
}

.grain {
  position: absolute;
  inset: 0;
  background-image:
    repeating-radial-gradient(circle at 10% 20%, rgba(255,255,255,0.04) 0 1px, transparent 1px 3px);
  opacity: 0.22;
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 30;
}

.fog {
  position: absolute;
  width: 70%;
  height: 35%;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  filter: blur(50px);
  pointer-events: none;
  z-index: 3;
}

.fog-one {
  left: -15%;
  bottom: 12%;
  animation: driftOne 12s ease-in-out infinite alternate;
}

.fog-two {
  right: -20%;
  top: 30%;
  animation: driftTwo 15s ease-in-out infinite alternate;
}

.neon-sign {
  position: absolute;
  top: 7%;
  left: 50%;
  transform: translateX(-50%);
  font-size: clamp(2rem, 6vw, 5rem);
  letter-spacing: 4px;
  color: #ff4fd8;
  text-align: center;
  text-shadow:
    0 0 8px #ff4fd8,
    0 0 20px #ff4fd8,
    0 0 45px #7c00ff;
  animation: flicker 3.5s infinite;
  z-index: 10;
}

.hotspot {
  position: absolute;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(0,0,0,0.28);
  color: white;
  border-radius: 22px;
  padding: 0.9rem;
  font-size: 4rem;
  text-decoration: none;
  backdrop-filter: blur(4px);
  box-shadow:
    0 0 18px rgba(255,0,200,0.35),
    inset 0 0 18px rgba(255,255,255,0.06);
  transition: 0.25s ease;
  z-index: 15;
  animation: floatHotspot 3.2s ease-in-out infinite;
}

.hotspot:hover {
  box-shadow:
    0 0 35px rgba(0,255,255,0.75),
    inset 0 0 20px rgba(255,255,255,0.1);
}

.hotspot.arcade-machine {
  left: 38%;
  top: 45%;
  transform: translateX(-50%);
  font-size: 7rem;
  animation-delay: 0s;
}

.hotspot.arcade-machine:hover {
  transform: translateX(-50%) scale(1.08);
}

.hotspot.jungle-poster {
  left: 12%;
  top: 31%;
  animation-delay: 0.5s;
}

.hotspot.jungle-poster:hover {
  transform: scale(1.08) rotate(-2deg);
}

.hotspot.alien {
  left: 58%;
  top: 22%;
  width: 90px;
  height: 90px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 4rem;
  line-height: 1;
  padding: 0;
  z-index: 20;
  animation-delay: 1s;
}

.hotspot.radio {
  left: 18%;
  bottom: 17%;
  width: 90px;
  height: 90px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 4rem;
  line-height: 1;
  padding: 0;
  z-index: 20;
  animation-delay: 1.5s;
}

.hotspot.radio:hover {
  transform: scale(1.08);
}

.hotspot.door {
  left: 65%;
  top: 70%;
  width: 90px;
  height: 120px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 4rem;
  line-height: 1;
  padding: 0;
  z-index: 20;
  animation-delay: 2s;
}

.dialogue-box {
  position: absolute;
  left: 50%;
  bottom: 5%;
  transform: translateX(-50%);
  width: min(90%, 680px);
  padding: 1rem 1.2rem;
  background: rgba(0,0,0,0.78);
  border: 2px solid #ff4fd8;
  border-radius: 18px;
  color: #dffcff;
  text-align: center;
  font-size: 1rem;
  line-height: 1.5;
  box-shadow: 0 0 28px rgba(255,79,216,0.5);
  z-index: 25;
}

/* =========================
   JUNGLE ROOM
========================= */

#loadingScreen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: black;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 1s ease;
}

.loading-content {
  text-align: center;
  color: #b8ff7a;
  font-size: 1rem;
  text-shadow:
    0 0 8px #00ff66,
    0 0 18px #00ff66;
  line-height: 2;
}

.loading-content p {
  animation: loadingBlink 1s infinite;
}

.loading-content p:nth-child(2) {
  animation-delay: 0.2s;
}

.loading-content p:nth-child(3) {
  animation-delay: 0.4s;
}

.jungle-room {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  font-family: "Courier New", monospace;
  color: #b8ff7a;
  background:
    linear-gradient(rgba(0,0,0,0.15), rgba(0,0,0,0.55)),
    url("./img/customjungle.png") no-repeat center center;
  background-size: contain;
}

.jungle-fog {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 70%, rgba(34,255,0,0.18), transparent 35%),
    radial-gradient(circle at 80% 30%, rgba(191,0,255,0.18), transparent 35%);
  filter: blur(6px);
  pointer-events: none;
  z-index: 2;
}

.jungle-title {
  position: absolute;
  top: 7%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  font-size: clamp(1.7rem, 5vw, 4.2rem);
  text-align: center;
  color: #b8ff7a;
  text-shadow:
    0 0 8px #b8ff7a,
    0 0 20px #00ff66,
    3px 3px 0 #220033;
}

.ps-button {
  position: absolute;
  top: 18%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  background: transparent;
  border: none;
  color: #d8ffb8;
  font-size: 1rem;
  letter-spacing: 3px;
  text-shadow:
    0 0 6px #00ff66,
    0 0 15px #00ff66,
    0 0 25px rgba(184,255,122,0.7);
  transition: 0.25s ease;
}

.ps-button:hover {
  transform: translateX(-50%) scale(1.08);
  text-shadow:
    0 0 10px #00ff66,
    0 0 25px #00ff66,
    0 0 40px rgba(184,255,122,1);
}

.ps1-hud {
  position: absolute;
  left: 20px;
  bottom: 194px;
  z-index: 31;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.8rem;
  color: #d8ffb8;
  text-shadow: 0 0 8px #00ff66;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(184,255,122,0.5);
  padding: 0.6rem 0.8rem;
}

.jungle-zone {
  position: absolute;
  z-index: 25;
  border: 2px solid rgba(184,255,122,0.18);
  background: rgba(0,0,0,0.08);
  color: rgba(114,134,77,0.55);
  font-size: 0.9rem;
  font-weight: bold;
  letter-spacing: 2px;
  display: flex;
  justify-content: center;
  align-items: center;
  text-shadow: 0 0 6px rgba(114,134,77,0.6);
  border-radius: 10px;
  transition: 0.2s ease;
}

.jungle-zone:hover {
  transform: scale(1.02);
}

.crt-zone {
  left: 39%;
  top: 34%;
  width: 21%;
  height: 30%;
  animation: crtFlicker 0.12s infinite, crtGlow 3s ease-in-out infinite;
}

.crt-screen {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 8px;
  background: radial-gradient(circle at center, rgba(114,134,77,0.15), black 85%);
  box-shadow: inset 0 0 25px rgba(114,134,77,0.25);
}

.crt-mix-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.88;
  filter: contrast(1.15) saturate(1) brightness(1.1);
  z-index: 1;
}

.crt-static {
  position: absolute;
  inset: 0;
  z-index: 2;
  opacity: 0.08;
  background-image:
    repeating-radial-gradient(circle, rgba(255,255,255,0.08) 0 1px, transparent 1px 4px);
  animation: staticMove 0.25s infinite linear;
}

.crt-content {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #d8ff9e;
  text-align: center;
  padding: 10px;
  text-shadow:
    0 0 10px rgba(216,255,158,0.9),
    0 0 20px rgba(216,255,158,0.45);
}

.crt-now-playing {
  font-size: 0.8rem;
  letter-spacing: 3px;
  color: #f2ffd0;
  margin-bottom: 4px;
}

#crtTrackName {
  font-size: 1.3rem;
  color: white;
  margin: 4px 0;
  text-shadow:
    0 0 16px rgba(255,255,255,0.9),
    0 0 28px rgba(210,255,140,0.45);
}

.crt-status {
  font-size: 0.65rem;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.8);
}

.mix-one {
  left: 18%;
  top: 45%;
  width: 14%;
  height: 18%;
}

.mix-two {
  right: 16%;
  top: 45%;
  width: 14%;
  height: 18%;
}

.boombox-zone {
  left: 39%;
  bottom: 20%;
  width: 22%;
  height: 13%;
  background:
    linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)),
    url("./img/cherry-blossom-mix.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 2px solid rgba(114,134,77,0.25);
  box-shadow: 0 0 15px rgba(114,134,77,0.25);
  overflow: hidden;
  color: transparent;
}

.npc-zone {
  right: 26%;
  bottom: 22%;
  width: 10%;
  height: 18%;
}

.secret-zone {
  left: 5%;
  bottom: 8%;
  width: 10%;
  height: 12%;
}

.equalizer {
  position: absolute;
  right: 30px;
  bottom: 115px;
  z-index: 31;
  display: flex;
  align-items: end;
  gap: 5px;
  height: 45px;
  padding: 8px;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(184,255,122,0.5);
}

.equalizer span {
  width: 8px;
  height: 15px;
  background: #b8ff7a;
  box-shadow: 0 0 10px #00ff66;
  animation: eqMove 0.7s infinite ease-in-out;
}

.equalizer span:nth-child(2) { animation-delay: 0.1s; }
.equalizer span:nth-child(3) { animation-delay: 0.2s; }
.equalizer span:nth-child(4) { animation-delay: 0.3s; }
.equalizer span:nth-child(5) { animation-delay: 0.4s; }

.jungle-dialogue {
  position: absolute;
  left: 50%;
  bottom: 5%;
  transform: translateX(-50%);
  width: min(90%, 720px);
  z-index: 35;
  padding: 1rem 1.2rem;
  background: rgba(0,0,0,0.8);
  border: 2px solid #b8ff7a;
  color: #eaffd5;
  text-align: center;
  font-size: 1rem;
  line-height: 1.5;
  box-shadow: 0 0 25px rgba(184,255,122,0.45);
}

.selected-mix {
  background: rgba(114,134,77,0.35) !important;
  box-shadow:
    0 0 25px rgba(114,134,77,0.9),
    inset 0 0 20px rgba(114,134,77,0.4) !important;
}

.vhs-particles {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  overflow: hidden;
}

.vhs-particles span {
  position: absolute;
  width: 6px;
  height: 6px;
  background: rgba(210,255,140,0.85);
  border-radius: 50%;
  filter: blur(2px);
  box-shadow:
    0 0 12px rgba(210,255,140,0.8),
    0 0 22px rgba(210,255,140,0.45);
  animation:
    floatParticle 9s infinite linear,
    particlePulse 3s infinite ease-in-out;
}

.vhs-particles span:nth-child(1) { left: 10%; top: 80%; animation-delay: 0s; }
.vhs-particles span:nth-child(2) { left: 25%; top: 65%; animation-delay: 1.5s; }
.vhs-particles span:nth-child(3) { left: 40%; top: 90%; animation-delay: 3s; }
.vhs-particles span:nth-child(4) { left: 60%; top: 70%; animation-delay: 0.8s; }
.vhs-particles span:nth-child(5) { left: 75%; top: 85%; animation-delay: 2.2s; }
.vhs-particles span:nth-child(6) { left: 88%; top: 75%; animation-delay: 4s; }
.vhs-particles span:nth-child(7) { left: 50%; top: 78%; animation-delay: 5s; }

/* =========================
   RHYTHM ROOM
========================= */

.rhythm-room {
  position: relative;
  width: 100vw;
  height: 100svh;
  min-height: 100svh;
  overflow: hidden;
  font-family: "Courier New", monospace;
  background:
    linear-gradient(rgba(0,0,0,0.12), rgba(0,0,0,0.32)),
    url("./img/beachlove.png") center center / cover no-repeat;
  color: #fff2c4;
}

.rhythm-title {
  position: absolute;
  top: 7%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  font-size: clamp(2rem, 6vw, 4.5rem);
  letter-spacing: 6px;
  text-align: center;
  color: #fff2c4;
  text-shadow:
    0 0 12px rgba(255,220,120,0.9),
    0 0 25px rgba(255,150,0,0.6);
}

#rhythmJukebox {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(760px, 82vw);
  height: min(620px, 56vh);
  transform: translate(-50%, -50%);
  z-index: 25;
  overflow: visible;
  border-radius: 20px;
}

.music-display {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  border: 3px solid rgba(255,220,120,0.45);
  background: black;
  box-shadow:
    0 0 30px rgba(255,180,80,0.35),
    inset 0 0 18px rgba(255,180,80,0.15);
}

.music-display img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  border-radius: 16px;
  image-rendering: pixelated;
  transition:
    opacity 0.35s ease,
    transform 0.35s ease,
    filter 0.35s ease;
}

.music-display.flash img {
  opacity: 0.25;
  transform: scale(1.03);
  filter: brightness(1.35) saturate(1.3);
}

#rhythmTrack {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  width: 90%;
  z-index: 60;
  font-size: clamp(1rem, 2vw, 2rem);
  letter-spacing: 3px;
  text-align: center;
  color: white;
  text-shadow: 0 0 12px rgba(255,220,120,0.9);
}

.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 2px solid rgba(255,220,120,0.4);
  background: rgba(0,0,0,0.55);
  color: #ffe8b8;
  font-size: 1.8rem;
  z-index: 100;
  display: flex;
  justify-content: center;
  align-items: center;
  text-shadow: 0 0 10px rgba(255,220,120,0.8);
  box-shadow: 0 0 18px rgba(255,180,80,0.25);
}

.left-arrow {
  left: -85px;
}

.right-arrow {
  right: -85px;
}

.rhythm-dialogue {
  position: absolute;
  left: 50%;
  bottom: 7%;
  transform: translateX(-50%);
  width: min(88%, 720px);
  padding: 1rem;
  background: rgba(0,0,0,0.65);
  border: 2px solid rgba(255,220,120,0.4);
  border-radius: 16px;
  color: #fff2c4;
  text-align: center;
  z-index: 45;
  box-shadow: 0 0 22px rgba(255,180,80,0.25);
}

.arcade-info {
  position: absolute;
  left: 24px;
  bottom: 16%;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 45;
  color: #fff0ba;
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-shadow: 0 0 12px rgba(255,220,120,0.8);
}

.arcade-info span {
  background: rgba(0,0,0,0.45);
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255,220,120,0.25);
}

.free-play {
  position: absolute;
  top: 24px;
  right: 28px;
  z-index: 55;
  font-size: 1rem;
  color: #ffcf7a;
  letter-spacing: 3px;
  text-shadow:
    0 0 10px rgba(255,190,90,0.95),
    0 0 22px rgba(255,140,40,0.65),
    0 0 40px rgba(255,120,0,0.35);
  animation: freePlayBlink 1.2s infinite;
  pointer-events: none;
}

.screen-pulse {
  filter: brightness(1.15);
}

.seagulls,
.moving-clouds {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.seagulls {
  z-index: 5;
}

.seagulls span {
  position: absolute;
  color: rgba(255,255,255,0.85);
  font-size: 1.8rem;
  text-shadow: 0 0 10px rgba(255,255,255,0.45);
  animation: flyAcross linear infinite;
}

.seagulls span:nth-child(1) { top: 14%; animation-duration: 18s; }
.seagulls span:nth-child(2) { top: 24%; animation-duration: 24s; animation-delay: 4s; }
.seagulls span:nth-child(3) { top: 18%; animation-duration: 20s; animation-delay: 8s; }

.moving-clouds {
  z-index: 4;
}

.moving-clouds span {
  position: absolute;
  width: 180px;
  height: 55px;
  background: rgba(255,235,190,0.28);
  border-radius: 50%;
  filter: blur(18px);
  animation: cloudDrift 26s linear infinite;
}

.moving-clouds span:nth-child(1) { top: 14%; left: -220px; }
.moving-clouds span:nth-child(2) { top: 28%; left: -320px; animation-delay: 8s; }
.moving-clouds span:nth-child(3) { top: 20%; left: -420px; animation-delay: 15s; }

/* =========================
   DEPTH ROOM
========================= */

.depth-room {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: radial-gradient(circle at center, rgba(40,40,60,0.8), black 80%);
  perspective: 1200px;
  animation: breathingRoom 6s infinite ease-in-out;
}

.depth-background {
  position: absolute;
  inset: 0;
  background: url("./img/depth-bg.png") no-repeat center center/cover;
  opacity: 0.55;
  transform: scale(1.08);
  transition: transform 0.2s ease;
}

.depth-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  transition: transform 0.15s ease;
}

.layer-one {
  background: radial-gradient(circle, rgba(120,180,255,0.12), transparent 60%);
  mix-blend-mode: screen;
}

.layer-two {
  background: linear-gradient(rgba(255,255,255,0.03), transparent);
  opacity: 0.6;
}

.layer-three {
  backdrop-filter: blur(2px);
}

.depth-light {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(180,220,255,0.18), transparent 70%);
  filter: blur(30px);
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.depth-title {
  position: absolute;
  top: 10%;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  font-size: clamp(2rem, 5vw, 5rem);
  letter-spacing: 8px;
  text-shadow: 0 0 20px rgba(180,220,255,0.45);
  z-index: 30;
}

.depth-text {
  position: absolute;
  bottom: 12%;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.8);
  letter-spacing: 3px;
  font-size: 1rem;
  z-index: 30;
}

.depth-floating {
  position: absolute;
  inset: 0;
  z-index: 12;
  pointer-events: none;
}

.depth-floating span {
  position: absolute;
  color: rgba(180,220,255,0.55);
  font-size: 3rem;
  text-shadow: 0 0 20px rgba(180,220,255,0.7);
  animation: floatDepth 8s infinite ease-in-out;
}

.depth-floating span:nth-child(1) { left: 18%; top: 30%; }
.depth-floating span:nth-child(2) { right: 20%; top: 38%; animation-delay: 1.4s; }
.depth-floating span:nth-child(3) { left: 35%; bottom: 22%; animation-delay: 2.6s; }
.depth-floating span:nth-child(4) { right: 35%; bottom: 28%; animation-delay: 3.8s; }

.depth-messages {
  position: absolute;
  left: 30px;
  bottom: 30px;
  z-index: 40;
  color: rgba(255,255,255,0.75);
  font-size: 0.8rem;
  letter-spacing: 2px;
  line-height: 1.8;
  text-shadow: 0 0 12px rgba(180,220,255,0.5);
}

.depth-messages p {
  opacity: 0;
  animation: messageFade 9s infinite;
}

.depth-messages p:nth-child(2) { animation-delay: 3s; }
.depth-messages p:nth-child(3) { animation-delay: 6s; }

.page-transition {
  position: fixed;
  inset: 0;
  background: black;
  z-index: 999999;
  pointer-events: none;
  opacity: 1;
  animation: pageFadeIn 1.1s ease forwards;
}

/* =========================
   ALIEN ROOM
========================= */

.alien-room {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  font-family: "Courier New", monospace;
  background:
    linear-gradient(rgba(0,0,0,0.15), rgba(0,0,0,0.45)),
    url("./img/alien-bg.png") no-repeat center center/contain;
  color: #b8ff7a;
}

.alien-title {
  position: absolute;
  top: 7%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  font-size: clamp(2rem, 5vw, 5rem);
  letter-spacing: 6px;
  color: #b8ff7a;
  text-shadow:
    0 0 10px #00ff66,
    0 0 25px rgba(0,255,120,0.7);
}

.alien-dialogue {
  position: absolute;
  left: 50%;
  bottom: 5%;
  transform: translateX(-50%);
  width: min(90%, 720px);
  padding: 1rem 1.2rem;
  background: rgba(0,0,0,0.75);
  border: 2px solid rgba(184,255,122,0.5);
  color: #eaffd5;
  text-align: center;
  box-shadow: 0 0 25px rgba(0,255,120,0.35);
  z-index: 35;
}

.space-stars {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 5;
}

.space-stars span {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 0 10px white;
  animation: starFloat linear infinite;
}

.space-stars span:nth-child(1) { left: 12%; top: 20%; animation-duration: 8s; }
.space-stars span:nth-child(2) { left: 35%; top: 40%; animation-duration: 12s; }
.space-stars span:nth-child(3) { left: 55%; top: 18%; animation-duration: 10s; }
.space-stars span:nth-child(4) { left: 72%; top: 52%; animation-duration: 14s; }
.space-stars span:nth-child(5) { left: 88%; top: 26%; animation-duration: 9s; }

.alien-radar {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 40;
  padding: 10px 14px;
  background: rgba(0,0,0,0.7);
  border: 1px solid rgba(0,255,120,0.5);
  color: #7dff9e;
  letter-spacing: 2px;
  font-size: 0.8rem;
  text-shadow: 0 0 12px rgba(0,255,120,0.8);
  animation: radarBlink 1.5s infinite;
}

/* =========================
   RESPONSIVE
========================= */

@media screen and (min-width: 769px) and (max-width: 1024px) {
  .hotspot.arcade-machine { left: 12%; top: 50%; }
  .hotspot.alien { left: 58%; top: 24%; }
  .hotspot.radio { left: 14%; top: 72%; bottom: auto; }
  .hotspot.jungle-poster { left: 72%; top: 62%; }
  .hotspot.door { left: 72%; top: 48%; }

  .rhythm-room #rhythmJukebox,
  .rhythm-room .jukebox-screen {
    width: 86vw !important;
    height: 42vh !important;
    top: 42% !important;
  }

  .rhythm-room .left-arrow { left: 8px !important; }
  .rhythm-room .right-arrow { right: 8px !important; }
  .rhythm-room .arrow { width: 62px !important; height: 62px !important; top: 50% !important; }
}

@media screen and (max-width: 768px) {
  .hotspot { font-size: 2.6rem; padding: 0.55rem; }
  .hotspot.arcade-machine { left: 38%; top: 45%; }
  .hotspot.alien { left: 58%; top: 24%; }
  .hotspot.radio { left: 12%; top: 67%; bottom: auto; }
  .hotspot.jungle-poster { left: 72%; top: 64%; }
  .hotspot.door { left: 8%; top: 23%; }

  .back-button {
    top: 45px;
    left: 22px;
    font-size: 0.72rem;
    padding: 0.45rem 0.65rem;
  }

  .dialogue-box,
  .jungle-dialogue,
  .rhythm-dialogue,
  .alien-dialogue {
    width: 88%;
    font-size: 0.85rem;
  }

  .rhythm-title {
    top: 12%;
    font-size: 2rem;
  }

  .rhythm-room #rhythmJukebox,
  .rhythm-room .jukebox-screen {
    position: absolute !important;
    left: 50% !important;
    top: 43% !important;
    width: 92vw !important;
    height: 34vh !important;
    transform: translate(-50%, -50%) !important;
    overflow: visible !important;
  }

  .rhythm-room .arrow {
    top: 50% !important;
    width: 58px !important;
    height: 58px !important;
    font-size: 1.3rem !important;
  }

  .rhythm-room .left-arrow { left: -10px !important; }
  .rhythm-room .right-arrow { right: -10px !important; }

  .rhythm-dialogue {
    bottom: 8%;
  }

  .arcade-info {
    left: 22px;
    bottom: 18%;
    font-size: 0.65rem;
  }

  .free-play {
    top: 105px;
    right: 24px;
    font-size: 0.7rem;
  }

  .jungle-title {
    top: 13%;
    font-size: 1.8rem;
    line-height: 1.25;
  }

  .ps-button {
    top: 27%;
    font-size: 0.82rem;
  }

  .crt-zone {
    left: 31%;
    top: 39%;
    width: 38%;
    height: 18%;
  }

  .mix-one {
    left: 4%;
    top: 40%;
    width: 22%;
    height: 15%;
  }

  .mix-two {
    right: 4%;
    top: 40%;
    width: 22%;
    height: 15%;
  }

  .npc-zone {
    right: 13%;
    bottom: 26%;
    width: 20%;
    height: 16%;
  }

  .boombox-zone {
    left: 26%;
    bottom: 29%;
    width: 36%;
    height: 12%;
  }

  .ps1-hud {
    left: 10px;
    bottom: 143px;
    font-size: 0.62rem;
  }

  .equalizer {
    right: 22px;
    bottom: 93px;
  }

  .jungle-dialogue {
    bottom: 12px;
    width: 93%;
    font-size: 0.8rem;
  }

  .depth-title {
    top: 16%;
    font-size: 2.1rem;
    line-height: 1.35;
  }

  .depth-text {
    bottom: 16%;
    width: 85%;
    font-size: 0.78rem;
    text-align: center;
  }

  .depth-messages {
    left: 30px;
    bottom: 125px;
    font-size: 0.72rem;
  }

  .alien-title {
    top: 13%;
    font-size: 2.2rem;
    line-height: 1.25;
  }

  .alien-radar {
    top: 46px;
    right: 18px;
    font-size: 0.58rem;
  }

  .alien-dialogue {
    bottom: 82px;
    font-size: 0.8rem;
  }
}

/* =========================
   KEYFRAMES
========================= */

@keyframes loadingBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  45% { opacity: 0.85; }
  50% { opacity: 0.35; }
  55% { opacity: 1; }
}

@keyframes driftOne {
  from { transform: translateX(0); }
  to { transform: translateX(120px); }
}

@keyframes driftTwo {
  from { transform: translateX(0); }
  to { transform: translateX(-140px); }
}

@keyframes floatHotspot {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

@keyframes crtFlicker {
  0% { opacity: 0.92; }
  20% { opacity: 1; }
  40% { opacity: 0.88; }
  60% { opacity: 0.95; }
  80% { opacity: 0.9; }
  100% { opacity: 1; }
}

@keyframes crtGlow {
  0%, 100% {
    box-shadow:
      0 0 12px rgba(114,134,77,0.25),
      inset 0 0 15px rgba(114,134,77,0.12);
  }
  50% {
    box-shadow:
      0 0 28px rgba(114,134,77,0.6),
      inset 0 0 25px rgba(114,134,77,0.25);
  }
}

@keyframes staticMove {
  0% { transform: translateY(0px); }
  100% { transform: translateY(-4px); }
}

@keyframes blinkText {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

@keyframes eqMove {
  0%, 100% { height: 10px; }
  50% { height: 42px; }
}

@keyframes floatParticle {
  0% {
    transform: translateY(0) translateX(0);
    opacity: 0;
  }
  15% { opacity: 0.85; }
  100% {
    transform: translateY(-420px) translateX(35px);
    opacity: 0;
  }
}

@keyframes particlePulse {
  0%, 100% {
    box-shadow:
      0 0 8px rgba(210,255,140,0.45),
      0 0 18px rgba(210,255,140,0.25);
  }
  50% {
    box-shadow:
      0 0 16px rgba(210,255,140,1),
      0 0 32px rgba(210,255,140,0.65);
  }
}

@keyframes freePlayBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

@keyframes flyAcross {
  0% {
    transform: translateX(-200px);
    opacity: 0;
  }
  10%, 90% { opacity: 1; }
  100% {
    transform: translateX(120vw);
    opacity: 0;
  }
}

@keyframes cloudDrift {
  from { transform: translateX(0); }
  to { transform: translateX(140vw); }
}

@keyframes breathingRoom {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.12); }
}

@keyframes floatDepth {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-28px) rotate(8deg); }
}

@keyframes messageFade {
  0%, 100% { opacity: 0; }
  20%, 45% { opacity: 1; }
}

@keyframes pageFadeIn {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes starFloat {
  0%, 100% {
    transform: translateY(0);
    opacity: 0.6;
  }
  50% {
    transform: translateY(-12px);
    opacity: 1;
  }
}

@keyframes radarBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.45; }
}

.room-loader {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: black;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 1s ease;
}

.room-loader-content {
  text-align: center;
  font-family: "Courier New", monospace;
  line-height: 2.2;
  letter-spacing: 2px;
  color: white;
  text-shadow: 0 0 12px currentColor;
}

.room-loader-content p {
  animation: loadingBlink 1s infinite;
}

.room-loader-content p:nth-child(2) {
  animation-delay: 0.2s;
}

.room-loader-content p:nth-child(3) {
  animation-delay: 0.4s;
}

.rhythm-loader {
  color: #ffcf7a;
}

.alien-loader {
  color: #7dff9e;
}

.depth-loader {
  color: #8fd3ff;
}

.depth-floating span {
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

/* =========================
   ROOM LOADER COLORS
========================= */

.jungle-loader {
  background:
    radial-gradient(circle, #0d1b0d, #020402);

  color: #9dff7a;
}

.rhythm-loader {
  background:
    radial-gradient(circle, #241204, #050200);

  color: #ffcf7a;
}

.alien-loader {
  background:
    radial-gradient(circle, #061b14, #010504);

  color: #7dffb7;
}

.depth-loader {
  background:
    radial-gradient(circle, #07121f, #010204);

  color: #8fd3ff;
}

.room-loader-content {
  text-shadow:
    0 0 12px currentColor,
    0 0 22px currentColor;
}
/* =========================
   BACK BUTTON BASE
========================= */

.back-button {
  position: absolute;

  top: 20px;
  left: 20px;

  padding: 0.7rem 1rem;

  border-radius: 12px;

  text-decoration: none;

  font-family: "Courier New", monospace;

  letter-spacing: 2px;

  z-index: 200;

  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.back-button:hover {
  transform: scale(1.05);
}

/* JUNGLE */

.jungle-room .back-button {
  background: rgba(20,40,20,0.7);

  border: 2px solid #9dff7a;

  color: #b8ff7a;

  box-shadow:
    0 0 12px rgba(157,255,122,0.5);
}

/* RHYTHM */

.rhythm-room .back-button {
  background: rgba(40,20,0,0.7);

  border: 2px solid #ffcf7a;

  color: #ffe2a8;

  box-shadow:
    0 0 12px rgba(255,207,122,0.5);
}

/* ALIEN */

.alien-room .back-button {
  background: rgba(0,30,20,0.7);

  border: 2px solid #7dffb7;

  color: #aaffdd;

  box-shadow:
    0 0 12px rgba(125,255,183,0.5);
}

/* DEPTH */

.depth-room .back-button {
  background: rgba(10,20,40,0.7);

  border: 2px solid #8fd3ff;

  color: #c7ecff;

  box-shadow:
    0 0 12px rgba(143,211,255,0.5);
}
