
.menu-height {
    height: 20rem;
}

.portfolio {
    background: #ffcc00;
    padding: 20rem 0;
}

.portfolio p {
    font-size: 2.1rem;
    font-weight: 300;
    line-height: 1.65em;
    margin-bottom: 4rem;
}

.portfolio p:last-child {
    margin-bottom: 0rem;
}

.portfolio .text {
    width: 60%;
}


.list {
    background: #f1f1f0;
    padding: 0 0 40rem;
}

.list .filters {
    color: #000000;
    padding: 8rem 0 6rem;
    font-size: 2.1rem;
    line-height: 1.65em;
    font-weight: 300;
}

.list .filters button {
    margin-left: 3rem;
}

.list .filters button.active {
    font-weight: 500;
}

@keyframes listGridItem {
    0% { opacity: 0; transform: translateY(20%); }
    100% { opacity: 1; transform: translateY(0%); }
}

.list .grid-item,
.list .grid-sizer {
    width: calc(66.6666% - 5px);
    height: 70rem;
    margin: 0 0 10px;
    display: block;
    opacity: 0;
    animation: listGridItem 0.4s forwards ease-out;
    background: rgba(0,0,0, 0.05);
}

.list .grid-item:nth-child(2) { animation-delay: 0.1s }
.list .grid-item:nth-child(3) { animation-delay: 0.2s }
.list .grid-item:nth-child(4) { animation-delay: 0.3s }
.list .grid-item:nth-child(5) { animation-delay: 0.4s }
.list .grid-item:nth-child(6) { animation-delay: 0.5s }

.list .grid-item--width1 { width: calc(33.3333% - 5px); }
.list .grid-item--width2 { width: 100%; }

.list .project img {
    object-position: center bottom;
}

.modal {
    z-index: 100;

    opacity: 0;
    display: flex;
    justify-content: center;
    transition: 0.3s ease-out;
    pointer-events: none;

    top: 0;
    left: 0;
    right: 0;
    bottom: 0;

    overflow: auto;
    position: fixed;

    background: rgba(255,255,255,0.9);
}

.modal h3 {
    font-size: 3.6rem;
    font-weight: 500;
    line-height: 4rem;
    letter-spacing: 0.1em;
}

.modal .text {
    margin: 3rem 0;
    display: flex;

    font-size: 2.1rem;
    font-weight: 300;
    line-height: 1.65em;

    flex-direction: column;
}

.modal .text b.projects {
    display: block;
    margin-top: 4rem;
    font-size: 2.1rem;
    line-height: 1.65em;
    text-transform: none;
}

.modal .text span.chip {
    display: block;
    margin-top: auto;
    font-size: 1.8rem;
    font-weight: 500;
    text-transform: uppercase;
}

.modal .gallery {
    width: 62%;
    background: black;
}

.modal .gallery .splide,
.modal .gallery .splide__track {
    height: 100%;
}

.modal .gallery .splide__list img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.modal .gallery .splide__arrows {
    left: 1rem;
    right: 1rem;
}

.modal .gallery .splide__pagination {
    left: 50%;
    bottom: 2rem;
    transform: translateX(-50%);
}

.modal .details {
    display: flex;
    padding: 4rem;
    flex-direction: column;
}

.modal .window {
    width: 100%;

    margin: auto 0;
    max-width: 140rem;
    min-height: 88rem;

    opacity: 0;
    transition: 0.3s ease-out;
    transform: translate(0%,10%);

    background: #ffcc00;
}

.modal .window > [grow][shrink] {
    display: flex;
}

.modal .window > button {
    top: 4rem;
    right: 1rem;
    width: 4rem;
    height: 4rem;
    z-index: 2;
    position: absolute;
}

.modal .window > button svg {
    width: 100%;
    height: auto;
}

.modal .window > button svg path {
    fill: #000000 !important;
}

.modal.visible {
    opacity: 1;
    pointer-events: auto;
}

.modal.visible .window {
    opacity: 1;
    transform: translate(0%,0%);
}


/* hovers ********************************************************************/

@media (any-hover: hover) {

}


/* responsive *****************************************************************/

@media (min-width: 1160px) {
    .modal .text {
        overflow: auto;
        padding-right: 4rem;
    }

    .modal .details {
        padding-right: 0;
    }

    .modal.visible .window {
        max-height: 90%;
    }
}

@media (max-width: 1160px) {


    .portfolio {
        padding: 10rem 0;
    }

    .portfolio .text {
        width: 100%;
    }

    .list {
        padding-bottom: 15rem;
    }

    .list .filters {
        flex-wrap: wrap;
    }

    .list .filters span {
        width: 100%;
        display: block;
        margin-bottom: 1rem;
    }

    .list .filters button {
        width: 50%;
        text-align: left;
        line-height: 5rem;
        margin-left: 0;
    }


    .list .grid-item, .list .grid-sizer {
        height: 30rem;
        width: calc(50% - 5px);
    }

    .list .grid-item--width1 { width: calc(50% - 5px); }
    .list .grid-item--width2 { width: 100%; }

    .list .project .label {
        top: auto;
        opacity: 1;
        display: block;
        font-size: 2rem;
        text-align: left;
        padding: 2rem 15px;
    }

    .list .project .label div {
        white-space: normal;
    }

    .list .project .label div .for-display {
        display: none;
    }


    .modal h3 {
        font-size: 3rem;
    }

    .modal .gallery {
        width: 100%;
        height: 50rem;
    }

    .modal .window {
        flex-wrap: wrap;
        min-height: 100vh;
        max-height: none;
    }

    .modal .text span.chip {
        margin-top: 0;
    }

    .modal .window > button {
        top: 1rem;
    }

    .modal .window > button svg path {
        fill: #ffffff !important;
    }

}
