/*
 * CaliGo Movers unified desktop header v1.5.3
 * One header geometry for the homepage, pages, archives, singles and 404.
 * Desktop navigation is locked to the visual center of the viewport.
 */

@media (min-width: 901px) {
    body .caligo-header {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        left: auto !important;
        z-index: 10000 !important;
        width: calc(100% - 20px) !important;
        max-width: none !important;
        min-height: 60px !important;
        height: 60px !important;
        margin: 10px 10px 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        transform: none !important;
        background: rgba(3, 15, 31, 0.84) !important;
        border: 1px solid rgba(72, 121, 184, 0.25) !important;
        border-radius: 11px !important;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.20), inset 0 1px 0 rgba(255, 255, 255, 0.025) !important;
        backdrop-filter: blur(16px) saturate(120%) !important;
        -webkit-backdrop-filter: blur(16px) saturate(120%) !important;
    }

    /* On the homepage the approved header remains over the hero. */
    body.home .caligo-header,
    body.page-template-front-page .caligo-header {
        position: absolute !important;
        top: 10px !important;
        right: 10px !important;
        left: 10px !important;
        width: auto !important;
        margin: 0 !important;
    }

    body.admin-bar.home .caligo-header,
    body.admin-bar.page-template-front-page .caligo-header {
        top: 42px !important;
    }

    body .caligo-header.is-sticky-fixed,
    body.home .caligo-header.is-sticky-fixed,
    body.page-template-front-page .caligo-header.is-sticky-fixed {
        position: fixed !important;
        top: 10px !important;
        right: 10px !important;
        left: 10px !important;
        width: auto !important;
        margin: 0 !important;
    }

    body.admin-bar .caligo-header.is-sticky-fixed,
    body.admin-bar.home .caligo-header.is-sticky-fixed,
    body.admin-bar.page-template-front-page .caligo-header.is-sticky-fixed {
        top: 42px !important;
    }

    body .caligo-header__container,
    body.home .caligo-header__container,
    body.page-template-front-page .caligo-header__container {
        position: relative !important;
        display: grid !important;
        grid-template-columns: 132px minmax(0, 1fr) 356px !important;
        align-items: center !important;
        width: 100% !important;
        max-width: none !important;
        min-height: 58px !important;
        height: 58px !important;
        margin: 0 !important;
        padding: 0 14px !important;
        gap: 14px !important;
    }

    body .caligo-header__brand {
        position: relative !important;
        z-index: 3 !important;
        min-width: 0 !important;
        width: 132px !important;
        margin: 0 !important;
    }

    body .caligo-header__logo {
        display: inline-flex !important;
        align-items: center !important;
        height: 48px !important;
    }

    body .caligo-header__logo .site-logo-image,
    body.home .caligo-header__logo .site-logo-image {
        display: block !important;
        width: auto !important;
        max-width: 122px !important;
        max-height: 42px !important;
        margin: 0 !important;
        object-fit: contain !important;
    }

    /* Absolute centering prevents logo and CTA widths from shifting the menu. */
    body .caligo-header__nav {
        position: absolute !important;
        top: 50% !important;
        left: 50% !important;
        z-index: 4 !important;
        display: block !important;
        order: initial !important;
        grid-column: auto !important;
        width: max-content !important;
        max-width: calc(100% - 650px) !important;
        min-width: 0 !important;
        margin: 0 !important;
        transform: translate(-50%, -50%) !important;
    }

    body .caligo-header__menu,
    body .caligo-header__menu.collapse,
    body .caligo-header__menu.navbar-collapse {
        position: static !important;
        display: flex !important;
        visibility: visible !important;
        align-items: center !important;
        justify-content: center !important;
        width: auto !important;
        height: auto !important;
        min-height: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        opacity: 1 !important;
    }

    body .caligo-header__menu-list {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        width: max-content !important;
        margin: 0 !important;
        padding: 0 !important;
        gap: 22px !important;
        white-space: nowrap !important;
    }

    body .caligo-header__menu-list > li {
        position: relative !important;
        flex: 0 0 auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    body .caligo-header__nav .nav-link {
        display: inline-flex !important;
        align-items: center !important;
        min-height: 38px !important;
        margin: 0 !important;
        padding: 9px 2px !important;
        font-size: 11px !important;
        font-weight: 700 !important;
        line-height: 1 !important;
        white-space: nowrap !important;
    }

    body .caligo-header__nav .nav-link::after {
        right: 2px !important;
        bottom: 3px !important;
        left: 2px !important;
    }

    body .caligo-header__nav .dropdown-menu {
        top: calc(100% + 9px) !important;
        z-index: 10020 !important;
        min-width: 190px !important;
        margin: 0 !important;
    }

    body .caligo-header__actions {
        position: relative !important;
        z-index: 3 !important;
        display: flex !important;
        grid-column: 3 !important;
        align-items: center !important;
        justify-content: flex-end !important;
        justify-self: end !important;
        width: 356px !important;
        margin: 0 !important;
        gap: 14px !important;
        white-space: nowrap !important;
    }

    /* CTA proportions from the approved internal-page reference. */
    body .caligo-header__action,
    body .caligo-header__action--call {
        display: inline-flex !important;
        flex: 0 0 166px !important;
        width: 166px !important;
        min-width: 166px !important;
        max-width: 166px !important;
        min-height: 42px !important;
        height: 42px !important;
        margin: 0 !important;
        padding: 7px 13px !important;
        gap: 9px !important;
        border-radius: 16px !important;
        font-size: 11.5px !important;
        line-height: 1 !important;
    }

    body .caligo-header__action svg {
        flex: 0 0 18px !important;
        width: 18px !important;
        height: 18px !important;
    }

    body .caligo-header__action--call span {
        display: grid !important;
        gap: 1px !important;
        min-width: 0 !important;
        text-align: center !important;
    }

    body .caligo-header__action--call strong {
        font-size: 11.5px !important;
        line-height: 1 !important;
    }

    body .caligo-header__action--call small {
        display: block !important;
        font-size: 8.5px !important;
        font-weight: 700 !important;
        line-height: 1 !important;
        white-space: nowrap !important;
    }

    body .caligo-header__mobile-toggle {
        display: none !important;
    }

    /* The homepage hero starts below the 60px overlay header. */
    body.home .caligo-hero,
    body.page-template-front-page .caligo-hero,
    .caligo-live-homepage .caligo-hero {
        padding-top: 88px !important;
    }
}

