/* ===== RESET ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ===== BODY ===== */
body {
  font-family: "Segoe UI", Arial, sans-serif;
  background: #C9D6FF;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* =================================
   CHATBOT PAGE
================================= */

/* ===== LOGIN BUTTON ===== */
.btn-loginadmin {
  position: fixed;
  top: 20px;
  right: 20px;
}

.btn-loginadmin {
  padding: 8px 16px;
  border: none;
  background: #1e88e5;
  color: white;
  border-radius: 8px;
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: 0.3s;
  font-weight: bold;
}

.btn-loginadmin:hover {
  background:#002E5D;
}

/* ===== CHAT CONTAINER ===== */
.chat-container {
  width: 95%;
  max-width: 420px; /*ukuran desktok*/
  height: 520px;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  box-shadow: 0 15px 40px rgba(0, 51, 102, 0.7);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ===== HEADER ===== */
.chat-header {
  background:  #002E5D;
  color: white;
  padding: 18px;
  text-align: center;
  font-weight: bold;
  font-size: 18px;
}

/* ===== CHATBOX ===== */
#chatbox {
  flex: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
}

/* ===== CHAT BUBBLE BASE ===== */
.chat-message {
  padding: 12px 16px;
  border-radius: 18px;
  max-width: 75%;
  font-size: 14px;
  line-height: 1.4;
  position: relative;
  word-wrap: break-word;
  animation: fadeIn 0.2s ease;
}

/* ===== BOT MESSAGE ===== */
.chat-message.bot {
  background: rgba(255,255,255,0.9);
  align-self: flex-start;
  border-bottom-left-radius: 5px;
}

/* ekor bubble bot */
.chat-message.bot::after {
  content: "";
  position: absolute;
  left: -8px;
  bottom: 0;
  width: 0;
  height: 0;
  border-right: 10px solid rgba(255,255,255,0.9);
  border-top: 10px solid transparent;
}

/* ===== USER MESSAGE ===== */
.chat-message.user {
  background: linear-gradient(135deg,#1e88e5,#42a5f5);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 5px;
}

/* ekor bubble user */
.chat-message.user::after {
  content: "";
  position: absolute;
  right: -8px;
  bottom: 0;
  width: 0;
  height: 0;
  border-left: 10px solid #42a5f5;
  border-top: 10px solid transparent;
}

/* animasi muncul */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== INPUT AREA ===== */
.chat-input {
  display: flex;
  padding: 12px;
  gap: 10px;
  background: rgba(255,255,255,0.2);
}

/* input field */
.chat-input input {
  flex: 1;
  padding: 12px;
  border-radius: 25px;
  border: none;
  outline: none;
  background: rgba(255,255,255,0.9);
}

/* send button */
.chat-input button {
  padding: 12px 18px;
  border: none;
  border-radius: 25px;
  background: #1e88e5;
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s;
}

.chat-input button:hover {
  background: #002E5D;
}


.suggestion-box {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.suggest-btn {
  background: #f5f7ff;
  border: 1px solid #d6dcff;
  color: #002E5D;
  padding: 6px 10px;
  border-radius: 12px;
  font-size: 13px;
  cursor: pointer;
  transition: 0.2s;
}

.suggest-btn:hover {
  background: #3b4cca;
  color: white;
  transform: scale(1.03);
}