/* Victoria — la plateforme OS : jetons et composants (DAT v4.0 §13, prototype [Ref.38]).
   Habillage logiciel neutre, marque en accent (ENF-09) : police système, contrôles
   standards, fond gris chaud ; le crème et l'or servent la sélection, l'étape en cours
   et les accents. Un même indice a toujours le même sens (SPÉC-80, UX-R12) :
   or = en cours / sélection · vert = fait · rouge = casse ou faute · gris pointillé = verrouillé. */

:root {
  --fond: #f5f4f0; --surface: #ffffff; --surface2: #faf9f6; --trait: #e2dfd8; --trait2: #cfcac0;
  --encre: #1c1b18; --texte: #2b2a26; --sourdine: #6b675e; --muet: #8a857a;
  --or: #b3922a; --or-clair: #fbf4dc; --or-bord: #e4cf8a; --or-texte: #6d5710;
  --vert: #256a42; --vert-clair: #e6f3ea; --rouge: #a03b2e; --rouge-clair: #fbe9e5;
  --bleu: #2f5fa8; --bleu-clair: #e8effa;
  --r: 8px; --r-carte: 12px;
  --ombre: 0 1px 2px rgba(28, 27, 24, .08), 0 1px 1px rgba(28, 27, 24, .04);
  --focus: 0 0 0 2px var(--surface), 0 0 0 4px var(--or);
}
*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: light; }
body {
  margin: 0; background: var(--fond); color: var(--texte);
  font: 14px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { margin: 0; font-weight: 600; color: var(--encre); }
h1 { font-size: 22px; } h2 { font-size: 16px; } h3 { font-size: 14px; }
p { margin: 0; }
a { color: var(--bleu); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: #1e4787; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: none; box-shadow: var(--focus); }
svg:not([width]) { width: 18px; height: 18px; flex: none; }
.visuellement-cache { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- gabarit */
.app { display: flex; width: 100%; min-height: 100vh; }
.principal { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.entete { display: flex; align-items: center; gap: 16px; padding: 14px 32px; background: var(--surface); border-bottom: 1px solid var(--trait); position: sticky; top: 0; z-index: 2; }
.entete .actions { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.contenu { padding: 24px 32px 48px; display: flex; flex-direction: column; gap: 20px; max-width: 1240px; }
.fil { display: flex; align-items: center; gap: 6px; color: var(--sourdine); font-size: 13px; flex-wrap: wrap; }
.fil ol { display: contents; list-style: none; margin: 0; padding: 0; }
.fil li { display: flex; align-items: center; gap: 6px; }
.fil a { color: var(--sourdine); }
.fil .sep { color: var(--muet); }
.fil b { color: var(--encre); font-weight: 600; }

/* ---------- navigation latérale */
.nav { width: 248px; flex: none; background: var(--surface); border-right: 1px solid var(--trait); display: flex; flex-direction: column; padding: 16px 12px; gap: 6px; }
.marque { display: flex; align-items: center; gap: 10px; padding: 6px 8px 14px; border-bottom: 1px solid var(--trait); margin-bottom: 8px; }
.marque .logo { width: 28px; height: 28px; border-radius: 7px; background: var(--encre); color: #fff; display: grid; place-items: center; font-family: Georgia, serif; font-size: 16px; }
.marque b { font-weight: 600; color: var(--encre); }
.marque small { display: block; color: var(--sourdine); font-size: 12px; }
.nav-titre { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--sourdine); padding: 10px 8px 4px; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.nav a.item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r); color: var(--texte); text-decoration: none; font-weight: 500; }
.nav a.item:hover { background: var(--surface2); }
.nav a.item.actif { background: var(--or-clair); color: var(--encre); box-shadow: inset 3px 0 0 var(--or); }
.nav a.item svg { width: 18px; height: 18px; flex: none; color: var(--sourdine); }
.nav a.item.actif svg { color: var(--or); }
.nav .sujet { padding-left: 14px; }
.nav .sujet .etat { margin-left: auto; }
.nav .sujet .nom { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav .bas { margin-top: auto; border-top: 1px solid var(--trait); padding-top: 8px; }
.nav .compte { display: flex; align-items: center; gap: 10px; padding: 8px 10px; }
.nav .compte .rond { width: 30px; height: 30px; border-radius: 15px; background: var(--or-clair); border: 1px solid var(--or-bord); display: grid; place-items: center; font-weight: 600; color: var(--or-texte); }

/* ---------- boutons (SPÉC-81) */
.btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: var(--r); border: 1px solid var(--trait2); background: var(--surface); color: var(--encre); font-weight: 500; box-shadow: var(--ombre); white-space: nowrap; text-decoration: none; transition: background .12s, transform .06s, box-shadow .12s; }
.btn:hover { background: var(--surface2); border-color: #b8b2a6; }
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn svg { width: 16px; height: 16px; }
.btn.primaire { background: var(--encre); border-color: var(--encre); color: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); }
.btn.primaire:hover { background: #000; }
.btn.grand { height: 44px; padding: 0 20px; font-size: 15px; }
.btn.danger { color: var(--rouge); border-color: #e6c3bc; }
.btn.danger:hover { background: var(--rouge-clair); }
.btn:disabled, .btn.inactif { opacity: .5; cursor: not-allowed; box-shadow: none; transform: none; }
.btn.lien { border: none; background: none; box-shadow: none; color: var(--bleu); text-decoration: underline; padding: 0 4px; height: auto; }
.raison { font-size: 12.5px; color: var(--sourdine); display: inline-flex; align-items: center; gap: 6px; }
.raison svg { width: 14px; height: 14px; color: var(--sourdine); }
.avec-raison { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ---------- cartes */
.carte { background: var(--surface); border: 1px solid var(--trait); border-radius: var(--r-carte); padding: 18px 20px; box-shadow: var(--ombre); }
.carte.accent { border-color: var(--or-bord); background: var(--or-clair); }
.carte.accent p { color: var(--or-texte); }
.carte > svg:not([width]) { width: 28px; height: 28px; color: var(--or); }
.carte.cliquable { cursor: pointer; transition: border-color .12s, box-shadow .12s, transform .06s; }
.carte.cliquable:hover { border-color: var(--or-bord); box-shadow: 0 4px 12px rgba(28, 27, 24, .08); }
.grille { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.deux { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
.entete-carte { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.entete-carte h2 { flex: 1; }
.pile { display: flex; flex-direction: column; gap: 14px; }
.chiffre { font-size: 24px; font-weight: 600; color: var(--encre); line-height: 1.1; }
.legende { font-size: 12.5px; color: var(--sourdine); }
.liste { display: flex; flex-direction: column; gap: 8px; list-style: none; margin: 0; padding: 0; }
.ligne-liste { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--trait); border-radius: 10px; background: var(--surface); }
.ligne-liste .txt { flex: 1; min-width: 0; }
.ligne-liste .txt b { display: block; font-weight: 600; color: var(--encre); }
.ligne-liste .txt small { color: var(--sourdine); }
.kbd { font: 12px ui-monospace, Menlo, monospace; background: var(--surface2); border: 1px solid var(--trait2); border-bottom-width: 2px; border-radius: 4px; padding: 0 5px; }

/* ---------- statuts (SPÉC-84) : icône + texte, jamais une couleur seule */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 12px; font-size: 12px; font-weight: 500; border: 1px solid transparent; white-space: nowrap; }
.badge svg { width: 12px; height: 12px; }
.badge.ok { background: var(--vert-clair); color: var(--vert); border-color: #bfe0cb; }
.badge.attention { background: var(--or-clair); color: var(--or-texte); border-color: var(--or-bord); }
.badge.faute { background: var(--rouge-clair); color: var(--rouge); border-color: #efc4bb; }
.badge.neutre { background: var(--surface2); color: var(--sourdine); border-color: var(--trait); }
.badge.info { background: var(--bleu-clair); color: var(--bleu); border-color: #c5d5ef; }

/* ---------- pastille d'aide (SPÉC-84) : au survol et au focus */
.aide { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 8px; border: 1px solid var(--trait2); color: var(--sourdine); font-size: 11px; font-weight: 600; cursor: help; position: relative; vertical-align: middle; margin-left: 4px; background: var(--surface); }
.aide:hover, .aide:focus-visible { border-color: var(--or); color: var(--or-texte); }
.aide .bulle { display: none; position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); width: 260px; background: var(--encre); color: #fff; font-size: 12.5px; font-weight: 400; line-height: 1.45; padding: 10px 12px; border-radius: 8px; z-index: 5; text-align: left; cursor: default; }
.aide:hover .bulle, .aide:focus-visible .bulle, .aide:focus-within .bulle { display: block; }
.aide .bulle::after { content: ""; position: absolute; left: 50%; bottom: -6px; transform: translateX(-50%); border: 6px solid transparent; border-top-color: var(--encre); border-bottom: 0; }

/* ---------- pipeline (SPÉC-80) */
.pipeline { display: flex; background: var(--surface); border: 1px solid var(--trait); border-radius: var(--r-carte); overflow: hidden; box-shadow: var(--ombre); list-style: none; margin: 0; padding: 0; }
.pipeline li { flex: 1; display: flex; }
.etape { flex: 1; display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-right: 1px solid var(--trait); position: relative; text-decoration: none; color: var(--texte); }
.pipeline li:last-child .etape { border-right: none; }
a.etape:hover { background: var(--surface2); }
.etape.actif { background: var(--or-clair); }
.etape.actif::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--or); }
.etape.verrou { cursor: not-allowed; color: var(--sourdine); }
.num { width: 28px; height: 28px; border-radius: 14px; display: grid; place-items: center; font-weight: 600; font-size: 13px; flex: none; border: 1.5px solid var(--trait2); color: var(--sourdine); background: var(--surface); }
.num svg { width: 14px; height: 14px; }
.num.fait { background: var(--vert); border-color: var(--vert); color: #fff; }
.num.encours { border-color: var(--or); color: var(--or-texte); background: var(--or-clair); }
.num.verrou { border-style: dashed; }
.num.casse { border-color: var(--rouge); color: var(--rouge); background: var(--rouge-clair); }
.num.petit { width: 24px; height: 24px; font-size: 11px; }
.etape .lib { display: flex; flex-direction: column; line-height: 1.25; }
.etape .lib b { font-weight: 600; color: inherit; }
.etape .lib small { color: var(--sourdine); font-size: 12px; }

/* ---------- tables */
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th { text-align: left; font-weight: 600; color: var(--sourdine); font-size: 12px; padding: 8px 12px; border-bottom: 1px solid var(--trait); background: var(--surface2); }
td { padding: 10px 12px; border-bottom: 1px solid var(--trait); vertical-align: middle; white-space: nowrap; }
td.libre { min-width: 260px; white-space: normal; }
td .btn { height: 30px; padding: 0 10px; font-size: 13px; }
.defile { overflow-x: auto; }

/* ---------- formulaire */
label.champ { display: flex; flex-direction: column; gap: 6px; font-weight: 500; color: var(--encre); }
label.champ small { font-weight: 400; color: var(--sourdine); }
.entree { height: 38px; border: 1px solid var(--trait2); border-radius: var(--r); padding: 0 12px; background: #fff; font: inherit; color: var(--texte); width: 100%; }
textarea.entree { height: auto; min-height: 64px; padding: 8px 12px; resize: vertical; }
.entree:focus-visible { border-color: var(--or); }
.choix { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1.5px solid var(--trait); border-radius: 10px; cursor: pointer; background: var(--surface); }
.choix:hover { border-color: var(--trait2); background: var(--surface2); }
.choix.coche { border-color: var(--or); background: var(--or-clair); }
.choix.inactif { cursor: not-allowed; color: var(--sourdine); }
.choix input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choix .rond { width: 18px; height: 18px; border-radius: 9px; border: 2px solid var(--trait2); flex: none; margin-top: 2px; display: grid; place-items: center; }
.choix.coche .rond { border-color: var(--or); }
.choix.coche .rond::after { content: ""; width: 8px; height: 8px; border-radius: 4px; background: var(--or); }
.choix b { display: block; color: var(--encre); }
.choix small { color: var(--sourdine); }
.choix:focus-within { box-shadow: var(--focus); }
.depot { border: 2px dashed var(--trait2); border-radius: var(--r-carte); padding: 28px; text-align: center; background: var(--surface2); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.depot svg { width: 32px; height: 32px; color: var(--or); }

/* ---------- états vides, bannières, accusé, dialogue (SPÉC-82, SPÉC-83) */
.vide { border: 1px dashed var(--trait2); border-radius: var(--r-carte); padding: 36px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; background: var(--surface); }
.vide > svg { width: 40px; height: 40px; color: var(--sourdine); }
.vide h2 { font-size: 17px; }
.vide p { color: var(--sourdine); max-width: 520px; }
.vide .actions { display: flex; gap: 10px; margin-top: 6px; flex-wrap: wrap; justify-content: center; }
.banniere { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; border-radius: 10px; border: 1px solid; font-size: 13.5px; }
.banniere > svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.banniere.info { background: var(--bleu-clair); border-color: #c5d5ef; color: #24447a; }
.banniere.attention { background: var(--or-clair); border-color: var(--or-bord); color: var(--or-texte); }
.banniere.ok { background: var(--vert-clair); border-color: #bfe0cb; color: #1f5c39; }
.banniere.faute { background: var(--rouge-clair); border-color: #efc4bb; color: #7d2c22; }
.banniere .btn { margin-left: auto; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px); background: var(--encre); color: #fff; padding: 12px 18px; border-radius: 10px; display: flex; gap: 10px; align-items: center; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); opacity: 0; transition: all .2s; z-index: 20; pointer-events: none; font-size: 14px; }
.toast.visible { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast svg { width: 18px; height: 18px; color: #8fd3a8; }
.voile { position: fixed; inset: 0; background: rgba(28, 27, 24, .45); display: grid; place-items: center; z-index: 15; }
.dialogue { background: var(--surface); border-radius: 14px; width: 520px; max-width: calc(100vw - 32px); padding: 24px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); display: flex; flex-direction: column; gap: 14px; }
.dialogue .pied { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }
.dialogue ul { margin: 4px 0 0; padding-left: 18px; }
.barre { height: 8px; border-radius: 4px; background: var(--trait); overflow: hidden; }
.barre > div { height: 100%; background: var(--or); border-radius: 4px; transition: width .4s; }
.barre.vert > div { background: var(--vert); }
.barre.rouge > div { background: var(--rouge); }
.jalon { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--trait); }
.jalon:last-child { border-bottom: none; }
.jalon b { color: var(--encre); }
.jalon.attente b { color: var(--sourdine); }
.jalon small { color: var(--sourdine); }
.spin { width: 14px; height: 14px; border: 2px solid var(--or-bord); border-top-color: var(--or); border-radius: 50%; animation: tourne 1s linear infinite; display: inline-block; }
@keyframes tourne { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } .toast, .btn, .barre > div { transition: none; } }

/* ---------- onglets, assistant, matrice, lignée, atelier */
.onglets { display: flex; gap: 4px; border-bottom: 1px solid var(--trait); list-style: none; margin: 0; padding: 0; }
.onglet { padding: 8px 14px; border: none; background: none; color: var(--sourdine); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; text-decoration: none; display: inline-block; }
.onglet:hover { color: var(--encre); }
.onglet.actif { color: var(--encre); border-bottom-color: var(--or); }
.stepper { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; flex-wrap: wrap; }
.stepper .trait { width: 32px; height: 1px; background: var(--trait2); margin: 0 6px; }
.stepper .courant { font-weight: 600; color: var(--encre); }
.stepper .autre { color: var(--sourdine); }
.pied-carte { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; padding-top: 14px; border-top: 1px solid var(--trait); gap: 10px; flex-wrap: wrap; }
.matrice td { text-align: center; padding: 6px; }
.matrice .cellule { width: 100%; height: auto; flex-direction: column; gap: 2px; padding: 6px; }
.matrice .cellule b { font-size: 16px; }
.matrice .cellule small { color: var(--sourdine); }
.matrice .cellule.diagonale { background: var(--or-clair); border-color: var(--or-bord); }
.matrice .cellule.non-reconnu { background: var(--rouge-clair); border-color: #efc4bb; }
.lignee { display: block; max-width: 100%; }
.lignee .noeud { cursor: pointer; }
.lignee .noeud circle { fill: var(--texte); stroke: var(--texte); stroke-width: 2; }
.lignee .noeud:hover circle, .lignee .noeud:focus circle { stroke: var(--or); stroke-width: 3; }
.lignee .noeud.fort circle { fill: var(--or); stroke: var(--or); }
.lignee .noeud.isole circle { fill: #fff; stroke: var(--rouge); }
.lignee .noeud.faute circle { stroke: var(--rouge); stroke-width: 3; }
.lignee .noeud text { font-size: 11px; fill: var(--encre); }
.lignee .noeud.isole text { fill: var(--rouge); }
.lignee .couche-lib { font-size: 12px; fill: var(--sourdine); font-weight: 600; }
.lignee line { stroke: #e6e2d8; }
.lignee line.fort { stroke: var(--or); stroke-width: 2.5; }
.lignee-legende { display: flex; gap: 18px; font-size: 12.5px; color: var(--sourdine); padding: 0 6px; flex-wrap: wrap; }
.lignee-legende .puce { display: inline-block; width: 9px; height: 9px; border-radius: 5px; margin-right: 5px; vertical-align: middle; }
.lignee-liste { font-size: 13px; }
.lignee-liste ul { margin: 0; padding-left: 18px; }
.panneau b { display: block; font-size: 16px; color: var(--encre); margin-bottom: 8px; }
.panneau .renvois { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; align-items: center; }
.jauge { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

@media (max-width: 960px) {
  .deux, .g3, .g4 { grid-template-columns: 1fr; }
  .g2 { grid-template-columns: 1fr; }
  .app { flex-direction: column; }
  .nav { width: 100%; border-right: none; border-bottom: 1px solid var(--trait); }
  .entete, .contenu { padding-left: 16px; padding-right: 16px; }
  .pipeline { flex-direction: column; }
  .etape { border-right: none; border-bottom: 1px solid var(--trait); }
}

/* ---------- le site public (v4.1, amendement « la bascule », SPÉC-90 à 92) : même gabarit, sans navigation latérale */
.site-entete { gap: 20px; }
.site-entete .marque { border: none; margin: 0; padding: 0; text-decoration: none; color: var(--encre); }
.barre-site ul { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.barre-site a { display: inline-block; padding: 6px 10px; border-radius: var(--r); color: var(--texte); font-weight: 500; text-decoration: none; }
.barre-site a:hover { background: var(--surface2); }
.barre-site a[aria-current="page"] { color: var(--encre); background: var(--or-clair); box-shadow: inset 0 -2px 0 var(--or); }
.site-contenu { width: 100%; max-width: 1040px; margin: 0 auto; gap: 32px; }
.accroche { display: flex; flex-direction: column; gap: 16px; max-width: 760px; padding-top: 32px; }
.accroche .badge { align-self: flex-start; }
.accroche h1 { font-size: 40px; line-height: 1.15; }
.accroche .sous { font-size: 17px; color: var(--sourdine); max-width: 640px; }
.actions-accroche { display: flex; gap: 10px; flex-wrap: wrap; }
.encart { display: flex; gap: 24px; align-items: center; background: var(--or-clair); border-color: var(--or-bord); }
.pied { width: 100%; max-width: 1040px; margin: 0 auto; display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding: 16px 32px 32px; border-top: 1px solid var(--trait); font-size: 12.5px; color: var(--sourdine); }
.pied a { color: var(--sourdine); }
.texte { max-width: 780px; background: var(--surface); border: 1px solid var(--trait); border-radius: var(--r-carte); padding: 28px 36px; box-shadow: var(--ombre); }
.texte h1 { font-size: 26px; }
.texte h2 { margin: 24px 0 6px; }
.texte p, .texte ul { margin: 8px 0; line-height: 1.65; }
.texte li { margin: 4px 0; }
.texte .date { color: var(--sourdine); font-size: 12.5px; }
.texte-nav { margin-top: 28px; padding-top: 14px; border-top: 1px solid var(--trait); font-size: 13px; }
.formulaire { width: 100%; max-width: 460px; margin: 16px auto 0; display: flex; flex-direction: column; gap: 14px; }
.choix:has(input:checked) { border-color: var(--or); background: var(--or-clair); }
.choix:has(input:checked) .rond { border-color: var(--or); }
.choix:has(input:checked) .rond::after { content: ""; width: 8px; height: 8px; border-radius: 4px; background: var(--or); }
.choix:has(input[type="checkbox"]) .rond { border-radius: 4px; }
.choix:has(input[type="checkbox"]:checked) .rond::after { border-radius: 2px; }
@media (max-width: 760px) {
  .site-entete { flex-wrap: wrap; }
  .accroche h1 { font-size: 30px; }
  .encart { flex-direction: column; align-items: flex-start; }
}

/* ---------- le Mirroir (v4.1, SPÉC-91) : la vue « le Mirroir » du prototype, présence comprise */
.mirroir { width: 100%; max-width: 900px; margin: 0 auto; display: flex; flex-direction: column; gap: 20px; }
.mirroir-tete { display: flex; flex-direction: column; align-items: center; gap: 6px; padding-top: 24px; text-align: center; }
.mirroir-tete .logo { width: 44px; height: 44px; border-radius: 10px; background: var(--encre); color: #fff; display: grid; place-items: center; font-family: Georgia, serif; font-size: 24px; }
.mirroir-tete h1 { font-size: 26px; }
#mirroir-chat .entete-carte a { margin-left: auto; }
#mirroir-fil { max-height: 20rem; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 2px 0 10px; }
.mirroir-msg { margin: 0; padding: 8px 12px; border-radius: 10px; max-width: 88%; white-space: pre-wrap; line-height: 1.45; }
.mirroir-msg--presence { align-self: flex-start; background: var(--or-clair); border-left: 2px solid var(--or); border-radius: 0 10px 10px 0; color: var(--texte); }
.mirroir-msg--visiteur { align-self: flex-end; background: var(--surface2); border: 1px solid var(--trait); }
#mirroir-parole { display: flex; gap: 8px; margin: 4px 0 8px; }
.mirroir-champs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; max-width: 560px; text-align: left; }
#mirroir-jauge { height: 6px; }
.mirroir-promesse { text-align: center; color: var(--sourdine); max-width: 640px; margin: 0 auto; }
.mirroir-promesse b { color: var(--encre); display: block; font-size: 15px; margin-bottom: 4px; }
.mirroir-couches { display: flex; gap: 8px; list-style: none; margin: 12px 0 8px; padding: 0; }
.mirroir-couches li { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 6px; border: 1px solid var(--trait); border-radius: 10px; background: var(--surface); text-align: center; font-size: 12.5px; color: var(--sourdine); }
.mirroir-couches li.faite { border-color: var(--vert); color: var(--texte); }
.mirroir-couches li.faite .num { background: var(--vert); border-color: var(--vert); color: #fff; }
.mirroir-couches li.en-cours { border-color: var(--or); background: var(--or-clair); color: var(--encre); }
.mirroir-couches li.en-cours .num { border-color: var(--or); color: var(--or-texte); }
#mirroir-panneau[hidden], #mirroir-voile[hidden] { display: none !important; }
#mirroir-voile { position: fixed; inset: 0; background: rgba(28, 27, 24, .35); z-index: 40; }
#mirroir-panneau { position: fixed; top: 0; right: 0; bottom: 0; z-index: 41; width: min(38rem, 94vw); background: var(--surface); border-left: 1px solid var(--trait2); box-shadow: -12px 0 40px rgba(28, 27, 24, .18); display: flex; flex-direction: column; }
#mirroir-panneau header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--trait); }
.mirroir-doc { overflow-y: auto; padding: 20px 24px 48px; line-height: 1.6; }
.mirroir-doc h1 { font-size: 22px; margin: 0 0 12px; }
.mirroir-doc h2 { font-size: 17px; margin: 24px 0 8px; color: var(--or-texte); }
.mirroir-doc h3 { font-size: 14px; margin: 16px 0 6px; }
.mirroir-doc p, .mirroir-doc ul { margin: 8px 0; }
.mirroir-doc pre { background: var(--surface2); border: 1px solid var(--trait); border-radius: var(--r); padding: 10px 12px; overflow-x: auto; font-size: 12.5px; }
.mirroir-doc blockquote { border-left: 2px solid var(--or); margin: 10px 0; padding: 2px 0 2px 12px; color: var(--sourdine); }
@media (max-width: 760px) {
  .mirroir-champs { grid-template-columns: 1fr; }
  .mirroir-couches { flex-wrap: wrap; }
}
/* un bouton dans le dépôt garde l'icône de tous les boutons (SPÉC-92 : un seul style de bouton) */
.depot .btn svg { width: 16px; height: 16px; color: currentColor; }
