:root {
  --fond: #f4f5f7; --surface: #ffffff; --surface-2: #f8f9fb; --bord: #e2e5ea; --bord-fort: #cfd4dc;
  --texte: #1c2230; --texte-2: #4b5466; --texte-3: #7b8496;
  --accent: #2f6fdf; --accent-doux: #e8f0fd; --accent-texte: #1d4fa8;
  --critique: #c62d2d; --critique-doux: #fdeaea;
  --eleve: #d9731a; --eleve-doux: #fdf1e5;
  --moyen: #b8920b; --moyen-doux: #fbf5dc;
  --faible: #3d8b5a; --faible-doux: #e7f4ec;
  --s-ouvert: #8b93a3; --s-redaction: #2f6fdf; --s-a_valider: #d9731a; --s-valide: #2e9b5f;
  --ombre: 0 1px 2px rgba(20, 28, 45, .06), 0 4px 16px rgba(20, 28, 45, .05);
  --rayon: 12px;
  --police: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --fond: #0f131a; --surface: #171c25; --surface-2: #1c2230; --bord: #262e3c; --bord-fort: #343e50;
  --texte: #e6e9ef; --texte-2: #b3bbc9; --texte-3: #7f8a9d;
  --accent: #5b93f5; --accent-doux: #1a2740; --accent-texte: #9cc0ff;
  --critique: #ef6060; --critique-doux: #3a1b1d;
  --eleve: #f0954a; --eleve-doux: #3a2617;
  --moyen: #e0bd3a; --moyen-doux: #352e14;
  --faible: #5fbf83; --faible-doux: #173024;
  --s-ouvert: #6f7889;
  --ombre: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fond: #0f131a; --surface: #171c25; --surface-2: #1c2230; --bord: #262e3c; --bord-fort: #343e50;
    --texte: #e6e9ef; --texte-2: #b3bbc9; --texte-3: #7f8a9d;
    --accent: #5b93f5; --accent-doux: #1a2740; --accent-texte: #9cc0ff;
    --critique: #ef6060; --critique-doux: #3a1b1d;
    --eleve: #f0954a; --eleve-doux: #3a2617;
    --moyen: #e0bd3a; --moyen-doux: #352e14;
    --faible: #5fbf83; --faible-doux: #173024;
    --s-ouvert: #6f7889;
    --ombre: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; font: 15px/1.6 var(--police); background: var(--fond); color: var(--texte); -webkit-font-smoothing: antialiased; }
a { color: var(--accent-texte); }
h1, h2, h3 { line-height: 1.25; margin: 0; }
p { margin: 0 0 .7em; }
ul { margin: .2em 0 .8em; padding-left: 1.2em; }
li { margin: .25em 0; }
code { font-family: var(--mono); font-size: .88em; background: var(--surface-2); border: 1px solid var(--bord); border-radius: 5px; padding: 0 .3em; }
[hidden] { display: none !important; }
* { scrollbar-color: var(--bord-fort) transparent; scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--bord-fort); border-radius: 10px; border: 2px solid var(--fond); }

