/* WCC first-party floating WhatsApp button (22 Nov 2026). No third-party widget.
   Stacking: above page content, the header (100) and the mobile amber bar (20);
   below the cookie panel (2147483000) and launcher (2147483001), so the cookie UI
   always wins if they ever meet. A future age pop-up should use z-index >= 1000
   and/or the documented hide hook (see wcc-whatsapp-float-20261122.js). */
.wcc-wa-float {
  position: fixed; right: 24px; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 900;
  display: flex; align-items: center; justify-content: center;
  width: 60px; height: 60px; min-width: 44px; min-height: 44px; padding: 0; margin: 0;
  border-radius: 50%; background: #25d366; color: #fff; text-decoration: none;
  box-shadow: 0 4px 14px rgba(20, 39, 60, .28); border: 0;
}
.wcc-wa-float svg { display: block; width: 32px; height: 32px; fill: currentColor; pointer-events: none; }
.wcc-wa-float:hover { background: #1ebe5b; }
.wcc-wa-float:focus-visible { outline: 3px solid #14273c; outline-offset: 3px; }
@media (prefers-reduced-motion: no-preference) {
  .wcc-wa-float { transition: transform .15s ease, background-color .15s ease; }
  .wcc-wa-float:hover { transform: scale(1.05); }
}
/* Hide while the menu is open (matches the amber bar), while the documented
   hook is set (future /book-appointment/ age pop-up), or while any open modal
   dialog or [data-age-gate] element is showing. */
body[data-menu-open] .wcc-wa-float,
html[data-wcc-whatsapp-float="hidden"] .wcc-wa-float { display: none; }
/* Kept in separate rules so older browsers without :has() still apply the two above. */
body:has(dialog[open]) .wcc-wa-float { display: none; }
/* A closed <dialog data-age-gate> is covered by dialog[open] above; other [data-age-gate] elements hide the bubble unless [hidden]. */
body:has([data-age-gate]:not(dialog):not([hidden])) .wcc-wa-float { display: none; }
@media (max-width: 899px) {
  /* Phones and small tablets: sit above the sticky amber bar (.mobile-enquiry). */
  .wcc-wa-float { right: 16px; bottom: calc(76px + env(safe-area-inset-bottom, 0px)); width: 56px; height: 56px; }
  .wcc-wa-float svg { width: 30px; height: 30px; }
  /* First-screen hero buttons stop 64px short of the right edge so the bubble never sits on
     them before scrolling: homepage and /visit-your-cask/ (.hero-actions), the book-a-call and
     campaign landers (.inner-hero-copy), the Caol Ila and Singapore team landers (.lander-copy)
     and /thank-you/ (.ty-hero). Mobile only; nothing else on those pages moves. */
  .hero-actions .button,
  .inner-hero-copy .button,
  .lander-copy .lander-button,
  .ty-hero .button { max-width: calc(100% - 64px); }
  /* No bar on the page, or the bar is hidden because a form is in view: drop down. */
  body:not(:has(> .mobile-enquiry)) .wcc-wa-float { bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
  body:has(> .mobile-enquiry[hidden]) .wcc-wa-float { bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
  /* Typing in a lead or guide form: get out of the way, as the bar does. */
  body:has(.lead-form :focus) .wcc-wa-float { display: none; }
  body:has([data-guide-form]:focus-within) .wcc-wa-float { display: none; }
}
@media (max-width: 719px) {
  /* The cookie panel spans the screen here; let it be read without the bubble over it. */
  body:has(#wcc-consent .wcc-consent-panel:not([hidden])) .wcc-wa-float { display: none; }
}
@media print { .wcc-wa-float { display: none !important; } }
