/* Fichier: /modules/salesmanager/views/css/front.css */

/* Badge de solde sur les listes de produits */
.sale-badge {
    padding-top: 100px;
    position: relative;
    top: 25px;
    left: 0;
    right: 0;
    text-align: center;
    padding: 8px 0;
    font-weight: bold;
    font-size: 11px;
    border-radius: 0;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Container pour l'affichage des prix */
.sale-price-container {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 10px 0;
}

/* Prix original barré */
.sale-original-price {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9em;
    opacity: 0.7;
}

/* Nouveau prix soldé */
.sale-new-price {
    font-weight: bold;
    font-size: 1.3em;
    animation: flash 1s ease-in-out;
}

@keyframes flash {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* Badge de réduction à côté du prix */
.sale-discount-badge {
    background: linear-gradient(135deg, #ff6b6b, #ff4757);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: bold;
    margin-left: 8px;
}

/* Économie réalisée */
.sale-economy {
    color: #27ae60;
    font-size: 0.9em;
    font-weight: 500;
    margin-top: 5px;
    padding: 5px 10px;
    background: rgba(39, 174, 96, 0.1);
    border-radius: 4px;
    display: inline-block;
}

/* Adaptations pour les cartes produits */
.product-miniature .sale-badge {
    top: 5px;
    left: 5px;
    font-size: 10px;
    padding: 6px 10px;
}

.product-miniature .product-price-and-shipping {
    position: relative;
}

/* Page produit détaillée */
.product-page .sale-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 14px;
    padding: 10px 15px;
}

.product-page .sale-price-container {
    margin: 15px 0;
}

.product-page .sale-new-price {
    font-size: 1.5em;
}

/* Responsive mobile */
@media (max-width: 768px) {
    .sale-badge {
        font-size: 9px;
        padding: 5px 8px;
        top: 5px;
        left: 5px;
    }
    
    .sale-price-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .sale-new-price {
        font-size: 1.2em;
    }
}

/* Hover effects */
.product-miniature:hover .sale-badge {
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

/* Style pour le panier */
.cart-summary .sale-original-price {
    font-size: 0.85em;
    margin-right: 5px;
}

.cart-summary .sale-new-price {
    color: #ff4757;
}

/* Countdown timer si date de fin */
.sale-countdown {
    background: #fff3cd;
    color: #856404;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 0.9em;
    margin-top: 10px;
    border: 1px solid #ffeaa7;
}

.sale-countdown strong {
    color: #ff6b6b;
}