/* Archive Page Masonry */
.gallery-masonry-container {
    margin: 0 auto;
}

.gallery-sizer,
.gallery-item {
    width: 33.333%;
    padding: 0 5px;
    margin-bottom: 10px;
    box-sizing: border-box;
}

.gallery-item img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
    transition: opacity 0.3s;
}

.gallery-item a:hover img {
    opacity: 0.8;
}

/* Responsive columns */
@media (max-width: 768px) {
    .gallery-sizer,
    .gallery-item {
        width: 50%;
    }
}

@media (max-width: 480px) {
    .gallery-sizer,
    .gallery-item {
        width: 100%;
    }
}

/* Top Page Shortcode */
.home-gallery-container {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 20px 0;
}

.home-gallery-item {
    flex: 1;
}

.home-gallery-item img {
    width: 100%;
    height: 250px; /* Fixed height for consistent look on top page */
    object-fit: cover;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    .home-gallery-container {
        flex-direction: column;
    }
    .home-gallery-item img {
        height: auto;
    }
}

/* Archive Page Padding */
.p-archive--gallery {
    padding: var(--_padding3) 0;
}

/* Archive Content Spacing */
.p-archive__content {
    margin-top: calc(var(--_margin1));
}
