/* ==========================================================================
   CNIPLC — identité visuelle
   Palette relevée sur le sceau : rouge #D72123, or #C9A227, noir.
   Le rouge ne sert qu'au sceau, à l'alerte et à l'action de signalement.
   ========================================================================== */

:root {
  --encre:      #14161A;
  --encre-douce:#3A3F47;
  --pierre:     #6B6F76;
  --papier:     #FCFCFA;
  --papier-2:   #F4F2EC;
  --filet:      #DEDAD0;
  --rouge:      #D72123;
  --rouge-fonce:#A5171A;
  --or:         #C9A227;        /* filets, éléments décoratifs */
  --or-texte:   #8A6D10;        /* or lisible sur papier — contraste AA */
  --or-clair:   #E7D9A8;

  --serif: "Marcellus", "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --page: 1180px;
  --lisible: 68ch;
  --gouttiere: clamp(1.15rem, 4vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; line-height: 1.16; margin: 0; }
h1 { font-size: clamp(2.05rem, 5vw, 3.35rem); letter-spacing: -0.015em; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
h3 { font-size: clamp(1.18rem, 2.2vw, 1.42rem); }
p { margin: 0 0 1.15em; }

a { color: var(--encre); text-underline-offset: 3px; text-decoration-color: var(--or); }
a:hover { color: var(--rouge-fonce); }

:focus-visible { outline: 3px solid var(--rouge); outline-offset: 3px; border-radius: 2px; }

img { max-width: 100%; height: auto; display: block; }

/* ---------- Ossature ---------- */
.enveloppe { width: 100%; max-width: var(--page); margin-inline: auto; padding-inline: var(--gouttiere); }
.etroit { max-width: var(--lisible); }

.evitement {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--encre); color: #fff; padding: .85rem 1.3rem; font-weight: 600;
}
.evitement:focus { left: .5rem; top: .5rem; }

/* ---------- Bandeau République ---------- */
.republique {
  background: var(--encre); color: #E9E7E1;
  font-size: .78rem; letter-spacing: .03em;
}
.republique .enveloppe { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; justify-content: space-between; padding-block: .5rem; }
.republique a { color: #E9E7E1; }

/* ---------- En-tête ---------- */
.entete { background: var(--papier); border-bottom: 1px solid var(--filet); }
.entete-corps { display: flex; align-items: center; gap: 1rem; padding-block: 1.05rem; }

.marque { display: flex; align-items: center; gap: .9rem; text-decoration: none; flex: 1; min-width: 0; }
.marque img { width: 58px; height: auto; flex: none; }
.marque-texte { display: flex; flex-direction: column; min-width: 0; }
.marque-nom { font-family: var(--serif); font-size: 1.02rem; line-height: 1.22; color: var(--encre); }
.marque-sous { font-size: .73rem; color: var(--pierre); letter-spacing: .04em; margin-top: .15rem; }

/* ---------- Navigation ---------- */
.nav-bascule {
  display: none; align-items: center; gap: .55rem;
  background: none; border: 1px solid var(--filet); border-radius: 3px;
  padding: .6rem .8rem; font: inherit; font-size: .84rem; color: var(--encre); cursor: pointer;
}
.nav-bascule svg { width: 20px; height: 20px; }

.nav { display: flex; align-items: center; gap: clamp(.8rem, 1.5vw, 1.5rem); }
.nav a { font-size: .9rem; text-decoration: none; padding-block: .3rem; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--or); }

/* Bouton signaler : le seul élément rouge de la navigation. */
.bouton-signaler {
  background: var(--rouge); color: #fff !important; border-radius: 3px;
  padding: .62rem 1.15rem !important; font-weight: 600; border-bottom: none !important;
}
.bouton-signaler:hover { background: var(--rouge-fonce); color: #fff !important; }

@media (max-width: 900px) {
  .nav-bascule { display: inline-flex; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--papier); border-bottom: 1px solid var(--filet);
    box-shadow: 0 18px 30px -22px rgba(20,22,26,.4); padding: .5rem var(--gouttiere) 1.1rem; z-index: 40;
  }
  .nav[data-ouvert="true"] { display: flex; }
  .nav a { padding: .92rem 0; border-bottom: 1px solid var(--filet); }
  .nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--filet); color: var(--rouge-fonce); }
  .bouton-signaler { text-align: center; margin-top: .85rem; border-radius: 3px; }
  .entete-corps { position: relative; }
}

