/* ── Animations de la page Intégrations (FR et EN), 17/11/2026 ──
   La page était jugée « molle » : un schéma qui clignotait à peine, rien
   d'autre ne bougeait. Ce fichier ne contient QUE le mouvement ; la mise en
   page reste dans le <style> de chaque page.

   Règle d'or : tout ce qui est masqué au départ l'est sous `html.anim`, classe
   posée par integrations.js seulement si le navigateur sait animer et si le
   visiteur n'a pas demandé moins de mouvement. Sans JS, la page est complète. */

/* 1. Apparition au défilement, en cascade (délai posé par le JS). */
html.anim .rv { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.2,1); }
html.anim .rv.vu { opacity: 1; transform: none; }

/* 2. Héros : « vos outils » se surligne, puis le schéma entre. */
html.anim .phero h1 em { animation: surligne .75s .25s cubic-bezier(.6,0,.2,1) both; }
@keyframes surligne { from { clip-path: inset(0 100% 0 0 round 6px); } to { clip-path: inset(0 0 0 0 round 6px); } }
html.anim .hub { animation: monte .8s .5s cubic-bezier(.2,.7,.2,1) both; }
@keyframes monte { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }

/* 3. Schéma événements → app → outils. Le JS trace les fils (SVG) et fait
   voyager un colis le long ; l'ancien clignotement est coupé pour ne pas
   brouiller la lecture. */
.hub { position: relative; }
.hub .fils { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 0; }
.hub .col, .hub .core { position: relative; z-index: 1; }
/* De la place entre colonnes et cœur, sinon les fils (18 px) ne se voient pas. */
.hub.vivant { column-gap: clamp(36px, 7vw, 96px); }
.hub .fils .base { fill: none; stroke: rgba(27,45,90,.22); stroke-width: 1.5; stroke-dasharray: 4 5; }
.hub .fils .actif { fill: none; stroke: var(--signal); stroke-width: 2.5; stroke-linecap: round; }
.hub .fils .colis { fill: var(--signal); }
.hub.vivant .core::before, .hub.vivant .core::after { display: none; }
.hub.vivant .ev i, .hub.vivant .tool .dot { animation: none; opacity: .35; transition: opacity .3s, transform .3s; }
.hub .ev, .hub .tool { transition: border-color .3s, box-shadow .3s, transform .3s; }
.hub .ev.on { border-color: var(--signal); box-shadow: 0 8px 22px -12px rgba(255,130,0,.6); transform: translateX(4px); }
.hub .ev.on i { opacity: 1; transform: scale(1.5); }
.hub .tool.on { border-color: #2E9E6A; box-shadow: 0 8px 22px -12px rgba(46,158,106,.55); transform: translateX(-4px); }
.hub .tool.on .dot { opacity: 1; transform: scale(1.5); }
.hub .tool small { transition: color .3s; }
.hub .tool.on small { color: #1F7A4D; }
/* Le cœur « reçoit » : un anneau orange s'élargit. */
.hub .core .anneau { position: absolute; inset: 0; border-radius: 28px; border: 2px solid var(--signal); opacity: 0; pointer-events: none; }
.hub .core.ping .anneau { animation: anneau .7s ease-out; }
.hub .core.ping svg { animation: tape .45s ease-out; }
@keyframes anneau { from { opacity: .9; transform: scale(1); } to { opacity: 0; transform: scale(1.35); } }
@keyframes tape { 40% { transform: scale(1.15) rotate(-6deg); } }

/* 4. Les 15 événements s'allument dans l'ordre : la vie du colis, aller puis
   retour. `.on` = déjà passé, `.cur` = l'étape en cours. */
.chips .pill { transition: background-color .25s, color .25s, transform .25s; }
.chips .pill.on { background: #FFD3A6; }
.chips .pill.cur { background: var(--signal); color: #fff; transform: scale(1.08); }

/* 5. Tuiles : la pastille de l'outil s'anime au survol, un reflet balaie. */
.tile { overflow: hidden; }
.tile .mono { transition: transform .3s cubic-bezier(.3,1.6,.5,1); }
.tile:hover .mono { transform: rotate(-8deg) scale(1.1); }
.tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 35%, rgba(255,130,0,.10) 50%, transparent 65%); transform: translateX(-100%); pointer-events: none; }
.tile:hover::after { transform: translateX(100%); transition: transform .8s ease; }
.tile:hover { box-shadow: 0 16px 34px -22px rgba(27,45,90,.45); }

/* 6. Appel final : la flèche du bouton pousse vers l'avant. */
html.anim .final .btn { animation: pousse 2.4s 1s ease-in-out infinite; }
@keyframes pousse { 0%, 70%, 100% { transform: none; } 80% { transform: translateX(5px); } 90% { transform: translateX(0); } }

@media (prefers-reduced-motion: reduce) {
  .tile .mono, .tile::after { transition: none; }
  .tile:hover .mono { transform: none; }
  .tile:hover::after { transform: translateX(-100%); }
}
