/*
 * Natal Mais Feliz — galerias históricas.
 */

.nc-natal-history {
    padding: 78px 0 88px;
}

.nc-natal-history__heading {
    max-width: 720px;
    margin-bottom: 32px;
}

.nc-natal-history__heading h2 {
    margin: 8px 0 12px;
}

.nc-natal-history__heading > p:last-child {
    max-width: 580px;
    line-height: 1.7;
}

.nc-natal-history__years {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 22px;
}

.nc-natal-history__year,
.nc-natal-history__load-more {
    border: 1px solid currentColor;
    border-radius: 999px;
    padding: 10px 20px;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition:
        transform .18s ease,
        opacity .18s ease;
}

.nc-natal-history__year:hover,
.nc-natal-history__load-more:hover {
    transform: translateY(-1px);
}

.nc-natal-history__year.is-active {
    background: var(--nc-primary, #073577);
    border-color: var(--nc-primary, #073577);
    color: #fff;
}

.nc-natal-history__status {
    min-height: 24px;
    margin: 0 0 24px;
    opacity: .72;
}

.nc-natal-history__grid {
    display: grid;
    grid-template-columns:
        repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.nc-natal-history__item {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    padding: 0;
    border: 0;
    border-radius: 14px;
    overflow: hidden;
    background: transparent;
    cursor: zoom-in;
}

.nc-natal-history__item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .28s ease;
}

.nc-natal-history__item:hover img {
    transform: scale(1.035);
}

.nc-natal-history__more {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.nc-natal-history__load-more[hidden] {
    display: none;
}

.nc-natal-lightbox {
    position: fixed;
    width: min(92vw, 1180px);
    max-width: 1180px;
    max-height: 90vh;
    padding: 0;
    border: 0;
    border-radius: 16px;
    overflow: visible;
    background: transparent;
}

.nc-natal-lightbox::backdrop {
    background: rgba(0, 0, 0, .84);
}

.nc-natal-lightbox img {
    display: block;
    max-width: 100%;
    max-height: 86vh;
    margin: auto;
    border-radius: 14px;
}

.nc-natal-lightbox__close {
    position: absolute;
    z-index: 2;
    top: -18px;
    right: -18px;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: #111;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
}

.nc-natal-gallery-admin-preview {
    display: grid;
    grid-template-columns:
        repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin: 16px 0;
}

.nc-natal-gallery-admin-item img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    margin-bottom: 5px;
}


@media (max-width: 900px) {

    .nc-natal-history__grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }
}


@media (max-width: 600px) {

    .nc-natal-history {
        padding: 58px 0 68px;
    }

    .nc-natal-history__grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .nc-natal-history__year {
        padding: 9px 16px;
    }

    .nc-natal-lightbox__close {
        top: 8px;
        right: 8px;
    }
}