/* ============================================================
   Charte PF. v1.0 — couche finale de pokemon-france.com
   Chargée en dernier (functions.php, priorité 9999), après les feuilles des
   mini-sites : têtière et pied de page de la charte (p. 15), polices
   Unbounded (titres) / Inter (texte) partout (p. 12), boutons et pastilles
   de marque, mode sombre automatique via les tokens de pf-brand.css.
   ============================================================ */

/* ---------- Fond de page ---------- */
html body { background: var(--pfb-fond); color: var(--pfb-encre); font-family: var(--pfb-font-texte); }

/* ---------- Polices (p. 12) : Inter pour tout le texte (y compris les mini-sites), Unbounded pour les titres ----------
   :where() garde une spécificité minimale, pour que la règle des titres ci-dessous l'emporte. Exceptions : code
   (chasse fixe) et logotype de l'éditeur Circulys. */
html body :where(*:not(code, pre, kbd, samp, .circulys-mark, .circulys-mark *)) { font-family: var(--pfb-font-texte) !important; }
/* ---------- Polices : tous les titres en Unbounded, approche de la charte ---------- */
html body :is(h1, h2, h3, h4, h5, h6) { font-family: var(--pfb-font-titre) !important; }
html body h1 { font-weight: 900 !important; letter-spacing: -.02em !important; }
html body h2 { font-weight: 700 !important; letter-spacing: -.01em !important; }
html body :is(h3, h4, h5, h6) { font-weight: 700 !important; letter-spacing: 0 !important; }

/* ---------- Têtière (p. 15) : 64 px mobile / 80 px bureau, blanche en clair, noire en sombre, filet 1 px ---------- */
html body .nav {
    background: var(--pfb-tetiere-fond);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom: 1px solid var(--pfb-tetiere-filet);
    color: var(--pfb-tetiere-encre);
}
html body .nav-inner { height: var(--pfb-tetiere-h); gap: 8px; }
html body .nav .container.nav-inner { padding-left: var(--pfb-tetiere-marge); padding-right: var(--pfb-tetiere-marge); }
html body .nav-logo { height: var(--pfb-tetiere-logo-h); margin-right: 24px; gap: 0; }
html body .nav-logo .pfb-logo { height: var(--pfb-tetiere-logo-h); }
html body .nav-right { background: var(--pfb-tetiere-fond); box-shadow: -12px 0 10px -2px var(--pfb-tetiere-fond); gap: 12px; }

/* Liens de section : Inter 700, encre de la têtière, page active soulignée de jaune. */
html body .nav-link {
    color: var(--pfb-tetiere-encre);
    font-family: var(--pfb-font-texte);
    font-size: 15px;
    line-height: 20px;
    font-weight: 700;
    letter-spacing: .01em;
    padding: 0 10px;
    border-radius: 0;
}
html body .nav-link:hover,
html body .nav-link.active,
html body .current-menu-item > .nav-link,
html body .current-menu-parent > .nav-link { color: var(--pfb-tetiere-encre); background: transparent; }
html body .nav-link:hover { text-decoration: underline; text-decoration-color: var(--pfb-jaune); text-decoration-thickness: 2px; text-underline-offset: 6px; }
html body .nav-link.active::after,
html body .current-menu-item > .nav-link::after { bottom: calc((var(--pfb-tetiere-logo-h) - var(--pfb-tetiere-h)) / 2); height: 3px; background: var(--pfb-jaune); }
html body .nav-link--news { color: var(--pfb-tetiere-encre); font-size: 15px; font-weight: 700; }
html body .nav-arrow { opacity: .6; }
html body .nav-badge { background: var(--pfb-jaune); color: var(--pfb-noir); }

/* Icônes 24 px, trait 2 px ; boutons Connexion / S'inscrire en Inter 700 15/20 +1 %. */
html body .btn-search { color: var(--pfb-tetiere-encre); width: 40px; height: 40px; }
html body .btn-search svg { width: 24px; height: 24px; }
html body .btn-search svg circle, html body .btn-search svg path { stroke-width: 2; }
html body .btn-search:hover { background: var(--pfb-surface-2); color: var(--pfb-tetiere-encre); }
html body :is(.btn-login, .btn-register) { font-family: var(--pfb-font-texte); font-size: 15px; line-height: 20px; font-weight: 700; letter-spacing: .01em; padding: 8px 16px; }
html body .btn-login { color: var(--pfb-tetiere-encre); border-color: var(--pfb-tetiere-filet); }
html body .btn-login:hover { color: var(--pfb-tetiere-encre); border-color: var(--pfb-tetiere-encre); }
html body .btn-register { background: var(--pfb-jaune); color: var(--pfb-noir); }
html body .btn-register:hover { background: var(--pfb-jaune-ombre); color: var(--pfb-noir); }
html body .btn-register--ink { background: var(--pfb-encre); color: var(--pfb-fond); }
html body .btn-register--ink:hover { background: var(--pfb-encre-2); color: var(--pfb-fond); }
html body .btn-account { color: var(--pfb-tetiere-encre); border-color: var(--pfb-tetiere-filet); background: transparent; }
html body .nav-waffle { color: var(--pfb-tetiere-encre); }
html body .nav-waffle:hover, html body .nav-waffle:focus-visible { background: var(--pfb-surface-2); }

