body {
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  background-color: #f0f0f0;
  font-family: Arial, sans-serif;
}
.game-container {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}
#game-canvas {
  border: 2px solid #333;
  background-color: #8fbc8f;
}
#confetti-canvas {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 5;
}
#score-display {
  margin-top: 10px;
  font-size: 18px;
  font-weight: bold;
}
#win-message {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(255, 255, 255, 0.9);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  text-align: center;
  display: none;
  z-index: 10;
}
#win-message h2 {
  color: #468847;
  margin-top: 0;
}
#restart-button {
  background-color: #5cb85c;
  color: white;
  border: none;
  padding: 10px 15px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  margin-top: 10px;
}
#restart-button:hover {
  background-color: #4cae4c;
}
.control-buttons {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.game-button {
  padding: 8px 15px;
  background-color: #5cb85c;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
}
.control-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  background-color: #f8f9fa;
  padding: 8px 15px;
  border-radius: 5px;
  border: 1px solid #ced4da;
}
.control-checkbox {
  margin-right: 8px;
}

/* Race mode specific styles */
#race-toggle:checked + span {
  color: #d9534f;
  font-weight: bold;
}

/* Visual indicator when race mode is active */
label:has(#race-toggle:checked) {
  background-color: #fff8f8;
  border-color: #d9534f;
}
