/* ---------------------------------------------------------
   STYLE GLOBAL DU WIDGET
--------------------------------------------------------- */
.custom-product-widget {
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: relative;
}

/* Mode Landing Page */
.custom-product-widget.landing-mode {
    padding: 30px;
    border-radius: 12px;
}

/* Mode Compact Mobile */
@media (max-width: 768px) {
    .custom-product-widget.compact-mobile {
        padding: 12px;
    }
    .custom-product-widget.compact-mobile .product-title {
        font-size: 18px;
    }
    .custom-product-widget.compact-mobile .variation-image-item img {
        width: 45px;
        height: 45px;
    }
}

/* ---------------------------------------------------------
   BADGE + SOUS-TITRE — VERSION OFFICIELLE (Elementor prefix_class)
--------------------------------------------------------- */

/* Desktop */
.custom-product-widget.header-layout-inline .product-header-row {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.custom-product-widget.header-layout-columns .product-header-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
}

/* Mobile */
@media (max-width: 768px) {
    .custom-product-widget.header-layout-inline-mobile .product-header-row {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
    }

    .custom-product-widget.header-layout-columns-mobile .product-header-row {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 10px;
    }
}

/* Badge compact + centré */
.custom-product-widget .product-badge-left {
    display: inline-block;
    width: auto !important;
    max-width: fit-content !important;
    flex-shrink: 0;
    margin-left: auto;
    margin-right: auto;
}

/* ---------------------------------------------------------
   TITRE + PRIX (inline / columns)
--------------------------------------------------------- */

.custom-product-widget .product-title-price-row.inline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
}

.custom-product-widget .product-title-price-row.inline .product-title-left {
    flex: 1;
}

.custom-product-widget .product-title-price-row.inline .product-price-right {
    flex-shrink: 0;
}

.custom-product-widget .product-title-price-row.columns {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

@media (max-width: 768px) {
    .custom-product-widget .product-title-price-row.inline {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ---------------------------------------------------------
   BADGE PROMO
--------------------------------------------------------- */
.custom-product-widget .product-badge {
    display: inline-block;
    background: #ff4d4d;
    color: #fff;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 12px;
}

/* ---------------------------------------------------------
   SOUS-TITRE ÉMOTIONNEL
--------------------------------------------------------- */
.custom-product-widget .product-subtitle {
    font-size: 16px;
    font-weight: 600;
    color: #444;
    margin-bottom: 12px;
}

/* ---------------------------------------------------------
   TITRE PRODUIT
--------------------------------------------------------- */
.custom-product-widget .product-title {
    margin: 0 0 15px;
    font-size: 24px;
    line-height: 1.3;
    font-weight: 700;
}

.custom-product-widget .product-title a {
    color: #333;
    text-decoration: none;
}

.custom-product-widget .product-title a:hover {
    color: #0073aa;
}

/* ---------------------------------------------------------
   IMAGE PRODUIT
--------------------------------------------------------- */
.custom-product-widget .product-image {
    margin-bottom: 20px;
    overflow: hidden;
    border-radius: 8px;
}

.custom-product-widget .product-image img {
    width: 100%;
    transition: transform 0.3s ease;
}

.custom-product-widget .product-image:hover img {
    transform: scale(1.05);
}

/* ---------------------------------------------------------
   PRIX
--------------------------------------------------------- */
.custom-product-widget .product-price {
    margin-bottom: 15px;
    font-size: 22px;
    font-weight: bold;
    color: #333;
}

.custom-product-widget .product-price del {
    opacity: 0.5;
    margin-right: 8px;
}

.custom-product-widget .product-price ins {
    color: #0073aa;
    text-decoration: none;
}

/* ---------------------------------------------------------
   STOCK DYNAMIQUE
--------------------------------------------------------- */
.custom-product-widget .product-stock-dynamic {
    margin-bottom: 12px;
    font-size: 14px;
}

.custom-product-widget .product-stock-dynamic .in-stock {
    color: #4caf50;
    font-weight: 700;
}

.custom-product-widget .product-stock-dynamic .out-of-stock {
    color: #f44336;
    font-weight: 700;
}

/* ---------------------------------------------------------
   TIMER PROMO
--------------------------------------------------------- */
.custom-product-widget .product-timer {
    background: #ffe9e9;
    border-left: 4px solid #ff4d4d;
    padding: 10px 12px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
    font-weight: 600;
    color: #d32f2f;
}

.custom-product-widget .product-timer .timer-countdown {
    font-weight: 800;
    margin-left: 6px;
}

/* ---------------------------------------------------------
   DESCRIPTION COURTE
--------------------------------------------------------- */
.custom-product-widget .product-excerpt {
    margin-bottom: 20px;
    color: #666;
    line-height: 1.6;
}

/* ---------------------------------------------------------
   VARIATIONS — VERSION PREMIUM
--------------------------------------------------------- */
.custom-product-widget .product-variations-images-section {
    padding: 12px 16px;
    margin-bottom: 20px;
    background: #fff4f8;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.custom-product-widget .variation-title {
    font-size: 18px;
    font-weight: 700;
    color: #d63384;
    text-align: center;
    margin-bottom: 12px;
}

.custom-product-widget .variation-images-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.custom-product-widget .variation-image-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.custom-product-widget .variation-image-item img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 3px solid #ddd;
    object-fit: cover;
    transition: all 0.3s ease;
}

.custom-product-widget .variation-image-item:hover img {
    border-color: #d63384;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.custom-product-widget .variation-image-item.selected img {
    border-color: #d63384;
    box-shadow: 0 0 0 2px rgba(214,51,132,0.4);
    transform: scale(1.1);
}

.custom-product-widget .variation-name {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    text-align: center;
}

.custom-product-widget .variation-image-item.selected .variation-name {
    color: #d63384;
}

/* Mobile variations */
@media (max-width: 768px) {
    .custom-product-widget .variation-image-item img {
        width: 55px;
        height: 55px;
    }
    .custom-product-widget .variation-name {
        font-size: 12px;
    }
}

/* ---------------------------------------------------------
   MESSAGE DE RÉASSURANCE
--------------------------------------------------------- */
.custom-product-widget .product-reassurance {
    margin-top: 15px;
    font-size: 14px;
    color: #444;
    line-height: 1.5;
}

/* ---------------------------------------------------------
   BOUTON ACHETER
--------------------------------------------------------- */
.custom-product-widget .product-add-to-cart {
    margin-top: 20px;
}

.custom-product-widget .custom-add-to-cart-button {
    background: #0073aa;
    color: #fff;
    padding: 14px 26px;
    border: none;
    border-radius: 6px;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.custom-product-widget .custom-add-to-cart-button:hover:not(.disabled) {
    background: #005a87;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,115,170,0.3);
}

.custom-product-widget .custom-add-to-cart-button.disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.custom-product-widget .product-add-to-cart.fullwidth .custom-add-to-cart-button {
    width: 100%;
}

/* ---------------------------------------------------------
   RESPONSIVE GLOBAL
--------------------------------------------------------- */
@media (max-width: 768px) {
    .custom-product-widget .product-title {
        font-size: 20px;
    }
    .custom-product-widget .product-price {
        font-size: 18px;
    }
}
