/* ChunkArc site motion layer, 30/11/2026 (owner: «fai animazione per tutto il sito»).
   One idea carried everywhere: content arrives like blocks being placed. Cards rise and settle,
   steps light up in order, callouts slide in once. Plus state feedback (header shadow, FAQ
   answers, new results, lazy screenshots) and a reading bar on long articles.
   Nothing is hidden without JavaScript: every hidden state needs html.mx-on (set by motion.js,
   removed again on anchor jumps, print and reduced motion). Home, plans, Playstead and the status
   page keep their own motion systems; motion.js does not reveal there. */

/* Header: a soft shadow once the page has scrolled (state, also kept with reduced motion). */
html body.pc-site header.nh-header.mx-scrolled{box-shadow:0 12px 26px -20px rgba(9,14,18,.5)!important}

/* Reading bar on long articles (scroll-driven; created by motion.js only where supported). */
.mx-progress{position:fixed;top:0;left:0;right:0;height:3px;z-index:60;pointer-events:none;background:var(--pc-blue,#007fa6);transform-origin:0 50%;transform:scaleX(0);animation:mx-progress linear both;animation-timeline:scroll(root block)}
html[dir="rtl"] .mx-progress{transform-origin:100% 50%}
@keyframes mx-progress{to{transform:scaleX(1)}}

@media (prefers-reduced-motion: no-preference){
  html body.pc-site header.nh-header{transition:box-shadow .3s ease,background-color .2s ease,border-color .2s ease}

  /* Blocks being placed: rise, settle, a hair of scale. */
  html.mx-on .mx-wait{opacity:0;translate:0 20px;scale:.965;
    transition:opacity .45s cubic-bezier(.16,1,.3,1) var(--mx-d,0ms),translate .65s cubic-bezier(.16,1,.3,1) var(--mx-d,0ms),scale .65s cubic-bezier(.16,1,.3,1) var(--mx-d,0ms)}
  /* Headings and callouts: same arrival, no scale. */
  html.mx-on .mx-wait.mx-soft{translate:0 14px;scale:none}
  html.mx-on .mx-wait.mx-in{opacity:1;translate:none;scale:none}

  /* Step numbers light up in order, after their card lands. */
  html.mx-on .mx-wait .mx-badge{opacity:0;scale:.45 1;transform-origin:0 50%;
    transition:opacity .25s ease calc(var(--mx-d,0ms) + .22s),scale .5s cubic-bezier(.16,1,.3,1) calc(var(--mx-d,0ms) + .22s)}
  html[dir="rtl"].mx-on .mx-wait .mx-badge{transform-origin:100% 50%}
  html.mx-on .mx-wait.mx-in .mx-badge{opacity:1;scale:1}

  /* Lazy screenshots fade in when their pixels arrive, never as an empty box. */
  html.mx-on img.mx-img{opacity:0;transition:opacity .5s ease}
  html.mx-on img.mx-img.mx-in{opacity:1}

  /* FAQ and disclosure answers ease in when opened (home has its own). */
  @keyframes mx-open{from{opacity:0;translate:0 -5px}to{opacity:1;translate:none}}
  html:not(.pc-motion-paused) body.pc-site:not(.ac-home):not(.ps-page) :is(.faq-list details,#faq details,details.faq-item,details.feature-detail,details.plans-helper)[open]>:not(summary){animation:mx-open .28s cubic-bezier(.16,1,.3,1)}

  /* Analytics consent banner arrives instead of popping. */
  @keyframes mx-rise{from{opacity:0;translate:0 18px}to{opacity:1;translate:none}}
  html:not(.pc-motion-paused) body #chunkarc-analytics-consent{animation:mx-rise .45s cubic-bezier(.16,1,.3,1) .25s both}
}
