body {
  margin: 0;
  overflow: hidden;
  background: #f0f0f0;
  font-family: sans-serif;
}

.cursor {
  position: absolute;
  pointer-events: none; /* Pour ne pas bloquer les clics */
  transition: transform 0.1s linear; /* Lissage basique */
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.cursor img {
  max-width: 200px;
  max-height: 200px;
  width: auto;
  height: auto;
}

.bubble {
  position: absolute;
  top: -35px; /* Ajuste pour être au-dessus du curseur */
  left: 15px;
  background: #333; /* Noir pour bien la voir */
  color: white; /* Texte blanc */
  padding: 5px 12px;
  border-radius: 10px;
  font-family: Arial, sans-serif;
  font-size: 14px;
  display: none; /* Caché par défaut */
  white-space: nowrap;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.username {
  background: #4a90e2;
  color: white;
  padding: 4px 8px;
  border-radius: 5px;
  font-family: Arial, sans-serif;
  font-size: 12px;
  white-space: nowrap;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  position: static;
  margin-top: 5px;
}

#loginScreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
}

#loginScreen.hidden {
  display: none;
}

.login-container {
  background: white;
  padding: 40px;
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  text-align: center;
  max-width: 400px;
}

.login-container h1 {
  margin: 0 0 30px 0;
  color: #333;
}

.login-container input {
  display: block;
  width: 100%;
  padding: 12px;
  margin: 10px 0;
  border: 2px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
}

.login-container input:focus {
  outline: none;
  border-color: #667eea;
}

.login-container button {
  width: 100%;
  padding: 12px;
  margin-top: 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  font-weight: bold;
}

.login-container button:hover {
  opacity: 0.9;
}

.image-preview {
  width: 80px;
  height: 80px;
  margin: 15px auto;
  border: 2px dashed #667eea;
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f9f9f9;
}

.image-preview img {
  max-width: 100%;
  max-height: 100%;
}

#gameScreen {
  display: none;
}

#gameScreen.show {
  display: block;
}

.target {
  position: absolute;
  width: 30px;
  height: 30px;
  background: radial-gradient(circle, #ff6b6b 0%, #ff1744 100%);
  border: 2px solid #fff;
  border-radius: 50%;
  z-index: 5;
  box-shadow: 0 0 10px rgba(255, 23, 68, 0.8);
  pointer-events: auto;
  cursor: pointer;
}

.scoreboard {
  position: fixed;
  top: 20px;
  right: 20px;
  background: white;
  padding: 15px 25px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  z-index: 100;
  font-family: Arial, sans-serif;
  font-size: 20px;
  font-weight: bold;
  color: #333;
}

.scoreboard .score-value {
  color: #ff1744;
  margin-left: 10px;
}

.leaderboard {
  position: fixed;
  top: 20px;
  left: 20px;
  background: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  z-index: 100;
  font-family: Arial, sans-serif;
  min-width: 250px;
  max-height: 400px;
  overflow-y: auto;
}

.leaderboard h3 {
  margin: 0 0 15px 0;
  color: #333;
  font-size: 18px;
  border-bottom: 2px solid #667eea;
  padding-bottom: 10px;
}

.leaderboard-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}

.leaderboard-item:last-child {
  border-bottom: none;
}

.leaderboard-player {
  font-size: 14px;
  color: #333;
  font-weight: 500;
}

.leaderboard-player.me {
  color: #667eea;
  font-weight: bold;
}

.leaderboard-score {
  font-size: 14px;
  font-weight: bold;
  color: #ff1744;
}

.chat-hint {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid #eee;
  font-size: 12px;
  color: #666;
  text-align: center;
  font-style: italic;
}