/* Boutons */
.btn { display: inline-flex; align-items: center; gap: .4em; border: 1px solid transparent; border-radius: 9px; padding: .5em .95em; font: 600 14px var(--police); cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s, color .15s; white-space: nowrap; }
.btn-primaire { background: var(--accent); color: #fff; }
.btn-primaire:hover { filter: brightness(1.08); }
.btn-secondaire { background: var(--surface); color: var(--texte); border-color: var(--bord-fort); }
.btn-secondaire:hover { border-color: var(--accent); color: var(--accent-texte); }
.btn-fantome { background: transparent; color: var(--texte-2); }
.btn-fantome:hover { background: var(--surface-2); color: var(--texte); }
.btn-petit { padding: .3em .65em; font-size: 13px; }
.lien { background: none; border: 0; color: var(--accent-texte); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Connexion */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(1200px 600px at 20% -10%, var(--accent-doux), transparent), var(--fond); }
.login-carte { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--bord); border-radius: 18px; padding: 32px; box-shadow: var(--ombre); display: grid; gap: 16px; }
.login-logo, .marque { width: 44px; height: 44px; border-radius: 11px; background: var(--texte); color: var(--surface); display: grid; place-items: center; font-weight: 800; letter-spacing: .02em; font-size: 14px; }
.login h1 { font-size: 22px; }
.login-sous { color: var(--texte-3); margin: -10px 0 4px; }
.champ { display: grid; gap: 6px; font-size: 13px; color: var(--texte-2); font-weight: 600; }
.champ input { font: 15px var(--police); padding: .65em .8em; border: 1px solid var(--bord-fort); border-radius: 9px; background: var(--surface-2); color: var(--texte); }
.champ input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-doux); }
.choix-noms { display: flex; gap: 6px; flex-wrap: wrap; }
.choix-noms button { border: 1px solid var(--bord-fort); background: var(--surface-2); color: var(--texte); border-radius: 999px; padding: .35em .8em; cursor: pointer; font: 600 13px var(--police); display: inline-flex; align-items: center; gap: .4em; }
.choix-noms button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-doux); color: var(--accent-texte); }
.pastille { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.login-erreur { color: var(--critique); min-height: 1.2em; margin: 0; font-size: 14px; }

/* En-tête */
.entete { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 24px; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--bord); }
.entete-gauche { display: flex; align-items: center; gap: 12px; min-width: 0; }
.entete h1 { font-size: 17px; }
.entete-sous { margin: 0; color: var(--texte-3); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entete-centre { flex: 1; max-width: 420px; }
.entete-droite { display: flex; align-items: center; gap: 8px; }
.progression { display: grid; gap: 4px; font-size: 12px; color: var(--texte-3); }
.progression-barre { display: flex; height: 8px; border-radius: 99px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--bord); }
.progression-barre span { display: block; height: 100%; transition: width .3s; }
.progression-texte { display: flex; gap: 12px; flex-wrap: wrap; }
.progression-texte b { color: var(--texte); }
.presence { display: flex; align-items: center; }
.avatar { width: 30px; height: 30px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 12.5px; border: 2px solid var(--surface); margin-left: -6px; position: relative; cursor: default; }
.avatar:first-child { margin-left: 0; }
.avatar.moi { box-shadow: 0 0 0 2px var(--accent); }
.connexion { width: 9px; height: 9px; border-radius: 50%; background: var(--s-ouvert); }
.connexion.ok { background: var(--s-valide); }
.connexion.ko { background: var(--critique); animation: clignote 1s infinite; }
@keyframes clignote { 50% { opacity: .35; } }

/* Filtres */
.barre-filtres { position: relative; z-index: 15; display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; padding: 10px 24px; background: color-mix(in srgb, var(--fond) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--bord); }
.filtre-groupe { display: flex; align-items: center; gap: 8px; }
.filtre-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--texte-3); }
.puces { display: flex; gap: 4px; flex-wrap: wrap; }
.puce { border: 1px solid var(--bord); background: var(--surface); color: var(--texte-2); border-radius: 999px; padding: .2em .65em; font: 600 12.5px var(--police); cursor: pointer; display: inline-flex; align-items: center; gap: .35em; }
.puce:hover { border-color: var(--bord-fort); color: var(--texte); }
.puce[aria-pressed="true"] { background: var(--texte); color: var(--surface); border-color: var(--texte); }
.puce .compte { opacity: .6; font-weight: 500; }
.filtre-fin { margin-left: auto; }
#f-recherche { font: 14px var(--police); padding: .4em .7em; border: 1px solid var(--bord-fort); border-radius: 9px; background: var(--surface); color: var(--texte); width: 240px; }
#f-recherche:focus { outline: none; border-color: var(--accent); }
.interrupteur { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--texte-2); cursor: pointer; user-select: none; }
.interrupteur input { appearance: none; width: 30px; height: 18px; border-radius: 99px; background: var(--bord-fort); position: relative; cursor: pointer; transition: background .15s; margin: 0; }
.interrupteur input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform .15s; }
.interrupteur input:checked { background: var(--accent); }
.interrupteur input:checked::after { transform: translateX(12px); }

