/* Radar Fighters 2 — PixiJS Edition */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  font-family: 'Russo One', 'Press Start 2P', monospace;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

canvas {
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  touch-action: none;
}

/* ── Loading screen ──────────────────────────────────────── */
#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  color: #fff;
}

#game-logo {
  width: clamp(280px, 55vw, 700px);
  height: auto;
  margin-bottom: 28px;
  filter: drop-shadow(0 0 18px #ff2244) drop-shadow(0 0 36px #cc0020);
  animation: logoGlow 2s ease-in-out infinite alternate;
}

@keyframes logoGlow {
  from { filter: drop-shadow(0 0 14px #ff2244) drop-shadow(0 0 28px #cc0020); }
  to   { filter: drop-shadow(0 0 28px #ff4466) drop-shadow(0 0 56px #ff2244) drop-shadow(0 0 80px #880010); }
}

#loading-screen h1 {
  font-family: 'Russo One', 'Press Start 2P', monospace;
  font-size: clamp(18px, 4vw, 48px);
  color: #ff2244;
  text-shadow: 0 0 20px #ff2244, 0 0 40px #cc0020, 0 0 60px #880010;
  margin-bottom: 24px;
  letter-spacing: 6px;
  text-transform: uppercase;
}

#loading-bar-outer {
  width: 300px;
  height: 20px;
  border: 2px solid #ff2244;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 16px;
  box-shadow: 0 0 8px #cc0020, 0 0 16px #880010;
}

#loading-bar {
  height: 100%;
  background: linear-gradient(90deg, #880010, #cc0020, #ff2244, #ff4400);
  width: 0%;
  transition: width 0.3s ease;
  box-shadow: 0 0 10px #ff2244;
}

#loading-text {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: #cc4444;
}

/* ── Volume slider overlay ───────────────────────────────── */
#volume-control {
  position: fixed;
  top: 14px;
  right: 200px; /* sit to the left of the PixiJS UI buttons */
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(0,0,0,0.5);
  border: 1.5px solid rgba(255,255,255,0.2);
  border-radius: 10px;
  padding: 6px 10px;
  opacity: 0.75;
  transition: opacity 0.2s;
}
#volume-control:hover { opacity: 1; }

#volume-icon {
  font-size: 14px;
  cursor: pointer;
  user-select: none;
  min-width: 18px;
  text-align: center;
}

#volume-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 72px;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, #4488ff 0%, #4488ff var(--vol, 70%), #334 var(--vol, 70%));
  outline: none;
  cursor: pointer;
}
#volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: #4488ff;
  box-shadow: 0 0 4px #4488ff;
  cursor: pointer;
}
#volume-slider::-moz-range-thumb {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: #4488ff;
  border: none;
  cursor: pointer;
}
