* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body {
  height: 100%; width: 100%; overflow: hidden;
  background: #eef1fb; color: #1a2350;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
canvas { display: block; width: 100vw; height: 100vh; touch-action: none; }

/* Minimal HTML overlay used only for the player name entry (typing on canvas is awful). */
.overlay {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 16px; padding: 24px; z-index: 10;
}
.overlay.hidden { display: none; }
.overlay h1 { font-size: 32px; font-weight: 800; }
.overlay p { color: #6b7597; font-weight: 600; }
.overlay input {
  font-size: 18px; padding: 15px 18px; border-radius: 14px; width: 100%; max-width: 340px;
  border: 2px solid #d8deee; background: #ffffff; color: #1a2350; font-weight: 600;
}
.overlay input:focus { outline: none; border-color: #2f6bff; }
.overlay button {
  font-size: 18px; font-weight: 800; padding: 16px 22px; border-radius: 14px; width: 100%; max-width: 340px;
  border: none; background: #2f6bff; color: #fff; cursor: pointer;
  box-shadow: 0 6px 0 #234fc0;
}
.overlay button:active { transform: translateY(3px); box-shadow: 0 3px 0 #234fc0; }
.overlay .err { color: #e63950; min-height: 20px; font-weight: 700; }
