/* ============================================================================
   Perpens — bibliotheque.css
   Refonte premium, piste B (2026-09-27) : s'appuie sur refonte.css (jetons,
   Geist, feuilles). Aucune dépendance à l'ancienne feuille (retirée).
   Quatre types de capsules, quatre identités. Les couleurs sont celles de
   capsule/CAPSULES-DESIGN-SPEC.md §6 : PME, Achat, Négo (prune, proposée),
   Loi (lilas, proposée). Le corail n'est jamais un fond de texte blanc.
   ========================================================================== */

/* -- Jetons des capsules (polish, 2026-09-27) -----------------------------
   Nuances propres à la charte des capsules (CAPSULES-DESIGN-SPEC.md §6),
   mêmes valeurs qu'avant, nommées ici une fois. Les couleurs communes au
   site (nuit, émeraudes, encre) viennent des jetons de refonte.css. */
:root {
  --cap-vin-900: #3B1530;  --cap-vin-800: #4A1D3F;  --cap-vin-700: #6B2D5C;  --cap-vin-600: #5A2D4C;
  --cap-lilas: #EDE4F5;    --cap-rose: #F1E3EC;     --cap-menthe: #D8EFE6;   --cap-em-950: #022C22;
  --cap-corail-50: #FFF4F0; --cap-corail-ink: #9A2F14;
}

