/* PPS — Scroll-in animations (data-anim values set in main.js)
   Loaded in numeric order; later files may refine earlier ones. */

/* ==========================================================================
   Reveal on scroll — each element type enters differently
   main.js gives every animated element a data-anim value and adds .in when
   it scrolls into view. Individual properties (translate / scale / rotate)
   are used so they never clash with hover transforms.
   ========================================================================== */
.js [data-anim] {
  opacity: 0;
  transition: opacity .8s var(--ease), translate .8s var(--ease), scale .8s var(--ease), rotate .9s var(--ease), clip-path 1s var(--ease), filter .8s var(--ease),
              transform .45s var(--ease), box-shadow .35s, border-color .35s, background .3s, color .3s;
}
.js [data-anim].in { opacity: 1; translate: none; scale: none; rotate: none; filter: none; }
.js [data-anim="rise"]  { translate: 0 30px; }
.js [data-anim="title"] { translate: 0 22px; filter: blur(6px); }
.js [data-anim="fade"]  { }
.js [data-anim="left"]  { translate: -44px 0; }
.js [data-anim="right"] { translate: 44px 0; }
[dir="rtl"].js [data-anim="left"]  { translate: 44px 0; }
[dir="rtl"].js [data-anim="right"] { translate: -44px 0; }
.js [data-anim="zoom"]  { scale: .9; }
.js [data-anim="pop"]   { scale: .55; }
.js [data-anim="flip"]  { rotate: x 55deg; translate: 0 30px; transform-origin: 50% 100%; }
.js [data-anim="swing"] { rotate: y -35deg; transform-origin: 0 50%; }
.js [data-anim="wipe"]  { opacity: 1; clip-path: inset(0 100% 0 0 round var(--radius)); }
.js [data-anim="wipe"].in { clip-path: inset(0 0 0 0 round var(--radius)); }
[dir="rtl"].js [data-anim="wipe"] { clip-path: inset(0 0 0 100% round var(--radius)); }

/* Eyebrow: the gold line draws in */
.js .eyebrow[data-anim]::before, .js .eyebrow[data-anim]::after { width: 0; transition: width .7s var(--ease) .2s; }
.js .eyebrow[data-anim].in::before, .js .eyebrow[data-anim].in::after { width: 26px; }

/* Journey: connector lines draw after the dots appear */
.js .step[data-anim]::after { transform-origin: 0 50%; scale: 0 1; transition: scale .8s var(--ease) .35s; }
.js .step[data-anim].in::after { scale: 1 1; }
@media (max-width: 1024px) {
  .js .step[data-anim]::after { transform-origin: 50% 0; scale: 1 0; }
  .js .step[data-anim].in::after { scale: 1 1; }
}
/* Timeline: the vertical line grows as the section enters */
.js .timeline[data-line]::before { transform-origin: 50% 0; scale: 1 0; transition: scale 1.6s var(--ease); }
.js .timeline[data-line].in::before { scale: 1 1; }
/* Stat: gold bar grows */
.js .stat[data-anim] { border-inline-start-color: transparent; position: relative; }
.js .stat[data-anim]::before { content: ""; position: absolute; inset-block: 0; inset-inline-start: -2px; width: 2px; background: var(--gold); transform-origin: 50% 100%; scale: 1 0; transition: scale 1s var(--ease) .2s; }
.js .stat[data-anim].in::before { scale: 1 1; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-anim] { opacity: 1 !important; translate: none !important; scale: none !important; rotate: none !important; filter: none !important; clip-path: none !important; transition: none !important; }
  .scroll-cue::after { animation: none; }
}
