/* Brick Breakthrough — phone-first full-viewport game */

*,
*::before,
*::after {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #0a0e1a;
  color: #e8eefc;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

#app {
  position: relative;
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
}

#game {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: none;
}

.hud {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: max(10px, env(safe-area-inset-top)) 16px 0;
  pointer-events: none;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

.hud-left,
.hud-center,
.hud-right {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 4.5rem;
}

.hud-center {
  align-items: center;
}

.hud-right {
  align-items: flex-end;
}

.hud-label {
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.65;
  font-weight: 600;
}

.hud-value {
  font-size: 1.25rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.overlay {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  background: rgba(6, 10, 20, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.overlay.hidden {
  display: none;
}

.overlay-card {
  max-width: 22rem;
  width: 100%;
  text-align: center;
  padding: 28px 22px;
  border-radius: 20px;
  background: linear-gradient(160deg, rgba(30, 40, 70, 0.95), rgba(14, 18, 36, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

.overlay-card h1 {
  margin: 0 0 12px;
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, #59f0c2, #7eb6ff, #ff6b9d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.overlay-card p {
  margin: 0 0 22px;
  font-size: 0.95rem;
  line-height: 1.45;
  color: rgba(232, 238, 252, 0.78);
}

.btn {
  appearance: none;
  border: none;
  border-radius: 999px;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 700;
  color: #0a0e1a;
  background: linear-gradient(135deg, #59f0c2, #7eb6ff);
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(89, 240, 194, 0.25);
  touch-action: manipulation;
}

.btn:active {
  transform: scale(0.97);
}
