@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400&family=Space+Grotesk:wght@300;400;500;600&display=swap');

/* ============================================================
   RESPECT ESSENCE — THÈME COMMUN DU SITE CLIENT
   ------------------------------------------------------------
   Toutes les couleurs du site sont ici. Pour changer une couleur
   partout, modifie seulement la valeur dans :root ci-dessous.

   Règles de confort des yeux :
   - jamais de blanc pur (var(--re-texte)) ni de noir pur (var(--re-fond)) en grande surface ;
   - texte blanc cassé doux, texte secondaire gris ;
   - le vert seulement en accent (boutons, points, chiffres clés).

   À charger sur chaque page client, APRÈS style.css et aurora.css :
     <link rel="stylesheet" href="theme.css">
   (La page Pilotage, admin.html, a son propre thème.)
   ============================================================ */

:root {
  /* ================= PALETTE RESPECT ESSENCE (seul endroit où les couleurs sont écrites) ================= */

  /* Fonds (noirs teintés vert, pour la profondeur) */
  --re-fond:        #0A0E0C;  /* fond de page */
  --re-carte:       #121813;  /* cartes, blocs */
  --re-carte-haut:  #1B241E;  /* carte au survol / élevée */
  --re-bordure:     #242B26;  /* bordures discrètes */

  /* Textes */
  --re-texte:       #F3F4F0;  /* texte principal */
  --re-texte-2:     #C4CCC5;  /* texte secondaire */
  --re-texte-3:     #A7B0A9;  /* texte discret / légendes */

  /* Couleurs fortes */
  --re-vert:        #25D366;  /* ACTION : boutons valider, liens actifs, accents principaux */
  --re-vert-survol: #1FB857;  /* survol du vert */

  /* ---- Système vert « vivant » (accueil, voir vivant.css) : 3 verts + leurs lueurs ---- */
  --re-emeraude:    #11804F;  /* émeraude profond : halos de fond */
  --re-menthe:      #6EE7A8;  /* menthe lumineux : accents, lueurs, particules */
  --re-vert-nuit:   #0A1C14;  /* vert très sombre : dégradés de fond, cartes « verre » */
  --lueur-douce:    0 0 18px color-mix(in srgb, var(--re-menthe) 22%, transparent);   /* titres, chiffres */
  --lueur-moyenne:  0 0 26px color-mix(in srgb, var(--re-menthe) 34%, transparent);   /* prix recommandé, survol */
  --lueur-cta:      0 10px 34px -6px color-mix(in srgb, var(--re-vert) 80%, transparent), 0 0 0 6px color-mix(in srgb, var(--re-vert) 12%, transparent); /* la plus forte : bouton principal seulement */
  --halo-intensite: 0.55;     /* force des halos de fond (0 = éteints, 1 = maximum) */
  --respiration:    8s;       /* durée d'une respiration des halos */
  --verre-fond:     color-mix(in srgb, var(--re-vert-nuit) 62%, transparent);          /* fond des cartes « verre » */
  --verre-bordure:  color-mix(in srgb, var(--re-menthe) 14%, transparent);             /* bordure au repos */
  --verre-bordure-vive: color-mix(in srgb, var(--re-menthe) 46%, transparent);         /* bordure au survol */
  --trait-lumineux: linear-gradient(90deg, transparent, color-mix(in srgb, var(--re-menthe) 50%, transparent), transparent); /* séparateur */
  --re-or:          #E8B84B;  /* VIP : badges, titres débloqués, prix, paliers premium */
  --re-or-texte:    #412402;  /* texte posé SUR un fond doré */

  /* Les 4 piliers */
  --re-mentalite:   #8B7FF0;  /* violet */
  --re-equilibre:   #2DD4BF;  /* cyan */
  --re-discipline:  #F97A52;  /* orange */
  --re-croissance:  #25D366;  /* vert (même que --re-vert) */

  /* Gamification */
  --re-flamme:      #FB8C3C;  /* orange : flamme / série active */

  /* Messages d'erreur (pas de rouge dans la palette : l'orange de Discipline sert d'alerte) */
  --re-alerte:      var(--re-discipline);

  /* ================= Variables historiques du site, rebranchées sur la palette ================= */
  /* (les pages s'en servent encore : elles suivent automatiquement les valeurs ci-dessus) */

  /* ---- Fonds ---- */
  --fond:            var(--re-fond);
  --fond-2:          color-mix(in srgb, var(--re-carte) 55%, var(--re-fond));   /* bandes de section */
  --carte:           var(--re-carte);
  --carte-2:         var(--re-carte-haut);   /* carte dans une carte, champs de saisie */
  --contour:         var(--re-bordure);
  --contour-fort:    color-mix(in srgb, var(--re-texte-3) 28%, var(--re-bordure));

  /* ---- Textes ---- */
  --texte:           var(--re-texte);
  --texte-2:         var(--re-texte-2);
  --texte-3:         var(--re-texte-3);

  /* ---- Vert de la marque ---- */
  --vert:            var(--re-vert);
  --vert-clair:      var(--re-vert-survol);
  --vert-vif:        var(--re-vert);
  --vert-fond:       color-mix(in srgb, var(--re-vert) 10%, transparent);
  --vert-contour:    color-mix(in srgb, var(--re-vert) 35%, transparent);
  --sur-vert:        var(--re-fond);   /* texte posé sur un bouton vert */

  /* ---- Alertes ---- */
  --alerte:          var(--re-alerte);
  --alerte-fond:     color-mix(in srgb, var(--re-alerte) 10%, transparent);

  /* ---- Formes ---- */
  --rayon:           20px;
  --rayon-moyen:     14px;
  --rayon-petit:     10px;
  --ombre-carte:     0 1px 0 color-mix(in srgb, var(--re-texte) 4%, transparent) inset, 0 18px 40px -24px color-mix(in srgb, var(--re-fond) 90%, transparent);
  --satin:           radial-gradient(120% 70% at 15% -20%, color-mix(in srgb, var(--re-texte) 4.5%, transparent), transparent 55%);

  /* ---- Polices ---- */
  --police-titre:    'Cormorant Garamond', Georgia, serif;
  --police-texte:    'Space Grotesk', 'DM Sans', system-ui, sans-serif;

  /* ---- Anciennes variables de style.css, rebranchées sur le thème ---- */
  --noir:            var(--fond);
  --noir-2:          var(--fond-2);
  --noir-3:          var(--carte);
  --gris-fonce:      var(--carte-2);
  --gris:            var(--texte-3);
  --gris-moyen:      var(--texte-3);
  --gris-clair:      var(--texte-2);
  --blanc:           var(--texte);
  --blanc-pur:       var(--texte);
  --vert-accent:     var(--vert);
  --vert-pale:       var(--vert-clair);
  --or:              var(--vert);
  --or-clair:        var(--vert-vif);
}

