@charset "UTF-8";
/* CSS Document */

#masonry-gallery {
    margin: 0 auto;
}

.grid-item {
    width: 400px;
    max-width: 100%;
    margin-bottom: 32px;
    break-inside: avoid;
    transition: transform 0.2s;
}

.grid-item:hover {
    transform: scale(1.02);
}

.grid-item a {
    display: flex;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
}

.grid-item img {
    width: 100%;
    height: auto;
    border-radius: 6px;
    user-select: none;
}

.grid-item div {
    padding: 16px 0 0 5px;
}

.grid-item h3 {
    font-size: 1.125rem;
    margin: 0 0 6px;
    font-weight: var(--semibold);
}

.grid-item p {
    font-size: 0.875rem;
    margin: 0;
    color: var(--cnx-greydark);
}


#filtersCollapse {
    display: none;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

#filtersCollapse button {
    background: #eee;
    border-radius: 6px;
    height: 36px;
    aspect-ratio: 1 / 1;
    border: none;
    background-image: url(../collapse.svg);
    background-size: 16px;
    background-position: center;
    background-repeat: no-repeat;
}

.rotate {
    transform: scaleY(-1);
}

nav {
    height: fit-content;
    padding: 20px 0;
    display: flex;
    align-items: center;
    margin-bottom: 40px;
    transition: 0.2s;
}

nav p {
    margin: 0 15px 0 0;
    font-weight: var(--semibold);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  overflow-x: scroll;
}

.filters a {
  padding: 8px 16px;
  text-decoration: none;
  background: #eee;
  border-radius: 6px;
  color: var(--cnx-black);
  transition: background 0.2s;
  cursor: pointer;
}

.filters a:hover {
  background: #ddd;
}

.filters a.active {
  background: var(--cnx-black);
  color: white;
  font-weight: var(--bold);
}

footer p {
    margin: 0;
}

footer br {
    display: none;
}

@media only screen and (max-width: 600px) {

    #filtersCollapse {
        display: flex;
    }

    .collapsed {
        height: 0;
        padding: 0;
        overflow-y: hidden;
    }

    footer br {
        display: initial;
    }

}