html {
  -ms-touch-action: none;
}

body, canvas, div {
  display: block;
  outline: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);

  user-select: none;
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  -khtml-user-select: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

/* Remove spin of input type number */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    /* display: none; <- Crashes Chrome on hover */
    -webkit-appearance: none;
    margin: 0; /* <-- Apparently some margin are still there even though it's hidden */
}

body {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  margin: 0;

  cursor: default;
  color: #888;
  background-color: #333;

  text-align: center;
  font-family: Helvetica, Verdana, Arial, sans-serif;

  display: flex;
  flex-direction: column;
}

canvas {
  background-color: rgba(0, 0, 0, 0);
}

#GameDiv, #Cocos3dGameContainer, #GameCanvas {
  width: 100%;
  height: 100%;
}

:root {
  --safe-top: env(safe-area-inset-top);
  --safe-right: env(safe-area-inset-right);
  --safe-bottom: env(safe-area-inset-bottom);
  --safe-left: env(safe-area-inset-left);
}

/* ── One deliberate deviation from the shipped style.css (which this file otherwise
   copies byte-for-byte). ──────────────────────────────────────────────────────────
   The recorded side-by-side shows OUR window with a horizontal scrollbar (thumb
   almost full width, so a few px of overflow) and a vertical one, while the original
   at a comparable window size has neither. The page is never meant to scroll: the
   canvas is sized to fill the viewport, and any scrollbar both steals pixels and
   shrinks the viewport, which can then trigger the other scrollbar.

   ⚠ This is a symptom guard, not a diagnosis. Measured here, our build does NOT
   overflow -- canvas == clientWidth/Height at 1280x720, at 848x440, and in a real
   (non-viewport-forced) window -- and index.html + style.css are byte-identical to
   the shipped ones apart from 5 hashed filenames. So the overflow is environmental
   (window size / per-origin browser zoom, which Chrome stores separately for
   localhost:8912 and for the live host). This rule makes the page unscrollable so
   the symptom cannot appear either way; it changes no layout and no rendering. */
html, body {
  overflow: hidden;
  overscroll-behavior: none;
}