/* ============================================================
   BASE
   ============================================================ */
html { background: var(--fond); }
body {
  background: var(--fond);
  color: var(--texte);
  font-family: var(--police-texte);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
/* L'ancienne lueur verte animée de style.css est retirée : fond calme */
body::before { display: none !important; }
::selection { background: color-mix(in srgb, var(--re-vert) 30%, transparent); color: var(--texte); }
::-webkit-scrollbar-track { background: var(--fond); }
::-webkit-scrollbar-thumb { background: color-mix(in srgb, var(--re-texte) 18%, transparent); border-radius: 4px; }
a { color: var(--vert-clair); }
:focus-visible { outline: 2px solid var(--vert-vif); outline-offset: 3px; }

/* Aurore très légère : on la devine, elle ne prend jamais le dessus */
#aurora-ciel { opacity: 0.30; background: var(--fond); }
#aurora-voile { background: linear-gradient(180deg, color-mix(in srgb, var(--re-fond) 35%, transparent), color-mix(in srgb, var(--re-fond) 55%, transparent)); }

/* ============================================================
   COMPOSANTS RÉUTILISABLES  (préfixe « t- » pour « thème »)
   ============================================================ */

/* Section : beaucoup d'air, une idée par section */
.t-section { padding: 7.5rem 1.5rem; position: relative; }
.t-conteneur { max-width: 1120px; margin: 0 auto; }
.t-centre { text-align: center; }
.t-centre .t-etiquette { justify-content: center; }
.t-centre .t-intro { margin-left: auto; margin-right: auto; }

/* Petite étiquette en majuscules espacées, avec un point vert */
.t-etiquette {
  display: inline-flex; align-items: center; gap: 0.7rem; margin: 0 0 1.4rem;
  font-family: var(--police-texte); font-size: 0.78rem; font-weight: 500;
  letter-spacing: 0.24em; text-transform: uppercase; color: var(--texte-2);
}
.t-etiquette::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
  background: var(--vert-vif); box-shadow: 0 0 10px color-mix(in srgb, var(--re-vert) 45%, transparent);
}

