* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
}

body {
  width: 100vw;
  height: 100vh;
  background: #050409;
  font-family: 'Orbitron', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
}

#game-container {
  position: relative;
  width: 1200px;
  height: 600px;
  background: #000;
  border: 4px solid #00f2ff;
  border-radius: 12px;
  box-shadow: 0 0 35px rgba(0, 242, 255, 0.3), inset 0 0 20px rgba(255, 0, 255, 0.2);
  overflow: hidden;
}

#game-canvas {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #070714 0%, #0d0a21 50%, #170a2b 100%);
}

/* HUD System overlaying the canvas */
#hud {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 15px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 100%);
  z-index: 10;
}

.hud-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hud-item .label {
  font-size: 11px;
  letter-spacing: 2px;
  color: #8f8ba8;
}

.hud-item span:not(.label) {
  font-size: 20px;
  font-weight: bold;
  text-shadow: 0 0 8px rgba(0, 255, 255, 0.8);
  font-variant-numeric: tabular-nums;
  color: #00ffff;
}

.hud-item .highlight {
  color: #ff00ff !important;
  text-shadow: 0 0 8px rgba(255, 0, 255, 0.8) !important;
}

#shield-status,
#jump-status {
  transition: all 0.3s ease;
}

#shield-status.active {
  color: #39ff14 !important;
  text-shadow: 0 0 10px rgba(57, 255, 20, 0.8) !important;
}

#jump-status.active {
  color: #ff4dff !important;
  text-shadow: 0 0 10px rgba(255, 77, 255, 0.9) !important;
}

/* Alerts like Active Shield */
#alert-banner {
  position: absolute;
  top: 75px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: rgba(255, 0, 255, 0.2);
  border: 2px solid #ff00ff;
  border-radius: 4px;
  padding: 8px 24px;
  font-size: 14px;
  font-weight: bold;
  color: #fff;
  text-shadow: 0 0 8px #ff00ff;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
  z-index: 10;
}

#alert-banner.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* Screens / Overlays (Title and Game Over) */
.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(8, 6, 18, 0.9);
  backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 20;
  transition: opacity 0.4s ease;
}

.overlay-content {
  text-align: center;
  max-width: 650px;
  padding: 40px;
  border-radius: 12px;
  background: rgba(18, 14, 38, 0.8);
  border: 1px dashed rgba(0, 255, 255, 0.3);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.6);
}

.logo-text {
  font-size: 42px;
  letter-spacing: 4px;
  margin-bottom: 8px;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 0 15px rgba(0, 255, 255, 0.6);
}

.accent-color {
  color: #ff00ff;
  text-shadow: 0 0 15px rgba(255, 0, 255, 0.6);
}

.subtitle {
  font-size: 14px;
  color: #a29db8;
  margin-bottom: 30px;
}

.instructions {
  background: rgba(0, 0, 0, 0.4);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 30px;
  border: 1px solid rgba(255, 0, 255, 0.1);
}

.key-hint {
  font-size: 16px;
  color: #00f2ff;
  margin-bottom: 15px;
}

.key {
  background: #251e4a;
  border-bottom: 3px solid #ff00ff;
  border-radius: 4px;
  padding: 2px 10px;
  font-weight: bold;
}

.collect-items {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.badge {
  font-size: 11px;
  font-weight: bold;
  padding: 6px 12px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.05);
}

.coin-item {
  color: #ffd700;
  border: 1px solid rgba(255, 215, 0, 0.2);
}

.shield-item {
  color: #00ff66;
  border: 1px solid rgba(0, 255, 102, 0.2);
}

.jump-item {
  color: #ff4dff;
  border: 1px solid rgba(255, 77, 255, 0.25);
}

.obstacle-item {
  color: #ff3333;
  border: 1px solid rgba(255, 51, 51, 0.2);
}

.flying-item {
  color: #ff9d2e;
  border: 1px solid rgba(255, 157, 46, 0.3);
}

#start-btn {
  font-family: 'Orbitron', sans-serif;
  font-weight: bold;
  background: linear-gradient(90deg, #ff00ff, #00ffff);
  color: #000;
  border: none;
  font-size: 18px;
  letter-spacing: 2px;
  padding: 16px 40px;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 242, 255, 0.4);
  transition: all 0.2s ease-in-out;
}

#start-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(255, 0, 255, 0.6);
  filter: brightness(1.2);
}

#start-btn:active {
  transform: translateY(1px);
}

.hidden {
  display: none !important;
  opacity: 0;
  pointer-events: none;
}