/* ---------- Boutons ---------- */
.bouton {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .82rem 1.5rem; border-radius: 3px; font-weight: 600; font-size: .95rem;
  text-decoration: none; border: 1px solid transparent; cursor: pointer; font-family: inherit;
}
.bouton-primaire { background: var(--rouge); color: #fff; }
.bouton-primaire:hover { background: var(--rouge-fonce); color: #fff; }
.bouton-second { background: transparent; color: var(--encre); border-color: var(--encre); }
.bouton-second:hover { background: var(--encre); color: var(--papier); }

/* ---------- Hero ---------- */
.hero { border-bottom: 1px solid var(--filet); background: var(--papier); }
.hero .enveloppe { padding-block: clamp(3rem, 8vw, 5.5rem); text-align: center; }
.hero-sceau { width: clamp(96px, 16vw, 132px); margin: 0 auto clamp(1.3rem, 3vw, 2rem); }
.hero h1 { max-width: 19ch; margin-inline: auto; }

/* Filet doré : rappel discret du laurier du sceau. */
.filet-or { width: 92px; height: 2px; background: var(--or); margin: 1.5rem auto; border: 0; }
.filet-or.gauche { margin-inline: 0; }

.hero-texte { max-width: 60ch; margin: 0 auto 2rem; color: var(--encre-douce); font-size: 1.11rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; justify-content: center; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(3rem, 7vw, 5rem); }
.section-alt { background: var(--papier-2); border-block: 1px solid var(--filet); }
.section-titre { margin-bottom: 2.2rem; }
.section-titre p { color: var(--pierre); margin-top: .7rem; max-width: 56ch; }

/* ---------- Actualité à la une ---------- */
.une { display: grid; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; }
@media (min-width: 860px) { .une { grid-template-columns: 1.15fr 1fr; } }
.une-image { aspect-ratio: 4 / 3; overflow: hidden; background: var(--papier-2); }
.une-image img { width: 100%; height: 100%; object-fit: cover; }
.une-date, .carte-date { font-size: .8rem; color: var(--pierre); letter-spacing: .02em; }
.une h3 { font-size: clamp(1.4rem, 3vw, 1.95rem); margin: .6rem 0 .9rem; }
.une p { color: var(--encre-douce); }

/* ---------- Grille d'actualités ---------- */
.grille { display: grid; gap: clamp(1.5rem, 3vw, 2.4rem); }
@media (min-width: 620px) { .grille { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .grille-3 { grid-template-columns: repeat(3, 1fr); } }

.carte { display: flex; flex-direction: column; }
.carte-image { aspect-ratio: 3 / 2; overflow: hidden; background: var(--papier-2); margin-bottom: .95rem; }
.carte-image img { width: 100%; height: 100%; object-fit: cover; }
.carte h3 { font-size: 1.14rem; margin: .45rem 0 .55rem; }
.carte h3 a { text-decoration: none; }
.carte h3 a:hover { text-decoration: underline; }
.carte p { font-size: .94rem; color: var(--encre-douce); margin: 0; }

/* ---------- Missions ---------- */
.missions { display: grid; gap: 1px; background: var(--filet); border: 1px solid var(--filet); }
@media (min-width: 760px) { .missions { grid-template-columns: repeat(3, 1fr); } }
.mission { background: var(--papier); padding: clamp(1.5rem, 3vw, 2.2rem); }
.mission h3 { margin-bottom: .6rem; }
.mission p { color: var(--encre-douce); font-size: .96rem; margin: 0; }
.mission-chiffre { font-family: var(--serif); font-size: 2.1rem; color: var(--or-texte); display: block; margin-bottom: .5rem; }

/* ---------- Appel au signalement ---------- */
.appel { background: var(--encre); color: #F2F0EA; }
.appel .enveloppe { padding-block: clamp(3rem, 7vw, 4.5rem); text-align: center; }
.appel h2 { color: #fff; }
.appel p { color: #C9C6BE; max-width: 58ch; margin-inline: auto; }
.appel .filet-or { margin-block: 1.4rem; }

/* ---------- Documents ---------- */
.documents { border-top: 1px solid var(--filet); }
.document {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.05rem 0; border-bottom: 1px solid var(--filet); text-decoration: none;
}
.document:hover { background: var(--papier-2); }
.document svg { width: 22px; height: 22px; color: var(--rouge); flex: none; }
.document-titre { flex: 1; font-size: .98rem; }
.document-poids { font-size: .82rem; color: var(--pierre); flex: none; }

/* ---------- Article ---------- */
.article-entete { border-bottom: 1px solid var(--filet); padding-block: clamp(2.2rem, 5vw, 3.5rem); }
.article-corps { padding-block: clamp(2rem, 5vw, 3rem); font-size: 1.09rem; }
.article-corps p { max-width: var(--lisible); }
.article-galerie { display: grid; gap: 1rem; margin-block: 2rem; }
@media (min-width: 700px) { .article-galerie { grid-template-columns: repeat(2, 1fr); } }
.article-galerie img { width: 100%; }

/* ---------- Prose institutionnelle ---------- */
.prose { max-width: var(--lisible); }
.prose p { color: var(--encre-douce); }
.prose > p:first-of-type { font-size: 1.14rem; color: var(--encre); }

/* ---------- Formulaire ---------- */
.champ { margin-bottom: 1.5rem; }
.champ label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .2rem; }
.champ .aide { font-size: .86rem; color: var(--pierre); margin-bottom: .55rem; }
.champ input, .champ select, .champ textarea {
  width: 100%; padding: .8rem .9rem; font: inherit; font-size: 1rem;
  border: 1px solid var(--filet); border-radius: 3px; background: #fff; color: var(--encre);
}
.champ textarea { min-height: 13rem; resize: vertical; line-height: 1.6; }
.champ input:focus, .champ select:focus, .champ textarea:focus { border-color: var(--encre); }
.erreur { color: var(--rouge-fonce); font-size: .88rem; margin-top: .4rem; font-weight: 500; }

.encadre {
  border: 1px solid var(--filet); border-left: 3px solid var(--or);
  background: var(--papier-2); padding: 1.3rem 1.5rem; margin-bottom: 2rem;
}
.encadre p:last-child { margin-bottom: 0; }
.encadre h3 { font-size: 1.1rem; margin-bottom: .6rem; }

.reference {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: clamp(1.5rem, 4vw, 2rem); letter-spacing: .09em;
  background: var(--papier-2); border: 1px dashed var(--or);
  padding: 1.1rem 1.4rem; display: inline-block; margin: 1rem 0;
}

/* ---------- Pied de page ---------- */
.pied { background: var(--encre); color: #B9B6AE; font-size: .92rem; }
.pied .enveloppe { padding-block: clamp(2.5rem, 5vw, 3.5rem); }
.pied-grille { display: grid; gap: 2rem; }
@media (min-width: 720px) { .pied-grille { grid-template-columns: 1.4fr 1fr 1fr; } }
.pied h3 { color: #fff; font-size: 1.02rem; margin-bottom: .9rem; }
.pied a { color: #B9B6AE; text-decoration: none; }
.pied a:hover { color: #fff; text-decoration: underline; }
.pied ul { list-style: none; margin: 0; padding: 0; }
.pied li { margin-bottom: .5rem; }
.pied-bas {
  border-top: 1px solid #2C2F35; margin-top: 2.5rem; padding-top: 1.4rem;
  display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; justify-content: space-between; font-size: .85rem;
}
.pied-logo { width: 52px; margin-bottom: 1rem; }

/* En dessous du grand écran, le sigle remplace la raison sociale complète :
   la navigation compte six entrées et le nom entier ne tient plus sur une ligne. */
.marque-court { display: none; }
@media (max-width: 1150px) {
  .marque-long { display: none; }
  .marque-court { display: block; font-size: 1.45rem; letter-spacing: .06em; }
}
@media (max-width: 900px) {
  .marque-court { font-size: 1.35rem; }
  .marque img { width: 46px; }
}

/* ==========================================================================
   Carrousel — les travaux de la Commission en ouverture de page
   ========================================================================== */
.carrousel { position: relative; background: var(--encre); overflow: hidden; }

/* Les bannières sont au ratio 1600x766 : la piste le respecte pour ne
   rogner aucun texte incrusté, avec un plafond sur très grand écran. */
.carrousel-piste { position: relative; aspect-ratio: 1600 / 766; }

/* Au-delà de la largeur de page, la bannière est centrée plutôt qu'étirée. */
@media (min-width: 1400px) {
  .carrousel-piste { max-width: 1400px; margin-inline: auto; }
}

.diapo {
  position: absolute; inset: 0; opacity: 0; visibility: hidden;
  /* visibility est différée le temps du fondu, sinon la diapositive
     disparaît avant la fin de la transition d'opacité. */
  transition: opacity .7s ease, visibility 0s linear .7s;
}
.diapo-active {
  opacity: 1; visibility: visible; z-index: 1;
  transition: opacity .7s ease, visibility 0s linear 0s;
}

/* Les visuels portent leur propre titre incrusté : pas de voile ni de
   texte superposé, l'image est montrée telle quelle. */
.diapo img {
  width: 100%; height: 100%; object-fit: cover; object-position: center;
}

.carrousel-fleche {
  position: absolute; top: calc(50% - 2.5rem); z-index: 3;
  display: grid; place-items: center;
  width: 46px; height: 46px; padding: 0;
  background: rgba(20,22,26,.55); color: #fff;
  border: 1px solid rgba(255,255,255,.35); border-radius: 50%; cursor: pointer;
}
.carrousel-fleche:hover { background: var(--rouge); border-color: var(--rouge); }
.carrousel-fleche svg { width: 22px; height: 22px; }
.carrousel-prec { left: clamp(.6rem, 2vw, 1.4rem); }
.carrousel-suiv { right: clamp(.6rem, 2vw, 1.4rem); }

.carrousel-pieds {
  position: absolute; inset: auto 0 0 0; z-index: 4;
  display: flex; align-items: center; justify-content: center; gap: 1rem;
  padding-block: .7rem;
  background: linear-gradient(to top, rgba(20,22,26,.75), transparent);
}
.carrousel-puces { display: flex; gap: .5rem; }
.puce {
  width: 34px; height: 4px; padding: 0; border: 0; cursor: pointer;
  background: rgba(255,255,255,.4);
}
.puce-active { background: var(--or); }
.puce:hover { background: #fff; }

.carrousel-pause {
  display: grid; place-items: center; width: 30px; height: 30px; padding: 0;
  background: transparent; border: 1px solid rgba(255,255,255,.35);
  border-radius: 50%; color: #fff; cursor: pointer;
}
.carrousel-pause:hover { border-color: #fff; }
.carrousel-pause svg { width: 13px; height: 13px; }

@media (max-width: 620px) {
  .carrousel-fleche { width: 38px; height: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  .diapo { transition: none; }
}

/* Document : un PDF à télécharger, ou un renvoi vers la source officielle. */
.document-titre { flex: 1; font-size: .98rem; line-height: 1.45; }
.document-note { display: block; font-size: .8rem; color: var(--pierre); margin-top: .15rem; }
.document .icone-lien { color: var(--pierre); }
.document-poids { white-space: nowrap; }

/* Rubrique du catalogue documentaire */
.rubrique { padding-block: clamp(2rem, 4vw, 2.8rem); border-top: 1px solid var(--filet); }
.rubrique:first-of-type { border-top: 0; padding-top: 0; }
.rubrique-chapo { color: var(--pierre); max-width: 58ch; margin: .6rem 0 1.4rem; }

/* Sommaire du catalogue */
.sommaire { display: flex; flex-wrap: wrap; gap: .55rem; margin-bottom: 1rem; }
.sommaire a {
  display: inline-flex; align-items: baseline; gap: .45rem;
  padding: .5rem .9rem; border: 1px solid var(--filet); border-radius: 3px;
  font-size: .9rem; text-decoration: none; background: var(--papier);
}
.sommaire a:hover { border-color: var(--encre); }
.sommaire .compte { color: var(--pierre); font-size: .82rem; }

/* Citation d'un article de loi */
.citation {
  margin: 0; max-width: 58ch;
  border-left: 3px solid var(--or); padding-left: clamp(1.1rem, 3vw, 1.8rem);
}
.citation p {
  font-family: var(--serif); font-size: clamp(1.15rem, 2.4vw, 1.45rem);
  line-height: 1.5; color: var(--encre); margin-bottom: .9rem;
}
.citation cite {
  font-style: normal; font-size: .88rem; color: var(--pierre); display: block;
}

/* ---------- Signalement ---------- */
[hidden] { display: none !important; }

.encadre-alerte { border-left-color: var(--rouge); }
.encadre-alerte ul { margin: 0 0 .8rem; padding-left: 1.2rem; }
.encadre-alerte:focus { outline: none; }

/* Deux canaux de dépôt */
.canaux { display: grid; gap: 1px; background: var(--filet); border: 1px solid var(--filet); margin-bottom: clamp(2.5rem, 6vw, 4rem); }
@media (min-width: 760px) { .canaux:has(> .canal + .canal) { grid-template-columns: 1fr 1fr; } }
.canal { background: var(--papier); padding: clamp(1.5rem, 3vw, 2.2rem); display: flex; flex-direction: column; align-items: flex-start; }
.canal h3 { font-size: clamp(1.3rem, 2.6vw, 1.6rem); margin-bottom: .7rem; }
.canal .canal-surtitre { font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: var(--pierre); margin-bottom: .3rem; }
.canal p { color: var(--encre-douce); font-size: .97rem; }
.canal .canal-note { font-size: .86rem; color: var(--pierre); margin-top: auto; padding-top: .2rem; }
.canal-icone { width: 30px; height: 30px; color: var(--or-texte); margin-bottom: 1rem; }

/* Repère des étapes */
.etapes { list-style: none; margin: 0 0 2.2rem; padding: 0; display: flex; gap: .4rem; counter-reset: none; }
.etapes li {
  flex: 1; display: flex; flex-direction: column; gap: .45rem;
  font-size: .82rem; color: var(--pierre); border-top: 3px solid var(--filet); padding-top: .6rem;
}
.etapes-numero { font-family: var(--serif); font-size: 1.05rem; }
.etapes li.etapes-faite { border-top-color: var(--or); color: var(--encre-douce); }
.etapes li[aria-current="step"] { border-top-color: var(--encre); color: var(--encre); font-weight: 600; }
@media (max-width: 620px) {
  .etapes-nom { display: none; }
  .etapes li[aria-current="step"] .etapes-nom { display: inline; }
}

/* Étapes et questions */
.etape { border: 0; margin: 0 0 2.5rem; padding: 0; min-width: 0; }
.pas-a-pas .etape { margin-bottom: 1.5rem; }
.etape-titre { font-family: var(--serif); font-size: clamp(1.5rem, 3vw, 2rem); padding: 0; margin-bottom: 1.6rem; }
.etape-titre:focus { outline: none; }
.etape-numero { display: block; font-family: var(--sans); font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; color: var(--or-texte); margin-bottom: .35rem; }

fieldset.champ { border: 0; padding: 0; min-width: 0; }
.question { font-weight: 600; font-size: .95rem; padding: 0; margin-bottom: .55rem; }
.facultatif { font-weight: 400; color: var(--pierre); }
.champ textarea.court { min-height: 6.5rem; }

.choix { display: grid; gap: .6rem; }
@media (min-width: 620px) { .choix { grid-template-columns: repeat(2, 1fr); } }
.choix-ligne { display: flex; flex-wrap: wrap; }
.champ .choix-option {
  display: flex; gap: .75rem; align-items: flex-start; margin: 0;
  font-weight: 400; font-size: .97rem; cursor: pointer;
  border: 1px solid var(--filet); border-radius: 3px; background: #fff; padding: .85rem 1rem;
}
.champ .choix-option:hover { border-color: var(--pierre); }
.champ .choix-option:has(input:checked) { border-color: var(--encre); background: var(--papier-2); box-shadow: inset 0 0 0 1px var(--encre); }
.champ .choix-option:has(input:focus-visible) { outline: 3px solid var(--rouge); outline-offset: 2px; }
.champ .choix-option input { width: auto; margin: .2rem 0 0; accent-color: var(--encre); flex: none; }
.choix-detail { display: block; color: var(--pierre); font-size: .88rem; margin-top: .15rem; }
.champ .declaration { background: var(--papier-2); }

.conditionnel { margin: 1rem 0 0; padding-left: 1rem; border-left: 2px solid var(--or-clair); }

.champ input[type="file"] { background: var(--papier-2); border-style: dashed; cursor: pointer; }
.fichiers { list-style: none; margin: .6rem 0 0; padding: 0; font-size: .88rem; color: var(--encre-douce); }
.fichiers li { padding: .3rem 0; border-bottom: 1px solid var(--filet); overflow-wrap: anywhere; }
.fichiers .fichier-refuse { color: var(--rouge-fonce); }

/* Récapitulatif */
.recap { border: 1px solid var(--filet); margin-bottom: 1.8rem; }
.recap section { padding: 1.1rem 1.3rem; border-top: 1px solid var(--filet); }
.recap section:first-child { border-top: 0; }
.recap-entete { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: .6rem; }
.recap h3 { font-size: 1.08rem; margin: 0; }
.recap dl { margin: 0; display: grid; gap: .25rem 1.4rem; font-size: .93rem; }
@media (min-width: 680px) { .recap dl { grid-template-columns: minmax(12rem, 1fr) 2fr; } }
.recap dt { color: var(--pierre); }
.recap dd { margin: 0 0 .5rem; white-space: pre-line; overflow-wrap: anywhere; }
.recap dd.vide { color: var(--pierre); font-style: italic; }
.lien-bouton {
  background: none; border: 0; padding: 0; font: inherit; font-size: .88rem; cursor: pointer;
  color: var(--encre); text-decoration: underline; text-decoration-color: var(--or); text-underline-offset: 3px;
}
.lien-bouton:hover { color: var(--rouge-fonce); }

.etapes-nav { display: flex; flex-wrap: wrap; gap: .85rem; padding-top: 1.5rem; border-top: 1px solid var(--filet); }
.etapes-nav [data-suivant], .etapes-nav [data-envoyer] { margin-left: auto; }
.etapes-nav button:disabled { opacity: .65; cursor: progress; }

/* Résultat du suivi */
.etat-reference { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .85rem; color: var(--pierre); letter-spacing: .05em; margin-bottom: .4rem; }
.etat-dossier h3 { font-size: 1.35rem; }

/* ==========================================================================
   Parcours de signalement : décrire, comprendre, signaler
   ========================================================================== */
.parcours { scroll-margin-top: 2rem; }
.parcours > * { max-width: 52rem; }
.parcours [data-focus]:focus { outline: none; }

/* Le parcours se renouvelle en fondu ; la nouvelle étape monte légèrement. */
::view-transition-old(root) { animation: .22s ease both disparition; }
::view-transition-new(root) { animation: .38s cubic-bezier(.2,.7,.2,1) both apparition; }
@keyframes disparition { to { opacity: 0; } }
@keyframes apparition { from { opacity: 0; transform: translateY(10px); } }

/* --- Description ---------------------------------------------------------- */
.assistant-entete { display: flex; gap: 1.1rem; align-items: flex-start; margin-bottom: 1.4rem; }
.assistant-icone { width: 34px; height: 34px; color: var(--or-texte); flex: none; margin-top: .2rem; }
.assistant-entete h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: .45rem; }
.assistant-entete p { color: var(--encre-douce); margin: 0; max-width: 56ch; }

.assistant-saisie {
  position: relative; overflow: hidden;
  background: #fff; border: 1px solid var(--filet); border-radius: 4px;
  box-shadow: 0 1px 2px rgba(20,22,26,.04), 0 12px 32px -24px rgba(20,22,26,.35);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.assistant-saisie:focus-within { border-color: var(--encre); box-shadow: 0 0 0 1px var(--encre), 0 12px 32px -24px rgba(20,22,26,.45); }
.assistant-saisie textarea {
  display: block; width: 100%; border: 0; outline: 0; resize: none; background: transparent;
  padding: 1.15rem 1.25rem .5rem; font: inherit; font-size: 1.04rem; line-height: 1.65; color: var(--encre);
  min-height: 9.5rem; max-height: 26rem; field-sizing: content;
}
.assistant-saisie textarea::placeholder { color: #9A9DA3; }
.assistant-saisie textarea[aria-invalid="true"] { background: #FFF8F8; }

.assistant-pied {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .7rem .8rem .8rem 1.25rem;
}
.assistant-compteur { font-size: .8rem; color: var(--pierre); font-variant-numeric: tabular-nums; }
.assistant-compteur-limite { color: var(--rouge-fonce); }
.assistant-pied .bouton svg { transition: transform .2s ease; }
.assistant-pied .bouton:hover svg { transform: translateX(3px); }
.assistant-pied .bouton:disabled { opacity: .7; cursor: progress; }

/* Attente : un filet doré parcourt le bas de la zone de saisie. */
.assistant-progression { position: absolute; inset: auto 0 0 0; height: 2px; opacity: 0; transition: opacity .2s ease; }
.assistant-progression::after {
  content: ""; position: absolute; inset: 0; width: 35%;
  background: linear-gradient(90deg, transparent, var(--or), transparent);
  animation: balayage 1.4s ease-in-out infinite;
}
@keyframes balayage { from { transform: translateX(-100%); } to { transform: translateX(290%); } }
.assistant-occupe .assistant-progression { opacity: 1; }
.assistant-occupe textarea { color: var(--encre-douce); }

.assistant-attente { min-height: 1.6em; margin: .7rem 0 0; font-size: .9rem; color: var(--or-texte); }
.assistant-attente:not(:empty) { animation: apparition .3s ease both; }

.assistant-note {
  display: flex; gap: .6rem; align-items: flex-start;
  font-size: .86rem; color: var(--pierre); margin: .6rem 0 0;
}
.assistant-note svg { flex: none; margin-top: .2rem; }

.parcours-raccourci { margin: 2.2rem 0 0; padding-top: 1.3rem; border-top: 1px solid var(--filet); font-size: .92rem; }

/* --- Analyse -------------------------------------------------------------- */
.situation { margin: 0 0 1.8rem; }
.situation figcaption {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--pierre); margin-bottom: .5rem;
}
.situation figcaption a { text-transform: none; letter-spacing: 0; font-size: .88rem; }
.situation blockquote {
  margin: 0; padding: 1rem 1.2rem; background: var(--papier-2); border-radius: 4px;
  color: var(--encre-douce); white-space: pre-line; overflow-wrap: anywhere;
}

.verdict {
  --ton: var(--pierre);
  position: relative; background: #fff; border: 1px solid var(--filet); border-radius: 4px;
  padding: clamp(1.4rem, 3.5vw, 2.2rem); padding-left: calc(clamp(1.4rem, 3.5vw, 2.2rem) + 4px);
  box-shadow: 0 16px 40px -30px rgba(20,22,26,.45);
  animation: apparition .45s cubic-bezier(.2,.7,.2,1) both;
}
.verdict::before { content: ""; position: absolute; inset: -1px auto -1px -1px; width: 4px; border-radius: 4px 0 0 4px; background: var(--ton); }
.verdict-oui { --ton: var(--rouge); }
.verdict-incertain { --ton: var(--or); }
.verdict-indisponible { --ton: var(--filet); }

.verdict-surtitre { display: flex; align-items: center; gap: .55rem; font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: var(--pierre); margin-bottom: .55rem; }
.verdict-surtitre::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ton); }
.verdict h2 { font-size: clamp(1.45rem, 3.2vw, 2rem); margin-bottom: .5rem; }
.verdict-infraction { font-weight: 600; color: var(--encre); margin-bottom: 1rem; }
.verdict-texte { color: var(--encre-douce); white-space: pre-line; max-width: var(--lisible); }

.verdict-details { display: grid; gap: .2rem 1.5rem; margin: 0 0 1.2rem; font-size: .95rem; }
@media (min-width: 680px) { .verdict-details { grid-template-columns: 11rem 1fr; } }
.verdict-details dt { color: var(--pierre); }
.verdict-details dd { margin: 0 0 .6rem; white-space: pre-line; }

.verdict-sources { border-top: 1px solid var(--filet); margin-top: .4rem; }
.verdict-sources summary, .quand-meme summary {
  display: flex; align-items: center; gap: .6rem; cursor: pointer; list-style: none;
  padding: .9rem 0; font-weight: 600; font-size: .93rem;
}
.verdict-sources summary::-webkit-details-marker, .quand-meme summary::-webkit-details-marker { display: none; }
.verdict-sources summary::after, .quand-meme summary::after {
  content: ""; width: 7px; height: 7px; margin-left: auto; flex: none;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px); transition: transform .2s ease;
}
.verdict-sources[open] summary::after, .quand-meme[open] summary::after { transform: rotate(-135deg) translateY(-2px); }
.verdict-sources summary:hover, .quand-meme summary:hover { color: var(--rouge-fonce); }
.verdict-sources ul { list-style: none; margin: 0 0 .6rem; padding: 0; }
.verdict-sources li { padding: .2rem 0 1rem; }
.source-ref { font-size: .93rem; margin-bottom: .45rem; }
.verdict-sources blockquote {
  margin: 0; padding-left: 1rem; border-left: 2px solid var(--or-clair);
  font-size: .9rem; color: var(--encre-douce); white-space: pre-line;
}

.verdict-avertissement { font-size: .82rem; color: var(--pierre); margin: 1rem 0 0; padding-top: 1rem; border-top: 1px solid var(--filet); }

/* --- Suite : les canaux --------------------------------------------------- */
.suite { margin-top: clamp(2.5rem, 6vw, 3.8rem); }
.parcours > .suite:first-child { margin-top: 0; }
.suite > h2 { font-size: clamp(1.45rem, 3vw, 1.9rem); margin-bottom: .6rem; }
.suite-chapo { color: var(--encre-douce); max-width: 60ch; margin-bottom: 1.8rem; }
.suite .canaux { margin-bottom: clamp(2rem, 5vw, 3rem); }

.quand-meme { border-top: 1px solid var(--filet); border-bottom: 1px solid var(--filet); margin-top: 1.6rem; }
.quand-meme[open] { padding-bottom: 1.5rem; }
.quand-meme[open] summary { margin-bottom: 1rem; }

