/* copie de hall/shared/lamie-ds — ne pas modifier ici */
/* ============================================================================
   LA MIE DORÉE — Base commune des mouvements · lamie-mouvement.css
   Consigne esthétique de Patrice (15/11/2026), validée sur « À trier » de
   Passe-Plat et la page des cartes de Retours :
   chaque geste répond tout de suite, une carte traitée glisse et la suivante
   arrive en douceur, une barre de progression avance, un écran de fin propre
   apparaît, les boutons réagissent au toucher. Sobre : rien qui clignote,
   pas d'emoji, la lisibilité avant l'effet.
   Source : hall/shared/lamie-ds/ (https://accueil.lamiedoree.eu/shared/lamie-ds/).
   Chaque outil en garde une COPIE locale, chargée après sa feuille de charte.
   Tout mouvement est coupé si l'appareil demande moins d'animations.
   Accent : --lm-accent (sinon bleu de la charte #1a56db).
   ============================================================================ */
:root {
  --lm-accent-mv: var(--lm-accent, #1a56db);
  --lm-accent-mv-pale: var(--lm-accent-pale, #eaf1fe);
  --lm-ease-out: cubic-bezier(.22,1,.36,1);
  --lm-ease-in: cubic-bezier(.4,0,1,1);
}

/* 1. Les boutons répondent au toucher : léger enfoncement (rien d'autre ne change) */
.lm-btn, .btn, button, [role="button"], .lm-touch {
  transition: transform .14s ease, background-color .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.lm-btn:active:not(:disabled), .btn:active:not(:disabled), button:active:not(:disabled),
[role="button"]:active, .lm-touch:active { transform: scale(.97); }

/* 2. Une carte traitée glisse sur le côté, se replie ; les suivantes remontent (JS : LamieMouvement.sortir) */
.lm-part { animation: lm-part .2s var(--lm-ease-in) forwards; pointer-events: none; overflow: hidden; }
.lm-replie { transition: height .26s var(--lm-ease-out), margin .26s var(--lm-ease-out), padding .26s var(--lm-ease-out);
  margin-top: 0 !important; margin-bottom: 0 !important; padding-top: 0 !important; padding-bottom: 0 !important;
  border-width: 0 !important; }
@keyframes lm-part { to { transform: translateX(-48px) scale(.97); opacity: 0; } }

/* 3. Une nouvelle carte (ou un écran) arrive en douceur (JS : LamieMouvement.arrivees, ou la classe à la main) */
.lm-arrive { animation: lm-arrive .34s var(--lm-ease-out) both; }
@keyframes lm-arrive { from { transform: translateY(10px) scale(.985); opacity: 0; } }
/* Une carte arrivée en douceur puis traitée doit quand même sortir (la sortie l'emporte sur l'arrivée) */
.lm-arrive.lm-part { animation: lm-part .2s var(--lm-ease-in) forwards; animation-delay: 0s; }
.lm-apparait { animation: lm-apparait .22s ease-out both; }
@keyframes lm-apparait { from { opacity: 0; transform: translateY(4px); } }

/* 4. Barre de progression (« 3 réglées · 5 restantes ») — JS : LamieMouvement.barre */
.lm-progres { margin: 0 0 16px; }
.lm-progres-l { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; color: #6b7280;
  font-variant-numeric: tabular-nums; margin-bottom: 6px; }
.lm-progres-l span:first-child { color: #111; font-weight: 600; }
.lm-progres-barre { height: 4px; border-radius: 999px; background: #eef0f3; overflow: hidden; }
.lm-progres-barre i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--lm-accent-mv);
  transition: width .45s var(--lm-ease-out); }

/* 5. Écran de fin : une coche qui se trace — JS : LamieMouvement.fin */
.lm-fin { text-align: center; padding: 40px 16px 32px; animation: lm-arrive .4s var(--lm-ease-out) both; }
.lm-fin svg { width: 64px; height: 64px; display: block; margin: 0 auto 16px; }
.lm-fin-rond { fill: var(--lm-accent-mv-pale); }
.lm-fin-trait { fill: none; stroke: var(--lm-accent-mv); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 30; stroke-dashoffset: 30; animation: lm-trace .5s .18s cubic-bezier(.65,0,.35,1) forwards; }
@keyframes lm-trace { to { stroke-dashoffset: 0; } }
.lm-fin h3 { font-size: 22px; font-weight: 700; margin: 0 0 6px; letter-spacing: -.01em; color: #111; }
.lm-fin p { margin: 0; color: #6b7280; font-size: 15px; }

/* 6. Moins d'animations demandé : tout s'arrête, le contenu reste */
@media (prefers-reduced-motion: reduce) {
  .lm-btn, .btn, button, [role="button"], .lm-touch, .lm-progres-barre i, .lm-replie { transition: none; }
  .lm-btn:active:not(:disabled), .btn:active:not(:disabled), button:active:not(:disabled),
  [role="button"]:active, .lm-touch:active { transform: none; }
  .lm-part, .lm-arrive, .lm-arrive.lm-part, .lm-apparait, .lm-fin { animation: none; }
  .lm-fin-trait { animation: none; stroke-dashoffset: 0; }
}
