/* Vente Flash Slider - Similar to Actualités */
.vente-flash-carousel {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 1rem 0.5rem;
    scroll-behavior: auto; /* Désactiver smooth pour éviter les sauts */
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    /* Empêcher le scroll vertical de se propager */
    touch-action: pan-x;
    /* Permettre le scroll vertical de la page même quand on touche le carousel */
    overscroll-behavior-x: contain;
    overscroll-behavior-y: none; /* Empêcher tout effet sur le scroll vertical */
    /* Empêcher le scroll du carousel d'affecter le scroll de la page */
    isolation: isolate;
    contain: layout style paint;
}

.vente-flash-carousel::-webkit-scrollbar {
    display: none;
}

.vente-flash-item {
    flex: 0 0 auto;
    text-align: center;
    padding: 0.5rem;
    width: 200px;
    height: 400px;
    opacity: 0.6;
    transform: scale(0.95);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    position: relative;
    /* Optimiser les performances pour éviter les reflows */
    will-change: transform, opacity;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

.vente-flash-item:hover {
    opacity: 0.8;
    transform: scale(0.98);
}

.vente-flash-item.active {
    opacity: 1;
    transform: scale(1);
}

.vente-flash-shadow-effect {
    background: #fff;
    padding: 0;
    border-radius: 12px;
    text-align: center;
    border: 1px solid #ECECEC;
    box-shadow: 0 19px 38px rgba(0,0,0,0.10), 0 15px 12px rgba(0,0,0,0.02);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.vente-flash-item.active .vente-flash-shadow-effect {
    box-shadow: 0 25px 50px rgba(200, 16, 46, 0.15), 0 20px 15px rgba(200, 16, 46, 0.08);
    border-color: var(--primary-color);
}

.vente-flash-shadow-effect:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.15), 0 20px 15px rgba(0,0,0,0.05);
}

.vente-flash-media-container {
    width: 100%;
    height: 200px;
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: #f5f5f5;
}

.vente-flash-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vente-flash-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d1d5db;
    background: #f9fafb;
}

.vente-flash-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 2;
}

.vente-flash-content {
    flex: 1;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.vente-flash-product-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vente-flash-prices {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.vente-flash-original-price {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-decoration: line-through;
}

.vente-flash-flash-price {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-color);
}

.vente-flash-description {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.vente-flash-actions {
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
    margin-top: auto;
    justify-content: center;
    align-items: center;
}

.vente-flash-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.1);
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.vente-flash-action-btn:hover {
    background: white;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.vente-flash-action-btn svg {
    width: 18px;
    height: 18px;
}

.vente-flash-btn-view {
    color: var(--primary-color);
}

.vente-flash-btn-view:hover {
    color: var(--primary-hover);
}

.vente-flash-btn-cart {
    color: var(--primary-color);
}

.vente-flash-btn-cart:hover {
    color: var(--primary-hover);
}

.vente-flash-btn-chat {
    color: #3b82f6;
}

.vente-flash-btn-chat:hover {
    color: #2563eb;
}

/* Logo de l'entreprise en haut à droite */
.vente-flash-company-logo {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid white;
    background: var(--primary-color);
    z-index: 15;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: transform 0.2s ease;
}

.vente-flash-company-logo:hover {
    transform: scale(1.1);
}

.vente-flash-company-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Slider interne pour les ventes flash d'une entreprise */
.vente-flash-inner-slider {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.vente-flash-slide-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.vente-flash-slide-item.active {
    opacity: 1;
    z-index: 1;
}

.vente-flash-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding: 0.5rem;
}

.vente-flash-carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #d1d5db;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    padding: 0;
}

.vente-flash-carousel-dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

.vente-flash-carousel-dot:hover {
    background: var(--primary-hover);
    transform: scale(1.1);
}

.slider-info-box {
    background: #f9fafb;
    border: 1px solid #fecaca;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1rem 0;
}

.info-box-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.info-box-icons {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-icon-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.info-icon-text {
    color: white;
    font-size: 0.875rem;
    font-weight: 700;
    font-style: italic;
    line-height: 1;
}

.info-bulb-icon {
    width: 24px;
    height: 24px;
    color: #fbbf24;
    flex-shrink: 0;
}

.info-box-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--gray-800);
    margin: 0;
    line-height: 1.2;
}

.info-box-content {
    margin-top: 0.75rem;
}

.info-box-text {
    font-size: 0.9375rem;
    color: var(--gray-700);
    line-height: 1.6;
    margin: 0 0 1rem 0;
}

.info-box-text strong {
    font-weight: 700;
    color: var(--gray-900);
}

.info-box-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #ef4444;
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: color 0.2s ease;
    margin-top: 0.5rem;
}

.info-box-link:hover {
    color: #dc2626;
    text-decoration: underline;
}

.info-box-link svg {
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

.info-box-link:hover svg {
    transform: translateX(2px);
}

.slider-empty,
.slider-error {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

/* Responsive */
@media (max-width: 768px) {
    .vente-flash-item {
        width: 160px;
        height: 320px;
        padding: 0.375rem;
    }
    
    .vente-flash-media-container {
        height: 150px;
    }
    
    .vente-flash-content {
        padding: 0.5rem;
    }
    
    .vente-flash-action-btn {
        width: 32px;
        height: 32px;
    }
    
    .vente-flash-action-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .slider-info-box {
        padding: 1.25rem;
    }
    
    .info-box-header {
        gap: 0.5rem;
        margin-bottom: 0.75rem;
    }
    
    .info-icon-circle {
        width: 20px;
        height: 20px;
    }
    
    .info-icon-text {
        font-size: 0.75rem;
    }
    
    .info-bulb-icon {
        width: 20px;
        height: 20px;
    }
    
    .info-box-title {
        font-size: 0.9375rem;
    }
    
    .info-box-text {
        font-size: 0.875rem;
        margin-bottom: 0.75rem;
    }
    
    .info-box-link {
        font-size: 0.875rem;
    }
}

/* Menu déroulant pour les ventes flash */
.vente-flash-more-menu-wrapper {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 20;
}

.vente-flash-more-btn {
    width: 36px;
    height: 36px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1px solid #e4e6eb;
    border-radius: 50%;
    color: #65676b !important;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    padding: 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    z-index: 20;
}

.vente-flash-more-btn:hover {
    background: #ffffff !important;
    color: #1a1a1a !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transform: scale(1.05);
}

.vente-flash-more-btn svg {
    width: 18px;
    height: 18px;
}

.vente-flash-more-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
    background: #ffffff;
    border: 1px solid #e4e6eb;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    min-width: 160px;
    overflow: hidden;
    animation: fadeInDown 0.2s ease;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.vente-flash-menu-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    color: #1a1a1a;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.vente-flash-menu-item:hover {
    background: #f5f7fa;
}

.vente-flash-menu-item-danger {
    color: #dc2626;
}

.vente-flash-menu-item-danger:hover {
    background: #fee2e2;
    color: #991b1b;
}

.vente-flash-menu-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.vente-flash-menu-item span {
    flex: 1;
}

.vente-flash-shadow-effect {
    position: relative;
}