/* Mise en page */
.mise-en-page { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; padding: 20px 24px; }
.sommaire { position: sticky; top: 84px; align-self: start; max-height: calc(100vh - 100px); overflow: auto; padding-right: 6px; }
.sommaire h4 { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--texte-3); margin: 14px 0 6px; }
.sommaire h4:first-child { margin-top: 0; }
.sommaire-grille { display: flex; flex-wrap: wrap; gap: 5px; }
.som-id { position: relative; border: 1px solid var(--bord); background: var(--surface); color: var(--texte-2); border-radius: 7px; min-width: 44px; padding: .25em .4em; font: 700 12px var(--mono); cursor: pointer; text-align: center; text-decoration: none; border-left: 4px solid var(--s-ouvert); }
.som-id:hover { border-color: var(--bord-fort); color: var(--texte); }
.som-id[data-statut="redaction"] { border-left-color: var(--s-redaction); }
.som-id[data-statut="a_valider"] { border-left-color: var(--s-a_valider); }
.som-id[data-statut="valide"] { border-left-color: var(--s-valide); color: var(--s-valide); }
.som-id.masque { opacity: .3; }
.som-id .qui { position: absolute; top: -4px; right: -4px; width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--fond); }
.contenu { min-width: 0; }

/* Sections */
.section-titre { display: flex; align-items: baseline; gap: 12px; margin: 8px 0 16px; }
.section-titre .num { font: 700 13px var(--mono); color: var(--texte-3); }
.section-titre h2 { font-size: 21px; }
.intro { margin-bottom: 36px; }
.intro-meta { color: var(--texte-3); font-size: 13px; margin-top: -8px; }
.intro-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); gap: 12px; }
.intro-large ul, .intro-alerte ul { columns: 2 520px; column-gap: 36px; }
.intro-large li, .intro-alerte li { break-inside: avoid; }
.intro-carte { background: var(--surface); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 16px 18px; box-shadow: var(--ombre); }
.intro-carte h3 { font-size: 15px; margin-bottom: 8px; }
.intro-large, .intro-alerte { grid-column: 1 / -1; }
.intro-large { border-left: 4px solid var(--accent); }
.intro-alerte { border-left: 4px solid var(--critique); }
.intro-carte p, .intro-carte li { font-size: 14px; color: var(--texte-2); }
.legende { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 14px; font-size: 12.5px; color: var(--texte-3); }
.legende span { display: inline-flex; align-items: center; gap: 6px; }
.theme-titre { display: flex; align-items: baseline; gap: 12px; margin: 34px 0 14px; padding-top: 6px; border-top: 1px solid var(--bord); }
.theme-titre h2 { font-size: 19px; }
.theme-titre .compte { color: var(--texte-3); font-size: 13px; }