/* -- Identités par type --------------------------------------------------- */
.t-pme   { --bg:var(--night-2); --fg:#fff;    --mu:var(--cap-menthe); --pill:var(--em-800); --pillfg:#fff; --box:var(--em-50); --boxfg:var(--ink); --ghost:rgba(255,255,255,.06); }
.t-achat { --bg:var(--em-700); --fg:#fff;    --mu:#fff;    --pill:var(--em-800); --pillfg:#fff; --box:var(--em-50); --boxfg:var(--ink); --ghost:rgba(255,255,255,.09); }
.t-nego  { --bg:var(--cap-vin-800); --fg:#fff;    --mu:var(--cap-rose); --pill:var(--cap-vin-700); --pillfg:#fff; --box:var(--cap-lilas); --boxfg:var(--cap-vin-900); --ghost:rgba(255,255,255,.07); }
.t-loi   { --bg:var(--cap-lilas); --fg:var(--cap-vin-900); --mu:var(--cap-vin-600); --pill:var(--cap-vin-900); --pillfg:#fff; --box:#fff;    --boxfg:var(--cap-vin-900); --ghost:rgba(59,21,48,.07); }
/* Une capsule qui existe des deux côtés porte les deux identités : le même arrêt, lu des deux côtés. */
.t-paire { --bg:var(--night-2); --fg:#fff;    --mu:#fff;    --pill:var(--em-800); --pillfg:#fff; --box:var(--em-50); --boxfg:var(--ink); --ghost:rgba(255,255,255,.08);
           background-image: linear-gradient(115deg, var(--night-2) 0 52%, var(--em-700) 52% 100%); }

.bib-maquette {
  background: var(--cap-corail-50); color: var(--ink);
  border-bottom: 3px solid var(--coral);
  padding: 12px var(--gut); text-align: center; font-size: 14.5px; line-height: 1.5;
}

.bib-retour { color: inherit; text-decoration: none; }
.bib-retour:hover { text-decoration: underline; }

/* -- 1. Les quatre types --------------------------------------------------- */
.bib-types-grille {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.bib-type {
  position: relative; overflow: hidden;
  background-color: var(--bg); color: var(--fg);
  border-radius: 18px; padding: 24px 22px 22px;
  min-height: 210px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: 0 10px 22px -16px rgba(0,0,0,.6);
}
.bib-type::before, .cap::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 1; background-repeat: repeat; }
.bib-type > *, .cap > * { position: relative; }
.bib-type h3 { margin: 0; font-family: var(--f-titre); font-weight: 700; font-size: 22px; line-height: 1.15; color: inherit; }
.bib-type p { margin: 0; color: var(--mu); font-size: 15px; line-height: 1.5; }
.bib-type .bib-nb { margin-top: auto; font-weight: 700; font-size: 14px; letter-spacing: .02em; }
.bib-type.t-paire .bib-nb, .bib-type .bib-nb { color: var(--fg); }
.bib-type button { all: unset; cursor: pointer; margin-top: 4px; min-height: 24px; /* WCAG 2.5.8 (analyse 26/09) */ font-weight: 700; font-size: 14.5px; text-decoration: underline; text-underline-offset: 3px; color: var(--fg); }
.bib-type button:focus-visible { outline: 3px solid var(--fg); outline-offset: 3px; } /* audit T4 : couleur du texte de la carte, contrastée sur son fond */

/* Motifs : un par type, discrets (jamais de texte dessus) */
.t-pme::before   { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40'%3E%3Cg fill='none' stroke='%23fff' stroke-opacity='.07' stroke-width='2'%3E%3Crect x='1' y='1' width='38' height='18'/%3E%3Crect x='41' y='1' width='38' height='18'/%3E%3Crect x='-19' y='21' width='38' height='18'/%3E%3Crect x='21' y='21' width='38' height='18'/%3E%3Crect x='61' y='21' width='38' height='18'/%3E%3C/g%3E%3C/svg%3E"); }
.t-achat::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='36' height='36'%3E%3Cg stroke='%23fff' stroke-opacity='.1' stroke-width='2'%3E%3Cpath d='M0 9h36M0 27h36'/%3E%3C/g%3E%3Cg fill='%23fff' fill-opacity='.1'%3E%3Crect x='4' y='4' width='6' height='10'/%3E%3Crect x='22' y='22' width='6' height='10'/%3E%3C/g%3E%3C/svg%3E"); }
.t-nego::before  { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='32'%3E%3Cg fill='none' stroke='%23fff' stroke-opacity='.09' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 8l7 8-7 8'/%3E%3Cpath d='M40 8l-7 8 7 8'/%3E%3C/g%3E%3C/svg%3E"); }
.t-loi::before   { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='44'%3E%3Ctext x='8' y='30' font-family='Georgia,serif' font-weight='800' font-size='26' fill='%233B1530' fill-opacity='.08'%3E%C2%A7%3C/text%3E%3C/svg%3E"); }
.t-paire::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40'%3E%3Cg fill='none' stroke='%23fff' stroke-opacity='.06' stroke-width='2'%3E%3Crect x='1' y='1' width='38' height='18'/%3E%3Crect x='41' y='1' width='38' height='18'/%3E%3Crect x='-19' y='21' width='38' height='18'/%3E%3Crect x='21' y='21' width='38' height='18'/%3E%3Crect x='61' y='21' width='38' height='18'/%3E%3C/g%3E%3C/svg%3E"); }

/* -- 2. L'outil de recherche ---------------------------------------------- */
.bib-label { display: block; font-weight: 700; font-size: 15px; color: var(--ink); margin: 0 0 8px; }
.bib-champ { position: relative; }
.bib-input {
  width: 100%; padding: 17px 22px; font: 500 17px/1.3 var(--f-sans); color: var(--ink);
  background: var(--paper); border: 2px solid var(--line); border-radius: 999px;
}
.bib-input:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 2px; border-color: var(--em-800); }
.bib-effacer { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); border: 0; background: var(--em-50); color: var(--em-800); font: 600 13px var(--f-sans); padding: 8px 14px; border-radius: 999px; cursor: pointer; }
.bib-aide { margin: 12px 0 0; font-size: 14px; color: var(--ink-2); line-height: 1.9; }
.bib-aide button { font: 600 13.5px var(--f-sans); margin: 0 6px 6px 0; padding: 7px 14px; border-radius: 999px; border: 1.5px solid var(--em-200); background: var(--paper); color: var(--em-800); cursor: pointer; }
.bib-aide button:hover { background: var(--em-50); }

.bib-guide { margin-top: 30px; padding: 22px; background: var(--paper); border: 1px solid var(--line); border-radius: 18px; }
.bib-guide-titre { margin-bottom: 14px; }
.bib-selects { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.bib-selects label { display: block; font-size: 13.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.bib-selects select {
  width: 100%; padding: 13px 40px 13px 16px; font: 500 15.5px var(--f-sans); color: var(--ink);
  border: 2px solid var(--line); border-radius: 14px; background: var(--canvas);
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none' stroke='%23065F46' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
}
.bib-selects select:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 2px; }

.bib-types-filtre { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.bib-filtre {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px 9px 12px; border-radius: 999px;
  border: 2px solid var(--line); background: var(--paper); font: 600 14px var(--f-sans); color: var(--ink); cursor: pointer;
}
.bib-filtre i { width: 14px; height: 14px; border-radius: 4px; background: var(--bg); border: 1.5px solid rgba(0,0,0,.25); display: inline-block; }
.bib-filtre[aria-pressed="true"] { border-color: var(--bg); background: var(--em-50); box-shadow: inset 0 0 0 1px var(--bg); }
.bib-filtre:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 2px; }

/* -- 3. Résultats : les cartes --------------------------------------------- */
.bib-res-titre { margin-bottom: 6px; }
.bib-compte { margin: 0 0 20px; color: var(--ink-2); font-size: 15px; }
.bib-grille { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(290px, 100%), 1fr)); }
.cap {
  position: relative; overflow: hidden; isolation: isolate;
  display: flex; flex-direction: column; gap: 10px; padding: 22px 22px 18px; min-height: 250px;
  background-color: var(--bg); color: var(--fg); border-radius: 18px; text-decoration: none;
  box-shadow: 0 10px 22px -16px rgba(0,0,0,.6);
  transition: transform .15s ease, box-shadow .15s ease;
}
a.cap:hover { transform: translateY(-3px); box-shadow: 0 16px 26px -16px rgba(0,0,0,.7); }
a.cap:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 3px; }
.cap-num { position: absolute !important; right: 14px; top: -6px; font: 500 96px/1 var(--f-mono); letter-spacing: -.06em; color: var(--ghost); z-index: -1; }
.cap-band { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.cap-pill { font: 500 11.5px/1 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; padding: 6px 10px; border-radius: 999px; background: var(--pill); color: var(--pillfg); }
.cap-pill.p-achat { background: var(--em-800); }
.cap-pill.p-pme { background: var(--em-800); }
.t-paire .cap-pill.p-pme { background: var(--cap-em-950); }
.cap h3 { margin: 4px 0 0; font: 700 20px/1.2 var(--f-titre); color: inherit; letter-spacing: -.005em; }
.cap-hook { margin: 0; font-size: 14.5px; line-height: 1.5; color: var(--mu); }
.cap-hook b { font-weight: 700; color: var(--fg); }
.cap-meta { margin-top: auto; font-size: 12.5px; font-weight: 600; color: var(--mu); padding-top: 6px; border-top: 1px solid currentColor; border-top-color: rgba(255,255,255,.22); display: flex; justify-content: space-between; gap: 10px; }
.t-loi .cap-meta { border-top-color: rgba(59,21,48,.25); }
.cap-meta span:last-child { font-weight: 700; color: var(--fg); white-space: nowrap; }
.cap-afaire { opacity: .92; }
.cap-afaire .cap-meta span:last-child { font-weight: 600; }
.cap-theme { background: var(--cap-lilas); color: var(--cap-vin-900); }
/* Loi expliquée : la référence de l'article, en pilule blanche sur le lilas. */
.cap-texte { background: #fff; color: var(--cap-vin-900); }
/* Régime (classiques, spéciaux ou les deux) : pilule au trait, couleur du
   texte de la carte, lisible sur les quatre fonds. */
.cap-regime { background: transparent; color: var(--fg); box-shadow: inset 0 0 0 1px currentColor; }
/* Recherche : deuxième rangée (régime, procédure) et lien d'aide (2026-10-01). */
.bib-guide-suite { margin-top: 22px; }
.bib-guide-aide { margin: 12px 0 0; font-size: 14px; color: var(--ink-2); }
.bib-guide-aide a { display: inline-block; padding-block: 13px; margin-block: -13px; font-weight: 700; color: var(--em-800); text-underline-offset: 3px; } /* 44 px au toucher (tests du 2026-10-01) */
/* Carte d'une procédure quand une procédure est choisie : « Quand l'envisager ». */
.cap-quand { margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--fg); }
.cap-quand b { font-weight: 700; }
/* Sur la page, « L'exemple » est un texte long : encadré lilas (le blanc
   disparaîtrait sur le fond de page), graisse normale. */
.cap-page.t-loi .cap-reflexe { background: var(--cap-lilas); }
.cap-page.t-loi .cap-reflexe p { font-weight: 500; }
.bib-plus { text-align: center; margin: 26px 0 0; }
.bib-vide { padding: 28px; border: 2px dashed var(--line); border-radius: 18px; background: var(--paper); color: var(--ink-2); }
.bib-vide strong { color: var(--ink); }

/* -- 4. Parcours ---------------------------------------------------------- */
.bib-parcours-grille { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.bib-parcours-carte { text-align: left; cursor: pointer; border: 2px solid var(--line); background: var(--paper); border-radius: 18px; padding: 20px 20px 18px; font: inherit; color: var(--ink); }
.bib-parcours-carte:hover { border-color: var(--em-800); }
.bib-parcours-carte:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 3px; }
.bib-parcours-carte strong { display: block; font: 700 18px/1.25 var(--f-sans); color: var(--em-800); margin-bottom: 6px; }
.bib-parcours-carte span { font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.bib-mention { text-align: center; font-style: italic; color: var(--ink-2); font-size: 14px; margin: 0 var(--gut) 40px; }

/* -- Page d'une capsule ---------------------------------------------------- */
.cap-page { max-width: 880px; margin: 0 auto; }
.cap-tete {
  position: relative; overflow: hidden; isolation: isolate; border-radius: 22px 22px 0 0;
  background-color: var(--bg); color: var(--fg); padding: 34px clamp(20px, 5vw, 44px) 30px;
}
.cap-tete::before { content: ""; position: absolute; inset: 0; pointer-events: none; background-repeat: repeat; z-index: -1; }
.cap-tete .cap-num { font-size: 220px; right: 10px; top: -30px; }
/* Fil rouge de la fiche (charte Perpens § 4) : du haut de la carte jusqu'au
   niveau de l'accroche ; c'est le seul de la page (pas de fil dans l'en-tête mini). */
.cap-tete > .fil-rouge { left: 16px; bottom: 42px; }
@media (max-width: 599px) { .cap-tete > .fil-rouge { left: 9px; } }
/* Achat (vert moyen, corail peu contrasté) : fil épaissi ; Loi (lilas) : corail foncé. */
.cap-tete.t-achat > .fil-rouge { width: 5px; margin-left: -2.5px; }
.cap-tete.t-achat > .fil-rouge::after { width: 18px; height: 18px; margin-left: -9px; bottom: -18px; }
.cap-tete.t-achat > .fil-rouge { bottom: 48px; }
.cap-tete.t-loi > .fil-rouge, .cap-tete.t-loi > .fil-rouge::after { background: var(--coral-fil); }
.cap-tete h1 { margin: 18px 0 12px; font: 700 clamp(26px, 5vw, 38px)/1.15 var(--f-titre); letter-spacing: -.015em; color: inherit; max-width: 22em; }
.cap-tete .cap-hook { font-size: 18px; font-weight: 600; color: var(--fg); max-width: 34em; }
.cap-onglets { display: flex; gap: 8px; margin: 18px 0 0; }
.cap-onglet {
  font: 700 14px var(--f-sans); padding: 10px 18px; border-radius: 999px; cursor: pointer;
  border: 2px solid currentColor; background: transparent; color: var(--fg);
}
.cap-onglet[aria-selected="true"] { background: var(--fg); color: var(--bg); }
.cap-onglet:focus-visible { outline: 3px solid var(--fg); outline-offset: 3px; } /* audit T4 */
.cap-corps { background: var(--paper); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 22px 22px; padding: clamp(20px, 5vw, 40px); }
.cap-corps h2 { font: 700 13.5px/1 var(--f-sans); letter-spacing: .07em; text-transform: uppercase; color: var(--em-800); margin: 26px 0 10px; }
.cap-corps h2:first-child { margin-top: 0; }
.cap-corps p { margin: 0 0 12px; font-size: 17px; line-height: 1.6; max-width: 62ch; }
.cap-reflexe { margin: 28px 0 0; padding: 22px 24px; border-radius: 18px; background: var(--box); color: var(--boxfg); }
.cap-reflexe b.etiq { display: inline-block; background: var(--coral); color: var(--ink); font: 700 12.5px/1 var(--f-sans); letter-spacing: .05em; text-transform: uppercase; padding: 7px 12px; border-radius: 999px; margin-bottom: 12px; }
.cap-reflexe p { font-weight: 700; margin: 0; }
.cap-public { margin: 18px 0 0; padding: 18px 22px; border: 2px solid var(--coral); border-radius: 18px; background: var(--cap-corail-50); }
.cap-public b { display: block; font: 700 12.5px/1 var(--f-sans); letter-spacing: .05em; text-transform: uppercase; color: var(--cap-corail-ink); margin-bottom: 8px; }
.cap-public p { margin: 0; font-size: 16px; }
.cap-source { margin: 26px 0 0; font-size: 14.5px; color: var(--ink-2); }
.cap-mention { font-style: italic; font-size: 13.5px; color: var(--ink-2); margin: 4px 0 0; }
.cap-duo { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin-top: 6px; }
.cap-duo > div { border: 1px solid var(--line); border-radius: 18px; padding: 20px; background: var(--canvas); }
.cap-duo h3 { margin: 0 0 10px; font: 700 17px var(--f-sans); color: var(--em-800); }
.cap-duo p { font-size: 15.5px; }
.cap-duo .plum h3 { color: var(--cap-vin-800); }
.cap-pair { margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
.cap-pair button { all: unset; cursor: pointer; font-weight: 700; color: var(--em-800); text-decoration: underline; text-underline-offset: 3px; }
.cap-pair button:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 3px; }
.cap-voisines { margin-top: 44px; }
.cap-voisines h2 { font: 700 22px var(--f-titre); margin-bottom: 16px; }

@media (max-width: 560px) {
  .cap { min-height: 0; }
  .cap-tete .cap-num { font-size: 150px; }
  .bib-guide { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) { a.cap { transition: none; } a.cap:hover { transform: none; } }
.bib-type .cap-pill { align-self: flex-start; }
.bib-outil { padding-bottom: 12px; }
.bib-resultats { padding-top: 28px; }
.bib-types { padding-bottom: 12px; }
.t-nego .cap-corps h2 { color: var(--cap-vin-700); }
.t-loi .cap-corps h2, .t-loi .cap-duo h3 { color: var(--cap-vin-900); }
.t-achat .cap-corps h2:first-child + p { font-style: italic; }
.cap-public + .cap-source { margin-top: 22px; }

/* Décision du 2026-09-25 : sur téléphone, les listes déroulantes passent avant la question libre. */
.bib-outil { display: flex; flex-direction: column; }
.bib-outil > h2 { order: 0; }
.bib-recherche { order: 1; }
.bib-guide { order: 2; }
.bib-types-filtre { order: 3; }
@media (max-width: 760px) {
  .bib-guide { order: 1; margin-top: 0; margin-bottom: 26px; }
  .bib-recherche { order: 2; }
}

/* Version publiable : les onglets sont des liens entre deux pages. */
.cap-onglet { text-decoration: none; display: inline-block; }
.cap-onglet[aria-current="page"] { background: var(--fg); color: var(--bg); }
a.cap-onglet:hover { background: rgba(255,255,255,.14); }
.cap-pair a { font-weight: 700; color: var(--em-800); text-underline-offset: 3px; }
.bib-niveaux p { max-width: 70ch; color: var(--ink-2); }

/* Pont vers un questionnaire gratuit, en bas de capsule (2026-09-26). */
.cap-suite { margin-top: 18px; font-size: 14.5px; color: var(--ink-2); }
.cap-suite a { font-weight: 700; color: var(--em-800); text-underline-offset: 3px; }

/* Sur téléphone, la recherche et ses résultats passent avant les quatre
   cartes de type : empilées, elles repoussaient la recherche à ~2 000 px
   (analyse du 26/09). */
@media (max-width: 560px) {
  .bib-flux:has(> .bib-outil) { display: flex; flex-direction: column; }
  .bib-flux > .bib-outil     { order: 1; }
  .bib-flux > .bib-resultats { order: 2; }
  .bib-flux > .bib-types     { order: 3; }
  .bib-flux > .bib-niveaux   { order: 4; }
  .bib-flux > .bib-lettre    { order: 5; }
  .bib-flux > .bib-mention   { order: 6; }
}

/* == Refonte premium : structure de page (2026-09-27) ====================== */
.bib-sheet { padding: var(--s7) 0; }
@media (min-width: 768px) { .bib-sheet { padding: var(--s8) 0; } }
.bib-flux > .section { padding: 0 0 var(--s7); }
.bib-flux > .section:last-child { padding-bottom: 0; }
.bib-flux > .section > h2 { margin-bottom: var(--s5); }
.bib-mention { margin: 0 0 var(--s2); }
/* En-tête d'une page capsule : seulement le retour à la bibliothèque */
.bib-head-mini { padding: var(--s2) 0 var(--s5); }
.page-head .label .bib-retour {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px;
  color: var(--tx); text-decoration: none; letter-spacing: .06em;
}
.page-head .label .bib-retour:hover { text-decoration: underline; text-underline-offset: 4px; }
/* Fil d'Ariane à trois niveaux (Accueil › Entreprises › Bibliothèque) : à
   320 px il dépassait de 19 px ; il passe désormais à la ligne. */
.page-head nav.label { flex-wrap: wrap; row-gap: 0; }
/* Cartes de capsule : même profondeur que les panneaux de la refonte */
.cap, .bib-type { border-radius: var(--r-lg); }
a.cap { transition: transform var(--t-in) var(--ease), box-shadow var(--t-in) var(--ease); }
a.cap:hover { transform: translateY(-4px); box-shadow: var(--sh-paper-lift); }
.cap-tete { border-radius: var(--r-lg) var(--r-lg) 0 0; }
.cap-corps { border-radius: 0 0 var(--r-lg) var(--r-lg); }
.cap-corps h2 { font: 500 .78rem/1.2 var(--f-mono); letter-spacing: .08em; }
.bib-guide, .bib-vide { border-radius: var(--r-lg); }
.bib-selects select { min-height: 48px; border-color: var(--line-strong); border-width: 1.5px; }
.bib-filtre { min-height: 44px; }
.bib-type button { min-height: 44px; }
.cap-onglet { min-height: 44px; display: inline-flex; align-items: center; white-space: nowrap; flex: none; }
.cap-onglets { flex-wrap: wrap; }
@media (max-width: 420px) { .cap-onglet { padding: 10px 14px; } }
/* « Source » était collée à l'encadré : .cap-corps p (plus spécifique) annulait sa marge */
.cap-corps .cap-source { margin-top: 26px; }
.cap-corps .cap-source + .cap-source { margin-top: 4px; }

/* Écrans tactiles : pas de carte qui reste soulevée après un toucher
   (même règle que refonte.css, section 20). */
@media (hover: none) { a.cap:hover { transform: none; box-shadow: 0 10px 22px -16px rgba(0,0,0,.6); } }
/* Mouvement réduit : placé en fin de feuille, sinon la règle a.cap:hover
   plus haut l'emporte (tests du 2026-09-27). */
@media (prefers-reduced-motion: reduce) { a.cap:hover { transform: none; } }

/* Sans JavaScript, les questions guidées ne peuvent rien filtrer : masquées
   (relecture du 2026-09-29). Les cartes restent toutes affichées. */
html:not(.js) .bib-guide { display: none; }

/* Encart « Recevoir les nouvelles capsules » (lettre d'information, 2026-09-29). */
.bib-lettre p { max-width: 60ch; color: var(--ink-2); }

/* == Bibliothèque en deux couloirs (décision du 2026-10-02, EXPERIENCE.md § 11) ==
   Aiguillage (bibliotheque.html), étapes repliables des bibliothèques
   Entreprises et Acheteurs, lien discret vers l'autre côté sur les capsules. */
a.bib-parcours-carte { display: block; text-decoration: none; }
a.bib-parcours-carte.plum strong { color: var(--plum-700); }
a.bib-parcours-carte.plum:hover { border-color: var(--plum-500); }
.bib-portes-suite, .bib-etapes-aide { color: var(--ink-2); margin: 14px 0 0; }
.bib-etapes-aide { margin: 0 0 14px; }
.bib-etape { border: 1px solid var(--line); border-radius: var(--r-md); background: var(--paper); margin: 0 0 12px; }
.bib-etape > summary {
  display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 14px 20px;
  cursor: pointer; list-style: none; font: 700 18px/1.3 var(--f-sans); color: var(--ink);
}
.bib-etape > summary::-webkit-details-marker { display: none; }
.bib-etape > summary::after { content: "+"; flex: none; width: 1ch; font: 400 24px/1 var(--f-mono); color: var(--em-800); }
.bib-etape[open] > summary::after { content: "−"; }
.bib-etape > summary:hover { color: var(--em-800); }
.bib-etape > summary:focus-visible { outline: 3px solid var(--coral-ink); outline-offset: 2px; border-radius: var(--r-md); }
.bib-etape-nom { flex: 1; }
.bib-etape-nb { font: 500 var(--fs-small)/1.3 var(--f-mono); color: var(--ink-2); white-space: nowrap; }
.bib-etape > .bib-grille { padding: 4px 20px 20px; }
.bib-etape-offre { padding: 0 20px 16px; margin: 0; font-weight: 600; }
.bib-etape-offre a { display: inline-block; padding-block: 12px; color: var(--em-800); }
.parcours-ach .bib-etape > summary::after,
.parcours-ach .bib-etape > summary:hover { color: var(--plum-700); }
@media (max-width: 480px) {
  .bib-etape > summary { padding: 12px 14px; font-size: 16.5px; }
  .bib-etape > .bib-grille { padding: 4px 12px 14px; }
  .bib-etape-offre { padding: 0 14px 12px; }
}
/* Lien vers l'autre côté : discret, après l'appel vers l'offre. */
.cap-pair { font-size: 15px; color: var(--ink-2); }
.cap-pair a { display: inline-block; padding-block: 12px; }

/* Listes déroulantes de « Trouver la capsule qui vous concerne » (2026-10-02) :
   la page déclare color-scheme: dark (en-tête nuit), si bien que le navigateur
   ouvrait la liste des choix en sombre, texte foncé sur fond foncé. La feuille
   claire repasse en schéma clair ; les choix ont un fond et un texte explicites. */
.bib-sheet { color-scheme: light; }
.bib-selects select option { background-color: var(--paper); color: var(--ink); }
.bib-selects select option:checked { background-color: var(--em-50); color: var(--em-800); }
