/*
 * Lot L8 CHARTE-ESPACE-CLIENT (v2.0.48, plan du 24/11/2026) : la charte du tableau de bord (noir #111111 et terracotta
 * #B5420F, Bricolage Grotesque Bold et Inter) sur tout l'espace client en parcours Afrique, sans nouvel écran : mêmes blocs,
 * mêmes textes, mêmes tailles. Constats R-07, R-08, R-09, R-27, F-01, G-N06, VOCAL-5, DEM-06, THEME-01.
 *
 * Chargée après public/css/charte-jetons.css (jetons et redirection de l'ancienne charte), seulement quand le gabarit client
 * pose la classe lx-charte-client sur le body (App\Support\Charte::espaceClient). Toutes les règles sont limitées à cette
 * classe. Elle traite ce que la redirection des jetons ne peut pas atteindre :
 *  1. les polices, servies par l'application (fin de Google Fonts et de Bunny côté client) ;
 *  2. les couleurs de l'ancienne charte écrites en dur dans les feuilles compilées, les styles en ligne et SweetAlert ;
 *  3. les contrastes : texte blanc sur terracotta, terracotta clair sur les bandeaux sombres ;
 *  4. les classes Tailwind à valeur arbitraire de l'en-tête, du pied de page et des pages (§ 4), une règle par classe ;
 *     CharteEspaceClientTest vérifie que toute classe de ce genre écrite dans une vue de l'espace client y figure.
 *
 * Cascade : les règles du § 4 sont ajoutées à la couche « utilities » de Tailwind, avec :where() sur le body : elles battent
 * l'utilitaire de base (même spécificité, plus loin dans la page) et laissent gagner les états (survol, focus) de Tailwind.
 * Les autres règles sont hors couche, pour battre les feuilles anciennes et les styles en ligne non couchés.
 *
 * Contrastes (WCAG 2.1, AA, calculés par CharteEspaceClientTest) : blanc sur terracotta 5,6:1 ; noir sur terracotta clair
 * 9,2:1 ; terracotta clair sur noir 9,2:1 ; encre #4D585F sur le gris du pied #F7F9FB 6,9:1 ; gris discret #5E6870 sur
 * #F7F9FB 5,4:1 ; anneau de focus terracotta sur blanc 5,6:1 (élément graphique, seuil 3:1).
 */

/* ── 1. Polices ────────────────────────────────────────────────────────────────────────────────────────────────────
   Mêmes fichiers que le thème uniforme (public/css/charte-luxing.css) et le back-office : Bricolage Grotesque Bold
   (public/fonts/luxing, OFL), Inter variable (public/landing-luxing, OFL). Montserrat n'est plus servie à l'espace
   client : les règles anciennes qui la demandent en dur (feuilles compilées, styles en ligne) reçoivent Inter, les titres
   passent au Bricolage par le jeton --lx-font-display (charte-jetons.css) et par les règles ci-dessous. */
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/luxing/bricolage-grotesque-700-7963b408d724.woff2) format("woff2"),
       url(../fonts/luxing/BricolageGrotesque-Bold.ttf) format("truetype");
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../landing-luxing/inter-latin-ext-a28eb6d3ccb5.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../landing-luxing/inter-latin-c940764593d0.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../landing-luxing/inter-latin-ext-a28eb6d3ccb5.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../landing-luxing/inter-latin-c940764593d0.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Titres des composants cf-* (Montserrat en dur dans resources/css/dashboard-tw.css) et avatar : police de titre. */
body.lx-charte-client :is(.cf-page-title, .cf-card-title, .cf-section-title, .cf-modal-title, .cf-hero-headline, .cf-stat-value, .cf-empty-title) {
  font-family: var(--lx-police-titre);
}

/* ── 2. Couleurs écrites en dur hors des classes utilitaires ─────────────────────────────────────────────────────── */

/* Anneau de focus (tokens.css : bleu marine 500, devenu gris sombre) : terracotta de la charte. */
body.lx-charte-client *:focus-visible { outline-color: var(--ux-terre); }
/* Pages de connexion et du mot de passe : anneau #0A1F44 écrit en dur dans template/css/dashboard/fixes.css. */
body.lx-charte-client:is(.lx-auth-page) :is(.lx-input, input, button, a):focus-visible { outline-color: var(--ux-terre); }
body.lx-charte-client ::selection { background-color: var(--ux-terre-pale); color: var(--ux-sombre); }