/* Pastille Premium (p. 15) : jaune, étoile et texte Noir PF ; abonné : même pastille. */
html body .e4-pill,
html body .e4-pill--on {
    height: 36px;
    padding: 0 14px;
    background: var(--pfb-jaune);
    color: var(--pfb-noir);
    font-family: var(--pfb-font-texte);
    font-size: 15px;
    line-height: 20px;
    font-weight: 700;
    letter-spacing: .01em;
    box-shadow: none;
}
html body .e4-pill:hover, html body .e4-pill--on:hover { background: var(--pfb-jaune-ombre); color: var(--pfb-noir); transform: none; box-shadow: none; }

/* Méga-menus et menu mobile : surfaces de la charte. */
html body .mega-menu { background: var(--pfb-surface); border-color: var(--pfb-ligne); color: var(--pfb-encre); }
html body .mega-e4 { background: var(--pfb-jaune); color: var(--pfb-noir); }
html body .mega-e4 .e4-mark { background: var(--pfb-noir); color: var(--pfb-jaune); border-radius: 50%; width: 28px; height: 28px; }
html body .mega-e4__txt b, html body .mega-e4__go { color: var(--pfb-noir); }
html body .mega-e4__txt small { color: var(--pfb-graphite); }
html body .nav-mobile__panel { background: var(--pfb-fond); color: var(--pfb-encre); }
html body .nav-mobile__header { background: var(--pfb-tetiere-fond); border-bottom: 1px solid var(--pfb-tetiere-filet); min-height: var(--pfb-tetiere-h); }
html body .nav-mobile__brand .pfb-logo { height: 36px; }
html body .nav-mobile__e4 { background: var(--pfb-jaune) !important; color: var(--pfb-noir) !important; }
html body .nav-mobile__e4 .e4-mark { background: var(--pfb-noir); color: var(--pfb-jaune); border-radius: 50%; }
html body .nav-mobile__e4 b { color: var(--pfb-noir) !important; }
html body .nav-mobile__e4 small { color: var(--pfb-graphite) !important; }

/* ---------- Bannière de l'app (ex-Elite4) : Noir PF, emblème PF, filet Graphite ---------- */
html body .e4-banner { background: var(--pfb-noir); color: var(--pfb-blanc); border-bottom: 1px solid var(--pfb-graphite); font-family: var(--pfb-font-texte); }
html body .e4-banner__icon { border-radius: 0; box-shadow: none; }
html body .e4-banner__text b { color: var(--pfb-blanc); }
html body .e4-banner__text span { color: var(--pfb-acier); }
html body .e4-store { background: var(--pfb-noir); color: var(--pfb-blanc); border-color: var(--pfb-graphite); }
html body .e4-store:hover { border-color: var(--pfb-jaune); color: var(--pfb-blanc); }
html body .e4-banner__close { background: var(--pfb-graphite); color: var(--pfb-blanc); }

/* ---------- Boutons et marques de l'offre Premium ---------- */
html body .e4-btn { font-family: var(--pfb-font-texte); font-weight: 700; letter-spacing: .01em; }
html body .e4-btn--gold, html body .e4-btn--gold:hover { background: var(--pfb-jaune); color: var(--pfb-noir); box-shadow: none; }
html body .e4-btn--gold:hover { background: var(--pfb-jaune-ombre); }
html body .e4-btn--ink { background: var(--pfb-encre); color: var(--pfb-fond); }
html body .e4-btn--ghost { color: var(--pfb-encre); border-color: var(--pfb-ligne); }
html body .e4-mark { background: var(--pfb-noir); color: var(--pfb-jaune); font-family: var(--pfb-font-titre); }
html body .e4-kicker { font-family: var(--pfb-font-texte); font-size: 11px; line-height: 14px; font-weight: 700; letter-spacing: .08em; }
html body .e4-footer-band { background: var(--pfb-graphite); color: var(--pfb-blanc); }
html body .e4-footer-band b { color: var(--pfb-jaune); }

/* ---------- Pied de page : Noir PF, logo complet négatif, Blanc PF / Acier, filet Graphite ---------- */
html body .footer { background: var(--pfb-noir); color: var(--pfb-blanc); border-top: 1px solid var(--pfb-graphite); }
html body .footer-brand-logo { display: block; width: 240px; max-width: 100%; margin-bottom: 16px; line-height: 0; }
html body .footer-brand-logo img { display: block; width: 240px; height: auto; }
html body .footer-desc { color: var(--pfb-acier); font-size: 13px; line-height: 20px; max-width: 260px; }
html body .footer-since { color: var(--pfb-blanc); font-size: 11px; line-height: 14px; letter-spacing: .08em; }
html body .footer-col h4 { font-family: var(--pfb-font-texte) !important; font-size: 11px; line-height: 14px; font-weight: 700 !important; letter-spacing: .08em !important; color: var(--pfb-acier); text-transform: uppercase; }
html body .footer-col a { color: var(--pfb-blanc); font-size: 14px; }
html body .footer-col a:hover { color: var(--pfb-jaune); }
html body .footer-bottom { border-top-color: var(--pfb-graphite); gap: 24px; align-items: flex-start; }
html body .footer-copy { color: var(--pfb-acier); font-size: 13px; line-height: 20px; max-width: 80ch; }
html body .footer-affiliate { color: var(--pfb-acier); }
html body .footer-social { background: var(--pfb-graphite); color: var(--pfb-blanc); }
html body .footer-social:hover { background: var(--pfb-graphite); color: var(--pfb-jaune); }

