* { margin: 0; padding: 0; box-sizing: border-box; }
body { background: #000; overflow: hidden; font-family: 'Segoe UI', sans-serif; user-select: none; }
#gameCanvas { display: block; width: 100vw; height: 100vh; }

#hud {
  position: absolute; top: 20px; left: 0; width: 100%;
  display: flex; justify-content: space-between; padding: 0 28px;
  pointer-events: none;
}
.hud-box {
  background: rgba(0,220,255,0.08);
  border: 1px solid rgba(0,220,255,0.35);
  border-radius: 8px; padding: 8px 18px;
  color: #00dcff; font-size: 13px; letter-spacing: 1px;
  text-shadow: 0 0 8px #00dcff;
}
.hud-box span { font-size: 22px; font-weight: 700; display: block; }

.screen {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  background: rgba(0,0,0,0.75); color: #fff; text-align: center;
  transition: opacity .3s;
}
.screen.hidden { opacity: 0; pointer-events: none; }

.screen h1 {
  font-size: clamp(30px,6vw,62px); color: #00dcff;
  text-shadow: 0 0 24px #00dcff, 0 0 60px #006aff;
  letter-spacing: 4px; margin-bottom: 10px;
}
.screen p {
  color: rgba(200,240,255,0.7); font-size: clamp(13px,2vw,16px);
  margin-bottom: 28px; max-width: 400px; line-height: 1.7;
}
.screen .final-score {
  font-size: clamp(16px,3vw,26px); color: #ffe066;
  text-shadow: 0 0 12px #ffb300; margin-bottom: 28px;
}
.controls-hint {
  display: flex; gap: 16px; margin-bottom: 32px; flex-wrap: wrap;
  justify-content: center;
}
.key-badge {
  background: rgba(0,220,255,0.1); border: 1px solid rgba(0,220,255,0.4);
  border-radius: 6px; padding: 6px 14px; color: #00dcff;
  font-size: 13px; letter-spacing: 1px;
}
.btn {
  background: transparent; border: 2px solid #00dcff;
  color: #00dcff; font-size: 15px; letter-spacing: 2px;
  padding: 13px 38px; border-radius: 6px; cursor: pointer;
  text-shadow: 0 0 8px #00dcff;
  box-shadow: 0 0 18px rgba(0,220,255,0.2);
  transition: background .2s, box-shadow .2s, transform .1s;
}
.btn:hover  { background: rgba(0,220,255,0.1); box-shadow: 0 0 32px rgba(0,220,255,0.45); }
.btn:active { transform: scale(0.96); }

#touchHint {
  position: absolute; bottom: 24px; width: 100%;
  text-align: center; color: rgba(0,220,255,0.35);
  font-size: 12px; letter-spacing: 1px; pointer-events: none;
}