/* Pied de page, grandes surfaces de la FAQ : gris clair de la charte plutôt que le terracotta pâle des pastilles. */
body.lx-charte-client .lxp-footer.bg-navy-50,
body.lx-charte-client .lx-section.bg-navy-50,
body.lx-charte-client .lx-faq-item.bg-navy-50 { background-color: var(--ux-fond-2); border-color: var(--lx-border-subtle); }
body.lx-charte-client .lx-faq-item.bg-navy-50:hover { border-color: var(--ux-filet2); }

/* ── 3. Contrastes, styles en ligne, SweetAlert, tiroir ─────────────────────────────────────────────────────────────────────────────────────────── */

/* Bandeaux sombres (titre des pages publiques, appel du pied de page) : petits textes et coches en terracotta clair,
   comme les panneaux sombres de la connexion ; le bouton d'appel y garde son texte noir (9,2:1). */
body.lx-charte-client [class*="bg-[linear-gradient(135deg,var(--lx-navy-"] {
  --lx-gold-300: var(--ux-terre-clair);
  --lx-gold-400: var(--ux-terre-clair);
  --lx-gold-500: var(--ux-terre-clair);
  --lx-gold-600: var(--ux-terre-clair);
}

/* Boutons d'appel terracotta : texte blanc (le noir n'y atteint que 3,4:1). */
body.lx-charte-client .cf-btn-gold,
body.lx-charte-client .cf-btn-gold:hover,
body.lx-charte-client .lx-btn-gold,
body.lx-charte-client .lx-btn-gold:hover { color: var(--ux-fond); }

/* Bannière des cookies (styles en ligne de layouts/frontend/master.blade.php) : bordure et ombre au noir de la charte. */
body.lx-charte-client .lx-cookie-banner { border-color: rgba(17, 17, 17, .12); box-shadow: 0 16px 40px rgba(17, 17, 17, .18); }

/* Messagerie client (styles en ligne de frontend/messagerie.blade.php) : bleu #1a3a8a écrit en dur. */
body.lx-charte-client .cf-msgr-embed .message.sent .message-content,
body.lx-charte-client .cf-msgr-embed .btn-primary,
body.lx-charte-client .cf-msgr-embed .scrollbar-primary::-webkit-scrollbar-thumb { background: var(--ux-sombre); }

/* Calcul financier des dossiers FR-CH (styles en ligne de calcul_financier/calcul.blade.php). */
body.lx-charte-client .cf-autosave--saving { color: var(--ux-sombre); }
body.lx-charte-client .cf-monthly-modal__backdrop { background: rgba(17, 17, 17, .55); }

/* Packs et facturation : encadré « or » en style en ligne (frontend/mon-abonnement.blade.php). */
body.lx-charte-client [style*="rgba(201,169,97,0.08)"] { background: var(--ux-terre-pale) !important; border-color: var(--ux-terre-halo) !important; }

/* À propos (styles en ligne de frontend/a-propos.blade.php). */
body.lx-charte-client .lx-apropos .prose-narrative p { color: var(--ux-encre2); }
body.lx-charte-client .lx-apropos .prose-narrative a { text-decoration-color: var(--ux-terre-halo); }

/* SweetAlert : les vues et public/js/cf-app.js passent l'ancienne charte en couleur de bouton. Selon la version servie par le
   CDN (sweetalert2@11, non figée), cette couleur arrive en style en ligne : « background-color » (anciennes versions) ou
   variable « --swal2-confirm-button-background-color » (11.2x, peinte par la feuille de SweetAlert sous :where()).
   - Bouton SANS couleur fournie (aucun style en ligne) : noir de la charte, au lieu du violet par défaut. Seule la variable
     est posée (une variable en ligne la remplace toujours), et « background-color » seulement sans style en ligne.
   - Bouton avec une couleur de l'ancienne charte : bleu marine -> noir, or -> terracotta (règles !important ci-dessous).
   - Bleu par défaut de SweetAlert (#3085d6) : noir de la charte (règle du lot RESTES-AUDIT-2611 ci-dessous).
   - Tout autre bouton avec une couleur explicite (rouge, vert, gris) : inchangé.
   CharteEspaceClientTest vérifie qu'aucune règle sans style de l'ancienne charte ne vise un bouton qui porte un style en
   ligne. */