/* ---------- Surfaces de marque (ex-Elite4 / Passlord) : Noir PF uni, filet Graphite ---------- */
html body :is(.e4p-hero, .e4p-final, .e4h-hero, .e4h-final, .e4-home__card, .e4-teaser--dark, .e4-paywall, .passlord-banner, .passlord-cta, .comment-passlord-cta, .comment-login-cta, .jo-sec--premium, .si-sec--premium, .pf-johto .article-body .jo-premium, .pf-sinnoh .article-body .si-premium) {
    background: var(--pfb-noir) !important;
    color: var(--pfb-blanc);
    border-color: var(--pfb-graphite);
}
html body :is(.e4p-hero, .e4h-hero, .e4p-final, .e4h-final)::before,
html body :is(.e4p-hero, .e4h-hero, .e4p-final, .e4h-final)::after { display: none !important; }
html body .e4h .e4-dcard--feature .e4-dcard__link { background: var(--pfb-noir) !important; }
html body .e4-teaser { background: var(--pfb-surface-2); border-color: var(--pfb-ligne); }
html body :is(.e4-pbadge, .e4h-pass__seal, .e4-paywall__seal) { background: var(--pfb-jaune) !important; color: var(--pfb-noir) !important; box-shadow: none !important; }
html body .e4p-card__brand img { display: block; height: 26px; width: auto; }

/* Jetons de police hérités (ex-Elite4) → Unbounded. */
html body, html body * { --e4-display: var(--pfb-font-titre); }

/* Entrée LEGO de la têtière : plus d'aplat jaune (une seule touche de jaune, p. 10). */
html body .nav-link--lego,
html body .nav-link--lego:hover,
html body .nav-link--lego.active { background: transparent; color: var(--pfb-tetiere-encre); }

/* Bandeau saisonnier : version sombre (fond Graphite) en mode sombre. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body .pf-season-bar { background: var(--pfb-graphite); color: var(--pfb-blanc); }
    :root:not([data-theme="light"]) body .pf-season-bar__text b { color: var(--season-a, var(--pfb-jaune)); }
    :root:not([data-theme="light"]) body .pf-season-bar__close { background: var(--pfb-noir); color: var(--pfb-blanc); }
}
:root[data-theme="dark"] body .pf-season-bar { background: var(--pfb-graphite); color: var(--pfb-blanc); }
    :root[data-theme="dark"] body .pf-season-bar__text b { color: var(--season-a, var(--pfb-jaune)); }
    :root[data-theme="dark"] body .pf-season-bar__close { background: var(--pfb-noir); color: var(--pfb-blanc); }


/* Le contenu des titres (span, em, b…) garde la police du titre. */
html body :is(h1, h2, h3, h4, h5, h6) * { font-family: inherit !important; }

/* Bouton clair (sur héros Noir PF) : Blanc PF, texte Noir PF, dans les deux modes. */
html body .e4-btn--light { background: var(--pfb-blanc); color: var(--pfb-noir); }

/* Menu mobile : l'entrée « Guide shopping » suit les surfaces du thème. */
html body .nav-mobile__shop { background: var(--pfb-surface-2) !important; color: var(--pfb-encre) !important; }

