/* =============================================================
   PLANCHE DU CORPS — Centre de réadaptation de Baicaotang
   Une seule famille, une seule casse, pas d'italique, pas de
   filets décoratifs. La hiérarchie tient au corps, à la graisse
   et à la couleur — rien d'autre.
   ============================================================= */

/* ---------- 1. Jetons ----------------------------------------------------- */
:root {
  --paper:     #FBFAF7;
  --paper-2:   #F4F2EC;
  --paper-3:   #ECE9E0;

  --ink:       #16241C;
  --ink-72:    rgba(22,36,28,.72);
  --ink-52:    rgba(22,36,28,.52);
  --ink-34:    rgba(22,36,28,.34);
  --line:      rgba(22,36,28,.11);
  --line-fort: rgba(22,36,28,.22);

  --vert:       #26AB3C;
  --vert-fonce: #177C29;
  --vert-pale:  #E3F3E5;
  --vert-halo:  rgba(38,171,60,.26);
  --rouge:      #E40718;
  --rouge-fonce:#B4050F;
  --ambre:      #D89216;

  /* Une famille, point. */
  /* Géométrique ronde, dans l'esprit des sites de cliniques */
  --texte: 'Poppins', 'Noto Sans Arabic', 'Century Gothic', 'Avenir Next', Avenir, 'Helvetica Neue', Arial, sans-serif;

  --gut:    clamp(1rem, 3.2vw, 3.25rem);
  --barre:  3.85rem;
  --radius: 4px;

  --ease:    cubic-bezier(.22,.61,.36,1);
  --ease-io: cubic-bezier(.65,0,.35,1);
}

/* ---------- 2. Socle ------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

html { height: 100%; }
body {
  margin: 0; height: 100%; overflow: hidden;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--texte);
  font-size: 16px; line-height: 1.7; font-weight: 400; letter-spacing: -.002em;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: none;
}
::selection { background: var(--vert); color: #fff; }
:focus-visible { outline: 2px solid var(--vert-fonce); outline-offset: 3px; }

/* ---------- 3. Typographie ------------------------------------------------ */
h1, h2, h3, h4 {
  font-family: inherit; font-weight: 600;
  letter-spacing: -.022em; line-height: 1.22; margin: 0; text-wrap: balance;
}
strong, b { font-weight: 600; }
em, i, cite { font-style: normal; }

/* Intitulé de rubrique : même famille, même casse, simplement plus discret */
.eyebrow {
  font-size: .88rem; font-weight: 600; color: var(--rouge-fonce);
  margin: 0 0 .75rem;
}
.lede { color: var(--ink-72); font-size: 1.06rem; max-width: 48ch; }

/* ---------- 4. Mise en page -----------------------------------------------
   `width: 100%` est indispensable : dans une colonne flex, une marge
   horizontale automatique annule l'étirement et la section se recroqueville
   sur son contenu. C'est ce qui rabougrissait toute la version bureau.  --- */
.shell {
  width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 var(--gut);
}

