/* L'animation de l'accueil, chargée après vitrine.css.
   Tout ce qui cache, déplace ou anime ne vaut que sous html.anime : la classe n'est posée que si le script tourne et
   que le système ne demande pas moins d'animation. Sans script, ou en mouvement réduit, la page entière est visible et
   immobile, et le récit se lit en images et textes alternés. */

/* =====================================================================================================================
   1. La grammaire commune : chaque bloc apparaît à son entrée dans l'écran (fondu qui monte), en cascade par --rang.
   ===================================================================================================================== */
html.anime [data-revele] {
  opacity: 0;
  transform: translateY(1.5rem);
  transition: opacity .75s cubic-bezier(.2, .7, .2, 1), transform .75s cubic-bezier(.2, .7, .2, 1);
  transition-delay: calc(var(--rang, 0) * 110ms);
}
html.anime [data-revele].vu { opacity: 1; transform: none; }

/* =====================================================================================================================
   2. Le héros : les deux lignes du titre l'une après l'autre, puis le texte, le bouton, la scène.
   ===================================================================================================================== */
@keyframes entree {
  from { opacity: 0; transform: translateY(1.1rem); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}
@keyframes fondu { from { opacity: 0; } to { opacity: 1; } }
html.anime .heros-vivant .droit { animation: entree .9s cubic-bezier(.2, .7, .2, 1) .15s both; }
html.anime .heros-vivant .italique { animation: entree .9s cubic-bezier(.2, .7, .2, 1) .45s both; }
html.anime .heros-vivant .plomb { animation: entree .8s cubic-bezier(.2, .7, .2, 1) .75s both; }
html.anime .heros-vivant .actes { animation: entree .8s cubic-bezier(.2, .7, .2, 1) .9s both; }
html.anime .heros-vivant .scene-vivante { animation: fondu 1.6s ease .6s both; }

/* =====================================================================================================================
   3. « Votre communication mérite mieux… » — le récit en six temps.
   Par défaut (téléphone, sans script, mouvement réduit) : image puis texte, six fois ; dès 821 px, côte à côte en
   alternance. Épinglé (dès 960 px, sous html.anime, classe .epingle posée par le script) : la scène reste à l'écran à
   gauche et change d'état pendant que les textes défilent à droite.
   ===================================================================================================================== */
.recit .recit-entete { max-width: 46rem; margin-inline: auto; align-items: center; text-align: center; }
.recit-scene { display: none; }
.recit-corps { display: grid; gap: clamp(2.8rem, 7vw, 5rem); margin-top: clamp(2.4rem, 5vw, 3.6rem); }
.temps { display: grid; gap: 1.4rem; align-items: center; }
.vignette { width: 100%; max-width: 36rem; margin-inline: auto; }
.temps-texte { display: flex; flex-direction: column; gap: .9rem; align-items: flex-start; max-width: 31rem; }
.temps-numero { font-family: var(--police-titre); font-weight: 700; color: var(--principale); font-size: var(--t-moyen); letter-spacing: .06em; }
/* Les titres des temps 01 à 04 en 600, moins gras (retouche du 23.11.2026, demandée par l'utilisateur). */
.temps-texte h3 { font-size: clamp(1.6rem, 1.15rem + 1.5vw, 2.3rem); line-height: 1.16; font-weight: 600; letter-spacing: -.015em; }
.temps-texte h3 .verbe { color: var(--principale); }
.temps-texte > p { color: var(--encre-douce); font-size: var(--t-moyen); line-height: 1.55; }
.temps-texte > p.temps-numero { color: var(--principale); }
.temps-texte > p.temps-plomb { color: var(--encre); font-size: var(--t-plomb); line-height: var(--t-plomb-lh); }
.temps-texte > p.temps-final { color: var(--encre); }
.temps-final .droit {
  display: block; font-family: var(--police-titre); font-weight: 600; color: var(--encre);
  font-size: clamp(1.8rem, 1.25rem + 1.9vw, 2.6rem); line-height: 1.1; letter-spacing: -.02em;
}
.temps-final .italique {
  display: block; margin-top: .45rem; font-style: italic; font-weight: 600; color: var(--principale);
  font-size: clamp(1.35rem, 1.05rem + 1.1vw, 1.9rem); line-height: 1.22;
}
@media (min-width: 821px) {
  /* L'image près de son texte, et plus grande (retouche du 23.11.2026) : une gouttière courte, une colonne d'image
     plus large, la vignette sans plafond. */
  .temps { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(1rem, 2vw, 1.5rem); }
  .recit .vignette { max-width: none; }
  .temps:nth-child(odd) .vignette { order: 2; }
}

@media (min-width: 960px) {
  /* L'écran près de son texte, et plus grand (retouche du 23.11.2026) : une colonne plus large, et pas de gouttière —
     la scène garde à droite de son écran 4 % de sa largeur (l'écran et la forme s'arrêtent à 96 %). */
  html.anime .recit-corps.epingle {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); column-gap: 0; row-gap: 0;
  }
  /* Sur un grand écran, la scène déborde dans la marge de gauche (la page s'arrête à 1 180 px) : jusqu'à 18rem, sans
     jamais atteindre le bord de la fenêtre ; le texte, lui, reste aligné sur le reste de la page. Une scène que la
     hauteur de l'écran rétrécit se range contre son texte (end), pas au milieu de sa colonne. */
  html.anime .epingle .recit-scene {
    display: grid; place-items: center end; grid-column: 1; grid-row: 1 / span 6; align-self: start;
    position: sticky; top: calc(78px + 2.5vh); height: calc(100vh - 78px - 5vh);
    margin-left: calc(-1 * clamp(0px, (100vw - 1180px) / 2, 18rem));
  }
  /* Une largeur explicite : un conteneur de requêtes (container-type) ne prend pas la largeur de son contenu. */
  html.anime .epingle .recit-scene .scene { width: min(100%, calc((100vh - 78px - 5vh) * 1.15)); }
  html.anime .epingle .temps { grid-column: 2; display: flex; align-items: center; min-height: 74vh; }
  /* Le dernier temps, plus haut : la scène reste épinglée tant que son texte est au milieu de l'écran. */
  html.anime .epingle .temps:last-child { min-height: 100vh; }
  html.anime .epingle .vignette { display: none; }
  html.anime .epingle .temps-texte[data-revele] {
    opacity: .26; transform: translateY(.5rem); transition: opacity .5s ease, transform .5s ease;
  }
  html.anime .epingle .actif .temps-texte[data-revele] { opacity: 1; transform: none; }
}

