/* ==========================================================================
   COMPACT HEADER PO SCROLLU — CZYSTA WERSJA
   ========================================================================== */

@media (min-width: 1200px) {

    /* ======================================================================
       HEADER I BELKA
       ====================================================================== */

    #header.header--compact {
        position: relative;
        z-index: 10050 !important;
    }

    #header.header--compact .header-bottom {
        min-height: 76px !important;
        padding: 6px 28px !important;

        background: transparent !important;
        overflow: visible !important;
    }

    #header.header--compact .header-bottom__container {
        background: transparent !important;
        overflow: visible !important;
    }

    #header.header--compact .header-bottom__row {
        top: 6px !important;

        display: flex !important;
        align-items: center !important;
        flex-wrap: nowrap !important;

        height: 64px !important;
        min-height: 64px !important;

        margin: 0 !important;
        padding: 0 16px 0 14px !important;

        /*
         * Pełne białe tło.
         * Bez rgba i bez blur, żeby banner nie prześwitywał.
         */
        background: #fff !important;
        background-color: #fff !important;

        border: 1px solid rgba(30, 80, 145, .08) !important;
        border-radius: 34px !important;

        box-shadow: 0 7px 24px rgba(18, 42, 69, .1) !important;

        opacity: 1 !important;

        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;

        overflow: visible !important;
        isolation: isolate;
    }


    /* ======================================================================
       LOGO
       ====================================================================== */

    #header.header--compact .header-bottom__logo,
    #header.header--compact #_desktop_logo {
        align-self: stretch !important;

        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;

        flex: 0 0 210px !important;

        width: 210px !important;
        min-width: 210px !important;
        max-width: 210px !important;
        height: 64px !important;

        margin: 0 20px 0 0 !important;
        padding: 0 !important;

        transform: none !important;
    }

    #header.header--compact #_desktop_logo a,
    #header.header--compact .header-bottom__logo a {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;

        width: 100% !important;
        height: 64px !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    #header.header--compact #_desktop_logo img,
    #header.header--compact .header-bottom__logo img {
        display: block !important;

        width: auto !important;
        max-width: 195px !important;

        height: auto !important;
        max-height: 48px !important;

        margin: 0 !important;
        padding: 0 !important;

        object-fit: contain;
        object-position: left center;

        transform: none !important;
    }


    /* ======================================================================
       MENU
       ====================================================================== */

    #header.header--compact .ps-mainmenu--desktop {
        align-self: stretch !important;

        display: flex !important;
        align-items: center !important;

        flex: 1 1 auto !important;

        min-width: 0 !important;
        height: 64px !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    #header.header--compact .ps-mainmenu__desktop {
        display: flex !important;
        align-items: center !important;

        width: 100% !important;
        height: 64px !important;
    }

    #header.header--compact #top-menu {
        display: flex !important;
        align-items: center !important;
        flex-wrap: nowrap !important;

        width: 100% !important;
        height: 64px !important;

        gap: 20px !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    #header.header--compact #top-menu > li {
        display: flex !important;
        align-items: center !important;

        height: 64px !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    #header.header--compact
    #top-menu > li > .ps-mainmenu__tree-item-wrapper,
    #header.header--compact
    #top-menu > li .ps-mainmenu__tree-link {
        display: flex !important;
        align-items: center !important;

        height: 64px !important;
        min-height: 64px !important;

        margin: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;

        font-size: 14px !important;
        white-space: nowrap;
    }


    /* ======================================================================
       ZEWNĘTRZNE KONTENERY IKON

       Każdy kontener ma wysokość belki 64px.
       Kółko wewnątrz ma 40px.
       ====================================================================== */

    #header.header--compact #_desktop_search_widget,
    #header.header--compact #_desktop_ps_searchbar,
    #header.header--compact #_desktop_user_info,
    #header.header--compact #_desktop_ps_customersignin,
    #header.header--compact #_desktop_wishlist,
    #header.header--compact #_desktop_blockwishlist,
    #header.header--compact #_desktop_ps_shoppingcart {
        position: relative !important;

        align-self: stretch !important;

        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        flex: 0 0 40px !important;

        width: 40px !important;
        min-width: 40px !important;
        max-width: 40px !important;

        height: 64px !important;
        min-height: 64px !important;
        max-height: 64px !important;

        margin: 0 0 0 8px !important;
        padding: 0 !important;

        float: none !important;

        overflow: visible !important;
        transform: none !important;
    }


    /* ======================================================================
       WSPÓLNY WYGLĄD KÓŁEK
       ====================================================================== */

    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier,

    #header.header--compact
    #_desktop_user_info .header-block__action-btn,

    #header.header--compact
    #_desktop_user_info .dropdown-toggle,

    #header.header--compact
    #_desktop_ps_customersignin .header-block__action-btn,

    #header.header--compact
    #_desktop_ps_customersignin .dropdown-toggle,

    #header.header--compact
    #_desktop_wishlist .wishlist-button,

    #header.header--compact
    #_desktop_blockwishlist .wishlist-button,

    #header.header--compact
    #_desktop_ps_shoppingcart .cart-preview {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        flex: 0 0 40px !important;

        width: 40px !important;
        min-width: 40px !important;
        max-width: 40px !important;

        height: 40px !important;
        min-height: 40px !important;
        max-height: 40px !important;

        margin: 0 !important;
        padding: 0 !important;

        color: #006cff !important;
        background: #fff !important;

        border: 1px solid #64a1f4 !important;
        border-radius: 50% !important;

        box-shadow: 0 2px 6px rgba(45, 107, 177, .08) !important;

        box-sizing: border-box;
        transform: none !important;
    }


    /* ======================================================================
       WYSZUKIWARKA
       ====================================================================== */

    #header.header--compact #_desktop_ps_searchbar {
        z-index: 100;
    }

    #header.header--compact
    #_desktop_ps_searchbar #ps_searchbar {
        position: absolute !important;

        top: 50% !important;
        right: 0 !important;
        left: auto !important;
        
        width: 40px !important;
        height: 40px !important;

        margin: 0 !important;
        padding: 0 !important;

        transform: translateY(-50%) !important;
    }

    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__form {
        position: relative !important;

        width: 100% !important;
        height: 40px !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier {
        position: absolute !important;

        top: 0 !important;
        right: 0 !important;
        left: auto !important;

        transform: none !important;
    }

    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier:hover,
    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier:focus,
    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier:active {
        width: 40px !important;
        height: 40px !important;

        transform: none !important;
    }

    /* Otwarta wyszukiwarka */

    #header.header--compact
    #_desktop_ps_searchbar.is-search-open #ps_searchbar {
        width: 270px !important;
        min-width: 270px !important;
        max-width: 270px !important;
    }

    #header.header--compact
    #_desktop_ps_searchbar.is-search-open .ps-searchbar__form {
        width: 270px !important;
        min-width: 270px !important;
        max-width: 270px !important;
    }

    #header.header--compact
    #_desktop_ps_searchbar.is-search-open .ps-searchbar__input {
        width: 100% !important;
        height: 40px !important;

        padding-right: 48px !important;
        line-height: 40px !important;
    }


    /* ======================================================================
       IKONA UŻYTKOWNIKA
       ====================================================================== */

    #header.header--compact
    #_desktop_user_info .header-block__title,
    #header.header--compact
    #_desktop_ps_customersignin .header-block__title {
        display: none !important;
    }

    #header.header--compact
    #_desktop_user_info .material-icons,
    #header.header--compact
    #_desktop_user_info .header-block__icon,
    #header.header--compact
    #_desktop_ps_customersignin .material-icons,
    #header.header--compact
    #_desktop_ps_customersignin .header-block__icon {
        position: relative !important;

        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        width: 19px !important;
        min-width: 19px !important;
        height: 19px !important;
        min-height: 19px !important;

        margin: 0 !important;
        padding: 0 !important;

        font-size: 0 !important;
        line-height: 0 !important;

        transform: none !important;
    }

    #header.header--compact
    #_desktop_user_info .material-icons::before,
    #header.header--compact
    #_desktop_user_info .header-block__icon::before,
    #header.header--compact
    #_desktop_ps_customersignin .material-icons::before,
    #header.header--compact
    #_desktop_ps_customersignin .header-block__icon::before {
        position: static !important;

        display: block !important;

        width: 19px !important;
        height: 19px !important;

        margin: 0 !important;

        transform: none !important;
    }


    /* ======================================================================
       KOSZYK
       ====================================================================== */

    #header.header--compact
    #_desktop_ps_shoppingcart .ps-shoppingcart {
        position: relative !important;

        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        width: 40px !important;
        height: 40px !important;

        margin: 0 !important;
        padding: 0 !important;

        overflow: visible !important;
    }

    #header.header--compact
    #_desktop_ps_shoppingcart .cart-preview {
        position: relative !important;

        width: 40px !important;
        min-width: 40px !important;
        height: 40px !important;
        min-height: 40px !important;

        overflow: visible !important;
    }

    /*
     * Link nie może tworzyć własnego drugiego kółka.
     */
    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__action-btn {
        position: relative !important;

        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;

        height: 100% !important;
        min-height: 0 !important;
        max-height: none !important;

        margin: 0 !important;
        padding: 0 !important;

        color: inherit !important;
        background: transparent !important;

        border: 0 !important;
        border-radius: 50% !important;

        box-shadow: none !important;
        transform: none !important;

    }

    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__action-btn:hover,
    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__action-btn:focus,
    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__action-btn:active {
        color: inherit !important;
        background: transparent !important;

        border: 0 !important;
        box-shadow: none !important;
        transform: none !important;
    }

    /* SVG koszyka wewnątrz linku */

    #header.header--compact
    #_desktop_ps_shoppingcart
    .header-block__action-btn::before {
        display: block !important;
        flex: 0 0 19px !important;

        width: 19px !important;
        height: 19px !important;

        margin: 0 !important;
        padding: 0 !important;

        transform: none !important;
    }

    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__title,
    #header.header--compact
    #_desktop_ps_shoppingcart .cart-label,
    #header.header--compact
    #_desktop_ps_shoppingcart .cart-title {
        display: none !important;
    }


    /* ======================================================================
       LICZNIK KOSZYKA
       ====================================================================== */

    #header.header--compact
    #_desktop_ps_shoppingcart .header-block__badge,
    #header.header--compact
    #_desktop_ps_shoppingcart .cart-products-count {
        position: absolute !important;

        top: -5px !important;
        right: -5px !important;
        z-index: 10 !important;

        display: flex !important;
        align-items: center !important;
        justify-content: center !important;

        width: 18px !important;
        min-width: 18px !important;
        height: 18px !important;
        min-height: 18px !important;

        margin: 0 !important;
        padding: 0 !important;

        font-size: 10px !important;
        font-weight: 700 !important;
        line-height: 14px !important;

        color: #fff !important;
        background: #006cff !important;

        border: 2px solid #fff !important;
        border-radius: 50% !important;

        box-sizing: border-box;
    }


    /* ======================================================================
       HOVER
       ====================================================================== */

    #header.header--compact
    #_desktop_ps_searchbar .ps-searchbar__magnifier:hover,

    #header.header--compact
    #_desktop_user_info .header-block__action-btn:hover,

    #header.header--compact
    #_desktop_user_info .dropdown-toggle:hover,

    #header.header--compact
    #_desktop_ps_customersignin .header-block__action-btn:hover,

    #header.header--compact
    #_desktop_ps_customersignin .dropdown-toggle:hover,

    #header.header--compact
    #_desktop_ps_shoppingcart .cart-preview:hover {
        color: #fff !important;
        background: #006cff !important;
        border-color: #006cff !important;

        transform: none !important;
    }


    /* ======================================================================
       MEGA MENU
       ====================================================================== */

    #header.header--compact
    #top-menu > li.ps-mainmenu__tree-item > .submenu {
        top: 64px !important;
    }
}