:root {
  --bm-contact-bg: #0f172a;
  --bm-contact-surface: #ffffff;
  --bm-contact-text: #111827;
  --bm-contact-muted: #4b5563;
  --bm-contact-ring: #38bdf8;
  --bm-contact-shadow: 0 18px 45px rgba(15, 23, 42, 0.22);
  --bm-contact-radius: 8px;
}

.bm-contact-widget {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 9999;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.bm-contact-widget *,
.bm-contact-widget *::before,
.bm-contact-widget *::after {
  box-sizing: border-box;
}

.bm-contact-panel {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
  opacity: 0;
  transform: translateY(8px) scale(0.98);
  pointer-events: none;
  transition: opacity 170ms ease, transform 170ms ease;
}

.bm-contact-widget:hover .bm-contact-panel,
.bm-contact-widget:focus-within .bm-contact-panel,
.bm-contact-widget.is-open .bm-contact-panel {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.bm-contact-link,
.bm-contact-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--bm-contact-shadow);
  -webkit-tap-highlight-color: transparent;
}

.bm-contact-link {
  width: 52px;
  height: 52px;
  margin-left: auto;
  border-radius: 50%;
  color: #ffffff;
  transform: translateX(0);
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.bm-contact-link:hover,
.bm-contact-link:focus-visible {
  transform: translateX(-3px);
}

.bm-contact-link:focus-visible,
.bm-contact-toggle:focus-visible {
  outline: 3px solid var(--bm-contact-ring);
  outline-offset: 3px;
}

.bm-contact-link svg,
.bm-contact-toggle svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
}

.bm-contact-link[data-channel="whatsapp"] {
  background: #25d366;
}

.bm-contact-link[data-channel="call"] {
  background: #2563eb;
}

.bm-contact-link[data-channel="email"] {
  background: #dc2626;
}

.bm-contact-link[data-channel="sms"] {
  background: linear-gradient(180deg, #5ff675 0%, #34c759 54%, #24a944 100%);
  color: #ffffff;
  box-shadow: 0 18px 45px rgba(52, 199, 89, 0.28);
}

.bm-contact-toggle {
  width: 60px;
  height: 60px;
  margin-left: auto;
  border-radius: 50%;
  background: var(--bm-contact-bg);
  color: #ffffff;
  transition: transform 150ms ease, background 150ms ease;
}

.bm-contact-widget:hover .bm-contact-toggle,
.bm-contact-widget:focus-within .bm-contact-toggle,
.bm-contact-widget.is-open .bm-contact-toggle {
  background: #111827;
  transform: translateY(-2px) scale(1.03);
}

.bm-contact-label {
  position: absolute;
  right: 62px;
  max-width: 160px;
  padding: 7px 9px;
  border-radius: var(--bm-contact-radius);
  background: var(--bm-contact-surface);
  color: var(--bm-contact-text);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
  opacity: 0;
  transform: translateX(4px);
  transition: opacity 140ms ease, transform 140ms ease;
}

.bm-contact-link:hover .bm-contact-label,
.bm-contact-link:focus-visible .bm-contact-label {
  opacity: 1;
  transform: translateX(0);
}

.bm-contact-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 520px) {
  .bm-contact-widget {
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
  }

  .bm-contact-link {
    width: 50px;
    height: 50px;
  }

  .bm-contact-toggle {
    width: 58px;
    height: 58px;
  }

  .bm-contact-label {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bm-contact-panel,
  .bm-contact-link,
  .bm-contact-toggle,
  .bm-contact-label {
    transition: none;
  }
}

/* Keep contact options above the mobile booking bar. */
@media(max-width:850px){.bm-contact-widget{bottom:calc(84px + env(safe-area-inset-bottom))}}
.bm-contact-panel{visibility:hidden}.bm-contact-widget:hover .bm-contact-panel,.bm-contact-widget:focus-within .bm-contact-panel,.bm-contact-widget.is-open .bm-contact-panel{visibility:visible}
