.gallery-banner .banner-img { background: #a8dacb; }
.gallery-banner .banner-img img { object-fit: cover; object-position: center; }

.discovery-section article h3 {
    margin-top: 26px;
    margin-bottom: 12px;
}

.discovery-section article p {
    margin-bottom: 0;
}

.gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 11000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 76px 24px 24px;
    background: rgba(2, 28, 16, .94);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, visibility .25s ease;
}

.gallery-lightbox.open {
    opacity: 1;
    visibility: visible;
}

.gallery-lightbox img {
    display: block;
    width: auto;
    max-width: min(1200px, 94vw);
    height: auto;
    max-height: 84vh;
    object-fit: contain;
    border-radius: 14px;
    box-shadow: 0 22px 70px rgba(0, 0, 0, .38);
}

.gallery-lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #087b3c;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    transition: transform .2s ease, background-color .2s ease;
}

.gallery-lightbox-close:hover,
.gallery-lightbox-close:focus-visible {
    background: #075b30;
    transform: rotate(90deg);
}

body.gallery-lightbox-open {
    overflow: hidden !important;
}

@media (max-width: 991px) {
    .discovery-section .offset-lg-2 {
        margin-left: 0;
    }
}

@media (max-width: 575px) {
    .discovery-section article h3 {
        margin-top: 20px;
        margin-bottom: 10px;
    }

    .gallery-lightbox {
        padding: 66px 12px 12px;
    }

    .gallery-lightbox-close {
        top: 14px;
        right: 14px;
        width: 42px;
        height: 42px;
        font-size: 19px;
    }
}

/* Gallery Filter Bar */
.gallery-filter-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 0 auto 40px;
    max-width: 900px;
}

.gallery-filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border: 1.5px solid #c7e5d3;
    border-radius: 50px;
    background: #ffffff;
    color: #134e32;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 4px 12px rgba(8, 118, 56, 0.06);
}

.gallery-filter-btn i {
    color: #087638;
    transition: color 0.25s ease;
}

.gallery-filter-btn:hover {
    border-color: #087638;
    background: #edf8f1;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(8, 118, 56, 0.12);
}

.gallery-filter-btn.active {
    border-color: #087638;
    background: #087638;
    color: #ffffff;
    box-shadow: 0 6px 20px rgba(8, 118, 56, 0.28);
}

.gallery-filter-btn.active i {
    color: #8be5aa;
}

/* Card-Based Gallery Grid Format */
.gallery-masonry {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 22px !important;
}

@media (max-width: 1199px) {
    .gallery-masonry {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 18px !important;
    }
}

@media (max-width: 767px) {
    .gallery-masonry {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 14px !important;
    }
}

@media (max-width: 480px) {
    .gallery-masonry {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }
}

.gallery-item {
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    height: 280px !important;
    grid-row: auto !important;
    background: #ffffff !important;
    border: 1.5px solid #dbeae0 !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    box-shadow: 0 6px 18px rgba(3, 84, 40, 0.06) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease !important;
}

.gallery-item.gallery-hidden {
    display: none !important;
}

.gallery-item:hover {
    transform: translateY(-6px) !important;
    border-color: #087638 !important;
    box-shadow: 0 16px 36px rgba(3, 84, 40, 0.16) !important;
}

.gallery-img-container {
    position: relative !important;
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 14px !important;
    background: #fbfdfc !important;
}

.gallery-img-container img {
    width: 100% !important;
    height: 100% !important;
    max-height: 250px !important;
    object-fit: contain !important;
    object-position: center !important;
    transition: transform 0.4s ease !important;
}

.gallery-item:hover .gallery-img-container img {
    transform: scale(1.06) !important;
}

.gallery-tag-pill {
    position: absolute !important;
    top: 12px !important;
    left: 12px !important;
    padding: 4px 12px !important;
    border-radius: 20px !important;
    background: rgba(3, 84, 40, 0.90) !important;
    backdrop-filter: blur(4px) !important;
    color: #ffffff !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    z-index: 2 !important;
    pointer-events: none !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
}

.gallery-item span:not(.gallery-tag-pill):not(.gallery-hover-overlay) {
    display: none !important;
}

.gallery-hover-overlay {
    position: absolute !important;
    inset: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: transparent !important;
    opacity: 0 !important;
    transition: opacity 0.25s ease !important;
    z-index: 3 !important;
    pointer-events: none !important;
    border-radius: 18px !important;
}

.gallery-hover-overlay i {
    display: grid !important;
    place-items: center !important;
    width: 46px !important;
    height: 46px !important;
    background: #087638 !important;
    color: #ffffff !important;
    border-radius: 50% !important;
    font-size: 1.1rem !important;
    box-shadow: 0 6px 20px rgba(3, 84, 40, 0.4) !important;
    transform: scale(0.8) !important;
    transition: transform 0.25s ease !important;
}

.gallery-item:hover .gallery-hover-overlay {
    opacity: 1 !important;
}

.gallery-item:hover .gallery-hover-overlay i {
    transform: scale(1) !important;
}
