/* Floating WhatsApp button — Douexa (2026-09-30)
   Stacked above the chat bubble (#chatToggle: 60px, bottom 16px, right 16px). */
.dx-wa {
  --dx-wa-green: #25d366;
  --dx-wa-green-dark: #1ebe5b;
  --dx-wa-label-bg: rgba(12, 14, 20, 0.88);
  --dx-wa-label-fg: #fff;
  position: fixed;
  right: 22px;
  bottom: 88px;
  z-index: 499; /* just under the chat widget (500) */
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
html[data-theme="light"] .dx-wa {
  --dx-wa-label-bg: rgba(255, 255, 255, 0.95);
  --dx-wa-label-fg: #10131a;
}

.dx-wa__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--dx-wa-green);
  box-shadow: 0 8px 22px rgba(37, 211, 102, 0.35), 0 2px 6px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.dx-wa__label {
  font: 500 13px/1 "Inter", system-ui, sans-serif;
  color: var(--dx-wa-label-fg);
  background: var(--dx-wa-label-bg);
  border: 1px solid rgba(127, 127, 127, 0.2);
  padding: 8px 12px;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.14);
  opacity: 0;
  transform: translateX(6px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.dx-wa:hover .dx-wa__icon,
.dx-wa:focus-visible .dx-wa__icon {
  transform: scale(1.07);
  background: var(--dx-wa-green-dark);
  box-shadow: 0 10px 26px rgba(37, 211, 102, 0.45), 0 2px 6px rgba(0, 0, 0, 0.2);
}
.dx-wa:hover .dx-wa__label,
.dx-wa:focus-visible .dx-wa__label {
  opacity: 1;
  transform: none;
}
.dx-wa:focus-visible { outline: none; }
.dx-wa:focus-visible .dx-wa__icon { outline: 2px solid var(--dx-wa-green); outline-offset: 3px; }

/* Hide while the chat panel is open (desktop panel + mobile full screen) */
#chatWidget.open ~ .dx-wa,
body:has(#chatWidget.open) .dx-wa,
html.chat-open .dx-wa {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Hidden until the page is ready, so it does not show over the home loading screen */
.dx-wa { transition: opacity 0.3s ease, visibility 0.3s; }
.dx-wa[data-wa-hidden] { opacity: 0; visibility: hidden; }

@media (max-width: 640px) {
  .dx-wa { right: 22px; bottom: 86px; }
  .dx-wa__icon { width: 48px; height: 48px; }
  .dx-wa__label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .dx-wa__icon, .dx-wa__label, .dx-wa { transition: none; }
}

@media print { .dx-wa { display: none; } }
