:root {
  color-scheme: dark;
  --sat: env(safe-area-inset-top, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
  --sal: env(safe-area-inset-left, 0px);
  --sar: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0; width: 100%; height: 100%;
  background: #1a1a24; color: #fff1e8;
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none; user-select: none;
  font-family: monospace;
  touch-action: none;
}
#stage {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  overflow: hidden;
  background: #1a1a24;
  touch-action: none;
}
#game {
  position: absolute; left: 0; top: 0;
  image-rendering: crisp-edges;
  image-rendering: pixelated;
  touch-action: none;
  display: block;
  cursor: pointer;
}
/* Hidden probe so the game can read safe-area insets in JS. */
#safe-probe {
  position: fixed; left: 0; top: 0; visibility: hidden; pointer-events: none;
  padding-top: var(--sat); padding-bottom: var(--sab);
  padding-left: var(--sal); padding-right: var(--sar);
}
#noscript {
  position: fixed; inset: 0; display: grid; place-items: center;
  text-align: center; padding: 2rem; font-size: 1.1rem;
}
