/* Full-screen cabinet. The page chrome stays on the 32 greys. The canvas keeps the trail colours. */
@font-face {
  font-family: "Press Start 2P";
  src: url("PressStart2P.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

html, body { height: 100%; overflow: hidden; background: #101010; }
body { display: flex; flex-direction: column; overscroll-behavior: none; }
h1.menubar__app { font-size: 22.5px; font-weight: 700; line-height: 1.4; }
.stage {
  position: relative;
  flex: 1;
  min-height: 0;
  display: grid;
  place-items: center;
  background: #101010;
  touch-action: none;
}
#screen {
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  background: #000;
  touch-action: none;
}
#players, #pause {
  position: absolute;
  z-index: 2;
  margin: 0;
  padding: 6px 10px;
  border: 2px solid #101010;
  background: #efefef;
  color: #101010;
  font: 600 22.5px/1 var(--font-ui);
  touch-action: manipulation;
}
#players { top: 8px; left: 8px; }
#pause { top: 8px; right: 8px; }
body[data-mode="play"] #players, body[data-mode="pause"] #players, body[data-mode="over"] #players { display: none; }
#players:active, #pause:active { background: #101010; color: #fff; }

.touch {
  display: none;
  position: fixed;
  z-index: 40;
  left: 0; right: 0; bottom: 0;
  justify-content: space-between;
  align-items: flex-end;
  padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
  pointer-events: none;
  touch-action: none;
}
.dpad {
  display: grid;
  grid-template-columns: 54px 54px 54px;
  grid-template-rows: 54px 54px 54px;
  gap: 6px;
  pointer-events: none;
}
.pedals { display: flex; gap: 14px; align-items: flex-end; pointer-events: none; }
.touch button {
  pointer-events: auto;
  touch-action: none;
  margin: 0;
  padding: 0;
  border: 2px solid #101010;
  border-radius: 8px;
  background: #efefef;
  color: #101010;
  font: 600 22.5px/1 var(--font-ui);
  user-select: none;
  -webkit-user-select: none;
}
.dpad button { width: 54px; height: 54px; }
.dpad [data-k="up"] { grid-column: 2; grid-row: 1; }
.dpad [data-k="left"] { grid-column: 1; grid-row: 2; }
.dpad [data-k="right"] { grid-column: 3; grid-row: 2; }
.dpad [data-k="down"] { grid-column: 2; grid-row: 3; }
.pedals button {
  width: 92px; height: 92px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  border-radius: 46px;
  font-size: 36px;
}
.pedals small { font: 600 16px/1 var(--font-ui); letter-spacing: 0.04em; }
.touch button:active { background: #101010; color: #fff; }

@media (pointer: coarse), (max-width: 820px) {
  .touch { display: flex; }
}
body.has-touch .touch { display: flex; }

@media (max-width: 359px) {
  h1.menubar__app { font-size: 19.5px; }
  .pedals button { width: 76px; height: 76px; font-size: 30px; }
  .dpad, .dpad button { width: auto; }
  .dpad { grid-template-columns: 46px 46px 46px; grid-template-rows: 46px 46px 46px; }
  .dpad button { width: 46px; height: 46px; }
}

.noscript { padding: 24px; color: #efefef; font: 16px/1.4 var(--font-ui); }
