/* Arcade Shelf shared theme. Every game links this BEFORE its own style.css. */
@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;700&family=JetBrains+Mono:wght@500;700&display=swap");

:root {
  --bg: #0e1016;
  --bg-2: #161922;
  --surface: #1c2030;
  --surface-2: #252a3d;
  --line: #2f3550;
  --text: #eef0f7;
  --muted: #9aa1bb;
  --accent: #ffb020;      /* primary: warm amber */
  --accent-2: #4fd1c5;    /* secondary: teal */
  --danger: #ff5d73;
  --good: #6ee7a0;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  --font: "Space Grotesk", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --bar-h: 52px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: radial-gradient(1200px 600px at 50% -10%, #1d2235 0%, var(--bg) 60%) fixed, var(--bg);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

/* Top bar injected by shell.js */
.as-bar {
  position: fixed; inset: 0 0 auto 0; height: var(--bar-h); z-index: 1000;
  display: flex; align-items: center; gap: 12px; padding: 0 16px;
  background: rgba(14, 16, 22, 0.82); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.as-bar a, .as-bar button {
  color: var(--text); text-decoration: none; font: 500 14px var(--font);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 7px 12px; cursor: pointer;
}
.as-bar a:hover, .as-bar button:hover { border-color: var(--accent); }
.as-bar .as-title { font-weight: 700; font-size: 16px; flex: 1; text-align: center; }
.as-bar .as-keys { color: var(--muted); font-size: 13px; }
body.as-has-bar { padding-top: var(--bar-h); }

/* Common building blocks games may use */
.as-btn {
  font: 700 15px var(--font); color: #1a1205; background: var(--accent);
  border: 0; border-radius: var(--radius-sm); padding: 10px 18px; cursor: pointer;
  transition: transform .08s ease, filter .15s ease;
}
.as-btn:hover { filter: brightness(1.08); }
.as-btn:active { transform: translateY(1px); }
.as-btn.ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--line); }

.as-panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px;
}

.as-stat { font: 700 22px var(--mono); }
.as-label { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }

kbd {
  font: 600 12px var(--mono); background: var(--surface-2); border: 1px solid var(--line);
  border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px;
}

/* Overlay for start / pause / game over */
.as-overlay {
  position: fixed; inset: var(--bar-h) 0 0 0; z-index: 900;
  display: grid; place-items: center; background: rgba(8, 9, 14, 0.72);
  backdrop-filter: blur(4px);
}
.as-overlay[hidden] { display: none; }
.as-overlay .as-panel { text-align: center; min-width: 300px; max-width: 90vw; }
.as-overlay h2 { margin: 0 0 8px; font-size: 28px; }
.as-overlay p { color: var(--muted); margin: 0 0 18px; }

:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }
