.sponsors-slideshow {
    position: relative;
    width: 100%;
    padding: 0 2.25rem 1.4rem;
}

.sponsors-slideshow__viewport {
    display: grid;
    grid-template-columns: repeat(var(--sponsors-slideshow-items-per-view, 1), minmax(0, 1fr));
    gap: 1rem;
    min-height: calc(var(--sponsors-slideshow-max-height) + 2.5rem);
}

.sponsors-slideshow__slide {
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    min-height: calc(var(--sponsors-slideshow-max-height) + 2.5rem);
}

.sponsors-slideshow__slide.is-active {
    display: flex;
    animation: sponsors-slideshow-fade .45s ease-in-out;
}

.sponsors-slideshow__link {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    color: inherit;
    text-decoration: none;
}

.sponsors-slideshow__image {
    display: block;
    width: auto;
    max-width: min(100%, var(--sponsors-slideshow-max-height));
    height: auto;
    max-height: var(--sponsors-slideshow-max-height);
    object-fit: contain;
}

.sponsors-slideshow__caption {
    display: block;
    margin-top: .65rem;
    overflow-wrap: anywhere;
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
}

.sponsors-slideshow__link:hover .sponsors-slideshow__caption,
.sponsors-slideshow__link:focus-visible .sponsors-slideshow__caption {
    text-decoration: underline;
}

.sponsors-slideshow__control {
    position: absolute;
    top: calc(var(--sponsors-slideshow-max-height) / 2);
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgb(0 0 0 / 55%);
    color: #fff;
    font-size: 1.65rem;
    line-height: 1;
    transform: translateY(-50%);
}

.sponsors-slideshow__control:hover,
.sponsors-slideshow__control:focus-visible {
    background: rgb(0 0 0 / 78%);
}

.sponsors-slideshow__control--prev { left: 0; }
.sponsors-slideshow__control--next { right: 0; }

.sponsors-slideshow__control[hidden],
.sponsors-slideshow__indicators[hidden] {
    display: none;
}

.sponsors-slideshow__indicators {
    position: absolute;
    right: 0;
    bottom: .4rem;
    left: 0;
    display: flex;
    justify-content: center;
    gap: .45rem;
}

.sponsors-slideshow__indicators button {
    width: .65rem;
    height: .65rem;
    padding: 0;
    border: 1px solid currentColor;
    border-radius: 50%;
    background: transparent;
    color: currentColor;
    opacity: .55;
}

.sponsors-slideshow__indicators button.is-active {
    background: currentColor;
    opacity: 1;
}

@keyframes sponsors-slideshow-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    .sponsors-slideshow__slide.is-active { animation: none; }
}
