/* Intro logo — 1re ouverture accueil
   Séquence: fond blanc → assombrissement → vol vers brand */
html {
  scrollbar-gutter: stable;
}
html.logo-intro-pending,
html.logo-intro-pending body,
html.logo-intro-running,
html.logo-intro-running body {
  overflow: hidden !important;
}
/* Blanc dès le premier paint (avant l’overlay JS) */
html.logo-intro-pending,
html.logo-intro-pending body {
  background: #ffffff !important;
}
html.logo-intro-dark,
html.logo-intro-dark body {
  background: #141210 !important;
}
html.logo-intro-pending .brand img,
html.logo-intro-running:not(.logo-intro-handoff) .brand img {
  opacity: 0 !important;
}
html.logo-intro-handoff .brand img {
  opacity: 1 !important;
  visibility: visible !important;
}
html.logo-intro-running .site-header {
  pointer-events: none;
}

/* Contenu page figé jusqu’à la fin du vol logo */
html.logo-intro-running:not(.logo-intro-reveal) .nav,
html.logo-intro-running:not(.logo-intro-reveal) .nav-toggle {
  opacity: 0 !important;
  visibility: hidden !important;
}
html.logo-intro-running:not(.logo-intro-reveal) .fx-line,
html.logo-intro-running:not(.logo-intro-reveal) .fx-hero__copy .fx-kicker,
html.logo-intro-running:not(.logo-intro-reveal) .fx-hero__text,
html.logo-intro-running:not(.logo-intro-reveal) .fx-motto,
html.logo-intro-running:not(.logo-intro-reveal) .fx-actions,
html.logo-intro-running:not(.logo-intro-reveal) .fx-hero__stage {
  animation: none !important;
  opacity: 0 !important;
  transform: translateY(1.1em);
  clip-path: inset(0 100% 0 0);
}
html.logo-intro-reveal .nav,
html.logo-intro-reveal .nav-toggle {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.logo-intro {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
}
.logo-intro[hidden] {
  display: none !important;
}
.logo-intro__veil {
  position: absolute;
  inset: 0;
  background: #ffffff;
  opacity: 1;
  transition:
    background-color 1.1s cubic-bezier(0.45, 0, 0.55, 1),
    opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}
.logo-intro.is-dark .logo-intro__veil {
  background: #141210;
}
.logo-intro__mark {
  position: fixed;
  left: 50%;
  top: 50%;
  width: min(78vw, 26rem);
  height: auto;
  max-height: 58vh;
  object-fit: contain;
  object-position: center;
  transform: translate(-50%, -50%);
  transform-origin: center center;
  z-index: 2;
  margin: 0;
  padding: 0;
  border: 0;
  /* Ombre légère sur blanc ; se renforce avec le fond sombre */
  filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.1));
  opacity: 1;
  transition: filter 1.1s cubic-bezier(0.45, 0, 0.55, 1);
}
.logo-intro.is-dark .logo-intro__mark {
  filter: drop-shadow(0 12px 40px rgba(0, 0, 0, 0.45));
}
.logo-intro.is-leaving .logo-intro__veil {
  opacity: 0;
}
.logo-intro.is-flying .logo-intro__mark {
  max-height: none;
  max-width: none;
  transform: none;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.5));
}
.logo-intro.is-done {
  visibility: hidden;
  pointer-events: none;
}