/* =====================================================================================================================
   4. La scène : un cadre 23:20 qui se dessine en unités de conteneur (cqw), pour garder ses proportions à toute largeur.
   Son état : data-etape (0 la galère, 1 centraliser, 2 publier, 3 programmer, 4 analyser, 5 la fin). Les états finaux
   sont écrits sans condition ; les mouvements n'existent que sous html.anime, quand la scène joue (.joue).
   ===================================================================================================================== */
.scene {
  position: relative; width: 100%; aspect-ratio: 23 / 20;
  container-type: inline-size; overflow: clip;
  font-family: var(--police-texte); color: var(--encre); line-height: 1.3;
}
.scene .forme {
  position: absolute; left: 20%; top: 2%; width: 76%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at 38% 32%, var(--surface) 0, var(--surface-douce) 56%, var(--principale-teinte) 100%);
  transition: transform .9s cubic-bezier(.3, 1.2, .5, 1);
}
.scene[data-etape="0"] .forme { transform: scale(.84) translate(-5%, 5%); }

/* --- Les applications éparpillées (temps 0), qui volent dans l'écran au temps 1 --- */
.fenetres { position: absolute; inset: 0; }
.fenetre {
  position: absolute; left: var(--x, 0); top: var(--y, 0); width: 19%; aspect-ratio: 4 / 3;
  transform: rotate(var(--r, 0deg));
  transition: left .8s cubic-bezier(.6, 0, .25, 1) var(--d, 0s), top .8s cubic-bezier(.6, 0, .25, 1) var(--d, 0s),
    transform .8s cubic-bezier(.6, 0, .25, 1) var(--d, 0s), opacity .3s ease calc(var(--d, 0s) + .5s);
}
.scene:not([data-etape="0"]) .fenetre { left: 41.5%; top: 35.5%; transform: rotate(0deg) scale(.2); opacity: 0; }
.fenetre-dedans {
  position: relative; width: 100%; height: 100%; padding: 1.1cqw;
  display: flex; flex-direction: column; gap: .9cqw;
  background: var(--surface); border-radius: 1.6cqw;
  box-shadow: 0 1.4cqw 3cqw -1.2cqw rgb(var(--ombre-rvb) / .55), 0 0 0 .15cqw var(--trait);
}
.fenetre-dedans img { width: 5.2cqw; height: 5.2cqw; }
.fenetre-dedans i { display: block; height: .9cqw; border-radius: 1cqw; background: var(--neutre-fond); }
.fenetre-dedans i + i { width: 62%; }
.badge {
  position: absolute; top: -1.1cqw; right: -1.1cqw; min-width: 3.6cqw; height: 3.6cqw; padding: 0 .8cqw;
  border-radius: 2cqw; background: var(--accent); color: var(--surface);
  font: 700 1.7cqw/3.6cqw var(--police-texte); text-align: center; box-shadow: 0 0 0 .45cqw var(--fond);
}
@keyframes flotte { from { transform: translateY(-5%) rotate(-2.5deg); } to { transform: translateY(5%) rotate(2.5deg); } }
@keyframes battement { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.25); } }
html.anime .joue[data-etape="0"] .fenetre-dedans { animation: flotte 1.7s ease-in-out infinite alternate; animation-delay: calc(var(--i, 0) * -.41s); }
html.anime .joue[data-etape="0"] .badge { animation: battement 1s ease-in-out infinite; animation-delay: calc(var(--i, 0) * -.23s); }

