/* =========================================================
   DZ FULL DESKTOP HEADER STICKY V4.1.4
   Sticky unit = header-top + header-middle + header-main
   ========================================================= */

@media (min-width: 1200px) {
    /*
     * Make the WHOLE desktop header sticky as one unit.
     * Sticky keeps its normal document space, so the page does not jump.
     */
    .header {
        position: sticky !important;
        position: -webkit-sticky !important;
        top: 0 !important;
        inset-block-start: 0 !important;
        z-index: 1035 !important;
        overflow: visible !important;
        width: 100%;
        background: var(--dz-header-bg, #fff);
        box-shadow: 0 7px 22px rgba(15, 23, 42, .055);
    }

    /*
     * The original theme puts love-sticky only on header-main.
     * Disable child-only fixed/sticky positioning on desktop so the nav
     * cannot detach from logo/search/top strip. The PARENT .header now
     * performs the sticky behavior.
     */
    .header .header-main,
    .header .header-main.love-sticky,
    .header .header-main.love-sticky.fixed,
    .header .header-main.love-sticky.active,
    .header .header-main.fixed,
    .header .header-main.sticky,
    .header .header-main.fixed-top {
        position: relative !important;
        top: auto !important;
        bottom: auto !important;
        inset-block-start: auto !important;
        inset-block-end: auto !important;
        left: auto !important;
        right: auto !important;
        inset-inline-start: auto !important;
        inset-inline-end: auto !important;
        width: 100% !important;
        max-width: none !important;
        transform: none !important;
        margin: 0 !important;
        z-index: 3 !important;
    }

    /* All header rows remain part of one stacking context. */
    .header .header-top {
        position: relative !important;
        z-index: 1 !important;
        overflow: visible !important;
    }

    .header .header-middle {
        position: relative !important;
        z-index: 2 !important;
        overflow: visible !important;
    }

    .header .header-main {
        overflow: visible !important;
    }

    .header .header-main > .container,
    .header .header-main > .container > .d-flex,
    .header .header-main .nav-wrapper,
    .header .header-main .dropdown,
    .header .header-main .main-menu,
    .header .header-main .main-menu > li {
        overflow: visible !important;
    }

    /* Keep all category/search/account dropdowns above page content. */
    .header .dropdown-menu,
    .header .dropdown-menu.show,
    .header .dropdown--menu,
    .header .dropdown--menu .sub-menu,
    .header .main-menu .sub-menu,
    .header .main-menu .megamenu,
    .header .search-result-box {
        z-index: 1220 !important;
    }
}

/* Dark mode keeps the complete sticky block opaque/readable. */
[theme="dark"] .header {
    background: var(--dz-header-bg, #141414);
}
