/*
|--------------------------------------------------------------------------
| CGEI Header
|--------------------------------------------------------------------------
| The navigation strip and shared hero use the same outer shell width.
| Navigation cells are compact, content-proportional and right-aligned.
|--------------------------------------------------------------------------
*/

.ceig-site-header {
    position: relative;
    z-index: 1000;

    width: 100%;
    margin: 0;
    padding: 0;

    background: #ffffff;

    border-bottom: 1px solid #d8dde6;
}

.ceig-site-header,
.ceig-site-header * {
    box-sizing: border-box;
}

/*
|--------------------------------------------------------------------------
| Shared Header Shell
|--------------------------------------------------------------------------
| This matches the shared hero width exactly.
|--------------------------------------------------------------------------
*/

.ceig-header-container {
    width: calc(100% - 40px);
    max-width: calc(var(--content-width) - 40px);

    margin-right: auto;
    margin-left: auto;

    padding: 9px 0 0;
}

/*
|--------------------------------------------------------------------------
| Navigation Column
|--------------------------------------------------------------------------
*/

.ceig-navigation-column {
    display: block;

    width: 100%;

    margin: 0;
    padding: 0;
}

/*
|--------------------------------------------------------------------------
| Navigation Strip
|--------------------------------------------------------------------------
| The dark-blue strip retains its full width.
|--------------------------------------------------------------------------
*/

.ceig-navigation-row {
    position: relative;

    display: block;

    width: 100%;

    margin: 0;
    padding: 0;

    overflow: hidden;

    background: #00163e;

    border: 1px solid #00163e;
    border-radius: 3px;

    box-shadow: 0 4px 12px rgba(0, 22, 62, 0.12);
}

/*
|--------------------------------------------------------------------------
| Primary Navigation
|--------------------------------------------------------------------------
*/

.ceig-primary-navigation {
    position: relative;

    display: block;

    width: 100%;

    margin: 0;
    padding: 0;

    background: #00163e;

    border: 0;
}

/*
|--------------------------------------------------------------------------
| Navigation List
|--------------------------------------------------------------------------
| The menu cells align to the right. Any unused portion of the full-width
| dark-blue strip remains visible on the left.
|--------------------------------------------------------------------------
*/

.ceig-navigation-list {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: flex-end;

    width: 100%;

    margin: 0;
    padding: 0;

    list-style: none;
}

/*
|--------------------------------------------------------------------------
| Individual Navigation Cells
|--------------------------------------------------------------------------
| Each cell uses only the width required by its label and padding.
|--------------------------------------------------------------------------
*/

.ceig-navigation-item {
    position: relative;

    display: flex;
    flex: 0 0 auto;

    align-items: stretch;

    width: auto;
    min-width: 0;

    margin: 0;
    padding: 0;

    border-right: 1px solid rgba(255, 255, 255, 0.48);
}

.ceig-navigation-item:last-child {
    border-right: 0;
}

/*
|--------------------------------------------------------------------------
| Navigation Links
|--------------------------------------------------------------------------
*/

.ceig-navigation-link {
    position: relative;

    display: flex;

    align-items: center;
    justify-content: center;

    width: auto;

    min-width: max-content;
    min-height: 50px;

    margin: 0;
    padding: 9px 7px;

    color: #ffffff;

    font-family: Georgia, "Times New Roman", serif;
    font-size: 12pt !important;
    font-weight: 700;
    line-height: 1.25;

    text-align: center;
    text-decoration: none;

    white-space: nowrap;

    background: transparent;

    border: 0;

    visibility: visible;
    opacity: 1;

    transition:
        color 0.2s ease,
        background-color 0.2s ease;
}

/*
|--------------------------------------------------------------------------
| Current and Hover States
|--------------------------------------------------------------------------
*/

.ceig-navigation-link::after {
    position: absolute;

    right: 5px;
    bottom: 4px;
    left: 5px;

    height: 2px;

    background: transparent;

    content: "";
}

.ceig-navigation-link:hover,
.ceig-navigation-link:focus-visible,
.ceig-navigation-link-current {
    color: #ffffff;

    background: #0b2b59;
}

