/* SITE-WA-ICON: one native floating link, normal document scroll, no viewport rail. */
.floating-whatsapp {
  position: fixed;
  right: calc(16px + env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 30;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  min-width: 52px;
  min-height: 52px;
  box-sizing: border-box;
  padding: 0;
  background: var(--corporate-green, #23a63e);
  color: #fff;
  border: 1px solid #1a7a2e;
  border-radius: 50%;
  text-decoration: none;
  box-shadow: 0 4px 16px #23282e35;
  transition: background-color .15s;
}
.floating-whatsapp:hover { background: #1a7a2e; color: #fff; text-decoration: none; }
.floating-whatsapp:focus-visible { outline: 3px solid #23282e; outline-offset: 4px; box-shadow: 0 0 0 2px #fff, 0 4px 16px #23282e35; }
.floating-whatsapp-icon { display: flex; align-items: center; justify-content: center; flex: 0 0 28px; width: 28px; height: 28px; }
.floating-whatsapp-icon svg { display: block; width: 28px; height: 28px; stroke: currentColor; }
.floating-whatsapp-label { position: absolute; right: 0; bottom: calc(100% + 8px); display: block; width: max-content; max-width: 128px; box-sizing: border-box; padding: 4px 8px; border: 1px solid #dce0df; border-radius: 4px; background: #f5f6f5; color: #23282e; font-size: 14px; font-weight: 400; line-height: 1.3; text-align: center; white-space: normal; overflow-wrap: anywhere; }
@media (max-width: 600px) {
  .floating-whatsapp {
    right: calc(8px + env(safe-area-inset-right, 0px));
    bottom: calc(8px + env(safe-area-inset-bottom, 0px));
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
  .floating-whatsapp-icon { flex-basis: 24px; width: 24px; height: 24px; }
  .floating-whatsapp-icon svg { width: 24px; height: 24px; }
}
body:has(dialog[open]) .floating-whatsapp { visibility: hidden; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .floating-whatsapp { transition: none; } }
@media print { .floating-whatsapp { display: none; } }

@media screen and (max-width: 760px) {
  .vehicle-detail .detail-summary {
    --detail-wa-action-clearance: max(0px, calc(152px + env(safe-area-inset-right, 0px) - 24px));
  }
  .vehicle-detail .detail-summary > .button.full-width {
    width: calc(100% - var(--detail-wa-action-clearance));
    margin-inline-end: var(--detail-wa-action-clearance);
    min-width: 0;
  }
  .vehicle-detail .detail-summary .direct-contact-links {
    padding-inline-end: var(--detail-wa-action-clearance);
  }
}

@media screen and (max-width:600px){
 .vehicle-detail .detail-summary{--detail-wa-action-clearance:max(0px,calc(144px + env(safe-area-inset-right,0px) - 24px));}
}
@media screen and (max-width:480px){
 .vehicle-detail .detail-summary{--detail-wa-action-clearance:max(0px,calc(144px + env(safe-area-inset-right,0px) - 16px));}
}