/* Titres : serif élégant */
.t-titre {
  font-family: var(--police-titre); font-weight: 300; color: var(--texte);
  font-size: clamp(2.25rem, 4.6vw, 3.6rem); line-height: 1.1; letter-spacing: -0.01em; margin: 0 0 1.2rem;
}
.t-titre em, .t-titre .t-gris { font-style: italic; color: var(--texte-2); }
.t-intro { color: var(--texte-2); font-size: 1.05rem; line-height: 1.8; max-width: 620px; margin: 0 0 2.5rem; }

/* Carte noir satiné */
.t-carte {
  background: var(--satin), var(--carte);
  border: 1px solid var(--contour);
  border-radius: var(--rayon);
  box-shadow: var(--ombre-carte);
  padding: 1.8rem;
}
.t-carte-titre { font-family: var(--police-titre); font-weight: 400; font-size: 1.55rem; line-height: 1.2; color: var(--texte); margin: 0 0 0.6rem; }
.t-carte p { color: var(--texte-2); margin: 0; }
.t-libelle { font-size: 0.75rem; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--texte-2); margin: 0 0 0.8rem; }
.t-chiffre { font-family: var(--police-titre); font-size: 2.6rem; line-height: 1; color: var(--vert-vif); font-variant-numeric: lining-nums; }

/* Grilles */
.t-grille { display: grid; gap: 1.2rem; }
.t-grille-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.t-grille-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.t-grille-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Boutons (au moins 48 px de haut) */
.t-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 50px; padding: 0 1.8rem; border-radius: 999px;
  font-family: var(--police-texte); font-size: 0.95rem; font-weight: 500; letter-spacing: 0.01em;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.t-btn-plein { background: var(--vert); color: var(--sur-vert); box-shadow: 0 8px 26px -10px color-mix(in srgb, var(--re-vert) 55%, transparent); }
.t-btn-plein:hover { background: var(--vert-clair); transform: translateY(-1px); }
.t-btn-contour { background: transparent; color: var(--texte); border-color: var(--contour-fort); }
.t-btn-contour:hover { border-color: var(--vert-contour); color: var(--vert-clair); transform: translateY(-1px); }

/* Accordéon (FAQ) */
.t-faq { max-width: 760px; margin: 0 auto; }
.t-faq details { border-bottom: 1px solid var(--contour); }
.t-faq summary {
  list-style: none; cursor: pointer; min-height: 56px; padding: 1.1rem 0;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  font-size: 1.05rem; color: var(--texte);
}
.t-faq summary::-webkit-details-marker { display: none; }
.t-faq summary::after { content: '+'; color: var(--vert); font-size: 1.4rem; line-height: 1; flex-shrink: 0; }
.t-faq details[open] summary::after { content: '–'; }
.t-faq details p { color: var(--texte-2); padding: 0 0 1.3rem; margin: 0; max-width: 680px; }

/* Harmonisation des boutons déjà présents dans les pages (même forme que .t-btn).
   On ne force que la forme et la typographie : les couleurs restent celles de chaque page.
   !important parce que les styles des pages sont chargés après ce fichier. */
.btn-primary, .btn-secondary, .form-submit, .eng-btn, .bouton, .bouton-avis, .rituel-fait, .al-bouton,
.cta-btn, .rs-bouton, .lc-bouton, .aller-loin-bouton, .exo-btn, .lien-compte, .pc-action, .ac-ouvrir {
  border-radius: 999px !important;
  text-transform: none !important;
  letter-spacing: 0.01em !important;
  font-family: var(--police-texte) !important;
  font-weight: 500;
}

/* ============================================================
   EFFETS (voir effets.js) — mouvement doux, jamais imposé :
   tout s'arrête si le visiteur a demandé moins d'animations.
   ============================================================ */

/* Flèche qui avance sur les boutons d'action principaux */
.fx-fleche::after { content: '→'; display: inline-block; margin-left: 0.15rem; transition: transform .25s ease; }
.fx-fleche:hover::after, .fx-fleche:focus-visible::after { transform: translateX(4px); }

/* Bouton principal qui « respire » doucement */
@keyframes fx-respire {
  0%, 100% { box-shadow: 0 8px 26px -10px color-mix(in srgb, var(--re-vert) 55%, transparent), 0 0 0 0 color-mix(in srgb, var(--re-vert) 0%, transparent); }
  50%      { box-shadow: 0 10px 34px -8px color-mix(in srgb, var(--re-vert) 75%, transparent), 0 0 0 6px color-mix(in srgb, var(--re-vert) 10%, transparent); }
}
.fx-eclat { animation: fx-respire 4.5s ease-in-out infinite; }

