/*
 * WhatsApp floating chat button (static, no JS). Markup lives just before </body> in the template.
 * Placement: fixed bottom-right. The theme's back-to-top button (.uicore-back-to-top, 40px square,
 * right/bottom 2em, desktop only >= 1025px) sits at the corner, so on desktop this button stacks
 * above it; on tablet/mobile (back-to-top hidden) it takes the corner.
 * z-index 990 stays under the theme back-to-top (999) and far under the mobile menu overlay (99999999).
 * Colours: brand green #25D366 with dark #062E17 glyph/label (about 8:1) instead of white (2:1).
 */
.lc-wa-float {
  --lc-wa-green: #25D366;
  --lc-wa-green-hover: #1EBE5A;
  --lc-wa-ink: #062E17;
  position: fixed;
  right: calc(30px + env(safe-area-inset-right, 0px));
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  z-index: 990;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 56px;
  padding: 0 20px 0 14px;
  border-radius: 28px;
  background: var(--lc-wa-green);
  color: var(--lc-wa-ink);
  font: 700 15px/1 "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .28);
  transition: background-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
/* Desktop: stack above the 40px back-to-top button (30px + 40px + 14px gap). */
@media (min-width: 1025px) {
  .lc-wa-float { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
}
.lc-wa-float:hover,
.lc-wa-float:focus-visible {
  background: var(--lc-wa-green-hover);
  color: var(--lc-wa-ink);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .34);
}
.lc-wa-float:focus-visible { outline: 3px solid var(--lc-wa-ink); outline-offset: 3px; }
.lc-wa-icon { flex: none; width: 28px; height: 28px; }
.lc-wa-label { display: inline-flex; align-items: center; }
/* The number slides in on hover/focus; it is also in the title attribute. */
.lc-wa-number {
  display: inline-block;
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-width .3s ease, opacity .2s ease, margin .3s ease;
}
.lc-wa-float:hover .lc-wa-number,
.lc-wa-float:focus-visible .lc-wa-number { max-width: 150px; margin-left: 8px; opacity: 1; }
/* Soft pulse ring behind the button. */
.lc-wa-float::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 0 0 rgba(37, 211, 102, .55);
  animation: lc-wa-pulse 2.4s ease-out infinite;
  pointer-events: none;
}
@keyframes lc-wa-pulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, .55); }
  70%, 100% { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .lc-wa-float, .lc-wa-number { transition: none; }
  .lc-wa-float::before { animation: none; }
  .lc-wa-float:hover, .lc-wa-float:focus-visible { transform: none; }
}
/* Phones: icon-only round button; the visible text is replaced by aria-label/title. */
@media (max-width: 600px) {
  .lc-wa-float {
    right: calc(16px + env(safe-area-inset-right, 0px));
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    width: 56px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
  }
  .lc-wa-label {
    position: absolute;
    width: 1px; height: 1px;
    margin: -1px; padding: 0; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%);
    white-space: nowrap; border: 0;
  }
}
@media print { .lc-wa-float { display: none !important; } }