/* --- L'écran de l'application, en HTML : absent au temps 0, puis une vue par temps. Il est son propre conteneur de
   requêtes : les tailles de son contenu sont en cqw de l'ÉCRAN, si bien que tout grandit avec lui. --- */
.ecran {
  position: absolute; left: 6%; top: 3%; width: 90%; height: 81.5%;
  container-type: inline-size;
  display: grid; grid-template-rows: auto minmax(0, 1fr); overflow: hidden;
  background: var(--surface); border-radius: 3.05cqw;
  box-shadow: 0 3.2cqw 6cqw -3cqw rgb(var(--ombre-rvb) / .5), 0 0 0 .22cqw var(--trait);
  transition: opacity .6s ease .45s, transform .8s cubic-bezier(.2, .9, .3, 1.15) .45s;
}
.scene[data-etape="0"] .ecran { opacity: 0; transform: scale(.86) translateY(5%); transition-delay: 0s; }
.ecran-barre {
  display: flex; align-items: center; gap: 1.54cqw; padding: 1.69cqw 2.46cqw;
  border-bottom: .23cqw solid var(--trait); font: 700 3cqw/1 var(--police-titre); color: var(--encre);
}
.ecran-barre img { width: 4.46cqw; height: 4.46cqw; border-radius: 1.08cqw; }
.ecran-barre .avatar { margin-left: auto; width: 4.46cqw; height: 4.46cqw; border-radius: 50%; background: linear-gradient(135deg, var(--rose), var(--principale)); }
.ecran-corps { display: grid; grid-template-columns: 23% minmax(0, 1fr); min-height: 0; font-size: 2.69cqw; }
.ecran-menu { list-style: none; margin: 0; padding: 2cqw 1.38cqw; display: flex; flex-direction: column; gap: .77cqw; border-right: .23cqw solid var(--trait); background: var(--fond); }
.ecran-menu li {
  display: flex; align-items: center; gap: 1.08cqw; padding: 1.15cqw 1.23cqw; border-radius: 1.38cqw;
  font-size: 2.31cqw; font-weight: 600; color: var(--encre-douce); white-space: nowrap; transition: background .35s, color .35s;
}
.ecran-menu svg { width: 2.92cqw; height: 2.92cqw; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.scene[data-etape="1"] .menu-comptes, .scene[data-etape="2"] .menu-creer, .scene[data-etape="3"] .menu-posts,
.scene[data-etape="4"] .menu-stats, .scene[data-etape="5"] .menu-stats { background: var(--principale-teinte); color: var(--principale); }
.vues { position: relative; min-height: 0; }
.vue {
  position: absolute; inset: 0; padding: 2.31cqw 2.77cqw; display: flex; flex-direction: column; gap: 1.69cqw;
  opacity: 0; transform: translateY(3%); transition: opacity .45s ease, transform .45s ease;
}
.scene[data-etape="1"] .vue-comptes, .scene[data-etape="2"] .vue-creer, .scene[data-etape="3"] .vue-semaine,
.scene[data-etape="4"] .vue-stats, .scene[data-etape="5"] .vue-stats { opacity: 1; transform: none; transition-delay: .3s; }
.vue-titre { font: 700 3.23cqw/1.1 var(--police-titre); color: var(--encre); }

/* Les logos des réseaux, dans leur pastille de couleur. */
.logo-reseau { display: inline-grid; place-items: center; flex: none; width: 5.08cqw; height: 5.08cqw; border-radius: 1.46cqw; color: var(--surface); }
.logo-reseau svg { width: 62%; height: 62%; fill: currentColor; }
.lr-facebook { background: #1877f2; }
.lr-instagram { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fd5949 45%, #d6249f 60%, #285aeb 90%); }
.lr-tiktok, .lr-x { background: #111; }
.lr-youtube { background: #ff0000; }
.lr-snapchat { background: #fffc00; color: #111; }
.lr-discord { background: #5865f2; }
.coche { width: 2.46cqw; height: 2.46cqw; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

/* Vue 1 — Comptes : six comptes, connectés l'un après l'autre. */
.comptes { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.15cqw; }
.comptes li { display: flex; align-items: center; gap: 1.54cqw; padding: .85cqw 1.23cqw; border: .23cqw solid var(--trait); border-radius: 1.69cqw; }
.comptes .nom { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.comptes .etat {
  margin-left: auto; display: inline-flex; align-items: center; gap: .69cqw; padding: .46cqw 1.46cqw; border-radius: 3.08cqw;
  background: var(--succes-fond); color: var(--succes); font-weight: 600; font-size: 2.15cqw; white-space: nowrap;
}
@keyframes glisse { from { opacity: 0; transform: translateX(-6%); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: none; } }
html.anime .joue[data-etape="1"] .comptes li { animation: glisse .5s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(.6s + var(--i, 0) * .13s); }
html.anime .joue[data-etape="1"] .comptes .etat { animation: pop .45s cubic-bezier(.3, 1.6, .5, 1) both; animation-delay: calc(1.05s + var(--i, 0) * .13s); }

/* Vue 2 — Créer : le texte qui s'écrit, les médias, les comptes choisis, « Publier maintenant » pressé. */
.champ {
  padding: 1.69cqw 1.85cqw; min-height: 11.54cqw; border: .23cqw solid var(--trait-net); border-radius: 1.69cqw;
  font-size: 2.69cqw; white-space: nowrap; overflow: hidden;
}
.frappe { display: inline-block; vertical-align: bottom; overflow: hidden; white-space: nowrap; }
.curseur { display: inline-block; width: .31cqw; height: 3.38cqw; margin-left: .23cqw; vertical-align: bottom; background: var(--principale); }
.compteur { font-size: 2.08cqw; color: var(--encre-douce); }
.medias { display: flex; gap: 1.38cqw; }
.media { position: relative; width: 10.77cqw; height: 8.31cqw; border-radius: 1.38cqw; background: linear-gradient(135deg, var(--photo-peche), var(--rose)); }
.media + .media { background: linear-gradient(135deg, var(--photo-ciel), var(--photo-bleu)); }
.media svg { position: absolute; inset: 0; margin: auto; width: 3.38cqw; height: 3.38cqw; fill: var(--surface); }
.cibles { display: flex; flex-wrap: wrap; gap: 1.08cqw; }
.cible {
  display: inline-flex; align-items: center; gap: .77cqw; padding: .54cqw 1.23cqw .54cqw .54cqw; border-radius: 3.08cqw;
  background: var(--principale-teinte); color: var(--principale); font-size: 2.08cqw; font-weight: 600;
}
.cible .logo-reseau { width: 4cqw; height: 4cqw; border-radius: 50%; }
.actions-ecran { display: flex; justify-content: flex-end; gap: 1.38cqw; margin-top: auto; }
.faux-bouton { padding: 1.38cqw 2.31cqw; border-radius: 1.38cqw; font: 600 2.38cqw/1 var(--police-titre); }
.faux-bouton.pale { background: var(--neutre-fond); color: var(--encre); }
.faux-bouton.plein { background: var(--principale); color: var(--sur-principale); }
@keyframes tape { from { width: 0; } to { width: var(--l, 46ch); } }
@keyframes clignote-curseur { 50% { opacity: 0; } }
@keyframes appui { 0%, 100% { transform: none; } 45% { transform: scale(.9); } }
html.anime .joue[data-etape="2"] .frappe { animation: tape 1.5s steps(44, end) .7s both; }
html.anime .joue[data-etape="2"] .curseur { animation: clignote-curseur .8s steps(1) infinite; }
html.anime .joue[data-etape="2"] .cible { animation: pop .4s cubic-bezier(.3, 1.6, .5, 1) both; animation-delay: calc(2.1s + var(--i, 0) * .1s); }
html.anime .joue[data-etape="2"] .faux-bouton.plein { animation: appui .45s ease 2.9s both; }

/* Les réseaux qui s'envolent du bouton, une fois pressé. */
.envols { position: absolute; left: 82.4%; top: 79.4%; width: 0; height: 0; }
.envols .logo-reseau { position: absolute; left: -1.6cqw; top: -1.6cqw; width: 3.6cqw; height: 3.6cqw; border-radius: 50%; opacity: 0; }
@keyframes envol {
  0% { opacity: 0; transform: translate(0, 0) scale(.5); }
  18% { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--tx, 0), var(--ty, 0)) scale(1.15); }
}
html.anime .joue[data-etape="2"] .envols .logo-reseau { animation: envol 1.2s cubic-bezier(.25, .1, .3, 1) both; animation-delay: calc(3.15s + var(--i, 0) * .09s); }

/* Vue 3 — Posts : la semaine, les publications qui tombent dans leurs créneaux. */
.semaine { flex: 1; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); grid-template-rows: auto repeat(3, minmax(0, 1fr)); gap: .77cqw; min-height: 0; }
.ecran-jour { display: flex; flex-direction: column; align-items: center; font-size: 1.92cqw; color: var(--encre-douce); font-weight: 600; }
.ecran-jour b { font: 700 2.77cqw/1.1 var(--police-titre); color: var(--encre); }
.case { border: .2cqw solid var(--trait); border-radius: 1.23cqw; background: var(--fond); }
.creneau {
  z-index: 1; align-self: center; justify-self: stretch; margin: 0 .46cqw;
  display: flex; flex-direction: column; align-items: center; gap: .46cqw; padding: .77cqw .31cqw;
  background: var(--surface); border-radius: 1.38cqw; box-shadow: 0 .92cqw 2.15cqw -.92cqw rgb(var(--ombre-rvb) / .6), 0 0 0 .2cqw var(--trait-net);
  font-size: 1.85cqw; font-weight: 700; color: var(--encre);
}
.creneau .logo-reseau { width: 3.69cqw; height: 3.69cqw; border-radius: 1.08cqw; }
@keyframes tombe { from { opacity: 0; transform: translateY(-130%) scale(.9); } to { opacity: 1; transform: none; } }
html.anime .joue[data-etape="3"] .creneau { animation: tombe .6s cubic-bezier(.3, 1.5, .5, 1) both; animation-delay: calc(.65s + var(--i, 0) * .2s); }

/* Vue 4 — Statistiques : les quatre totaux qui comptent, les barres qui montent, la courbe qui se trace. */
.tuiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.23cqw; }
.tuile { display: flex; flex-direction: column; gap: .31cqw; padding: 1.23cqw 1.38cqw; border-radius: 1.69cqw; }
.tuile b { font: 700 3.54cqw/1.1 var(--police-titre); font-variant-numeric: tabular-nums; white-space: nowrap; }
.tuile i { font-style: normal; font-size: 1.85cqw; font-weight: 600; color: var(--encre-douce); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-jaime { background: var(--indicateur-jaime-fond); color: var(--indicateur-jaime); }
.t-commentaires { background: var(--indicateur-commentaires-fond); color: var(--indicateur-commentaires); }
.t-partages { background: var(--indicateur-partages-fond); color: var(--indicateur-partages); }
.t-vues { background: var(--indicateur-vues-fond); color: var(--indicateur-vues); }
.graphe {
  position: relative; flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); align-items: end;
  gap: 2cqw; padding: 1.54cqw .92cqw 0; border-bottom: .23cqw solid var(--trait-net);
}
.barre { height: var(--h, 0); border-radius: 1.23cqw 1.23cqw .31cqw .31cqw; background: linear-gradient(to top, var(--principale), var(--rose)); transform-origin: bottom; }
.courbe { position: absolute; inset: 1.54cqw .92cqw 0; width: calc(100% - 1.85cqw); height: calc(100% - 1.54cqw); overflow: visible; }
.courbe path { fill: none; stroke: var(--encre); stroke-width: .69cqw; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 0; vector-effect: non-scaling-stroke; }
@keyframes monte { from { transform: scaleY(0); } to { transform: none; } }
@keyframes trace { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
html.anime .joue[data-etape="4"] .barre { animation: monte .7s cubic-bezier(.2, .9, .3, 1.1) both; animation-delay: calc(.6s + var(--i, 0) * .08s); }
html.anime .joue[data-etape="4"] .courbe path { animation: trace 1.3s ease-in-out 1.2s both; }

/* Temps 5 — la fin : l'annonce « Publié sur 6 réseaux ». */
.toast {
  position: absolute; top: 1.85cqw; right: 2.15cqw; z-index: 2; display: inline-flex; align-items: center; gap: .92cqw;
  padding: 1.08cqw 1.85cqw; border-radius: 1.85cqw; background: var(--succes-fond); color: var(--succes);
  font-size: 2.31cqw; font-weight: 700; box-shadow: 0 1.54cqw 3.08cqw -1.54cqw rgb(var(--ombre-rvb) / .6);
  opacity: 0; transform: translateY(-40%) scale(.9); transition: opacity .4s ease, transform .5s cubic-bezier(.3, 1.5, .5, 1);
}
.scene[data-etape="5"] .toast { opacity: 1; transform: none; transition-delay: .5s; }

/* --- Le personnage du récit : une pose par temps, debout devant le bord gauche de l'écran. Chaque pose est posée
   par l'ancre de ses pieds (--pied, fraction de la largeur de l'image), si bien que le personnage ne glisse pas d'une
   pose à l'autre quand ses bras s'écartent. « max-width: none » : la règle générale des images (100 %) l'écraserait
   dans une boîte de largeur nulle. Ancre à 19,5 % : la pose la plus large à gauche (bras levés, 0,613 × 284/480 de
   la hauteur) reste dans la scène, que « overflow: clip » couperait (mesuré à 15,5 % : −3,4 %, le poing coupé). --- */
.personnage { position: absolute; left: 19.5%; bottom: 2.5%; width: 0; height: 60%; }
.personnage::before {
  content: ""; position: absolute; left: -10cqw; bottom: -1.3cqw; width: 20cqw; height: 2.8cqw; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(var(--ombre-rvb) / .24), rgb(var(--ombre-rvb) / 0));
}
.pose {
  position: absolute; left: 0; bottom: 0; height: 100%; width: auto; max-width: none;
  translate: calc(var(--pied, 0) * -100%) 0; transform-origin: calc(var(--pied, 0) * 100%) 100%;
  opacity: 0; transform: translateY(3%); transition: opacity .4s ease, transform .5s cubic-bezier(.2, .9, .3, 1.25);
}
.scene[data-etape="0"] .pose-0, .scene[data-etape="1"] .pose-1, .scene[data-etape="2"] .pose-2,
.scene[data-etape="3"] .pose-3, .scene[data-etape="4"] .pose-4, .scene[data-etape="5"] .pose-5 { opacity: 1; transform: none; transition-delay: .12s; }
@keyframes inquiete { from { rotate: -1.2deg; } to { rotate: 1.2deg; } }
@keyframes respire { from { scale: 1; } to { scale: 1.012 1.018; } }
@keyframes bondit { 0%, 100% { translate: calc(var(--pied, 0) * -100%) 0; } 45% { translate: calc(var(--pied, 0) * -100%) -6%; } }
html.anime .joue[data-etape="0"] .pose-0 { animation: inquiete .9s ease-in-out infinite alternate; }
html.anime .joue:is([data-etape="1"], [data-etape="2"], [data-etape="3"], [data-etape="4"]) .pose { animation: respire 2.4s ease-in-out infinite alternate; }
html.anime .joue[data-etape="5"] .pose-5 { animation: bondit .55s cubic-bezier(.3, 0, .5, 1) .6s 3; }

/* =====================================================================================================================
   5. « Tout ce dont vous avez besoin… » : les pictogrammes se tracent ; sur téléphone, une rangée qui glisse au doigt.
   ===================================================================================================================== */
html.anime .carte[data-revele] .glyphe svg * { stroke-dasharray: 1; stroke-dashoffset: 1; }
html.anime .carte[data-revele].vu .glyphe svg * { stroke-dashoffset: 0; transition: stroke-dashoffset 1.2s ease calc(var(--rang, 0) * 110ms + .3s); }
.repere { display: none; }
@media (max-width: 820px) {
  .defilement .paire {
    display: flex; gap: .9rem; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
    margin-inline: calc(-1 * clamp(1.1rem, 4vw, 2rem)); padding: .2rem clamp(1.1rem, 4vw, 2rem) .8rem;
    scroll-padding-inline: clamp(1.1rem, 4vw, 2rem); scrollbar-width: none;
  }
  .defilement .paire::-webkit-scrollbar { display: none; }
  .defilement .carte { flex: 0 0 min(84%, 26rem); scroll-snap-align: start; }
  html.js .repere {
    display: flex; align-items: center; justify-content: center; gap: .9rem; margin-top: .6rem;
    font: 600 var(--t-petit)/1 var(--police-texte); color: var(--encre-douce); font-variant-numeric: tabular-nums;
  }
  .repere .points { display: flex; gap: .35rem; }
  .repere .points i { width: .5rem; height: .5rem; border-radius: 1rem; background: var(--trait-net); transition: width .3s ease, background .3s ease; }
  .repere .points i.actif { width: 1.4rem; background: var(--principale); }
}

/* =====================================================================================================================
   5 bis. Les cartes des fonctionnalités s'ouvrent comme un livre. L'animation n'anime que transform et opacity, que
   le navigateur joue sans recalculer la mise en page, une seule fois, à l'arrivée de la carte. « backwards » : avant le
   départ, la carte est dans son état fermé ; à la fin, elle revient à son style de base (aucune transformation ne
   reste posée).
   data-col (posé par le script) dit où se trouve la carte : g ou d sur deux colonnes, seul sinon.
   ===================================================================================================================== */
html.anime #fonctionnalites { overflow-x: clip; }
html.anime .paire .carte[data-revele] { transition: none; position: relative; }
html.anime .paire .carte[data-revele]:not(.vu) { opacity: 0; }
html.anime .paire .carte[data-revele].vu { opacity: 1; transform: none; }

/* Le livre : sur deux colonnes, chaque rangée s'ouvre depuis le dos, au milieu — la carte de gauche pivote sur son
   bord droit, celle de droite sur son bord gauche, et l'ombre du pli s'efface quand la page se pose. Une carte seule
   (une colonne, rangée glissante) s'ouvre comme une page, sur son bord gauche. */
html.anime .paire .carte { --charniere: left; --ferme: -74deg; --pli: to right; }
html.anime .paire .carte[data-col="g"] { --charniere: right; --ferme: 80deg; --pli: to left; }
html.anime .paire .carte[data-col="d"] { --ferme: -80deg; }
html.anime .paire .carte[data-revele].vu {
  transform-origin: var(--charniere) center;
  animation: cartes-livre 1.1s cubic-bezier(.3, .65, .2, 1) backwards;
}
html.anime .paire .carte[data-revele]::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0;
  background: linear-gradient(var(--pli), rgb(var(--pli-rvb) / .2), rgb(var(--pli-rvb) / 0) 55%);
}
html.anime .paire .carte[data-revele].vu::before { animation: cartes-pli 1.1s ease-out backwards; }
@keyframes cartes-livre {
  from { opacity: 0; transform: perspective(1500px) rotateY(var(--ferme)); }
  18% { opacity: 1; }
  to { opacity: 1; transform: perspective(1500px) rotateY(0deg); }
}
@keyframes cartes-pli { from { opacity: 1; } 70% { opacity: .35; } to { opacity: 0; } }

/* =====================================================================================================================
   6. Les réseaux : les pastilles arrivent dispersées, puis se rangent.
   ===================================================================================================================== */
#reseaux { overflow-x: clip; }
html.anime .slab[data-revele] .jeton {
  opacity: 0; transform: translate(var(--dx, 0), var(--dy, 0)) rotate(var(--r, 0deg)) scale(.85);
  transition: opacity .5s ease, transform 1s cubic-bezier(.2, .85, .25, 1.12);
  transition-delay: calc(.25s + var(--rang, 0) * 70ms);
}
html.anime .slab[data-revele].vu .jeton { opacity: 1; transform: none; }

/* =====================================================================================================================
   7. Trois étapes : un fil qui se remplit au défilement ; chaque étape s'allume quand il l'atteint.
   ===================================================================================================================== */
.etapes.fil { position: relative; padding-left: 2.7rem; --avance: 1; }
.etapes.fil::before, .etapes.fil::after {
  content: ""; position: absolute; left: .95rem; top: .75rem; bottom: .75rem; width: 3px; border-radius: 3px;
}
.etapes.fil::before { background: var(--trait); }
.etapes.fil::after { background: var(--principale); transform-origin: top; transform: scaleY(var(--avance)); }
.etapes.fil li { position: relative; }
.etapes.fil li::before {
  content: ""; position: absolute; left: calc(-2.7rem + .95rem + 1.5px); top: .45rem; width: 1.15rem; height: 1.15rem;
  transform: translateX(-50%); border-radius: 50%; box-sizing: border-box;
  background: var(--principale); border: 3px solid var(--principale); box-shadow: 0 0 0 5px var(--principale-teinte);
  transition: background .35s ease, border-color .35s ease, box-shadow .35s ease;
}
html.anime .etapes.fil { --avance: 0; }
html.anime .etapes.fil li::before { background: var(--fond); border-color: var(--trait-net); box-shadow: 0 0 0 5px transparent; }
html.anime .etapes.fil li.allume::before { background: var(--principale); border-color: var(--principale); box-shadow: 0 0 0 5px var(--principale-teinte); }
html.anime .etapes.fil li > * { transition: opacity .4s ease; }
html.anime .etapes.fil li:not(.allume) > * { opacity: .45; }

/* =====================================================================================================================
   8. La finale : à son arrivée à l'écran, la fourmi se cache et lance les icônes (le geste du survol), puis revient.
   ===================================================================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .fourmi.lancer .cachette { clip-path: inset(0); transition: clip-path .08s ease-in; }
  .fourmi.lancer .clignote { transform: translateY(100%); transition: transform .34s cubic-bezier(.55, 0, .8, .2); }
  .fourmi.lancer .reseaux-jetes img {
    left: var(--x); top: var(--y); transform: translate(-50%, -50%) rotate(var(--r)) scale(1); opacity: 1;
    transition: left .6s cubic-bezier(.15, .75, .35, 1) var(--depart), top .6s cubic-bezier(.3, 1.45, .55, 1) var(--depart),
      transform .6s cubic-bezier(.3, 1.35, .5, 1) var(--depart), opacity .12s linear var(--depart);
  }
}

/* Une scène hors de l'écran (classe posée par le script) arrête ses mouvements en boucle. « !important » : les règles
   d'animation, plus précises, réécrivent animation-play-state par leur raccourci « animation ». */
.scene.endormie, .scene.endormie * { animation-play-state: paused !important; }
