.gallery-filters {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-3);
    margin-bottom: var(--sp-8);
}
.gallery-filter-btn {
    background: #fff;
    border: 2px solid var(--clr-border);
    color: var(--clr-text);
    padding: 0.55rem 1.25rem;
    border-radius: 50px;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    font-size: 0.9rem;
}
.gallery-filter-btn:hover { border-color: var(--clr-primary); color: var(--clr-primary); }
.gallery-filter-btn.is-active {
    background: var(--clr-primary);
    border-color: var(--clr-primary);
    color: #fff;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--sp-5);
}
@media (max-width: 860px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
    .gallery-grid { grid-template-columns: 1fr; }
}

.gallery-item {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    position: relative;
    display: block;
    width: 100%;
    text-align: left;
}
.gallery-item__img-wrap {
    aspect-ratio: 4 / 3;
    overflow: hidden;
}
.gallery-item img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.gallery-item:hover img,
.gallery-item:focus-visible img { transform: scale(1.06); }
.gallery-item__caption {
    padding: var(--sp-3) var(--sp-4);
    background: #fff;
}
.gallery-item__caption {
    display: block;
}
.gallery-item__title {
    display: block;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1rem;
    margin: 0 0 var(--sp-1);
    color: var(--clr-text);
}
.gallery-item__cat {
    display: block;
    font-size: 0.8rem;
    color: var(--clr-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.gallery-item[hidden] { display: none; }

/* ---------- Lightbox ---------- */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(16, 35, 63, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: var(--sp-6);
}
.lightbox[hidden] { display: none; }
.lightbox__dialog {
    max-width: min(900px, 100%);
    width: 100%;
    position: relative;
}
.lightbox__img-wrap { text-align: center; }
.lightbox img {
    max-height: 78vh;
    width: auto;
    max-width: 100%;
    margin: 0 auto;
    border-radius: 8px;
}
.lightbox__caption {
    color: #fff;
    text-align: center;
    margin-top: var(--sp-4);
}
.lightbox__caption h2 { color: #fff; font-size: 1.15rem; margin-bottom: var(--sp-1); }
.lightbox__caption span { color: var(--clr-accent); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; }
.lightbox__close {
    position: absolute;
    top: -50px; right: 0;
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: none;
    width: 42px; height: 42px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
}
.lightbox__close:hover { background: rgba(255,255,255,0.3); }
.lightbox__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: none;
    width: 46px; height: 46px;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
}
.lightbox__nav:hover { background: rgba(255,255,255,0.3); }
.lightbox__nav--prev { left: -60px; }
.lightbox__nav--next { right: -60px; }
@media (max-width: 760px) {
    .lightbox__nav--prev { left: var(--sp-2); }
    .lightbox__nav--next { right: var(--sp-2); }
    .lightbox__close { top: var(--sp-2); right: var(--sp-2); }
}