/* Keep the desktop layout during browser zoom until a true phone-sized viewport. */
@media (min-width: 901px) and (max-width: 1199px) {
    body .caligo-header__container,
    body.home .caligo-header__container,
    body.page-template-front-page .caligo-header__container {
        grid-template-columns: 112px minmax(0, 1fr) 304px !important;
        padding: 0 10px !important;
        gap: 8px !important;
    }

    body .caligo-header__brand {
        width: 112px !important;
    }

    body .caligo-header__logo .site-logo-image,
    body.home .caligo-header__logo .site-logo-image {
        max-width: 104px !important;
        max-height: 38px !important;
    }

    body .caligo-header__nav {
        max-width: calc(100% - 450px) !important;
    }

    body .caligo-header__menu-list {
        gap: 11px !important;
    }

    body .caligo-header__nav .nav-link {
        padding-inline: 1px !important;
        font-size: 10px !important;
    }

    body .caligo-header__actions {
        width: 304px !important;
        gap: 8px !important;
    }

    body .caligo-header__action,
    body .caligo-header__action--call {
        flex-basis: 148px !important;
        width: 148px !important;
        min-width: 148px !important;
        max-width: 148px !important;
        padding-inline: 10px !important;
        font-size: 10.5px !important;
    }
}

/* Existing collapsible mobile navigation starts only on phone-sized screens. */
@media (max-width: 900px) {
    body .caligo-header,
    body.home .caligo-header,
    body.page-template-front-page .caligo-header {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        left: auto !important;
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        margin: 0 !important;
        border-radius: 0 !important;
    }

    body.home .caligo-hero,
    body.page-template-front-page .caligo-hero,
    .caligo-live-homepage .caligo-hero {
        padding-top: 26px !important;
    }
}
