@font-face {
  font-family: "Kid Icarus";
  src: url("../assets/fonts/kid-icarus-nes.otf") format("opentype");
}

@font-face {
  font-family: "Starwing";
  src: url("../assets/fonts/starwing.ttf") format("truetype");
}

/* Test: swapped in as the active face below. Kid Icarus and Starwing are left
   registered above, unused, so the swap is one string away from being undone. */
@font-face {
  font-family: "City Connection";
  src: url("../assets/fonts/cityconnection.otf") format("opentype");
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #05060c;
  color: #7f8db4;
  font: 13px/1.5 "City Connection", "Lucida Console", Monaco, "Courier New", monospace;
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-text-size-adjust: 100%;
}

#frame {
  height: 100vh;
  height: 100dvh;          /* mobile address bars make 100vh lie */
  box-sizing: border-box;
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

/* The stage is just the space available. The canvas inside it is sized by
   the renderer, which picks a wide or tall buffer to suit. */
#stage {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

canvas {
  display: block;
  background: #05060c;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  border: 1px solid #1b2038;
  box-shadow: 0 0 0 1px #05060c, 0 18px 60px rgba(0, 0, 0, 0.85),
              0 0 90px rgba(50, 70, 140, 0.14);
  /* The canvas is a control surface, not a document: no panning, no
     double-tap zoom, no text selection, no blue flash on tap. */
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

@media (pointer: coarse), (max-width: 560px) {
  #frame { padding: 6px; gap: 6px; }
}
