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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #060f0a;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Fredoka', Arial, Helvetica, sans-serif;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

#gameCanvas {
  display: block;
  image-rendering: crisp-edges;
  border-radius: 0;
  /* Sizing handled by JS for perfect fit */
}

/* Desktop — subtle glow border */
@media (min-width: 600px) {
  #gameCanvas {
    border-radius: 12px;
    box-shadow:
      0 0 60px rgba(60, 200, 120, 0.15),
      0 0 120px rgba(60, 200, 120, 0.06);
  }
}

/* Loading screen */
#loading {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #aaa;
  font-size: 18px;
  gap: 16px;
}

#loading .spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #333;
  border-top: 4px solid #6c5ce7;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
