/* Mr. Benef — lot front v1 (10/11/2026). Design system Babenef, section 27.
 * À charger après babenef-tokens.css. Aucune ressource externe.
 * Une pose = un SVG en ligne (calques PNG + objets dessinés) ; les animations ne jouent que si le SVG porte
 * benef-svg--apparition (une fois, posé par mr-benef.js quand il devient visible) ou benef-svg--attente (en boucle). */

@font-face{font-family:"Newsreader";font-style:italic;font-weight:500;font-display:swap;src:url("../fonts/newsreader-latin-500-italic.woff2") format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:"Newsreader";font-style:italic;font-weight:500;font-display:swap;src:url("../fonts/newsreader-latin-ext-500-italic.woff2") format("woff2");unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}

/* ---- `hidden` l'emporte sur les display ci-dessous (attentes, répliques en attente) */
.benef-moment[hidden],.benef-line[hidden],.benef-figure[hidden]{display:none!important}

/* ---- Tailles (section 27, §5) */
.benef-figure{--benef-h:140px;flex:none;line-height:0;position:relative}
.benef-figure--petit{--benef-h:96px}
.benef-figure--vignette{--benef-h:140px}
.benef-figure--illustration{--benef-h:260px}
.benef-figure--heros{--benef-h:440px}
.benef-figure .benef-svg{display:block;height:var(--benef-h);width:auto;max-width:100%;overflow:visible}
.benef-figure--retourne .benef-svg{transform:scaleX(-1)}
.benef-figure--avatar{width:64px;height:64px;border-radius:50%;background:var(--sky-tint);overflow:hidden}
.benef-figure__tete{display:block;width:100%;height:100%}
@media (max-width:599px){
  .benef-figure--illustration,.benef-figure--heros{--benef-h:160px}
  .benef-figure--vignette{--benef-h:120px}
}

/* ---- Réplique : texte HTML, Newsreader italique, entre guillemets (§6) */
.benef-line{margin:0;font-family:var(--font-display);font-style:italic;font-weight:500;font-size:18px;line-height:1.4;color:var(--ink);max-width:46ch;text-wrap:pretty}
.benef-line--on-ink,.benef-on-ink .benef-line{color:var(--on-ink)}

