.greenwood-consignment-gallery,
.greenwood-thrift-gallery {
    width: 100%;
}

.greenwood-gallery-category {
    clear: both;
    margin-bottom: 48px;
}

.greenwood-gallery-category h2 {
    margin-bottom: 18px;
}

.greenwood-gallery-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 18px;
    margin: 20px 0 35px;
}

.greenwood-gallery-item {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    text-align: left;
}

.greenwood-gallery-item img {
    width: 100%;
    height: 135px;
    object-fit: cover;
    display: block;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.greenwood-gallery-item:hover img,
.greenwood-gallery-item:focus img {
    opacity: 0.85;
}

.greenwood-lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(0, 0, 0, 0.75);
}

.greenwood-lightbox-overlay.is-active {
    display: flex;
}

.greenwood-lightbox-dialog {
    position: relative;
    width: min(960px, 100%);
    max-height: 92vh;
    overflow: auto;
    background: #fff;
    padding: 20px;
}

.greenwood-lightbox-close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: 0;
    background: transparent;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
}

.greenwood-lightbox-image {
    width: 100%;
    max-height: 65vh;
    object-fit: contain;
    display: block;
    margin: 0 auto 16px;
}

.greenwood-lightbox-title {
    margin: 0 40px 8px 0;
}

.greenwood-lightbox-meta {
    margin: 8px 0 0;
}

.greenwood-lightbox-meta strong {
    color: inherit;
}

/* Popup Maker migration safety: preserve page scrolling when the email signup popup is enabled. */
html.pum-open,
body.pum-open,
body.pum-open-overlay {
    overflow-y: auto !important;
    padding-right: 0 !important;
}

.pum-overlay {
    overflow-y: auto !important;
}

@media (max-width: 991px) {
    .greenwood-gallery-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .greenwood-gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .greenwood-gallery-item img {
        height: 125px;
    }
}