/* Contour lumineux qui tourne lentement (offre recommandée) */
@property --fx-angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
@keyframes fx-tour { to { --fx-angle: 360deg; } }
.fx-bordure { position: relative; isolation: isolate; }
.fx-bordure::before {
  content: ''; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; pointer-events: none; z-index: 0;
  background: conic-gradient(from var(--fx-angle), transparent 0 55%, color-mix(in srgb, var(--re-vert) 90%, transparent) 72%, color-mix(in srgb, var(--re-vert) 90%, transparent) 80%, transparent 92%);
  -webkit-mask: linear-gradient(var(--re-fond) 0 0) content-box, linear-gradient(var(--re-fond) 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: fx-tour 7s linear infinite;
}

/* Lumière qui suit le pointeur sur les cartes (ordinateur seulement) */
/* (le halo est dessiné sous le contenu de la carte, au-dessus de son fond, grâce à « isolation ») */
.fx-lumiere { position: relative; isolation: isolate; }
.fx-halo {
  position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s ease; z-index: -1;
  background: radial-gradient(420px circle at var(--lx, 50%) var(--ly, 50%), color-mix(in srgb, var(--re-vert) 10%, transparent), transparent 60%);
}
.fx-lumiere:hover > .fx-halo { opacity: 1; }

/* Lueur qui respire derrière une illustration */
@keyframes fx-lueur { 0%, 100% { transform: scale(1); opacity: 0.55; } 50% { transform: scale(1.12); opacity: 0.85; } }
.fx-lueur { position: absolute; inset: 8% 4%; border-radius: 50%; pointer-events: none; z-index: 0; filter: blur(40px);
  background: radial-gradient(closest-side, color-mix(in srgb, var(--re-vert) 35%, transparent), color-mix(in srgb, var(--re-vert) 8%, transparent) 60%, transparent); animation: fx-lueur 8s ease-in-out infinite; }

/* Flamme qui vacille */
@keyframes fx-flamme { 0%, 100% { transform: scale(1) rotate(0deg); } 30% { transform: scale(1.06, 0.97) rotate(-2deg); } 60% { transform: scale(0.97, 1.05) rotate(2deg); } }
.ico-flamme { transform-origin: 50% 90%; animation: fx-flamme 2.6s ease-in-out infinite; }

/* Barre d'action collante sur téléphone (apparaît après le haut de page) */
.fx-cta { display: none; }
@media (max-width: 760px) {
  .fx-cta {
    display: flex; position: fixed; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 1500;
    flex-direction: column; align-items: stretch; gap: 0.35rem; padding: 0.7rem; border-radius: 22px;
    background: color-mix(in srgb, var(--re-carte) 86%, transparent); border: 1px solid var(--contour-fort);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 18px 40px -12px color-mix(in srgb, var(--re-fond) 70%, transparent);
    transform: translateY(calc(100% + 24px)); opacity: 0; transition: transform .35s ease, opacity .35s ease; pointer-events: none;
  }
  .fx-cta.fx-visible { transform: none; opacity: 1; pointer-events: auto; }
  .fx-cta .t-btn { width: 100%; }
  .fx-cta-note { text-align: center; font-size: 0.82rem; color: var(--texte-2); }
}

@media (prefers-reduced-motion: reduce) {
  .fx-eclat, .fx-bordure::before, .fx-lueur, .ico-flamme { animation: none !important; }
  .fx-fleche::after, .fx-halo, .fx-cta { transition: none !important; }
}

/* Apparition douce au défilement (voir nav-compte.js) */
[data-apparition] { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
[data-apparition].t-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-apparition] { opacity: 1; transform: none; transition: none; }
}

/* ============================================================
   TÉLÉPHONE ET TABLETTE
   ============================================================ */
@media (max-width: 900px) {
  .t-grille-3, .t-grille-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .t-section { padding: 5rem 1.25rem; }
  .t-grille-2, .t-grille-3, .t-grille-4 { grid-template-columns: 1fr; }
  .t-titre { font-size: clamp(2.25rem, 9vw, 2.8rem); }
  .t-carte { padding: 1.5rem; }
  .t-btn { width: 100%; min-height: 52px; }
}

