/* Identité : le registre papier d'une agence. Fond blanc, encre, vermillon des tampons ; Hubot Sans modifiée (« Titre » : zéro non barré, outils/zero_non_barre.py ; largeur
   resserrée) et Rethink Sans (texte). Ordinateur d'abord pour la direction, téléphone d'abord pour le parcours. */
@font-face { font-family: "Titre"; src: url("polices/hubot-sans.woff2") format("woff2"); font-weight: 200 900; font-stretch: 75% 125%; font-display: swap; }
@font-face { font-family: "Rethink"; src: url("polices/rethink-sans.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }
@font-face { font-family: "Rethink"; src: url("polices/rethink-sans-italique.woff2") format("woff2"); font-weight: 400 800; font-style: italic; font-display: swap; }

:root {
  --encre: #16181d; --doux: #5c616c; --filet: #d6d9de; --filet-2: #e8eaed; --surface: #f3f4f6; --blanc: #fff;
  --vermillon: #c4301a; --vermillon-fonce: #a32612; --vermillon-pale: #fbeae6; --vert: #1d6b46; --vert-pale: #e6f2ec;
  --r: 6px; --titre: "Titre", system-ui, sans-serif; --texte: "Rethink", system-ui, sans-serif;
}
* { box-sizing: border-box; touch-action: manipulation; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 16px; }
body { margin: 0; background: var(--blanc); color: var(--encre); font: 400 17px/1.55 var(--texte); text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; font-kerning: normal; }
h1, h2, h3 { font-family: var(--titre); font-stretch: 88%; font-weight: 720; line-height: 1.12; letter-spacing: 0; word-spacing: .1em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(30px, 4.2vw, 50px); }
h2 { font-size: clamp(24px, 2.6vw, 32px); }
h3 { font-size: 19px; }
p { margin: 0 0 1em; text-wrap: pretty; }
a { color: inherit; text-decoration-color: var(--vermillon); text-decoration-thickness: 1.5px; text-underline-offset: .2em; text-decoration-skip-ink: none; }
a:hover { color: var(--vermillon-fonce); }
:focus-visible { outline: 3px solid var(--vermillon); outline-offset: 2px; }
img { max-width: 100%; height: auto; display: block; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.insec { white-space: nowrap; }
.l { width: min(1200px, 100%); margin: 0 auto; padding: 0 clamp(20px, 4vw, 40px); }
.etroit .l, .etroit-l { max-width: 780px; }
.bloc { padding: clamp(48px, 7vw, 96px) 0; }
.chapeau { font-size: clamp(18px, 1.7vw, 21px); line-height: 1.5; color: var(--encre); max-width: 40em; }
.note { color: var(--doux); font-size: 15px; }
.maj, .source { color: var(--doux); font-size: 14px; }
.questions .maj, details + .maj { margin-top: 20px; }

/* boutons : rectangles, jamais de pilule */
.bouton, .b2 { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px;
  border-radius: var(--r); font: 650 16px/1.2 var(--texte); text-decoration: none; cursor: pointer; border: 2px solid transparent;
  -webkit-user-select: none; user-select: none; text-align: center; }
.bouton { background: var(--vermillon); color: #fff; }
.bouton:hover { background: var(--vermillon-fonce); color: #fff; }
.b2 { background: var(--blanc); color: var(--encre); border-color: var(--encre); }
.b2:hover { background: var(--surface); color: var(--encre); }
.bouton:disabled, .b2:disabled { opacity: .4; cursor: default; }
.danger.b2 { border-color: var(--vermillon); color: var(--vermillon-fonce); }
.bouton.danger { background: var(--vermillon-fonce); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 24px; }
.actions form { margin: 0; }

.brouillon { background: var(--encre); color: #fff; text-align: center; font-size: 14px; font-weight: 600; padding: 6px; }

/* en-tête et pied */
.haut { border-bottom: 1px solid var(--filet); background: var(--blanc); }
.haut .l { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.logo { font: 780 22px/1 var(--titre); font-stretch: 82%; letter-spacing: -.01em; text-decoration: none; color: var(--encre); }
.haut nav { display: flex; gap: 4px; align-items: center; }
.haut nav a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 14px; text-decoration: none; font-weight: 600; border-radius: var(--r); }
.haut nav a[aria-current]:not(.nav-cta) { box-shadow: inset 0 -3px 0 var(--vermillon); }
.haut nav .nav-cta { background: var(--encre); color: #fff; }
.haut nav .nav-cta:hover { background: #000; color: #fff; }
.agence-nom { color: var(--doux); font-weight: 600; text-align: right; min-width: 0; line-height: 1.25; overflow-wrap: anywhere; padding: 6px 0; }
.pied { border-top: 3px solid var(--encre); margin-top: 40px; padding: 32px 0 calc(32px + env(safe-area-inset-bottom)); font-size: 15px; }
.mention { color: var(--doux); max-width: 60em; }
.pied .liens { display: flex; flex-wrap: wrap; gap: 0 4px; align-items: center; }
.pied .liens a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 10px 0 0; margin-right: 10px; text-decoration: none; }
.pied .liens a:hover { text-decoration: underline; }
.pied .liens .logo { font-size: 18px; margin-right: 18px; }

/* une : le registre comme objet */
.une { padding: clamp(40px, 6vw, 84px) 0 clamp(40px, 6vw, 72px); border-bottom: 1px solid var(--filet); }
.une-grille { display: grid; grid-template-columns: 1fr 1.02fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.une h1 { font-size: clamp(32px, 3.9vw, 52px); }
.registre { margin: 0; background: var(--blanc); border: 1px solid var(--filet); border-top: 4px solid var(--encre);
  box-shadow: 0 1px 0 var(--filet), 0 18px 40px -24px rgba(22, 24, 29, .35); font-size: 15px; }
.registre-tete { display: flex; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 2px solid var(--encre); }
.registre-tete b { word-spacing: .1em; font-family: var(--titre); font-stretch: 85%; font-size: 17px; }
.registre-tete > span { color: var(--doux); }
.registre-pied span { white-space: nowrap; }
.registre table { width: 100%; border-collapse: collapse; }
.registre th { text-align: left; font-size: 14px; color: var(--doux); font-weight: 600; padding: 10px 10px 8px; border-bottom: 1px solid var(--filet); }
.registre td { padding: 11px 10px; border-bottom: 1px solid var(--filet-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.registre th:first-child, .registre td:first-child { padding-left: 18px; }
.registre-pied { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; padding: 12px 18px; color: var(--doux); font-size: 14px; font-variant-numeric: tabular-nums; }
.tampon { display: inline-block; border: 2px solid var(--vermillon); color: var(--vermillon); font: 750 14px/1 var(--titre); font-stretch: 85%;
  padding: 4px 6px; border-radius: 3px; transform: rotate(-3deg); margin-right: 8px; font-variant-numeric: tabular-nums; }
.suivi .valide { display: block; }
.suivi .valide .nw, .suivi .valide .quand { white-space: nowrap; }
@media (max-width: 359px) { .suivi .valide .quand { white-space: normal; } }
.suivi .detail { display: block; color: var(--doux); font-size: 14px; margin-top: 4px; }
.suivi .lien-doc { display: flex; width: max-content; margin: 8px 0 0; }
.tampon.grand { font-size: 28px; padding: 8px 12px; border-width: 3px; }
.a-faire { color: var(--doux); font-style: italic; }

/* parcours par poste */
.intro { max-width: 46em; font-size: 18px; }
.postes { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 2px solid var(--encre); margin-top: 32px; }
.poste { padding: 18px 18px 8px 0; }
.poste + .poste { padding-left: 18px; border-left: 1px solid var(--filet); }
.poste h3 { font-size: 20px; }
.poste p { font-size: 15px; color: var(--doux); margin: 0; }
.tronc-titre { margin-top: 36px; }
.tronc { list-style: none; counter-reset: ch; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  border-top: 1px solid var(--filet); }
.tronc li { counter-increment: ch; padding: 12px 16px 12px 0; border-bottom: 1px solid var(--filet); font-weight: 600; font-size: 15px; display: flex; gap: 10px; }
.tronc li::before { content: counter(ch); color: var(--vermillon); font-family: var(--titre); font-weight: 750; font-variant-numeric: tabular-nums; }

/* preuve */
.preuve { background: var(--surface); }
.preuve-grille { display: grid; grid-template-columns: .95fr 1.05fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.apercu { margin: 0 auto; width: min(100%, 460px); border: 1px solid var(--filet); box-shadow: 0 18px 40px -24px rgba(22, 24, 29, .35); background: var(--blanc); }
.docs { margin: 24px 0; border-top: 2px solid var(--encre); }
.docs div { padding: 14px 0; border-bottom: 1px solid var(--filet); }
.docs dt { font-weight: 700; }
.docs dd { margin: 4px 0 0; color: var(--doux); font-size: 16px; }

/* prix */
.prix-grille { display: grid; grid-template-columns: 440px 1fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.prix-carte { border: 2px solid var(--encre); border-radius: var(--r); padding: 28px; }
.montant { font: 760 56px/1 var(--titre); font-stretch: 85%; margin: 0 0 6px; font-variant-numeric: tabular-nums; }
.pour { color: var(--doux); margin-bottom: 18px; }
.formules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.formules > div + div { border-left: 1px solid var(--filet); padding-left: 20px; }
.formules > div:first-child { padding-right: 20px; }
.formules { margin-bottom: 24px; }
.encart .formules { margin-bottom: 14px; }
.encart .pour { margin: 0; }
.prix-carte ul { padding: 0; margin: 0; list-style: none; border-top: 1px solid var(--filet); }
.prix-carte li { padding: 10px 0 10px 24px; border-bottom: 1px solid var(--filet); position: relative; font-size: 16px; }
.prix-carte li:last-child { border-bottom: 0; padding-bottom: 0; }
.prix-carte li::before { content: ""; position: absolute; left: 2px; top: 17px; width: 10px; height: 6px; border-left: 2px solid var(--vermillon);
  border-bottom: 2px solid var(--vermillon); transform: rotate(-45deg); }
.prix-carte .bouton { width: 100%; }
.hoguet { border-left: 4px solid var(--vermillon); padding: 4px 0 4px 16px; font-weight: 600; }
.prix-avis h3 { margin-top: 28px; }

/* questions */
.questions details { border-bottom: 1px solid var(--filet); }
.questions details:first-of-type { border-top: 2px solid var(--encre); }
.questions summary { cursor: pointer; list-style: none; padding: 16px 40px 16px 0; font-weight: 700; position: relative; min-height: 44px; text-wrap: balance; }
.questions summary::-webkit-details-marker { display: none; }
.questions summary::after { content: ""; position: absolute; right: 8px; top: 20px; width: 9px; height: 9px; border-right: 2px solid var(--encre);
  border-bottom: 2px solid var(--encre); transform: rotate(45deg); transition: transform .15s; }
.questions details[open] summary::after { transform: rotate(-135deg); top: 25px; }
.questions details p { color: var(--encre); max-width: 46em; }

/* formulaires */
.formulaire { margin-top: 24px; }
fieldset { border: 0; padding: 0; margin: 0 0 28px; min-width: 0; }
legend { word-spacing: .1em; font: 720 20px/1.2 var(--titre); font-stretch: 88%; margin-bottom: 12px; padding: 0;
  float: left; width: 100%; }  /* flottante : sous le filet de son bloc au lieu de le couper */
legend + * { clear: both; }
.champ { margin-bottom: 16px; }
.champ label { display: block; font-weight: 650; margin-bottom: 6px; font-size: 16px; }
/* Chromium remet text-rendering à auto dans les champs et boutons : ils reprennent celui de la page (kit 04/12). */
button, input, select, textarea { text-rendering: inherit; }
input:not([type=checkbox]):not([type=radio]), select, textarea { width: 100%; min-height: 48px; font: 400 17px/1.3 var(--texte); color: var(--encre);
  border: 1.5px solid #9aa0aa; border-radius: var(--r); padding: 10px 12px; background: var(--blanc); -webkit-appearance: none; appearance: none; }
select { background-image: linear-gradient(45deg, transparent 50%, var(--encre) 50%), linear-gradient(135deg, var(--encre) 50%, transparent 50%);
  background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
input[type=date] { min-width: 0; }
input[type=date]::-webkit-date-and-time-value { text-align: left; margin: 0; }
input:focus, select:focus, textarea:focus { border-color: var(--encre); outline: 3px solid rgba(196, 48, 26, .25); outline-offset: 0; }
input[readonly] { background: var(--surface); }
.faux input:not([type=checkbox]), .champ.faux input { border-color: var(--vermillon); }
.erreur { display: block; color: var(--vermillon-fonce); font-size: 15px; margin-top: 6px; font-weight: 600; }
.alerte { background: var(--vermillon-pale); border-left: 4px solid var(--vermillon); padding: 12px 16px; font-weight: 600; border-radius: 0 var(--r) var(--r) 0; }
.bandeau { background: var(--vert-pale); border-left: 4px solid var(--vert); padding: 12px 16px; font-weight: 600; border-radius: 0 var(--r) var(--r) 0; }
.case { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; cursor: pointer; min-height: 44px; }
.case input, .choix input { width: 22px; height: 22px; margin: 1px 0 0; flex: none; accent-color: var(--vermillon); }
.case.faux span { color: var(--vermillon-fonce); }
fieldset:disabled .case { cursor: default; color: var(--doux); }
fieldset:disabled .case input { opacity: .45; accent-color: var(--doux); }
.risques .case { border-bottom: 1px solid var(--filet-2); }
.aide-legende { color: var(--doux); font-size: 15px; }

/* commande : le prix affiché suit la formule cochée, sans script (bouton de commande et récapitulatif) */
.commande-grille:has([name=places][value="3"]:checked) .si-10, .commande-grille:has([name=places][value="10"]:checked) .si-3 { display: none; }
.choix-formule .choix { align-items: center; min-height: 56px; font-weight: 600; }
.choix-formule .choix b { margin-left: auto; font: 760 24px/1 var(--titre); font-stretch: 88%; }
.choix-formule .choix input { margin: 0; }
.commande-grille { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(32px, 5vw, 64px); align-items: start; }
.commande h1 { font-size: clamp(30px, 3.4vw, 42px); }
.commande fieldset + fieldset { border-top: 2px solid var(--encre); padding-top: 22px; }
.avant-achat { border-top: 2px solid var(--encre); padding-top: 22px; }
.avant-achat .bouton { width: 100%; margin-top: 16px; min-height: 56px; font-size: 17px; }
.recap { position: sticky; top: 24px; border: 2px solid var(--encre); border-radius: var(--r); padding: 24px; }
.recap .montant { font-size: 44px; }
.recap dl { margin: 0; border-top: 1px solid var(--filet); }
.recap dl div { padding: 10px 0; border-bottom: 1px solid var(--filet); display: grid; grid-template-columns: 116px 1fr; gap: 12px; font-size: 15px; }
.recap dt { color: var(--doux); }
.recap dd { margin: 0; font-weight: 600; }
.apres { margin: 16px 0 0; font-size: 15px; color: var(--doux); }

/* espace de l'agence */
.espace { padding-top: clamp(28px, 4vw, 48px); }
.espace-tete { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 24px; }
.espace-tete h1 { font-size: clamp(28px, 3vw, 40px); margin-bottom: 6px; }
.etat-pass { margin: 0; font-weight: 600; color: var(--vert); }
.etat-termine, .etat-rembourse { color: var(--vermillon-fonce); }
.telechargements { display: flex; gap: 10px; flex-wrap: wrap; }
.telechargements a { white-space: nowrap; padding: 0 16px; }
.equipe { border-top: 4px solid var(--encre); margin-top: 8px; }
.grand-livre { width: 100%; border-collapse: collapse; font-size: 16px; }
.grand-livre th { text-align: left; font-size: 14px; color: var(--doux); font-weight: 600; padding: 12px 12px 10px 0; border-bottom: 2px solid var(--encre); white-space: nowrap; }
.grand-livre td { padding: 12px 12px 12px 0; border-bottom: 1px solid var(--filet); vertical-align: middle; font-variant-numeric: tabular-nums; }
.grand-livre td.nom { font-weight: 700; }
.grand-livre .parti { display: block; font-weight: 400; color: var(--doux); font-size: 14px; }
.grand-livre tr.statut-parti td { color: var(--doux); }
.grand-livre td.echue { color: var(--vermillon-fonce); font-weight: 700; }
@media (min-width: 900px) { .grand-livre td[data-l="Poste"] { min-width: 11.5rem; } }
.lien-doc { margin-left: 14px; white-space: nowrap; min-height: 44px; }
.jauge { display: inline-block; width: 64px; height: 8px; background: var(--filet); border-radius: 4px; overflow: hidden; vertical-align: middle; margin-right: 8px; }
.jauge i { display: block; height: 100%; width: var(--p); background: var(--vermillon); }
.actions-ligne { text-align: right; width: 1%; }
.menu { position: relative; display: inline-block; text-align: left; }
.menu summary { list-style: none; min-height: 44px; }
.menu:not([open]) > :not(summary), .confirmer:not([open]) > :not(summary) { display: none; }
.menu summary::-webkit-details-marker { display: none; }
.menu-corps { position: absolute; right: 0; top: calc(100% + 6px); z-index: 5; width: 380px; background: var(--blanc); border: 2px solid var(--encre);
  border-radius: var(--r); padding: 16px; display: grid; box-shadow: 0 18px 40px -20px rgba(22, 24, 29, .4); }
.menu-corps form { margin: 0; }
.menu-corps label { font-weight: 650; font-size: 14px; }
.menu-corps .b2 { min-height: 44px; }
.copie { display: flex; gap: 8px; margin-top: 6px; }
.copie input { font-size: 16px !important; }
.ligne-form { display: grid; gap: 6px; justify-items: start; }
.ligne-form .b2 { margin-top: 4px; }
.ligne-form .erreur { margin: 0; }
.menu-corps .alerte, .menu-corps .bandeau { margin: 0; font-size: 15px; }
.menu-corps > * { padding-bottom: 14px; }
.menu-corps > * + * { border-top: 1px solid var(--filet); padding-top: 12px; }
.menu-corps > :last-child { padding-bottom: 0; }
.menu-corps > .alerte, .menu-corps > .bandeau, .menu-corps > .alerte + *, .menu-corps > .bandeau + * { border-top: 0; }
.menu-corps > .alerte, .menu-corps > .bandeau { padding-top: 12px; }
/* geste qui coupe ou efface : il se déplie, dit ce qu'il fait, puis se confirme */
.confirmer summary { cursor: pointer; min-height: 44px; padding: 10px 0; font-weight: 650; text-decoration: underline;
  text-decoration-color: var(--vermillon); text-underline-offset: .2em; list-style: none; }
.confirmer summary::-webkit-details-marker { display: none; }
.confirmer .rouge { color: var(--vermillon-fonce); }
.confirmer p { font-size: 15px; margin: 0 0 10px; }
.menu-corps > .confirmer { padding: 2px 0; }
.menu-corps > .confirmer[open] { padding-bottom: 14px; }
.compte .confirmer { margin-bottom: 16px; }
.neuf { margin-bottom: 22px; padding-bottom: 22px; border-bottom: 1px solid var(--filet); }
.neuf label { font-weight: 650; }
.neuf .copie { max-width: 640px; }
.vide { color: var(--doux); padding: 18px 0; margin: 0; }
.ajout { margin-top: 28px; background: var(--surface); padding: 20px 24px; border-radius: var(--r); }
.ajout h2 { font-size: 20px; }
.ajout-champs { display: grid; grid-template-columns: 1.4fr 1fr 1fr auto; gap: 16px; align-items: start; }
.ajout-champs .bouton { margin-top: 31px; }   /* à la hauteur des champs, sous leur libellé */
.ajout-champs .champ { margin: 0; }
.espace-bas { display: grid; grid-template-columns: 1fr 380px; gap: clamp(32px, 5vw, 64px); margin-top: 56px; align-items: start; }
.espace-bas h2 { font-size: 24px; }
.frequence legend { font-size: 17px; }
.compte dl { margin: 0 0 16px; border-top: 2px solid var(--encre); }
.compte dl div { display: grid; grid-template-columns: 110px 1fr; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--filet); font-size: 15px; }
.compte dt { color: var(--doux); }
.compte dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.compte dd a { display: flex; align-items: center; width: fit-content; min-height: 44px; }
.compte dd a:first-child { margin: -10px 0; }
.page-passage .avant-achat { border-top: 0; padding-top: 0; }
.retour { margin-top: 16px; }
.complet { margin-bottom: 14px; }
.total { font-size: 18px; margin: 0 0 14px; }
.relire .calcul { display: block; font-weight: 400; margin-top: 6px; }

/* parcours du collaborateur (téléphone d'abord) */
.page-formation main { padding-bottom: 24px; }
.haut-formation .l { min-height: 56px; }
.haut-formation .logo { font-size: 19px; }
.avance { height: 4px; background: var(--filet-2); }
.avance i { display: block; height: 100%; background: var(--vermillon); }
.lecture { max-width: 720px; padding-top: 28px; }
.lecture h1 { font-size: clamp(27px, 4vw, 38px); }
.lecture p, .lecture li { font-size: 18px; line-height: 1.6; }
.sur-titre { color: var(--vermillon-fonce); font-weight: 700; margin-bottom: 8px; font-size: 16px !important; }
.puces { padding-left: 1.2em; margin: 0 0 1em; }
.puces li { margin-bottom: .5em; padding-left: 4px; }
.puces li::marker { color: var(--vermillon); }
.retenir { border-left: 4px solid var(--vermillon); background: var(--vermillon-pale); padding: 14px 16px; border-radius: 0 var(--r) var(--r) 0; font-weight: 600; }
.plan-parcours { list-style: none; padding: 0; margin: 24px 0; border-top: 2px solid var(--encre); }
.plan-parcours li { padding: 14px 0; border-bottom: 1px solid var(--filet); display: grid; gap: 2px; }
.plan-parcours b { word-spacing: .1em; font-family: var(--titre); font-stretch: 88%; font-size: 20px; }
.plan-parcours a { min-height: 44px; display: flex; align-items: center; font-weight: 600; }
.plan-parcours li:has(a) { padding: 0; }
.plan-parcours span { color: var(--doux); font-size: 16px; }
.situation { background: var(--surface); padding: 16px 18px; border-radius: var(--r); }
.choix-cas legend, .question legend { word-spacing: normal; font: 700 18px/1.4 var(--texte); margin-bottom: 10px; }
.question legend { padding-left: 1.9em; position: relative; }
.choix { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1.5px solid var(--filet); border-radius: var(--r); margin-bottom: 8px;
  cursor: pointer; min-height: 48px; font-size: 17px; }
.choix:has(input:checked):not(.juste, .faux) { border-color: var(--encre); background: var(--surface); }
.choix.juste { border-color: var(--vert); background: var(--vert-pale); }
.choix.faux { border-color: var(--vermillon); background: var(--vermillon-pale); }
fieldset:disabled .choix { cursor: default; color: var(--encre); }
/* rond dessiné : le navigateur grise le sien dès que la réponse est validée, et le choix fait ne se voit plus */
.choix input { appearance: none; -webkit-appearance: none; border: 2px solid var(--doux); border-radius: 50%; background: var(--blanc); }
.choix input:checked { border-color: var(--encre); box-shadow: inset 0 0 0 4px var(--blanc); background: var(--encre); }
.choix.juste input:checked { border-color: var(--vert); background: var(--vert); }
.choix.faux input:checked { border-color: var(--vermillon); background: var(--vermillon); }
.corrige { margin: 10px 0 12px; }
.corrige div { display: grid; grid-template-columns: 9.5em 1fr; gap: 12px; padding: 6px 0; }
.corrige dt { color: var(--doux); }
.corrige dd { margin: 0; }
.corrige .bonne { color: var(--vert); font-weight: 600; }
.explication { border-left: 4px solid var(--vert); padding: 4px 0 4px 16px; margin: 20px 0; }
.explication.revoir { border-color: var(--vermillon); }
.verdict-cas { font-weight: 700; }
.attendue { color: var(--vert); font-weight: 600; }
.question { padding-top: 18px; border-top: 1px solid var(--filet); }
.question.faux legend { color: var(--vermillon-fonce); }
.num { position: absolute; left: 0; color: var(--vermillon); font-family: var(--titre); font-weight: 750; }
.fait { display: flex; gap: 20px; align-items: center; margin: 24px 0; }
.fait .chapeau { margin-bottom: 4px; }
.note.suite { margin-top: 20px; }
.fait p:last-child { margin: 0; color: var(--doux); font-size: 16px; }
/* bouton principal collé en bas sur téléphone, au-dessus du clavier et de la barre de Safari */
.colle { margin-top: 28px; }

/* vérification */
.relire { margin: 20px 0; border-top: 2px solid var(--encre); }
.relire div { display: grid; grid-template-columns: 160px 1fr; gap: 12px; border-bottom: 1px solid var(--filet); padding: 10px 0; }
.relire dt { color: var(--doux); }
.relire dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.empreinte { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.verifie .chapeau { color: var(--vert); font-weight: 700; }

/* guides et pages légales */
.guide-grille { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(32px, 5vw, 72px); align-items: start; }
.guide-texte { max-width: 720px; }
.guide-texte h1 { font-size: clamp(30px, 3.6vw, 44px); }
.guide-texte h2, .texte-legal h2 { margin-top: 1.6em; font-size: 24px; }
.guide-texte p { font-size: 18px; line-height: 1.65; }
.guide-texte .maj { font-size: 14px; margin-top: 28px; }
.guide-cote { position: sticky; top: 24px; }
.encart { border: 2px solid var(--encre); border-radius: var(--r); padding: 22px; }
.encart .montant { font-size: 40px; }
.encart p { font-size: 15px; }
.encart .bouton { width: 100%; }
.autres { display: grid; margin-top: 20px; border-top: 1px solid var(--filet); }
.autres a { padding: 12px 0; border-bottom: 1px solid var(--filet); text-decoration: none; font-weight: 600; font-size: 15px; min-height: 44px; }
.autres a:hover { color: var(--vermillon-fonce); }
.texte-legal { font-size: 16px; }
.texte-legal li { margin-bottom: .4em; }

/* facture */
.imprimer main { background: var(--surface); }
.imprimer .pied { margin-top: 0; }
.d-page { padding-top: 20px; padding-bottom: 40px; max-width: 980px; }
.d-actions { display: flex; gap: 10px; }
.d-barre { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; max-width: 900px; margin-bottom: 18px; }
.d-barre .b2, .d-barre .bouton { white-space: nowrap; }
.doc { background: var(--blanc); padding: clamp(20px, 4vw, 48px); border: 1px solid var(--filet); max-width: 900px; font-size: 15px; }
.d-tete { display: flex; justify-content: space-between; gap: 24px; border-bottom: 3px solid var(--encre); padding-bottom: 12px; margin-bottom: 18px; }
.d-tete h1 { font-size: 26px; margin-bottom: 4px; }
.d-tete p { margin: 0; color: var(--doux); }
.d-brouillon { color: var(--vermillon); font-weight: 700; text-transform: uppercase; }
.f-parties { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 24px; }
.f-parties h3 { font-size: 15px; color: var(--doux); }
.d-grille, .d-tab { width: 100%; border-collapse: collapse; margin-bottom: 18px; }
.d-grille th, .d-grille td { border: 1px solid var(--filet); padding: 8px; text-align: left; vertical-align: top; }
.d-grille thead th { background: var(--surface); font-size: 14px; }
.d-grille td:not(:first-child) { white-space: nowrap; text-align: right; }
.f-total { max-width: 420px; margin-left: auto; }
.d-tab th { text-align: left; font-weight: 450; padding: 6px 8px 6px 0; }
.d-tab td { text-align: right; font-weight: 650; white-space: nowrap; }
.d-tab tr.fort { border-top: 2px solid var(--encre); }
.d-note { color: var(--doux); font-size: 14px; }

@media print {
  .haut, .pied, .d-barre, .brouillon { display: none; }
  .imprimer main { background: none; }
  .doc { border: 0; padding: 0; }
}

/* ordinateur moyen : 1280–1366 */
@media (max-width: 1240px) {
  .postes { grid-template-columns: repeat(3, 1fr); }
  .poste:nth-child(4) { padding-left: 0; border-left: 0; }
  .poste:nth-child(n+4) { border-top: 1px solid var(--filet); }
}

/* tablette et téléphone */
@media (max-width: 900px) {
  .une-grille, .preuve-grille, .prix-grille, .commande-grille, .espace-bas, .guide-grille { grid-template-columns: minmax(0, 1fr); }
  .recap, .guide-cote { position: static; }
  .tronc { grid-template-columns: 1fr 1fr; }
  .ajout-champs { grid-template-columns: 1fr 1fr; }
  .ajout-champs .bouton { grid-column: 1 / -1; margin-top: 0; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .haut .l { min-height: 60px; }
  .haut nav a[href^="/guide"] { display: none; }
  .haut nav a { padding: 0 12px; }
  .postes { grid-template-columns: 1fr; }
  .poste, .poste + .poste { padding: 14px 0; border-left: 0; border-top: 1px solid var(--filet); }
  .poste:first-child { border-top: 0; }
  .tronc { grid-template-columns: 1fr; }
  .registre { font-size: 14px; margin: 0 -8px; }
  .registre th:nth-child(4), .registre td:nth-child(4) { display: none; }
  .registre td, .registre th { padding-left: 6px; padding-right: 6px; }
  .registre th:first-child, .registre td:first-child { padding-left: 12px; }
  .registre-tete, .registre-pied { padding-left: 12px; padding-right: 12px; }
  .registre-tete { flex-direction: column; gap: 2px; }
  .montant { font-size: 46px; }
  .prix-carte { padding: 22px; }
  .formules > div + div { padding-left: 14px; }
  .formules > div:first-child { padding-right: 14px; }
  .formules .montant { font-size: 42px; }
  .actions .bouton, .actions .b2 { flex: 1 1 auto; }
  .ajout-champs { grid-template-columns: 1fr; }
  .ajout { padding: 18px 16px; margin-left: -4px; margin-right: -4px; }
  .relire div, .recap dl div, .compte dl div { grid-template-columns: 1fr; gap: 2px; }
  .telechargements { width: 100%; }
  .telechargements .bouton { flex: 1 1 100%; }
  .telechargements .b2 { flex: 1 1 0; }
  .menu-corps { width: min(340px, calc(100vw - 40px)); }
  .f-parties { grid-template-columns: 1fr; }
  /* parcours : le bouton principal reste à portée du pouce */
  .page-formation .colle { position: sticky; bottom: 0; background: var(--blanc); border-top: 1px solid var(--filet); margin: 20px -20px 0;
    padding: 18px 20px calc(12px + env(safe-area-inset-bottom)); display: flex; flex-wrap: wrap; gap: 10px; z-index: 3; }
  .page-formation .colle .bouton { flex: 2 1 auto; white-space: nowrap; }
  .page-formation .colle .b2 { flex: 1 0 auto; white-space: nowrap; }
  .lecture p, .lecture li { font-size: 17px; }
  .fait { flex-direction: column; align-items: flex-start; gap: 12px; }
  .corrige div { grid-template-columns: 1fr; gap: 0; }
  .pied .liens { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .pied .liens a { margin: 0; padding: 6px 0; line-height: 1.3; }
  .pied .liens .logo { grid-column: 1 / -1; margin: 0; }
}
@media (max-width: 359px) {
  .registre th:nth-child(3), .registre td:nth-child(3) { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Fiches et facture en blocs : à l'ÉCRAN seulement (une page A4 imprimée fait ~718 px CSS : sans « screen », l'équipe
   et la facture s'imprimeraient en fiches ; contre-relecture 04/12). */
@media screen and (max-width: 900px) {
  /* équipe en fiches : une personne par bloc, libellé à gauche (data-l), menu Gérer en haut à droite */
  .grand-livre thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .grand-livre, .grand-livre tbody { display: block; }
  .grand-livre tr { display: grid; grid-template-columns: 1fr auto; column-gap: 12px; row-gap: 4px; padding: 14px 0;
    border-bottom: 1px solid var(--filet); }
  .grand-livre td { display: block; padding: 0; border: 0; }
  .grand-livre td.nom { grid-column: 1; grid-row: 1; font-size: 18px; align-self: center; }
  .grand-livre td.actions-ligne { grid-column: 2; grid-row: 1; width: auto; }
  .grand-livre td[data-l] { grid-column: 1 / -1; position: relative; padding-left: 140px; min-height: 26px; }
  .grand-livre td[data-l]::before { content: attr(data-l); position: absolute; left: 0; top: 0; width: 132px; white-space: nowrap; color: var(--doux);
    font-size: 14px; font-weight: 600; line-height: 1.85; }
  .grand-livre .suivi .lien-doc { margin: 8px 0 0; display: flex; width: max-content; }
  .grand-livre .tampon { margin-right: 6px; }
}
@media screen and (max-width: 600px) {
  .d-tete { flex-wrap: wrap; gap: 4px 24px; }
  .d-tete h1 { font-size: 24px; }
  .d-grille thead { display: none; }
  .d-grille, .d-grille tbody, .d-grille tr { display: block; }
  .d-grille tr { border: 1px solid var(--filet); }
  .d-grille td { display: flex; justify-content: space-between; gap: 12px; border: 0; border-top: 1px solid var(--filet); }
  .d-grille td:first-child { display: block; border-top: 0; font-weight: 600; }
  .d-grille td[data-l]::before { content: attr(data-l); color: var(--doux); font-weight: 450; font-size: 14px; }
}
