.container {
  max-width: 800px;
  margin: 5px auto;
  padding: 5px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

h1 {
  color: #333;
}

.game-container {
  margin: 5px auto;
  max-width: 480px;
}

.target-display {
  background-color: #f5f5f5;
  padding: 5px;
  border-radius: 10px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  font-size: 24px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.target-text {
  color: #333;
}

.target-emoji {
  font-size: 40px;
}

.target-name {
  color: #2196F3;
  font-weight: bold;
}

.score {
  font-size: 32px;
  margin-bottom: 20px;
  font-family: 'Courier New', monospace;
  color: #333;
}

#gameCanvas {
  background-color: #9EAD86;
  border: 10px solid #494F42;
  border-radius: 10px;
  margin-bottom: 20px;
  width: 480px;
  height: 480px;
}

.game-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 20px auto;
}

.controls {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.control-row {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.control-btn {
  width: 64px;
  height: 64px;
  font-size: 28px;
  background-color: #494F42;
  color: #9EAD86;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.control-btn:active {
  background-color: #2c2f28;
}

.game-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.action-btn {
  padding: 12px 24px;
  font-size: 20px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s;
  min-width: 120px;
}

.start-btn {
  background-color: #4CAF50;
  color: white;
}

.start-btn:hover {
  background-color: #45a049;
}

.navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
  padding: 0 20px;
}

.nav-button {
  background-color: #2196F3;
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 5px;
  font-size: 24px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.3s;
}

.nav-button:hover {
  background-color: #1976D2;
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  pointer-events: none;
}

.confetti {
  position: absolute;
  width: 10px;
  height: 10px;
  pointer-events: none;
}

/* Prevent double-tap zoom on iOS */
* {
  touch-action: manipulation;
}

/* Disable text selection */
.control-btn, .action-btn {
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* Game start overlay */
.start-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 24px;
  color: white;
  text-align: center;
}

/* Mobile responsiveness */
@media (max-width: 500px) {
  .game-container {
    width: 100%;
    max-width: 100%;
  }

  #gameCanvas {
    width: 100%;
    height: auto;
    border-width: 5px;
  }

  .control-btn {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }

  .game-controls {
    flex-direction: column;
  }

  .action-btn {
    padding: 10px 20px;
    font-size: 18px;
  }
}
