/* ==========================================================================
   Scruméo — styles de l'app (espace connecté).
   Reçoit progressivement les styles jusqu'ici inline dans les templates
   (backlog #10 : migration au fil de l'eau, pas de big-bang).
   Les tokens (--g, --s1, --tx…) viennent de base.html ; les titres héritent
   de Barlow Condensed via la règle h1,h2,h3 de base.html.
   ========================================================================== */

/* Garde-fou viewport : aucun débordement horizontal, jamais. Sur mobile,
   un contenu qui dépasse à droite élargit le canevas de la page et DÉCALE
   tout élément position:fixed (les cartes de fin étaient coupées — retour
   Mel 2026-07-14, cause : halo du coach sur la page simulation). Le
   symptôme est corrigé à la source ET interdit globalement ici. */
html { overflow-x: hidden; overflow-x: clip; }

.app-wrap { max-width: 720px; margin: 0 auto; padding: 4rem 1.5rem 3rem; }
.app-eyebrow {
  color: var(--g2); font-weight: 700; letter-spacing: .15em;
  text-transform: uppercase; font-size: .8rem; margin: 0 0 .6rem;
}
.app-title {
  font-weight: 900; text-transform: uppercase; font-size: 2.25rem;
  color: var(--tx); margin: 0 0 2.5rem; line-height: 1;
}
.app-h2 {
  font-weight: 800; text-transform: uppercase; font-size: 1.3rem;
  color: var(--tx); margin: 0 0 1rem;
}
.app-empty { color: var(--mu); }
.app-empty a { color: var(--g); }
.app-cta-row { margin-top: 2.5rem; }

