/* FINCASLAXE - CONTROLES FLOTANTES V1 */

.flx-floating-actions,
.flx-floating-dialog {
    display: none;
}

@media (max-width: 700px) {

    /*
     * Substitúe o antigo buscador sticky.
     * O buscador orixinal queda na súa
     * posición normal na páxina.
     */

    .flx-search--archive {
        position: static !important;
        top: auto !important;
        max-height: none !important;
    }

    /* Botóns inferiores */

    .flx-floating-actions {
        position: fixed;
        inset: auto 0
            calc(12px + env(safe-area-inset-bottom, 0px))
            0;

        z-index: 1200;
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding-inline: 18px;
        pointer-events: none;
    }

    .flx-float-btn {
        display: grid;
        place-items: center;
        width: 64px;
        height: 64px;
        padding: 0;
        border: 0;
        border-radius: 50%;
        color: #FFFFFF;
        cursor: pointer;
        text-decoration: none;
        pointer-events: auto;
        box-shadow:
            0 5px 18px rgba(15, 45, 70, .20);
    }

    .flx-float-btn svg {
        display: block;
        width: 33px;
        height: 33px;
    }

    /* WhatsApp oficial */

    .flx-float-whatsapp {
        background: #25D366;
        color: #FFFFFF;
    }

    .flx-float-whatsapp svg {
        width: 41px;
        height: 41px;
        fill: currentColor;
    }

    /* Lupa azul vivo */

    .flx-float-search {
        display: none;
        background: #007AC2;
        color: #FFFFFF;
    }

    .flx-float-search.flx-float-visible {
        display: grid;
    }

    .flx-float-btn:focus-visible {
        outline: 3px solid #172D3C;
        outline-offset: 4px;
    }

    /* Buscador flotante */

    .flx-floating-dialog[open] {
        display: block;
        box-sizing: border-box;
        position: fixed;

        inset: auto 14px
            calc(90px + env(safe-area-inset-bottom, 0px))
            14px;

        width: min(460px, calc(100vw - 28px));
        max-width: none;
        max-height: calc(100dvh - 125px);

        margin: 0 auto;
        padding: 22px;

        overflow-y: auto;
        overscroll-behavior: contain;

        border: 1px solid #DCE7EF;
        border-radius: 17px;
        background: #FFFFFF;
        color: #172D3C;

        box-shadow:
            0 15px 55px rgba(10, 35, 60, .25);
    }

    .flx-floating-dialog::backdrop {
        background: rgba(10, 25, 40, .46);
    }

    .flx-floating-heading {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
        margin-bottom: 20px;
    }

    .flx-floating-heading h2 {
        margin: 0;
        font-size: 21px;
        font-weight: 750;
        line-height: 1.3;
    }

    .flx-floating-close {
        display: grid;
        place-items: center;
        width: 40px;
        height: 40px;
        border: 0;
        border-radius: 9px;
        background: #EDF3F7;
        color: #172D3C;
        font-size: 19px;
        cursor: pointer;
    }

    .flx-floating-form {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 9px;
    }

    .flx-floating-form label {
        margin-top: 5px;
        font-size: 14px;
        font-weight: 700;
        line-height: 1.4;
    }

    .flx-floating-form select,
    .flx-floating-form input {
        box-sizing: border-box;
        display: block;
        width: 100%;
        min-width: 0;
        min-height: 47px;
        padding: 0 13px;

        border: 1px solid #D3E0E8;
        border-radius: 9px;
        background: #FFFFFF;
        color: #172D3C;

        font-family: inherit;
        font-size: 16px;
    }

    .flx-floating-submit {
        min-height: 49px;
        margin-top: 13px;
        border: 0;
        border-radius: 11px;
        background: #007AC2;
        color: #FFFFFF;
        font-family: inherit;
        font-size: 15px;
        font-weight: 750;
        cursor: pointer;
    }

    .flx-floating-submit:hover {
        background: #0067A5;
        color: #FFFFFF;
    }
}