/* ---------- 5. Barre fixe ------------------------------------------------- */
.topbar {
  position: sticky; top: 0; z-index: 80;
  backdrop-filter: blur(16px) saturate(1.4);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-bottom: 1px solid var(--line);
}
.topbar__in {
  max-width: 1180px; margin: 0 auto; height: var(--barre);
  padding: 0 var(--gut); display: flex; align-items: center; gap: 1.25rem;
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: inherit; min-width: 0; flex: 1 1 auto; overflow: hidden; }
.brand__logo {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  object-fit: cover; background: #fff;
}
.brand__txt { display: flex; flex-direction: column; min-width: 0; }
.brand__mark { font-size: 1rem; font-weight: 600; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand__sub { font-size: .78rem; color: var(--ink-34); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.2; }

.compteur {
  display: flex; align-items: center; gap: .45rem; flex-shrink: 0;
  font-size: .88rem; color: var(--ink-52); white-space: nowrap;
}
.compteur b { color: var(--vert-fonce); font-weight: 600; font-variant-numeric: tabular-nums; }

.langues { display: flex; gap: .15rem; flex-shrink: 0; }
.langues button {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: inherit; font-size: .82rem; font-weight: 600; color: var(--ink-34);
  padding: .3rem .45rem; border-radius: var(--radius);
  transition: color .2s var(--ease), background .2s var(--ease);
}
.langues button:hover { color: var(--ink-72); }
.langues button[aria-pressed="true"] { color: var(--vert-fonce); background: var(--vert-pale); }
/* ---------- 6. Ouverture -------------------------------------------------- */
main {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column; overflow: hidden;
}
body { display: flex; flex-direction: column; }
.hero { flex: none; text-align: center; padding-block: clamp(.5rem, .9vw, .85rem) clamp(.35rem, .6vw, .6rem); }
.hero h1 { font-size: clamp(1.35rem, 1.9vw, 1.85rem); font-weight: 700; line-height: 1.2; max-width: 46ch; margin-inline: auto; }
.hero .lede { margin: .2rem auto 0; font-size: .94rem; line-height: 1.55; color: var(--ink-52); max-width: 92ch; }

/* ---------- 7. Atelier ---------------------------------------------------- */
.workbench { flex: 1; min-height: 0; display: flex; padding-block: 0 .35rem; }
.workbench__grid {
  flex: 1; min-height: 0;
  display: grid; gap: clamp(.9rem, 2.2vw, 2.2rem);
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch;
}

/* --- 7a. La planche : figée, tenant dans la hauteur d'écran --- */
.plate {
  height: 100%; min-height: 0;
  display: flex; flex-direction: column; gap: 0;
}
.plate__frame {
  --trait: rgba(22,36,28,.22);
  position: relative; flex: 1; min-height: 0;
  width: fit-content; max-width: 100%; margin-inline: auto;
  display: flex; flex-direction: column;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: .55rem .5rem .45rem;
  transition: background .5s var(--ease), border-color .5s var(--ease);
}

.plate__head { display: flex; align-items: center; gap: .7rem; padding: 0 .35rem .5rem; flex-shrink: 0; }
.plate__no, .plate__title { display: none; }

.viewswitch { margin-inline: auto; display: flex; gap: .2rem; }
.viewswitch button {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: inherit; font-size: .86rem; font-weight: 600;
  color: var(--ink-52); padding: .32rem .7rem; border-radius: var(--radius);
  transition: color .25s var(--ease), background .25s var(--ease);
}
.viewswitch button[aria-pressed="true"] { background: var(--vert); color: #fff; }
@media (hover: hover) { .viewswitch button:hover[aria-pressed="false"] { color: var(--ink); background: rgba(22,36,28,.06); } }

/* La scène tient le rapport de la planche : sa hauteur vient du flux, sa
   largeur s'en déduit. Le cadre l'épouse, sans colonne de vide autour. */
.figure-stage {
  position: relative; flex: 1; min-height: 0; display: flex;
  aspect-ratio: 366 / 883; width: auto; max-width: 100%; margin-inline: auto;
}
.figure { display: block; width: 100%; height: 100%; touch-action: manipulation; direction: ltr; }
.figure[hidden] { display: none; }
.plaque { opacity: 0; pointer-events: none; transition: opacity .6s var(--ease); }
.figure.a-image .plaque { opacity: 1; }

/* --- 7b. Zones cliquables --- */
.zone { cursor: pointer; }
.zone__aire {
  fill: var(--vert); fill-opacity: 0; stroke: none; pointer-events: all;
  transition: fill-opacity .22s var(--ease);
}
.zone__halo {
  fill: none; pointer-events: none;
  stroke: #fff; stroke-width: 0; stroke-opacity: .9; stroke-linejoin: round;
  transition: stroke-width .22s var(--ease);
}
.zone__trait {
  fill: none; pointer-events: none;
  stroke: var(--trait); stroke-width: .8; stroke-opacity: .34; stroke-linejoin: round;
  transition: stroke .22s var(--ease), stroke-width .22s var(--ease),
              stroke-opacity .22s var(--ease), opacity .3s var(--ease);
}
.figure:not(.a-image) .zone__aire { fill: #C9553F; fill-opacity: .9; }

.zone.est-visee .zone__aire { fill-opacity: .2; }
.zone.est-visee .zone__trait,
.zone:focus-visible .zone__trait { stroke: var(--vert-fonce); stroke-width: 1.6; stroke-opacity: 1; }
.zone.est-visee .zone__halo { stroke-width: 2.6; }
@media (hover: hover) {
  .zone:hover .zone__aire { fill-opacity: .2; }
  .zone:hover .zone__trait { stroke: var(--vert-fonce); stroke-width: 1.6; stroke-opacity: 1; }
  .zone:hover .zone__halo { stroke-width: 2.6; }
  }
.zone:focus-visible { outline: none; }

.zone.est-on .zone__aire  { fill-opacity: .46; }
.zone.est-on .zone__halo  { stroke-width: 4.2; stroke-opacity: .92; }
.zone.est-on .zone__trait { stroke: var(--vert-fonce); stroke-width: 1.9; stroke-opacity: 1; }
.zone.est-pale .zone__trait { opacity: .55; }

.zone.vient-de-changer .zone__halo  { animation: frappe-halo .68s var(--ease); }
.zone.vient-de-changer .zone__trait { animation: frappe-trait .68s var(--ease); }
@keyframes frappe-halo  { 0% { stroke-width: 13; stroke-opacity: 0; } 40% { stroke-width: 8; stroke-opacity: .85; } 100% { stroke-width: 4.2; } }
@keyframes frappe-trait { 0% { stroke-width: 3.4; } 100% { stroke-width: 1.9; } }

.figure.revele .zone__trait { animation: revelation 1.5s var(--ease) both; }
@keyframes revelation {
  0%   { stroke: rgba(38,171,60,0);   stroke-width: 1.7; }
  22%  { stroke: rgba(38,171,60,.95); stroke-width: 1.7; }
  100% { stroke: var(--trait);        stroke-width: .8; }
}
.figure.revele .zone.est-on .zone__trait { animation: none; }

/* Étiquette de survol */
.etiquette { pointer-events: none; opacity: 0; transition: opacity .15s var(--ease); }
.etiquette.est-la { opacity: 1; }
.etiquette__fond { fill: var(--ink); fill-opacity: .94; }
.etiquette__txt { font-family: var(--texte); font-size: 11.5px; font-weight: 600; fill: #fff; unicode-bidi: plaintext; }

/* --- 7c. Annotations de marge --- */
  stroke: var(--vert-fonce); stroke-width: 1; fill: none;
  stroke-dasharray: 240; stroke-dashoffset: 240; animation: trace .55s var(--ease) forwards;
}
@keyframes trace { to { stroke-dashoffset: 0; } }
  font-family: var(--texte); font-size: 11px; font-weight: 600; fill: var(--ink-72);
  unicode-bidi: plaintext; opacity: 0; animation: paraitre .5s var(--ease) .18s forwards;
}
@keyframes paraitre { to { opacity: 1; } }


/* ---------- 8. Dossier ---------------------------------------------------- */
/* Le contenu du dossier reste groupé à gauche de sa colonne : sur un grand
   écran, une largeur de lecture vaut mieux qu'un bandeau qui traverse. */
.dossier > * { max-width: 22rem; width: 100%; }
.dossier {
  min-width: 0; height: 100%; overflow-y: auto;
  -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  display: flex; flex-direction: column;
}
.section { margin-bottom: clamp(2rem, 4vw, 3rem); scroll-margin-top: calc(var(--barre) + 1rem); }
.section__head { margin-bottom: 1.2rem; }
.section__head h2 { font-size: clamp(1.2rem, 1.9vw, 1.5rem); font-weight: 600; margin-bottom: .45rem; }
.section__head p { margin: 0; color: var(--ink-52); font-size: .94rem; max-width: 56ch; }
.step { font-size: .88rem; font-weight: 600; color: var(--ink-34); display: block; margin-bottom: .35rem; }
.step b { color: var(--rouge); font-weight: 600; }


/* --- Jetons : la région choisie, découpée dans la planche --------------- */
.cards {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .4rem;
  align-content: start;
}
.jeton {
  position: relative; aspect-ratio: 1; padding: 0; cursor: pointer;
  border: 1px solid var(--line); border-radius: 12px; background: #fff;
  overflow: hidden; -webkit-tap-highlight-color: transparent;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
  animation: jeton-entre .3s var(--ease) both;
}
.jeton__vue { display: block; width: 100%; height: 100%; }
.jeton__voile { fill: var(--vert); fill-opacity: .18; stroke: none; }
.jeton__x {
  position: absolute; top: 3px; inset-inline-end: 3px;
  width: 17px; height: 17px; border-radius: 50%;
  background: rgba(251, 250, 247, .82);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  color: var(--ink-52); font-size: 12px; line-height: 17px; text-align: center;
}
.jeton__x::after { content: '\00d7'; }
.jeton.est-visee { border-color: var(--vert); box-shadow: 0 0 0 2px var(--vert-halo); }
@media (hover: hover) {
  .jeton:hover { border-color: var(--vert); transform: translateY(-1px); }
  .jeton:hover .jeton__x { background: var(--rouge); color: #fff; }
}
@keyframes jeton-entre { from { opacity: 0; transform: scale(.86); } to { opacity: 1; transform: none; } }





.input, .select, .textarea {
  width: 100%; background: #fff; border: 1px solid var(--line-fort); color: var(--ink);
  font-family: inherit; font-size: 1rem; padding: .62rem .75rem; border-radius: var(--radius);
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.textarea { resize: vertical; min-height: 5rem; line-height: 1.55; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--vert); box-shadow: 0 0 0 3px var(--vert-pale); }
.input::placeholder, .textarea::placeholder { color: var(--ink-34); }
.select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-52) 50%),
                    linear-gradient(135deg, var(--ink-52) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 2.2rem;
}

.card__drop {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: inherit; font-size: .88rem; color: var(--ink-34);
  padding: .25rem 0; flex-shrink: 0;
  transition: color .25s var(--ease);
}
@media (hover: hover) { .card__drop:hover { color: var(--rouge); } }

/* ---------- 9. Terrain ---------------------------------------------------- */
.terrain { display: grid; gap: .5rem; }
.terrain .card__no { color: var(--rouge-fonce); }

/* ---------- 10. Coordonnées ---------------------------------------------- */
.grid2 { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid2 .span2 { grid-column: 1 / -1; }
@media (max-width: 560px) { .grid2 { grid-template-columns: 1fr; } }
.field { display: block; }
.field + .field { margin-top: 1rem; }
.req { color: var(--rouge); }

/* ---------- 11. Boutons --------------------------------------------------- */
.btn {
  appearance: none; cursor: pointer; font-family: inherit;
  font-size: .96rem; font-weight: 600; padding: .72rem 1.4rem;
  border: 1px solid var(--vert); background: var(--vert); color: #fff;
  border-radius: var(--radius);
  transition: background .25s var(--ease), border-color .25s var(--ease), transform .15s var(--ease);
}
@media (hover: hover) { .btn:hover { background: var(--vert-fonce); border-color: var(--vert-fonce); } }
.btn:active { transform: translateY(1px); }
.btn--ghost { background: #fff; color: var(--ink-72); border-color: var(--line-fort); }
.btn--ghost:hover { background: #fff; color: var(--ink); border-color: var(--ink-34); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin-top: 1.4rem; }
.status { font-size: .92rem; color: var(--ink-52); }
.status.ok { color: var(--vert-fonce); }
.status.err { color: var(--rouge); }

/* ---------- 12. Récapitulatif -------------------------------------------- */

/* ---------- 13. Pied de page ---------------------------------------------
   Une seule ligne, pleine largeur, au bas de la coquille : la colonne de
   droite est ainsi réservée aux zones choisies.                          --- */
.foot {
  flex-shrink: 0;
  border-top: 1px solid var(--line);
  padding: .5rem var(--gut) calc(.5rem + env(safe-area-inset-bottom));
  background: var(--paper);
}
.foot__ligne {
  margin: 0; text-align: center;
  font-size: .74rem; line-height: 1.5; color: var(--ink-52);
}
.foot__nom { font-weight: 600; color: var(--ink-72); }
.foot__sep { padding-inline: .45rem; color: var(--line-fort); }
.foot__tel {
  color: var(--vert-fonce); font-weight: 600; text-decoration: none;
  white-space: nowrap;
}
@media (hover: hover) { .foot__tel:hover { text-decoration: underline; } }
.foot__mention { color: var(--ink-34); font-size: .68rem; }

/* ---------- 14. Calibrage ------------------------------------------------- */
.calib {
  position: fixed; right: 1rem; bottom: 1rem; z-index: 200;
  background: #fff; border: 1px solid var(--vert); border-radius: var(--radius);
  padding: 1rem; width: 18rem; box-shadow: 0 18px 40px -20px rgba(22,36,28,.45);
  font-size: .88rem; color: var(--ink-72);
}
.calib h4 { font-size: .9rem; color: var(--vert-fonce); margin-bottom: .6rem; }
.calib label { display: grid; grid-template-columns: 3.2rem 1fr 3.4rem; gap: .5rem; align-items: center; margin-bottom: .3rem; }
.calib code { font-family: ui-monospace, monospace; font-size: .8rem; color: var(--vert-fonce); display: block; margin-top: .5rem; word-break: break-all; }
.defs-globales { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- 14 bis. Lecture de droite à gauche ---------------------------- */
[dir="rtl"] .gauge-val { text-align: left; }
[dir="rtl"] .select { background-position: 18px 50%, 13px 50%; padding-right: .75rem; padding-left: 2.2rem; }
[dir="rtl"] .calib { right: auto; left: 1rem; }

/* ---------- 15. Adaptatif ------------------------------------------------- */
/* Sous 1080 px, la page devient une application plein écran :
   le corps occupe toute la hauteur à gauche, la sélection défile à droite. */
@media (max-width: 900px) {
  .hero { padding-block: .65rem .45rem; }
  .hero h1 { font-size: 1.08rem; line-height: 1.25; max-width: none; }
  .hero .lede {
    margin-top: .3rem; font-size: .86rem; line-height: 1.45; max-width: none;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }

  .workbench { padding-block: 0 0; padding-inline: .4rem; }
  /* Sur téléphone, deux colonnes en proportions fixes. Surtout pas de
     colonne « auto » ici : une SVG a une largeur intrinsèque de 300 px que
     la grille retiendrait, ce qui écraserait les jetons à quelques
     pixels de large. La scène remplit donc sa colonne. */
  .workbench__grid { grid-template-columns: 1.7fr 1fr; gap: .35rem; justify-content: stretch; }
  .figure-stage { aspect-ratio: auto; width: 100%; max-width: none; }
  .dossier--g { display: none; }
  .hero { text-align: start; }
  .plate { margin: 0; padding: 0; background: none; border: 0; box-shadow: none; gap: 0; }
  /* Pas de cadre sur mobile : le corps flotte, l'espace vide ne se voit plus */
  .plate__frame { flex: 1; height: auto; min-height: 0; width: auto; padding: .4rem 0 0; border: 0; background: none; }
  .plate__head { padding: 0 .2rem .45rem; gap: .35rem; }
  .viewswitch { margin-inline: auto; gap: .1rem; width: 100%; }
  .viewswitch button { flex: 1; padding: .34rem .2rem; font-size: .78rem; text-align: center; }
  
  .dossier { padding-bottom: .5rem; }
  .dossier__tete {
    position: sticky; top: 0; z-index: 2; background: var(--paper);
    padding-block: .1rem .45rem; justify-content: flex-end;
  }
  .dossier__tete h2 { display: none; }
  .lien { font-size: .8rem; }

    .foot { padding: .35rem .55rem calc(.35rem + env(safe-area-inset-bottom)); }
  .foot__ligne { font-size: .66rem; line-height: 1.45; }
  .foot__mention { font-size: .62rem; }
  .foot__sep { padding-inline: .3rem; }
}

@media (max-width: 620px) {
  .brand__sub { display: none; }
  .compteur { display: none; }
  .hero .lede { -webkit-line-clamp: 2; font-size: .8rem; margin-top: .2rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}


/* --- Numéro WhatsApp : indicatif à part, pour réduire les mauvais numéros */
.tel { display: flex; gap: .5rem; align-items: stretch; }
.tel__code {
  flex: 0 0 auto; width: auto; min-width: 6.2rem;
  font-size: 1.05rem; padding: .85rem .7rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-52) 50%),
                    linear-gradient(135deg, var(--ink-52) 50%, transparent 50%);
  background-position: calc(100% - 15px) 50%, calc(100% - 10px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
  padding-inline-end: 1.8rem; appearance: none;
  direction: ltr; text-align: start;
}
.tel__num { flex: 1; min-width: 0; direction: ltr; text-align: start; }
.field__aide { margin: .4rem 0 0; font-size: .82rem; color: var(--ink-34); }

@media (max-width: 420px) {
  .tel__code { min-width: 5.6rem; font-size: 1rem; padding-inline: .55rem 1.5rem; }
}

/* ---------- 17. Formulaire de contact : deux champs, gros ---------------- */
.champs { display: grid; gap: 1.1rem; max-width: 34rem; }
.input--grand { font-size: 1.12rem; padding: .85rem 1rem; }
.champs .field > label { font-size: 1rem; margin-bottom: .4rem; color: var(--ink); }
.actions .btn { font-size: 1.05rem; padding: .9rem 1.9rem; }

/* ---------- 19. En-tête de la colonne de sélection ----------------------- */
.dossier__tete { display: flex; align-items: baseline; gap: 1rem; margin-bottom: .7rem; }
.dossier__tete h2 { font-size: 1.1rem; font-weight: 600; flex: 1; min-width: 0; }
.lien {
  appearance: none; background: none; border: 0; cursor: pointer; flex-shrink: 0;
  font-family: inherit; font-size: .85rem; color: var(--ink-34);
  padding: 0; transition: color .2s var(--ease);
}
@media (hover: hover) { .lien:hover { color: var(--rouge); } }

/* ---------- 20. Barre d'appel --------------------------------------------
   Sa place est réservée dès le chargement, même quand le bouton ne s'est
   pas encore montré : la figure garde exactement la même taille avant et
   après la première sélection, et ses pieds ne sont jamais recouverts. --- */
.cta {
  flex-shrink: 0; display: flex; justify-content: center;
  padding: .4rem var(--gut) .45rem;
}
.cta .btn {
  width: min(26rem, 100%);
  font-size: 1rem; padding: .7rem 1.5rem;
  box-shadow: 0 10px 26px -10px rgba(23,124,41,.75);
  opacity: 0; visibility: hidden; transform: translateY(7px);
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
}
.cta.est-la .btn { opacity: 1; visibility: visible; transform: none; }

/* ---------- 21. Pop-up de prise de contact ------------------------------- */
.modale {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
}
.modale[hidden] { display: none; }
.modale__voile {
  position: absolute; inset: 0;
  background: rgba(22,36,28,.42);
  backdrop-filter: blur(8px) saturate(.9);
  -webkit-backdrop-filter: blur(8px) saturate(.9);
  animation: voile .28s var(--ease);
}
@keyframes voile { from { opacity: 0; } }
.modale__boite {
  position: relative; background: #fff;
  width: min(30rem, 100%); max-height: 92dvh; overflow-y: auto;
  border-radius: 16px; padding: 1.7rem 1.4rem 1.6rem;
  box-shadow: 0 30px 70px -25px rgba(22,36,28,.55);
  animation: monte .32s var(--ease);
}
@keyframes monte { from { opacity: 0; transform: translateY(18px); } }
.modale__boite h2 { font-size: 1.25rem; font-weight: 600; padding-inline-end: 2rem; }
.modale__intro { margin: .5rem 0 1.3rem; color: var(--ink-52); font-size: .95rem; }
.modale__x {
  position: absolute; top: .7rem; inset-inline-end: .7rem;
  appearance: none; background: var(--paper-2); border: 0; cursor: pointer;
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  font-size: 1.35rem; line-height: 1; color: var(--ink-52);
  transition: background .2s var(--ease), color .2s var(--ease);
}
.modale__x:hover { background: var(--paper-3); color: var(--ink); }
.btn--large { width: 100%; font-size: 1.02rem; padding: .9rem 1.4rem; margin-top: 1.3rem; }
.modale .status { display: block; margin-top: .8rem; text-align: center; }
.modale .champs { max-width: none; }
body.fige { overflow: hidden; }

@media (max-width: 620px) {
  .modale { align-items: flex-end; }
  .modale__boite {
    border-radius: 18px 18px 0 0; width: 100%;
    padding: 1.5rem 1.15rem calc(1.4rem + env(safe-area-inset-bottom));
  }
  @keyframes monte { from { opacity: 0; transform: translateY(60px); } }
}

/* ---------- 22. Mention d'acceptation au clic ---------------------------- */
.mention {
  margin: .8rem 0 0; font-size: .78rem; line-height: 1.45;
  color: var(--ink-34); text-align: center;
}

@media (max-width: 900px) {
}

/* ---------- 23. Résumé : liste des zones --------------------------------- */
  display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap;
  font-size: .98rem; font-weight: 500;
}

/* ---------- 22. Tutoriel de première visite -------------------------------
   Un doigt survole la figure, tape trois régions, puis s'efface dès que le
   visiteur touche lui-même une zone.                                    --- */
.tuto { pointer-events: none; transition: transform .62s cubic-bezier(.4, 0, .2, 1); }
.tuto__onde {
  fill: var(--vert); opacity: 0; transform-origin: 0 0;
}
.tuto__doigt {
  font-size: 58px; text-anchor: middle;
  filter: drop-shadow(0 3px 5px rgba(0, 0, 0, .3));
}
.tuto.frappe .tuto__onde { animation: onde .68s ease-out; }
.tuto.frappe .tuto__doigt { animation: frappe .68s ease-out; }
@keyframes onde {
  0%   { opacity: .5; transform: scale(.35); }
  100% { opacity: 0;  transform: scale(3.4); }
}
@keyframes frappe {
  0%, 100% { transform: translateY(0); }
  28%      { transform: translateY(-9px); }
}

/* Verre dépoli plutôt qu'un bandeau opaque : la figure reste lisible
   sous la légende, même quand celle-ci passe sur le torse. */
.tuto__bulle {
  position: absolute; left: 50%; z-index: 5;
  transform: translate(-50%, -50%);
  padding: .34rem .8rem; border-radius: 999px;
  background: rgba(251, 250, 247, .62);
  -webkit-backdrop-filter: blur(7px) saturate(1.3);
  backdrop-filter: blur(7px) saturate(1.3);
  border: 1px solid rgba(22, 36, 28, .10);
  color: var(--ink);
  font-size: .82rem; font-weight: 600; line-height: 1.3;
  white-space: nowrap; pointer-events: none;
  opacity: 0; transition: opacity .25s var(--ease), top .62s cubic-bezier(.4, 0, .2, 1);
  box-shadow: 0 2px 10px -6px rgba(22, 36, 28, .4);
}
.tuto__bulle.est-la { opacity: 1; }
.tuto__bulle[hidden] { display: none; }

@media (max-width: 900px) {
  .tuto__doigt { font-size: 66px; }
  .tuto__bulle { font-size: .78rem; padding: .35rem .7rem; }
}

/* ---------- 23. Réglages fins du téléphone -------------------------------
   Placés en fin de feuille pour l'emporter sur les blocs de base.      --- */
@media (max-width: 900px) {
  .cta { padding: .25rem .5rem .3rem; }
  .cta .btn { font-size: .92rem; padding: .58rem 1rem; box-shadow: none; }
}

/* ---------- 24. Composition de bureau -------------------------------------
   La planche occupe le centre, les régions choisies bordent ses deux côtés :
   celles du côté gauche de la figure à gauche de l'écran, celles du côté
   droit à droite. L'ordre des colonnes est donc physique — il ne suit pas le
   sens de lecture, sans quoi l'arabe renverrait la gauche du corps à droite.
   ------------------------------------------------------------------------ */
@media (min-width: 901px) {
  .workbench__grid { direction: ltr; }
  [dir="rtl"] .dossier__tete { direction: rtl; }

  .dossier--g { align-items: flex-end; }
  .dossier--g .cards { direction: rtl; }   /* les jetons bordent la planche */
  .dossier--d .cards { direction: ltr; }
  .jeton { direction: ltr; }

  /* Les deux colonnes démarrent à la même hauteur : la gauche réserve la
     place de la ligne d'en-tête que porte la droite. */
  .dossier__tete { height: 1.7rem; margin-bottom: .55rem; }
  .dossier__tete h2 { display: none; }
  .dossier--g::before { content: ''; flex-shrink: 0; height: 1.7rem; margin-bottom: .55rem; }
}
