/* Global AI sales chatbot: mobile viewport and floating-widget compatibility. */
@media (max-width: 600px) {
    .aichat-widget.is-maximized {
        top: max(8px, env(safe-area-inset-top)) !important;
        right: 8px !important;
        bottom: max(8px, env(safe-area-inset-bottom)) !important;
        left: 8px !important;
        width: auto !important;
        height: auto !important;
        max-width: none !important;
        max-height: none !important;
    }

    .aichat-widget.is-maximized .aichat-inner {
        width: 100% !important;
        height: 100% !important;
        max-height: 100% !important;
    }

    /*
     * WhatsApp normally has a higher z-index than the chatbot. Hide it only
     * while the chatbot is maximized so it cannot cover the message input or
     * Send button. It returns as soon as the chatbot is minimized or closed.
     */
    body:has(.aichat-widget.is-maximized) .whatsapp-sticky-btn {
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}
