.sw-gallery-a1 #thumbSplideSp {
    width: min(90%, calc(var(--a1-slots) * 76px + var(--a1-gaps)));
    margin: 12px auto 0;
    padding: 0;
}

/* Match Splide's ten-pixel gap so the rail ends on a whole thumbnail. */
.sw-gallery-a1 #thumbSplideSp .splide__slide {
    width: calc((100% - var(--a1-gaps)) / var(--a1-slots)) !important;
    margin-inline-start: 0;
}

.sw-gallery-a1 #thumbSplideSp .thumb-square {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.sw-gallery-a1 #thumbSplideSp .is-active .thumb-square {
    outline: 2px solid #151515 !important;
    outline-offset: -2px;
    box-shadow: none;
}

.sw-gallery-a1 #thumbSplideSp .splide__slide:focus-visible .thumb-square,
.sw-gallery-a1 #mainSplide:focus-visible {
    outline: 2px dashed currentColor !important;
    outline-offset: -4px;
}

.sw-gallery-a1__count {
    margin: 10px 0 0;
    color: var(--bs-body-color, #222);
    font: 500 13px/20px system-ui, sans-serif;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

/* Paint the real first slide while Splide prepares the interactive track. */
.sw-gallery-a1 #mainSplide:not(.is-initialized) .splide__slide:first-child:not(.splide__slide--clone) {
    width: 100%;
    visibility: visible;
    pointer-events: none;
}

.sw-gallery-a1 #mainSplide:not(.is-initialized) .splide__arrows {
    visibility: hidden;
}

.sw-gallery-a1 #mainSplide.is-initialized[data-splide] .splide__arrow {
    display: flex !important;
}
