/* motion-kit v2 (DictIA) — styles du mouvement automatique (voir motion.js et MOTION.md).
   Règles : jamais `transform` ni `transition` posés durablement sur le contenu du site (propriétés
   individuelles translate/scale, classes retirées après révélation) ; transform/opacity/clip-path
   seulement ; aucune animation infinie ; états cachés posés par le JS (.m-pre). */
:where(:root) {
  --m-accent: var(--accent, #c8a165);
  --m-ease: cubic-bezier(0.23, 1, 0.32, 1);
}
.m-clip { overflow: clip; }

/* ---- Arrivée (héros) : tout est fini, ≤ 5 s ---- */
.m-on .m-settle { animation: m-settle 4.8s var(--m-ease) both; }
@keyframes m-settle { from { scale: 1.07; } to { scale: 1; } }
.m-on .m-pulse { animation: m-pulse 1.5s ease-in-out 3; }
.m-on .m-pulse:is(:hover, :focus-visible) { animation: m-pulse 1.5s ease-in-out 2; }
@keyframes m-pulse { 0%, 100% { scale: 1; } 50% { scale: 1.05; } }

.m-on .m-wait { opacity: 0; }
.m-on .m-w { display: inline-block; overflow: clip; vertical-align: top; padding: 0.2em 0.05em 0.25em; margin: -0.2em -0.05em -0.25em; }
.m-on .m-w > span { display: inline-block; animation: m-word 0.7s var(--m-ease) both; animation-delay: calc(var(--i, 0) * 70ms + 100ms); }
@keyframes m-word { from { translate: 0 118%; } to { translate: 0 0; } }

.m-on .m-now { animation: m-now 0.7s var(--m-ease) both; animation-delay: calc(var(--i, 0) * 80ms + 450ms); }
@keyframes m-now { from { opacity: 0; translate: 0 20px; } to { opacity: 1; translate: 0 0; } }

/* ---- Révélations au scroll (classes retirées par le JS après la révélation) ---- */
/* .m-pre : aucune transition (elle vit sur .m-in) ; clip-path jamais d'aire nulle (IntersectionObserver en tient compte). */
.m-on .m-wipe.m-pre { clip-path: polygon(0 0, 14% 0, -16% 100%, -30% 100%); opacity: 0; translate: -22px 0; }
.m-on .m-wipe.m-in { clip-path: polygon(0 0, 125% 0, 125% 100%, 0 100%); opacity: 1; translate: 0 0;
  transition: clip-path 0.7s var(--m-ease), opacity 0.45s ease, translate 0.7s var(--m-ease); transition-delay: calc(var(--i, 0) * 70ms); }

.m-on .m-unveil.m-pre { clip-path: inset(0 86% 0 0); opacity: 0.01; }
.m-on .m-unveil.m-in { clip-path: inset(0 0 0 0); opacity: 1;
  transition: clip-path 0.9s var(--m-ease), opacity 0.5s ease; transition-delay: calc(var(--i, 0) * 70ms); }

.m-on .m-up.m-pre { opacity: 0; translate: 0 26px; }
.m-on .m-up.m-in { opacity: 1; translate: 0 0;
  transition: opacity 0.5s ease, translate 0.6s var(--m-ease); transition-delay: calc(var(--i, 0) * 70ms); }

/* Mode doux (le système demande de réduire le mouvement) : fondus courts, aucun déplacement (même spécificité, placé après). */
.m-on.m-soft .m-pre { clip-path: none; translate: none; opacity: 0; }
.m-on.m-soft .m-in { clip-path: none; translate: none; opacity: 1; transition: opacity 0.45s ease; transition-delay: 0s; }

/* ---- Survol (souris) : .m-lift posé par le JS seulement sur les cartes sans transition de leur site ---- */
@media (hover: hover) and (pointer: fine) {
  .m-on:not(.m-soft) .m-lift:not(.m-pre) { transition: translate 0.3s var(--m-ease); }
  .m-on:not(.m-soft) .m-lift:not(.m-pre):hover { translate: 0 -5px; }
}

/* ---- Bandeau (créé par le JS depuis <meta name="motion-marquee">) ---- */
.m-marquee {
  overflow: hidden; white-space: nowrap; user-select: none; color: inherit;
  padding: 0.9rem 0; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  font-size: clamp(0.85rem, 1.7vw, 1.2rem); font-family: var(--m-font, var(--font-display, inherit));
  background: color-mix(in srgb, var(--m-accent) 14%, transparent);
  border-block: 1px solid color-mix(in srgb, var(--m-accent) 45%, transparent);
}
.m-track { display: flex; width: max-content; align-items: center; }
.m-track span { padding: 0 1.7rem; }
.m-track i { display: block; flex: none; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--m-accent); }

/* ---- Barre et cadran de scroll (liés au scroll) ---- */
.m-bar { position: fixed; inset: 0 0 auto 0; height: 3px; background: var(--m-accent); transform: scaleX(0); transform-origin: 0 50%; z-index: 9999; pointer-events: none; }
.m-dial { position: fixed; left: 18px; bottom: 18px; width: 58px; height: 58px; z-index: 9998; pointer-events: none; display: none; }
@media (min-width: 900px) { .m-dial { display: block; } }
.m-dial svg { width: 100%; height: 100%; overflow: visible; }
.m-ticks { transform-box: view-box; transform-origin: 50% 50%; }
.m-ticks line { stroke: var(--m-accent); stroke-width: 2; stroke-linecap: round; opacity: 0.9; }
.m-arc { fill: none; stroke: var(--m-accent); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; transform-box: view-box; transform-origin: 50% 50%; transform: rotate(-90deg); }

/* ---- Filets ---- */
@media print {
  .m-pre, .m-now, .m-wait, .m-w > span { opacity: 1 !important; translate: none !important; scale: none !important; clip-path: none !important; animation: none !important; }
  .m-bar, .m-dial, .m-marquee { display: none !important; }
}

/* cadran de scroll retiré (JD, 13 oct. 2026) */
.m-dial { display: none !important; }
