/*
 * FAMILOV - Design system du site (chargé en dernier, après style.css, responsive.css et front.css).
 * Une seule source pour la marque : couleurs, police, boutons, prix, focus. La structure des pages ne change pas :
 * ce fichier redonne la même apparence aux classes existantes. Fiche : DESIGN.md à la racine du projet.
 */
:root {
    /* Couleurs de la marque */
    --fm-green: #0EB947;        /* vert Familov : boutons, accents */
    --fm-green-ink: #06301A;    /* texte posé sur le vert (contraste 6:1) */
    --fm-green-dark: #087A34;   /* liens, survol, texte vert sur fond clair */
    --fm-green-soft: #ECFDF3;   /* fonds légers, badges */
    --fm-mint: #2FBF87;         /* dégradés avec le vert */
    --fm-pink: #FF4D6D;         /* rose du logo : promos, cœur, prix barré */
    --fm-pink-dark: #D62C4C;
    --fm-pink-soft: #FFF0F3;
    --fm-ink: #111827;          /* texte principal, prix */
    --fm-ink-2: #344054;        /* texte secondaire */
    --fm-muted: #667085;        /* aides, dates, légendes */
    --fm-line: #E4ECE7;         /* bordures */
    --fm-page: #F6FBF8;         /* fond de page */
    --fm-surface: #FFFFFF;
    --fm-warn: #B54708;
    --fm-danger: #B42318;

    /* Forme */
    --fm-radius-sm: 8px;
    --fm-radius: 12px;          /* boutons, champs */
    --fm-radius-lg: 16px;       /* cartes */
    --fm-radius-pill: 999px;
    --fm-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 4px 14px rgba(16, 24, 40, .06);
    --fm-shadow-lg: 0 8px 28px rgba(16, 24, 40, .12);

    /* Police : la même partout (style.css et les pages lisent déjà --f-font-body / --f-font-display) */
    --fm-font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --f-font-body: var(--fm-font);
    --f-font-display: var(--fm-font);

    /* Anciennes variables des pages boutique, alignées sur la marque */
    --fmlv-green: var(--fm-green);
    --fmlv-green-dark: var(--fm-green-dark);
    --fmlv-green-soft: var(--fm-green-soft);
    --fmlv-pink: var(--fm-pink);
    --fmlv-pink-dark: var(--fm-pink-dark);
    --fmlv-pink-soft: var(--fm-pink-soft);
    --fmlv-ink: var(--fm-ink);
    --fmlv-muted: var(--fm-muted);
    --fmlv-line: var(--fm-line);
    --familov-green: var(--fm-green);
    --familov-mint: var(--fm-mint);
    --familov-pink: var(--fm-pink);
    --familov-muted: var(--fm-muted);
    --familov-line: var(--fm-line);
}

/* ---------- Base ---------- */
html body { font-family: var(--fm-font); color: var(--fm-ink); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body input, body select, body textarea, body button { font-family: var(--fm-font); }
body h1, body h2, body h3, body h4 { color: var(--fm-ink); letter-spacing: -0.01em; text-wrap: balance; }
::selection { background: rgba(14, 185, 71, .22); color: var(--fm-ink); }
body input, body textarea { caret-color: var(--fm-green-dark); }
body a { text-underline-offset: 3px; }
body :focus-visible { outline: 3px solid rgba(14, 185, 71, .55); outline-offset: 2px; border-radius: 6px; }
body input:focus, body select:focus, body textarea:focus { border-color: var(--fm-green) !important; box-shadow: 0 0 0 3px rgba(14, 185, 71, .18) !important; outline: none; }
body .fmlv-card__price, body .fmlv-card__price-old, body .product-detail-price, body .details_price_actual, body .details_price_discount { font-variant-numeric: tabular-nums; }

/* ---------- Boutons : un principal, un secondaire ---------- */
/* Principal : vert Familov, texte vert très foncé (lisible), même arrondi partout. */
body .btn-success:not(.btn-number), body .front-success:not(.btn-number), body .btn-orange, body .add-to-cart-btn, body .fmlv-add:not(.fmlv-add--disabled),
body .familov-final-cta-btn, body .familov-v2-left button[type=submit], body .btn-continue, body .continue-btn,
body .familov-primary-cta, body .nav-link.register, body .familov-gradient-btn, body .familov-shop-change-btn-primary,
body #familov-ai-send, body .cookie_btn, body #navbar .register.btn, body .fmlv-search__submit {
    background: var(--fm-green) !important;
    border-color: var(--fm-green) !important;
    color: var(--fm-green-ink) !important;
    border-radius: var(--fm-radius) !important;
    font-weight: 800 !important;
    letter-spacing: 0;
    text-transform: none !important;
    transition: background-color .15s ease, box-shadow .15s ease, transform .1s ease;
}
body .familov-gradient-btn { background-image: none !important; }
body .btn-success:not(.btn-number):hover, body .btn-orange:hover, body .add-to-cart-btn:hover, body .fmlv-add:not(.fmlv-add--disabled):hover,
body .familov-primary-cta:hover, body .nav-link.register:hover, body .familov-gradient-btn:hover, body .familov-shop-change-btn-primary:hover {
    background: #12C850 !important;
    box-shadow: 0 4px 14px rgba(14, 185, 71, .28);
}
body .btn-success:active, body .btn-orange:active, body .add-to-cart-btn:active, body .fmlv-add:active { transform: translateY(1px); }
body .fmlv-add i, body .add-to-cart-btn i { color: var(--fm-green-ink) !important; }

/* Le bouton blanc du bandeau vert final garde son fond blanc (il est posé sur du vert). */
body .familov-final-cta-btn { background: #fff !important; border-color: #fff !important; color: var(--fm-green-dark) !important; }
body .familov-final-cta-btn:hover { background: var(--fm-green-soft) !important; }

/* Secondaire : contour vert. */
body .btn-dark-continueshoping, body .btn-outline-success {
    background: #fff !important;
    color: var(--fm-green-dark) !important;
    border: 1.5px solid var(--fm-green) !important;
    border-radius: var(--fm-radius) !important;
    font-weight: 700 !important;
}
body .btn-dark-continueshoping:hover, body .btn-outline-success:hover { background: var(--fm-green-soft) !important; }

/* ---------- Prix : encre, le rose réservé aux promotions ---------- */
body .fmlv-card__price { color: var(--fm-ink) !important; font-weight: 800; }
body .fmlv-card__prices:has(.fmlv-card__price-old) .fmlv-card__price { color: var(--fm-pink-dark) !important; }
body .fmlv-card__price-old { color: var(--fm-muted) !important; }
body .product-detail-price .details_price_actual { color: var(--fm-ink) !important; font-weight: 800; }
body .product-detail-price .details_price_discount ~ .details_price_actual,
body .product-detail-price .details_price_actual + .details_price_discount { color: var(--fm-muted) !important; }

/* ---------- Pied de page ---------- */
body footer a, body .footer a { color: var(--fm-ink-2); }
body footer a:hover, body .footer a:hover { color: var(--fm-green-dark); }

@media (prefers-reduced-motion: reduce) {
    body .btn-success, body .btn-orange, body .add-to-cart-btn, body .fmlv-add { transition: none; }
}
