/*
  Axvoid Learn — motion tokens (AxvoidLearn theme; design basis of 2026-10-30)

  Theme file of AxvoidLearn 2.0.0. Source of truth for this part of the design system.
  Components never write a raw duration or easing. Every duration AND delay is built from the
  multiplier --lrn-motion-k, so one switch turns all motion off and every animation lands on its
  finished state at once (nothing is left half-drawn).

  Switch on <html>:
    data-motion="auto"      follows the visitor's system setting (default)
    data-motion="reduced"   forces reduced motion regardless of the system
  There is deliberately no "force full motion": a system-level reduce request is always respected.

  Usage rule: animate with  animation-duration: calc(480ms * var(--lrn-motion-k));
  and delay with            animation-delay:    calc(300ms * var(--lrn-motion-k));
*/

:root {
  --lrn-motion-k: 1;

  /* durations (already multiplied; 0ms when reduced) */
  --lrn-dur-instant: calc(90ms  * var(--lrn-motion-k));   /* press, focus ring */
  --lrn-dur-fast:    calc(160ms * var(--lrn-motion-k));   /* hover, chips */
  --lrn-dur-base:    calc(240ms * var(--lrn-motion-k));   /* colour change, panel open */
  --lrn-dur-slow:    calc(480ms * var(--lrn-motion-k));   /* section reveal, stamp */

  /* easings */
  --lrn-ease-standard: cubic-bezier(.2, 0, 0, 1);         /* things moving between places */
  --lrn-ease-enter:    cubic-bezier(0, 0, 0, 1);          /* appearing */
  --lrn-ease-exit:     cubic-bezier(.4, 0, 1, 1);         /* leaving */
  --lrn-ease-settle:   cubic-bezier(.34, 1.3, .64, 1);    /* a small overshoot, used once for the failure stamp */

  /* distances */
  --lrn-move-sm: 2px;    /* hover lift */
  --lrn-move-md: 8px;    /* reveal rise */
}

html[data-motion="reduced"] { --lrn-motion-k: 0; }

@media (prefers-reduced-motion: reduce) {
  html { --lrn-motion-k: 0; }
}