/* ============================================================
   CURSEURS DU BILAN D'ÉVOLUTION (Diagnostic Essence et Mon espace)
   Grand bouton rond utilisable au pouce. Tant que la personne n'a pas
   touché la barre, aucune valeur n'est retenue (classe .vide).
   ============================================================ */
.curseurs { display: grid; gap: 0.4rem; margin: 0 0 1.4rem; padding: 0; list-style: none; }
.curseur { display: grid; gap: 0.35rem; padding: 0.9rem 0 0.7rem; border-bottom: 1px solid var(--contour); }
.curseur:last-child { border-bottom: none; }
.curseur-tete { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.curseur-libelle { color: var(--texte); font-weight: 500; line-height: 1.4; }
.curseur-valeur { font-family: var(--police-titre); font-size: 1.7rem; line-height: 1; color: var(--texte); min-width: 2.2ch; text-align: right; flex-shrink: 0; }
.curseur.vide .curseur-valeur { font-family: inherit; font-size: 0.82rem; color: var(--texte-3); min-width: 0; white-space: nowrap; }
.curseur-echelle { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--texte-3); }
input[type="range"].curseur-barre {
  -webkit-appearance: none; appearance: none; width: 100%; height: 48px; margin: 0; padding: 0;
  background: transparent; cursor: pointer; touch-action: pan-y; --remplissage: 50%;
}
.curseur-barre::-webkit-slider-runnable-track {
  height: 8px; border-radius: 99px;
  background: linear-gradient(to right, var(--vert) var(--remplissage), var(--contour-fort) var(--remplissage));
}
.curseur-barre::-moz-range-track { height: 8px; border-radius: 99px; background: var(--contour-fort); }
.curseur-barre::-moz-range-progress { height: 8px; border-radius: 99px; background: var(--vert); }
.curseur-barre::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 34px; height: 34px; margin-top: -13px; border-radius: 50%;
  background: var(--texte); border: 3px solid var(--vert); box-shadow: 0 2px 10px color-mix(in srgb, var(--re-fond) 45%, transparent);
}
.curseur-barre::-moz-range-thumb {
  width: 28px; height: 28px; border-radius: 50%; background: var(--texte); border: 3px solid var(--vert); box-shadow: 0 2px 10px color-mix(in srgb, var(--re-fond) 45%, transparent);
}
.curseur.vide .curseur-barre::-webkit-slider-runnable-track { background: var(--contour-fort); }
.curseur.vide .curseur-barre::-moz-range-progress { background: transparent; }
.curseur.vide .curseur-barre::-webkit-slider-thumb { background: var(--carte-2); border-color: var(--contour-fort); }
.curseur.vide .curseur-barre::-moz-range-thumb { background: var(--carte-2); border-color: var(--contour-fort); }
.curseur-barre:focus { outline: none; }
.curseur-barre:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px var(--vert-contour); }
.curseur-barre:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 4px var(--vert-contour); }
.curseurs-prive { display: flex; gap: 0.5rem; align-items: flex-start; font-size: 0.88rem; color: var(--texte-2); line-height: 1.55; margin: 0 0 1.2rem; }
.curseurs-prive::before { content: ''; width: 7px; height: 7px; margin-top: 0.5em; border-radius: 50%; background: var(--vert); flex-shrink: 0; }

/* ============================================================
   RÔLES DES COULEURS (palette --re-*)
   - Le VERT reste la couleur dominante : actions, liens, progression.
   - Le DORÉ seulement en petites touches VIP : prix des packs, badges « Recommandé »,
     paliers et titres débloqués.
   - La couleur d'un PILIER n'apparaît que sur ce qui concerne ce pilier (attribut data-pilier).
   - La FLAMME (série de jours) a sa propre couleur.
   « :root » devant chaque règle : elle passe avant les styles écrits dans les pages.
   ============================================================ */

/* ---- Doré VIP ---- */
:root .ac-prix, :root .pack-prix, :root .rpd-prix, :root .lc-prix, :root .aller-loin-prix, :root .prix { color: var(--re-or); }
:root .ac-pack-badge, :root .rpd-badge, :root .pack-etiquette { background: var(--re-or); color: var(--re-or-texte); border-color: var(--re-or); }
:root .badge-onglet:not(.gratuit) { border-color: color-mix(in srgb, var(--re-or) 45%, transparent); color: var(--re-or); }
:root .palier.atteint .palier-num, :root .palier.actuel .palier-num { color: var(--re-or); }
:root .badge-serie.titre .badge-nombre, :root .ligne-titre.atteint .titre-nom { color: var(--re-or); }
:root .ligne-titre.atteint { border-color: color-mix(in srgb, var(--re-or) 35%, transparent); }
:root .titre-icone { filter: none; }
:root .rs-test { color: var(--re-or-texte); }

