/* A separate WhatsApp shortcut shares the site's black, white and gold palette. */
.floating-whatsapp {
  position: fixed;
  right: var(--wa-right, max(18px, env(safe-area-inset-right, 0px)));
  bottom: var(--wa-bottom, max(18px, env(safe-area-inset-bottom, 0px)));
  z-index: 45;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  background: var(--black);
  color: #fff;
  box-shadow: 0 8px 24px #0004;
  transition: transform .2s ease, box-shadow .2s ease, opacity .65s ease;
}

.floating-whatsapp svg {
  display: block;
  width: 25px;
  height: 25px;
}

.floating-whatsapp:focus-visible {
  outline: 3px solid var(--gold-light);
  outline-offset: 4px;
}

/* The logo link previously spanned the whole row despite its smaller image. */
.footer-brand > a {
  display: block;
  width: fit-content;
  max-width: 100%;
}

@media (hover: hover) and (pointer: fine) {
  .floating-whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 11px 28px #0005;
  }
}

/* Keep the earlier mobile phone shortcut, stacked above WhatsApp by default. */
@media (max-width: 700px) {
  .floating-call {
    right: var(--call-right, max(18px, env(safe-area-inset-right, 0px)));
    bottom: var(--call-bottom, calc(max(18px, env(safe-area-inset-bottom, 0px)) + 64px));
  }

  /* Without script, reserve the fixed-button rail alongside footer links. */
  html:not(.js) .footer > .shell {
    padding-right: calc(64px + env(safe-area-inset-right, 0px));
  }
}

/* Keep both shortcuts usable when a landscape viewport is too short to
   position them above and below full-width links or the form submit button. */
@media (max-width: 700px) and (max-height: 340px) {
  .footer > .shell {
    padding-right: calc(64px + env(safe-area-inset-right, 0px));
  }

  .form-wrap {
    padding-right: calc(74px + env(safe-area-inset-right, 0px));
  }
}

/* Maintain the existing logo-only and image-only opening stages. */
.opening-staging .floating-whatsapp {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.footer-service-area {
  margin: 12px 0 0;
  color: var(--white);
  font-size: 11px;
  line-height: 1.7;
}

@media (prefers-reduced-motion: reduce) {
  .floating-whatsapp { transition: none; }
}
