/* Invaders – Seiten-Styles (nur auf /invaders/ geladen) */

.howto {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 4px;
}
.howto-item {
  background: var(--panel-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 0.85rem;
  color: var(--text-dim);
}

/* --- Spielbühne (Vollbild) --- */
#invadersStage {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 60;
  background: #05040c;
  overflow: hidden;
}
body.playing #invadersStage {
  display: block;
}
body.playing {
  overflow: hidden;
}
/* Vollbild: auch auf Desktop komplette Website-Kopfzeile ausblenden */
body.playing .site-header,
body.playing .site-footer {
  display: none !important;
}
body.playing main.container {
  max-width: none;
  padding: 0;
}

#neonCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

/* --- HUD --- */
.hud {
  position: absolute;
  top: 10px;
  left: 12px;
  right: 12px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  z-index: 3;
  pointer-events: none;
  font-family: "Segoe UI", system-ui, sans-serif;
}
.hud-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.hud-lbl {
  font-size: 0.62rem;
  letter-spacing: 1.5px;
  color: #7ee8fa;
  opacity: 0.85;
}
.hud-val {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 0 10px rgba(126, 232, 250, 0.7);
  font-variant-numeric: tabular-nums;
}
.hud.rapid #hudScore {
  color: #ff5d5d;
  text-shadow: 0 0 10px rgba(255, 93, 93, 0.8);
}
.hud.shielded #hudShield {
  color: #7edfff;
  animation: shieldPulse 0.7s infinite alternate;
}
@keyframes shieldPulse {
  from { text-shadow: 0 0 6px rgba(93, 185, 255, 0.6); }
  to   { text-shadow: 0 0 16px rgba(93, 185, 255, 1); }
}

.shield-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 6;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid rgba(93, 185, 255, 0.7);
  background: rgba(13, 11, 28, 0.7);
  color: #7edfff;
  font-size: 1.5rem;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}
@media (pointer: coarse) {
  .shield-btn { display: flex; }
}
.shield-btn:active {
  background: rgba(93, 185, 255, 0.25);
}

.shield-hint {
  position: absolute;
  top: 34%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 6;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(13, 11, 28, 0.85);
  border: 1px solid rgba(93, 185, 255, 0.5);
  color: #7edfff;
  font-size: 0.9rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s;
}
.shield-hint.show {
  opacity: 1;
}

/* --- Overlay (Start / Pause / Game over) --- */
.ovl {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 4, 12, 0.72);
  backdrop-filter: blur(4px);
  z-index: 5;
}
.ovl-box {
  text-align: center;
  padding: 28px 30px;
  border: 1px solid rgba(126, 232, 250, 0.35);
  border-radius: 16px;
  background: rgba(13, 11, 28, 0.86);
  box-shadow: 0 0 60px rgba(126, 232, 250, 0.18), inset 0 0 40px rgba(126, 232, 250, 0.05);
  max-width: min(92vw, 460px);
  margin: 12px;
}
.ovl-title {
  font-size: 1.9rem;
  font-weight: 900;
  letter-spacing: 2px;
  color: #fff;
  text-shadow: 0 0 18px rgba(126, 232, 250, 0.9);
}
.ovl-sub {
  margin: 8px 0 4px;
  color: #b9b4d8;
}
.ovl-score {
  margin: 12px 0 18px;
  font-size: 1.15rem;
  color: #fff;
}
.ovl-score .big {
  display: block;
  font-size: 2.1rem;
  font-weight: 900;
  color: #7ee8fa;
  text-shadow: 0 0 16px rgba(126, 232, 250, 0.8);
}
.ovl-score .newrec {
  display: inline-block;
  margin-top: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  background: #0f766e;
  color: #a7ffef;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 1px;
}
.ovl-score .bonus {
  display: block;
  margin-top: 6px;
  font-size: 0.95rem;
  color: #ffd166;
}
.ovl-score .ach {
  display: block;
  margin-top: 6px;
  font-size: 0.9rem;
  color: #7ee8fa;
}