/* ---- Piliers : chaque élément marqué data-pilier prend la couleur de son pilier ---- */
[data-pilier="mentalite"]  { --pilier: var(--re-mentalite); }
[data-pilier="equilibre"]  { --pilier: var(--re-equilibre); }
[data-pilier="discipline"] { --pilier: var(--re-discipline); }
[data-pilier="croissance"] { --pilier: var(--re-croissance); }
:root .system-card[data-pilier], :root .diag-card[data-pilier], :root .travail-card[data-pilier] {
  border-top: 2px solid var(--pilier);
  background-image: linear-gradient(180deg, color-mix(in srgb, var(--pilier) 9%, transparent), transparent 60%);
}
:root [data-pilier] .system-card-label, :root [data-pilier] .diag-pillar, :root [data-pilier] .travail-pilier { color: var(--pilier); }
:root .espace-pilier[data-pilier] a { color: var(--pilier); }
:root .espace-pilier[data-pilier]::before { background: var(--pilier) !important; box-shadow: 0 0 10px color-mix(in srgb, var(--pilier) 55%, transparent); }
:root .cp-resultat-pilier[data-pilier] span { color: var(--pilier); }

/* ---- Flamme (série de jours actifs) : couleur dédiée + pulsation douce ---- */
:root .ico-flamme, :root .ac-flamme, :root .flamme-nombre, :root .rpd-flamme, :root .badge-serie:not(.titre) .badge-nombre { color: var(--re-flamme); fill: var(--re-flamme); }
/* (pastille « série » de l'accueil seulement : pas la tuile « Ta flamme » de Mon espace) */
:root .ac-flamme:not(.ac-valeur) { background: color-mix(in srgb, var(--re-flamme) 10%, transparent); border-color: color-mix(in srgb, var(--re-flamme) 35%, transparent); }
:root .flamme-icone, :root .badge-serie:not(.titre) .badge-icone { filter: none; } /* l'émoji 🔥 garde sa couleur de feu */
@keyframes re-flamme-pulse {
  0%, 100% { filter: drop-shadow(0 0 0 transparent); }
  50%      { filter: drop-shadow(0 0 6px color-mix(in srgb, var(--re-flamme) 70%, transparent)); }
}
:root .ico-flamme, :root .flamme-icone, :root .badge-serie:not(.titre) .badge-icone { animation: fx-flamme 2.6s ease-in-out infinite, re-flamme-pulse 2.6s ease-in-out infinite; }

/* ---- Cartes : 3 niveaux de fond, la carte s'éclaire au survol ou au toucher ---- */
.t-carte, .bloc-compte, .pack, .system-card, .diag-card, .travail-card, .ac-tuile, .tuile-stat {
  transition: background-color .25s ease, border-color .25s ease, transform .25s ease;
}
@media (hover: hover) {
  .t-carte:hover, .pack:hover, .system-card:hover, .diag-card:hover, .travail-card:hover, .ac-tuile:hover, .tuile-stat:hover {
    background-color: var(--re-carte-haut);
    border-color: color-mix(in srgb, var(--re-vert) 22%, var(--re-bordure));
  }
  .t-carte:hover { background: var(--satin), var(--re-carte-haut); }
}
.t-carte:active, .pack:active, .system-card:active, .diag-card:active, .travail-card:active { background-color: var(--re-carte-haut); }

/* ---- Barres de progression et de palier : elles se remplissent à l'arrivée ---- */
@keyframes re-remplir { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.cp-piste span, .remplissage, .barre-remplie, .ac-barre span, .progression-remplie, .objectif-rempli, .palier-segment.atteint, .palier-segment.actuel .remplissage {
  transform-origin: left center;
  animation: re-remplir 0.9s cubic-bezier(.2, .8, .2, 1) both;
}

@media (prefers-reduced-motion: reduce) {
  :root .ico-flamme, :root .flamme-icone, :root .badge-serie .badge-icone { animation: none !important; }
  .cp-piste span, .remplissage, .barre-remplie, .ac-barre span, .progression-remplie, .objectif-rempli, .palier-segment.atteint, .palier-segment.actuel .remplissage { animation: none !important; }
  .t-carte, .bloc-compte, .pack, .system-card, .diag-card, .travail-card, .ac-tuile, .tuile-stat { transition: none; }
}