.ceig-navigation-link:hover::after,
.ceig-navigation-link:focus-visible::after,
.ceig-navigation-link-current::after {
    background: #d4af37;
}

.ceig-navigation-link:focus-visible {
    z-index: 2;

    outline: 2px solid #d4af37;
    outline-offset: -3px;
}

/*
|--------------------------------------------------------------------------
| Mobile Menu Button
|--------------------------------------------------------------------------
*/

.ceig-menu-toggle {
    display: none;

    width: 44px;
    height: 44px;

    margin: 0;
    padding: 9px;

    background: #00163e;

    border: 1px solid #00163e;
    border-radius: 3px;

    cursor: pointer;
}

.ceig-menu-toggle span {
    display: block;

    width: 100%;
    height: 2px;

    margin: 5px 0;

    background: #ffffff;

    transition:
        transform 0.2s ease,
        opacity 0.2s ease;
}

.ceig-menu-toggle-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.ceig-menu-toggle-open span:nth-child(2) {
    opacity: 0;
}

.ceig-menu-toggle-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/*
|--------------------------------------------------------------------------
| Medium Desktop
|--------------------------------------------------------------------------
| Padding reduces slightly before the mobile navigation becomes active.
|--------------------------------------------------------------------------
*/

@media (min-width: 1181px) and (max-width: 1350px) {

    .ceig-navigation-link {
        padding-right: 5px;
        padding-left: 5px;

        font-size: 12pt !important;
    }
}

/*
|--------------------------------------------------------------------------
| Mobile and Compact Navigation
|--------------------------------------------------------------------------
*/

@media (max-width: 1180px) {

    .ceig-header-container {
        width: calc(100% - 40px);

        padding-top: 7px;
    }

    .ceig-navigation-row {
        display: flex;
        flex-direction: column;

        align-items: center;

        width: 100%;

        overflow: visible;

        background: transparent;

        border: 0;
        border-radius: 0;

        box-shadow: none;
    }

    .ceig-menu-toggle {
        display: block;
    }

    .ceig-primary-navigation {
        display: none;

        width: 100%;

        margin: 6px 0 0;
        padding: 0;

        overflow: hidden;

        background: #00163e;

        border: 1px solid #00163e;
        border-radius: 3px;

        box-shadow: 0 8px 20px rgba(0, 22, 62, 0.16);
    }

    .ceig-primary-navigation-open {
        display: block;
    }

    .ceig-navigation-list {
        display: grid;

        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        width: 100%;
    }

    .ceig-navigation-item {
        width: 100%;

        border-right: 1px solid rgba(255, 255, 255, 0.48);
        border-bottom: 1px solid rgba(255, 255, 255, 0.48);
    }

    .ceig-navigation-item:nth-child(2n) {
        border-right: 0;
    }

    .ceig-navigation-link {
        justify-content: center;

        width: 100%;

        min-width: 0;
        min-height: 48px;

        padding: 11px 14px;

        font-size: 12pt !important;

        text-align: center;

        white-space: normal;
    }

}

/*
|--------------------------------------------------------------------------
| Mobile Shell Alignment
|--------------------------------------------------------------------------
| Matches the shared hero mobile width exactly.
|--------------------------------------------------------------------------
*/

@media (max-width: 700px) {

    .ceig-header-container {
        width: calc(100% - 28px);

        margin-right: 14px;
        margin-left: 14px;
    }
}

/*
|--------------------------------------------------------------------------
| Small Mobile Screens
|--------------------------------------------------------------------------
*/

@media (max-width: 520px) {

    .ceig-menu-toggle {
        width: 44px;
        height: 44px;

        padding: 9px;
    }

    .ceig-navigation-list {
        grid-template-columns: 1fr;
    }

    .ceig-navigation-item,
    .ceig-navigation-item:nth-child(2n) {
        border-right: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.48);
    }

    .ceig-navigation-item:last-child {
        border-bottom: 0;
    }

}

/* World Stature is visible but has no destination until its page launches. */
.ceig-navigation-link-disabled {
    cursor: default;
    pointer-events: none;
}
.ceig-navigation-link-disabled::after {
    background: transparent;
}
