/* Floating live chat widget — help center */
.support-chat-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 250;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--brand, #136f4e);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(19, 111, 78, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.support-chat-fab:hover {
  transform: scale(1.04);
  box-shadow: 0 10px 32px rgba(19, 111, 78, 0.45);
}
.support-chat-fab svg {
  width: 26px;
  height: 26px;
  fill: currentColor;
}
.support-chat-panel {
  position: fixed;
  right: 20px;
  bottom: 88px;
  z-index: 249;
  width: min(380px, calc(100vw - 24px));
  height: min(520px, calc(100vh - 120px));
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(15, 20, 25, 0.18);
  border: 1px solid var(--line, #e2e8f0);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px) scale(0.98);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.support-chat-panel.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.support-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 14px;
  background: var(--brand, #136f4e);
  color: #fff;
}
.support-chat-header h2 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}
.support-chat-header p {
  margin: 2px 0 0;
  font-size: 0.75rem;
  opacity: 0.9;
}
.support-chat-header-actions {
  display: flex;
  gap: 4px;
  align-items: center;
}
.support-chat-header-actions button {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #fff;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
}
.support-chat-header-actions button:hover {
  background: rgba(255, 255, 255, 0.25);
}
.support-chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  background: #f6faf8;
}
.support-chat-msg {
  max-width: 88%;
  margin: 6px 0;
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 0.9rem;
  line-height: 1.4;
  white-space: pre-wrap;
  word-break: break-word;
}
.support-chat-msg.assistant {
  background: #e8f0ec;
  color: #0f1419;
  border-bottom-left-radius: 4px;
}
.support-chat-msg.user {
  margin-left: auto;
  background: var(--brand, #136f4e);
  color: #fff;
  border-bottom-right-radius: 4px;
}
.support-chat-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.support-chat-quick button {
  border: 1px solid var(--line, #e2e8f0);
  background: #fff;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  cursor: pointer;
  color: var(--brand-dark, #0c5a40);
}
.support-chat-quick button:hover {
  background: var(--brand-light, #e7f3ec);
}
.support-chat-auth,
.support-chat-ended {
  padding: 16px;
  text-align: center;
}
.support-chat-auth input {
  width: 100%;
  margin: 6px 0;
  padding: 10px 12px;
  border: 1px solid var(--line, #e2e8f0);
  border-radius: 10px;
  font-size: 0.9rem;
}
.support-chat-auth .btn,
.support-chat-ended .btn {
  margin-top: 8px;
  width: 100%;
}
.support-chat-footer {
  border-top: 1px solid var(--line, #e2e8f0);
  padding: 10px;
  background: #fff;
}
.support-chat-input-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}
.support-chat-input-row textarea {
  flex: 1;
  resize: none;
  min-height: 40px;
  max-height: 100px;
  padding: 10px 12px;
  border: 1px solid var(--line, #e2e8f0);
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.9rem;
}
.support-chat-input-row button.send {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: var(--brand, #136f4e);
  color: #fff;
  cursor: pointer;
  flex-shrink: 0;
}
.support-chat-input-row button.send:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.support-chat-banner {
  margin: 0 12px 8px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #e7f3ec;
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.support-chat-banner button {
  border: none;
  background: var(--brand, #136f4e);
  color: #fff;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.support-chat-loading {
  font-size: 0.8rem;
  color: var(--muted, #6b7280);
  padding: 4px 0;
}
.support-chat-typing {
  font-size: 0.8rem;
  color: var(--muted, #6b7280);
  padding: 4px 0;
}
.support-chat-msg.agent {
  background: #e8f4fc;
  color: #0f3d5c;
  align-self: flex-start;
}
.support-chat-status-hint {
  font-size: 0.78rem;
  color: var(--muted, #6b7280);
  margin: 0 0 8px;
}
.support-chat-agent-btn {
  margin-top: 8px;
  width: 100%;
  border: 1px solid var(--brand, #136f4e);
  background: #fff;
  color: var(--brand, #136f4e);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}
.support-chat-typing-indicator[hidden] {
  display: none !important;
}
.support-chat-typing-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 4px;
  font-size: 0.78rem;
  color: var(--muted, #6b7280);
}
.support-chat-typing-dots {
  display: inline-flex;
  gap: 3px;
  align-items: center;
}
.support-chat-typing-dots span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #94a3b8;
  animation: support-chat-dot 1.2s infinite ease-in-out;
}
.support-chat-typing-dots span:nth-child(2) { animation-delay: 0.15s; }
.support-chat-typing-dots span:nth-child(3) { animation-delay: 0.3s; }
@keyframes support-chat-dot {
  0%, 80%, 100% { opacity: 0.35; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}