/* Cartes de stats principales */
.stat-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: .9rem; margin-bottom: 2.2rem;
}
.stat {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 14px; padding: 1.4rem 1rem; text-align: center;
}
.stat__num {
  font-weight: 900; font-size: 2rem; line-height: 1; margin-bottom: .3rem;
  font-variant-numeric: tabular-nums;
}
.stat__lbl { font-size: .78rem; color: var(--mu); }
.stat--xp .stat__num { color: var(--g); }
.stat--streak .stat__num { color: var(--g2); }
.stat--etapes .stat__num { color: var(--tx); }
.stat--badges .stat__num { color: #ffca4a; }

/* Détail : ce qui a rapporté l'XP */
.breakdown { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 2.6rem; }
.bd-chip {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 99px; padding: .55rem 1rem; font-size: .85rem; color: var(--mu);
}
.bd-chip b { color: var(--tx); font-weight: 800; font-variant-numeric: tabular-nums; }

/* Activité récente */
.act-list { display: flex; flex-direction: column; gap: .6rem; }
.act {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 14px; padding: .9rem 1.3rem;
  display: flex; justify-content: space-between; align-items: center;
}
.act__date { color: var(--mu); font-size: .9rem; }
.act__xp { color: var(--g); font-weight: 700; }

@media (max-width: 560px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ==== Page Mon compte ==================================================== */

.compte-ok {
  color: var(--g); font-weight: 700; margin: 0 0 1.2rem;
}
.compte-bloc {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 14px; padding: 1.4rem 1.5rem; margin-bottom: 1rem;
}
.compte-label {
  margin: 0 0 .4rem; font-size: .75rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--mu);
}
.compte-email { margin: 0; color: var(--tx); font-weight: 600; }
.compte-aide { margin: .4rem 0 0; font-size: .8rem; color: var(--mu); }
.compte-err { margin: .4rem 0 0; font-size: .85rem; color: var(--red); }
.compte-liens {
  display: flex; gap: 1.4rem; flex-wrap: wrap; margin-top: 1.6rem;
  font-size: .92rem;
}
.compte-liens a { color: var(--mu); text-decoration: none; }
.compte-liens a:hover { color: var(--tx); text-decoration: underline; }
.compte-liens .compte-logout:hover { color: var(--red); }

/* Le composant .coach-fig (mascotte, 3 tailles) vit dans landing.css :
   il sert à l'app ET à la landing marketing (une seule définition). */

/* La carte « Coach Scruméo » du hub */
.hub-grid { display: grid; grid-template-columns: 3fr 2fr; gap: 1.25rem; align-items: stretch; }
@media (max-width: 700px) { .hub-grid { grid-template-columns: 1fr; } }
.coach-card {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 18px; padding: 1.4rem; display: flex; flex-direction: column;
}
.coach-card__head { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: .9rem; }
.coach-card__eyebrow {
  color: var(--g2); text-transform: uppercase; letter-spacing: .15em;
  font-size: .72rem; font-weight: 700; margin: 0 0 .5rem;
}
.coach-card__texte { color: var(--tx); font-size: .93rem; line-height: 1.55; margin: 0; }
.coach-card__cta { margin-top: auto; padding-top: 1rem; }

/* ==== Sortie de jeu : jamais de cul-de-sac après une correction ========== */

.mj-sortie {
  position: sticky; bottom: 0; z-index: 50;
  display: flex; gap: .8rem; justify-content: center; align-items: center;
  flex-wrap: wrap; padding: 1rem;
  background: linear-gradient(180deg, transparent, var(--bg, #060d17) 35%);
  margin-top: 1.5rem;
}

/* ==== Avatars de profil (les coachs, débloqués par les badges) =========== */

.avatars-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: .7rem; margin-top: .6rem;
}
@media (max-width: 460px) { .avatars-grid { grid-template-columns: repeat(2, 1fr); } }
.avatar-opt {
  position: relative; display: flex; flex-direction: column; align-items: center;
  gap: .35rem; cursor: pointer; padding: .55rem .3rem;
  background: var(--s2); border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 12px; transition: border-color .15s;
}
.avatar-opt input { position: absolute; opacity: 0; pointer-events: none; }
.avatar-opt img {
  width: 64px; height: 64px; border-radius: 50%; object-fit: cover;
  border: 2px solid transparent;
}
.avatar-opt span { font-size: .68rem; color: var(--mu); text-align: center; line-height: 1.2; }
.avatar-opt:hover { border-color: rgba(57, 255, 126, .35); }
.avatar-opt.on, .avatar-opt:has(input:checked) {
  border-color: var(--g);
}
.avatar-opt:has(input:checked) img { border-color: var(--g); }
.avatar-opt--lock { cursor: default; opacity: .45; }
.avatar-opt--lock:hover { border-color: rgba(255, 255, 255, .07); }
.avatar-opt--lock img { filter: grayscale(.6); }

/* Teinte personnalisée de l'avatar : masque coloré transparent.
   Le VERT n'est pas proposé — c'est la couleur de Scruméo. */
.avatar-teinte {
  position: relative; display: inline-block;
  border-radius: 50%; overflow: hidden; line-height: 0;
}
.avatar-teinte::after {
  content: ''; position: absolute; inset: 0;
  background: var(--teinte, transparent);
  mix-blend-mode: color; opacity: .85; pointer-events: none;
}
.avatar-teinte--bleu { --teinte: #3da9ff; }
.avatar-teinte--turquoise { --teinte: #00e5c8; }
.avatar-teinte--violet { --teinte: #9b7cf4; }
.avatar-teinte--rose { --teinte: #ff5fa2; }
.avatar-teinte--orange { --teinte: #ff9950; }
.avatar-teinte--jaune { --teinte: #ffd84d; }
.avatar-teinte--rouge { --teinte: #ff5050; }

/* Pastilles de choix de couleur */
.teintes { display: flex; gap: .55rem; flex-wrap: wrap; margin-top: .5rem; }
.teinte input { position: absolute; opacity: 0; pointer-events: none; }
.teinte__pastille {
  width: 30px; height: 30px; border-radius: 50%; display: block;
  background: var(--sw); border: 2px solid transparent; cursor: pointer;
  transition: transform .12s;
}
.teinte__pastille:hover { transform: scale(1.12); }
.teinte input:checked + .teinte__pastille {
  border-color: var(--tx); box-shadow: 0 0 0 3px rgba(255, 255, 255, .15);
}

/* Interrupteur de préférence (vibrations…) */
.compte-toggle {
  display: flex; gap: .6rem; align-items: center; cursor: pointer;
  color: var(--tx); font-size: .92rem;
}
.compte-toggle input { width: 18px; height: 18px; accent-color: var(--g); }

/* Avatar dans l'en-tête du hub */
.hub-avatar {
  width: 58px; height: 58px; border-radius: 50%; object-fit: cover;
  border: 2px solid rgba(57, 255, 126, .5);
  box-shadow: 0 0 18px rgba(57, 255, 126, .25);
  flex: none;
}

/* ==== Onboarding : l'accueil du coach (première visite du hub) =========== */

.scr-onb {
  position: fixed; inset: 0; z-index: 460;
  display: flex; align-items: center; justify-content: center;
  background: rgba(6, 13, 23, .88); backdrop-filter: blur(8px);
}
.scr-onb__box {
  position: relative; display: flex; gap: 2.2rem; align-items: center;
  max-width: 620px; width: 92%;
  background: var(--s1); border: 1px solid var(--line-green, rgba(57,255,126,.35));
  border-radius: 22px; padding: 2.2rem 2.4rem;
  box-shadow: 0 0 70px rgba(57, 255, 126, .15);
}
.scr-onb__close {
  position: absolute; top: .9rem; right: 1.1rem;
  background: none; border: none; color: var(--mu); font-size: 1rem;
  cursor: pointer; padding: .3rem;
}
.scr-onb__close:hover { color: var(--tx); }
.scr-onb__fig { flex: 0 0 170px; }
.scr-onb__corps { flex: 1; min-width: 0; }
.scr-onb__eyebrow {
  margin: 0 0 .6rem; font-size: .72rem; font-weight: 700;
  letter-spacing: .2em; text-transform: uppercase; color: var(--g2);
}
.scr-onb__slide { min-height: 150px; }
.scr-onb__slide h2 {
  margin: 0 0 .7rem; font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900; font-size: 1.9rem; line-height: 1.05;
  text-transform: none; color: var(--tx);
}
.scr-onb__slide p { margin: 0; color: var(--mu); line-height: 1.6; font-size: .95rem; }
.scr-onb__dots { display: flex; gap: .45rem; margin: 1rem 0 1.2rem; }
.scr-onb__dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255, 255, 255, .18);
}
.scr-onb__dot.on { background: var(--g); }
@media (max-width: 560px) {
  .scr-onb__box { flex-direction: column; text-align: center; padding: 1.8rem 1.4rem; }
  .scr-onb__fig { flex-basis: auto; max-width: 120px; }
  .scr-onb__dots { justify-content: center; }
}

/* ==== Fin d'exercice unifiée (Scr.fin) =================================== */

.scr-fin {
  position: fixed; inset: 0; z-index: 440;
  display: flex; align-items: center; justify-content: center;
  background: rgba(6, 13, 23, .82); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .3s ease;
}
.scr-fin.in { opacity: 1; }
.scr-fin__box {
  display: flex; gap: 1.6rem; align-items: center;
  max-width: 520px; width: 92%;
  background: var(--s1); border: 1px solid var(--line-green, rgba(57,255,126,.35));
  border-radius: 22px; padding: 1.8rem 2rem;
  box-shadow: 0 0 60px rgba(57, 255, 126, .15);
  transform: scale(.9); transition: transform .35s cubic-bezier(.2, .9, .3, 1.3);
}
.scr-fin.in .scr-fin__box { transform: scale(1); }
.scr-fin__corps { flex: 1; min-width: 0; }
.scr-fin__titre {
  margin: 0 0 .2rem; font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900; text-transform: uppercase; font-size: 1.8rem;
  color: var(--tx); line-height: 1;
}
.scr-fin__xp { font-weight: 900; font-size: 1.3rem; color: var(--g); margin: 0 0 1rem; }
.scr-fin__mot { color: var(--mu); font-size: .9rem; margin: 0 0 1.1rem; line-height: 1.5; }
.scr-fin__stats { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.scr-fin__stat {
  background: var(--s2); border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 10px; padding: .45rem .8rem; font-size: .82rem; color: var(--mu);
}
.scr-fin__stat b { color: var(--tx); font-variant-numeric: tabular-nums; }
.scr-fin__actions { display: flex; gap: .7rem; flex-wrap: wrap; align-items: center; }

/* Variante défaite (retour review 20/07 : « du rouge au minimum pour
   l'échec ») : bordure, titre et stat fautive — pas un écran anxiogène. */
.scr-fin__box--echec {
  border-color: rgba(255, 80, 80, .45);
  box-shadow: 0 0 60px rgba(255, 80, 80, .14);
}
.scr-fin__box--echec .scr-fin__titre { color: var(--red); }
.scr-fin__box--echec .scr-fin__xp { color: var(--mu); }
.scr-fin__stat--faute { border-color: rgba(255, 80, 80, .4); color: #ffb3b3; }
.scr-fin__stat--faute b { color: var(--red); }
.btn-rejouer {
  background: none; border: 1px solid rgba(255, 80, 80, .5); color: #ffb3b3;
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  border-radius: 999px; padding: 8px 18px; cursor: pointer; font-family: inherit;
  text-decoration: none; display: inline-block; transition: background .2s, color .2s;
}
.btn-rejouer:hover { background: rgba(255, 80, 80, .12); color: #fff; }

@media (max-width: 520px) {
  /* Carte de succès centrée et compacte (même langage que la fin de démo) —
     l'ancrage bas + grand vide sombre faisait « cassé » (retour Mel). */
  .scr-fin { padding: 1rem; }
  .scr-fin__box {
    flex-direction: column; text-align: center;
    width: 92%; max-width: 380px; padding: 1.6rem 1.3rem;
    max-height: 88vh; overflow-y: auto;
  }
  .scr-fin__box .coach-fig--buste { margin: 0 auto; }
  .scr-fin__stats { justify-content: center; }
  .scr-fin__actions { flex-direction: column; align-items: stretch; }
  .scr-fin__actions a, .scr-fin__actions button { text-align: center; }
}

/* ==== Feedback unifié : toast XP + célébration de badge (feedback.js) ==== */

.scr-toast-xp {
  position: fixed; bottom: 34px; left: 50%; z-index: 400;
  transform: translateX(-50%) translateY(16px); opacity: 0;
  background: var(--grad); color: var(--ink-on-green, #04130b);
  font-weight: 900; font-size: 1.05rem; letter-spacing: .02em;
  font-variant-numeric: tabular-nums;
  padding: .6rem 1.4rem; border-radius: 999px;
  box-shadow: 0 8px 30px rgba(57, 255, 126, .35);
  transition: transform .35s cubic-bezier(.2, .9, .3, 1.3), opacity .35s ease;
  pointer-events: none;
}
.scr-toast-xp.in { transform: translateX(-50%) translateY(0); opacity: 1; }

.scr-badge-pop {
  position: fixed; inset: 0; z-index: 450;
  display: flex; align-items: center; justify-content: center;
  background: rgba(6, 13, 23, .82); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .3s ease;
}
.scr-badge-pop.in { opacity: 1; }
.scr-badge-pop__box {
  position: relative; text-align: center; max-width: 340px; width: 90%;
  background: var(--s1); border: 1px solid var(--line-green);
  border-radius: 22px; padding: 2.6rem 2.2rem 2.2rem;
  box-shadow: 0 0 60px rgba(57, 255, 126, .18);
  transform: scale(.85); transition: transform .4s cubic-bezier(.2, .9, .3, 1.4);
}
.scr-badge-pop.in .scr-badge-pop__box { transform: scale(1); }
.scr-badge-pop__coach { display: flex; justify-content: center; margin-bottom: .6rem; }
.scr-badge-pop__halo {
  position: absolute; top: -30px; left: 50%; transform: translateX(-50%);
  width: 180px; height: 180px; pointer-events: none;
  background: radial-gradient(circle, rgba(57, 255, 126, .3), transparent 65%);
}
.scr-badge-pop__ico {
  font-size: 4rem; line-height: 1; margin-bottom: .8rem;
  animation: scr-badge-bounce .8s cubic-bezier(.2, .9, .3, 1.4);
}
.scr-badge-pop__lbl {
  margin: 0 0 .3rem; font-size: .72rem; font-weight: 700;
  letter-spacing: .22em; text-transform: uppercase; color: var(--g2, #00e5c8);
}
.scr-badge-pop__titre {
  margin: 0 0 1.6rem; font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900; text-transform: uppercase; font-size: 1.7rem;
  color: var(--tx, #e6edf6); line-height: 1.05;
}
@keyframes scr-badge-bounce {
  0% { transform: scale(0) rotate(-16deg); }
  60% { transform: scale(1.18) rotate(5deg); }
  100% { transform: scale(1) rotate(0); }
}
@media (prefers-reduced-motion: reduce) {
  .scr-toast-xp, .scr-badge-pop, .scr-badge-pop__box { transition: none; }
  .scr-badge-pop__ico { animation: none; }
}

/* ==== Fin de démo : célébration + création de compte (feedback.js) ==== */

.scr-demo {
  position: fixed; inset: 0; z-index: 460;
  display: flex; align-items: center; justify-content: center;
  background: rgba(6, 13, 23, .85); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .3s ease;
  padding: 1rem;
}
.scr-demo.in { opacity: 1; }
.scr-demo__box {
  position: relative; text-align: center; max-width: 380px; width: 92%;
  background: var(--s1); border: 1px solid var(--line-green, rgba(57,255,126,.35));
  border-radius: 22px; padding: 2.4rem 2rem 2rem;
  box-shadow: 0 0 60px rgba(57, 255, 126, .18);
  transform: scale(.85); transition: transform .4s cubic-bezier(.2, .9, .3, 1.4);
  max-height: 92vh; overflow-y: auto;
}
.scr-demo.in .scr-demo__box { transform: scale(1); }
.scr-demo__coach { display: flex; justify-content: center; margin-bottom: .5rem; }
.scr-demo__coach .coach-fig { animation: scr-demo-bounce .7s cubic-bezier(.2, .9, .3, 1.4); }
.scr-demo__halo {
  position: absolute; top: -30px; left: 50%; transform: translateX(-50%);
  width: 200px; height: 200px; pointer-events: none;
  background: radial-gradient(circle, rgba(57, 255, 126, .3), transparent 65%);
}
.scr-demo__lbl {
  margin: 0 0 .3rem; font-size: .72rem; font-weight: 700;
  letter-spacing: .22em; text-transform: uppercase; color: var(--g2, #00e5c8);
}
.scr-demo__titre {
  margin: 0; font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900; text-transform: uppercase; font-size: 1.5rem;
  color: var(--tx, #e6edf6); line-height: 1.05;
}
.scr-demo__xp {
  margin: .2rem 0 1rem; font-weight: 900; font-size: 2.2rem; color: var(--g);
  font-variant-numeric: tabular-nums;
  animation: scr-badge-bounce .8s cubic-bezier(.2, .9, .3, 1.4);
}
.scr-demo__mot {
  margin: 0 0 1.6rem; color: var(--mu); font-size: .92rem; line-height: 1.55;
}
.scr-demo__actions { display: flex; flex-direction: column; gap: .7rem; align-items: stretch; }
.scr-demo__actions a, .scr-demo__actions button { text-align: center; }
@keyframes scr-demo-bounce {
  0% { transform: translateY(14px) scale(.9); }
  60% { transform: translateY(-4px) scale(1.05); }
  100% { transform: translateY(0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .scr-demo, .scr-demo__box { transition: none; }
  .scr-demo__coach .coach-fig, .scr-demo__xp { animation: none; }
}

/* ==== Hub refondu (retours review 20/07) ================================
   Un écran desktop sans scroll : en-tête compact + stats, reprise du
   dernier parcours joué, coach, une carte par parcours. */
.hub2 { max-width: 62rem; margin: 0 auto; padding: 0 1.5rem; }
.hub2__head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.4rem; flex-wrap: wrap; }
.hub2__head h1 { margin: 0; font-weight: 900; text-transform: uppercase; font-size: 2rem; color: var(--tx); line-height: 1.05; }
.hub2__stats { display: flex; gap: .5rem; margin-left: auto; flex-wrap: wrap; }
.hub2__stats .chip {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 99px; padding: .35rem .8rem; font-size: .78rem;
  color: var(--mu); white-space: nowrap;
}
.hub2__grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1.1rem; align-items: stretch; }
@media (max-width: 860px) { .hub2__grid { grid-template-columns: 1fr; } }

.parc-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: .7rem; margin-top: 1.1rem; }
@media (max-width: 860px) { .parc-cards { grid-template-columns: repeat(2, 1fr); } }
.parc-card {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 14px; padding: .85rem .95rem; text-decoration: none;
  transition: border-color .2s, transform .15s;
}
.parc-card:hover { border-color: rgba(57, 255, 126, .35); transform: translateY(-2px); }
.parc-card__nom { display: flex; align-items: center; gap: .45rem; font-weight: 800; text-transform: uppercase; font-size: .85rem; color: var(--tx); margin-bottom: .55rem; }
.parc-card__bar { height: 6px; border-radius: 99px; background: var(--s2); overflow: hidden; margin-bottom: .4rem; }
.parc-card__fill { height: 100%; background: var(--grad); }
.parc-card__cap { font-size: .72rem; color: var(--mu); }
.parc-card--zero .parc-card__fill { background: rgba(255, 255, 255, .18); }

/* ==== Page tarifs (retour review 20/07) =================================
   Occasionnel (un parcours) vs récurrent (Scruméo+). Violet = premium. */
.tarifs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; align-items: stretch; }
@media (max-width: 860px) { .tarifs-grid { grid-template-columns: 1fr; max-width: 26rem; margin-inline: auto; } }
.tarif {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 18px; padding: 1.6rem 1.5rem; display: flex; flex-direction: column;
  position: relative;
}
.tarif--star { border-color: rgba(155, 124, 244, .55); box-shadow: 0 0 44px rgba(155, 124, 244, .14); }
.tarif__pop {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--purple); color: #120a26; font-size: .64rem; font-weight: 800;
  letter-spacing: .1em; text-transform: uppercase; border-radius: 999px; padding: .3rem .9rem;
  white-space: nowrap;
}
.tarif__nom { margin: 0 0 .2rem; font-size: 1.25rem; font-weight: 800; text-transform: uppercase; color: var(--tx); }
.tarif__prix { margin: 0 0 .2rem; font-size: 2.3rem; font-weight: 900; color: var(--tx); }
.tarif__prix small { font-size: .85rem; color: var(--mu); font-weight: 600; }
.tarif--star .tarif__prix { color: var(--purple); }
.tarif--libre .tarif__prix { color: var(--g); }
.tarif__sous { margin: 0 0 1.1rem; font-size: .8rem; color: var(--mu); }
.tarif__liste { list-style: none; margin: 0 0 1.4rem; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.tarif__liste li { display: flex; gap: .5rem; font-size: .85rem; color: var(--tx); line-height: 1.45; }
.tarif__liste li::before { content: '✓'; color: var(--g); font-weight: 900; flex: none; }
.tarif__liste li.non { color: var(--mu); }
.tarif__liste li.non::before { content: '—'; color: var(--mu2); }
.tarif__cta { margin-top: auto; text-align: center; }
.tarif__cta--violet {
  background: linear-gradient(135deg, #9b7cf4, #6d5bd0); color: #fff;
  box-shadow: 0 10px 40px rgba(155, 124, 244, .3);
}
.tarif__note { text-align: center; color: var(--mu); font-size: .78rem; margin-top: 1.6rem; }
/* Résiliation en un clic : un bouton qui a l'air d'un lien (c'est un POST) */
.tarif__lien {
  background: none; border: 0; padding: 0; cursor: pointer; font-family: inherit;
  color: var(--mu); font-size: .82rem; text-decoration: underline;
}
.tarif__lien:hover { color: var(--tx); }
.tarif__message {
  margin: 0 auto 1.6rem; max-width: 34rem; padding: .7rem 1rem; border-radius: 12px;
  text-align: center; font-size: .9rem; color: var(--tx);
  background: rgba(57, 255, 126, .08); border: 1px solid var(--line-green);
}
.tarif__message--erreur { background: rgba(255, 80, 80, .08); border-color: rgba(255, 80, 80, .35); }

/* ==== Compte : sections + suppression par email (retours review 20/07) == */
.compte-section {
  margin: 2.2rem 0 .9rem; display: flex; align-items: center; gap: .8rem;
}
.compte-section h2 {
  margin: 0; font-size: 1.05rem; font-weight: 800; text-transform: uppercase;
  color: var(--tx); letter-spacing: .04em;
}
.compte-section::after { content: ''; flex: 1; height: 1px; background: rgba(255, 255, 255, .1); }
.compte-section__ico { font-size: 1.1rem; }

.supp-danger {
  border: 1px solid rgba(255, 80, 80, .4); background: rgba(255, 80, 80, .05);
  border-radius: 14px; padding: 1.3rem 1.4rem;
}
.btn-danger {
  background: var(--red); color: #fff; border: none; border-radius: 999px;
  font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  padding: 10px 20px; cursor: pointer; font-family: inherit; opacity: .45;
  transition: opacity .2s;
}
.btn-danger.actif { opacity: 1; }
.btn-danger.actif:hover { background: #ff6b6b; }

/* ==== Avatars (retours review 20/07) ====================================
   Grille éclaircie (fini le robot noir sur fond noir) + frise d'évolution
   du hub : départ → stade actuel → formes suivantes (tablette/desktop). */
.avatar-lum img {
  filter: brightness(1.28) contrast(1.05) !important;
  background: radial-gradient(circle at 50% 35%, rgba(57, 255, 126, .16), rgba(10, 21, 37, 0) 70%);
}
.avatar-lum .avatar-opt--lock img { filter: brightness(.9) grayscale(.6) !important; }

.avatar-evo {
  display: flex; align-items: flex-end; gap: 1.1rem;
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 16px; padding: 1rem 1.2rem; margin-top: 1.25rem;
}
@media (max-width: 700px) { .avatar-evo { display: none; } }
.avatar-evo__stade { text-align: center; flex: 1; }
.avatar-evo__img {
  width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin: 0 auto .4rem;
  filter: brightness(1.28) contrast(1.05);
}
.avatar-evo__stade--futur .avatar-evo__img { filter: brightness(.55) grayscale(.8); }
.avatar-evo__stade--actuel .avatar-evo__img {
  border: 2px solid var(--g); box-shadow: 0 0 22px rgba(57, 255, 126, .35);
  width: 76px; height: 76px;
}
.avatar-evo__stade--max .avatar-evo__img { box-shadow: 0 0 26px rgba(155, 124, 244, .5); border: 2px solid var(--purple); }
.avatar-evo__lbl { font-size: .68rem; color: var(--mu); line-height: 1.3; }
.avatar-evo__fleche { color: var(--mu2); font-size: 1.2rem; padding-bottom: 1.4rem; }

/* ==== Jeux : barre latérale de niveau (retour review 20/07) =============
   Progression du niveau cliquable + leçon consultable pendant le jeu.
   La classe jeu-layout n'est posée que quand le jeu appartient à une
   carte (sinon la page garde sa mise en page pleine largeur). */
.jeu-layout {
  display: grid; grid-template-columns: 218px minmax(0, 1fr);
  gap: 1.6rem; max-width: 76rem; margin: 0 auto; padding: 0 1.25rem;
  align-items: start;
}
.jeu-main { min-width: 0; }
.jeu-side { position: sticky; top: 110px; display: flex; flex-direction: column; gap: 1rem; }
.jeu-side__titre {
  margin: 0; font-size: .68rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; color: var(--g2);
}
.jeu-etapes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .3rem; }
.jeu-etapes a, .jeu-etapes span.off {
  display: flex; align-items: center; gap: .55rem;
  padding: .5rem .65rem; border-radius: 9px; font-size: .82rem;
  color: var(--mu); text-decoration: none;
}
.jeu-etapes a:hover { background: var(--s2); color: var(--tx); }
.jeu-etapes .on { background: var(--s2); color: var(--tx); border: 1px solid rgba(57, 255, 126, .35); }
.jeu-etapes .fait { color: var(--g); }
.jeu-etapes span.off { opacity: .45; }
.jeu-side__lecon {
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 12px; padding: .85rem .95rem; font-size: .8rem; color: var(--mu);
  line-height: 1.5;
}
.jeu-side__lecon a { color: var(--g2); }
@media (max-width: 860px) {
  .jeu-layout { display: block; }
  .jeu-side { position: static; margin-bottom: 1rem; }
  /* sur mobile, la carte reste la référence : seule la leçon consultable
     accompagne le jeu (la liste prendrait tout le premier écran) */
  .jeu-side .jeu-etapes { display: none; }
}

/* Variante fine du bouton d'action (hub « Reprendre / Commencer », retour
   Mel 03/10 : bouton affiné, sans flèche) */
.scr-nav-cta--fin { padding: 6px 14px; font-size: 11px; letter-spacing: .06em; }

/* ==== Jeux libres (relecture Mel 03/10) : une rubrique par famille, puis
   ses jeux. Tuiles de famille (écran 1), lignes de jeu (écran 2) et la
   coche « déjà joué » du retour review 20/07. */
.familles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 760px) { .familles-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 460px) { .familles-grid { grid-template-columns: 1fr; } }
.famille-tile {
  display: flex; flex-direction: column; gap: .3rem; min-height: 11rem;
  padding: 1.4rem 1.3rem; border-radius: 16px;
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  color: var(--tx); text-decoration: none;
  transition: border-color .2s, transform .15s;
}
.famille-tile:hover { border-color: var(--line-green); transform: translateY(-2px); }
.famille-tile__ico { font-size: 2.2rem; line-height: 1; }
.famille-tile__nom { font-weight: 900; text-transform: uppercase; font-size: 1.1rem; margin-top: .5rem; }
.famille-tile__accroche { color: var(--mu); font-size: .85rem; flex: 1; }
.famille-tile__compte { color: var(--g); font-weight: 700; font-size: .8rem; margin-top: .6rem; }

.mj-row {
  position: relative; display: flex; align-items: center; gap: 1rem;
  padding: 1.25rem 1.5rem; border-radius: 14px;
  background: var(--s1); border: 1px solid rgba(255, 255, 255, .06);
  color: var(--tx); text-decoration: none;
  transition: border-color .2s, transform .15s;
}
.mj-row:hover { border-color: var(--line-green); transform: translateY(-1px); }
.mj-row__ico { font-size: 1.6rem; }
.mj-row__corps { flex: 1; }
.mj-row__titre { display: block; font-weight: 800; text-transform: uppercase; font-size: 1.05rem; }
.mj-row__sous { display: block; color: var(--mu); font-size: .85rem; margin-top: .15rem; }
.mj-row__xp { color: var(--g); font-weight: 700; font-size: .85rem; white-space: nowrap; }
.mj-done {
  flex: none; width: 24px; height: 24px; border-radius: 50%;
  background: var(--grad); color: var(--ink-on-green, #04130b);
  display: grid; place-items: center; font-size: .8rem; font-weight: 900;
}
.mj-done--pas { background: none; border: 1px dashed rgba(255, 255, 255, .25); color: transparent; }

/* Le coach flottant (includes/scrbot.html) est stylé dans landing.css,
   la feuille commune aux deux bases : il vit aussi sur l'accueil. */
