/* Trusted runtime layout: keep the 960 × 640 (3:2) reference frame, but never taller than the screen,
   and switch to a portrait frame on upright phones. */
:root {
  --rf-game-max-width: min(960px, calc((100dvh - 2px) * 3 / 2));
  --rf-game-aspect-ratio: 3 / 2;
}
@media (orientation: portrait) and (max-width: 700px) {
  :root {
    --rf-game-max-width: min(100vw, calc((100dvh - 2px) * 2 / 3));
    --rf-game-aspect-ratio: 2 / 3;
  }
}
html, body { background: #101014; overscroll-behavior: none; }
