/* ========================================
   COMPANIES CAROUSEL STYLES
   ======================================== */

/* Carousel Container */
#companiesCarousel {
    position: relative;
    padding: 2rem 0;
}

/* Company Logo Container */
.company-logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 140px;
    padding: 2rem;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
    overflow: visible;
    margin: 0.5rem;
}

.company-logo-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    border-color: #0dcaf0;
}

/* Company Logo Images */
.company-logo {
    max-width: 140px;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    opacity: 0.8;
    transition: all 0.3s ease;
}

.company-logo-container:hover .company-logo {
    opacity: 1;
    transform: scale(1.02);
}

/* Carousel Controls Styling */
#companiesCarousel .carousel-control-prev,
#companiesCarousel .carousel-control-next {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    border: 2px solid #0dcaf0;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

#companiesCarousel .carousel-control-prev {
    left: 20px;
}

#companiesCarousel .carousel-control-next {
    right: 20px;
}

#companiesCarousel .carousel-control-prev:hover,
#companiesCarousel .carousel-control-next:hover {
    background: #0dcaf0;
    transform: translateY(-50%) scale(1.05);
    box-shadow: 0 6px 20px rgba(13, 202, 240, 0.3);
}

#companiesCarousel .carousel-control-prev-icon,
#companiesCarousel .carousel-control-next-icon {
    width: 24px;
    height: 24px;
    background-size: 24px 24px;
}

/* Carousel Indicators */
#companiesCarousel .carousel-indicators {
    bottom: -50px;
    margin-bottom: 0;
}

#companiesCarousel .carousel-indicators [data-bs-target] {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #dee2e6;
    border: none;
    margin: 0 6px;
    transition: all 0.3s ease;
}

#companiesCarousel .carousel-indicators .active {
    background-color: #0dcaf0;
    transform: scale(1.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .company-logo-container {
        height: 120px;
        padding: 1.5rem;
        margin: 0.25rem;
    }
    
    .company-logo {
        max-width: 120px;
        max-height: 60px;
    }
    
    #companiesCarousel .carousel-control-prev,
    #companiesCarousel .carousel-control-next {
        width: 50px;
        height: 50px;
    }
    
    #companiesCarousel .carousel-control-prev {
        left: 10px;
    }
    
    #companiesCarousel .carousel-control-next {
        right: 10px;
    }
    
    #companiesCarousel .carousel-control-prev-icon,
    #companiesCarousel .carousel-control-next-icon {
        width: 20px;
        height: 20px;
        background-size: 20px 20px;
    }
}

@media (max-width: 576px) {
    .company-logo-container {
        height: 100px;
        padding: 1rem;
        margin: 0.25rem;
    }
    
    .company-logo {
        max-width: 100px;
        max-height: 50px;
    }
    
    #companiesCarousel .carousel-control-prev,
    #companiesCarousel .carousel-control-next {
        width: 45px;
        height: 45px;
    }
    
    #companiesCarousel .carousel-control-prev {
        left: 5px;
    }
    
    #companiesCarousel .carousel-control-next {
        right: 5px;
    }
    
    #companiesCarousel .carousel-control-prev-icon,
    #companiesCarousel .carousel-control-next-icon {
        width: 18px;
        height: 18px;
        background-size: 18px 18px;
    }
}

/* Animation for smooth transitions */
.carousel-item {
    transition: transform 0.6s ease-in-out;
}

/* Accessibility improvements */
.company-logo-container:focus {
    outline: 2px solid #0dcaf0;
    outline-offset: 2px;
}

/* Loading state */
.company-logo {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.company-logo[src] {
    background: none;
    animation: none;
}

/* Animaciones para los logos */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Animación de entrada para el carrusel */
.carousel-item {
    animation: slideIn 0.6s ease-in-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
