.content-gallery {
    display: grid;
    gap: clamp(0.7rem, 1.6vw, 1rem);
    width: 100%;
    max-width: 100%;
    margin: 0 0 1.15rem;
}

.content-gallery--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.content-gallery--3,
.content-gallery--auto.content-gallery--count-many {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.content-gallery--auto.content-gallery--count-2,
.content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(4):last-child) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.content-gallery--auto.content-gallery--count-1 {
    grid-template-columns: minmax(0, 1fr);
}

.content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(5):last-child) {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(5):last-child) > .content-gallery__item {
    grid-column: span 2;
}

.content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(5):last-child) > .content-gallery__item:nth-child(4) {
    grid-column: 2 / span 2;
}

.content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(5):last-child) > .content-gallery__item:nth-child(5) {
    grid-column: 4 / span 2;
}

.content-gallery--content {
    width: min(100%, var(--structured-content-width, 920px));
    margin-right: auto;
    margin-left: auto;
}

.content-gallery__item {
    min-width: 0;
    margin: 0;
}

.content-gallery__tile {
    display: flex;
    height: 100%;
    min-width: 0;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
}

.content-gallery__tile--viewer,
.content-gallery__tile--link {
    cursor: pointer;
}

.content-gallery__image-frame {
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border-radius: 0.65rem;
    background: #eef2f5;
}

.content-gallery .content-gallery__image-frame > .content-gallery__image {
    display: block;
    width: 100%;
    max-width: none;
    height: 100%;
    object-fit: cover;
    transition: transform 180ms ease;
}

.content-gallery.content-gallery--fit-cover .content-gallery__image-frame > .content-gallery__image {
    object-fit: cover;
}

.content-gallery.content-gallery--fit-contain .content-gallery__image-frame {
    overflow: visible;
    aspect-ratio: auto;
    border-radius: 0;
    background: transparent;
}

.content-gallery.content-gallery--fit-contain .content-gallery__image-frame > .content-gallery__image {
    width: 100%;
    height: auto;
    object-fit: initial;
    border-radius: 0.65rem;
}

.content-gallery__description {
    display: block;
    padding: 0.55rem 0.2rem 0;
    color: #5f6f83;
    font-size: 0.86rem;
    line-height: 1.45;
    text-align: center;
}

@media (hover: hover) and (pointer: fine) {
    .content-gallery__tile--viewer:hover .content-gallery__image,
    .content-gallery__tile--link:hover .content-gallery__image {
        transform: scale(1.025);
    }

    .content-gallery__tile--link:hover .content-gallery__description {
        color: var(--theme-primary, #337ab7);
    }

    .content-gallery.content-gallery--fit-contain .content-gallery__tile--viewer:hover .content-gallery__image,
    .content-gallery.content-gallery--fit-contain .content-gallery__tile--link:hover .content-gallery__image {
        transform: none;
    }
}

@media (max-width: 800px) {
    .content-gallery--3,
    .content-gallery--auto.content-gallery--count-many {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .content-gallery--auto.content-gallery--count-many:has(> .content-gallery__item:nth-child(5):last-child) > .content-gallery__item {
        grid-column: auto;
    }
}

@media (max-width: 560px) {
    .content-gallery,
    .content-gallery--2,
    .content-gallery--3,
    .content-gallery--auto.content-gallery--count-2,
    .content-gallery--auto.content-gallery--count-many {
        grid-template-columns: minmax(0, 1fr);
    }
}

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

.content-gallery-lightbox {
    position: fixed;
    z-index: 5000;
    inset: 0;
    display: none;
    background: rgba(7, 12, 20, 0.94);
}

.content-gallery-lightbox.is-open {
    display: block;
}

.content-gallery-lightbox__dialog {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    min-width: 0;
    min-height: 0;
}

.content-gallery-lightbox__stage {
    position: relative;
    display: grid;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    place-items: center;
    padding: clamp(3.8rem, 7vw, 5.25rem) clamp(4.5rem, 8vw, 6.25rem) clamp(1rem, 2vw, 1.5rem);
}

.content-gallery-lightbox__close,
.content-gallery-lightbox__previous,
.content-gallery-lightbox__next {
    display: inline-flex;
    width: 2.75rem;
    height: 2.75rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    color: #fff;
    font: inherit;
    font-size: 1.45rem;
    cursor: pointer;
    z-index: 2;
}

.content-gallery-lightbox__close {
    position: absolute;
    top: clamp(0.85rem, 2vw, 1.35rem);
    right: clamp(0.85rem, 2vw, 1.35rem);
}

.content-gallery-lightbox__previous,
.content-gallery-lightbox__next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

.content-gallery-lightbox__previous {
    left: clamp(0.85rem, 2vw, 1.35rem);
}

.content-gallery-lightbox__next {
    right: clamp(0.85rem, 2vw, 1.35rem);
}

.content-gallery-lightbox__figure {
    display: grid;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    margin: 0;
    place-items: center;
}

.content-gallery-lightbox__image {
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    object-fit: scale-down;
    object-position: center;
    transform-origin: center;
}

.content-gallery-lightbox__image.is-entering-next {
    animation: content-gallery-lightbox-enter-next 220ms ease-out;
}

.content-gallery-lightbox__image.is-entering-previous {
    animation: content-gallery-lightbox-enter-previous 220ms ease-out;
}

@keyframes content-gallery-lightbox-enter-next {
    from {
        opacity: 0.15;
        transform: translateX(1.75rem);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes content-gallery-lightbox-enter-previous {
    from {
        opacity: 0.15;
        transform: translateX(-1.75rem);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.content-gallery-lightbox__footer {
    position: relative;
    display: flex;
    width: 100%;
    min-height: 4.2rem;
    align-items: center;
    justify-content: center;
    padding: 0.8rem clamp(4.5rem, 8vw, 6.25rem) 0.9rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(2, 6, 23, 0.78);
}

.content-gallery-lightbox__caption {
    max-width: 70rem;
    margin: 0 auto;
    color: #f1f5f9;
    font-size: 0.95rem;
    line-height: 1.45;
    text-align: center;
}

.content-gallery-lightbox__counter {
    position: absolute;
    right: clamp(1rem, 2.5vw, 1.75rem);
    color: #cbd5e1;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.content-gallery-lightbox__close:focus-visible,
.content-gallery-lightbox__previous:focus-visible,
.content-gallery-lightbox__next:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    .content-gallery-lightbox__image.is-entering-next,
    .content-gallery-lightbox__image.is-entering-previous {
        animation: none;
    }
}

@media (max-width: 640px) {
    .content-gallery-lightbox__stage {
        padding: 3.8rem 3.45rem 0.8rem;
    }

    .content-gallery-lightbox__close,
    .content-gallery-lightbox__previous,
    .content-gallery-lightbox__next {
        width: 2.5rem;
        height: 2.5rem;
    }

    .content-gallery-lightbox__close {
        top: 0.7rem;
        right: 0.7rem;
    }

    .content-gallery-lightbox__previous {
        left: 0.55rem;
    }

    .content-gallery-lightbox__next {
        right: 0.55rem;
    }

    .content-gallery-lightbox__footer {
        min-height: 4rem;
        padding: 0.7rem 4rem 0.8rem 0.8rem;
    }

    .content-gallery-lightbox__caption {
        font-size: 0.88rem;
    }

    .content-gallery-lightbox__counter {
        right: 0.9rem;
        font-size: 0.78rem;
    }
}
