/* chatbot.css — real chat widget styling, matching this site's actual
   current design tokens (--ink, --gold, --paper, Space Grotesk/DM
   Sans) — the earlier version of this widget used an indigo palette
   from a prior design era; this uses the real, current one. */

.chat-bubble {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 900;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: none;
  background: var(--gold);
  color: #10100e;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(216, 181, 106, 0.35);
  transition: transform 0.25s var(--ease);
}
.chat-bubble:hover { transform: scale(1.06); }
.chat-bubble img { width: 24px; height: 24px; }
.chat-bubble .chat-close-icon { display: none; font-size: 26px; font-weight: 300; }
.chat-bubble.open .chat-open-icon { display: none; }
.chat-bubble.open .chat-close-icon { display: block; }

.chat-panel {
  position: fixed;
  bottom: 94px;
  right: 24px;
  z-index: 900;
  width: 360px;
  max-width: calc(100vw - 32px);
  height: 480px;
  max-height: calc(100vh - 140px);
  background: var(--paper);
  border-radius: 18px;
  border: 1px solid rgba(216, 181, 106, 0.25);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.chat-panel.open { display: flex; }

.chat-panel-header {
  background: #10100e;
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(216, 181, 106, 0.2);
}
.chat-panel-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gold);
  color: #10100e;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  flex-shrink: 0;
}
.chat-panel-title { font: 600 14.5px 'Space Grotesk', sans-serif; }
.chat-panel-subtitle { font-size: 12px; color: rgba(255, 255, 255, 0.6); }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--paper);
}
.chat-msg {
  max-width: 82%;
  padding: 10px 13px;
  border-radius: 12px;
  font-size: 13.5px;
  line-height: 1.45;
}
.chat-msg.bot {
  background: #fff;
  border: 1px solid var(--line);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  color: var(--ink);
}
.chat-msg.user {
  background: var(--gold);
  color: #10100e;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.chat-typing { display: flex; gap: 4px; padding: 12px 14px; }
.chat-typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: chat-typing-bounce 1.2s infinite ease-in-out;
}
.chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes chat-typing-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

.chat-input-row {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--line);
  background: #fff;
}
.chat-input-row input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 10px 16px;
  font-size: 13.5px;
  font-family: 'DM Sans', Arial, sans-serif;
  color: var(--ink);
}
.chat-input-row input:focus { outline: 2px solid var(--gold); outline-offset: 1px; }
.chat-send-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: var(--gold);
  color: #10100e;
  font-size: 16px;
  cursor: pointer;
  flex-shrink: 0;
}
.chat-send-btn:disabled, .chat-input-row input:disabled { opacity: 0.6; cursor: not-allowed; }

.chat-disclaimer {
  text-align: center;
  font-size: 10.5px;
  color: var(--muted);
  padding: 8px 0 12px;
  background: #fff;
}

@media (max-width: 480px) {
  .chat-panel { right: 12px; bottom: 84px; }
  .chat-bubble { right: 12px; }
}
