/* MetaBIMLab mobile navigation reliability patch.
 * Keeps the header available at the current scroll position and avoids
 * mobile-browser scroll jumps when opening the navigation drawer.
 */
@media (max-width: 760px) {
    body {
        padding-top: 72px;
    }

    body.nav-open {
        overflow: auto;
    }

    .site-header {
        position: fixed;
        top: 0;
        right: 0;
        left: 0;
        width: 100%;
        z-index: 1000;
    }

    body.admin-bar .site-header {
        top: 46px;
    }

    .site-nav {
        position: fixed;
        top: 72px;
        right: 14px;
        left: 14px;
        z-index: 1001;
        max-height: calc(100dvh - 92px);
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    body.admin-bar .site-nav {
        top: 118px;
        max-height: calc(100dvh - 138px);
    }
}

@media (max-width: 600px) {
    body.admin-bar .site-header {
        top: 46px;
    }
}