/* Cartes question */
.carte { background: var(--surface); border: 1px solid var(--bord); border-radius: 16px; box-shadow: var(--ombre); margin-bottom: 18px; overflow: hidden; border-top: 4px solid var(--s-ouvert); }
.carte[data-statut="redaction"] { border-top-color: var(--s-redaction); }
.carte[data-statut="a_valider"] { border-top-color: var(--s-a_valider); }
.carte[data-statut="valide"] { border-top-color: var(--s-valide); }
.carte-entete { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 16px 20px 12px; }
.carte-id { font: 800 22px var(--mono); letter-spacing: -.02em; }
.carte-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: var(--texte-3); }
.carte-meta .sep { opacity: .5; }
.refs a { font: 600 12px var(--mono); text-decoration: none; background: var(--surface-2); border: 1px solid var(--bord); border-radius: 6px; padding: .05em .4em; margin-right: 3px; color: var(--texte-2); }
.refs a:hover { border-color: var(--accent); color: var(--accent-texte); }
.badge { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: .15em .65em; font-size: 12px; font-weight: 700; }
.badge-critique { background: var(--critique-doux); color: var(--critique); }
.badge-eleve { background: var(--eleve-doux); color: var(--eleve); }
.badge-moyen { background: var(--moyen-doux); color: var(--moyen); }
.badge-faible { background: var(--faible-doux); color: var(--faible); }
.badge-nature { background: var(--surface-2); color: var(--texte-2); border: 1px solid var(--bord); font-weight: 600; }
.carte-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.statuts { display: inline-flex; border: 1px solid var(--bord-fort); border-radius: 9px; overflow: hidden; }
.statuts button { border: 0; background: var(--surface); color: var(--texte-3); font: 600 12.5px var(--police); padding: .35em .7em; cursor: pointer; border-right: 1px solid var(--bord); }
.statuts button:last-child { border-right: 0; }
.statuts button:hover { color: var(--texte); background: var(--surface-2); }
.statuts button[aria-pressed="true"] { color: #fff; }
.statuts button[data-v="ouvert"][aria-pressed="true"] { background: var(--s-ouvert); }
.statuts button[data-v="redaction"][aria-pressed="true"] { background: var(--s-redaction); }
.statuts button[data-v="a_valider"][aria-pressed="true"] { background: var(--s-a_valider); }
.statuts button[data-v="valide"][aria-pressed="true"] { background: var(--s-valide); }
.resp { position: relative; }
.resp-btn { border: 1px solid var(--bord-fort); background: var(--surface); color: var(--texte); border-radius: 9px; padding: .35em .7em; font: 600 12.5px var(--police); cursor: pointer; display: inline-flex; align-items: center; gap: .4em; }
.resp-btn .lbl { color: var(--texte-3); font-weight: 500; }
.menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 10; min-width: 170px; background: var(--surface); border: 1px solid var(--bord-fort); border-radius: 10px; box-shadow: var(--ombre); padding: 4px; }
.menu button { display: flex; width: 100%; align-items: center; gap: 8px; border: 0; background: none; color: var(--texte); font: 500 13.5px var(--police); padding: .45em .6em; border-radius: 7px; cursor: pointer; text-align: left; }
.menu button:hover, .menu button:focus-visible { background: var(--surface-2); outline: none; }
.menu button[aria-checked="true"] { color: var(--accent-texte); font-weight: 700; }
.trace { font-size: 11.5px; color: var(--texte-3); }

/* Corps de carte : trois colonnes qui se replient seules selon la largeur
   (question | avis | proposition + réponse). Les filets entre colonnes viennent
   du fond visible dans l'espace de 1 px entre elles. */