/* ---- Dispositions */
.benef-moment{display:flex;gap:var(--space-4);align-items:center;min-width:0}
.benef-moment>.benef-line{min-width:0}
.benef-moment--ligne{align-items:flex-end}
.benef-moment--ligne>.benef-line{padding-bottom:var(--space-3)}
.benef-moment--pile{flex-direction:column;text-align:center}
.benef-moment--pile>.benef-line{max-width:40ch}
.benef-moment--notif{gap:var(--space-3)}
.benef-moment--notif>.benef-line{font-size:16px}
.benef-moment--bulle{align-items:flex-end}
.benef-moment--bulle>.benef-line{position:relative;padding:14px 18px;background:#fffdf7;border:1.5px solid var(--ink);border-radius:16px;margin-bottom:var(--space-8)} /* pages publiques seulement */
.benef-moment--bulle>.benef-line::before{content:"";position:absolute;left:-9px;bottom:18px;width:14px;height:14px;background:#fffdf7;border-left:1.5px solid var(--ink);border-bottom:1.5px solid var(--ink);transform:rotate(45deg)}
@media (max-width:359px){ /* sous 360 px : avatar seulement (§5) */
  .benef-moment--ligne .benef-figure:not(.benef-figure--avatar),.benef-moment--bulle .benef-figure:not(.benef-figure--avatar){display:none}
}
@media (max-width:599px){
  .benef-moment--ligne,.benef-moment--bulle{flex-direction:column;align-items:flex-start}
  .benef-moment--bulle>.benef-line::before{display:none}
  .benef-moment--bulle>.benef-line{margin-bottom:0}
}

/* ---- Attente : apparaît en fondu, la scène de lecture n'est visible qu'en attente */
.benef-attente:not([hidden]){animation:benef-fondu .3s ease-out both}
.benef-svg .benef-a-scan,.benef-svg .benef-a-glint{opacity:0}
.benef-svg--attente .benef-a-scan,.benef-svg--attente .benef-a-glint{opacity:1}
.benef-attente .benef-line:not([hidden]){animation:benef-fondu .4s ease-out both}
.benef-a-card,.benef-a-bin,.benef-a-twirl{transform-box:fill-box}
.benef-a-bin{transform-origin:center}
.benef-a-twirl{transform-origin:30% 45%}

/* ---- Animations (§7). Une à la fois par écran ; seules les attentes bouclent. */
@media (prefers-reduced-motion:no-preference){
  .benef-svg--apparition .benef-a-brow{animation:benef-brow .9s ease-in-out .2s 1 both}
  .benef-svg--apparition .benef-a-card{animation:benef-serve .45s ease-out both}
  .benef-svg--apparition .benef-a-card--2{animation-delay:.25s}
  .benef-svg--apparition .benef-a-card--3{animation-delay:.5s}
  .benef-svg--apparition .benef-a-bin{animation:benef-bin 3.4s cubic-bezier(.5,0,.7,1) .3s 1 both}
  .benef-svg--apparition .benef-a-swing{animation:benef-swing 1.8s ease-in-out 2}
  .benef-svg--apparition .benef-a-twirl{animation:benef-twirl 1.4s ease-in-out 2}

  .benef-svg--attente .benef-a-brow{animation:benef-brow-attente 1.6s ease-in-out infinite}
  .benef-svg--attente .benef-a-bob{animation:benef-bob 2.2s ease-in-out infinite}
  .benef-svg--attente .benef-a-scan{animation:benef-scan 1.8s linear infinite}
  .benef-svg--attente .benef-a-glint{animation:benef-glint 2.4s ease-in infinite}
  .benef-svg--attente .benef-a-swing{animation:benef-swing 1.8s ease-in-out infinite}
}
@media (prefers-reduced-motion:reduce){
  .benef-svg--attente .benef-a-scan{opacity:.85;transform:translateY(50px)} /* une barre fixe dit qu'il lit */
  .benef-svg--attente .benef-a-glint{opacity:0}
  .benef-attente:not([hidden]),.benef-attente .benef-line:not([hidden]){animation:none}
}
/* Valeurs en unités du viewBox (transform-box: view-box sur les groupes concernés). */
@keyframes benef-brow{0%{transform:none}40%,70%{transform:translate(0,-10px) rotate(-7deg)}85%{transform:translate(0,2px) rotate(2deg)}100%{transform:none}}
@keyframes benef-brow-attente{0%,100%{transform:none}25%{transform:translate(0,-11px) rotate(-8deg)}50%{transform:none}70%{transform:translate(0,-6px) rotate(-3deg)}}
@keyframes benef-bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-4px)}}
@keyframes benef-scan{0%{transform:translateY(0);opacity:0}10%,90%{opacity:.85}100%{transform:translateY(118px);opacity:0}}
@keyframes benef-glint{0%,70%{transform:translateX(-60px)}100%{transform:translateX(60px)}}
@keyframes benef-serve{from{transform:translateY(26px);opacity:0}to{transform:none;opacity:1}}
@keyframes benef-bin{0%{transform:none;opacity:1}55%{transform:translate(-62px,150px) rotate(-160deg);opacity:1}62%,100%{transform:translate(-66px,190px) rotate(-175deg) scale(.7);opacity:0}}
@keyframes benef-swing{0%,100%{transform:rotate(-9deg)}50%{transform:rotate(9deg)}}
@keyframes benef-twirl{0%,100%{transform:none}50%{transform:rotate(-7deg)}}
@keyframes benef-fondu{from{opacity:0}to{opacity:1}}

/* Origines des poses : remplacent les attributs style en ligne (CSP style-src 'self'). */
.benef-svg .benef-vb{transform-box:view-box}
.benef-svg .benef-o-138_0_80_0{transform-origin:138.0px 80.0px}
.benef-svg .benef-o-140_5_85_0{transform-origin:140.5px 85.0px}
.benef-svg .benef-o-144_0_89_0{transform-origin:144.0px 89.0px}
.benef-svg .benef-o-145_5_77_5{transform-origin:145.5px 77.5px}
.benef-svg .benef-o-148_0_89_5{transform-origin:148.0px 89.5px}
.benef-svg .benef-o-149_0_83_0{transform-origin:149.0px 83.0px}
.benef-svg .benef-o-161_0_81_5{transform-origin:161.0px 81.5px}
.benef-svg .benef-o-167_5_76_5{transform-origin:167.5px 76.5px}
.benef-svg .benef-o-316_200{transform-origin:316px 200px}
