/* ====================================
Navigation 
==================================== */

.overlay-navigation {
    position: fixed;
    z-index: 199;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: hsla(0, 0%, 100%, 0.2);
    display: none;
    opacity: 0;
}

nav, nav .parts {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}

    nav .parts {
        display: -webkit-box;
        display: -webkit-flex;
        display: -ms-flexbox;
        display: flex;
        list-style: none;
    }

        nav .parts li {
            -webkit-flex-basis: 20%;
            -ms-flex-preferred-size: 20%;
            flex-basis: 20%;
            -webkit-box-pack: center;
            -webkit-justify-content: center;
            -ms-flex-pack: center;
            justify-content: center;
            -webkit-box-align: center;
            -webkit-align-items: center;
            -ms-flex-align: center;
            align-items: center;
            height: 100%;
            overflow: hidden;
            opacity: 0;
            display: none;
            background-position: center;
            background-size: cover;
            transition: flex-basis .8s ease;
            border: 3px solid white;
        }

.overlay-navigation.finished nav .parts li:hover {
    flex-basis: 40%;
}


nav .parts li:nth-of-type(1) {
    /*background-color: #29363B;*/
        background-color: #cb9765;

}

nav .parts li:nth-of-type(2) {
    background-color: #cb9765;
}

nav .parts li:nth-of-type(3) {
    /*background-color: #F4837D;*/
    background-color: #cb9765;
}

nav .parts li:nth-of-type(4) {
    /*background-color: #FDCEA9;*/
    background-color: #cb9765;
}

nav .parts li:nth-of-type(5) {
    background-color: #99B998;
}

nav .content {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    flex-direction: column;
}

nav .title {
    position:relative;
    color: #fff;
    font-weight: 900;
    display: block;
    text-align: center;
    font-size: 42px;
    text-shadow: -2px 4px 4px black;
}

    nav .title:before {
        content: attr(data-hover);
        position: absolute;
        height: 100%;
        white-space: nowrap;
        text-align: center;
        overflow: hidden;
        width: 0;
        right: 0;
        color: #cb9765;
        direction: rtl;
        transition: .8s;
    }


    nav .title:hover {
        text-decoration: none;
    }

nav .parts li:hover .title:before {
    width: 100%;
}


nav .title-small {
    color: #fff;
    font-weight: 900;
    display: block;
    text-align: center;
    font-size: 23px;
    text-shadow: -2px 4px 4px black;
}


    nav .title-small:hover {
        text-decoration: none;
        color: #cb9765;
        text-shadow: -2px 4px 8px black;
    }


@media (max-width: 640px) {
    nav .parts {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -webkit-flex-direction: column;
        -ms-flex-direction: column;
        flex-direction: column;
    }

        nav .parts li {
            height: 20%;
        }


    .open-overlay {
        right: 1rem;
    }
}
