/**
 * Knapstack Logo Slider Styles
 * A flexible logo slider component that can be placed anywhere in content
 * with alternating scroll directions and fade-to-white effect
 */

.knapstack-logo-slider {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
    margin: 20px 0;
    background: transparent;
}

/* Inline slider specific styles */
.knapstack-inline-slider {
    background: none;
}

.knapstack-slider-row {
    height: 120px;
    margin-bottom: 20px;
    position: relative;
}

.knapstack-slider-row:last-child {
    margin-bottom: 0;
}

.knapstack-slider-row .swiper {
    width: 100%;
    height: 100%;
}

.knapstack-slider-row .swiper-wrapper {
    transition-timing-function: linear;
    align-items: center;
}

.knapstack-slider-row .swiper-slide {
    width: 140px !important; /* Fixed width for consistent spacing */
    margin-right: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.knapstack-logo {
    height: 60px;
    width: auto;
    max-width: 120px;
    object-fit: contain;
}

.knapstack-logo-grey {
    filter: grayscale(100%) opacity(0.7);
    transition: filter 0.3s ease;
}

.knapstack-logo:hover {
    filter: grayscale(0%) opacity(1);
}

/* Fade overlays - creates fade effects on different sides */
.knapstack-fade-overlay {
    position: absolute;
    pointer-events: none;
    z-index: 10;
    transition: opacity 0.3s ease;
}

/* Individual fade overlays for each side */
.knapstack-fade-overlay.fade-left {
    left: 0;
    top: 0;
    width: 100px;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
}

.knapstack-fade-overlay.fade-right {
    right: 0;
    top: 0;
    width: 100px;
    height: 100%;
    background: linear-gradient(to left, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
}

.knapstack-fade-overlay.fade-top {
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
}

.knapstack-fade-overlay.fade-bottom {
    bottom: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to top, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
}

/* Swiper handles animations - remove conflicting CSS animations */
/* Row styling is now handled by SwiperJS configuration */

/* Style variations */
.knapstack-logo-slider.style-compact {
    height: 250px;
}

.knapstack-logo-slider.style-wide {
    height: 500px;
}

.knapstack-logo-slider.style-compact .knapstack-slider-row {
    height: 70px;
    margin-bottom: 10px;
}

.knapstack-logo-slider.style-wide .knapstack-slider-row {
    height: 150px;
    margin-bottom: 25px;
}

/* Speed variations
.knapstack-logo-slider.speed-slow .knapstack-row-1 .swiper-slide {
    animation-duration: 45s;
}

.knapstack-logo-slider.speed-slow .knapstack-row-2 .swiper-slide {
    animation-duration: 40s;
}

.knapstack-logo-slider.speed-slow .knapstack-row-3 .swiper-slide {
    animation-duration: 50s;
}

.knapstack-logo-slider.speed-fast .knapstack-row-1 .swiper-slide {
    animation-duration: 15s;
}

.knapstack-logo-slider.speed-fast .knapstack-row-2 .swiper-slide {
    animation-duration: 12s;
}

.knapstack-logo-slider.speed-fast .knapstack-row-3 .swiper-slide {
    animation-duration: 18s;
}
 */
/* Responsive design */
@media screen and (max-width: 768px) {
    .knapstack-logo-slider {
        height: 300px;
        margin: 15px 0;
    }
    
    .knapstack-slider-row {
        height: 80px;
        margin-bottom: 10px;
    }
    
    .knapstack-logo {
        height: 40px;
        max-width: 80px;
    }
    
    .knapstack-fade-overlay {
        width: 60px;
    }
}

@media screen and (max-width: 480px) {
    .knapstack-logo-slider {
        height: 200px;
        margin: 10px 0;
    }
    
    .knapstack-slider-row {
        height: 60px;
        margin-bottom: 5px;
    }
    
    .knapstack-logo {
        height: 30px;
        max-width: 60px;
    }
    
    .knapstack-fade-overlay {
        width: 40px;
    }
}

/* Custom scrollbar for better integration (if needed) */
.knapstack-logo-slider::-webkit-scrollbar {
    display: none;
}

/* Swiper integration improvements */
.knapstack-logo-slider .swiper {
    overflow: visible;
}

.knapstack-logo-slider .swiper-wrapper {
    align-items: center;
    transition-timing-function: linear;
}

/* Smooth hover transitions */
.knapstack-logo-slider:hover .knapstack-logo {
    transition: filter 0.2s ease;
}

/* Additional styling for better visual integration */
.knapstack-logo-slider::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
    background: linear-gradient(to bottom, transparent 0%, rgba(255, 255, 255, 0.3) 100%);
    z-index: 11;
}

.knapstack-logo-slider::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    right: 0;
    height: 10px;
    background: linear-gradient(to top, transparent 0%, rgba(255, 255, 255, 0.3) 100%);
    z-index: 11;
}

/* Enhanced fade overlay responsiveness */
@media screen and (max-width: 768px) {
    .knapstack-fade-overlay {
        width: 60px;
    }
}

@media screen and (max-width: 480px) {
    .knapstack-fade-overlay {
        width: 40px;
    }
}