body {
  font-family: 'Roboto', sans-serif;
}

.message-time {
  display: block;
  font-size: 12px;
  color: #000000;
  margin-top: 5px;
  text-align: right;
}

/* Chatbot Floating Icon */
#chatbot-icon {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #007bff;
  color: white;
  padding: 15px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
  font-size: 24px;
  text-align: center;
  transition: transform 0.3s ease;
  z-index: 10000;
}

/* Chatbot Window */
#chatbot {
  position: fixed;
  bottom: 0;
  right: 20px;
  width: 350px;
  height: 500px;
  border-radius: 15px;
  border: 1px solid #ccc;
  background-color: #fff;
  display: flex !important;
  flex-direction: column;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
  transform: translateY(100%);
  transition: transform 0.4s ease-in-out;
  z-index: 10000;
}

#chatbot.show {
  transform: translateY(0);
}

/* Chat Header */
#chat-header {
  background-color: #007bff;
  color: white;
  padding: 8px;
  text-align: center;
  font-weight: 500;
  border-radius: 15px 15px 0 0;
  position: relative;
}

#close-btn {
  position: absolute;
  right: 15px;
  top: 10px;
  cursor: pointer;
  font-size: 20px;
}

/* Chat Content */
#chat-content {
  flex: 1;
  overflow-y: auto;
  padding: 15px;
  background-color: #f9f9f9;
}

#chat-content::-webkit-scrollbar {
  width: 8px;
}

#chat-content::-webkit-scrollbar-thumb {
  background-color: #007bff;
  border-radius: 10px;
}

/* Messages */
.message {
  margin-bottom: 15px;
  display: flex;
  align-items: flex-start;
}

.user-message {
  text-align: right;
  justify-content: flex-end;
}

.bot-message {
  justify-content: flex-start;
}

.user-icon,
.bot-icon {
  width: 20px;
  height: 20px;
  margin-right: 10px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 18px;
}

.user-icon {
  background-color: #007bff;
}

.bot-icon {
  background-color: #28a745;
}

.message-content {
  max-width: 90%;
  padding: 10px 15px;
  border-radius: 12px;
  color: #000005;
  font-size: 14px;
  text-align: justify;
  line-height: 1.5;
}

.user-message .message-content {
  background-color: #007bff45;
}

.bot-message .message-content {
  background-color: #fff;
}

/* Chat Input */
#chat-input {
  display: flex;
  padding: 15px;
  background-color: #fff;
  border-top: 1px solid #ccc;
  border-radius: 0 0 15px 15px;
}

#user-message {
  flex: 1;
  padding: 10px;
  border-radius: 25px;
  border: 1px solid #ccc;
  outline: none;
  transition: box-shadow 0.3s ease;
}

#user-message:focus {
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
}

#voice-btn,
#send-btn {
  background-color: transparent;
  border: none;
  color: #007bff;
  cursor: pointer;
  font-size: 24px;
  margin-left: 10px;
}

/* Loading Animation */
#loading-animation {
  display: none;
  text-align: center;
  padding: 15px;
}

.dot-flashing {
  position: relative;
  width: 10px;
  height: 10px;
  border-radius: 5px;
  background-color: #28a745;
  animation: dotFlashing 1s infinite linear alternate;
}

@keyframes dotFlashing {
  0% {
    background-color: #28a745;
  }
  50%,
  100% {
    background-color: #e0e0e0;
  }
}

/* Mobile Responsive */
@media (max-width: 600px) {
  #chatbot {
    width: 95%;
    left: 2.5%;
  }
}

/* Language Buttons */
.language-container {
  display: flex;
  justify-content: center;
}

.language-btn {
  background-color: #007bff;
  color: white;
  border: none;
  margin: 5px;
  cursor: pointer;
  border-radius: 5px;
  font-size: 14px;
  transition: background-color 0.3s;
  padding: 4px 10px;
}

.language-btn.active {
  background-color: #28a745;
}

.language-btn:hover {
  background-color: #0056b3;
}

/* Voice Button Animation */
#voice-btn.capturing {
  color: red;
  animation: glow 1s ease-in-out infinite alternate;
}

@keyframes glow {
  0% {
    box-shadow: 0 0 5px red;
  }
  100% {
    box-shadow: 0 0 20px red;
  }
}
