.ssp-logo-carousel-wrapper {
    position: relative;
    max-width: 100%;
    margin: 2em 0;
}

.ssp-logo-swiper {
    padding-bottom: 50px; /* Space for pagination */
}

/* Swiper default hides overflow, which is usually correct. 
   We removed the y-visible hack because it forces x-auto, causing scrollbars on Windows. */

.ssp-logo-swiper .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
    height: auto;
    min-height: 100px; /* Base height */
    box-sizing: border-box;
}

.ssp-logo-swiper .swiper-slide img {
    max-width: 100%;
    max-height: 120px; /* Prevent huge logos */
    width: auto;
    height: auto;
    object-fit: contain;
    transition: all 0.4s ease;
    display: block;
    margin: 0 auto;
}

.ssp-logo-swiper .swiper-slide a {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    border: none;
    outline: none;
}

/* Center Mode Logic */
/* We apply transforms to the image, not the slide, to avoid confusing Swiper's width calculations */
.ssp-center-mode-active .swiper-slide img {
    opacity: 0.4;
    transform: scale(0.7);
}

.ssp-center-mode-active .swiper-slide.swiper-slide-active img {
    opacity: 1;
    transform: scale(1.1);
    position: relative;
    z-index: 2;
}

/* Arrows customization */
.ssp-logo-carousel-wrapper .swiper-button-next,
.ssp-logo-carousel-wrapper .swiper-button-prev {
    color: #444; /* Default arrow color */
    background: rgba(255, 255, 255, 0.8);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    top: calc(50% - 25px); /* offsets the 50px bottom padding to align with images */
    margin-top: -20px; /* half of 40px height */
}

.ssp-logo-carousel-wrapper .swiper-button-next:after,
.ssp-logo-carousel-wrapper .swiper-button-prev:after {
    font-size: 18px;
    font-weight: bold;
}

/* Pagination customization */
.ssp-logo-carousel-wrapper .swiper-pagination-bullet-active {
    background: #444;
}

.ssp-logo-carousel-wrapper .swiper-pagination {
    bottom: 0;
}
