:root {
  --bg: #0f172a;
  --panel: #111827;
  --panel-alt: #1f2937;
  --primary: #34d399;
  --accent: #fbbf24;
  --danger: #f87171;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --grid: rgba(148, 163, 184, 0.18);
}

* {
  box-sizing: border-box;
}

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

.app {
  width: min(92vw, 500px);
  background: rgba(17, 24, 39, 0.88);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 20px;
  padding: 1.5rem;
  box-shadow: 0 30px 60px rgba(15, 23, 42, 0.55);
}

h1 {
  margin: 0 0 1rem;
  text-align: center;
  font-size: clamp(2rem, 4vw, 2.5rem);
}

.hud {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.score-box {
  flex: 1;
  background: var(--panel-alt);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
}

.label {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.72rem;
}

#game {
  display: block;
  width: 100%;
  max-width: 400px;
  aspect-ratio: 1;
  border-radius: 12px;
  background: #020817;
  border: 2px solid rgba(52, 211, 153, 0.4);
  margin: 0 auto;
}

.controls {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

button {
  border: none;
  border-radius: 999px;
  padding: 0.8rem 1.5rem;
  font-size: 1rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), #10b981);
  color: #062b21;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
  box-shadow: 0 12px 25px rgba(52, 211, 153, 0.2);
}

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

button:active {
  transform: translateY(0);
}

.instructions {
  margin: 1rem 0 0;
  text-align: center;
  color: var(--muted);
  line-height: 1.5;
}
