/* No browser defaults (UI-05) and no page zoom. The game's own look lives in its own stylesheet; this file only removes
   what the browser would otherwise draw. Sheets get their frames from the game's painted kit (border-image), never from
   CSS fills (LOOK-02) — the --sheet-* variables are where a game plugs its kit in. Sheet type grows with big screens (max(px, vmin)):
   the frames gate wants text ≥ 1.5 % of the short side (first pod run 2026-10-19: 16 px buttons and a 12 px stamp at 1920×1080). */
html, body { margin: 0; padding: 0; width: 100%; height: 100%; overflow: hidden; background: #000; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { touch-action: none; overscroll-behavior: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent; cursor: default; }
* { box-sizing: border-box; scrollbar-width: none; }
*::-webkit-scrollbar { display: none; }
*:focus, *:focus-visible { outline: none; }
img, canvas { -webkit-user-drag: none; user-select: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; cursor: inherit; appearance: none; }
/* never 100vh (REEF 2026-11-01, iPhone Safari): 100vh is the viewport with the toolbars HIDDEN, ~15 % taller than innerHeight
   while they show, so a canvas drawn at innerWidth x innerHeight was stretched and every tap landed above what it drew. The
   canvas fills the layout viewport itself; main.js lays out to the canvas's own box. */
canvas#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }

.sheet-veil { position: fixed; inset: 0; display: none; align-items: center; justify-content: center; z-index: 20; }
.sheet-veil.on { display: flex; }
.sheet { width: min(88vw, max(420px, 40vmin)); max-height: 86%; overflow: hidden; padding: 22px 24px; text-align: center;
  border-style: solid; border-width: var(--sheet-border-width, 0); border-image: var(--sheet-border, none);
  background: var(--sheet-fill, transparent); color: var(--sheet-ink, inherit); font-family: var(--sheet-font, inherit); }
.sheet h2 { margin: 0 0 12px; font-size: max(22px, 2.4vmin); }
.sheet p { margin: 8px 0; font-size: max(15px, 1.7vmin); line-height: 1.35; }
.sheet .row { display: flex; justify-content: center; gap: 12px; margin: 14px 0 4px; }
.sheet .btn { min-width: 120px; min-height: 44px; padding: 8px 16px; border-style: solid; border-width: var(--btn-border-width, 0);
  border-image: var(--btn-border, none); background: var(--btn-fill, transparent); font-size: max(16px, 1.7vmin); }
/* every button answers hover and press (UI-16; brand-hover): a lift on hover, a dip on press that keeps the hit box; the game's
   kit can restyle both through --btn-hover / --btn-press (a brightness or its own art), never remove them */
.sheet .btn { transition: transform 80ms ease-out, filter 80ms ease-out; }
.sheet .btn:hover { transform: translateY(-2px); filter: var(--btn-hover, brightness(1.15)); }
.sheet .btn:active { transform: translateY(1px) scale(0.97); filter: var(--btn-press, brightness(0.9)); }
.sheet .stamp { margin-top: 14px; font-size: max(14px, 1.6vmin); opacity: 0.7; }
/* the Music / Effects steppers (AUDIO-13): side by side where the sheet is wide enough, one under the other on a narrow phone;
   a short landscape phone (375–390 px tall) keeps every row on the sheet by tightening the gaps, never by hiding one */
.sheet .levels { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 22px; margin: 14px 0 4px; }
.sheet .levels .row { margin: 0; align-items: center; gap: 8px; }
.sheet .btn.step { min-width: 44px; padding: 8px 0; }
.sheet .btn.step:hover { transform: translateY(-2px); filter: var(--btn-hover, brightness(1.15)); }   /* UI-16: the steppers answer too */
.sheet .btn.step:active { transform: translateY(1px) scale(0.97); filter: var(--btn-press, brightness(0.9)); }
.sheet .lv { min-width: 6.2em; font-size: max(16px, 1.7vmin); }
@media (max-height: 480px) {
  .sheet { padding: 12px 20px; }
  .sheet h2 { margin-bottom: 4px; }
  .sheet .row, .sheet .levels { margin: 6px 0 2px; }
  .sheet .stamp { margin-top: 6px; }
}
/* Settings in two columns on a short landscape screen (RC-04, RUSH COURIER review 2026-10-25: at 800×450 the CG default size
   Start Over / Privacy / Credits were sliced, Back and the stamp off screen, and the sheet cannot scroll). Tall: the columns
   vanish (display: contents) and the rows stack in the T1 order (a short portrait screen, Safari's 390×660, tightens the gaps).
   Short and wide (≤ 700 px tall: CG 1077×606 / 800×450, phones held sideways): Sound / Music / Effects / the toggles on the left,
   How to play / Start Over / Privacy / Credits / Back on the right, the stamp under both; tighter rows; every row on one screen. */
.sheet.settings .cols, .sheet.settings .col { display: contents; }
@media (max-height: 700px) and (min-aspect-ratio: 1/1) {
  .sheet.settings { width: min(96vw, 680px); max-height: 98vh; padding-top: 6px; padding-bottom: 6px; }
  .sheet.settings h2 { margin: 0 0 4px; font-size: max(20px, 2.2vmin); }
  .sheet.settings .cols { display: grid; grid-template-columns: 1fr 1fr; column-gap: 14px; align-items: start; }
  .sheet.settings .col { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
  .sheet.settings .col .row, .sheet.settings .col .levels { margin: 0; }
  .sheet.settings .col .row { flex-wrap: wrap; gap: 6px; }
  .sheet.settings .col .row > .btn:not(.step) { flex: 1 1 auto; min-height: 44px; }
  .sheet.settings .levels { flex-direction: column; gap: 6px; }
  .sheet.settings .levels .row { justify-content: space-between; }
  .sheet.settings .lv { min-width: 0; flex: 1 1 auto; }
  .sheet.settings .stamp { margin-top: 4px; }
}
@media (max-height: 720px) and (max-aspect-ratio: 1/1) {
  .sheet.settings { max-height: 96vh; padding-top: 8px; padding-bottom: 8px; }
  .sheet.settings h2 { margin-bottom: 4px; }
  .sheet.settings .row, .sheet.settings .levels { margin: 6px 0 0; }
  .sheet.settings .stamp { margin-top: 6px; }
}
