/* Animations liées au défilement (CSS natif, sans JavaScript).
   Fichier servi tel quel depuis public/ : le minifieur d'Astro fusionnerait animation-timeline
   dans le raccourci « animation », ce que les navigateurs rejettent. Sans prise en charge, la page reste statique. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    /* Manifeste : chaque mot s'éclaire en passant dans l'écran. */
    .mw {
      display: inline-block;
      opacity: 0.16;
      animation-name: lit;
      animation-timing-function: linear;
      animation-fill-mode: both;
      animation-duration: auto;
      animation-timeline: view();
      animation-range: cover 15% cover 40%;
    }

    /* Galerie (grand écran) : léger parallaxe de la photo dans son cadre. */
    @media (min-width: 900px) {
      .galerie__frame img {
        scale: 1.14;
        animation-name: drift;
        animation-timing-function: linear;
        animation-fill-mode: both;
        animation-duration: auto;
        animation-timeline: view();
      }
    }
  }
}
@keyframes lit { to { opacity: 1; } }
@keyframes drift { from { translate: 0 -5%; } to { translate: 0 5%; } }
