/*
 * Répartie — styles de l'app (repris du prototype validé).
 * Les couleurs et les polices viennent de apps/repartie/app.json,
 * injectées par noyau/identite.php sur :root (--fond, --accent...).
 * Ici, on ne fait que donner aux jetons de l'identité les noms
 * qu'utilise le prototype : cobalt pour ta réplique, munition pour
 * le surligneur.
 */
:root {
  --cobalt: var(--accent);
  --sur-cobalt: var(--sur-accent);
  --cobalt-texte: var(--accent-texte, var(--accent));
  --cobalt-doux: color-mix(in srgb, var(--accent-texte, var(--accent)) 10%, transparent);
  --munition: var(--accent2);
  --sur-munition: var(--sur-accent2);
  --titre: var(--police-titre);
  --texte: var(--police-texte);
  /* Couleurs des trois courbes du graphique d'entraînement */
  --s1: #3448D8; --s2: #B8740F; --s3: #13866C;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="clair"]) { --s1: #6F7DEB; --s2: #C0862A; --s3: #2F9E83; }
}
:root[data-theme="sombre"] { --s1: #6F7DEB; --s2: #C0862A; --s3: #2F9E83; }
html, body { height: 100%; }
body { background: var(--fond); color: var(--encre); font: 400 16px/1.55 var(--texte); -webkit-font-smoothing: antialiased; margin: 0; }
* { box-sizing: border-box; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--cobalt-texte); outline-offset: 3px; border-radius: 6px; }

.app { max-width: 480px; margin: 0 auto; padding-inline: 18px; padding-block: 16px 110px; min-height: 100%; display: flex; flex-direction: column; gap: 22px; }
.app.plein { padding-block-end: 32px; }
.marque { font-family: var(--titre); font-weight: 900; font-stretch: 72%; font-size: 27px; letter-spacing: -0.01em; text-transform: uppercase; line-height: 1; }
.marque span { color: var(--cobalt-texte); }
.surtitre { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--gris); font-weight: 700; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
h1 { font-family: var(--titre); font-weight: 850; font-stretch: 80%; font-size: clamp(30px, 8.6vw, 40px); line-height: 1.02; letter-spacing: -0.01em; }
h2 { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 24px; line-height: 1.1; }
p { margin: 0; }
.t2 { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 24px; line-height: 1.1; display: block; text-wrap: balance; }
.scene { font-style: italic; font-size: clamp(19px, 5.2vw, 22px); line-height: 1.45; }
.truc { font-family: var(--titre); font-weight: 700; font-stretch: 90%; font-size: 23px; line-height: 1.2; }
.discret { color: var(--gris); font-size: 16px; }
.petit { font-size: 14.5px; color: var(--gris); }
.pile { display: flex; flex-direction: column; gap: 12px; }
.pile-l { display: flex; flex-direction: column; gap: 22px; }
.rangee { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.entre { display: flex; justify-content: space-between; align-items: center; gap: 12px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 24px; border-radius: 999px; border: 2px solid transparent; font-weight: 700; font-size: 16px; background: var(--cobalt); color: var(--sur-cobalt); width: 100%; transition: transform .12s ease; text-align: center; }
.btn:active { transform: scale(.985); }
.btn.fantome { background: transparent; color: var(--encre); border-color: var(--encre); }
.btn.lien { background: none; border: 0; color: var(--gris); min-height: 40px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; width: auto; padding: 0 4px; }
.btn.court { width: auto; min-height: 44px; padding: 0 18px; font-size: 15px; }
.mini { border: 1.5px solid var(--trait); background: var(--surface); border-radius: 999px; min-height: 36px; padding: 0 12px; font-size: 15px; font-weight: 600; }
.mini[aria-pressed="true"] { background: var(--encre); color: var(--fond); border-color: var(--encre); }

.carte { background: var(--surface); border: 1px solid var(--trait); border-radius: 16px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.carte.sobre { background: transparent; }
.hack { background: var(--encre); color: var(--fond); border-radius: 16px; padding: 18px; display: flex; flex-direction: column; gap: 8px; }
.hack .surtitre { color: inherit; opacity: .7; }
.hack strong { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 23px; line-height: 1.12; }

/* La pique : une bulle à angles vifs avec sa queue, la munition au surligneur */
.bulle { position: relative; background: var(--surface); border: 2px solid var(--encre); border-radius: 4px 18px 18px 18px; padding: 16px 18px 18px; margin-bottom: 14px; }
.bulle::after { content: ""; position: absolute; left: 22px; bottom: -14px; width: 22px; height: 14px; background: var(--encre); clip-path: polygon(0 0, 100% 0, 0 100%); }
.bulle::before { content: ""; position: absolute; left: 24px; bottom: -9px; width: 16px; height: 9px; background: var(--surface); clip-path: polygon(0 0, 100% 0, 0 100%); z-index: 1; }
.pique { font-family: var(--titre); font-weight: 800; font-stretch: 78%; font-size: clamp(28px, 8vw, 36px); line-height: 1.08; letter-spacing: -0.005em; }
.bulle.moyenne .pique { font-size: 24px; }
mark { background: linear-gradient(transparent 12%, var(--munition) 12%, var(--munition) 88%, transparent 88%); color: var(--sur-munition); padding: 0 .08em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.terrain { display: inline-block; font-size: 13.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; border: 1.5px solid currentColor; border-radius: 4px; padding: 1px 6px; }

.repliques { display: flex; flex-direction: column; padding-left: 26px; }
.replique { display: flex; flex-direction: column; gap: 6px; padding: 12px 0; border-top: 1px solid var(--trait); }
.replique:first-child { border-top: 0; padding-top: 4px; }
.replique .dit { font-weight: 600; font-size: 17px; line-height: 1.38; }
.replique .dit::before { content: "↩ "; color: var(--cobalt-texte); font-weight: 700; }
.replique.mien .dit { color: var(--cobalt-texte); }
.tag { font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: var(--gris); }
.replique.mien .tag { color: var(--cobalt-texte); }

.puces { display: flex; flex-wrap: wrap; gap: 8px; }
.puce { border: 1.5px solid var(--trait); background: var(--surface); border-radius: 999px; padding: 8px 14px; font-size: 15px; line-height: 1.25; text-align: left; }
.puce[aria-pressed="true"] { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); font-weight: 700; }
.puce.coche::before { content: ""; display: inline-block; width: 12px; height: 12px; border: 1.5px solid currentColor; border-radius: 3px; margin-right: 8px; vertical-align: -1px; }
.puce.coche[aria-pressed="true"]::before { background: currentColor; }

label.titre-champ, .titre-champ { font-size: 15px; color: var(--gris); font-weight: 700; display: block; }
textarea, input[type="text"], input[type="email"], input[type="time"] { width: 100%; background: var(--surface); border: 1.5px solid var(--trait); border-radius: 12px; padding: 12px 14px; line-height: 1.45; resize: vertical; font-size: 16px; }
textarea::placeholder, input::placeholder { color: var(--gris); opacity: .75; }
textarea:focus, input:focus { border-color: var(--cobalt-texte); outline: none; }

.options { display: flex; flex-direction: column; gap: 10px; }
.option { text-align: left; border: 1.5px solid var(--trait); background: var(--surface); border-radius: 12px; padding: 14px 16px; line-height: 1.4; }
.option.choisi, .option.bonne { border-color: var(--cobalt-texte); background: var(--cobalt-doux); }
.option.choisi { border-width: 2px; }
.option.ratee { opacity: .6; }
.option .tag { display: block; margin-bottom: 2px; }
.retour { color: var(--cobalt-texte); font-weight: 600; }

/* Séance */
.barre-seance { display: flex; flex-direction: column; gap: 10px; position: sticky; top: env(safe-area-inset-top, 0px); padding: 10px 0 12px; background: var(--fond); z-index: 5; }
.fermer { width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--trait); background: var(--surface); font-size: 20px; line-height: 1; }
.temps { display: flex; gap: 6px; }
.temps span { width: 26px; height: 5px; border-radius: 1px; background: var(--trait); }
.temps span.fait { background: var(--encre); }
.temps span.en-cours { background: var(--cobalt); }
.etiquette-temps { font-size: 13.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--cobalt-texte); font-weight: 700; }
details.source { border-top: 1px solid var(--trait); padding-top: 12px; }
details.source summary { cursor: pointer; color: var(--gris); font-size: 15px; }
details.source p { margin-top: 8px; font-size: 15px; color: var(--gris); line-height: 1.5; }
.reduit { border-left: 3px solid var(--munition); padding: 4px 0 4px 14px; }

/* Chrono de 10 secondes */
.chrono-bloc { display: flex; align-items: center; gap: 14px; }
.chrono { font-family: var(--titre); font-weight: 900; font-stretch: 70%; font-size: 58px; line-height: .9; font-variant-numeric: tabular-nums; min-width: 1.3ch; color: var(--cobalt-texte); }
.chrono.urgent { color: var(--s2); }
.jauge { flex: 1; height: 10px; border-radius: 2px; background: var(--relief); overflow: hidden; }
.jauge i { display: block; height: 100%; width: 100%; background: var(--cobalt); transform-origin: left; }

.notes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.note-tuile { background: var(--surface); border: 1px solid var(--trait); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.note-tuile b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 34px; line-height: 1; font-variant-numeric: tabular-nums; }
.note-tuile b small { font-size: 15px; color: var(--gris); font-weight: 600; }
.note-tuile .petit { line-height: 1.35; }

.lunes { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; }
.lune { aspect-ratio: 1; max-width: 100%; border-radius: 6px; border: 1.5px solid var(--trait); background: var(--surface); padding: 0; display: grid; place-items: center; font-size: 11px; color: var(--gris); font-variant-numeric: tabular-nums; }
.lune.faite { background: var(--encre); border-color: var(--encre); color: var(--fond); font-weight: 700; }
.lune.prochaine { border: 2px solid var(--cobalt-texte); color: var(--cobalt-texte); font-weight: 700; }
.lune.bilan { border-radius: 50%; }
.lune[disabled] { cursor: default; opacity: .55; }
.legende { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13.5px; color: var(--gris); align-items: center; }
.legende i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; border: 1.5px solid var(--trait); margin-right: 6px; vertical-align: -1px; }
.legende i.f { background: var(--encre); border-color: var(--encre); }
.legende i.p { border-color: var(--cobalt-texte); }
.legende i.b { border-radius: 50%; }
.legende i.l { width: 16px; height: 3px; border: 0; border-radius: 2px; vertical-align: 3px; }

