/* Chatbot Lara Styles */

/* ---- CHATBOT (Premium Lara Style) ---- */
#chat-btn {
  position: fixed !important;
  bottom: 28px !important; right: 28px !important;
  left: auto !important; top: auto !important;
  z-index: 9999 !important;
  height: 68px; border-radius: 34px;
  background: rgba(255,255,255,0.8); color: var(--navy);
  border: 1px solid rgba(255,255,255,0.6); cursor: pointer;
  box-shadow: 0 15px 45px rgba(15,45,74,0.12), 0 0 20px rgba(232,112,10,0.05);
  display: flex; align-items: center; gap: 14px;
  padding: 0 24px 0 8px;
  transition: all 0.4s cubic-bezier(0.16,1,0.3,1);
}
#chat-btn::before {
  content: ''; position: absolute; inset: -4px;
  border-radius: 38px; border: 2px solid var(--orange);
  opacity: 0; animation: lara-holo-pulse 2.2s cubic-bezier(0.16,1,0.3,1) infinite;
  pointer-events: none;
}
@keyframes lara-holo-pulse {
  0% { transform: scale(0.95); opacity: 0.8; }
  100% { transform: scale(1.18); opacity: 0; }
}
#chat-btn:hover {
  background: var(--orange); border-color: var(--orange2); color: #fff;
  transform: translateY(-4px); box-shadow: 0 20px 45px rgba(232,112,10,0.45);
}
#chat-btn .chat-avatar {
  width: 52px; height: 52px; border-radius: 50%;
  overflow: hidden; flex-shrink: 0;
  border: 2px solid var(--orange); background: #222;
  box-shadow: 0 4px 12px rgba(15,45,74,0.15);
}
#chat-btn .chat-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
#chat-btn .chat-label { display: flex; flex-direction: column; line-height: 1.25; text-align: left; }
#chat-btn .chat-label strong { font-size: 0.98rem; font-weight: 700; }
#chat-btn .chat-label span { font-size: 0.72rem; opacity: 0.75; font-weight: 300; }
#chat-window {
  position: fixed !important;
  bottom: 106px !important; right: 28px !important;
  left: auto !important; top: auto !important;
  z-index: 9999 !important;
  width: min(390px, calc(100vw - 40px));
  background: rgba(255,255,255,0.88); border-radius: 24px;
  backdrop-filter: blur(28px); -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(255,255,255,0.6);
  box-shadow: 0 30px 80px rgba(15,45,74,0.15);
  display: none; flex-direction: column; overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16,1,0.3,1);
}
#chat-window.open { display: flex; }
.chat-header {
  background: rgba(15,45,74,0.95); color: #fff;
  padding: 18px 20px; display: flex; justify-content: space-between; align-items: center;
}
.chat-header span { font-weight: 700; font-size: 0.98rem; }
.chat-header button { background: none; border: none; color: #fff; cursor: pointer; font-size: 1.1rem; opacity: 0.7; transition: opacity 0.2s; }
.chat-header button:hover { opacity: 1; }
.chat-body { flex: 1; padding: 20px; height: 320px; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; background: rgba(0,0,0,0.03); }
.chat-msg { max-width: 82%; padding: 12px 16px; border-radius: 16px; font-size: 0.88rem; line-height: 1.55; position: relative; }
.chat-msg.bot {
  background: #fff; border: 1px solid rgba(15,45,74,0.06); color: var(--navy);
  align-self: flex-start; border-radius: 4px 16px 16px 16px;
  box-shadow: 0 4px 12px rgba(15,45,74,0.03); padding-right: 32px;
}
.chat-msg.user {
  background: var(--orange); color: #fff; align-self: flex-end;
  border-radius: 16px 4px 16px 16px; box-shadow: 0 6px 18px rgba(232,112,10,0.25);
}
.chat-input-row { display: flex; border-top: 1px solid rgba(15,45,74,0.08); background: rgba(255,255,255,0.5); }
.chat-input-row input {
  flex: 1; padding: 14px 18px; border: none; outline: none;
  font-size: 0.9rem; font-family: inherit; background: transparent; color: var(--navy);
}
.chat-input-row input::placeholder { color: var(--grau); opacity: 0.7; }
.chat-input-row button {
  padding: 14px 22px; background: var(--orange); color: #fff;
  border: none; cursor: pointer; font-size: 1.05rem; transition: background 0.25s, transform 0.2s;
}
.chat-input-row button:hover { background: var(--orange2); transform: scale(1.03); }
.chat-quick-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; align-self: flex-start; max-width: 100%; }
.chat-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid rgba(255,255,255,0.8);
  color: var(--navy); padding: 8px 16px; border-radius: 30px;
  font-size: 0.78rem; font-weight: 700; cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16,1,0.3,1);
  box-shadow: 3px 3px 8px rgba(15,45,74,0.06), -3px -3px 8px rgba(255,255,255,0.9);
}
.chat-pill:hover { transform: translateY(-2px); color: var(--orange); }
.chat-pill svg { width: 14px; height: 14px; stroke-width: 2.5; }
.chat-voice-btn {
  background: rgba(15,45,74,0.05); border: 1px solid rgba(15,45,74,0.08);
  border-radius: 50%; width: 30px; height: 30px; cursor: pointer;
  position: absolute; right: 12px; top: 12px;
  color: var(--navy); opacity: 0.75; transition: all 0.25s;
  display: flex; align-items: center; justify-content: center;
}
.chat-voice-btn:hover { opacity: 1; color: var(--orange); }
.chat-voice-btn.active {
  opacity: 1; background: var(--orange); color: #fff !important;
  box-shadow: 0 4px 12px rgba(232,112,10,0.3);
  animation: lara-voice-bounce 0.8s infinite alternate;
}
@keyframes lara-voice-bounce { from { transform: scale(1); } to { transform: scale(1.15); } }
.chat-input-row button.chat-mic-btn {
  background: var(--orange) !important; color: #fff !important;
  border: none !important; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: 0.85; transition: all 0.25s; padding: 14px 20px !important;
}
.chat-input-row button.chat-mic-btn:hover { opacity: 1; background: var(--orange2) !important; }
.chat-input-row button.chat-mic-btn.recording {
  opacity: 1 !important; background: #ef4444 !important;
  animation: mic-glow-pulse 1.2s infinite alternate;
}
.chat-input-row #chat-send { margin-left: 3px !important; }
@keyframes mic-glow-pulse { 0% { box-shadow: 0 0 4px #ef4444; } 100% { box-shadow: 0 0 16px #ef4444; } }
.typing-indicator { display: flex; align-items: center; gap: 4px; padding: 6px 8px; }
.typing-dot {
  width: 6px; height: 6px; background: rgba(15,45,74,0.5); border-radius: 50%;
  animation: lara-typing-bounce 1.4s infinite ease-in-out both;
}
.typing-dot:nth-child(1) { animation-delay: -0.32s; }
.typing-dot:nth-child(2) { animation-delay: -0.16s; }
@keyframes lara-typing-bounce {
  0%, 80%, 100% { transform: scale(0.3); opacity: 0.3; }
  40% { transform: scale(1.1); opacity: 1; }
}
