/* ── Reset & Fullscreen ────────────────────────────────────── */
* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  font-family: 'Press Start 2P', 'Courier New', monospace;
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ── Ladebildschirm ────────────────────────────────────────── */
#loading-screen {
  position: fixed;
  inset: 0;
  background: #06030e;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  z-index: 999;
  transition: opacity 0.7s ease;
}
#loading-screen.hidden { opacity: 0; pointer-events: none; }

.skull {
  font-size: 80px;
  filter: drop-shadow(0 0 32px #7a20cf);
  animation: float 3s ease-in-out infinite;
}
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-14px)} }

#loading-title {
  font-size: 36px;
  color: #c080ff;
  letter-spacing: 8px;
  text-shadow: 0 0 30px #7a20cf, 0 0 80px #4a10af;
}
#loading-sub {
  font-size: 8px;
  color: #7a5a9a;
  letter-spacing: 2px;
  text-align: center;
  max-width: 480px;
  line-height: 2.2;
}
#loading-hint {
  font-size: 10px;
  color: #a070df;
  animation: pulse 1.2s ease-in-out infinite;
  letter-spacing: 4px;
}
@keyframes pulse { 0%,100%{opacity:0.2} 50%{opacity:1} }

/* ── Spielcontainer (Fullscreen) ───────────────────────────── */
#game-wrap {
  position: fixed;
  inset: 0;
}

#game {
  position: absolute;
  top: 0; left: 0;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

/* ── Dialogue-Box ──────────────────────────────────────────── */
#dbox {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 130px;
  background: rgba(6, 3, 14, 0.97);
  border-top: 3px solid #6a30af;
  padding: 12px 22px 10px;
  color: #ffffff;
  z-index: 50;
}
#dbox.hidden { display: none; }

#dbox-name {
  font-size: 8px;
  color: #c080ff;
  margin-bottom: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
#dbox-text {
  font-size: 7px;
  line-height: 2.2;
  color: #ffffff;
  min-height: 52px;
}
#dbox-arrow {
  position: absolute;
  bottom: 12px;
  right: 20px;
  color: #a050df;
  font-size: 10px;
  animation: blink 0.65s step-end infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

/* ── Steuerungshinweis ─────────────────────────────────────── */
#controls-hint {
  position: fixed;
  top: 8px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 6px;
  color: rgba(200,180,255,0.35);
  letter-spacing: 1px;
  pointer-events: none;
  z-index: 10;
}