body.lx-charte-client .swal2-popup .swal2-styled.swal2-confirm { --swal2-confirm-button-background-color: var(--ux-sombre); }
body.lx-charte-client .swal2-popup .swal2-styled.swal2-confirm:not([style*="background"]):not([style*="--swal2-confirm"]) { background-color: var(--ux-sombre); }
body.lx-charte-client .swal2-popup .swal2-styled:is([style*="rgb(10, 31, 68)"], [style*="rgb(26, 58, 138)"], [style*="#0a1f44" i], [style*="#1a3a8a" i]) {
  background-color: var(--ux-sombre) !important;
  --swal2-confirm-button-background-color: var(--ux-sombre) !important;
  --swal2-cancel-button-background-color: var(--ux-sombre) !important;
}
body.lx-charte-client .swal2-popup .swal2-styled:is([style*="rgb(201, 169, 97)"], [style*="#c9a961" i]) {
  background-color: var(--ux-terre) !important;
  --swal2-confirm-button-background-color: var(--ux-terre) !important;
  --swal2-cancel-button-background-color: var(--ux-terre) !important;
  color: var(--ux-fond) !important;
}
body.lx-charte-client .swal2-popup .swal2-styled.swal2-confirm:not([style*="background"]):not([style*="--swal2-confirm"]):focus { box-shadow: 0 0 0 3px var(--ux-terre-halo); }
/* Lot RESTES-AUDIT-2611 (réserve 7 du lot L8) : bleu par défaut de SweetAlert (#3085d6) passé en couleur de bouton par des
   vues de l'espace client (« Non » de l'annulation d'abonnement, confirmation de l'ancienne page d'organisation des
   chapitres) : noir de la charte. Les autres couleurs explicites (rouge, vert, gris) restent inchangées. */
body.lx-charte-client .swal2-popup .swal2-styled:is([style*="rgb(48, 133, 214)"], [style*="#3085d6" i]) {
  background-color: var(--ux-sombre) !important;
  --swal2-confirm-button-background-color: var(--ux-sombre) !important;
  --swal2-cancel-button-background-color: var(--ux-sombre) !important;
}
body.lx-charte-client .swal2-popup .swal2-title { font-family: var(--lx-police-titre); color: var(--ux-sombre); }

/* Lot RESTES-AUDIT-2611 (réserve 9 du lot L8, relecture R2) : couleurs de l'ancienne charte écrites en dur dans les feuilles
   compilées (resources/css/app-public.css, couche components ; resources/css/dashboard-tw.css), très transparentes :
   bleu marine -> noir, or -> terracotta, mêmes opacités. */
body.lx-charte-client :is(.lx-country-opt, .lx-curr-opt).is-active { box-shadow: 0 0 0 3px rgba(181, 66, 15, .15); }
body.lx-charte-client .lx-notif-dropdown-item.is-unread .lx-notif-dropdown-item-link { background: rgba(181, 66, 15, .04); }
body.lx-charte-client .lx-notif-dropdown-item.is-unread .lx-notif-dropdown-item-link:hover { background: rgba(181, 66, 15, .08); }
body.lx-charte-client :is(.cf-input, .cf-select, .cf-textarea):focus { box-shadow: 0 0 0 3px rgba(17, 17, 17, .14); }
body.lx-charte-client .lx-volume-range::-webkit-slider-thumb { box-shadow: 0 2px 6px rgba(17, 17, 17, .18); }
body.lx-charte-client .lx-volume-range::-moz-range-thumb { box-shadow: 0 2px 6px rgba(17, 17, 17, .18); }
body.lx-charte-client .lx-faq-item[open] { box-shadow: 0 12px 28px -18px rgba(17, 17, 17, .18); }
body.lx-charte-client .lxp-footer-newsletter-input-wrap { border-color: rgba(17, 17, 17, .14); }
body.lx-charte-client .lxp-footer-newsletter-input-wrap:focus-within { box-shadow: 0 0 0 3px rgba(17, 17, 17, .08); }
body.lx-charte-client .lxp-footer-newsletter-input-wrap input[type="email"]::placeholder { color: var(--ux-discret); }
body.lx-charte-client .lxp-footer-newsletter-btn:hover { box-shadow: 0 4px 12px -4px rgba(181, 66, 15, .4); }

/* Lot RESTES-AUDIT-2611 (réserve 12 du lot L8, relecture R5) : badge « Populaire » des formules (partials/plans-packs) en
   texte noir sur terracotta (3,4:1) : texte blanc, 5,6:1, comme les boutons d'appel. */
body.lx-charte-client .cf-card > .bg-gold-500.text-navy-700 { color: var(--ux-fond); }

