.filter {
    display: flex;
    justify-content: space-between;
    width: 500px;
    margin: auto;
    margin-top: 200px;
    position: sticky;
    position: -webkit-sticky;
    top: 70px;;
    z-index: 1;

    & a {
        text-decoration: none;
        text-transform: uppercase;
        color: var(--element-color);
        font-size: var(--font-size-body-small);
        -webkit-filter: blur(0.7px);
        transition: 0.2s;
    }
    
    & a:hover {
        /* border-bottom: 1px solid; */
        -webkit-filter: blur(0px); 
    }
}

@media (min-width: 300px) and (max-width: 768px) {
    /* Styles for screens between 600px and 768px */
    .filter {
       flex-direction: column;
       align-items: center;
       /* z-index: 1; */
       width: 100%;
       margin-top:100px;
    }

    .filter a {
        margin-top: 0.5rem;
    }

    

}


.is-active {
    -webkit-filter: blur(0px) !important;
}

.projects {
    background-color: var(--background-color);
    width: calc(100% - (2 * var(--margin-sides)));
    margin: 0 var(--margin-sides);
    margin-top: 50px;
    margin-bottom: 300px;
    
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--main-gutter);

    & a {
        height: auto;
        overflow: hidden;
        position: relative;
        padding-top: 175%;
    }

}


.project-item {

    flex: 1 1 auto;
    height: 100%;
    max-width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 0;
}

.project-item img {
    object-fit: cover;
    width: 100%;
    height: calc(100% - 100px);
    z-index: 2;
}

.image-hover img{
    visibility: hidden;
    object-fit: cover;
    width: 100%;
    height: calc(100% - 80px);
}

.info {
    display: grid;
    grid-template-areas: "h2 year"
                            "h3 h3";
}

.caption-h2 {
    grid-area: h2;
    color: var(--element-color);
    margin-top: 20px;
    margin-bottom: 10px;
    font-size: var(--font-size-h6);
    line-height: 1.2;
}

.caption-h3 {
    grid-area: h3;
    color: var(--element-color);
    font-size: var(--font-size-h6);
    font-style: italic;
    margin: 0;
    font-size: 1rem;
    line-height: 1.2;
}

.caption-year {
    grid-area: year;
    color: var(--element-color);
    font-size: var(--font-size-h6);
    margin-top: 20px;
    margin-bottom: 10px;
    text-align: right;
    font-size: 1rem;
    line-height: 1.2;
}
