/* Police de la charte de l'Ordre, hébergée sur la plateforme (licence SIL OFL : fonts/LICENCE-Montserrat-OFL.txt) */
@font-face { font-family: Montserrat; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/montserrat-400.woff2) format('woff2'); }
@font-face { font-family: Montserrat; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/montserrat-500.woff2) format('woff2'); }
@font-face { font-family: Montserrat; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/montserrat-600.woff2) format('woff2'); }
@font-face { font-family: Montserrat; font-style: normal; font-weight: 700; font-display: swap; src: url(/fonts/montserrat-700.woff2) format('woff2'); }

:root {
  /* Charte de l'Ordre (oeccabenin.bj) : bleu marine et or */
  --primaire: #02254f;
  --primaire-fonce: #011a38;
  --primaire-clair: #e6ecf4;
  --or: #c7a14f;
  --or-clair: #f7f0e1;
  --succes: #198754;
  --succes-clair: #e6f4ec;
  /* Variables du kit d'illustrations OECCA */
  --oecca-primary: var(--primaire);
  --oecca-accent: var(--or);
  --rouge: #c0392b;
  --rouge-clair: #fbe9e7;
  --bleu: #1f5fa8;
  --bleu-clair: #e6eef8;
  --texte: #1b2420;
  --texte-2: #55625b;
  --bord: #dde3df;
  --fond: #f4f6f5;
  --carte: #ffffff;
  --ombre: 0 1px 2px rgba(16, 32, 24, .06), 0 4px 16px rgba(16, 32, 24, .06);
  --rayon: 12px;
  --marge: clamp(16px, 3vw, 56px);       /* marges latérales, proportionnelles à l'écran */
  --largeur-max: 1920px;                  /* au-delà (très grands écrans), le contenu reste centré */
  font-family: Montserrat, "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--texte);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--fond); min-height: 100vh; display: flex; flex-direction: column; line-height: 1.5; }
a { color: var(--primaire); }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: clamp(1.35rem, 1.1rem + .9vw, 1.9rem); }
h2 { font-size: 1.2rem; }
h3 { font-size: 1.02rem; }
p { margin: 0 0 1em; }
.muted { color: var(--texte-2); }
.small { font-size: .875rem; }
.nowrap { white-space: nowrap; }
[hidden] { display: none !important; }

