/* Intro du studio Blo Games : 1,8 seconde au lancement de l'application (Android et iPhone), jamais sur le site.
   Même module dans tous les jeux Blo Games (voir tools/blo/README.md). Couleurs = logo Blo Games.

   DEUX RÈGLES À GARDER (version 2, voir intro.js) :
   1. Rien ne bouge tant que <html> n'a pas la classe « blo-joue » : intro.js la pose avec la première image
      réellement dessinée. Avant, les animations pouvaient partir pendant que l'écran était encore noir.
   2. On n'anime QUE transform et opacity. Le téléphone joue ces deux-là tout seul, même quand le jeu qui se
      charge bloque le reste ; background-position ou box-shadow, eux, se figent. */
#bloIntro{display:none}
html.blo-intro #bloIntro{display:flex;position:fixed;inset:0;z-index:2147483647;align-items:center;justify-content:center;overflow:hidden;
  background:linear-gradient(124deg,#ff5e3a 0%,#7c3aed 100%);will-change:opacity;-webkit-user-select:none;user-select:none}
/* la sortie : 1,45 s de spectacle puis 0,38 s de fondu (mêmes temps que DUREE et FONDU dans intro.js) */
html.blo-joue #bloIntro{animation:bloSortie .38s ease 1.45s both}
/* fin demandée par intro.js (robots testeurs) */
html.blo-intro.blo-fin #bloIntro{animation:none;opacity:0;pointer-events:none;transition:opacity .35s ease}
#bloIntro .bulle{position:absolute;border-radius:50%;background:rgba(255,255,255,.14)}
#bloIntro .b1{width:70vmax;height:70vmax;left:-30vmax;bottom:-35vmax}
#bloIntro .b2{width:55vmax;height:55vmax;right:-25vmax;top:-28vmax}
#bloIntro .marque{position:relative;width:min(84vw,430px);aspect-ratio:1;opacity:0;will-change:transform,opacity}
html.blo-joue #bloIntro .marque{animation:bloEntree .55s cubic-bezier(.2,1.4,.4,1) both}
#bloIntro .marque img{display:block;width:100%;height:100%}
/* le point jaune tombe sur le « O » et rebondit */
#bloIntro .point{position:absolute;left:66%;top:23%;width:14%;height:14%;border-radius:50%;background:#ffd60a;opacity:0;will-change:transform,opacity}
html.blo-joue #bloIntro .point{animation:bloPoint .6s cubic-bezier(.3,1.6,.5,1) .3s both}
/* l'onde autour du point : un disque qui grandit et s'efface */
#bloIntro .point::after{content:'';position:absolute;inset:0;border-radius:50%;background:#ffd60a;opacity:0;will-change:transform,opacity}
html.blo-joue #bloIntro .point::after{animation:bloOnde .7s ease-out .85s both}
/* reflet qui traverse le texte : une bande claire qui glisse derrière un masque à la forme des lettres */
#bloIntro .reflet{position:absolute;inset:0;overflow:hidden;
  -webkit-mask:url(blo-games-texte.png) center/100% no-repeat;mask:url(blo-games-texte.png) center/100% no-repeat}
#bloIntro .reflet::before{content:'';position:absolute;top:0;bottom:0;left:0;width:250%;transform:translateX(-72%);will-change:transform;
  background:linear-gradient(105deg,transparent 35%,rgba(255,255,255,.55) 50%,transparent 65%)}
html.blo-joue #bloIntro .reflet::before{animation:bloReflet .7s ease-in-out .8s both}
@keyframes bloSortie{to{opacity:0}}
@keyframes bloEntree{from{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}
@keyframes bloPoint{from{opacity:0;transform:translateY(-260%) scale(.6)}60%{opacity:1}to{opacity:1;transform:none}}
@keyframes bloOnde{from{opacity:.6;transform:scale(1)}to{opacity:0;transform:scale(2.1)}}
@keyframes bloReflet{from{transform:translateX(-72%)}to{transform:translateX(12%)}}
/* mouvement réduit : pas de spectacle, le logo est simplement là — la sortie, elle, reste */
@media (prefers-reduced-motion:reduce){
  html.blo-joue #bloIntro .marque,html.blo-joue #bloIntro .point{animation:none;opacity:1}
  html.blo-joue #bloIntro .point::after,html.blo-joue #bloIntro .reflet::before{animation:none}
}