/* ---------- Mini-sites à direction artistique propre : contenu toujours en version claire ----------
   Leurs palettes (ciel, mer, carte, foils…) sont dessinées pour un fond clair. En mode sombre, la têtière et le
   pied de page basculent ; le contenu (#content) garde les valeurs claires de la charte. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body:is(.pf-kanto, .pf-johto, .pf-hoenn, .pf-sinnoh, .pf-unys, .pf-kalos, .pf-alola, .pf-paldea, .pf-za, .pf-vv, .pkp-body, .pf-mk, .pf-go, .pf-frlg, .pf-anime, .pf-shop, .page-id-140748, .page-id-141285) #content {
        color-scheme: light;
        --pfb-fond: var(--pfb-blanc-pur);
        --pfb-surface: var(--pfb-blanc-pur);
        --pfb-surface-2: var(--pfb-blanc);
        --pfb-encre: var(--pfb-noir);
        --pfb-encre-2: var(--pfb-graphite);
        --pfb-ligne: var(--pfb-filet);
        --pfb-lien: var(--pfb-noir);
        --pfb-accent-texte: var(--pfb-noir);
        --white: var(--pfb-blanc-pur);
        --cream: var(--pfb-blanc);
        --ink: var(--pfb-noir);
        --ink-mid: var(--pfb-graphite);
        --ink-light: var(--pfb-graphite);
        --ink-faint: var(--pfb-graphite);
        --border: var(--pfb-filet);
        --border-light: var(--pfb-filet);
        --yellow-bg: var(--pfb-blanc);
        --blue: var(--pfb-noir);
        --blue-bg: var(--pfb-blanc);
        --e4-gold-deep: var(--pfb-noir);
        --e4-indigo-soft: var(--pfb-blanc);
        --e4-gold-soft: var(--pfb-blanc);
        --e4-line: var(--pfb-filet);
        background: var(--pfb-blanc-pur);
        color: var(--pfb-noir);
    }
}
:root[data-theme="dark"] body:is(.pf-kanto, .pf-johto, .pf-hoenn, .pf-sinnoh, .pf-unys, .pf-kalos, .pf-alola, .pf-paldea, .pf-za, .pf-vv, .pkp-body, .pf-mk, .pf-go, .pf-frlg, .pf-anime, .pf-shop, .page-id-140748, .page-id-141285) #content {
        color-scheme: light;
        --pfb-fond: var(--pfb-blanc-pur);
        --pfb-surface: var(--pfb-blanc-pur);
        --pfb-surface-2: var(--pfb-blanc);
        --pfb-encre: var(--pfb-noir);
        --pfb-encre-2: var(--pfb-graphite);
        --pfb-ligne: var(--pfb-filet);
        --pfb-lien: var(--pfb-noir);
        --pfb-accent-texte: var(--pfb-noir);
        --white: var(--pfb-blanc-pur);
        --cream: var(--pfb-blanc);
        --ink: var(--pfb-noir);
        --ink-mid: var(--pfb-graphite);
        --ink-light: var(--pfb-graphite);
        --ink-faint: var(--pfb-graphite);
        --border: var(--pfb-filet);
        --border-light: var(--pfb-filet);
        --yellow-bg: var(--pfb-blanc);
        --blue: var(--pfb-noir);
        --blue-bg: var(--pfb-blanc);
        --e4-gold-deep: var(--pfb-noir);
        --e4-indigo-soft: var(--pfb-blanc);
        --e4-gold-soft: var(--pfb-blanc);
        --e4-line: var(--pfb-filet);
        background: var(--pfb-blanc-pur);
        color: var(--pfb-noir);
    }


/* ---------- Sélecteur d'apparence (Système / Clair / Sombre) ---------- */
html body .pf-theme { position: relative; display: flex; }
html body .btn-theme { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border: 0; border-radius: var(--r-xs, 6px); background: transparent; color: var(--pfb-tetiere-encre); cursor: pointer; }
html body .btn-theme:hover, html body .btn-theme[aria-expanded="true"] { background: var(--pfb-surface-2); }
html body .btn-theme__ico { display: none; }
html body .btn-theme:not([data-mode]) .btn-theme__ico--auto,
html body .btn-theme[data-mode="auto"] .btn-theme__ico--auto,
html body .btn-theme[data-mode="light"] .btn-theme__ico--light,
html body .btn-theme[data-mode="dark"] .btn-theme__ico--dark { display: block; }
html body .pf-theme-menu { position: absolute; top: calc(100% + 10px); right: 0; z-index: 300; display: grid; min-width: 160px; padding: 6px; border: 1px solid var(--pfb-ligne); border-radius: 12px; background: var(--pfb-surface); box-shadow: 0 16px 48px rgba(10, 10, 10, .18); }
html body .pf-theme-menu[hidden] { display: none; }
html body .pf-theme-menu button { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border: 0; border-radius: 8px; background: transparent; color: var(--pfb-encre); font: 500 15px/20px var(--pfb-font-texte); text-align: left; cursor: pointer; }
html body .pf-theme-menu button:hover { background: var(--pfb-surface-2); }
html body .pf-theme-menu button::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--pfb-encre-2); flex: none; }
html body .pf-theme-menu button[aria-checked="true"] { font-weight: 700; }
html body .pf-theme-menu button[aria-checked="true"]::before { background: var(--pfb-jaune); border-color: var(--pfb-jaune); }
/* Menu mobile : contrôle segmenté. */
html body .nav-mobile__theme { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 12px 0 4px; padding: 10px 12px; border-radius: 12px; background: var(--pfb-surface-2); }
html body .nav-mobile__theme-label { flex: 1 0 100%; font: 700 11px/14px var(--pfb-font-texte); letter-spacing: .08em; text-transform: uppercase; color: var(--pfb-encre-2); }
html body .nav-mobile__theme button { flex: 1; padding: 8px 6px; border: 1px solid var(--pfb-ligne); border-radius: 9999px; background: var(--pfb-surface); color: var(--pfb-encre); font: 700 14px/18px var(--pfb-font-texte); cursor: pointer; }
html body .nav-mobile__theme button[aria-checked="true"] { background: var(--pfb-jaune); border-color: var(--pfb-jaune); color: var(--pfb-noir); }
@container pfnav (max-width: 519.98px) { html body .btn-theme { width: 36px; height: 36px; } }
@container pfnav (max-width: 389.98px) { html body .pf-theme { display: none; } }

/* Têtière chargée (7 rubriques + Premium + recherche + apparence + compte) : liens resserrés. */
html body .nav-link { padding: 0 8px; }
html body .nav-logo { margin-right: 16px; }
@container pfnav (max-width: 1299.98px) { html body .nav-link { padding: 0 6px; font-size: 14px; } }

