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

/* Conteneur global */
body {
  font-family: 'Roboto', sans-serif;
  background-color: #121212; /* Fond sombre pour un look futuriste */
  color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  margin: 0;
}

/* Formulaire de saisie de nom d'utilisateur */
.user-name-container {
  background-color: #1e1e1e; /* Fond plus sombre pour le conteneur */
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  text-align: center;
  width: 100%;
  max-width: 400px;
  box-sizing: border-box;
  transition: all 0.3s ease;
}

/* Label */
.user-name-container label {
  font-size: 18px;
  color: #ddd;
  margin-bottom: 10px;
  display: block;
  font-weight: bold;
}

/* Input (champ de texte pour le nom d'utilisateur) */
.user-name-container input[type="text"] {
  width: 100%;
  padding: 12px;
  margin: 10px 0;
  border: 2px solid #444;
  border-radius: 8px;
  font-size: 16px;
  background-color: #333; /* Fond sombre pour l'input */
  color: #fff; /* Texte en blanc */
  transition: all 0.3s ease;
}

.user-name-container input[type="text"]:focus {
  border-color: #5b9bd5; /* Bordure bleue au focus */
  outline: none;
  box-shadow: 0 0 8px rgba(91, 155, 213, 0.5);
}

/* Bouton pour valider le choix du nom d'utilisateur */
.user-name-container button {
  background-color: #5b9bd5;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s ease;
  margin-top: 10px;
}

.user-name-container button:hover {
  background-color: #4182c4;
}

.user-name-container button:active {
  background-color: #346ea1;
}


.chat-container {
  width: 350px;
  max-width: 100%;
  background-color: #1a1a1a; /* Fond sombre du chat */
  border-radius: 15px;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.5); /* Lueur néon */
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 2px solid #00FFB2; /* Bordure néon */
}

.header {
  background-color: #333;
  color: #00FFB2;
  padding: 15px;
  text-align: center;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
  border-bottom: 2px solid #00FFB2;
}

.chat-box {
  flex-grow: 1;
  padding: 10px;
  overflow-y: auto;
  height: 300px;
  background: #121212;
  color: #00FFB2;
  border-bottom: 2px solid #00FFB2;
}

.chat-box div {
  background-color: rgba(0, 255, 255, 0.1); /* Effet néon léger */
  border-radius: 10px;
  padding: 8px;
  margin: 5px 0;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

.input-container {
  display: flex;
  padding: 10px;
  background-color: #121212;
  border-top: 2px solid #00FFB2;
}

.chat-input {
  flex-grow: 1;
  padding: 10px;
  background-color: transparent;
  border: 2px solid #00FFB2;
  color: #00FFB2;
  border-radius: 30px;
  font-size: 14px;
  transition: all 0.3s ease;
}

.chat-input:focus {
  outline: none;
  border-color: #00FFB2;
}

button {
  padding: 10px 20px;
  background-color: transparent;
  color: #00FFB2;
  border: 2px solid #00FFB2;
  border-radius: 20px;
  font-size: 1rem;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.4s ease;
  box-shadow: 0 0 12px #00FFB2, 0 0 24px #00FFB2 inset;
  animation: neonPulse 1.5s ease-out infinite; /* Animation néon */
}

button:hover {
  background-color: #00FFB2;
  color: black;
  transform: scale(1.1);
  box-shadow: 0 0 25px #00FFB2, 0 0 45px #00FFB2, 0 0 65px #00FFB2 inset;
}

#toggle-speech {
  background-color: #00FFB2;
  color: black;
}

#toggle-speech:hover {
  background-color: #00e6b3;
}

#send {
  background-color: #00FFB2;
  color: black;
}

#send:hover {
  background-color: #00e6b3;
}

@keyframes neonPulse {
  0%, 100% {
    box-shadow: 0 0 10px #00FFB2, 0 0 20px #00FFB2 inset;
  }
  50% {
    box-shadow: 0 0 30px #00FFB2, 0 0 50px #00FFB2 inset;
  }
}

/* Responsive */
@media (max-width: 768px) {
  .chat-container {
    width: 90%;
    max-width: none;
  }

  .chat-input {
    font-size: 14px;
  }

  button {
    padding: 8px 16px;
    font-size: 14px;
  }
}
