/* Container override */
.partners-section > .container {
    max-width: 1100px !important;
    padding: 0 40px !important;
}

/* Sponsor Items */
.sponsor-item {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 140px;
    height: 90px;
}

.sponsor-item a {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.sponsor-item img {
    max-width: 120px;
    max-height: 55px;
    object-fit: contain;
    opacity: 0.9;
    transition: all 0.4s ease;
}

.sponsor-item:hover img {
    opacity: 1;
    transform: scale(1.1);
}

.sponsor-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    transition: color 0.3s ease;
}

.sponsor-item:hover .sponsor-name {
    color: #5B2C6F;
}

.sponsor-type {
    display: block;
    font-size: 0.65rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-top: 0.25rem;
    text-align: center;
    white-space: nowrap;
}

/* Carousel wrapper */
.sponsors-carousel-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Draggable row */
.draggable-row {
    cursor: default;
    user-select: none;
}

.draggable-row:active {
    cursor: grabbing;
}

.draggable-row.dragging {
    cursor: grabbing;
}

/* Auto-scroll track */
.sponsors-track.auto-scroll {
    animation: scrollLeft 140s linear infinite;
}

.sponsors-track.auto-scroll[data-direction="right"] {
    animation: scrollRight 140s linear infinite;
}

.sponsors-track.paused {
    animation-play-state: paused;
}

@keyframes scrollLeft {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

@keyframes scrollRight {
    0% { transform: translateX(-50%); }
    100% { transform: translateX(0); }
}

/* Sponsors row */
.sponsors-row {
    flex: 1;
    position: relative;
    overflow: hidden;
}

/* Fade edges - rimossi su richiesta cliente */

/* Responsive */
@media (max-width: 768px) {
    /* HOTFIX iOS: disabilita marquee infinite su mobile (saturano VRAM con texture bitmap gigante). */
    /* Ripristina scroll orizzontale nativo. */
    .sponsors-track.auto-scroll,
    .sponsors-track.auto-scroll[data-direction="right"] {
        animation: none !important;
        transform: none !important;
        width: auto !important;
    }
    .sponsors-row {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
    }
    .sponsors-row .sponsor-item {
        scroll-snap-align: start;
    }

    .partners-section {
        overflow: visible !important;
        max-width: 100vw !important;
    }

    .partners-section .container {
        overflow: visible !important;
        max-width: 100% !important;
        padding: 0 1rem !important;
    }

    .sponsors-row {
        /* Auto-scroll riabilitato: hidden + animation, swipe disabilitato */
        overflow: hidden !important;
        max-width: 100% !important;
    }

    .sponsors-track {
        gap: 2.5rem !important;
    }

    .sponsor-item {
        min-width: 100px;
        height: auto !important;
        min-height: 70px;
        overflow: visible !important;
    }

    .sponsor-item img {
        width: 80px;
        height: 45px;
        object-fit: contain;
        overflow: visible !important;
    }

    .sponsors-nav-btn {
        width: 36px;
        height: 36px;
    }

    .sponsors-nav-btn svg {
        width: 18px;
        height: 18px;
    }

    .sponsors-row::before,
    .sponsors-row::after {
        width: 40px;
    }
}
