/* Chat Widget — Dra. Alice Yasuda */
.chat-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #e84a43;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(232,74,67,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}
.chat-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 25px rgba(232,74,67,0.5);
}
.chat-btn svg {
  width: 28px;
  height: 28px;
  fill: #fff;
}

.chat-popup {
  position: fixed;
  bottom: 96px;
  right: 24px;
  z-index: 9998;
  width: 360px;
  max-height: 520px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.15);
  display: none;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Poppins', sans-serif;
}
.chat-popup.open {
  display: flex;
}

.chat-header {
  background: #e84a43;
  color: #fff;
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.chat-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
.chat-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 200px;
  max-height: 340px;
}
.chat-msg {
  max-width: 85%;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.5;
  word-wrap: break-word;
}
.chat-msg.bot {
  background: #f5f0eb;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.chat-msg.user {
  background: #e84a43;
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.chat-msg.typing {
  background: #f5f0eb;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  color: #999;
  font-style: italic;
}

.chat-input-wrap {
  padding: 12px 16px;
  border-top: 1px solid #eee;
  display: flex;
  gap: 8px;
}
.chat-input-wrap input {
  flex: 1;
  border: 1px solid #ddd;
  border-radius: 24px;
  padding: 8px 16px;
  font-size: 14px;
  font-family: 'Poppins', sans-serif;
  outline: none;
}
.chat-input-wrap input:focus {
  border-color: #e84a43;
}
.chat-send {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #e84a43;
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.chat-send svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}
.chat-send:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
