
/* Toggle Button */
#chat-toggle {
  position: fixed;
bottom: 50px;
    right: 80px;
  background: linear-gradient(135deg, #0A66C2, #1fa2ff);
  color: white;
  padding: 16px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  transition: 0.3s;
}
#chat-toggle:hover {
  transform: scale(1.1);
}

/* Chatbox */
#chatbox {
  display: none;
  position: fixed;
  bottom: 120px;
    right: 80px;
  width: 340px;
  height: 460px;
  background: #f9fafc;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.3);
  overflow: hidden;
  flex-direction: column;
      z-index: 99999;
}

/* Header */
#chat-header {
  background: linear-gradient(135deg, #0A66C2, #1fa2ff);
  color: white;
  padding: 12px 15px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
}

/* Messages */
#messages {
  flex: 1;
  padding: 12px;
  overflow-y: auto;
  font-size: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* USER MESSAGE */
.user-msg {
  display: flex;
  justify-content: flex-end;
}

.user-msg span {
  background: linear-gradient(135deg, #0A66C2, #1fa2ff);
  color: white;
  padding: 8px 12px;
  border-radius: 14px 14px 4px 14px;
  max-width: 75%;
  font-size: 13px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.2);
  animation: fadeIn 0.3s ease;
}

/* BOT MESSAGE */
.bot-msg {
  display: flex;
  justify-content: flex-start;
}

.bot-msg span {
  background: white;
  color: #333;
  padding: 8px 12px;
  border-radius: 14px 14px 14px 4px;
  max-width: 75%;
  font-size: 13px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 3px 10px rgba(0,0,0,0.1);
  animation: fadeIn 0.3s ease;
}

/* INPUT AREA */
#input-area {
  display: flex;
  border-top: 1px solid #ddd;
  background: white;
}

#input {
  flex: 1;
  border: none;
  padding: 12px;
  outline: none;
  font-size: 14px;
}

#input-area button {
  background: #0A66C2;
  color: white;
  border: none;
  padding: 12px 15px;
  cursor: pointer;
  transition: 0.2s;
}

#input-area button:hover {
  background: #084c91;
}

/* SUGGESTIONS */
#suggestions {
  padding: 6px;
  border-top: 1px solid #eee;
  background: #f3f4f6;
}

#suggestions button {
  margin: 3px;
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 20px;
  border: none;
  background: #e5e7eb;
  cursor: pointer;
  transition: 0.2s;
}

#suggestions button:hover {
  background: #0A66C2;
  color: white;
}

/* FORM INSIDE BOT */
.bot-msg input {
  width: 90%;
  padding: 6px;
  margin-top: 5px;
  border-radius: 6px;
  border: 1px solid #ddd;
}

.bot-msg button {
  margin-top: 5px;
  background: #0A66C2;
  color: white;
  border: none;
  padding: 6px 10px;
  border-radius: 6px;
  cursor: pointer;
}

/* ANIMATION */
@keyframes fadeIn {
  from {opacity:0; transform:translateY(10px);}
  to {opacity:1; transform:translateY(0);}
}








/* =========================
   📱 MOBILE OPTIMIZATION
========================= */
@media (max-width: 768px) {

  /* CHAT BUTTON */
  #chat-toggle {
           right: 70px;
        bottom: 55px;
        padding: 14px;
        font-size: 18px;
  }

  /* CHATBOX FULL WIDTH */
  /* #chatbox {
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100vh;
    border-radius: 0;
  } */
   #chatbox {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  
  width: 90%;
  max-width: 360px;

  height: 80vh;
  max-height: 550px;

  border-radius: 16px;
}

  /* HEADER */
  #chat-header {
    padding: 14px;
    font-size: 15px;
  }

  /* MESSAGES */
  #messages {
    padding: 10px;
    font-size: 13px;
  }

  /* BUBBLES WIDTH */
  .user-msg span,
  .bot-msg span {
    max-width: 85%;
    font-size: 13px;
    padding: 10px 12px;
  }

  /* INPUT AREA */
  #input-area {
    position: sticky;
    bottom: 0;
  }

  #input {
    font-size: 14px;
    padding: 14px;
  }

  #input-area button {
    padding: 14px;
    font-size: 14px;
  }

  /* SUGGESTIONS */
  #suggestions {
    padding: 8px;
    overflow-x: auto;
    white-space: nowrap;
  }

  #suggestions button {
    font-size: 11px;
    padding: 6px 10px;
  }

}