/* ---------- Îlots clairs en mode sombre ----------
   Encarts shopping (fiches produit sur fond blanc), fiches Amazon en ligne et fonds clairs posés
   en style en ligne par la rédaction (encadrés pastel, gris) : on garde le fond clair voulu et
   on repasse le texte, les liens et les variables en valeurs claires, pour rester lisible. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body .pfs-box,
    :root:not([data-theme="light"]) body .pfs-card,
    :root:not([data-theme="light"]) body .lg-home,
    :root:not([data-theme="light"]) body .vvh,
    :root:not([data-theme="light"]) body .pf-deal,
    :root:not([data-theme="light"]) body .jcc-box-x,
    :root:not([data-theme="light"]) body #content table[bgcolor],
    :root:not([data-theme="light"]) body #content td[bgcolor],
    :root:not([data-theme="light"]) body #content :is([style*="background-color: #bba3a3" i], [style*="background-color: #bba3a3;" i], [style*="background-color: #bfaeae" i], [style*="background-color: #bfaeae;" i], [style*="background-color: #c1b6b6" i], [style*="background-color: #c1b6b6;" i], [style*="background-color: #d0dfef" i], [style*="background-color: #d0dfef;" i], [style*="background-color: #d1ebf0" i], [style*="background-color: #d1ebf0;" i], [style*="background-color: #dbf0d1" i], [style*="background-color: #dbf0d1;" i], [style*="background-color: #dde8f4" i], [style*="background-color: #dde8f4;" i], [style*="background-color: #dff1f5" i], [style*="background-color: #dff1f5;" i], [style*="background-color: #e6f5df" i], [style*="background-color: #e6f5df;" i], [style*="background-color: #e8eff7" i], [style*="background-color: #e8eff7;" i], [style*="background-color: #e9f5f7" i], [style*="background-color: #e9f5f7;" i], [style*="background-color: #ebebeb" i], [style*="background-color: #ebebeb;" i], [style*="background-color: #ecf2f9" i], [style*="background-color: #ecf2f9;" i], [style*="background-color: #edf7e9" i], [style*="background-color: #edf7e9;" i], [style*="background-color: #f0f0d1" i], [style*="background-color: #f0f0d1;" i], [style*="background-color: #f2faed" i], [style*="background-color: #f2faed;" i], [style*="background-color: #f5f5df" i], [style*="background-color: #f5f5df;" i], [style*="background-color: #f5f5f5" i], [style*="background-color: #f5f5f5;" i], [style*="background-color: #f7f6f2" i], [style*="background-color: #f7f6f2;" i], [style*="background-color: #f7f7e9" i], [style*="background-color: #f7f7e9;" i], [style*="background-color: #f8f9fa" i], [style*="background-color: #f8f9fa;" i], [style*="background-color: #f9f9f9" i], [style*="background-color: #f9f9f9;" i], [style*="background-color: #fafafa" i], [style*="background-color: #fafafa;" i], [style*="background-color: #fff;" i], [style*="background-color: #fffbea" i], [style*="background-color: #fffbea;" i], [style*="background-color: #ffffff" i], [style*="background-color: #ffffff;" i], [style*="background-color: white;" i], [style*="background-color:#bba3a3" i], [style*="background-color:#bba3a3;" i], [style*="background-color:#bfaeae" i], [style*="background-color:#bfaeae;" i], [style*="background-color:#c1b6b6" i], [style*="background-color:#c1b6b6;" i], [style*="background-color:#d0dfef" i], [style*="background-color:#d0dfef;" i], [style*="background-color:#d1ebf0" i], [style*="background-color:#d1ebf0;" i], [style*="background-color:#dbf0d1" i], [style*="background-color:#dbf0d1;" i], [style*="background-color:#dde8f4" i], [style*="background-color:#dde8f4;" i], [style*="background-color:#dff1f5" i], [style*="background-color:#dff1f5;" i], [style*="background-color:#e6f5df" i], [style*="background-color:#e6f5df;" i], [style*="background-color:#e8eff7" i], [style*="background-color:#e8eff7;" i], [style*="background-color:#e9f5f7" i], [style*="background-color:#e9f5f7;" i], [style*="background-color:#ebebeb" i], [style*="background-color:#ebebeb;" i], [style*="background-color:#ecf2f9" i], [style*="background-color:#ecf2f9;" i], [style*="background-color:#edf7e9" i], [style*="background-color:#edf7e9;" i], [style*="background-color:#f0f0d1" i], [style*="background-color:#f0f0d1;" i], [style*="background-color:#f2faed" i], [style*="background-color:#f2faed;" i], [style*="background-color:#f5f5df" i], [style*="background-color:#f5f5df;" i], [style*="background-color:#f5f5f5" i], [style*="background-color:#f5f5f5;" i], [style*="background-color:#f7f6f2" i], [style*="background-color:#f7f6f2;" i], [style*="background-color:#f7f7e9" i], [style*="background-color:#f7f7e9;" i], [style*="background-color:#f8f9fa" i], [style*="background-color:#f8f9fa;" i], [style*="background-color:#f9f9f9" i], [style*="background-color:#f9f9f9;" i], [style*="background-color:#fafafa" i], [style*="background-color:#fafafa;" i], [style*="background-color:#fff;" i], [style*="background-color:#fffbea" i], [style*="background-color:#fffbea;" i], [style*="background-color:#ffffff" i], [style*="background-color:#ffffff;" i], [style*="background-color:white;" i], [style*="background: #bba3a3" i], [style*="background: #bba3a3;" i], [style*="background: #bfaeae" i], [style*="background: #bfaeae;" i], [style*="background: #c1b6b6" i], [style*="background: #c1b6b6;" i], [style*="background: #d0dfef" i], [style*="background: #d0dfef;" i], [style*="background: #d1ebf0" i], [style*="background: #d1ebf0;" i], [style*="background: #dbf0d1" i], [style*="background: #dbf0d1;" i], [style*="background: #dde8f4" i], [style*="background: #dde8f4;" i], [style*="background: #dff1f5" i], [style*="background: #dff1f5;" i], [style*="background: #e6f5df" i], [style*="background: #e6f5df;" i], [style*="background: #e8eff7" i], [style*="background: #e8eff7;" i], [style*="background: #e9f5f7" i], [style*="background: #e9f5f7;" i], [style*="background: #ebebeb" i], [style*="background: #ebebeb;" i], [style*="background: #ecf2f9" i], [style*="background: #ecf2f9;" i], [style*="background: #edf7e9" i], [style*="background: #edf7e9;" i], [style*="background: #f0f0d1" i], [style*="background: #f0f0d1;" i], [style*="background: #f2faed" i], [style*="background: #f2faed;" i], [style*="background: #f5f5df" i], [style*="background: #f5f5df;" i], [style*="background: #f5f5f5" i], [style*="background: #f5f5f5;" i], [style*="background: #f7f6f2" i], [style*="background: #f7f6f2;" i], [style*="background: #f7f7e9" i], [style*="background: #f7f7e9;" i], [style*="background: #f8f9fa" i], [style*="background: #f8f9fa;" i], [style*="background: #f9f9f9" i], [style*="background: #f9f9f9;" i], [style*="background: #fafafa" i], [style*="background: #fafafa;" i], [style*="background: #fff;" i], [style*="background: #fffbea" i], [style*="background: #fffbea;" i], [style*="background: #ffffff" i], [style*="background: #ffffff;" i], [style*="background: white;" i], [style*="background:#bba3a3" i], [style*="background:#bba3a3;" i], [style*="background:#bfaeae" i], [style*="background:#bfaeae;" i], [style*="background:#c1b6b6" i], [style*="background:#c1b6b6;" i], [style*="background:#d0dfef" i], [style*="background:#d0dfef;" i], [style*="background:#d1ebf0" i], [style*="background:#d1ebf0;" i], [style*="background:#dbf0d1" i], [style*="background:#dbf0d1;" i], [style*="background:#dde8f4" i], [style*="background:#dde8f4;" i], [style*="background:#dff1f5" i], [style*="background:#dff1f5;" i], [style*="background:#e6f5df" i], [style*="background:#e6f5df;" i], [style*="background:#e8eff7" i], [style*="background:#e8eff7;" i], [style*="background:#e9f5f7" i], [style*="background:#e9f5f7;" i], [style*="background:#ebebeb" i], [style*="background:#ebebeb;" i], [style*="background:#ecf2f9" i], [style*="background:#ecf2f9;" i], [style*="background:#edf7e9" i], [style*="background:#edf7e9;" i], [style*="background:#f0f0d1" i], [style*="background:#f0f0d1;" i], [style*="background:#f2faed" i], [style*="background:#f2faed;" i], [style*="background:#f5f5df" i], [style*="background:#f5f5df;" i], [style*="background:#f5f5f5" i], [style*="background:#f5f5f5;" i], [style*="background:#f7f6f2" i], [style*="background:#f7f6f2;" i], [style*="background:#f7f7e9" i], [style*="background:#f7f7e9;" i], [style*="background:#f8f9fa" i], [style*="background:#f8f9fa;" i], [style*="background:#f9f9f9" i], [style*="background:#f9f9f9;" i], [style*="background:#fafafa" i], [style*="background:#fafafa;" i], [style*="background:#fff;" i], [style*="background:#fffbea" i], [style*="background:#fffbea;" i], [style*="background:#ffffff" i], [style*="background:#ffffff;" i], [style*="background:white;" i]) {
        color-scheme: light;
        --pfb-fond: var(--pfb-blanc-pur);
        --pfb-surface: var(--pfb-blanc-pur);
        --pfb-surface-2: var(--pfb-blanc);
        --pfb-encre: var(--pfb-noir);
        --pfb-encre-2: var(--pfb-graphite);
        --pfb-ligne: var(--pfb-filet);
        --pfb-lien: var(--pfb-noir);
        --pfb-accent-texte: var(--pfb-noir);
        --white: var(--pfb-blanc-pur);
        --cream: var(--pfb-blanc);
        --ink: var(--pfb-noir);
        --ink-mid: var(--pfb-graphite);
        --ink-light: var(--pfb-graphite);
        --ink-faint: var(--pfb-graphite);
        --border: var(--pfb-filet);
        --border-light: var(--pfb-filet);
        --yellow-bg: var(--pfb-blanc);
        --blue: var(--pfb-noir);
        --blue-bg: var(--pfb-blanc);
        color: var(--pfb-noir);
    }
}
:root[data-theme="dark"] body .pfs-box,
    :root[data-theme="dark"] body .pfs-card,
    :root[data-theme="dark"] body .lg-home,
    :root[data-theme="dark"] body .vvh,
:root[data-theme="dark"] body .pf-deal,
:root[data-theme="dark"] body .jcc-box-x,
:root[data-theme="dark"] body #content table[bgcolor],
:root[data-theme="dark"] body #content td[bgcolor],
:root[data-theme="dark"] body #content :is([style*="background-color: #bba3a3" i], [style*="background-color: #bba3a3;" i], [style*="background-color: #bfaeae" i], [style*="background-color: #bfaeae;" i], [style*="background-color: #c1b6b6" i], [style*="background-color: #c1b6b6;" i], [style*="background-color: #d0dfef" i], [style*="background-color: #d0dfef;" i], [style*="background-color: #d1ebf0" i], [style*="background-color: #d1ebf0;" i], [style*="background-color: #dbf0d1" i], [style*="background-color: #dbf0d1;" i], [style*="background-color: #dde8f4" i], [style*="background-color: #dde8f4;" i], [style*="background-color: #dff1f5" i], [style*="background-color: #dff1f5;" i], [style*="background-color: #e6f5df" i], [style*="background-color: #e6f5df;" i], [style*="background-color: #e8eff7" i], [style*="background-color: #e8eff7;" i], [style*="background-color: #e9f5f7" i], [style*="background-color: #e9f5f7;" i], [style*="background-color: #ebebeb" i], [style*="background-color: #ebebeb;" i], [style*="background-color: #ecf2f9" i], [style*="background-color: #ecf2f9;" i], [style*="background-color: #edf7e9" i], [style*="background-color: #edf7e9;" i], [style*="background-color: #f0f0d1" i], [style*="background-color: #f0f0d1;" i], [style*="background-color: #f2faed" i], [style*="background-color: #f2faed;" i], [style*="background-color: #f5f5df" i], [style*="background-color: #f5f5df;" i], [style*="background-color: #f5f5f5" i], [style*="background-color: #f5f5f5;" i], [style*="background-color: #f7f6f2" i], [style*="background-color: #f7f6f2;" i], [style*="background-color: #f7f7e9" i], [style*="background-color: #f7f7e9;" i], [style*="background-color: #f8f9fa" i], [style*="background-color: #f8f9fa;" i], [style*="background-color: #f9f9f9" i], [style*="background-color: #f9f9f9;" i], [style*="background-color: #fafafa" i], [style*="background-color: #fafafa;" i], [style*="background-color: #fff;" i], [style*="background-color: #fffbea" i], [style*="background-color: #fffbea;" i], [style*="background-color: #ffffff" i], [style*="background-color: #ffffff;" i], [style*="background-color: white;" i], [style*="background-color:#bba3a3" i], [style*="background-color:#bba3a3;" i], [style*="background-color:#bfaeae" i], [style*="background-color:#bfaeae;" i], [style*="background-color:#c1b6b6" i], [style*="background-color:#c1b6b6;" i], [style*="background-color:#d0dfef" i], [style*="background-color:#d0dfef;" i], [style*="background-color:#d1ebf0" i], [style*="background-color:#d1ebf0;" i], [style*="background-color:#dbf0d1" i], [style*="background-color:#dbf0d1;" i], [style*="background-color:#dde8f4" i], [style*="background-color:#dde8f4;" i], [style*="background-color:#dff1f5" i], [style*="background-color:#dff1f5;" i], [style*="background-color:#e6f5df" i], [style*="background-color:#e6f5df;" i], [style*="background-color:#e8eff7" i], [style*="background-color:#e8eff7;" i], [style*="background-color:#e9f5f7" i], [style*="background-color:#e9f5f7;" i], [style*="background-color:#ebebeb" i], [style*="background-color:#ebebeb;" i], [style*="background-color:#ecf2f9" i], [style*="background-color:#ecf2f9;" i], [style*="background-color:#edf7e9" i], [style*="background-color:#edf7e9;" i], [style*="background-color:#f0f0d1" i], [style*="background-color:#f0f0d1;" i], [style*="background-color:#f2faed" i], [style*="background-color:#f2faed;" i], [style*="background-color:#f5f5df" i], [style*="background-color:#f5f5df;" i], [style*="background-color:#f5f5f5" i], [style*="background-color:#f5f5f5;" i], [style*="background-color:#f7f6f2" i], [style*="background-color:#f7f6f2;" i], [style*="background-color:#f7f7e9" i], [style*="background-color:#f7f7e9;" i], [style*="background-color:#f8f9fa" i], [style*="background-color:#f8f9fa;" i], [style*="background-color:#f9f9f9" i], [style*="background-color:#f9f9f9;" i], [style*="background-color:#fafafa" i], [style*="background-color:#fafafa;" i], [style*="background-color:#fff;" i], [style*="background-color:#fffbea" i], [style*="background-color:#fffbea;" i], [style*="background-color:#ffffff" i], [style*="background-color:#ffffff;" i], [style*="background-color:white;" i], [style*="background: #bba3a3" i], [style*="background: #bba3a3;" i], [style*="background: #bfaeae" i], [style*="background: #bfaeae;" i], [style*="background: #c1b6b6" i], [style*="background: #c1b6b6;" i], [style*="background: #d0dfef" i], [style*="background: #d0dfef;" i], [style*="background: #d1ebf0" i], [style*="background: #d1ebf0;" i], [style*="background: #dbf0d1" i], [style*="background: #dbf0d1;" i], [style*="background: #dde8f4" i], [style*="background: #dde8f4;" i], [style*="background: #dff1f5" i], [style*="background: #dff1f5;" i], [style*="background: #e6f5df" i], [style*="background: #e6f5df;" i], [style*="background: #e8eff7" i], [style*="background: #e8eff7;" i], [style*="background: #e9f5f7" i], [style*="background: #e9f5f7;" i], [style*="background: #ebebeb" i], [style*="background: #ebebeb;" i], [style*="background: #ecf2f9" i], [style*="background: #ecf2f9;" i], [style*="background: #edf7e9" i], [style*="background: #edf7e9;" i], [style*="background: #f0f0d1" i], [style*="background: #f0f0d1;" i], [style*="background: #f2faed" i], [style*="background: #f2faed;" i], [style*="background: #f5f5df" i], [style*="background: #f5f5df;" i], [style*="background: #f5f5f5" i], [style*="background: #f5f5f5;" i], [style*="background: #f7f6f2" i], [style*="background: #f7f6f2;" i], [style*="background: #f7f7e9" i], [style*="background: #f7f7e9;" i], [style*="background: #f8f9fa" i], [style*="background: #f8f9fa;" i], [style*="background: #f9f9f9" i], [style*="background: #f9f9f9;" i], [style*="background: #fafafa" i], [style*="background: #fafafa;" i], [style*="background: #fff;" i], [style*="background: #fffbea" i], [style*="background: #fffbea;" i], [style*="background: #ffffff" i], [style*="background: #ffffff;" i], [style*="background: white;" i], [style*="background:#bba3a3" i], [style*="background:#bba3a3;" i], [style*="background:#bfaeae" i], [style*="background:#bfaeae;" i], [style*="background:#c1b6b6" i], [style*="background:#c1b6b6;" i], [style*="background:#d0dfef" i], [style*="background:#d0dfef;" i], [style*="background:#d1ebf0" i], [style*="background:#d1ebf0;" i], [style*="background:#dbf0d1" i], [style*="background:#dbf0d1;" i], [style*="background:#dde8f4" i], [style*="background:#dde8f4;" i], [style*="background:#dff1f5" i], [style*="background:#dff1f5;" i], [style*="background:#e6f5df" i], [style*="background:#e6f5df;" i], [style*="background:#e8eff7" i], [style*="background:#e8eff7;" i], [style*="background:#e9f5f7" i], [style*="background:#e9f5f7;" i], [style*="background:#ebebeb" i], [style*="background:#ebebeb;" i], [style*="background:#ecf2f9" i], [style*="background:#ecf2f9;" i], [style*="background:#edf7e9" i], [style*="background:#edf7e9;" i], [style*="background:#f0f0d1" i], [style*="background:#f0f0d1;" i], [style*="background:#f2faed" i], [style*="background:#f2faed;" i], [style*="background:#f5f5df" i], [style*="background:#f5f5df;" i], [style*="background:#f5f5f5" i], [style*="background:#f5f5f5;" i], [style*="background:#f7f6f2" i], [style*="background:#f7f6f2;" i], [style*="background:#f7f7e9" i], [style*="background:#f7f7e9;" i], [style*="background:#f8f9fa" i], [style*="background:#f8f9fa;" i], [style*="background:#f9f9f9" i], [style*="background:#f9f9f9;" i], [style*="background:#fafafa" i], [style*="background:#fafafa;" i], [style*="background:#fff;" i], [style*="background:#fffbea" i], [style*="background:#fffbea;" i], [style*="background:#ffffff" i], [style*="background:#ffffff;" i], [style*="background:white;" i]) {
    color-scheme: light;
    --pfb-fond: var(--pfb-blanc-pur);
    --pfb-surface: var(--pfb-blanc-pur);
    --pfb-surface-2: var(--pfb-blanc);
    --pfb-encre: var(--pfb-noir);
    --pfb-encre-2: var(--pfb-graphite);
    --pfb-ligne: var(--pfb-filet);
    --pfb-lien: var(--pfb-noir);
    --pfb-accent-texte: var(--pfb-noir);
    --white: var(--pfb-blanc-pur);
    --cream: var(--pfb-blanc);
    --ink: var(--pfb-noir);
    --ink-mid: var(--pfb-graphite);
    --ink-light: var(--pfb-graphite);
    --ink-faint: var(--pfb-graphite);
    --border: var(--pfb-filet);
    --border-light: var(--pfb-filet);
    --yellow-bg: var(--pfb-blanc);
    --blue: var(--pfb-noir);
    --blue-bg: var(--pfb-blanc);
    color: var(--pfb-noir);
}

/* Liens et titres des îlots : Noir PF (le jaune n'est jamais du texte sur fond clair). */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body :is(.pfs-box, .pf-deal) a:not(.pfs-buy):not([class*="btn"]):not([style*="background"]) { color: var(--pfb-noir); }
}
:root[data-theme="dark"] body :is(.pfs-box, .pf-deal) a:not(.pfs-buy):not([class*="btn"]):not([style*="background"]) { color: var(--pfb-noir); }

