* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  overflow: hidden; /* letterbox math guarantees fit; never show scrollbars */
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #0b0f16;
  -webkit-tap-highlight-color: transparent;
}

/* Actual size is set from main.js (letterbox scale, devicePixelRatio-aware,
   minus the footer's height). */
canvas {
  display: block;
  background: #000;
  touch-action: none; /* pointer steering owns the gesture: no scroll/zoom */
  user-select: none;
  -webkit-user-select: none;
}

/* Credit line under the canvas; wraps gracefully in mobile portrait. */
footer {
  flex: none;
  max-width: 100%;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  font: 14px "Marker Felt", "Comic Sans MS", "Chalkboard SE", cursive;
  color: rgba(234, 246, 251, 0.55);
  text-align: center;
  line-height: 1.6;
}

footer a {
  color: rgba(234, 246, 251, 0.85);
  text-decoration-color: rgba(234, 246, 251, 0.35);
}

footer a:hover {
  color: #fffdf7;
}
