body {
  font-family: 'Inter', sans-serif;
  background-color: #fdfcfb; /* Crème / blanc cassé */
  color: #3c366b; /* Indigo / ardoise / bleu nuit - pour le texte par défaut */
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  line-height: 1.6;
}

#chat-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 800px; /* Limiter la largeur pour une meilleure lisibilité sur desktop */
  margin: 0 auto; /* Centrer le conteneur */
  box-shadow: 0 0 20px rgba(0,0,0,0.05); /* Ombre discrète pour un effet "flottant" */
}

header {
  padding: 1rem;
  text-align: center;
  /* border-bottom: 1px solid #e0e0e0; */ /* Optionnel: séparateur léger */
}

#logo {
  height: 40px; /* Ajustez selon la taille de votre logo */
  margin-bottom: 0.5rem;
}

#chatbox {
  flex-grow: 1;
  padding: 1rem 1.5rem;
  overflow-y: auto;
  background-color: #fdfcfb; /* Fond légèrement différent pour la zone de chat si besoin, sinon identique au body */
  display: flex;
  flex-direction: column;
}

.message {
  max-width: 75%;
  margin: 0.5rem 0;
  padding: 0.8rem 1.2rem;
  border-radius: 18px;
  line-height: 1.5;
  word-wrap: break-word;
  position: relative; /* Pour les animations ou les "queues" de bulles si besoin */
}

.user {
  align-self: flex-end;
  background-color: #4a6fff; /* Un bleu doux pour l'utilisateur, conforme à l'inspiration */
  color: white;
  border-bottom-right-radius: 4px; /* Style "Messenger" */
}

.agent {
  align-self: flex-start;
  background-color: #e5e7eb; /* Gris clair pour l'IA, comme ChatGPT */
  color: #1f2937; /* Texte plus foncé pour l'IA pour contraster avec le fond clair */
  border-bottom-left-radius: 4px; /* Style "Messenger" */
}


/* Optionnel: pour indiquer le streaming */
.agent.streaming::after {
  content: '▋';
  animation: blink 1s infinite;
  display: inline-block;
  margin-left: 0.3em;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

form {
  display: flex;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid #e0e0e0; /* Séparateur plus doux */
  background: #ffffff; /* Fond blanc pour la zone de saisie */
}

#input {
  flex: 1;
  padding: 0.85rem 1.2rem;
  border-radius: 20px;
  border: 1px solid #d1d5db; /* Bordure subtile */
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
}

#input:focus {
  outline: none;
  border-color: #4a6fff;
  box-shadow: 0 0 0 2px rgba(74, 111, 255, 0.2);
}

button {
  padding: 0.85rem 1.2rem;
  border: none;
  background-color: #4a6fff; /* Couleur principale pour les boutons */
  color: white;
  border-radius: 20px;
  cursor: pointer;
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  transition: background-color 0.2s ease;
}

button:hover {
  background-color: #3c58cc; /* Assombrir légèrement au survol */
}

#micro {
  background-color: transparent;
  color: #4a6fff;
  font-size: 1.5rem; /* Rendre l'icône plus grande */
  padding: 0.5rem; /* Ajuster le padding pour l'icône */
}

#micro:hover {
  background-color: rgba(74, 111, 255, 0.1); /* Effet de survol subtil */
}

/* Responsive */
@media (max-width: 600px) {
  body {
    font-size: 0.95rem;
  }
  #chat-container {
    width: 100%;
    height: 100%;
    box-shadow: none;
  }
  #chatbox {
    padding: 1rem;
  }
  form {
    padding: 0.75rem;
  }
  #input {
    padding: 0.75rem 1rem;
  }
  button {
    padding: 0.75rem 1rem;
  }
  .message {
    max-width: 85%;
  }
}
