/* Floating contact button: Live Chat + WhatsApp */

.chat-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
  font-family: Mulish, Montserrat, sans-serif;
}

.chat-fab-options {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
}

.chat-fab-option {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px) scale(.85);
  transition: opacity .25s ease, transform .25s cubic-bezier(.34, 1.4, .64, 1), visibility .25s;
}

.chat-fab.is-open .chat-fab-option {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.chat-fab.is-open .chat-fab-option:nth-child(1) { transition-delay: .08s; }
.chat-fab.is-open .chat-fab-option:nth-child(2) { transition-delay: .04s; }

.chat-fab-label {
  background: #fff;
  color: #111827;
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
  padding: 15px 22px;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(15, 23, 42, .12), 0 2px 6px rgba(15, 23, 42, .08);
}

.chat-fab-circle,
.chat-fab-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  height: 66px;
  border-radius: 50%;
  color: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, .18), 0 3px 8px rgba(15, 23, 42, .1);
  transition: transform .25s ease, box-shadow .25s ease, background-color .3s ease;
}

.chat-fab-circle-chat { background: #22c55e; }
.chat-fab-circle-wa   { background: #22c55e; }

.chat-fab-option:hover .chat-fab-circle { transform: scale(1.06); }
.chat-fab-option:hover .chat-fab-label  { box-shadow: 0 8px 22px rgba(15, 23, 42, .16); }

.chat-fab-toggle {
  position: relative;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #22c55e;
}

.chat-fab-toggle:hover { transform: scale(1.06); }

.chat-fab.is-open .chat-fab-toggle { background: #111827; }

.chat-fab-icon {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity .25s ease, transform .25s ease;
}

.chat-fab-icon-close { opacity: 0; transform: rotate(-90deg) scale(.6); }

.chat-fab.is-open .chat-fab-icon-chat  { opacity: 0; transform: rotate(90deg) scale(.6); }
.chat-fab.is-open .chat-fab-icon-close { opacity: 1; transform: rotate(0) scale(1); }

/* Hidden while the Crisp chatbox is open (Crisp shows its own button then). */
.chat-fab.is-hidden { display: none; }

@media (max-width: 575px) {
  .chat-fab { right: 16px; bottom: 16px; gap: 12px; }
  .chat-fab-options { gap: 12px; }
  .chat-fab-circle,
  .chat-fab-toggle { width: 60px; height: 60px; }
  .chat-fab-label { font-size: 15px; padding: 12px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .chat-fab-option,
  .chat-fab-circle,
  .chat-fab-toggle,
  .chat-fab-icon { transition: none; }
}