/* Texte courant des articles et guides (p. 12) : Inter 400, 17/28 bureau, 16/26 mobile. */
html body :is(.article-body, .guide-article__body) { font-size: 16px; line-height: 26px; }
@media (min-width: 1024px) { html body :is(.article-body, .guide-article__body) { font-size: 17px; line-height: 28px; } }

/* JCC (Académie, extensions) : encre, titres et surfaces de la rubrique en mode sombre. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) { --jcc-ink: var(--pfb-blanc); --jcc-title: var(--pfb-blanc); --jcc-muted: var(--pfb-acier); --jcc-bg: var(--pfb-noir); --jcc-line: var(--pfb-graphite); }
}
:root[data-theme="dark"] { --jcc-ink: var(--pfb-blanc); --jcc-title: var(--pfb-blanc); --jcc-muted: var(--pfb-acier); --jcc-bg: var(--pfb-noir); --jcc-line: var(--pfb-graphite); }

/* Bandeaux de rubrique des actus (.nb--*) : dégradé teinté → surface du thème en mode sombre. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) body .nb[class*="nb--"] { --nb-bg: var(--pfb-surface); --nb-line: var(--pfb-graphite); }
}
:root[data-theme="dark"] body .nb[class*="nb--"] { --nb-bg: var(--pfb-surface); --nb-line: var(--pfb-graphite); }

/* Menu mobile : bouton principal jaune → texte Noir PF ; bouton secondaire au trait. */
html body .nav-mobile__cta--primary:not([style*="background"]) { background: var(--pfb-jaune); color: var(--pfb-noir); }
html body .nav-mobile__cta--ghost { color: var(--pfb-encre); border-color: var(--pfb-ligne); }
