.archive-annonce {
    margin-top: 0;
    /* opacity: 0; */
    transition: opacity 0.3s ease-in-out;
    z-index: 1;
    position: relative;

    &.is-admin {
        opacity: 1 !important;
    }

    #map {
        height: auto !important;

        .facetwp-type-map {
            height: 100%;

            #facetwp-map {
                position: sticky !important;
                top: 81px;
                margin: 0;
                height: calc(100vh - 81px) !important;

                @media(width < 765px) {
                    height: 450px !important;
                }

                +div {
                    display: none;
                }
            }
        }

    }

    .archive-annonce__loop {
        padding-top: var(--wp--preset--spacing--large);
        padding-bottom: var(--wp--preset--spacing--large);
        max-width: 690px;

        @media(width < 1400px) {
            padding-bottom: 0;
        }


        .archive-annonce__loop_top {
            margin-bottom: 2em;

            @media(width < 991px) {
                position: fixed;
                bottom: 0;
                left: 0;
                right: 0;
                background-color: #fff;
                margin: 0;
                padding: 12px 0;
                z-index: 11;
            }

            .facetwp-facet-compteur_annonce {
                text-align: left;
                font-weight: bold;
                margin: 2em 0 1em;
                font-size: 1.25rem;
                color: var(--wp--preset--color--secondary);
            }

            .views {
                border: solid 1px var(--wp--preset--color--primary);
                padding: 5px;
                border-radius: 5px;

                .switch {
                    border-radius: 5px;
                    border: none;
                    padding: 5px 10px;
                    background-color: transparent;
                    font-weight: 500;
                    font-family: var(--wp--preset--font-family--secondary);

                    &:hover {
                        cursor: pointer;
                    }

                    &.active {
                        background-color: var(--wp--preset--color--primary);
                    }
                }
            }

            .alert,
            .facetwp-type-sort {
                display: inline-block;
                margin: 0;
            }
        }

        .facetwp-type-pager {
            margin: 2em 0 0;
        }
    }
}

/* cache listing annonnces sur mobile */
body.body-listing {
    &.map-view {
        #map {
            @media(width < 1400px) {
                margin-top: 1em;
            }
        }

        #wrap-annonces {
            @media(width < 1400px) {
                margin-top: 1em;
            }
        }
    }

    &:not(.map-view) {
        .archive-annonce {
            margin-left: auto !important;
            margin-right: auto !important;

            .archive-annonce__loop {
                max-width: inherit;
            }
        }
    }
}