/*
 *
 * HEADER / SIDEBAR STYLING
 *
 */

header {
    z-index: 100;
}

li.active {
    transform: translateX(8px);
    color: var(--secondary);
}

li.hoverable:hover {
    transform: translateX(8px);
    color: var(--secondary);
}

#press>a:hover {
    color: var(--secondary);
}

#press>a.active {
    color: var(--secondary);
}

#bio>a:hover {
    color: var(--secondary);
}

/*
 *
 * MOBILE MENU
 *
 */

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    z-index: 200;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background-color: var(--primary);
    transition: 0.3s ease;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 260px;
    height: 100%;
    background-color: whitesmoke;
    z-index: 500;
    padding: 50px 30px 30px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.mobile-menu nav {
    flex: 1;
}

.mobile-menu-contact {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mobile-menu-contact h5 {
    display: flex;
    justify-content: space-between;
}

.mobile-menu.open {
    transform: translateX(0);
}

.mobile-menu .nav-flex-item {
    margin-top: 10px;
}

.mobile-menu ol {
    padding-left: 15px;
    font-weight: 700;
}

.mobile-menu li {
    color: #333333;
    text-align: right;
    text-align-last: right;

    margin-bottom: 7px;
    padding-right: 4px;
    padding-top: 3px;

    transition: 0.3s ease;
}

.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 400;
}

.mobile-menu-overlay.open {
    display: block;
}

.mobile-menu-close {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 22px;
    position: absolute;
    top: 18px;
    right: 22px;
    color: var(--primary);
    line-height: 1;
}

/*
 *
 * SMALL SCREENS
 *
 */
@media screen and (max-width: 950px) {
    header {
        background-color: whitesmoke;

        padding: 25px 25px 10px;
    }

    .header-flex-container {
        display: flex;
        flex-flow: row nowrap;
        align-items: flex-start;
        justify-content: space-between;
    }

    .menu-toggle {
        display: flex;
    }

    .header-flex-item:nth-child(2) {
        width: 0;
        height: 0;
        display: none;
    }

    .header-flex-item:nth-child(3) {
        width: 0;
        height: 0;
        display: none;
    }

    .header-flex-item:nth-child(4) {
        width: 0;
        height: 0;
        display: none;
    }

    .sub-header-flex-container {
        display: flex;
        flex-flow: column nowrap;
        align-items: stretch;
    }

    .sub-header-flex-item {
        color: var(--primary);
        text-align: justify;
        text-align-last: justify;
    }

    #title {
        width: 160px;
    }

    #title a {
        display: flex;
        justify-content: space-between;
    }

    #title a img {
        max-width: 100%;
        height: auto;
        display: block;
    }

    #subtitle {
        display: inline;
        font-weight: 500;

        width: 160px;
    }
}

/*
 *
 * MEDIUM/LARGE SCREENS
 *
 */

@media screen and (min-width: 951px) {
    header {
        background-color: whitesmoke;

        position: fixed;
        width: 200px;
        padding-top: 25px;
        padding-bottom: 25px;
        padding-left: 50px;

        min-height: 320px;
        height: 100%;
    }

    .header-flex-container {
        display: flex;
        flex-flow: column nowrap;

        justify-content: space-around;
    }

    .header-flex-item {
        padding-top: 15px;
        padding-bottom: 15px;
    }

    .sub-header-flex-container {
        display: flex;
        flex-flow: column nowrap;
        align-items: stretch;
    }

    .sub-header-flex-item {
        color: var(--primary);
        text-align: justify;
        text-align-last: justify;

        display: flex;
        justify-content: space-between;
    }

    .sub-header-flex-container:last-child {
        row-gap: 5px;
    }

    .sub-header-flex-container:last-child > .sub-header-flex-item {
        color: var(--secondary);
    }

    .sub-header-flex-container:last-child > .sub-header-flex-item > a {
        color: var(--primary);
    }

    #title a {
        min-width: 100%;
        display: flex;
        justify-content: space-between;
    }

    #title a img {
        max-width: 100%;
        height: auto;
        display: block;
    }

    #subtitle {
        display: inline;
        font-weight: 500;
    }

    /* NAV STYLING */
    .nav-flex-container {
        display: flex;
        flex-flow: column nowrap;
        justify-content: space-evenly;
    }

    .nav-flex-item {
        margin-top: 5px;
        margin-bottom: 5px;
    }

    ol {
        padding-left: 15px;
        font-weight: 700;
    }

    li {
        color: #333333;
        text-align: right;
        text-align-last: right;

        margin-bottom: 4px;
        padding-right: 4px;
        padding-top: 2px;

        transition: 0.3s ease;
    }
}