.liste { display: flex; flex-direction: column; }
.ligne { display: flex; justify-content: space-between; gap: 14px; align-items: center; padding: 14px 0; border: 0; border-bottom: 1px solid var(--trait); background: none; text-align: left; width: 100%; }
.ligne:last-child { border-bottom: 0; }
.ligne .corps { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ligne .fl { color: var(--gris); }
.jour-tag { display: inline-block; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; background: var(--munition); color: var(--sur-munition); border-radius: 3px; padding: 1px 6px; }
.note-texte { white-space: pre-wrap; }
table.compare { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; font-size: 15px; }
table.compare th, table.compare td { text-align: right; padding: 8px 0; border-bottom: 1px solid var(--trait); }
table.compare th:first-child, table.compare td:first-child { text-align: left; }
table.compare th { font-size: 13.5px; color: var(--gris); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }

.graph { width: 100%; height: auto; display: block; overflow: visible; }
.graph text { fill: var(--gris); font-size: 11px; font-family: var(--texte); }
.graph text.val { fill: var(--encre); font-weight: 700; }

nav.onglets { position: fixed; left: 0; right: 0; bottom: 0; padding-bottom: env(safe-area-inset-bottom, 0px); background: var(--surface); border-top: 1px solid var(--trait); z-index: 10; }
nav.onglets .in { max-width: 480px; margin: 0 auto; display: flex; justify-content: space-around; padding: 0 4px; }
nav.onglets .in button { flex: 1 1 auto; }
nav.onglets button { background: none; border: 0; min-height: 62px; font-size: 13px; white-space: nowrap; color: var(--gris); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 0 4px; }
nav.onglets button::before { content: ""; width: 20px; height: 3px; border-radius: 1px; background: transparent; }
nav.onglets button[aria-current="page"] { color: var(--encre); font-weight: 700; }
nav.onglets button[aria-current="page"]::before { background: var(--cobalt); }

.toast { width: max-content; position: fixed; left: 50%; bottom: calc(82px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--encre); color: var(--fond); padding: 10px 16px; border-radius: 10px; font-weight: 700; font-size: 15px; z-index: 20; max-width: calc(100% - 32px); text-align: center; }
.orientation { font-size: 14.5px; color: var(--gris); border-top: 1px solid var(--trait); padding-top: 14px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* Inscription, installation, rappels */
a.btn { text-decoration: none; }
input[type="time"] { width: auto; }

/* Explication de l'arrivée et carte « Comment ça marche » */
.intro { font-size: 17px; line-height: 1.5; }
.etapes { list-style: none; counter-reset: etape; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.etapes li { counter-increment: etape; display: flex; gap: 12px; align-items: flex-start; line-height: 1.4; }
.etapes li::before { content: counter(etape); flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--cobalt); color: var(--sur-cobalt); font-weight: 800; font-size: 15px; display: grid; place-items: center; margin-top: -1px; }
.guide .btn { align-self: flex-start; }
.intro-carte { gap: 18px; }
.intro-carte > .pile + .pile { border-top: 1px solid var(--trait); padding-top: 16px; }
/* Les « pourquoi » : du problème de base à ce qui fait vraiment mal */
.pourquoi { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.pourquoi li { font-size: 17px; line-height: 1.45; color: var(--gris); }
.pourquoi li:last-child { color: var(--encre); font-weight: 700; }
.objectif { font-family: var(--titre); font-weight: 850; font-stretch: 80%; font-size: clamp(28px, 7.6vw, 36px); line-height: 1.04; color: var(--cobalt-texte); text-wrap: balance; }
.pourquoi li.vise { color: var(--cobalt-texte); font-weight: 700; }
/* Texte de la campagne de pub, en haut de l'arrivée */
.hero-campagne { gap: 10px; }
.hero-campagne h1 { color: var(--encre); }
/* Réponse à voix haute */
.micro { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-weight: 600; }
.micro .btn.lien { margin-left: auto; }
.micro-point { width: 12px; height: 12px; border-radius: 50%; background: var(--s2); flex: none; animation: micro-pouls 1.2s ease-in-out infinite; }
@keyframes micro-pouls { 50% { opacity: .25; transform: scale(.8); } }
@media (prefers-reduced-motion: reduce) { .micro-point { animation: none; } }
/* Le coach (analyse par l'IA) */
.coach { border-color: var(--cobalt-texte); }
.coach-verdict { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 21px; line-height: 1.2; }
.coach-charge { display: flex; align-items: center; gap: 12px; font-weight: 600; padding: 6px 0; }
.roue { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--relief); border-top-color: var(--cobalt-texte); flex: none; animation: roue .8s linear infinite; }
@keyframes roue { to { transform: rotate(360deg); } }
.coach-note b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 38px; line-height: 1; color: var(--cobalt-texte); font-variant-numeric: tabular-nums; }
.coach-note small { font-size: 15px; color: var(--gris); font-weight: 600; }
.coach-details { border-top: 1px solid var(--trait); padding-top: 10px; }
@media (prefers-reduced-motion: reduce) { .roue { animation-duration: 2.4s; } }
.coach-encourage { font-weight: 700; color: var(--cobalt-texte); }

/* Carnet de répliques : le type de chaque réplique */
.type { align-self: flex-start; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border-radius: 3px; padding: 2px 7px; }
.type-moi { background: var(--relief); color: var(--encre); }
.type-mieux { background: var(--cobalt); color: var(--sur-cobalt); }
.type-coach { border: 1px solid var(--trait); color: var(--gris); padding: 1px 6px; }
.ligne-replique { position: relative; padding-right: 40px; align-items: flex-start; }
.croix { position: absolute; top: 10px; right: 0; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--trait); background: var(--surface); color: var(--gris); font-size: 18px; line-height: 1; display: grid; place-items: center; cursor: pointer; }
.croix:hover, .croix:focus-visible { color: var(--encre); border-color: var(--encre); }
.confirmer-retrait { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; padding: 10px 12px; border-radius: 10px; background: var(--relief); font-size: 15px; }

/* Écran Entraînement */
.carte.lancer { gap: 14px; }
.carte.lancer > p { margin: 0; }
.compo { margin: 0; color: var(--gris); font-size: 15px; }
.compo b { color: var(--encre); font-variant-numeric: tabular-nums; }
.notes.trois { grid-template-columns: repeat(3, 1fr); }
.notes.trois .note-tuile { padding: 12px; }
.notes.trois .note-tuile b { font-size: 30px; }
.notes.trois .tag { letter-spacing: .06em; }
.note-tuile .petit.monte { color: var(--s3); font-weight: 600; }
.hero-note { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.hero-note b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 48px; line-height: 1; font-variant-numeric: tabular-nums; }
.hero-note b small { font-size: 18px; color: var(--gris); font-weight: 600; }
.hero-note span { color: var(--gris); font-size: 15px; }
.graph .zone { cursor: pointer; }
.graph-info { min-height: 1.35em; font-variant-numeric: tabular-nums; }
.series { display: flex; flex-direction: column; gap: 8px; }
.serie { background: var(--surface); border: 1px solid var(--trait); border-radius: 12px; }
.serie > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; cursor: pointer; }
.serie > summary::-webkit-details-marker { display: none; }
.serie > summary .corps { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.serie[open] > summary { border-bottom: 1px solid var(--trait); }
.serie > .liste { padding: 0 14px; }
.pastille { flex: none; min-width: 46px; text-align: center; font-family: var(--titre); font-weight: 900; font-stretch: 80%; font-size: 20px; font-variant-numeric: tabular-nums; padding: 4px 8px; border-radius: 10px; background: var(--cobalt-doux); color: var(--encre); }
.pastille.petite { min-width: 38px; font-size: 16px; padding: 2px 6px; }
@media (max-width: 360px) { .notes.trois .note-tuile b { font-size: 26px; } .notes.trois .tag { font-size: 11.5px; } }

/* Accueil */
/* La carte du jour ressort (fond inversé : noir en thème clair, blanc en sombre). */
.carte.du-jour { gap: 10px; background: var(--encre); color: var(--fond); border: 0; }
.carte.du-jour .surtitre, .carte.du-jour .petit, .carte.du-jour .discret { color: inherit; opacity: .72; }
.carte.du-jour .etiquette-temps { color: var(--munition); }
.carte.du-jour .progression { background: color-mix(in srgb, var(--fond) 22%, transparent); }
.carte.du-jour .progression i { background: var(--munition); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="clair"]) .carte.du-jour .etiquette-temps, :root:not([data-theme="clair"]) .carte.du-jour .progression i { color: var(--cobalt); background-color: transparent; }
  :root:not([data-theme="clair"]) .carte.du-jour .progression i { background: var(--cobalt); }
}
:root[data-theme="sombre"] .carte.du-jour .etiquette-temps { color: var(--cobalt); }
:root[data-theme="sombre"] .carte.du-jour .progression i { background: var(--cobalt); }
.carte.du-jour h1 { margin: 2px 0 0; font-size: 34px; }
.carte.du-jour .btn { margin-top: 6px; }
.carte.du-jour .surtitre, .carte.du-jour .etiquette-temps { font-size: 15px; }
.carte.du-jour .petit { font-size: 15px; }
.carte.du-jour .discret { font-size: 17px; line-height: 1.45; }
.progression { height: 6px; border-radius: 3px; background: var(--relief); overflow: hidden; }
.progression i { display: block; height: 100%; border-radius: 3px; background: var(--cobalt); min-width: 6px; }
.ent-home { gap: 10px; }
.ent-note { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.ent-note b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 40px; line-height: 1; font-variant-numeric: tabular-nums; }
.ent-note b small { font-size: 16px; color: var(--gris); font-weight: 600; }
.ent-note span { color: var(--gris); font-size: 15px; }
.ent-note em, .monte { font-style: normal; color: var(--s3); font-weight: 600; }
.mini-courbe { width: 92px; height: 26px; display: block; }
button.note-tuile { font: inherit; color: inherit; text-align: left; cursor: pointer; }
button.note-tuile .petit { color: var(--cobalt-texte); font-weight: 600; }
.note-tuile b.mot { font-size: 24px; line-height: 1.25; }