/* Tiroir mobile de l'en-tête (resources/css/app-public.css, couche components, couleurs en dur et !important). */
@layer components {
  body.lx-charte-client .lx-nav-link--testeur {
    background: linear-gradient(135deg, rgba(181, 66, 15, .12), rgba(181, 66, 15, .04));
    border-color: var(--ux-terre-halo);
    color: var(--ux-sombre) !important;
  }
  body.lx-charte-client .lx-nav-link--testeur:hover { background: linear-gradient(135deg, rgba(181, 66, 15, .2), rgba(181, 66, 15, .08)); }
  body.lx-charte-client .lx-nav-link--cta { background: var(--ux-sombre); }
  body.lx-charte-client .lx-nav-link--cta:hover { background: var(--ux-noir); }
}

/* ── 4. Classes Tailwind à valeur arbitraire de l'ancienne charte (en-tête, pied, fenêtre de connexion, FAQ, contact) ─
   Bleu marine rgba(10,31,68,a) -> noir rgba(17,17,17,a) ; or rgba(201,169,97,a) -> terracotta rgba(181,66,15,a) ;
   textes du pied de page -> encre ou gris discret de la charte (AA sur le gris du pied). Les classes qui lisent un jeton
   avec une valeur de repli (« var(--lx-…, #0A1F44) ») suivent déjà la redirection : elles ne figurent pas ici. */
