/* Styles personnalisés pour WAMI */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-in-out;
}

/* Product Cards */
.product-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* Consultation Cards */
.consultation-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.consultation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* Badge styles */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-popular {
    background-color: #FFB300;
    color: white;
}

.badge-promo {
    background-color: #EF5350;
    color: white;
}

.badge-new {
    background-color: #66BB6A;
    color: white;
}

/* Modal animations */
#cart-modal {
    transition: opacity 0.3s ease;
}

#cart-modal.show {
    display: flex !important;
}

/* Loading spinner */
.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2E7D32;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
}

/* Button hover effects */
button, .btn {
    transition: all 0.3s ease;
}

button:active, .btn:active {
    transform: scale(0.98);
}

/* Optimisation mobile */
@media (max-width: 768px) {
    h1 {
        font-size: 1.5rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* Optimisation pour connexions lentes */
.lazy-load {
    opacity: 0;
    transition: opacity 0.3s;
}

.lazy-load.loaded {
    opacity: 1;
}

/* Toast notifications */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #2E7D32;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    animation: slideIn 0.3s ease;
}

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

.toast.error {
    background-color: #EF5350;
}

.toast.success {
    background-color: #66BB6A;
}

/* Book preview styles */
.prose h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2E7D32;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.prose p {
    margin-bottom: 0.75rem;
    line-height: 1.6;
    color: #333;
}

.prose ul {
    margin-left: 1.5rem;
    margin-bottom: 0.75rem;
}

.prose li {
    margin-bottom: 0.5rem;
    color: #555;
}

.prose em {
    font-style: italic;
    color: #2E7D32;
}

/* Print styles */
@media print {
    header, footer, .no-print {
        display: none !important;
    }
}
