:root {
  --bg-top: #0f172a;
  --bg-bottom: #1e293b;
  --panel: rgba(15, 23, 42, 0.85);
  --panel-border: rgba(148, 163, 184, 0.25);
  --text: #e2e8f0;
  --accent: #38bdf8;
  --accent-strong: #0ea5e9;
  --danger: #f87171;
  --warning: #fbbf24;
  --success: #34d399;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  font-family: Arial, Helvetica, sans-serif;
  background: radial-gradient(circle at top, #1f2937 0%, var(--bg-top) 30%, var(--bg-bottom) 100%);
  color: var(--text);
}

.game-shell {
  width: min(90vw, 520px);
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--panel-border);
  border-radius: 18px;
  padding: 18px 18px 20px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.5);
}

.hud {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.hud > div {
  flex: 1;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  text-align: center;
  padding: 8px 10px;
}

.label {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.78;
}

.hud p:last-child {
  margin: 6px 0 0;
  font-size: 2rem;
  font-weight: 700;
}

#gameCanvas {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 14px;
  border: 2px solid rgba(148, 163, 184, 0.2);
  background: linear-gradient(180deg, #0b1120 0%, #111827 100%);
}

.controls {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

button {
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: white;
  font-size: 1rem;
  font-weight: 700;
  padding: 12px 20px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 12px 20px rgba(14, 165, 233, 0.3);
}

button:hover {
  transform: translateY(-1px);
}

button:active {
  transform: translateY(1px);
}
