.acf-gallery-grid img {
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 1rem;
    @media (max-width: 54em) {
        border-radius: 0.5rem;
    }
}

.acf-gallery-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;

    @media (max-width: 48em) {
        grid-template-columns: 1fr;
    }

    figcaption {
        font-weight: 500; 
        font-size: var(--heading-sizes--xs); 
        line-height: 1; 
        color: var(--neutral--90);
        margin-top: 0.5rem;

        @media (max-width: 48em) {
            font-size: var(--heading-sizes--xxs);
        }
        
    }
}

/* Lightbox Styles */
.simple-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.simple-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgb(3 17 25 / 90%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    box-sizing: border-box;
    backdrop-filter: blur(10px);
    transition: background-color 0.2s ease, backdrop-filter 0.2s ease;
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-image-container {
    position: relative;
    max-width: 100%;
    max-height: 80vh;
    overflow: hidden;
    border-radius: 0.5rem;
}

.lightbox-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain;
}

.lightbox-caption {
    color: white;
    text-align: center;
    margin-top: 1rem;
    font-size: 1rem;
    line-height: 1.4;
    max-width: 600px;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    background: var(--neutral--10);
    border: none;
    border-radius: 50%;
    padding: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--neutral--90);
    transition: background-color 0.2s ease, transform 0.2s ease;
    z-index: 10;

    font-family: 'bomuldots', sans-serif;
    font-size: 1.5rem;
    line-height: 1;
    font-weight: 100;
    transition: font-weight 0.7s cubic-bezier(0.075, 0.82, 0.165, 1);
    &:hover {
        font-weight: 250;
    }
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.1);
}

.lightbox-close {
    top: -25px;
    right: -25px;
}

.lightbox-prev {
    top: 50%;
    left: -25px;
    transform: translateY(-50%);
}

.lightbox-next {
    top: 50%;
    right: -25px;
    transform: translateY(-50%);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    transform: translateY(-50%) scale(1.1);
}

/* Gallery trigger styles */
.lightbox-trigger {
    transition: transform 0.2s ease;
    border-top: 1px solid var(--neutral--90); 
    padding-top: 1rem; 
    cursor: pointer;
    & > div {
        border-radius: 1.25rem;
        overflow: hidden;
        margin-bottom: 0.5rem;
        @media (max-width: 54em) {
            border-radius: 0.5rem;
        }
    }
}

/* .lightbox-trigger:hover {
    transform: scale(1.02);
} */

/* Mobile responsive */
@media (max-width: 768px) {
    .lightbox-overlay {
        padding: 1rem;
    }
    
    .lightbox-close,
    .lightbox-prev,
    .lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .lightbox-close {
        top: -20px;
        right: -20px;
    }
    
    .lightbox-prev {
        left: -20px;
    }
    
    .lightbox-next {
        right: -20px;
    }
    
    .lightbox-image-container {
        max-height: 70vh;
    }
}