/* Minimal, theme-aware shell. The surround and loading panel follow the OS
   light/dark setting; the canvas itself is the game's own (black space). */

:root {
  /* Lets native controls (the <progress> bar) render for the active theme. */
  color-scheme: light dark;

  --bg: #f1f1f4;
  --panel: rgba(255, 255, 255, 0.92);
  --border: rgba(0, 0, 0, 0.14);
  --fg: #16161a;
  --muted: #5b5b66;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0b10;
    --panel: rgba(24, 26, 38, 0.92);
    --border: rgba(255, 255, 255, 0.16);
    --fg: #f2f2f5;
    --muted: #9a9aa8;
  }
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg);
}

#wrapper {
  position: relative;
}

/* Fixed to the viewport so the loading panel stays centred even before the
   canvas has a real size (it defaults to 300x150 until the game sizes it). */
#overlay-wrapper {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

#overlay {
  padding: 16px 22px;
  background-color: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family:
    Bahnschrift, "DIN Alternate", "Franklin Gothic Medium",
    "Nimbus Sans Narrow", sans-serif-condensed, sans-serif;
  font-weight: normal;
}

#title {
  text-align: center;
  color: var(--fg);
  font-weight: normal;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#status {
  margin-top: 6px;
  text-align: center;
  color: var(--muted);
  font-size: 0.85em;
}

#progress-bar {
  display: block;
  margin-top: 12px;
  width: 100%;
  height: 6px;
}

#canvas {
  display: block;
  border: 0; /* a border throws off the reported mouse position */
  image-rendering: pixelated; /* keep the chunky pixel look when scaled */
}