/* --- En-tête --------------------------------------------------------- */
.topbar { background: var(--primaire-fonce); color: #fff; position: sticky; top: 0; z-index: 10; }
.topbar-inner { max-width: var(--largeur-max); margin: 0 auto; padding: 10px var(--marge); display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; margin-right: auto; }
.brand-mark svg { width: 36px; height: 36px; display: block; }
.brand-mark rect { fill: var(--primaire); stroke: rgba(255,255,255,.25); }
.brand-mark path { stroke: var(--or); stroke-width: 3.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text small { opacity: .75; font-size: .75rem; letter-spacing: .04em; text-transform: uppercase; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a, .nav button { color: rgba(255,255,255,.85); text-decoration: none; padding: 8px 12px; border-radius: 8px; font: inherit; font-size: .93rem; background: none; border: 0; cursor: pointer; }
.nav a:hover, .nav button:hover { background: rgba(255,255,255,.1); color: #fff; }
.nav a.actif { background: rgba(255,255,255,.14); color: #fff; }
.nav .user-chip { font-size: .82rem; opacity: .8; padding: 0 8px; border-left: 1px solid rgba(255,255,255,.2); margin-left: 6px; }
.menu-toggle { display: none; background: none; border: 1px solid rgba(255,255,255,.3); color: #fff; border-radius: 8px; padding: 4px 10px; font-size: 1.2rem; cursor: pointer; }
.flag-band { display: flex; height: 4px; }
.flag-band span:nth-child(1) { flex: 2; background: #138d4c; }
.flag-band span:nth-child(2) { flex: 1; background: #f4c430; }
.flag-band span:nth-child(3) { flex: 1; background: #d62828; }

@media (max-width: 1180px) {
  .menu-toggle { display: block; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--primaire-fonce); flex-direction: column; align-items: stretch; padding: 8px 16px 16px; }
  .nav.ouvert { display: flex; }
  .nav .user-chip { border: 0; margin: 8px 0 0; padding: 8px 12px; }
}

/* --- Mise en page ------------------------------------------------------ */
.container { width: 100%; max-width: var(--largeur-max); margin: 0 auto; padding: 28px var(--marge) 48px; flex: 1; outline: none; }
.footer { text-align: center; font-size: .8rem; color: var(--texte-2); padding: 20px 16px 28px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head h1 { margin: 0; }
.page-head p { margin: 4px 0 0; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.grid-stats { grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.section-title { display: flex; align-items: center; gap: 10px; margin: 32px 0 12px; }
.section-title h2 { margin: 0; }
.section-title .compteur { background: var(--primaire-clair); color: var(--primaire); border-radius: 99px; font-size: .78rem; font-weight: 600; padding: 2px 10px; }

.card { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); box-shadow: var(--ombre); padding: 20px; }
.card-flat { box-shadow: none; }

/* --- Cartes de scrutin --------------------------------------------------- */
.scrutin-card { display: flex; flex-direction: column; gap: 10px; text-decoration: none; color: inherit; transition: border-color .15s, transform .15s; }
.scrutin-card:hover { border-color: var(--primaire); transform: translateY(-1px); }
.scrutin-card h3 { margin: 0; font-size: 1.05rem; }
.scrutin-card .meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: .85rem; color: var(--texte-2); }
.scrutin-card .pied { display: flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 8px; border-top: 1px dashed var(--bord); font-size: .87rem; }

.badge { display: inline-flex; align-items: center; gap: 6px; font-size: .75rem; font-weight: 600; padding: 3px 10px; border-radius: 99px; letter-spacing: .02em; white-space: nowrap; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge-ouvert { background: var(--primaire-clair); color: var(--primaire); }
.badge-a_venir { background: var(--bleu-clair); color: var(--bleu); }
.badge-clos { background: #eceeed; color: #5b6560; }
.badge-brouillon { background: var(--or-clair); color: #8a6a10; }
.badge-vote { background: var(--succes); color: #fff; }
.badge-vote::before { display: none; }
.type-tag { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--texte-2); }

.progress { height: 8px; background: #e8ecea; border-radius: 99px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--primaire); border-radius: 99px; }

/* --- Boutons et formulaires ------------------------------------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: inherit; font-weight: 600; font-size: .92rem; padding: 10px 18px; border-radius: 10px; border: 1px solid transparent; cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-primary { background: var(--primaire); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--primaire-fonce); }
.btn-secondary { background: #fff; color: var(--texte); border-color: var(--bord); }
.btn-secondary:hover:not(:disabled) { border-color: var(--primaire); color: var(--primaire); }
.btn-danger { background: #fff; color: var(--rouge); border-color: #efc4be; }
.btn-danger:hover:not(:disabled) { background: var(--rouge-clair); }
.btn-gold { background: var(--or); color: #2a2205; }
.btn-gold:hover:not(:disabled) { background: #b38d3d; }
.btn-sm { padding: 6px 12px; font-size: .82rem; border-radius: 8px; }
.btn-lg { padding: 14px 26px; font-size: 1rem; }
.btn-block { width: 100%; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label { font-weight: 600; font-size: .88rem; }
.field .aide { font-size: .8rem; color: var(--texte-2); }
input[type=text], input:not([type]), input[type=date], input[type=tel], input[type=password], input[type=email], input[type=number], input[type=datetime-local], input[type=url], input[type=search], select, textarea {
  font: inherit; font-size: .95rem; padding: 10px 12px; border: 1px solid var(--bord); border-radius: 10px; background: #fff; color: var(--texte); width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(2, 37, 79, .25); border-color: var(--primaire); }
textarea { min-height: 120px; resize: vertical; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; }

.alert { padding: 12px 16px; border-radius: 10px; font-size: .92rem; margin-bottom: 16px; border: 1px solid; }
.alert-error { background: var(--rouge-clair); border-color: #efc4be; color: #8e2a1f; }
.alert-info { background: var(--bleu-clair); border-color: #c6d7ee; color: #17487f; }
.alert-success { background: var(--succes-clair); border-color: #b7dcc6; color: #0f5132; }
.alert-warn { background: var(--or-clair); border-color: #ecd9a0; color: #6d540c; }

/* --- Connexion --------------------------------------------------------- */
.login-wrap { min-height: calc(100vh - 80px); display: grid; place-items: center; }
.login-card { width: 100%; max-width: 420px; padding: 32px; }
.login-logo { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 24px; }
.login-logo svg { width: 64px; height: 64px; margin-bottom: 12px; }
.login-logo rect { fill: var(--primaire); }
.login-logo path { stroke: var(--or); stroke-width: 3.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.login-logo h1 { font-size: 1.35rem; margin: 0; }
.login-logo p { margin: 4px 0 0; color: var(--texte-2); font-size: .9rem; }

/* --- Bulletin de vote ---------------------------------------------------- */
.bulletin { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.choix { display: flex; align-items: flex-start; gap: 14px; padding: 16px; border: 2px solid var(--bord); border-radius: 12px; background: #fff; cursor: pointer; transition: border-color .12s, background .12s; }
.choix:hover { border-color: #9fb0c6; }
.choix input { margin-top: 3px; width: 20px; height: 20px; accent-color: var(--primaire); flex-shrink: 0; }
.choix.selectionne { border-color: var(--primaire); background: var(--primaire-clair); }
.choix .libelle { font-weight: 600; font-size: 1.02rem; }
.choix .desc { font-size: .87rem; color: var(--texte-2); margin-top: 2px; white-space: pre-line; }
.choix-pour.selectionne { border-color: #138d4c; background: #e5f5ec; }
.choix-contre.selectionne { border-color: var(--rouge); background: var(--rouge-clair); }
.choix-abstention.selectionne { border-color: #8a958f; background: #f0f2f1; }
.choix.desactive { opacity: .5; cursor: not-allowed; }

.recu-box { text-align: center; padding: 28px 20px; }
.recu-code { font-family: Consolas, "Courier New", monospace; font-size: 1.5rem; font-weight: 700; letter-spacing: .08em; background: var(--fond); border: 1px dashed var(--primaire); border-radius: 10px; padding: 14px 18px; display: inline-block; margin: 12px 0; user-select: all; }
.check-big { width: 64px; height: 64px; border-radius: 50%; background: var(--succes-clair); color: var(--succes); display: grid; place-items: center; font-size: 2rem; margin: 0 auto 12px; }

.description { white-space: pre-line; }
.infos { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 16px 0; }
.info { background: var(--fond); border-radius: 10px; padding: 10px 14px; }
.info dt { font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--texte-2); font-weight: 600; }
.info dd { margin: 2px 0 0; font-weight: 600; }

/* --- Résultats --------------------------------------------------------- */
.resultat-ligne { margin-bottom: 14px; }
.resultat-ligne .entete { display: flex; justify-content: space-between; gap: 12px; font-size: .93rem; margin-bottom: 5px; }
.resultat-ligne .entete strong { font-weight: 600; }
.barre { height: 14px; background: #eceeed; border-radius: 6px; overflow: hidden; }
.barre > span { display: block; height: 100%; background: #7c8c84; border-radius: 6px; }
.barre .b-pour { background: #138d4c; }
.barre .b-contre { background: var(--rouge); }
.barre .b-abstention { background: #a3aea8; }
.barre .b-gagnant { background: var(--primaire); }
.barre .b-autre { background: #9fb0c6; }
.verdict { display: flex; gap: 12px; align-items: center; padding: 14px 18px; border-radius: 10px; font-weight: 600; margin-bottom: 18px; }
.verdict-adopte, .verdict-elus, .verdict-retenu { background: var(--succes-clair); color: #0f5132; }
.verdict-rejete { background: var(--rouge-clair); color: #8e2a1f; }
.verdict-quorum, .verdict-egalite, .verdict-aucun { background: var(--or-clair); color: #6d540c; }
.elu { font-size: .72rem; font-weight: 700; color: #fff; background: var(--primaire); padding: 1px 8px; border-radius: 99px; margin-left: 6px; }

/* --- Statistiques ------------------------------------------------------- */
.stat { padding: 18px 20px; }
.stat .valeur { font-size: 1.9rem; font-weight: 700; color: var(--primaire-fonce); line-height: 1.1; }
.stat .libelle { font-size: .82rem; color: var(--texte-2); margin-top: 4px; }

/* --- Tableaux ------------------------------------------------------------ */
.table-wrap { overflow-x: auto; border: 1px solid var(--bord); border-radius: var(--rayon); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--bord); vertical-align: middle; }
th { background: #f7f9f8; font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--texte-2); font-weight: 600; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fafcfb; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.inactif td { color: #9aa49f; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--bord); margin-bottom: 20px; overflow-x: auto; }
.tabs a { font-size: .92rem; text-decoration: none; border-bottom: 3px solid transparent; padding: 10px 14px; color: var(--texte-2); white-space: nowrap; }
.tabs a:hover { color: var(--primaire); }
.tabs a.actif { color: var(--primaire); border-bottom-color: var(--primaire); font-weight: 600; }

/* --- Éditeur d'options ---------------------------------------------------- */
.option-row { display: grid; grid-template-columns: 28px 1fr 1.4fr auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.option-row .num { font-weight: 700; color: var(--texte-2); text-align: center; }
@media (max-width: 640px) { .option-row { grid-template-columns: 1fr auto; } .option-row .num { display: none; } }

/* --- Modale et notifications ---------------------------------------- */
.modal { border: 0; border-radius: 16px; padding: 0; width: min(560px, calc(100vw - 32px)); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal::backdrop { background: rgba(10, 25, 18, .5); }
.modal-body { padding: 24px; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; padding: 16px 24px; background: var(--fond); border-top: 1px solid var(--bord); flex-wrap: wrap; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(120px); background: var(--texte); color: #fff; padding: 12px 20px; border-radius: 10px; font-size: .92rem; box-shadow: 0 8px 24px rgba(0,0,0,.2); transition: transform .25s; z-index: 100; max-width: calc(100vw - 32px); }
.toast.visible { transform: translateX(-50%) translateY(0); }
.toast.erreur { background: var(--rouge); }

.vide { text-align: center; padding: 36px 20px; color: var(--texte-2); }
.chargement { text-align: center; padding: 60px; color: var(--texte-2); }
pre.mdp { font-family: Consolas, monospace; background: var(--fond); padding: 12px; border-radius: 8px; max-height: 260px; overflow: auto; font-size: .85rem; }

/* --- Assistance informatique ------------------------------------------------- */
.badge-t-nouveau { background: var(--bleu-clair); color: var(--bleu); }
.badge-t-en_cours { background: var(--primaire-clair); color: var(--primaire); }
.badge-t-en_attente { background: var(--or-clair); color: #8a6a10; }
.badge-t-resolu { background: var(--succes); color: #fff; }
.badge-t-ferme { background: #eceeed; color: #5b6560; }
.prio { display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: 2px 8px; border-radius: 6px; white-space: nowrap; }
.prio-basse { background: #eceeed; color: #5b6560; }
.prio-normale { background: var(--bleu-clair); color: var(--bleu); }
.prio-haute { background: var(--or-clair); color: #8a6a10; }
.prio-urgente { background: var(--rouge); color: #fff; }
.sla { display: inline-block; font-size: .8rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; }
.sla-ok { color: var(--succes); background: var(--succes-clair); }
.sla-proche { color: #8a6a10; background: var(--or-clair); }
.sla-retard { color: #fff; background: var(--rouge); }
.sla-pause { color: var(--texte-2); background: #eceeed; }
.ok { color: var(--succes); font-weight: 700; }
.ko { color: var(--rouge); font-weight: 700; }

.ligne-lien { cursor: pointer; }
.ligne-nouveau td:first-child { box-shadow: inset 4px 0 0 var(--bleu); }
.pastille { display: inline-block; font-size: .72rem; font-weight: 600; background: var(--or); color: #2a2205; padding: 1px 8px; border-radius: 99px; margin-left: 4px; }
.stat-btn { text-align: left; font: inherit; cursor: pointer; transition: border-color .15s; }
.stat-btn:hover { border-color: var(--primaire); }
.stat-alerte { border-color: #efc4be; background: var(--rouge-clair); }
.stat-alerte .valeur { color: var(--rouge); }

.ticket-layout { display: grid; grid-template-columns: minmax(0, 1fr) clamp(300px, 24vw, 400px); gap: 20px; align-items: start; }
.ticket-layout aside h3 { margin-bottom: 10px; }
@media (max-width: 900px) { .ticket-layout { grid-template-columns: minmax(0, 1fr); } .ticket-layout aside { order: -1; } }
.infos-col { grid-template-columns: 1fr; gap: 8px; margin: 0 0 12px; }
.fil { display: flex; flex-direction: column; gap: 12px; }
.msg { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 14px 16px; }
.msg-agent { border-left: 4px solid var(--or); }
.msg-demandeur { border-left: 4px solid var(--bleu); }
.msg-note { background: var(--or-clair); border-color: #ecd9a0; border-left: 4px solid var(--or); }
.msg-tete { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.msg-role { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--texte-2); }
.msg-corps { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg-evenement { text-align: center; font-size: .8rem; color: var(--texte-2); }
.msg-evenement span { opacity: .8; }
.pieces { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pieces a { font-size: .85rem; background: var(--fond); border: 1px solid var(--bord); border-radius: 8px; padding: 4px 10px; text-decoration: none; }
.bandeau-action { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; border-color: var(--or); background: var(--or-clair); }

.segments { display: inline-flex; border: 1px solid var(--bord); border-radius: 10px; overflow: hidden; margin-bottom: 12px; }
.segments label { cursor: pointer; }
.segments input { position: absolute; opacity: 0; pointer-events: none; }
.segments span { display: block; padding: 8px 14px; font-size: .88rem; font-weight: 600; color: var(--texte-2); }
.segments input:checked + span { background: var(--primaire); color: #fff; }
.segments input:focus-visible + span { outline: 2px solid var(--or); }
.mode-note { background: var(--or-clair); border-color: #ecd9a0; }
.mode-note .segments input:checked + span { background: var(--or); color: #2a2205; }

.choix-prio { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); gap: 8px; }
.choix-prio .choix { padding: 12px; }
.choix-prio .desc { font-size: .8rem; }
.etoiles { display: flex; gap: 4px; }
.etoiles input { position: absolute; opacity: 0; }
.etoiles span { font-size: 2rem; color: #cfd6d2; cursor: pointer; line-height: 1; }
.etoiles label.on span, .etoiles label:hover span { color: var(--or); }
.etoiles input:focus-visible + span { outline: 2px solid var(--primaire); border-radius: 4px; }
.etoiles-fixes { color: var(--or); font-size: 1.1rem; }

.encart-support { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; text-decoration: none; color: inherit; border-left: 4px solid var(--or); margin-bottom: 8px; }
a.encart-support:hover { border-color: var(--primaire); }
.encart-icone { width: 44px; height: 44px; border-radius: 10px; background: var(--primaire-clair); display: grid; place-items: center; font-size: 1.3rem; flex-shrink: 0; }
.aide-connexion { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--bord); text-align: center; }
.public-wrap { max-width: 760px; margin: 0 auto; }
.public-wrap .login-logo { margin-top: 12px; }
.public-entete { background: var(--primaire-fonce); color: #fff; padding: 12px 18px; border-radius: var(--rayon); margin-bottom: 16px; }
.piege { position: absolute; left: -10000px; width: 1px; height: 1px; opacity: 0; }

/* --- Kit d'illustrations OECCA (public/assets) ------------------------------- */
.illus { display: block; height: auto; max-width: 100%; }
.ic { width: 1.25em; height: 1.25em; flex-shrink: 0; color: var(--primaire); vertical-align: -.25em; }
.btn .ic { color: currentColor; }
.cat { display: inline-flex; align-items: center; gap: 6px; }
.cat .ic { width: 1.1em; height: 1.1em; }
.type-tag .cat .ic { width: 1.3em; height: 1.3em; }

.hero { display: flex; align-items: center; gap: 24px; padding: 24px 28px; margin-bottom: 20px; border-top: 4px solid var(--or); overflow: hidden; }
.hero-texte { flex: 1; min-width: 0; }
.hero h1 { margin: 6px 0 8px; color: var(--primaire); }
.illus-hero { width: 240px; flex-shrink: 0; }
@media (max-width: 700px) { .hero { flex-direction: column-reverse; text-align: center; } .illus-hero { width: 180px; } }

.page-head-illus { align-items: center; justify-content: flex-start; }
.illus-entete { width: 120px; }
@media (max-width: 640px) { .illus-entete { display: none; } }

.public-hero { text-align: center; margin: 8px 0 20px; }
.illus-bandeau { width: 100%; max-width: 560px; margin: 0 auto 8px; }
.public-hero h1 { color: var(--primaire); margin: 0; }
.public-hero p { margin: 4px 0 0; }

.champ-cat { border: 0; padding: 0; margin: 0 0 16px; min-width: 0; }
.champ-cat legend { font-weight: 600; font-size: .88rem; padding: 0; margin-bottom: 8px; }
.choix-cat { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 8px; }
.tuile { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 14px 8px; border: 2px solid var(--bord); border-radius: 12px; background: #fff; cursor: pointer; font-size: .85rem; font-weight: 600; transition: border-color .12s, background .12s; }
.tuile:hover { border-color: #9fb0c6; }
.tuile input { position: absolute; opacity: 0; pointer-events: none; }
.tuile .ic { width: 30px; height: 30px; }
.tuile:has(input:checked) { border-color: var(--primaire); background: var(--primaire-clair); }
.tuile:has(input:focus-visible) { outline: 2px solid var(--or); outline-offset: 2px; }

.illus-chargement { width: 110px; margin: 0 auto 8px; }
.illus-cadenas { width: 90px; margin: 0 auto 12px; }
.illus-succes { width: 170px; margin: 0 auto 8px; }
.illus-mini { width: 64px; }
.illus-suivi { width: 100%; max-width: 280px; margin: 0 auto 12px; }
.illus-vide { width: 150px; margin: 0 auto 8px; }
.illus-vide-large { width: 100%; max-width: 320px; margin: 0 auto 8px; }
.illus-envoi { width: 70px; }
.envoi { display: flex; align-items: center; gap: 12px; padding: 8px 12px; background: var(--primaire-clair); border-radius: 10px; margin-bottom: 16px; font-weight: 600; color: var(--primaire); }
.page-erreur { text-align: center; padding: clamp(24px, 5vw, 64px) 20px; }
.illus-erreur { width: 100%; max-width: 320px; margin: 0 auto 12px; }
.encart-icone .ic { width: 26px; height: 26px; }

/* --- Pages publiques ------------------------------------------------------------ */
.nav .nav-connexion { background: var(--or); color: #2a2205; font-weight: 600; margin-left: 6px; }
.nav .nav-connexion:hover, .nav .nav-connexion.actif { background: #b38d3d; color: #2a2205; }
.footer-liens { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin-bottom: 10px; }
.footer-liens a { color: var(--primaire); text-decoration: none; font-weight: 600; }
.footer-liens a:hover { text-decoration: underline; }

.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.accueil-hero { display: flex; align-items: center; gap: 28px; background: var(--primaire); color: #fff; border-radius: var(--rayon); padding: 32px; margin-bottom: 24px; overflow: hidden; border-bottom: 4px solid var(--or); }
.accueil-hero .type-tag { color: var(--or); }
.accueil-hero h1 { font-size: 2rem; margin: 8px 0 12px; }
.accueil-hero p { color: rgba(255,255,255,.85); font-size: 1.05rem; max-width: 560px; }
.accueil-texte { flex: 1; min-width: 0; }
.accueil-illus { width: 44%; max-width: 440px; flex-shrink: 0; background: #fff; border-radius: 12px; padding: 8px; }
.accueil-hero .btn-secondary { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.accueil-hero .btn-secondary:hover { border-color: #fff; color: #fff; }
@media (max-width: 760px) { .accueil-hero { flex-direction: column; padding: 24px 20px; } .accueil-illus { width: 100%; } .accueil-hero h1 { font-size: 1.5rem; } }

.carte-lien { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: inherit; transition: border-color .15s, transform .15s; }
.carte-lien:hover { border-color: var(--or); transform: translateY(-1px); }
.carte-lien h3 { margin: 6px 0 0; color: var(--primaire); }
.carte-lien p { margin: 0 0 6px; flex: 1; }
.carte-lien strong { color: var(--primaire); font-size: .9rem; }
.ic-grand { width: 40px; height: 40px; }

.liste-articles { list-style: none; padding: 0; margin: 0 0 12px; }
.liste-articles li { border-bottom: 1px solid var(--bord); }
.liste-articles li:last-child { border-bottom: 0; }
.liste-articles a { display: flex; align-items: center; gap: 10px; padding: 10px 2px; text-decoration: none; color: var(--texte); font-weight: 500; }
.liste-articles a:hover { color: var(--primaire); }
.liste-points { padding-left: 20px; margin: 0 0 16px; }
.liste-points li { margin-bottom: 6px; }
.liste-points li::marker { color: var(--or); }

.recherche-aide { padding: 14px; margin-bottom: 8px; }
.recherche-aide input { font-size: 1.05rem; padding: 14px 16px; }
.theme-aide { margin-top: 24px; }
.theme-aide h2 { display: flex; align-items: center; gap: 10px; color: var(--primaire); }
.theme-aide .liste-articles { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 0 16px; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) clamp(260px, 22vw, 360px); gap: 20px; align-items: start; }
@media (max-width: 900px) { .article-layout { grid-template-columns: minmax(0, 1fr); } }
.article-aide { padding: 28px 32px; }
.article-aide h1 { color: var(--primaire); margin: 8px 0 16px; }
.article-aide .type-tag { display: inline-flex; align-items: center; gap: 6px; }
.article-corps { font-size: 1rem; }
.article-corps li { margin-bottom: 8px; }
.article-pied { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--bord); }
.texte-legal p, .texte-legal li { max-width: 90ch; }
.sommaire { position: sticky; top: 90px; }
.sommaire .btn { margin-top: 8px; }
.texte-legal h2 { margin-top: 24px; color: var(--primaire); }
@media (max-width: 640px) { .article-aide { padding: 20px 16px; } }

.public-etroit { max-width: 520px; margin: 20px auto 0; }
.public-etroit h1 { color: var(--primaire); }
.contacts { list-style: none; padding: 0; margin: 0 0 16px; }
.contacts li { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.etapes { list-style: none; counter-reset: etape; padding: 0; margin: 0; display: grid; gap: 12px; }
.etapes li { counter-increment: etape; position: relative; background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 14px 16px 14px 64px; display: flex; flex-direction: column; }
.etapes li::before { content: counter(etape); position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border-radius: 50%; background: var(--primaire); color: var(--or); display: grid; place-items: center; font-weight: 700; }
.etapes span { color: var(--texte-2); font-size: .9rem; }

/* --- Administration centrale, annonces, état des services ------------------------ */
.stat-lien { text-decoration: none; color: inherit; transition: border-color .15s; }
.stat-lien:hover { border-color: var(--or); }
.stat-lien .ic { width: 24px; height: 24px; margin-bottom: 6px; }
.compteur-alerte { background: var(--or-clair) !important; color: #8a6a10 !important; }
.pastille-etat { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; padding: 3px 10px; border-radius: 99px; white-space: nowrap; }
.pastille-etat::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.etat-ok { background: var(--succes-clair); color: var(--succes); }
.etat-alerte { background: var(--or-clair); color: #8a6a10; }
.etat-erreur { background: var(--rouge-clair); color: var(--rouge); }
.controles td { vertical-align: top; }
.case { display: flex; align-items: flex-start; gap: 10px; margin: 6px 0; cursor: pointer; }
.case input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--primaire); flex-shrink: 0; }

.annonce { border-left: 5px solid var(--bleu); }
.annonce-incident { border-left-color: var(--rouge); }
.annonce-maintenance { border-left-color: var(--or); }
.bandeau-etat { color: #fff; font-size: .9rem; }
.bandeau-inner { max-width: var(--largeur-max); margin: 0 auto; padding: 10px var(--marge); }
.bandeau-etat a { color: inherit; font-weight: 600; margin-left: 8px; }
.bandeau-incident { background: var(--rouge); }
.bandeau-maintenance { background: var(--or); color: #2a2205; }
.bandeau-info { background: var(--bleu); }

/* --- Mises en page pleine largeur ------------------------------------------------ */
/* Deux zones : panneau de présentation + formulaire (connexion, retrouver ma demande) */
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(min(100%, 380px), .85fr); gap: clamp(20px, 3vw, 48px); min-height: calc(100vh - 230px); }
.split-panneau { background: var(--primaire); color: #fff; border-radius: var(--rayon); padding: clamp(24px, 4vw, 64px); display: flex; flex-direction: column; justify-content: center; gap: 16px; border-bottom: 4px solid var(--or); }
.split-panneau .type-tag { color: var(--or); }
.split-panneau h1 { font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.8rem); margin: 0; }
.split-panneau p { color: rgba(255,255,255,.85); font-size: 1.05rem; margin: 0; max-width: 62ch; }
.split-panneau .liste-points { margin: 0; }
.split-panneau .liste-points li { color: rgba(255,255,255,.9); }
.split-panneau .btn-secondary { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.split-panneau .btn-secondary:hover { border-color: #fff; color: #fff; }
.split-illus { width: 100%; max-width: 620px; background: #fff; border-radius: 12px; padding: 8px; }
.split-formulaire { align-self: center; width: 100%; padding: clamp(24px, 3vw, 44px); }
.split-formulaire .login-logo h2 { margin: 0; }
@media (max-width: 900px) {
  .split { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .split-formulaire { order: -1; }          /* sur téléphone, le formulaire d'abord */
  .split-illus { display: none; }
}

/* Formulaire + panneau latéral (nouvelle demande, contacter l'assistance) */
.form-layout { display: grid; grid-template-columns: minmax(0, 1fr) clamp(280px, 26vw, 420px); gap: 20px; align-items: start; }
.form-aside { position: sticky; top: 90px; }
.form-aside h3 { display: flex; align-items: center; gap: 8px; }
.illus-aside { width: 100%; background: #fff; border: 1px solid var(--bord); border-radius: var(--rayon); padding: 8px; }
@media (max-width: 980px) { .form-layout { grid-template-columns: minmax(0, 1fr); } .form-aside { position: static; } .illus-aside { display: none; } }

.infos-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }
.info-ligne { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.info-ligne dd { margin: 0; }
.grille-themes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); gap: 0 24px; align-items: start; }
.grille-themes > .card { grid-column: 1 / -1; }

/* --- Page « Contacter l'assistance » ---------------------------------------------- */
.aide-hero { display: flex; align-items: center; gap: clamp(20px, 4vw, 56px); background: var(--primaire); color: #fff;
  border-radius: var(--rayon); padding: clamp(24px, 4vw, 56px); margin-bottom: 24px; border-bottom: 4px solid var(--or); overflow: hidden;
  background-image: radial-gradient(circle at 85% 20%, rgba(199,161,79,.18), transparent 45%); }
.aide-hero-texte { flex: 1; min-width: 0; }
.aide-hero .type-tag { color: var(--or); }
.aide-hero h1 { font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.7rem); margin: 8px 0 12px; }
.aide-hero p { color: rgba(255,255,255,.86); font-size: 1.05rem; max-width: 62ch; margin: 0 0 22px; }
.aide-hero-illus { width: clamp(180px, 22vw, 300px); flex-shrink: 0; background: #fff; border-radius: 16px; padding: 10px; }
.aide-garanties { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px; }
.aide-garanties li { display: flex; gap: 12px; align-items: flex-start; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-radius: 12px; padding: 12px 14px; }
.aide-garanties .ic { color: var(--or); width: 26px; height: 26px; margin-top: 2px; }
.aide-garanties strong { display: block; }
.aide-garanties span { font-size: .84rem; color: rgba(255,255,255,.75); }
@media (max-width: 760px) { .aide-hero { flex-direction: column-reverse; align-items: stretch; } .aide-hero-illus { width: 150px; align-self: center; } }

.etape-form { padding: clamp(18px, 2.4vw, 28px); }
.etape-tete { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--bord); }
.etape-tete h2 { margin: 0; color: var(--primaire); }
.etape-tete p { margin: 2px 0 0; }
.etape-num { width: 36px; height: 36px; flex-shrink: 0; border-radius: 50%; background: var(--primaire); color: var(--or); display: grid; place-items: center; font-weight: 700; font-size: 1.05rem; }
.etape-form .champ-cat legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.suggestions { margin-top: 4px; padding: 14px 16px; background: var(--or-clair); border: 1px solid #e6d3a6; border-radius: 10px; }
.suggestions strong { display: flex; align-items: center; gap: 8px; color: #6d540c; }
.suggestions ul { margin: 8px 0 6px; padding-left: 20px; }
.suggestions li { margin: 4px 0; }
.suggestions a { font-weight: 600; }

/* --- Adaptation aux écrans --------------------------------------------------------- */
/* Tablettes et téléphones */
@media (max-width: 700px) {
  .container { padding-top: 18px; }
  .card { padding: 16px; }
  .page-head { align-items: stretch; }
  .page-head > .btn, .page-head > .row, .page-head > select { width: 100%; }
  .page-head > .row .btn { flex: 1; }
  .section-title { margin-top: 24px; }
  .modal-body { padding: 18px; }
  .modal-actions { padding: 12px 18px; }
  .modal-actions .btn { flex: 1; }
  .segments { display: flex; flex-wrap: wrap; }
  .segments label { flex: 1; text-align: center; }
  .hero { padding: 20px; }
  .bandeau-action .btn { flex: 1; }
  .accueil-hero .row .btn { flex: 1; }
  /* Évite le zoom automatique de Safari sur iPhone lors de la saisie */
  input[type=text], input:not([type]), input[type=date], input[type=email], input[type=number], input[type=search], input[type=url], input[type=datetime-local], select, textarea { font-size: 16px; }

  /* Tableaux → fiches empilées : chaque ligne devient une carte, chaque cellule affiche l'intitulé de sa colonne */
  .table-wrap { overflow: visible; border: 0; background: transparent; }
  table.tableau-fiches thead { display: none; }
  table.tableau-fiches, table.tableau-fiches tbody, table.tableau-fiches tr { display: block; width: 100%; }
  table.tableau-fiches tr { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 8px 14px; margin-bottom: 10px; }
  table.tableau-fiches td { display: grid; grid-template-columns: minmax(90px, 36%) 1fr; gap: 10px; align-items: center; border: 0; padding: 6px 0; text-align: left !important; white-space: normal; }
  table.tableau-fiches td::before { content: attr(data-label); font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--texte-2); }
  table.tableau-fiches td:not([data-label]) { display: block; }
  table.tableau-fiches td:not([data-label])::before { display: none; }
  table.tableau-fiches td + td { border-top: 1px dashed var(--bord); }
  .ligne-nouveau td:first-child { box-shadow: none; }
  .ligne-nouveau { border-left: 4px solid var(--bleu) !important; }
}
/* Petits téléphones */
@media (max-width: 420px) {
  .brand-text small { display: none; }
  .btn { padding: 10px 14px; }
  .btn-lg { padding: 12px 18px; }
  .stat .valeur { font-size: 1.6rem; }
}
/* Très grands écrans : un peu plus d'air */
@media (min-width: 1600px) {
  .grid { gap: 20px; }
  .card { padding: 24px; }
}

/* --- Procès-verbal --------------------------------------------------------- */
.pv { background: #fff; max-width: 820px; margin: 0 auto; padding: 48px 56px; border: 1px solid var(--bord); font-family: Georgia, "Times New Roman", serif; color: #111; }
.pv-entete { text-align: center; border-bottom: 2px solid var(--primaire); padding-bottom: 16px; margin-bottom: 24px; }
.pv-entete .republique { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; }
.pv-entete h1 { font-size: 1.15rem; margin: 8px 0 4px; }
.pv h2 { font-size: 1.25rem; text-align: center; text-transform: uppercase; letter-spacing: .05em; margin: 20px 0; }
.pv table { font-size: .95rem; }
.pv th { background: #f2f4f3; color: #111; }
.pv .signatures { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 56px; text-align: center; }
.pv .signatures div { border-top: 1px solid #555; padding-top: 8px; font-size: .9rem; }
@media (max-width: 640px) { .pv { padding: 24px 16px; } }

@media print {
  .topbar, .flag-band, .footer, .no-print, .toast { display: none !important; }
  body { background: #fff; }
  .container { padding: 0; max-width: none; }
  .pv { border: 0; padding: 0; }
}

/* --- Garde-fous de largeur et champ « pièces jointes » ----------------------------- */
html, body { overflow-x: clip; }                   /* aucune page ne doit défiler de côté */
.form-layout > *, .split > *, .ticket-layout > *, .article-layout > *, .grid > * { min-width: 0; }
.card, .field, .field input, .field textarea, .field select { max-width: 100%; }
input[type=file] { font: inherit; font-size: .88rem; width: 100%; padding: 10px; border: 2px dashed var(--bord); border-radius: 10px; background: var(--fond); color: var(--texte-2); cursor: pointer; }
input[type=file]:hover { border-color: var(--primaire); }
input[type=file]::file-selector-button { font: inherit; font-weight: 600; margin-right: 12px; padding: 8px 14px; border: 0; border-radius: 8px; background: var(--primaire); color: #fff; cursor: pointer; }
@media (max-width: 700px) { input[type=tel] { font-size: 16px; } }

/* --- Logo du site : le technicien de l'assistance ----------------------------------- */
.logo-bonhomme { display: block; border-radius: 22%; }
.brand-mark .logo-bonhomme { width: 40px; height: 40px; box-shadow: 0 0 0 1px rgba(255,255,255,.25); }
.login-logo .logo-bonhomme { width: 76px; height: 76px; margin-bottom: 12px; box-shadow: 0 4px 14px rgba(2,37,79,.2); }

/* --- Configuration et compte administrateur ---------------------------------------- */
.pastille-source { font-size: .68rem; font-weight: 700; padding: 1px 8px; border-radius: 99px; margin-left: 6px; background: #eceeed; color: #5b6560; vertical-align: 1px; }
.titre-icone { display: flex; align-items: center; gap: 10px; color: var(--primaire); }
.grille-config { align-items: start; }
.test-email { margin-top: 8px; padding-top: 16px; border-top: 1px dashed var(--bord); }
.barre-enregistrer { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 12px 16px; box-shadow: 0 -4px 16px rgba(2,37,79,.08); }
.form-compte { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--bord); }

/* --- Chiffres clés de l'Ordre (accueil) --------------------------------------------- */
.chiffres-cles { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; background: var(--carte); border: 1px solid var(--bord); border-left: 5px solid var(--or); border-radius: var(--rayon); padding: 16px 22px; margin-bottom: 20px; }
.chiffres-cles > div { display: flex; align-items: baseline; gap: 8px; }
.chiffres-cles strong { font-size: 1.8rem; color: var(--primaire); }
.chiffres-cles span { color: var(--texte-2); }
.chiffres-cles .chiffres-source { margin-left: auto; font-size: .78rem; color: var(--texte-2); }
.btn-gold .ic, .btn-primary .ic { --oecca-accent: currentColor; }
.article-corps h3 { margin: 18px 0 6px; color: var(--primaire); }
kbd { font-family: Consolas, monospace; font-size: .82em; background: var(--fond); border: 1px solid var(--bord); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; white-space: nowrap; }
.apercu-email { width: 100%; height: 900px; border: 1px solid var(--bord); border-radius: var(--rayon); background: #eef1f5; }

/* =====================================================================================
   Espace connecté : barre latérale (sidebar) + tableau de bord
   ===================================================================================== */
:root { --haut-topbar: 60px; --largeur-sidebar: 268px; }
.coque { display: block; flex: 1; }
.coque-contenu { min-width: 0; display: flex; flex-direction: column; min-height: calc(100vh - var(--haut-topbar)); }
.coque-contenu > .container { flex: 1; }
body.avec-sidebar .coque { display: grid; grid-template-columns: var(--largeur-sidebar) minmax(0, 1fr); }
body.avec-sidebar .container { max-width: 1680px; }

.sidebar { position: sticky; top: var(--haut-topbar); align-self: start; height: calc(100vh - var(--haut-topbar)); overflow-y: auto;
  background: var(--carte); border-right: 1px solid var(--bord); padding: 14px 12px; display: flex; flex-direction: column; gap: 2px; z-index: 8; }
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-titre { font-size: .68rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--texte-2); padding: 16px 12px 6px; }
.sidebar a, .sidebar-sortie { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; color: var(--texte);
  text-decoration: none; font: inherit; font-size: .92rem; font-weight: 500; background: none; border: 0; cursor: pointer; text-align: left; width: 100%; transition: background .12s, color .12s; }
.sidebar a:hover, .sidebar-sortie:hover { background: var(--fond); color: var(--primaire); }
.sidebar a.actif { background: var(--primaire-clair); color: var(--primaire); font-weight: 700; box-shadow: inset 4px 0 0 var(--or); }
.sidebar .ic { width: 20px; height: 20px; color: var(--primaire); flex-shrink: 0; }
.sidebar-pied { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--bord); display: flex; flex-direction: column; gap: 2px; }
.sidebar-profil { padding: 8px 10px !important; }
.sidebar-profil-texte { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.sidebar-profil-texte strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--primaire); }
.sidebar-profil-texte small { color: var(--texte-2); font-size: .76rem; }
.sidebar-sortie { color: var(--rouge); }
.sidebar-sortie .ic { color: var(--rouge); }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--primaire); color: var(--or); display: grid; place-items: center; font-weight: 700; font-size: .9rem; flex-shrink: 0; letter-spacing: .02em; }
.avatar-petit { width: 32px; height: 32px; font-size: .78rem; background: var(--or); color: var(--primaire); }

/* Barre du haut quand on est connecté : menu utilisateur compact, toujours visible */
body.avec-sidebar .topbar-inner { max-width: none; }
body.avec-sidebar .menu-toggle { display: none; }
body.avec-sidebar .nav { display: flex !important; position: static; flex-direction: row; align-items: center; background: none; padding: 0; gap: 6px; }
body.avec-sidebar .nav a, body.avec-sidebar .nav button { display: inline-flex; align-items: center; gap: 8px; }
body.avec-sidebar .nav .ic { width: 18px; height: 18px; color: #fff; }
.nav-aide { border: 1px solid rgba(255,255,255,.3); }
.nav-utilisateur { padding: 4px 10px 4px 4px !important; }
.voile { display: none; }

@media (max-width: 1024px) {
  body.avec-sidebar .coque { grid-template-columns: minmax(0, 1fr); }
  body.avec-sidebar .menu-toggle { display: block; order: -1; margin-right: 4px; }
  .sidebar { position: fixed; top: 0; left: 0; bottom: 0; height: 100vh; width: min(300px, 86vw); z-index: 60;
    transform: translateX(-105%); transition: transform .22s ease; box-shadow: 8px 0 30px rgba(2,37,79,.25); padding-top: 20px; }
  .sidebar.ouverte { transform: none; }
  .voile.visible { display: block; position: fixed; inset: 0; background: rgba(2,20,40,.45); z-index: 55; }
}
@media (max-width: 700px) {
  body.avec-sidebar .nav .nav-nom, .nav-aide span { display: none; }
  body.avec-sidebar .brand-text small { display: none; }
}

/* Tableau de bord */
.db-hero { display: flex; align-items: center; gap: clamp(16px, 3vw, 40px); background: var(--primaire); color: #fff; border-radius: var(--rayon);
  padding: clamp(22px, 3vw, 40px) clamp(22px, 3.5vw, 48px); margin-bottom: 20px; border-bottom: 4px solid var(--or); overflow: hidden;
  background-image: radial-gradient(circle at 88% 15%, rgba(199,161,79,.2), transparent 45%); }
.db-hero-texte { flex: 1; min-width: 0; }
.db-hero .type-tag { color: var(--or); }
.db-hero h1 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); margin: 6px 0 8px; }
.db-hero p { color: rgba(255,255,255,.88); font-size: 1.05rem; margin: 0 0 18px; max-width: 70ch; }
.db-hero p strong { color: var(--or); }
.db-hero .btn .ic { width: 18px; height: 18px; }
.btn-clair { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-clair:hover { border-color: #fff; }
.btn-clair .ic { color: #fff; }
.db-hero-illus { width: clamp(130px, 14vw, 200px); flex-shrink: 0; background: #fff; border-radius: 16px; padding: 8px; }
@media (max-width: 700px) { .db-hero-illus { display: none; } .db-hero .btn { flex: 1; } }

.db-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 14px; margin-bottom: 20px; }
.db-kpi { display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit; padding: 18px; transition: border-color .15s, transform .15s; }
.db-kpi:hover { border-color: var(--or); transform: translateY(-1px); }
.db-kpi-icone { width: 46px; height: 46px; border-radius: 12px; background: var(--primaire-clair); display: grid; place-items: center; flex-shrink: 0; }
.db-kpi-icone .ic { width: 24px; height: 24px; color: var(--primaire); }
.db-kpi-valeur { display: block; font-size: 1.9rem; font-weight: 700; line-height: 1; color: var(--primaire); }
.db-kpi-libelle { display: block; font-size: .84rem; color: var(--texte-2); margin-top: 4px; }
.db-kpi-alerte { border-color: #e6d3a6; background: var(--or-clair); }
.db-kpi-alerte .db-kpi-icone { background: var(--or); }
.db-kpi-alerte .db-kpi-icone .ic { color: var(--primaire); }

.db-colonnes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; align-items: start; }
.db-bloc { padding: 18px 18px 10px; }
.db-bloc-tete { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.db-bloc-tete h2 { margin: 0; color: var(--primaire); }
.db-bloc-tete a { font-size: .86rem; font-weight: 600; text-decoration: none; }
.db-ligne { display: flex; align-items: center; gap: 12px; padding: 12px 8px; border-top: 1px solid var(--bord); text-decoration: none; color: inherit; border-radius: 8px; }
.db-ligne:hover { background: var(--fond); }
.db-ligne-icone { width: 36px; height: 36px; border-radius: 10px; background: var(--primaire-clair); display: grid; place-items: center; flex-shrink: 0; }
.db-ligne-icone .ic { width: 19px; height: 19px; }
.db-ligne-texte { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.db-ligne-texte strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.db-ligne-texte small { color: var(--texte-2); font-size: .8rem; }
.db-vide { padding: 18px 10px 14px; }
.db-vide p { margin: 0 0 10px; }
body.avec-sidebar nav.tabs { display: none; }   /* la barre latérale remplace les onglets */

/* --- Résultats des scrutins : graphiques ------------------------------------------- */
.resultats .verdict { font-size: 1.02rem; }
.verdict-icone { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.verdict .verdict-icone { background: rgba(255,255,255,.7); font-weight: 800; }
.chiffres-res { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); gap: 10px; margin: 4px 0 8px; }
.chiffres-res > div { background: var(--fond); border-radius: 10px; padding: 12px 14px; }
.chiffre-valeur { display: block; font-size: 1.6rem; font-weight: 700; color: var(--primaire); line-height: 1.1; font-variant-numeric: tabular-nums; }
.chiffre-libelle { display: block; font-size: .78rem; color: var(--texte-2); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; margin-top: 2px; }
.res-titre { margin: 24px 0 10px; font-size: .95rem; color: var(--texte); }
/* Barre segmentée : 2 px d'écart entre segments, extrémités arrondies */
.segments-res { display: flex; gap: 2px; height: 44px; }
.segment-res { min-width: 4px; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: .88rem; cursor: default; }
.segment-res:first-child { border-radius: 8px 0 0 8px; }
.segment-res:last-child { border-radius: 0 8px 8px 0; }
.segment-res:only-child { border-radius: 8px; }
.segment-res span { text-shadow: 0 1px 2px rgba(0,0,0,.25); }
.legende-res { list-style: none; padding: 0; margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: .9rem; }
.legende-res i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 7px; vertical-align: -1px; }
/* Jauge avec seuil (majorité, quorum) */
.jauge-res { position: relative; height: 18px; background: #e8ecef; border-radius: 9px; margin-top: 26px; }
.jauge-rempli { height: 100%; border-radius: 9px; min-width: 2px; }
.jauge-seuil { position: absolute; top: -8px; bottom: -8px; width: 0; border-left: 2px dashed var(--texte); }
.jauge-seuil span { position: absolute; bottom: 100%; left: 0; transform: translateX(-50%); white-space: nowrap; font-size: .74rem; font-weight: 700; color: var(--texte); background: var(--carte); padding: 0 4px; margin-bottom: 2px; }
/* Barres classées (élections, options) */
.barres-res { display: flex; flex-direction: column; gap: 10px; }
.barre-res { display: grid; grid-template-columns: minmax(140px, 1.1fr) 2fr auto; align-items: center; gap: 12px; }
.barre-res-nom { font-weight: 600; display: flex; align-items: center; gap: 8px; min-width: 0; }
.barre-res-nom .rang { width: 22px; height: 22px; border-radius: 50%; background: var(--fond); color: var(--texte-2); display: grid; place-items: center; font-size: .74rem; font-weight: 700; flex-shrink: 0; }
.barre-retenue .rang { background: var(--primaire); color: var(--or); }
.barre-res-piste { height: 16px; }
.barre-res-rempli { height: 100%; border-radius: 0 6px 6px 0; }
.barre-res-valeur { font-size: .88rem; color: var(--texte-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.barre-res-valeur strong { color: var(--texte); }
@media (max-width: 640px) { .barre-res { grid-template-columns: 1fr auto; } .barre-res-piste { grid-column: 1 / -1; order: 3; } }
.tableau-res { margin-top: 22px; }
.tableau-res summary { cursor: pointer; font-weight: 600; color: var(--primaire); }
/* Infobulle */
.infobulle { position: fixed; z-index: 200; pointer-events: none; background: var(--primaire-fonce); color: #fff; font-size: .82rem; padding: 6px 10px; border-radius: 8px; box-shadow: 0 6px 18px rgba(0,0,0,.2); opacity: 0; transition: opacity .1s; max-width: 280px; }
.infobulle.visible { opacity: 1; }
@media print { .infobulle, .tableau-res summary { display: none; } .tableau-res { display: block; } }

/* --- Accueil des membres : « À faire maintenant » et deux grandes portes ------------- */
.a-faire { margin-bottom: 20px; padding: 18px 18px 8px; border-left: 4px solid var(--or); }
.a-faire h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; color: var(--primaire); }
.a-faire h2 .ic { width: 20px; height: 20px; }
.a-faire .compteur { background: var(--or); color: var(--primaire); border-radius: 99px; font-size: .78rem; font-weight: 700; padding: 2px 10px; }
.a-faire ul { list-style: none; margin: 0; padding: 0; }
.a-faire-item { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-top: 1px solid var(--bord); }
.a-faire-item:first-child { border-top: 0; }
.a-faire-icone { width: 38px; height: 38px; border-radius: 10px; background: var(--primaire-clair); display: grid; place-items: center; flex-shrink: 0; }
.a-faire-icone .ic { width: 20px; height: 20px; }
.a-faire-urgent .a-faire-icone { background: var(--or-clair); }
.a-faire-texte { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.a-faire-texte strong { overflow-wrap: anywhere; }
.a-faire-texte small { color: var(--texte-2); font-size: .82rem; }
.a-faire-item .btn { flex-shrink: 0; }
@media (max-width: 560px) {
  .a-faire-item { flex-wrap: wrap; }
  .a-faire-item .btn { width: 100%; justify-content: center; }
}

.portes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 16px; margin-bottom: 24px; }
.porte { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: clamp(20px, 2.5vw, 30px);
  background: var(--carte); border: 2px solid var(--bord); border-radius: var(--rayon); box-shadow: var(--ombre);
  text-decoration: none; color: inherit; transition: border-color .15s, transform .15s, box-shadow .15s; }
.porte:hover, .porte:focus-visible { border-color: var(--or); transform: translateY(-2px); }
.porte-icone { width: 60px; height: 60px; border-radius: 16px; background: var(--primaire); display: grid; place-items: center; }
.porte-icone .ic { width: 32px; height: 32px; color: #fff; }
.porte-titre { font-size: clamp(1.25rem, 1.05rem + .6vw, 1.55rem); font-weight: 700; color: var(--primaire); line-height: 1.25; }
.porte-texte { color: var(--texte-2); font-size: 1rem; flex: 1; }
.porte-texte strong { color: var(--primaire); }
.porte .btn { margin-top: 4px; }
@media (prefers-reduced-motion: reduce) { .porte, .porte:hover { transition: none; transform: none; } }

/* --- Vote : étapes numérotées ------------------------------------------------------- */
.etapes-vote { list-style: none; display: flex; gap: 6px; margin: 0 0 16px; padding: 0; counter-reset: none; }
.etapes-vote li { flex: 1; display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 10px;
  background: var(--carte); border: 1px solid var(--bord); color: var(--texte-2); font-size: .9rem; font-weight: 600; min-width: 0; }
.etape-pastille { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0;
  background: var(--fond); border: 1px solid var(--bord); font-size: .82rem; }
.etapes-vote li.courante { border-color: var(--primaire); color: var(--primaire); background: var(--primaire-clair); }
.etapes-vote li.courante .etape-pastille { background: var(--primaire); border-color: var(--primaire); color: var(--or); }
.etapes-vote li.faite { color: var(--primaire); }
.etapes-vote li.faite .etape-pastille { background: var(--or); border-color: var(--or); color: var(--primaire); }
@media (max-width: 600px) {
  .etapes-vote li { flex-direction: column; gap: 4px; padding: 8px 4px; font-size: .74rem; text-align: center; }
}

/* --- Présentation publique d'un scrutin (projection en assemblée) ------------------- */
body.mode-presentation #topbar, body.mode-presentation #sidebar, body.mode-presentation #footer,
body.mode-presentation #bandeau-etat, body.mode-presentation .voile { display: none !important; }
body.mode-presentation .coque { display: block; }
body.mode-presentation #app { max-width: 1400px; padding-top: 18px; }
.pres { display: flex; flex-direction: column; gap: 18px; }
.pres-tete { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--primaire); color: #fff;
  border-radius: var(--rayon); padding: 12px 18px; border-bottom: 4px solid var(--or); }
.pres-logo { width: 44px; height: 44px; background: #fff; border-radius: 10px; padding: 3px; }
.pres-marque { display: flex; flex-direction: column; line-height: 1.2; }
.pres-marque span { font-size: .8rem; color: var(--or); text-transform: uppercase; letter-spacing: .06em; }
.pres-etat { border-radius: 99px; padding: 6px 14px; font-weight: 700; font-size: .9rem; }
.pres-etat-direct { background: #fff; color: #b3261e; }
.pres-etat-avenir { background: var(--or); color: var(--primaire); }
.pres-etat-clos { background: rgba(255,255,255,.15); color: #fff; }
@media (prefers-reduced-motion: no-preference) { .pres-etat-direct { animation: pres-pulse 2s ease-in-out infinite; } }
@keyframes pres-pulse { 50% { opacity: .65; } }
.pres-titre h1 { font-size: clamp(1.6rem, 1.1rem + 2.2vw, 3rem); line-height: 1.15; margin: 6px 0 8px; color: var(--primaire); }
.pres-titre p { margin: 0; color: var(--texte-2); font-size: 1.05rem; }
.pres-chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px; }
.pres-chiffre { display: flex; flex-direction: column; gap: 6px; padding: clamp(18px, 2vw, 28px); }
.pres-valeur { font-size: clamp(2.2rem, 1.4rem + 3vw, 4.2rem); font-weight: 800; line-height: 1; color: var(--primaire); font-variant-numeric: tabular-nums; }
.pres-valeur small { font-size: .45em; font-weight: 600; color: var(--texte-2); }
.pres-compte { font-size: clamp(1.6rem, 1.1rem + 2vw, 2.8rem); }
.pres-libelle { color: var(--texte-2); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; font-size: .85rem; }
.pres-chiffre-fort { background: var(--primaire); border-color: var(--primaire); }
.pres-chiffre-fort .pres-valeur { color: var(--or); }
.pres-chiffre-fort .pres-libelle { color: rgba(255,255,255,.85); }
.pres-bloc h2 { margin: 0 0 14px; color: var(--primaire); }
.jauge-pres { height: 34px; margin-top: 26px; }
.pres-note { margin: 10px 0 0; font-size: 1.05rem; }
.pres-secret { display: flex; gap: 14px; align-items: center; background: var(--or-clair); border-color: #ecd9a0; }
.pres-secret .ic { width: 34px; height: 34px; flex-shrink: 0; color: var(--primaire); }
.pres-secret div { display: flex; flex-direction: column; gap: 2px; }
.pres-secret span { color: var(--texte-2); }
.pres-pied { text-align: center; margin: 0 0 10px; }
.pres .resultats { font-size: 1.08rem; }
.courbe-pres { width: 100%; height: auto; display: block; }
.courbe-pres .grille { stroke: var(--bord); stroke-width: 1; }
.courbe-pres .axe { fill: var(--texte-2); font-size: 13px; }
.courbe-pres .aire { fill: var(--primaire); opacity: .1; }
.courbe-pres .trace { fill: none; stroke: var(--primaire); stroke-width: 3; stroke-linejoin: round; }
.courbe-pres .point { fill: var(--or); stroke: var(--primaire); stroke-width: 2; }
.courbe-pres .ligne-quorum { stroke: var(--or); stroke-width: 2; stroke-dasharray: 7 5; }
.courbe-pres .etiquette-quorum { fill: #8a6a10; font-size: 13px; font-weight: 700; }
.pres-voter { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; border-left: 4px solid var(--or); }
.pres-voter div { flex: 1; min-width: 240px; display: flex; flex-direction: column; gap: 4px; }
.pres-voter strong { font-size: 1.15rem; color: var(--primaire); }
.pres-voter span { color: var(--texte-2); }

/* ==========================================================================
   Comités de l'Ordre
   ========================================================================== */
.fil-ariane { font-size: .82rem; color: var(--texte-2); margin: 0 0 8px; }
.fil-ariane a { color: var(--texte-2); }
.page-entete { max-width: 860px; margin-bottom: 20px; }
.lien-btn { background: none; border: 0; padding: 0; font: inherit; font-size: .8rem; color: var(--primaire); cursor: pointer; text-decoration: underline; }
.barre-filtres { margin-bottom: 16px; }
.barre-filtres select { width: auto; }
.filtres-comites { margin-bottom: 20px; }
.filtres-comites input[type=search] { flex: 1 1 320px; }
.pastilles { display: flex; gap: 8px; flex-wrap: wrap; }
.pastille { font: inherit; font-size: .85rem; font-weight: 600; border: 1px solid var(--bord); background: #fff; color: var(--texte); border-radius: 99px; padding: 7px 14px; cursor: pointer; }
.pastille.actif { background: var(--primaire); border-color: var(--primaire); color: #fff; }
.grid-comites { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); }
.carte-comite { display: flex; flex-direction: column; gap: 8px; }
.carte-comite h3 { margin: 4px 0 0; }
.carte-comite p { margin: 0; }
.carte-comite-pied { margin-top: auto; display: flex; flex-direction: column; gap: 6px; padding-top: 10px; border-top: 1px solid var(--bord); }
.sigle { display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 6px; border-radius: 12px; background: var(--or-clair); color: #7a5b16; font-weight: 800; letter-spacing: .04em; }
.faq-comite summary { cursor: pointer; font-size: .85rem; font-weight: 600; color: var(--primaire); }
.faq-comite details { margin: 6px 0 0 10px; }
.faq-comite details summary { font-weight: 500; color: var(--texte); }
.alert details summary { cursor: pointer; margin-top: 6px; }
.liste-etapes { padding-left: 18px; margin: 0; }
.liste-etapes li + li { margin-top: 6px; }
.page-confirmation { max-width: 640px; margin: 24px auto; text-align: center; }
.case-ligne { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--bord); font-size: .92rem; }
.case-ligne input, .liste-cases input { width: auto; }
.liste-cases { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; border: 1px solid var(--bord); border-radius: 10px; padding: 10px; }
.modal:has(.modal-large) { width: min(920px, calc(100vw - 32px)); }
.ligne-nouvelle td:first-child { box-shadow: inset 3px 0 0 var(--or); }
.ligne-nouvelle td:nth-child(2) { font-weight: 600; }

/* Statuts des demandes */
.badge-c-nouvelle { background: var(--bleu-clair); color: var(--bleu); }
.badge-c-instruction { background: var(--primaire-clair); color: var(--primaire); }
.badge-c-complement { background: var(--or-clair); color: #8a6a10; }
.badge-c-deliberation { background: #efe7fb; color: #5b3a9c; }
.badge-c-redaction, .badge-c-validation { background: #e3f3f4; color: #11636b; }
.badge-c-repondue { background: var(--succes); color: #fff; }
.badge-c-close { background: #eceeed; color: #5b6560; }
.badge-c-recours { background: var(--rouge-clair); color: var(--rouge); }
.badge-c-consulte { background: #efe7fb; color: #5b3a9c; }

/* Étapes du dossier */
.etapes-dossier { list-style: none; display: flex; gap: 4px; padding: 0; margin: 0; overflow-x: auto; }
.etapes-dossier li { flex: 1 1 0; min-width: 92px; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; font-size: .75rem; color: var(--texte-2); position: relative; }
.etapes-dossier li span { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: #eceeed; color: var(--texte-2); position: relative; z-index: 1; }
.etapes-dossier li + li::before { content: ""; position: absolute; top: 14px; right: 50%; width: 100%; height: 2px; background: var(--bord); }
.etapes-dossier li.fait + li::before { background: var(--succes); }
.etapes-dossier li.fait span { background: var(--succes); color: #fff; }
.etapes-dossier li.courant span { background: var(--primaire); color: #fff; box-shadow: 0 0 0 4px var(--primaire-clair); }
.etapes-dossier li.courant { color: var(--primaire); font-weight: 700; }

/* Réponse officielle signée */
.reponse-officielle { border-top: 4px solid var(--or); }
.reponse-corps { line-height: 1.65; margin: 12px 0; overflow-wrap: anywhere; }
.signature { display: flex; gap: 16px; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; border-top: 1px dashed var(--bord); padding-top: 12px; }
.signature-code { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.signature-code strong { font-family: ui-monospace, Consolas, monospace; letter-spacing: .08em; font-size: 1.05rem; color: var(--primaire); }
.verif-ok { border-top: 4px solid var(--succes); }
.verif-ko { border-top: 4px solid var(--rouge); }

/* Espace collégial : annotations, avis */
.dossier-instruction { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
@media (max-width: 1100px) { .dossier-instruction { grid-template-columns: minmax(0, 1fr); } }
[data-annotable] .msg-corps { cursor: text; }
[data-annotable] .msg-corps::selection { background: #ffe9a8; }
.annotations { display: flex; flex-direction: column; gap: 10px; }
.annotation { display: flex; gap: 10px; background: #fffaf0; border: 1px solid #ecd9a0; border-left: 4px solid var(--or); border-radius: 10px; padding: 10px 12px; }
.annotation-reponse { margin-left: 32px; background: #fff; }
.annotation-corps { flex: 1; min-width: 0; }
.annotation-texte { white-space: pre-wrap; font-size: .92rem; margin-top: 4px; overflow-wrap: anywhere; }
.citation { margin: 6px 0; padding: 6px 10px; border-left: 3px solid var(--bord); color: var(--texte-2); font-size: .85rem; font-style: italic; background: var(--fond); border-radius: 0 6px 6px 0; }
.ligne-membre { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--bord); }
.ligne-membre:last-child { border-bottom: 0; }
.avis { font-size: .78rem; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.avis-pour { background: var(--succes-clair); color: var(--succes); }
.avis-contre { background: var(--rouge-clair); color: var(--rouge); }
.avis-abstention { background: #eceeed; color: #5b6560; }
.consultation { padding: 10px 0; border-bottom: 1px solid var(--bord); }
.journal { list-style: none; padding: 0; margin: 0; max-height: 520px; overflow-y: auto; }
.journal li { padding: 7px 0; border-bottom: 1px solid var(--bord); font-size: .88rem; }
.kb-apercu { white-space: pre-wrap; }

/* Statistiques */
.barres { display: flex; align-items: flex-end; gap: 6px; height: 180px; padding-top: 8px; }
.barre-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; }
.barre-col small { font-size: .68rem; color: var(--texte-2); }
.barre-paire { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 2px; }
.barre { width: 42%; min-height: 2px; border-radius: 3px 3px 0 0; }
.b1 { background: var(--primaire); }
.b2 { background: var(--or); }
.legende { display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: middle; margin: 0 4px 0 10px; }
.barre-h { display: grid; grid-template-columns: minmax(120px, 1fr) 2fr 32px; gap: 10px; align-items: center; padding: 5px 0; }
.barre-h-fond { height: 10px; background: var(--fond); border-radius: 99px; overflow: hidden; }
.barre-h-fond span { display: block; height: 100%; background: var(--primaire); border-radius: 99px; }

@media (max-width: 640px) {
  .etapes-dossier li { min-width: 70px; font-size: .68rem; }
  .annotation-reponse { margin-left: 12px; }
  .signature-code { align-items: flex-start; }
  .barre-filtres > * { flex: 1 1 100%; }
}
@media print {
  .sidebar, .tabs, .fil, #f-msg, #f-avis, .ticket-layout aside, #bandeau-etat { display: none !important; }
  body.avec-sidebar .coque { display: block; }
  .ticket-layout { display: block; }
  .reponse-officielle { box-shadow: none; border: 0; }
}
body.avec-sidebar nav.tabs.onglets-dossier { display: flex; }
@media (max-width: 900px) { .layout-dossier aside { order: 1; } }
