/* Keep the site's controls clear of the hosting badge's 64px bottom strip. */
:root {
    --buyer-edge-clearance: max(76px, calc(env(safe-area-inset-bottom, 0px) + 12px));
    scroll-padding-bottom: var(--buyer-edge-clearance);
}

.buyer-contact {
    bottom: var(--buyer-edge-clearance);
}

#quoteSidebar > div > div:last-child,
#mobileQuoteSheet > div > div:last-child,
#mobileFilterModal > div:last-child {
    padding-bottom: var(--buyer-edge-clearance);
}

#mobileQuoteSheet {
    padding-bottom: 0;
}

@media (max-width: 767px) {
    /* The contact button fits to the left of the badge on narrow phones. */
    a.buyer-contact {
        left: 1rem;
        right: auto;
        bottom: max(1rem, env(safe-area-inset-bottom, 0px));
    }

    body {
        padding-bottom: var(--buyer-edge-clearance);
    }

    html.quote-page {
        --quote-control-space: calc(var(--buyer-edge-clearance) + 7rem);
        scroll-padding-bottom: var(--quote-control-space);
    }

    .quote-page body {
        padding-bottom: var(--quote-control-space);
    }

    #mobile-sticky-actions {
        padding-bottom: var(--buyer-edge-clearance);
    }
}
