/* Match the cover carousels while using the library's heading blue. */
.sbbdl-carousel .sbbdl-carousel-actions {
    margin-bottom: 4px;
    text-align: right;
}

.sbbdl-carousel .sbbdl-carousel-view-all {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding-inline: 26px;
    background-color: #0064bc;
    color: #fff;
}

.sbbdl-carousel .sbbdl-carousel-view-all:hover,
.sbbdl-carousel .sbbdl-carousel-view-all:focus-visible {
    background-color: #004b90;
    color: #fff;
    text-decoration: underline;
}

.sbbdl-carousel .sbbdl-carousel-banner {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 1rem;
    background: #0064bc;
}

.sbbdl-carousel .sbbdl-carousel-banner h1.heading-title {
    margin: 0;
    background: transparent;
}

.sbbdl-carousel .sbbdl-carousel-banner .sbbdl-carousel-view-all {
    flex-shrink: 0;
    min-height: 44px;
    margin-inline-end: 8px;
    padding-inline: 12px;
    background: transparent;
    white-space: nowrap;
}

.sbbdl-carousel .sbbdl-carousel-banner .sbbdl-carousel-view-all:hover,
.sbbdl-carousel .sbbdl-carousel-banner .sbbdl-carousel-view-all:focus-visible {
    background: #004b90;
}

.sbbdl-carousel .sbbdl-carousel-banner .sbbdl-carousel-view-all:focus-visible {
    outline: 2px solid #fff;
    outline-offset: -2px;
}

.sbbdl-carousel .sbbdl-carousel-cover {
    position: relative;
    display: block;
    width: min(11rem, calc(100% - 1rem));
    aspect-ratio: 2 / 3;
    margin-inline: auto;
    background: #f5f4f0;
    border-radius: 4px;
}

.sbbdl-carousel .sbbdl-carousel-cover > img {
    position: absolute;
    inset: 0;
    width: 100%;
    max-width: 100%;
    height: 100%;
    max-height: none;
    box-sizing: border-box;
    padding: 6px;
    object-fit: contain;
}

.sbbdl-carousel .sbbdl-carousel-cover:focus-visible {
    outline: 2px solid #0064bc;
    outline-offset: -2px;
}

.sbbdl-carousel .sbbdl-carousel-track:not(.owl-carousel) {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
}

.sbbdl-carousel .sbbdl-carousel-track:not(.owl-carousel) > .sbbdl-carousel-cover {
    flex: 0 0 min(11rem, calc(100% - 1rem));
    margin-inline: 0;
}

@media (scripting: enabled) {
    .sbbdl-carousel .sbbdl-carousel-track:not(.sbbdl-carousel-ready),
    .sbbdl-carousel .sbbdl-carousel-track.owl-carousel {
        /* Reserve room for the child theme's larger Owl controls. */
        min-height: calc(16.5rem + 56px);
    }

    .sbbdl-carousel .sbbdl-carousel-track:not(.sbbdl-carousel-ready) {
        visibility: hidden;
        animation: sbbdl-carousel-reveal 0s 2s forwards;
    }
}

/* Reveal the scrollable fallback even if initialization never runs. */
@keyframes sbbdl-carousel-reveal {
    to { visibility: visible; }
}
