* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: #000;
  color: #fff;
  font-family: monospace;
  min-height: 100vh;
  display: grid;
  place-items: center;
}

#game-shell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 12px;
}

#gameCanvas {
  width: min(96vw, 960px);
  height: auto;
  aspect-ratio: 4 / 3;
  border: 6px solid #f00;
  background: #000;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

#touch-controls {
  width: min(96vw, 960px);
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

#touch-controls button {
  flex: 1;
  padding: 14px 10px;
  font-family: monospace;
  font-size: 1rem;
  border: 2px solid #fff;
  background: #111;
  color: #fff;
  cursor: pointer;
}

#touch-controls button:active {
  background: #333;
}

@media (min-width: 1024px) {
  #touch-controls {
    max-width: 420px;
  }
}