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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #0a1a2e;
  font-family: 'Segoe UI', Arial, sans-serif;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

#gameCanvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* HUD */
#hud {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  z-index: 10;
}

#hudScore, #hudCoins {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  text-shadow: 1px 2px 4px rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  gap: 6px;
}

.hud-icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.4));
}

#hudBoost {
  position: fixed;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 28px;
  font-weight: 900;
  color: #00e5ff;
  text-shadow: 0 0 12px #00e5ff, 0 0 24px #00e5ff;
  animation: boostPulse 0.4s ease-in-out infinite alternate;
  z-index: 10;
  pointer-events: none;
}

@keyframes boostPulse {
  from { transform: translateX(-50%) scale(1); }
  to { transform: translateX(-50%) scale(1.15); }
}

/* Overlays */
#startScreen, #gameOverScreen {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 20;
  background: rgba(10, 26, 46, 0.55);
  color: #fff;
  text-align: center;
}

#coverImg {
  width: 260px;
  height: 260px;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 16px;
  box-shadow: 0 6px 32px rgba(0,0,0,0.45);
}

#startScreen h1, #gameOverScreen h1 {
  font-size: 52px;
  font-weight: 900;
  margin-bottom: 12px;
  text-shadow: 2px 3px 8px rgba(0,0,0,0.6);
  letter-spacing: 2px;
}

#startScreen p, #gameOverScreen p {
  font-size: 18px;
  margin-bottom: 10px;
  opacity: 0.9;
}

#startScreen .hint {
  font-size: 14px;
  opacity: 0.6;
  margin-top: 18px;
}

button {
  margin-top: 18px;
  padding: 14px 48px;
  font-size: 22px;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  background: linear-gradient(135deg, #43cea2, #185a9d);
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  transition: transform 0.15s, box-shadow 0.15s;
}

button:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 24px rgba(0,0,0,0.4);
}

button:active {
  transform: scale(0.97);
}

.hidden { display: none !important; }