.carte-corps { display: flex; flex-wrap: wrap; gap: 1px; background: var(--bord); border-top: 1px solid var(--bord); }
.col { background: var(--surface); flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; }
.col-avis { flex: 1.9 1 460px; }
.col-reponse { flex: 1.6 1 420px; background: var(--surface-2); }
.col-reponse .reponse { flex: 1; display: flex; flex-direction: column; }
.col-reponse .zone { flex: 1; display: flex; }
.col-reponse .zone textarea { flex: 1; }
.bloc { padding: 14px 20px; border-top: 1px solid var(--bord); }
.col > .bloc:first-child { border-top: 0; }
.bloc-titre { display: flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--texte-3); margin-bottom: 8px; }
.bloc-titre .n { font-family: var(--mono); background: var(--surface-2); border: 1px solid var(--bord); border-radius: 5px; padding: 0 .35em; color: var(--texte-2); }
.brute { margin: 0; padding: 12px 14px; background: var(--surface-2); border: 1px dashed var(--bord-fort); border-radius: 10px; font: 14.5px/1.55 var(--mono); color: var(--texte); white-space: pre-wrap; }
.clair { font-size: 15px; }
.avis { font-size: 14.5px; color: var(--texte); }
.avis-cadre { border-left: 3px solid var(--accent); padding-left: 14px; }
.sources { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.sources span { font-size: 11.5px; color: var(--texte-3); background: var(--surface-2); border: 1px solid var(--bord); border-radius: 6px; padding: .1em .5em; }
.prop { background: var(--accent-doux); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 10px; padding: 12px 14px; font-size: 14px; white-space: pre-wrap; color: var(--texte); }
.prop-actions { display: flex; gap: 8px; margin-top: 8px; align-items: center; }
.prop-actions .confirm { font-size: 13px; color: var(--texte-2); }

/* Zone de réponse multijoueur */
.reponse { background: var(--surface-2); }
.col-reponse .bloc-prop { background: var(--surface-2); }
.zone { position: relative; }
.zone textarea { width: 100%; min-height: 140px; resize: vertical; font: 15px/1.6 var(--police); color: var(--texte); background: var(--surface); border: 1.5px solid var(--bord-fort); border-radius: 10px; padding: 12px 14px; transition: border-color .15s, box-shadow .15s; overflow: hidden; }
.zone textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-doux); }
.zone textarea[readonly] { background: var(--surface-2); cursor: not-allowed; }
.zone.occupe textarea { border-color: var(--couleur-autre); box-shadow: 0 0 0 3px color-mix(in srgb, var(--couleur-autre) 18%, transparent); }
.zone-etiquette { position: absolute; top: -11px; right: 12px; background: var(--couleur-autre); color: #fff; font-size: 12px; font-weight: 700; border-radius: 99px; padding: .1em .6em; display: inline-flex; align-items: center; gap: 5px; }
.zone-etiquette .points::after { content: "…"; animation: points 1.2s infinite; }
@keyframes points { 0% { content: "."; } 33% { content: ".."; } 66% { content: "…"; } }
.zone-pied { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: 8px; font-size: 12.5px; color: var(--texte-3); }
.zone-pied .etat-envoi { font-weight: 600; }
.zone-pied .etat-envoi.ok { color: var(--s-valide); }
.zone-pied .etat-envoi.attente { color: var(--accent-texte); }
.zone-pied .etat-envoi.erreur { color: var(--critique); }
.zone-pied .fin { margin-left: auto; display: flex; gap: 6px; }
.versions { margin-top: 10px; border: 1px solid var(--bord); border-radius: 10px; background: var(--surface); max-height: 320px; overflow: auto; }
.version { padding: 10px 12px; border-bottom: 1px solid var(--bord); font-size: 13px; }
.version:last-child { border-bottom: 0; }
.version-tete { display: flex; align-items: center; gap: 8px; color: var(--texte-2); }
.version-tete .fin { margin-left: auto; display: flex; gap: 6px; }
.version pre { white-space: pre-wrap; font: 13px/1.5 var(--police); margin: 8px 0 0; color: var(--texte); background: var(--surface-2); border-radius: 8px; padding: 8px 10px; }
.print-reponse { display: none; }

.aucun { text-align: center; color: var(--texte-3); padding: 40px; }

/* Exports */
.exports { margin-top: 44px; padding-top: 8px; border-top: 1px solid var(--bord); }
.exports-grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; }
.export-carte { background: var(--surface); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 18px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--ombre); }
.export-carte h3 { font-size: 15.5px; }
.export-carte p { font-size: 13.5px; color: var(--texte-2); flex: 1; margin: 0; }
.export-carte .btn { align-self: flex-start; }
.pied { margin-top: 24px; font-size: 13px; color: var(--texte-3); }