@layer utilities {
  :where(body.lx-charte-client) [class~="[&[aria-expanded=true]]:shadow-[0_4px_12px_rgba(10,31,68,0.15)]"][aria-expanded=true] { box-shadow: 0 4px 12px rgba(17,17,17,0.15); }
  :where(body.lx-charte-client) [class~="bg-[linear-gradient(135deg,rgba(201,169,97,0.12),rgba(201,169,97,0.04))]"] { background-image: linear-gradient(135deg,rgba(181,66,15,0.12),rgba(181,66,15,0.04)); }
  :where(body.lx-charte-client) [class~="bg-[linear-gradient(135deg,rgba(201,169,97,0.12)_0%,rgba(201,169,97,0.06)_100%)]"] { background-image: linear-gradient(135deg,rgba(181,66,15,0.12) 0%,rgba(181,66,15,0.06) 100%); }
  :where(body.lx-charte-client) [class~="bg-[radial-gradient(ellipse_at_center,rgba(201,169,97,0.18),transparent_60%)]"] { background-image: radial-gradient(ellipse at center,rgba(181,66,15,0.18),transparent 60%); }
  :where(body.lx-charte-client) [class~="bg-[radial-gradient(ellipse_at_center_bottom,rgba(201,169,97,0.15),transparent_60%)]"] { background-image: radial-gradient(ellipse at center bottom,rgba(181,66,15,0.15),transparent 60%); }
  :where(body.lx-charte-client) [class~="bg-[radial-gradient(ellipse_at_top_right,rgba(201,169,97,0.18),transparent_60%)]"] { background-image: radial-gradient(ellipse at top right,rgba(181,66,15,0.18),transparent 60%); }
  :where(body.lx-charte-client) [class~="bg-[rgba(10,31,68,0.06)]"] { background-color: rgba(17,17,17,0.06); }
  :where(body.lx-charte-client) [class~="bg-[rgba(10,31,68,0.6)]"] { background-color: rgba(17,17,17,0.6); }
  :where(body.lx-charte-client) [class~="border-[rgba(10,31,68,0.04)]"] { border-color: rgba(17,17,17,0.04); }
  :where(body.lx-charte-client) [class~="border-[rgba(10,31,68,0.08)]"] { border-color: rgba(17,17,17,0.08); }
  :where(body.lx-charte-client) [class~="border-[rgba(10,31,68,0.1)]"] { border-color: rgba(17,17,17,0.1); }
  :where(body.lx-charte-client) [class~="border-[rgba(10,31,68,0.14)]"] { border-color: rgba(17,17,17,0.14); }
  :where(body.lx-charte-client) [class~="focus-within:shadow-[0_0_0_3px_rgba(10,31,68,0.08)]"]:focus-within { box-shadow: 0 0 0 3px rgba(17,17,17,0.08); }
  :where(body.lx-charte-client) [class~="focus:shadow-[0_0_0_3px_rgba(10,31,68,0.1)]"]:focus { box-shadow: 0 0 0 3px rgba(17,17,17,0.1); }
  :where(body.lx-charte-client) [class~="hover:bg-[linear-gradient(135deg,rgba(201,169,97,0.18)_0%,rgba(201,169,97,0.1)_100%)]"]:hover { background-image: linear-gradient(135deg,rgba(181,66,15,0.18) 0%,rgba(181,66,15,0.1) 100%); }
  :where(body.lx-charte-client) [class~="hover:bg-[linear-gradient(135deg,rgba(201,169,97,0.2),rgba(201,169,97,0.08))]"]:hover { background-image: linear-gradient(135deg,rgba(181,66,15,0.2),rgba(181,66,15,0.08)); }
  :where(body.lx-charte-client) [class~="hover:bg-[rgba(201,169,97,0.06)]"]:hover { background-color: rgba(181,66,15,0.06); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_4px_12px_-2px_rgba(201,169,97,0.25)]"]:hover { box-shadow: 0 4px 12px -2px rgba(181,66,15,0.25); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_4px_12px_-4px_rgba(201,169,97,0.25)]"]:hover { box-shadow: 0 4px 12px -4px rgba(181,66,15,0.25); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_4px_12px_-4px_rgba(201,169,97,0.4)]"]:hover { box-shadow: 0 4px 12px -4px rgba(181,66,15,0.4); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_4px_12px_rgba(10,31,68,0.15)]"]:hover { box-shadow: 0 4px 12px rgba(17,17,17,0.15); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_6px_20px_rgba(10,31,68,0.06)]"]:hover { box-shadow: 0 6px 20px rgba(17,17,17,0.06); }
  :where(body.lx-charte-client) [class~="hover:shadow-[0_8px_24px_-4px_rgba(10,31,68,0.45),0_0_24px_-6px_rgba(201,169,97,0.6)]"]:hover { box-shadow: 0 8px 24px -4px rgba(17,17,17,0.45),0 0 24px -6px rgba(181,66,15,0.6); }
  :where(body.lx-charte-client) [class~="placeholder:text-[rgba(10,31,68,0.4)]"]::placeholder { color: var(--ux-discret); }
  :where(body.lx-charte-client) [class~="shadow-[0_16px_40px_-8px_rgba(10,31,68,0.18)]"] { box-shadow: 0 16px 40px -8px rgba(17,17,17,0.18); }
  :where(body.lx-charte-client) [class~="shadow-[0_1px_3px_rgba(10,31,68,0.06),0_2px_8px_-2px_rgba(10,31,68,0.04)]"] { box-shadow: 0 1px 3px rgba(17,17,17,0.06),0 2px 8px -2px rgba(17,17,17,0.04); }
  :where(body.lx-charte-client) [class~="shadow-[0_20px_50px_-12px_rgba(10,31,68,0.25)]"] { box-shadow: 0 20px 50px -12px rgba(17,17,17,0.25); }
  :where(body.lx-charte-client) [class~="shadow-[0_20px_60px_-12px_rgba(10,31,68,0.4)]"] { box-shadow: 0 20px 60px -12px rgba(17,17,17,0.4); }
  :where(body.lx-charte-client) [class~="shadow-[0_24px_60px_-12px_rgba(10,31,68,0.35),0_0_0_1px_rgba(255,255,255,0.8)]"] { box-shadow: 0 24px 60px -12px rgba(17,17,17,0.35),0 0 0 1px rgba(255,255,255,0.8); }
  :where(body.lx-charte-client) [class~="shadow-[0_2px_6px_-1px_rgba(201,169,97,0.5)]"] { box-shadow: 0 2px 6px -1px rgba(181,66,15,0.5); }
  :where(body.lx-charte-client) [class~="shadow-[0_4px_14px_-2px_rgba(10,31,68,0.35)]"] { box-shadow: 0 4px 14px -2px rgba(17,17,17,0.35); }
  :where(body.lx-charte-client) [class~="shadow-[0_4px_18px_rgba(10,31,68,0.04)]"] { box-shadow: 0 4px 18px rgba(17,17,17,0.04); }
  :where(body.lx-charte-client) [class~="shadow-[0_4px_18px_rgba(10,31,68,0.06)]"] { box-shadow: 0 4px 18px rgba(17,17,17,0.06); }
  :where(body.lx-charte-client) [class~="text-[rgba(10,31,68,0.55)]"] { color: var(--ux-discret); }
  :where(body.lx-charte-client) [class~="text-[rgba(10,31,68,0.68)]"] { color: var(--ux-discret); }
  :where(body.lx-charte-client) [class~="text-[rgba(10,31,68,0.7)]"] { color: var(--ux-discret); }
  :where(body.lx-charte-client) [class~="text-[rgba(10,31,68,0.72)]"] { color: var(--ux-encre2); }
  :where(body.lx-charte-client) [class~="text-[rgba(10,31,68,0.78)]"] { color: var(--ux-encre2); }
}
