/* ==========================================================================
   Chargements aux couleurs de WeddingPart (octobre 2026)
   - Écran de lancement de l'appli installée : le logo se dessine (template-parts/global/launch.php)
   - Chargement des éditeurs (plan de salle, plan technique, aménagement, panneau) :
     la bague se trace en boucle au lieu de la roue qui tourne.
   ========================================================================== */

#wp-launch { display: none; }
#wp-launch.is-on {
  position: fixed; inset: 0; z-index: 2147483000;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px;
  padding: env(safe-area-inset-top, 0) 24px env(safe-area-inset-bottom, 0);
  background: radial-gradient(110% 80% at 50% 40%, #FFFFFF 0%, #FDFAF8 55%, #F6ECEF 100%);
  transition: opacity .5s ease, visibility 0s linear .5s;
  -webkit-user-select: none; user-select: none;
}
#wp-launch.is-on::before { /* halo rose et or derrière le logo */
  content: ''; position: absolute; width: min(90vw, 620px); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, rgba(181, 99, 122, .12) 0%, rgba(201, 168, 124, .08) 38%, transparent 68%);
  animation: wp-launch-halo 2.8s ease-out both;
}
#wp-launch.is-out { opacity: 0; visibility: hidden; pointer-events: none; }
#wp-launch.is-out .wp-launch__logo { transform: scale(1.04); transition: transform .5s ease; }
.wp-launch__logo { position: relative; width: min(82vw, 440px); height: auto; }
.wp-launch__bar { /* fine barre de progression sous le logo */
  position: relative; width: 120px; height: 2px; border-radius: 2px; overflow: hidden;
  background: rgba(181, 99, 122, .14);
}
.wp-launch__bar::after {
  content: ''; position: absolute; inset: 0; width: 40%; border-radius: 2px;
  background: linear-gradient(90deg, transparent, #B5637A, transparent);
  animation: wp-launch-slide 1.3s ease-in-out infinite .6s;
  transform: translateX(-100%);
}
@keyframes wp-launch-halo { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: none; } }
@keyframes wp-launch-slide { from { transform: translateX(-100%); } to { transform: translateX(260%); } }

/* Éditeurs lourds : la bague WeddingPart se trace au lieu de la roue */
.idd-ps-loader__spinner,
.idd-pt-loader__spinner,
.idd-am-loader__spinner,
.idd-pb-loader__spinner {
  width: 58px !important;
  height: 81px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: url('../images/brand/logo-mark-anim-v3.svg') center / contain no-repeat !important;
  animation: none !important;
}

@media (prefers-reduced-motion: reduce) {
  #wp-launch.is-on::before, .wp-launch__bar::after { animation: none; }
}