/* Modal, toast */
.modal-fond { position: fixed; inset: 0; z-index: 50; background: rgba(10, 14, 22, .45); display: grid; place-items: center; padding: 20px; }
.modal { width: min(720px, 100%); max-height: 85vh; overflow: auto; background: var(--surface); border: 1px solid var(--bord); border-radius: 16px; box-shadow: var(--ombre); }
.modal-entete { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; background: var(--surface); border-bottom: 1px solid var(--bord); }
.modal-corps { padding: 8px 20px 20px; }
.lexique dt { font-weight: 700; margin-top: 12px; }
.lexique dd { margin: 2px 0 0; color: var(--texte-2); font-size: 14px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); opacity: 0; pointer-events: none; z-index: 60; background: var(--texte); color: var(--surface); padding: .6em 1em; border-radius: 10px; font-size: 14px; font-weight: 600; transition: opacity .2s, transform .2s; }
.toast.visible { opacity: 1; transform: translateX(-50%); }

@media (max-width: 1100px) {
  .mise-en-page { grid-template-columns: 1fr; }
  .sommaire { position: static; max-height: none; }
  .entete-centre { display: none; }
}
@media (max-width: 700px) {
  .entete { padding: 10px 14px; }
  .entete-sous { display: none; }
  .mise-en-page { padding: 14px; }
  .carte-actions { margin-left: 0; }
  #f-recherche { width: 100%; }
  .filtre-fin { margin-left: 0; flex-wrap: wrap; }
}

@media print {
  :root { --fond: #fff; --surface: #fff; --surface-2: #f6f6f6; --texte: #000; --texte-2: #222; --texte-3: #555; --bord: #ccc; --ombre: none; color-scheme: light; }
  .entete, .barre-filtres, .sommaire, .exports, .carte-actions, .prop-actions, .zone, .zone-pied .fin, .versions, .toast, .modal-fond { display: none !important; }
  .mise-en-page { display: block; padding: 0; max-width: none; }
  .carte-corps { display: block; background: none; }
  .col { display: block; }
  .carte { break-inside: auto; box-shadow: none; border: 1px solid #bbb; margin-bottom: 14px; }
  .bloc { break-inside: avoid; }
  .print-reponse { display: block; white-space: pre-wrap; border: 1px solid #bbb; border-radius: 8px; padding: 10px 12px; min-height: 2em; }
  .intro-carte { box-shadow: none; break-inside: avoid; }
  a { color: #000; text-decoration: none; }
  body { font-size: 11pt; }
}

/* Masquage des avis ou des propositions (mode réunion) */
body.sans-avis .bloc-avis, body.sans-prop .bloc-prop { display: none; }
.avatar.moi { cursor: pointer; }

/* Références survolables */
.xref { cursor: help; border-bottom: 1px dotted currentColor; text-decoration: none; border-radius: 3px; }
span.xref { cursor: pointer; }
.xref-q { color: var(--accent-texte); font-weight: 600; }
.xref-cdc { color: inherit; }
.xref-regle { color: inherit; border-bottom-style: dashed; }
span.xref:hover, span.xref:focus-visible { background: var(--accent-doux); outline: none; }
.infobulle { position: fixed; z-index: 70; max-width: 440px; background: var(--surface); color: var(--texte); border: 1px solid var(--bord-fort); border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.25); padding: 10px 12px; font-size: 13.5px; line-height: 1.5; pointer-events: none; }
.ib-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-bottom: 6px; }
.ib-tete b { font-family: var(--mono); font-size: 13.5px; }
.ib-tete span { color: var(--texte-2); font-weight: 600; }
.ib-texte { margin: 0 0 6px; }
.ib-pied { font-size: 12px; color: var(--texte-3); }
.carte.eclair { animation: eclair 1.4s ease-out; }
@keyframes eclair { 0% { box-shadow: 0 0 0 4px var(--accent); } 100% { box-shadow: var(--ombre); } }
@media print { .xref { border: 0; color: inherit; background: none; } .infobulle { display: none !important; } }