/* Arrivée */
.carte.histoire { padding: 22px 20px; }
.pourquoi li:first-child { color: var(--encre); font-size: 20px; font-weight: 600; line-height: 1.3; }
.pourquoi li:last-child { font-size: 18px; }
.promesse { gap: 14px; }
h1.objectif { font-size: clamp(32px, 9vw, 42px); }
.etapes-ligne { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.etapes-ligne li { background: var(--surface); border: 1px solid var(--trait); border-radius: 12px; padding: 12px 10px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; line-height: 1.3; font-weight: 600; }
.etapes-ligne .num { width: 26px; height: 26px; border-radius: 50%; background: var(--cobalt); color: var(--sur-cobalt); font-weight: 800; font-size: 15px; display: grid; place-items: center; }
.pourquoi li.vise { color: var(--cobalt-texte); }

/* Hacks */
.hack-lien { border: 0; text-align: left; font: inherit; cursor: pointer; width: 100%; }
.hack-lien .petit { color: inherit; opacity: .75; }
.puces-hacks { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.puces-hacks::-webkit-scrollbar { display: none; }
.puces-hacks .puce { flex: none; white-space: nowrap; }
.hacks-liste { display: flex; flex-direction: column; gap: 10px; }
.hack-carte { text-align: left; font: inherit; color: inherit; cursor: pointer; width: 100%; gap: 8px; }
.hack-carte .formule { font-weight: 700; color: var(--cobalt-texte); font-size: 17px; line-height: 1.3; }
.hack-carte .fl { color: var(--gris); font-size: 20px; }
.badge { display: inline-block; font-size: 12.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; border-radius: 3px; padding: 1px 6px; vertical-align: 1px; }
.badge.revoir { background: color-mix(in srgb, var(--s2) 18%, transparent); color: var(--encre); }
.badge.acquis { background: color-mix(in srgb, var(--s3) 18%, transparent); color: var(--encre); }
.badge.pref { background: var(--cobalt-doux); color: var(--cobalt-texte); }
.carte.a-venir { background: transparent; border-style: dashed; }
@media (max-width: 375px) { nav.onglets button { font-size: 12px; padding: 0 2px; } nav.onglets .in { padding: 0; } }

/* Offre et abonnement */
.inclus { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; line-height: 1.4; }
.periodes .option { display: flex; flex-direction: column; gap: 2px; text-align: left; }
.periodes .option strong { font-size: 18px; }
.case { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; line-height: 1.4; color: var(--gris); cursor: pointer; }
.case input { width: 20px; height: 20px; margin-top: 1px; flex: none; accent-color: var(--cobalt); }
a.ligne { color: inherit; text-decoration: none; }
.lune.payant:not(.faite) { border-style: dashed; }

/* Article « Pour aller plus loin » */
.carte-article { text-align: left; font: inherit; color: inherit; cursor: pointer; width: 100%; gap: 6px; border-color: var(--cobalt-texte); }
.carte-article .lien-fleche { color: var(--cobalt-texte); font-weight: 700; }
.carte-article.compacte { padding: 14px 16px; }
.carte-article.compacte .t2 { font-size: 20px; }
.badge.article { background: transparent; border: 1px solid var(--trait); color: var(--gris); }
.article { display: flex; flex-direction: column; gap: 16px; }
.article h1 { margin-top: 4px; }
.article .chapeau { font-size: 19px; line-height: 1.45; color: var(--gris); margin: 0; }
.article h2 { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 24px; line-height: 1.15; margin: 12px 0 0; }
.article > p { font-size: 17px; line-height: 1.62; margin: 0; }
.article .astuce { border-left: 3px solid var(--munition); padding: 4px 0 4px 14px; }
.article .astuce p { margin: 4px 0 0; font-size: 16px; line-height: 1.5; }
.article .dialogue { background: var(--surface); border: 1px solid var(--trait); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.article .dialogue .terrain { align-self: flex-start; }
.article .dialogue p { margin: 0; font-size: 16px; line-height: 1.45; }
.article .dialogue p.toi { color: var(--cobalt-texte); font-weight: 600; }
.article .exercice p { margin: 0; font-size: 16px; line-height: 1.5; }
.article .sources { border-top: 1px solid var(--trait); padding-top: 12px; display: flex; flex-direction: column; gap: 4px; }
.article .sources p { margin: 0; font-size: 14.5px; color: var(--gris); line-height: 1.45; }

/* Offrir l'app, et cadeau reçu */
.ico-cadeau { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 40px; height: 40px; border-radius: 12px; background: var(--munition); color: var(--sur-munition); }
.ico-cadeau.grand { width: 56px; height: 56px; border-radius: 16px; }
.ico-cadeau.grand svg { width: 30px; height: 30px; }
.ligne.ligne-cadeau { justify-content: flex-start; }
.apercu-mail { background: var(--relief); border-style: dashed; gap: 8px; }
.apercu-mail p { margin: 0; line-height: 1.5; }
.apercu-mail .t2 { font-size: 20px; }
.mot { background: var(--surface); border-left: 3px solid var(--munition); border-radius: 10px; padding: 10px 14px; display: flex; flex-direction: column; gap: 4px; }
.mot p { margin: 0; font-size: 16px; line-height: 1.5; white-space: pre-line; overflow-wrap: anywhere; }
.faux-bouton { align-self: flex-start; background: var(--cobalt); color: var(--sur-cobalt); font-weight: 700; font-size: 15px; border-radius: 999px; padding: 9px 14px; opacity: .85; }
.cadeau-envoye { gap: 6px; padding: 14px 16px; }
.cadeau-email { overflow-wrap: anywhere; min-width: 0; }
.cadeau-parti h2 { margin: 0; overflow-wrap: anywhere; }
.recu { display: flex; flex-direction: column; gap: 16px; padding-top: 24px; }
.recu h1 { margin: 0; }
.recu .mot { background: var(--surface); }
.recu .mot p { font-size: 18px; }
.recu .btn { margin-top: 8px; }
.cadeau-offre { border-color: var(--cobalt-texte); border-width: 1.5px; gap: 8px; }
.cadeau-offre .entre { align-items: baseline; }
.cadeau-offre strong { font-size: 22px; }
.cadeau-offre .petit { margin: 0; }
.integrale-passer { border-color: var(--cobalt-texte); border-width: 1.5px; }
.integrale-passer p { margin: 0; line-height: 1.5; }

/* Écran d'offre : les deux formules */
.offre-avance { display: flex; flex-direction: column; gap: 10px; }
.offre-avance p { margin: 0; font-size: 17px; line-height: 1.45; }
.formules { display: flex; flex-direction: column; gap: 14px; }
.formule { position: relative; display: flex; flex-direction: column; gap: 6px; text-align: left; font: inherit; color: inherit; cursor: pointer;
  background: var(--surface); border: 1.5px solid var(--trait); border-radius: 18px; padding: 18px; transition: border-color .15s, box-shadow .15s, transform .1s; }
.formule:active { transform: scale(.99); }
.formule.choisi { border: 2.5px solid var(--cobalt-texte); padding: 17px; box-shadow: 0 8px 24px -12px color-mix(in srgb, var(--accent) 55%, transparent); }
.formule.vedette { padding-top: 26px; margin-top: 10px; }
.formule.vedette.choisi { padding-top: 25px; background: linear-gradient(180deg, var(--cobalt-doux), var(--surface) 70%); }
.formule .ruban { position: absolute; top: -12px; left: 16px; background: var(--munition); color: var(--sur-munition); font-size: 13.5px; font-weight: 800;
  letter-spacing: .06em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; }
.formule-tete { display: flex; align-items: center; gap: 10px; }
.formule .nom { font-weight: 800; font-size: 18px; flex: 1; }
.formule .eco { background: var(--cobalt); color: var(--sur-cobalt); font-weight: 800; font-size: 14.5px; padding: 4px 9px; border-radius: 8px; }
.formule .radio { width: 22px; height: 22px; flex: none; border-radius: 50%; border: 2px solid var(--trait); background: var(--surface); }
.formule .radio.on { border-color: var(--cobalt); box-shadow: inset 0 0 0 4px var(--surface); background: var(--cobalt); }
.formule .prix { display: flex; align-items: baseline; gap: 8px; margin-top: 2px; }
.formule .prix b { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 46px; line-height: 1; letter-spacing: -.02em; }
.formule:not(.vedette) .prix b { font-size: 34px; }
.formule .prix small { font-size: 15px; color: var(--gris); font-weight: 600; }
.formule .compare { font-size: 15px; color: var(--gris); }
.formule .compare s { text-decoration-thickness: 2px; }
.formule .coches { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--trait); }
.coche-ligne { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; line-height: 1.4; }
.coche-ligne .v { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--cobalt); color: var(--sur-cobalt); font-size: 13.5px; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; }
.formule:not(.choisi) .coche-ligne .v { background: var(--relief); color: var(--encre); }
.formule .petit { line-height: 1.45; }
.offre-action { display: flex; flex-direction: column; gap: 12px; }
.btn-offre { min-height: 58px; font-size: 17px; }
.rassure { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 0; font-size: 14.5px; color: var(--gris); }
.bandeau-test { background: var(--munition); color: var(--sur-munition); border-radius: 12px; padding: 10px 14px; font-size: 15px; line-height: 1.4; }
.btn.danger { background: #B3261E; color: #fff; }
.zone-danger { border-color: color-mix(in srgb, #B3261E 45%, var(--trait)); }
.zone-danger .surtitre { color: #B3261E; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) .zone-danger .surtitre { color: #F2B8B5; } }
:root[data-theme="sombre"] .zone-danger .surtitre { color: #F2B8B5; }
#don-prenom { flex: 1; min-width: 0; }
.btn.lien.a-gauche { align-self: flex-start; justify-content: flex-start; text-align: left; padding-left: 0; }
.liste-factures { display: flex; flex-direction: column; }
.facture-ligne { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--trait); color: inherit; text-decoration: none; }
.facture-ligne:last-child { border-bottom: 0; }
.facture-ligne .corps { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.facture-ligne .petit { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.facture-ligne .montant { font-weight: 800; white-space: nowrap; }

/* Bouton du compte et son menu */
.app { position: relative; }
.app.avec-avatar > :nth-child(2) { padding-right: 50px; }
.avatar { position: absolute; top: 12px; right: 18px; z-index: 5; width: 38px; height: 38px; border-radius: 50%; border: 0;
  background: var(--cobalt); color: var(--sur-cobalt); font-weight: 800; font-size: 16px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
  box-shadow: 0 2px 8px -3px color-mix(in srgb, var(--encre) 40%, transparent); }
.avatar.vide { background: var(--surface); color: var(--encre); border: 1.5px solid var(--trait); }
.avatar.grand { position: static; width: 48px; height: 48px; font-size: 20px; flex: none; box-shadow: none; }
.menu-compte { position: fixed; inset: 0; z-index: 50; }
.menu-fond { position: absolute; inset: 0; background: rgba(10, 12, 20, .45); opacity: 0; transition: opacity .18s; }
.menu-panneau { position: absolute; top: 0; right: 0; width: min(360px, 100%); max-height: 100%; overflow-y: auto; background: var(--fond);
  border-bottom-left-radius: 20px; padding: 18px 18px calc(18px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 14px;
  transform: translateY(-12px); opacity: 0; transition: transform .18s ease, opacity .18s ease; box-shadow: 0 20px 50px -20px rgba(0,0,0,.5); }
@media (max-width: 480px) { .menu-panneau { width: 100%; border-radius: 0 0 20px 20px; } }
.menu-compte.ouvert .menu-fond { opacity: 1; }
.menu-compte.ouvert .menu-panneau { transform: none; opacity: 1; }
.menu-tete { display: flex; align-items: center; gap: 12px; }
.menu-tete .corps { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.menu-tete .corps strong, .menu-tete .corps .petit { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu-fermer { background: none; border: 0; font-size: 28px; line-height: 1; color: var(--gris); width: 40px; height: 40px; cursor: pointer; }
.menu-liste { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--trait); border-radius: 16px; padding: 2px 14px; }
.menu-item { display: flex; align-items: center; gap: 12px; padding: 13px 0; background: none; border: 0; border-bottom: 1px solid var(--trait); text-align: left; font: inherit; color: inherit; cursor: pointer; }
.menu-item:last-child { border-bottom: 0; }
.menu-item .corps { flex: 1; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.menu-item .fl { color: var(--gris); }
.menu-theme { cursor: default; flex-wrap: wrap; }
.segments { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: color-mix(in srgb, var(--encre) 8%, transparent); }
.segments button { border: 0; background: none; padding: 7px 12px; border-radius: 999px; font-size: 15px; font-weight: 600; color: var(--gris); min-height: 34px; }
.segments button[aria-checked="true"] { background: var(--encre); color: var(--fond); }
.menu-pied { display: flex; flex-direction: column; gap: 2px; }
a.btn.lien { color: var(--gris); }
@media (prefers-reduced-motion: reduce) { .menu-fond, .menu-panneau { transition: none; } }

/* Écran Offrir */
.cadeau-hero { display: flex; flex-direction: column; gap: 10px; padding: 22px 20px; border-radius: 20px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--munition) 38%, var(--surface)), var(--surface) 75%); border: 1px solid var(--trait); }
.cadeau-hero h1 { margin: 4px 0 0; font-size: 34px; line-height: 1.05; }
.cadeau-hero .hero-accroche { margin: 0; font-size: 18px; font-weight: 700; line-height: 1.35; }
.cadeau-hero .discret { margin: 0; }
.cadeau-formule { cursor: default; }
.cadeau-formule:active { transform: none; }
.cadeau-formule .ruban { background: var(--cobalt); color: var(--sur-cobalt); }
.trois-temps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.trois-temps > div { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border: 1px solid var(--trait); border-radius: 14px; padding: 12px 10px; }
.trois-temps b { width: 26px; height: 26px; border-radius: 50%; background: var(--munition); color: var(--sur-munition); display: inline-flex; align-items: center; justify-content: center; font-size: 15px; }
.trois-temps span { display: flex; flex-direction: column; gap: 2px; font-size: 14px; line-height: 1.3; color: var(--gris); }
.trois-temps strong { color: var(--encre); font-size: 15px; }
.cadeau-form { gap: 16px; }
.mots-idees { gap: 6px; }
.mots-idees .puce { text-align: left; font-size: 15px; line-height: 1.3; white-space: normal; padding: 8px 12px; }
.enveloppe { padding: 0; overflow: hidden; border-radius: 18px; border: 1px dashed var(--trait); background: var(--relief); gap: 0; }
.enveloppe-tete { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border-bottom: 1px dashed var(--trait); }
.enveloppe-corps { display: flex; flex-direction: column; gap: 8px; padding: 16px; background: var(--surface); margin: 10px; border-radius: 12px; }
.enveloppe-corps p { margin: 0; line-height: 1.5; }

/* Parcours */
.parcours-tete { gap: 12px; border-color: var(--cobalt-texte); border-width: 1.5px; }
.parcours-tete .t2 { font-size: 20px; }
.frise { display: flex; gap: 4px; height: 10px; }
.frise span { background: var(--relief); border-radius: 5px; overflow: hidden; }
.frise span i { display: block; height: 100%; background: var(--cobalt); border-radius: 5px; }
.frise span.ent i { background: var(--munition); }
.frise-noms { display: flex; gap: 4px; margin-top: -6px; }
.frise-noms span { font-size: 12.5px; color: var(--gris); text-transform: uppercase; letter-spacing: .05em; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notes.trois.mini .note-tuile { padding: 10px 12px; }
.notes.trois.mini .note-tuile b { font-size: 24px; }
.legende i.v { border-style: dashed; }
.etapes-parcours { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; position: relative; }
.etapes-parcours::before { content: ""; position: absolute; left: 14px; top: 20px; bottom: 20px; width: 2px; background: var(--trait); }
.etape-p { position: relative; display: flex; gap: 12px; align-items: flex-start; }
.etape-p .pastille-n { position: relative; z-index: 1; flex: none; width: 30px; height: 30px; margin-top: 14px; border-radius: 50%; background: var(--surface); border: 2px solid var(--trait);
  display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 15px; color: var(--gris); }
.etape-p .carte { flex: 1; min-width: 0; gap: 8px; }
.etape-p .carte .t2 { font-size: 22px; }
.etape-p .carte .petit { margin: 0; }
.etape-p.finie .pastille-n { background: var(--encre); border-color: var(--encre); color: var(--fond); }
.etape-p.encours .pastille-n { background: var(--cobalt); border-color: var(--cobalt); color: var(--sur-cobalt); }
.etape-p.encours .carte { border: 2px solid var(--cobalt-texte); }
.etape-p .btn.court { align-self: flex-start; }
.etape-p .lunes { gap: 5px; }
.liste-raccourcis { display: flex; flex-direction: column; }
.a-savoir { gap: 14px; }
.a-savoir p { margin: 4px 0 0; }
.etape-p .badge { white-space: nowrap; }
.etape-p .badge.verrou { background: transparent; border: 1px dashed var(--trait); color: var(--gris); }
.etape-p .jours-p { font-size: 14.5px; color: var(--gris); margin-top: -6px; font-weight: 600; }
.frise-noms span:last-child { text-align: right; }

/* Légal, résiliation, rétractation, IA */
.liens-legaux { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; padding-top: 6px; }
.liens-legaux a { color: var(--gris); text-decoration: underline; text-underline-offset: 2px; }
.case a { color: inherit; text-decoration: underline; }
.badge-ia { display: inline-block; margin-left: 4px; padding: 1px 6px; border-radius: 6px; background: var(--cobalt); color: var(--sur-cobalt); font-size: 11.5px; letter-spacing: .06em; vertical-align: 1px; }
.mention-ia { margin: 0; opacity: .8; }
.resiliation { border: 2px solid color-mix(in srgb, #B3261E 55%, var(--trait)); }
.recap { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; margin: 0; font-size: 14.5px; }
.recap dt { color: var(--gris); }
.recap dd { margin: 0; font-weight: 600; }
.retractation { display: flex; flex-direction: column; gap: 8px; padding-top: 10px; border-top: 1px dashed var(--trait); }
.retractation p { margin: 0; }
.mot[hidden], .apercu-mail [hidden] { display: none !important; }

/* Écrit ou voix, sous la pique */
.mode-choix { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--relief); border-radius: 14px; }
.mode-choix button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border: 0; border-radius: 10px; background: transparent; color: var(--gris); font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; }
.mode-choix button[aria-checked="true"] { background: var(--surface); color: var(--encre); box-shadow: 0 1px 4px -1px color-mix(in srgb, var(--encre) 30%, transparent); }
.mode-choix button[aria-checked="true"] svg { color: var(--cobalt-texte); }

/* Invitation à installer */
.carte-install { gap: 14px; background: linear-gradient(160deg, var(--cobalt-doux), var(--surface) 70%); }
.install-tete { display: flex; gap: 14px; align-items: center; }
.install-icone { width: 52px; height: 52px; border-radius: 13px; flex: none; box-shadow: 0 4px 12px -4px color-mix(in srgb, var(--encre) 35%, transparent); }
.carte-install .t2 { font-size: 18px; line-height: 1.25; }
.carte-install .rangee .btn.court { flex: none; }

/* Volet d'installation (reprise de Remember) : calé en bas de l'écran, il monte.
   Couleurs inversées pour ressortir : noir en thème clair, blanc en sombre. */
.pwa-banniere {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  width: 100%; max-width: 480px; margin: 0 auto; box-sizing: border-box;
  display: none; flex-direction: column; align-items: center; text-align: center; gap: 14px;
  background: var(--encre); color: var(--fond); border: 0; border-radius: 22px 22px 0 0;
  padding: 26px 20px calc(20px + env(safe-area-inset-bottom, 0px)); box-shadow: 0 -12px 40px rgba(0, 0, 0, .28);
  opacity: 0; transform: translateY(110%);
  transition: transform .42s cubic-bezier(.22, .61, .36, 1), opacity .32s ease;
}
.pwa-banniere.on { opacity: 1; transform: translateY(0); }
.pwa-x { position: absolute; top: 10px; right: 12px; background: none; border: 0; color: inherit; opacity: .6; font-size: 16px; padding: 6px; line-height: 1; cursor: pointer; }
.pwa-titre { font-family: var(--titre); font-weight: 800; font-size: 20px; line-height: 1.25; max-width: 320px; }
.pwa-txt { font-size: 15px; color: color-mix(in srgb, var(--fond) 78%, var(--encre)); line-height: 1.45; max-width: 340px; }
.pwa-txt b { color: var(--fond); }
.pwa-picto { display: inline-flex; align-items: center; vertical-align: -3px; margin: 0 1px; color: var(--fond); }
.pwa-fleche { color: var(--fond); animation: pwaRebond 1.4s ease-in-out infinite; }
@keyframes pwaRebond { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }
.pwa-banniere .btn { width: 100%; }
@media (prefers-reduced-motion: reduce) { .pwa-banniere { transition: none; } .pwa-fleche { animation: none; } }

/* Se connecter avec un compte existant */
.btn.lien.en-ligne { display: inline; min-height: 0; padding: 0; font-size: inherit; color: var(--encre); font-weight: 700; }
.btn.lien.lien-connexion { min-height: 36px; padding: 0 2px; color: var(--encre); font-weight: 700; font-size: 15px; }
.menu-acces { display: flex; flex-direction: column; gap: 10px; }
.menu-ou { font-size: 14.5px; color: var(--gris); text-align: center; margin-top: 4px; }

/* Page « installer l'app », entre la fin d'un jour et l'accueil */
.page-install { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 18px; margin-top: 4vh; }
.page-install h1 { margin: 0; }
.page-install .intro { margin: 0; max-width: 340px; }
.install-icone.grande { width: 84px; height: 84px; border-radius: 20px; }
.page-install .pile { width: 100%; }

/* Notifications, dans l'app installée */
.page-install .cloche { width: 84px; height: 84px; border-radius: 20px; display: flex; align-items: center; justify-content: center; background: var(--cobalt); color: var(--sur-cobalt); }
.ligne-heure { justify-content: center; gap: 8px; }
.ligne-heure input[type="time"] { color: var(--encre); }
.pwa-banniere .btn.lien { color: inherit; opacity: .75; min-height: 32px; }
.pwa-banniere .btn.fantome-clair { background: transparent; color: var(--fond); border: 1.5px solid currentColor; }
.cloche.petite { width: 52px; height: 52px; border-radius: 13px; flex: none; display: flex; align-items: center; justify-content: center; background: var(--cobalt); color: var(--sur-cobalt); }
.cloche.petite svg { width: 26px; height: 26px; }

/* Le dernier hack, dans la boîte à hacks : sobre, la carte du jour passe devant. */
.hack.hack-sobre { background: var(--surface); color: var(--encre); border: 1px solid var(--trait); }
.hack.hack-sobre .surtitre { color: var(--gris); opacity: 1; }
.hack.hack-sobre .petit { color: var(--cobalt-texte); opacity: 1; font-weight: 600; }

/* Séance : le jour, les étapes nommées, puis l'étape en grand */
:root { --faux: #C2412D; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) { --faux: #FF8A7A; } }
:root[data-theme="sombre"] { --faux: #FF8A7A; }
.ligne-seance { display: flex; align-items: center; gap: 12px; }
.jour-seance { flex: 1; min-width: 0; font-size: 14.5px; font-weight: 600; color: var(--gris); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.etapes-seance { display: grid; gap: 6px; list-style: none; margin: 0; padding: 0; }
.etapes-seance li { display: flex; flex-direction: column; gap: 6px; min-width: 0; font-size: 13.5px; font-weight: 600; color: var(--gris); }
.etapes-seance li::before { content: ""; height: 8px; border-radius: 4px; background: var(--relief); }
.etapes-seance li span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.etapes-seance li.fait { color: var(--encre); }
.etapes-seance li.fait::before { background: var(--encre); }
.etapes-seance li.fait span::before { content: "✓ "; }
.etapes-seance li.en-cours { color: var(--cobalt-texte); font-weight: 800; }
.etapes-seance li.en-cours::before { background: var(--cobalt); }
.titre-etape { display: flex; align-items: flex-start; gap: 12px; }
.num-etape { flex: none; width: 38px; height: 38px; border-radius: 50%; background: var(--cobalt); color: var(--sur-cobalt); display: flex; align-items: center; justify-content: center; font-family: var(--titre); font-weight: 800; font-size: 19px; margin-top: 1px; }
.titre-etape h1 { margin: 0; font-size: 31px; line-height: 1.08; }
.sous-etape { margin: 0; color: var(--gris); font-size: 15px; line-height: 1.4; }
.nom-hack { margin: 0; font-size: 25px; line-height: 1.15; color: var(--cobalt-texte); }
/* Étape mémoire : deux exercices numérotés */
.exercice { display: flex; gap: 12px; align-items: flex-start; background: var(--surface); border: 1px solid var(--trait); border-radius: 16px; padding: 16px 14px; }
.exercice > .pile { flex: 1; min-width: 0; }
.num-exo { flex: none; width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--cobalt-texte); color: var(--cobalt-texte); font-weight: 800; font-size: 15px; display: flex; align-items: center; justify-content: center; }
.exercice h2 { font-size: 21px; margin: 2px 0 0; }
.consigne { margin: 0; font-size: 15px; font-weight: 700; color: var(--encre); }
.option .marque-rep { font-weight: 800; margin-right: 8px; }
.option.bonne .marque-rep { color: var(--cobalt-texte); }
.option.ratee { opacity: 1; border-color: var(--faux); background: color-mix(in srgb, var(--faux) 8%, var(--surface)); }
.option.ratee .marque-rep { color: var(--faux); }
.option.eteinte { opacity: .5; }
.retour.juste, .retour.faux { color: var(--encre); font-weight: 500; }
.retour.juste strong { color: var(--cobalt-texte); }
.retour.faux strong { color: var(--faux); }

/* Le hack : son explication dans le bloc sombre */
.hack-truc .truc { margin: 0; color: inherit; font-size: 22px; line-height: 1.25; }

/* Séance : une carte par pique, numérotée */
.carte-pique { gap: 14px; padding: 16px 16px 18px; border-width: 1.5px; }
.num-pique { align-self: flex-start; font-size: 13.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--fond); background: var(--encre); border-radius: 999px; padding: 4px 10px; }
.carte-pique .repliques { padding-left: 0; }

/* Résumé de la séance */
.hack-resume strong { font-size: 24px; }
.resume-replique { display: flex; flex-direction: column; gap: 2px; font-weight: 600; font-size: 17px; line-height: 1.38; padding-top: 10px; border-top: 1px solid var(--trait); }
.resume-replique .tag { font-weight: 700; }
.etapes-seance { gap: 5px; }
.etapes-seance li { font-size: 12.5px; letter-spacing: -.01em; }
.etapes-seance li.fait span::before { content: "✓"; margin-right: 2px; }
/* Chaque étape prend la place de son nom : rien n'est coupé, même à cinq. */
.etapes-seance { display: flex; }
.etapes-seance li { flex: 1 1 auto; }
.etapes-seance li span { overflow: visible; text-overflow: clip; }

/* Boutons posés sur un fond inversé (carte du jour, volet du bas) : couleurs
   inversées aussi, pour rester bien lisibles (blanc sur noir en thème clair). */
.carte.du-jour .btn:not(.lien):not(.fantome), .pwa-banniere .btn:not(.lien):not(.fantome):not(.fantome-clair) { background: var(--fond); color: var(--encre); border-color: var(--fond); }
.carte.du-jour .btn.fantome { color: var(--fond); border-color: var(--fond); }
.carte.du-jour .btn.lien { color: var(--fond); opacity: .8; }
.btn[disabled] { cursor: default; opacity: .55; }
.carte.du-jour .btn[disabled]:not(.lien):not(.fantome) { background: transparent; color: var(--fond); border: 2px solid color-mix(in srgb, var(--fond) 45%, transparent); opacity: .8; }
.consigne-drill { margin: 0; font-size: 18px; line-height: 1.45; }

/* Réponse à voix haute : on touche le micro pour parler, il s'arrête seul */
.btn-micro { display: inline-flex; align-items: center; gap: 10px; border: 0; border-radius: 999px; background: var(--cobalt); color: var(--sur-cobalt); font: inherit; font-weight: 700; font-size: 16px; min-height: 52px; padding: 0 22px 0 18px; }
.btn-micro svg { width: 22px; height: 22px; }
.micro.ecoute { background: var(--surface); border: 1.5px solid var(--s2); border-radius: 999px; padding: 6px 6px 6px 16px; }
.micro.ecoute .btn { margin-left: auto; min-height: 40px; }
.toujours-la { gap: 10px; text-align: center; align-items: stretch; }
.toujours-la h2 { margin: 0; font-size: 26px; }

/* Accueil : le parcours, puis la boîte à hacks en liste. */
.parcours-home { gap: 10px; }
.parcours-home > .petit { margin: 0; }
.boite-hacks { gap: 10px; }
.liste-hacks { list-style: none; margin: 0; padding: 2px 16px; background: var(--surface); border: 1px solid var(--trait); border-radius: 16px; }
.ligne-hack { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--trait); }
.ligne-hack:last-child, .ligne-hack:has(+ .ligne-hack[hidden]) { border-bottom: 0; }
.ligne-hack[hidden] { display: none; }
.ligne-hack-nom { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; background: none; border: 0; padding: 0; text-align: left; cursor: pointer; color: inherit; }
.ligne-hack-nom strong { font-size: 17px; line-height: 1.3; }
.ligne-hack-nom .petit { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btn-approfondir { flex: none; border: 1.5px solid var(--cobalt-texte); color: var(--cobalt-texte); background: none; border-radius: 999px; padding: 7px 14px; font-size: 15px; font-weight: 700; min-height: 36px; }

/* L'heure du rappel, après le premier jour */
.liste-moments { gap: 10px; }
.choix-moment { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 56px; padding: 0 20px; border-radius: 999px; border: 2px solid var(--trait); background: var(--surface); color: var(--encre); font-size: 16px; text-align: left; }
.choix-moment strong { font-size: 18px; }
.choix-moment:first-child { border-color: var(--cobalt-texte); }
.choix-moment:active { transform: scale(.98); }
.liste-moments .ligne-heure { justify-content: center; }

/* ---------- Conversation : séance et entraînement en messagerie ---------- */
.cv { display: flex; flex-direction: column; gap: 0; min-height: calc(100vh - 48px); }
.cv-barre { border-bottom: 1px solid var(--trait); margin-inline: -18px; padding-inline: 18px; }
.cv-qui { display: flex; align-items: center; gap: 10px; min-height: 38px; }
.cv-qui:empty { display: none; }
.cv-qui-txt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.cv-qui-txt strong { font-size: 17px; line-height: 1.2; }
.cv-av { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--gris); color: #fff; font: 800 15px/1 var(--titre); }
.cv-av.petit { width: 34px; height: 34px; font-size: 14px; }
.cv-av.tete { overflow: hidden; }
.cv-av.tete svg { width: 100%; height: 100%; display: block; }
.cv-av.coach { background: var(--encre); color: var(--fond); }
.cv-av.figurant { background: var(--relief); color: var(--encre); }
.cv-fil { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 16px 0 28px; }
.cv-pastille { align-self: center; font-size: 13.5px; font-weight: 700; letter-spacing: .03em; color: var(--gris); background: var(--relief); border-radius: 999px; padding: 5px 12px; margin: 6px 0; text-align: center; }
.cv-recit { align-self: center; max-width: 88%; text-align: center; font-style: italic; color: var(--gris); font-size: 16px; margin: 2px 0 4px; }
.cv-msg { display: flex; align-items: flex-end; gap: 8px; max-width: 88%; }
.cv-msg.moi { align-self: flex-end; flex-direction: row-reverse; }
.cv-col { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; min-width: 0; }
.cv-bulle { padding: 10px 14px; border-radius: 20px 20px 20px 6px; background: var(--surface); border: 1px solid var(--trait); font-size: 17px; line-height: 1.4; min-width: 0; overflow-wrap: anywhere; }
.cv-msg.moi .cv-bulle { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); border-radius: 20px 20px 6px 20px; }
.cv-bulle.pique { font-weight: 700; font-size: 19px; line-height: 1.3; }
.cv-bulle.silence { font-style: italic; opacity: .8; }
.cv-auteur { display: block; font-size: 13.5px; font-weight: 700; color: var(--gris); margin-bottom: 2px; }
.cv-bulle.tape { display: inline-flex; gap: 4px; padding: 14px 16px; }
.cv-bulle.tape i { width: 7px; height: 7px; border-radius: 50%; background: var(--gris); opacity: .5; animation: cv-point 1s infinite; }
.cv-bulle.tape i:nth-child(2) { animation-delay: .15s; } .cv-bulle.tape i:nth-child(3) { animation-delay: .3s; }
.cv-garder { border: 0; background: none; color: var(--gris); font-size: 14.5px; font-weight: 600; padding: 2px 4px; }
.cv-garder[aria-pressed="true"] { color: var(--cobalt-texte); }
.cv-arrive { animation: cv-arrive .28s ease both; }
@keyframes cv-arrive { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes cv-point { 0%, 60%, 100% { transform: none; opacity: .4; } 30% { transform: translateY(-4px); opacity: .9; } }
.cv-carte { align-self: stretch; border-radius: 22px; padding: 18px; display: flex; flex-direction: column; gap: 10px; margin: 6px 0; }
.cv-carte.constat { background: var(--surface); border: 1px solid var(--trait); }
.cv-carte.hack { background: var(--encre); color: var(--fond); }
.cv-carte.hack .surtitre { color: var(--munition); opacity: 1; }
.cv-carte.hack .gros { font-family: var(--titre); font-weight: 900; font-stretch: 78%; font-size: 40px; line-height: 1; letter-spacing: -.01em; }
.cv-carte.hack p { opacity: .9; font-size: 16px; }
.cv-carte.fin { background: var(--surface); border: 2px solid var(--cobalt-texte); text-align: center; align-items: center; }
.cv-score { font-family: var(--titre); font-weight: 900; font-stretch: 78%; font-size: 40px; line-height: 1; }
.cv-collection { align-self: center; width: min(100%, 330px); aspect-ratio: 3 / 4.1; border-radius: 26px; padding: 22px; display: flex; flex-direction: column; gap: 14px; background: var(--cobalt); color: var(--sur-cobalt); position: relative; overflow: hidden; margin: 10px 0; box-shadow: 0 18px 40px -18px color-mix(in srgb, var(--accent) 70%, transparent); }
.cv-collection.cv-arrive { animation: cv-retourne .7s cubic-bezier(.2,.8,.2,1) both; }
.cv-collection::after { content: ""; position: absolute; inset: auto -40% -45% auto; width: 90%; aspect-ratio: 1; border-radius: 50%; background: rgba(255,255,255,.08); }
.cv-c-num { display: flex; justify-content: space-between; font-size: 14.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }
.cv-c-formule { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: clamp(44px, 14vw, 60px); line-height: .95; margin-top: auto; text-wrap: balance; }
.cv-c-regle { font-size: 18px; font-weight: 700; line-height: 1.3; }
.cv-c-quand { font-size: 15px; opacity: .85; }
.cv-c-styles { display: flex; gap: 6px; flex-wrap: wrap; }
.cv-c-styles span { font-size: 13.5px; font-weight: 700; border: 1px solid rgba(255,255,255,.45); border-radius: 999px; padding: 4px 10px; }
@keyframes cv-retourne { from { transform: perspective(800px) rotateY(80deg) scale(.9); opacity: 0; } to { transform: none; opacity: 1; } }
.cv-garde { align-self: center; font-size: 14.5px; font-weight: 700; color: var(--s3); border: 1px solid currentColor; border-radius: 999px; padding: 5px 12px; }
.cv-coach { align-self: stretch; border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; background: color-mix(in srgb, var(--accent-texte, var(--accent)) 15%, var(--fond)); border: 1px solid color-mix(in srgb, var(--accent-texte, var(--accent)) 35%, transparent); font-size: 16.5px; line-height: 1.45; margin: 4px 0 8px; }
.cv-coach.attente { flex-direction: row; align-items: center; gap: 10px; color: var(--gris); }
.cv-coach .coach-verdict { font-size: 17.5px; line-height: 1.4; }
.cv-coach .surtitre { color: var(--cobalt-texte); }
.cv-coach .mini { background: var(--fond); }
/* La zone du bas : boutons de choix ou saisie, collée en bas de l'écran */
.cv-bas { position: sticky; bottom: 0; z-index: 4; background: var(--fond); margin-inline: -18px; padding: 10px 18px calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--trait); display: flex; flex-direction: column; gap: 8px; }
.cv-bas:empty { display: none; }
.cv-choix { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; align-self: stretch; margin: 8px 0 4px; }
.cv-choix.large { flex-direction: column; align-items: flex-end; }
.cv-choix.cv-arrive > * { animation: cv-arrive .3s ease both; }
.cv-rep { font-family: var(--texte); border: 2px solid var(--cobalt-texte); background: var(--surface); color: var(--cobalt-texte); border-radius: 22px 22px 6px 22px; padding: 12px 18px; min-height: 50px; max-width: 88%; font-size: 17px; font-weight: 700; line-height: 1.3; text-align: left; box-shadow: 0 2px 10px -6px color-mix(in srgb, var(--accent) 60%, transparent); }
.cv-rep:active { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); }
.cv-rep.cv-style { display: inline-flex; flex-direction: column; align-items: center; text-align: center; padding: 10px 20px; border-radius: 22px; }
.cv-rep.cv-style small { font-size: 14px; font-weight: 500; opacity: .8; }
.cv-rep.cv-style.mien { background: color-mix(in srgb, var(--accent-texte, var(--accent)) 10%, var(--surface)); }
.cv-choix .btn { align-self: stretch; width: 100%; min-height: 54px; font-size: 17px; }
.cv-choix .btn.lien { align-self: center; width: auto; min-height: 40px; font-size: 15px; }
.cv-saisie { display: flex; gap: 8px; align-items: flex-end; }
.cv-saisie textarea { flex: 1; min-width: 0; min-height: 46px; max-height: 140px; border-radius: 23px; padding: 11px 16px; resize: none; font-size: 16px; line-height: 1.4; }
.cv-rond { width: 46px; height: 46px; border-radius: 50%; border: 0; display: grid; place-items: center; flex: none; background: var(--cobalt); color: var(--sur-cobalt); }
.cv-rond.micro { background: var(--relief); color: var(--encre); }
.cv-chrono { display: flex; align-items: center; gap: 10px; }
.cv-chrono .jauge { flex: 1; height: 4px; border-radius: 4px; background: var(--relief); overflow: hidden; display: block; }
.cv-chrono .jauge i { display: block; height: 100%; background: var(--cobalt); transform-origin: left; }
.cv-chrono .chrono { font-size: 14.5px; font-weight: 700; color: var(--gris); min-width: 22px; text-align: right; font-variant-numeric: tabular-nums; }
.cv-chrono .chrono.urgent { color: var(--faux, #C2410C); }
.cv-ecoute { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.cv-ecoute #micro-etat { flex: 1; }
.cv-absent { display: flex; flex-direction: column; gap: 6px; align-items: stretch; text-align: center; }
.cv-fil.rembobine { animation: cv-rembobine .7s ease both; }
@keyframes cv-rembobine { 40% { filter: blur(3px) saturate(0); transform: translateY(18px); opacity: .5; } 100% { opacity: 0; transform: translateY(40px); filter: blur(6px); } }
.cv-rembobine { position: fixed; inset: 50% 0 auto; transform: translateY(-50%); text-align: center; font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 46px; color: var(--cobalt-texte); pointer-events: none; animation: cv-flash .8s ease both; z-index: 30; }
@keyframes cv-flash { 0% { opacity: 0; transform: translateY(-50%) scale(.8); } 30% { opacity: 1; transform: translateY(-50%) scale(1); } 100% { opacity: 0; transform: translateY(-50%) scale(1.15); } }
/* L'onglet Entraînement : choisir son adversaire */
.adversaires { display: flex; flex-direction: column; gap: 8px; }
.adversaire { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; border: 1.5px solid var(--trait); background: var(--surface); text-align: left; color: inherit; font: inherit; }
.adversaire .corps { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.adversaire.dernier { border-color: var(--cobalt-texte); }
.adversaire .score-adv { text-align: right; }
@media (prefers-reduced-motion: reduce) { .cv-arrive, .cv-collection.cv-arrive, .cv-bulle.tape i { animation: none; } }

/* Ta vraie vie : piques reçues, hacks placés */
.carte-vie { gap: 10px; }
.vie-boutons { flex-wrap: nowrap; }
.vie-boutons .btn { flex: 1; min-width: 0; padding: 0 12px; }
.ligne-hack-nom .utilise { font-size: 14px; font-weight: 700; color: var(--s3); }
.cv-rep.cv-replique { display: flex; flex-direction: column; gap: 2px; }
.cv-rep.cv-replique small { font-size: 13.5px; font-weight: 600; opacity: .75; }
#vie-etat:empty { display: none; }

/* Accueil : les tuiles sous la séance du jour. */
.tuiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tuile { position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 10px; min-height: 108px; padding: 16px 34px 16px 16px; border-radius: 16px; border: 1px solid var(--trait); background: var(--surface); color: var(--encre); text-align: left; transition: transform .12s ease; }
.tuile:active { transform: scale(.98); }
.tuile::after { content: "›"; position: absolute; top: 12px; right: 14px; font-size: 24px; line-height: 1; color: var(--gris); }
.tuile.large { grid-column: 1 / -1; min-height: 96px; }
.tuile.forte { border: 2px solid var(--cobalt-texte); }
.tuile-titre { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 21px; line-height: 1.1; text-wrap: balance; }
.tuile-info { font-size: 15px; color: var(--gris); line-height: 1.35; }
.tuile-info b { font-family: var(--titre); font-size: 20px; font-weight: 900; color: var(--encre); font-variant-numeric: tabular-nums; }
.tuile .progression { display: block; width: 100%; }
.tuile .progression i { display: block; }
.tuile .mini-courbe { position: absolute; right: 16px; bottom: 16px; }
.tuiles > .tuile:nth-child(2):last-child { grid-column: 1 / -1; min-height: 96px; }
.adversaire .cv-av { width: 58px; height: 58px; }
.cv-fil.ecran-neuf { animation: cv-ecran .32s ease both; }
@keyframes cv-ecran { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .cv-fil.ecran-neuf { animation: none; } }

/* Le coach dans l'entraînement : la piste, la réplique en mieux, les trois façons. */
.cv-coach .coach-piste { font-size: 16px; color: var(--gris); }
.cv-coach .coach-piste strong { color: var(--encre); }
.cv-mieux, .cv-facon { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 12px 14px; border-radius: 14px; background: var(--fond); }
.cv-mieux { border: 1.5px solid var(--cobalt-texte); }
.cv-mieux p, .cv-facon p { font-weight: 700; font-size: 17px; line-height: 1.35; }
.cv-mieux .tag { color: var(--cobalt-texte); }
.cv-facons { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.titre-facons { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 19px; }

/* Conversation aérée (23 nov.) */
.cv-barre.seule { gap: 0; padding-block: 12px 14px; }
.cv-barre.seule .ligne-seance { gap: 12px; }
.cv-barre.seule .cv-qui { flex: 1; min-width: 0; min-height: 44px; gap: 12px; }
.cv-fil { gap: 14px; padding: 24px 0 44px; }
.cv-msg { gap: 10px; max-width: 86%; }
.cv-bulle { padding: 12px 16px; border-radius: 22px 22px 22px 8px; line-height: 1.45; }
.cv-msg.moi .cv-bulle { border-radius: 22px 22px 8px 22px; }
.cv-bulle.pique { font-size: 20px; line-height: 1.3; padding: 14px 18px; }
.cv-pastille { margin: 2px 0 6px; padding: 6px 14px; }
.cv-recit { margin: 4px 0 8px; line-height: 1.5; }
.cv-coach { padding: 18px; gap: 12px; margin: 12px 0 14px; border-radius: 22px; }
.cv-carte { margin: 12px 0; }
.cv-choix { gap: 10px; margin: 16px 0 6px; }
.cv-bas { padding-top: 12px; gap: 10px; }
.cv-arrive { animation: cv-arrive .38s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes cv-arrive { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .cv-arrive { animation: none; } }
.cv-raison { align-self: center; font-size: 13.5px; color: var(--gris); margin: -4px 0 4px; text-align: center; }
.vie-boutons { flex-direction: column; align-items: stretch; } .vie-boutons .btn { width: 100%; flex: none; }

/* Accueil : l'icône de chaque tuile, en grand et en filigrane, derrière le texte. */
.tuile { overflow: hidden; isolation: isolate; }
.tuile-fond { position: absolute; right: -10px; bottom: -12px; width: 92px; height: 92px; color: var(--encre); opacity: .09; pointer-events: none; z-index: -1; }
.tuile-fond svg { width: 100%; height: 100%; display: block; }
.tuile.large .tuile-fond { right: -12px; bottom: -18px; width: 104px; height: 104px; }
.tuile.large .mini-courbe { top: 20px; bottom: auto; right: 42px; }

/* Le mot du coach (24 nov.) : l'anneau de la note, le mot d'encouragement,
   puis les blocs qui entrent l'un après l'autre. */
.coach-tete { display: flex; align-items: center; gap: 14px; }
.coach-anneau { position: relative; width: 70px; height: 70px; flex: none; }
.coach-anneau svg { width: 100%; height: 100%; transform: rotate(-90deg); display: block; }
.coach-anneau .fond { fill: none; stroke: color-mix(in srgb, var(--encre) 10%, transparent); stroke-width: 6; }
.coach-anneau .plein { fill: none; stroke: var(--cobalt-texte); stroke-width: 6; stroke-linecap: round; transition: stroke-dashoffset .9s cubic-bezier(.2, .8, .2, 1); }
.coach-chiffre { position: absolute; inset: 0; display: flex; align-items: baseline; justify-content: center; padding-top: 19px; gap: 1px; }
.coach-chiffre b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 28px; line-height: 1; font-variant-numeric: tabular-nums; }
.coach-chiffre small { font-size: 12px; color: var(--gris); font-weight: 600; }
.coach-titre { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.coach-mot { font-family: var(--titre); font-weight: 800; font-stretch: 85%; font-size: 20px; line-height: 1.15; text-wrap: balance; }
.cv-coach .coach-verdict { font-size: 17px; line-height: 1.45; }
.coach-label { font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; color: var(--gris); }
.cv-mieux { gap: 8px; padding: 14px 16px; border-radius: 16px; background: var(--fond); border: 1.5px solid var(--cobalt-texte); }
.cv-mieux .coach-label { color: var(--cobalt-texte); }
.cv-mieux p, .cv-facon p { font-weight: 700; font-size: 18px; line-height: 1.35; }
.cv-coach .coach-piste { display: flex; flex-direction: column; gap: 4px; padding: 2px 0 2px 14px; border-left: 3px solid var(--cobalt-texte); color: var(--encre); }
.cv-coach .coach-piste p { font-size: 16px; line-height: 1.45; }
.cv-facons { gap: 10px; margin-top: 2px; }
.facons-onglets { display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: color-mix(in srgb, var(--encre) 8%, transparent); }
.facon-onglet { flex: 1; min-height: 40px; border: 0; border-radius: 999px; background: none; color: var(--gris); font-weight: 700; font-size: 15px; transition: background .2s, color .2s; }
.facon-onglet[aria-selected="true"] { background: var(--fond); color: var(--encre); box-shadow: 0 1px 6px -2px rgba(0, 0, 0, .25); }
.facon-onglet i { font-style: normal; color: var(--cobalt-texte); margin-left: 5px; }
.cv-facon { gap: 10px; padding: 14px 16px; border-radius: 16px; background: var(--fond); }
.cv-facon[hidden] { display: none; }
.cv-facon:not([hidden]) { animation: coach-facon .25s ease both; }
.cv-coach.anime > * { animation: coach-entre .5s cubic-bezier(.2, .8, .2, 1) both; }
.cv-coach.anime > :nth-child(2) { animation-delay: .12s; }
.cv-coach.anime > :nth-child(3) { animation-delay: .24s; }
.cv-coach.anime > :nth-child(4) { animation-delay: .36s; }
.cv-coach.anime > :nth-child(5) { animation-delay: .48s; }
.cv-coach.anime > :nth-child(n+6) { animation-delay: .6s; }
@keyframes coach-entre { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes coach-facon { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
/* En attente : un anneau vide qui tourne et deux lignes qui scintillent. */
.cv-coach.attente { flex-direction: row; align-items: center; gap: 14px; color: var(--encre); }
.coach-anneau.vide { border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--encre) 6%, transparent); }
.coach-attente { flex: 1; display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.coach-attente .points i { font-style: normal; animation: coach-point 1.2s infinite; }
.coach-attente .points i:nth-child(2) { animation-delay: .2s; } .coach-attente .points i:nth-child(3) { animation-delay: .4s; }
.ligne-vide { height: 10px; border-radius: 5px; background: linear-gradient(90deg, color-mix(in srgb, var(--encre) 7%, transparent), color-mix(in srgb, var(--encre) 16%, transparent), color-mix(in srgb, var(--encre) 7%, transparent)); background-size: 200% 100%; animation: coach-scintille 1.3s linear infinite; }
.ligne-vide.courte { width: 60%; }
@keyframes coach-scintille { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@keyframes coach-point { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .cv-coach.anime > *, .cv-facon:not([hidden]), .ligne-vide, .coach-attente .points i { animation: none; } .coach-anneau .plein { transition: none; } }
.cv-coach .coach-verdict { font-family: var(--texte); font-weight: 500; font-stretch: 100%; }

/* Carnet : chaque pique en mini-échange (24 nov.). */
.carnet { gap: 4px; }
.carnet-filtres { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.carnet-echange { display: flex; flex-direction: column; gap: 8px; padding: 16px 0 18px; border-bottom: 1px solid var(--trait); }
.carnet-echange:last-child { border-bottom: 0; }
.carnet-meta { font-size: 13.5px; color: var(--gris); }
.carnet-echange .cv-bulle { font-size: 16.5px; }
.carnet-rep { max-width: 94%; align-items: center; }
.carnet-rep .cv-col { align-items: flex-end; gap: 4px; }
.carnet-rep .croix { position: static; flex: none; width: 30px; height: 30px; font-size: 16px; }
.carnet-type { font-size: 13px; color: var(--gris); }
.carnet-origine { font-size: 13px; color: var(--gris); text-align: right; max-width: 100%; }
.carnet-rep .confirmer-retrait { align-items: flex-end; text-align: right; }
@media (max-width: 340px) { .tuile.large .mini-courbe { width: 64px; } }

/* Accueil : deux tuiles aux couleurs de la marque, violet et jaune, pour
   le contraste et le rappel du logo. Les autres restent neutres. */
.tuile.violette { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); --s1: currentColor; }
.tuile.jaune { background: var(--munition); color: var(--sur-munition); border-color: var(--munition); }
.tuile.violette .tuile-info, .tuile.jaune .tuile-info { color: inherit; opacity: .82; }
.tuile.violette .tuile-info b, .tuile.jaune .tuile-info b { color: inherit; }
.tuile.violette::after, .tuile.jaune::after { color: inherit; opacity: .7; }
.tuile.violette .tuile-fond { color: var(--sur-cobalt); opacity: .16; }
.tuile.jaune .tuile-fond { color: var(--sur-munition); opacity: .13; }
/* Ma boîte à hacks en gris, troisième couleur de l'accueil. */
:root { --tuile-grise: #5B6074; --sur-tuile-grise: #FFFFFF; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) { --tuile-grise: #3B3F55; --sur-tuile-grise: #ECEDF5; } }
:root[data-theme="sombre"] { --tuile-grise: #3B3F55; --sur-tuile-grise: #ECEDF5; }
.tuile.grise { background: var(--tuile-grise); color: var(--sur-tuile-grise); border-color: var(--tuile-grise); }
.tuile.grise .tuile-info { color: inherit; opacity: .82; }
.tuile.grise::after { color: inherit; opacity: .7; }
.tuile.grise .tuile-fond { color: var(--sur-tuile-grise); opacity: .14; }
/* La dernière note, en grand dans la tuile Entraînement. */
.tuile-score { position: absolute; top: 12px; right: 40px; display: flex; align-items: baseline; gap: 2px; }
.tuile-score b { font-family: var(--titre); font-weight: 900; font-stretch: 75%; font-size: 34px; line-height: 1; font-variant-numeric: tabular-nums; }
.tuile-score small { font-size: 14px; font-weight: 600; opacity: .8; }
.tuile.large .tuile-info { padding-right: 70px; }
.cv-msg.moi .cv-bulle.silence { background: transparent; color: var(--gris); border: 1.5px dashed var(--trait); font-style: italic; opacity: 1; }
/* Le constat après le rejeu : en jaune, pour qu'il ressorte. */
.cv-recit.victoire { font-style: normal; font-weight: 700; color: var(--sur-munition); background: var(--munition); border-radius: 14px; padding: 10px 16px; max-width: 92%; margin: 6px 0 10px; }
/* La carte du hack est inversée : en sombre elle est claire, le jaune n'y
   se lit pas. On passe le surtitre en violet. */
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) .cv-carte.hack .surtitre { color: var(--cobalt); } }
:root[data-theme="sombre"] .cv-carte.hack .surtitre { color: var(--cobalt); }
/* Le constat après un piège : en gras, jaune sur fond sombre, violet sur fond clair. */
.cv-recit.constat { font-style: normal; font-weight: 700; color: var(--cobalt-texte); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) .cv-recit.constat { color: var(--munition); } }
:root[data-theme="sombre"] .cv-recit.constat { color: var(--munition); }
/* Le lieu, l'heure et la mise en scène : plus contrastés (24 nov.). */
.cv-pastille { color: var(--encre); background: color-mix(in srgb, var(--encre) 12%, transparent); font-size: 14px; padding: 7px 14px; }
.cv-recit { color: color-mix(in srgb, var(--encre) 86%, var(--fond)); font-size: 16.5px; font-weight: 500; }
.cv-recit.question { font-style: normal; font-weight: 700; color: var(--encre); font-size: 17.5px; margin: 6px 0 2px; }
/* Bulles des personnages plus tranchées, mise en scène en clair (24 nov.). */
.cv-msg:not(.moi) .cv-bulle { background: #FFFFFF; border-color: #C9CEDC; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) .cv-msg:not(.moi) .cv-bulle { background: #2A2E45; border-color: #3A3F5A; } }
:root[data-theme="sombre"] .cv-msg:not(.moi) .cv-bulle { background: #2A2E45; border-color: #3A3F5A; }
.cv-recit { font-style: normal; color: var(--encre); }
/* La carte du jour : le bouton principal en violet, la couleur d'action de l'app. */
.carte.du-jour .btn:not(.lien):not(.fantome):not([disabled]) { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); }
/* La pique : même texte que les autres bulles. */
.cv-bulle.pique { font-family: var(--texte); font-stretch: 100%; font-weight: 400; font-size: 17px; line-height: 1.45; padding: 12px 16px; letter-spacing: 0; }
/* Entraînement en vert (le violet reste au bouton « C'est parti »). */
:root { --tuile-verte: #12795F; --sur-tuile-verte: #FFFFFF; }
.tuile.verte { background: var(--tuile-verte); color: var(--sur-tuile-verte); border-color: var(--tuile-verte); }
.tuile.verte .tuile-info { color: inherit; opacity: .85; }
.tuile.verte::after { color: inherit; opacity: .7; }
.tuile.verte .tuile-fond { color: var(--sur-tuile-verte); opacity: .16; }
.cv-carte.constat .surtitre { color: var(--cobalt-texte); }
/* Le mot d'Alex, plus aéré : trois temps (la note et le verdict, ta
   réplique en mieux et le hack, les trois façons), bien séparés. */
.cv-coach:not(.attente) { padding: 22px 20px 18px; gap: 24px; }
.cv-coach .coach-tete { gap: 16px; }
.cv-coach .coach-mot { font-size: 22px; }
.cv-coach:not(.attente) .coach-verdict { margin-top: -10px; color: color-mix(in srgb, var(--encre) 88%, transparent); }
.cv-coach .coach-label { display: block; margin-bottom: 2px; }
.cv-mieux { padding: 16px 18px; gap: 10px; }
.cv-mieux p, .cv-facon p { font-size: 18.5px; line-height: 1.4; }
.cv-coach .coach-piste { gap: 8px; padding: 4px 0 4px 16px; }
.cv-facons { gap: 12px; }
.cv-facon { padding: 16px 18px; gap: 12px; }
.cv-coach .mention-ia { padding-top: 14px; border-top: 1px solid color-mix(in srgb, var(--encre) 12%, transparent); margin-top: -4px; }
/* « Ta réplique, en mieux » en jaune : c'est la réplique à retenir. */
.cv-mieux { background: var(--munition); color: var(--sur-munition); border-color: var(--munition); }
.cv-mieux .coach-label { color: var(--sur-munition); opacity: .75; }
.cv-mieux .mini { background: rgba(255, 255, 255, .55); color: var(--sur-munition); border-color: rgba(0, 0, 0, .18); }
.cv-mieux .mini[aria-pressed="true"] { background: var(--sur-munition); color: var(--munition); border-color: var(--sur-munition); }
/* La barre du haut quand Alex parle : teintée de violet, son nom en violet. */
.cv-barre.avec-coach { background: color-mix(in srgb, var(--cobalt) 16%, var(--fond)); border-bottom-color: color-mix(in srgb, var(--cobalt-texte) 40%, transparent); transition: background .3s; }
.cv-barre.avec-coach .cv-qui-txt strong { color: var(--cobalt-texte); }
/* Sans « en mieux », la réplique modèle des trois façons passe en jaune. */
.cv-facons.jaune .cv-facon { background: var(--munition); color: var(--sur-munition); }
.cv-facons.jaune .cv-facon .mini { background: rgba(255, 255, 255, .55); color: var(--sur-munition); border-color: rgba(0, 0, 0, .18); }
.cv-facons.jaune .cv-facon .mini[aria-pressed="true"] { background: var(--sur-munition); color: var(--munition); border-color: var(--sur-munition); }
/* Encore plus d'air dans le mot d'Alex. */
.cv-coach:not(.attente) { padding: 24px 22px 20px; gap: 30px; }
.cv-coach:not(.attente) .coach-verdict { margin-top: -14px; line-height: 1.55; }
.cv-coach .coach-piste { gap: 10px; padding: 6px 0 6px 18px; }
.cv-coach .coach-piste p { line-height: 1.55; }
.cv-facons { gap: 14px; }
.facons-onglets { margin-bottom: 2px; }
.cv-mieux, .cv-facon { padding: 18px 20px; gap: 14px; }
.cv-coach .mention-ia { margin-top: -10px; padding-top: 16px; }
/* iPhone : 100vh compte les barres de Safari ; 100svh, la hauteur visible. */
.cv { min-height: calc(100svh - 48px); }
/* La carte à collectionner prend la hauteur de son contenu : plus de vide entre l'en-tête et le titre. */
.cv-collection { aspect-ratio: auto; gap: 12px; }
.cv-collection .cv-c-formule { margin-top: 14px; }
/* Le hack dont parle Alex : son nom en violet, et un lien vers sa fiche. */
.cv-coach .coach-piste .coach-label { color: var(--cobalt-texte); }
.cv-coach .coach-plus { align-self: flex-start; padding: 0; min-height: 32px; color: var(--cobalt-texte); font-weight: 700; font-size: 15px; }
/* La fiche d'un hack, par-dessus la conversation. */
.feuille { position: fixed; inset: 0; z-index: 60; background: var(--fond); overflow-y: auto; -webkit-overflow-scrolling: touch; animation: feuille-monte .28s cubic-bezier(.2, .8, .2, 1) both; }
.feuille-dedans { max-width: 480px; margin: 0 auto; padding: 0 18px calc(40px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 22px; }
.feuille .barre-seance { position: sticky; top: 0; }
html.feuille-ouverte, html.feuille-ouverte body { overflow: hidden; }
@keyframes feuille-monte { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .feuille { animation: none; } }
.feuille-piques { gap: 6px; } .feuille-pique { display: flex; flex-direction: column; gap: 8px; padding: 14px 0 16px; border-bottom: 1px solid var(--trait); } .feuille-pique:last-child { border-bottom: 0; }
/* « Le hack : » couleur du texte, seul le nom du hack en violet. */
.cv-coach .coach-piste .coach-label { color: var(--gris); }
.cv-coach .coach-piste .piste-nom { color: var(--cobalt-texte); }
.cv-coach .coach-piste .coach-label { text-transform: none; letter-spacing: 0; font-size: 15px; }
/* « Retenue » dans le mot d'Alex : bouton violet plein (avant, texte et fond se confondaient). */
.cv-coach .cv-facons:not(.jaune) .mini[aria-pressed="true"] { background: var(--cobalt); color: var(--sur-cobalt); border-color: var(--cobalt); }
