/*
Theme Name: Maison Eclat Child
Template: maison-eclat
Version: 1.0
*/

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700&family=Montserrat:wght@400;700&display=swap');

:root { --rose: #e91e63; --gold: #d4af37; --peach: #fff5f6; }

body { background-color: var(--peach) !important; font-family: 'Montserrat', sans-serif !important; }

/* Header & Logo */
.top-bar { background: var(--rose); color: #fff; text-align: center; padding: 10px; font-size: 12px; font-weight: bold; letter-spacing: 1px; }
.site-header { background: #fff; padding: 20px; box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.logo { font-family: 'Playfair Display', serif; font-size: 32px; color: var(--rose); text-decoration: none; font-weight: bold; }

/* Boutons MariaShops */
.vc_btn3, .button, .woocommerce .button {
    background: linear-gradient(to right, #e91e63, #ff4081) !important;
    color: #fff !important;
    border-radius: 50px !important;
    padding: 12px 20px !important;
    border: none !important;
    box-shadow: 0 5px 15px rgba(233, 30, 99, 0.3) !important;
    text-transform: uppercase;
    font-weight: bold;
    transition: 0.3s;
    display: inline-block;
}

/* --- GRILLE DE PRODUITS SANS AUCUN DÉCALAGE --- */

ul.products {
    display: grid !important;
    list-style: none !important;
    padding: 0 !important;
    margin: 40px 0 !important;
}

/* 💻 Ordinateur : 5 colonnes */
@media (min-width: 1024px) {
    ul.products { grid-template-columns: repeat(5, 1fr) !important; gap: 20px !important; }
}

/* 📱 Mobile : 2 colonnes strictes */
@media (max-width: 767px) {
    ul.products { grid-template-columns: repeat(2, 1fr) !important; gap: 10px !important; padding: 0 10px !important; }
    
    ul.products li.product { padding: 8px !important; }
    
    ul.products li.product .woocommerce-loop-product__title {
        height: 32px !important; /* Hauteur fixe titres mobile */
        font-size: 11px !important;
    }
    
    ul.products li.product .price { font-size: 13px !important; }
}

/* --- LA STRUCTURE CARRÉE PARFAITE --- */

ul.products li.product {
    background: #fff;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,0.05);
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    transition: 0.3s ease;
    text-align: center;
    overflow: hidden;
}

/* 1. L'IMAGE : Carré identique pour tous */
ul.products li.product img {
    width: 100% !important;
    aspect-ratio: 1 / 1 !important; /* Carré strict */
    object-fit: cover !important;
    border-radius: 0 !important; /* Optionnel : image plein bord pour un look moderne */
    margin-bottom: 12px !important;
}

/* 2. LE TITRE : Aligné au pixel près */
ul.products li.product .woocommerce-loop-product__title {
    font-size: 13px !important;
    color: #2d2424 !important;
    text-transform: uppercase;
    height: 40px !important; /* Hauteur fixe impérative */
    margin: 0 5px 8px 5px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden;
}

/* 3. LE PRIX : Aligné au pixel près */
ul.products li.product .price {
    color: #e91e63 !important;
    font-weight: 700 !important;
    height: 24px !important; /* Hauteur fixe impérative */
    margin-bottom: 12px !important;
    display: block !important;
}

/* 4. LE BOUTON : Aligné en bas */
ul.products li.product .button {
    margin-top: auto !important; /* Pousse le bouton en bas du carré */
    margin-bottom: 10px !important;
    font-size: 10px !important;
    padding: 10px 15px !important;
    width: 90% !important;
    white-space: nowrap;
}

ul.products li.product:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(233, 30, 99, 0.1);
}