/*
 * Blondeau — Transitions : Intro Screen & Inter-pages
 * ======================================================
 * 1.  Variables & base
 * 2.  Intro Screen — base
 * 3.  Intro Screen — Style A (Rideau royal)
 * 4.  Intro Screen — Style B (Glisse élégante)
 * 5.  Intro Screen — Style C (Signature dorée)
 * 6.  Intro Screen — Style D (Flash cinéma)
 * 7.  Intro Screen — Logo & bouton passer
 * 8.  Intro Screen — États JS
 * 9.  Transition inter-pages — base
 * 10. Transition — Style 1 (Fondu)
 * 11. Transition — Style 2 (Rideau haut)
 * 12. Transition — Style 3 (Rideau bas)
 * 13. Transition — Style 4 (Diagonal)
 * 14. Réduction de mouvement
 *
 * DURÉES :
 *   --blc-trans-dur  injecté en style inline par PHP (trans_duration ms)
 *   --blc-intro-dur  positionné par JS sur #blc-intro (introDuration ms)
 *   Toutes les sous-animations intro utilisent calc(var(--blc-intro-dur) * %)
 */


/* ============================================================
   1. VARIABLES & BASE
   ============================================================ */

:root {
  --blc-dark:          #06090f;
  --blc-dark-mid:      #0d1220;
  --blc-dark-panel:    #112036;
  --blc-curtain-main:  #0e1a2e;
  --blc-curtain-mid:   #1a2d4a;
  --blc-curtain-edge:  #080e1c;
  --blc-gold:          #CCA63B;
  --blc-gold-bright:   #f0d070;
  --blc-gold-dim:      rgba(204, 166, 59, 0.55);
  --blc-white:         #FFFFFF;

  /* Z-indexes : au-dessus de tout, y compris les footers sticky */
  --blc-z-intro:       999999;
  --blc-z-trans:       99999;

  /* Durée overlay inter-pages (fallback — PHP injecte la vraie valeur en inline style) */
  --blc-trans-dur:     500ms;

  /* Durée intro screen (fallback — JS positionne la vraie valeur sur #blc-intro) */
  --blc-intro-dur:     2000ms;
}


/* ============================================================
   2. INTRO SCREEN — BASE
   ============================================================ */

#blc-intro {
  position: fixed;
  inset: 0;
  z-index: var(--blc-z-intro);
  background: var(--blc-dark-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden; /* clip les panneaux qui débordent pendant l'animation */
  visibility: hidden;
  pointer-events: none;
}

/* Affiché uniquement si JS a posé blc-intro-pending sur <html> */
.blc-intro-pending #blc-intro {
  visibility: visible;
  pointer-events: auto;
}

/* Terminé : masquer */
#blc-intro.blc-intro--done {
  display: none !important;
}


/* ============================================================
   3. INTRO SCREEN — STYLE A : RIDEAU ROYAL
   Deux lourds rideaux de velours se ferment depuis les bords,
   révèlent le logo, puis s'ouvrent en grand.
   ============================================================ */

/* Fond transparent — les panneaux couvrent tout */
#blc-intro.blc-intro--style-a {
  background: transparent;
}

/* ── Tringle dorée en haut ────────────────────────────────── */
#blc-intro.blc-intro--style-a::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 14px;
  background: linear-gradient(
    to bottom,
    #7a6220 0%,
    var(--blc-gold) 20%,
    var(--blc-gold-bright) 48%,
    var(--blc-gold) 75%,
    #7a6220 100%
  );
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.6), 0 1px 0 rgba(255, 215, 0, 0.25);
  z-index: 12;
}

/* ── Panneau générique ────────────────────────────────────── */
#blc-intro.blc-intro--style-a .blc-intro__panel {
  position: absolute;
  top: 0;
  height: 100%;
  width: 50.3%; /* léger chevauchement pour éviter le gap 1px */
  will-change: transform;
}

/* ── Panneau gauche ───────────────────────────────────────── */
#blc-intro.blc-intro--style-a .blc-intro__panel--left {
  left: 0;
  background:
    /* Ombre à l'arête intérieure (profondeur du pli central) */
    linear-gradient(to right, transparent 80%, rgba(0, 0, 0, 0.55) 100%),
    /* Ombre sous la tringle */
    linear-gradient(to bottom, rgba(0, 0, 0, 0.35) 0%, transparent 8%),
    /* Texture velours : plis verticaux répétés */
    repeating-linear-gradient(
      90deg,
      rgba(255,255,255,0)    0px,
      rgba(255,255,255,0.02) 6px,
      rgba(0,0,0,0.12)       12px,
      rgba(255,255,255,0.01) 18px,
      rgba(0,0,0,0)          24px
    ),
    /* Couleur base velours avec reflet gauche */
    linear-gradient(
      to right,
      var(--blc-curtain-edge) 0%,
      var(--blc-curtain-main) 15%,
      var(--blc-curtain-mid)  40%,
      var(--blc-curtain-main) 65%,
      var(--blc-curtain-edge) 85%,
      rgba(0, 0, 0, 0.5)     100%
    );
  /* Entrée : vient du bord gauche — 50 % de la durée totale */
  transform: translateX(-100%);
  animation: blcPanelLeftIn calc(var(--blc-intro-dur) * 0.50) cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ── Panneau droit (miroir) ───────────────────────────────── */
#blc-intro.blc-intro--style-a .blc-intro__panel--right {
  right: 0;
  background:
    linear-gradient(to left, transparent 80%, rgba(0, 0, 0, 0.55) 100%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.35) 0%, transparent 8%),
    repeating-linear-gradient(
      90deg,
      rgba(255,255,255,0)    0px,
      rgba(255,255,255,0.02) 6px,
      rgba(0,0,0,0.12)       12px,
      rgba(255,255,255,0.01) 18px,
      rgba(0,0,0,0)          24px
    ),
    linear-gradient(
      to left,
      var(--blc-curtain-edge) 0%,
      var(--blc-curtain-main) 15%,
      var(--blc-curtain-mid)  40%,
      var(--blc-curtain-main) 65%,
      var(--blc-curtain-edge) 85%,
      rgba(0, 0, 0, 0.5)     100%
    );
  /* Entrée : vient du bord droit — 50 % de la durée totale */
  transform: translateX(100%);
  animation: blcPanelRightIn calc(var(--blc-intro-dur) * 0.50) cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes blcPanelLeftIn  { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes blcPanelRightIn { from { transform: translateX(100%); }  to { transform: translateX(0); } }

/* ── Ligne dorée centrale — apparaît après la jonction des volets ── */
#blc-intro.blc-intro--style-a .blc-intro__line {
  position: absolute;
  top: 14px;   /* sous la tringle */
  left: calc(50% - 1.5px);
  width: 3px;
  height: calc(100% - 14px);
  background: linear-gradient(
    to bottom,
    var(--blc-gold)           0%,
    var(--blc-gold-bright)   25%,
    var(--blc-gold)          75%,
    rgba(204, 166, 59, 0.2)  100%
  );
  opacity: 0;
  z-index: 6;
  /* Halo doré */
  box-shadow:
    0 0 8px  3px rgba(204, 166, 59, 0.7),
    0 0 24px 8px rgba(204, 166, 59, 0.3);
  /* Apparaît à 42 % de la durée, dure 12 % */
  animation: blcLineAppear calc(var(--blc-intro-dur) * 0.12) ease calc(var(--blc-intro-dur) * 0.42) both;
}

@keyframes blcLineAppear { to { opacity: 0.9; } }

/* ── Logo après fermeture des volets ─────────────────────── */
#blc-intro.blc-intro--style-a .blc-intro__logo {
  position: relative;
  z-index: 8;
  /* Apparaît à 45 % de la durée, dure 15 % */
  animation: blcLogoRoyalIn calc(var(--blc-intro-dur) * 0.15) cubic-bezier(0.34, 1.56, 0.64, 1) calc(var(--blc-intro-dur) * 0.45) both;
}

@keyframes blcLogoRoyalIn {
  from { opacity: 0; transform: scale(0.86) translateY(10px); filter: blur(4px); }
  to   { opacity: 1; transform: scale(1) translateY(0);       filter: blur(0);   }
}

/* ── Exit : volets s'écartent en accélérant — 30 % de la durée totale ── */
#blc-intro.blc-intro--style-a.blc-intro--exiting .blc-intro__panel--left {
  animation: blcPanelLeftOut calc(var(--blc-intro-dur) * 0.30) cubic-bezier(0.55, 0, 1, 0.45) forwards;
}

#blc-intro.blc-intro--style-a.blc-intro--exiting .blc-intro__panel--right {
  animation: blcPanelRightOut calc(var(--blc-intro-dur) * 0.30) cubic-bezier(0.55, 0, 1, 0.45) forwards;
}

#blc-intro.blc-intro--style-a.blc-intro--exiting .blc-intro__line {
  animation: blcFadeOut calc(var(--blc-intro-dur) * 0.08) ease forwards;
}

#blc-intro.blc-intro--style-a.blc-intro--exiting .blc-intro__logo {
  animation: blcFadeOut calc(var(--blc-intro-dur) * 0.10) ease forwards;
}

/* from explicite obligatoire : quand l'exit remplace l'entry (fill:both),
   la valeur CSS sous-jacente (translateX(-100%)) redeviendrait le départ
   implicite, rendant le mouvement quasi invisible (−100% → −102%). */
@keyframes blcPanelLeftOut  { from { transform: translateX(0); }  to { transform: translateX(-102%); } }
@keyframes blcPanelRightOut { from { transform: translateX(0); }  to { transform: translateX(102%);  } }


/* ============================================================
   4. INTRO SCREEN — STYLE B : GLISSE ÉLÉGANTE
   Grand panneau qui monte depuis le bas, avec un reflet or
   sur son bord avant. Logo révélé avec une légère élasticité.
   ============================================================ */

#blc-intro.blc-intro--style-b {
  background:
    /* Dégradé au bas du panneau */
    linear-gradient(to bottom, var(--blc-dark-panel) 75%, rgba(6, 12, 24, 0.95) 100%),
    var(--blc-dark-mid);
  /* Fil doré sur le bord supérieur (bord avant du rideau qui monte) */
  border-top: 3px solid transparent;
  /* Entrée : 50 % de la durée totale */
  transform: translateY(100%);
  animation: blcSlideInFromBottom calc(var(--blc-intro-dur) * 0.50) cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* Reflet doré sur le bord avant */
#blc-intro.blc-intro--style-b::before {
  content: '';
  position: absolute;
  top: -3px; /* sur le bord du panneau */
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--blc-gold) 20%,
    var(--blc-gold-bright) 50%,
    var(--blc-gold) 80%,
    transparent 100%
  );
  box-shadow: 0 0 16px 4px rgba(204, 166, 59, 0.55);
  z-index: 2;
}

/* Texture subtile en lignes horizontales */
#blc-intro.blc-intro--style-b::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent         0px,
    transparent         56px,
    rgba(255,255,255,0.012) 56px,
    rgba(255,255,255,0.012) 57px
  );
  pointer-events: none;
  z-index: 1;
}

#blc-intro.blc-intro--style-b .blc-intro__logo {
  position: relative;
  z-index: 3;
  /* Logo : delay 42 %, durée 15 % */
  animation: blcLogoSlideIn calc(var(--blc-intro-dur) * 0.15) cubic-bezier(0.34, 1.56, 0.64, 1) calc(var(--blc-intro-dur) * 0.42) both;
}

@keyframes blcLogoSlideIn {
  from { opacity: 0; transform: translateY(20px) scale(0.92); }
  to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

#blc-intro.blc-intro--style-b.blc-intro--exiting {
  /* Sortie : 30 % de la durée totale */
  animation: blcSlideUp calc(var(--blc-intro-dur) * 0.30) cubic-bezier(0.55, 0, 1, 0.45) forwards;
}

@keyframes blcSlideInFromBottom { from { transform: translateY(100%); } to { transform: translateY(0); } }
@keyframes blcSlideUp           { from { transform: translateY(0); }    to { transform: translateY(-102%); } }


/* ============================================================
   5. INTRO SCREEN — STYLE C : SIGNATURE DORÉE
   Fond sombre. Une ligne lumineuse or balaie l'écran de gauche
   à droite, laissant un sillage, puis le logo est révélé.
   ============================================================ */

/* Ligne principale — trait d'or fin */
#blc-intro.blc-intro--style-c .blc-intro__line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  transform: translateX(-110%) translateY(-50%);
  z-index: 3;
  /* Balayage : delay 8 %, durée 38 % → finit à 46 % du total */
  animation: blcLineSweep calc(var(--blc-intro-dur) * 0.38) cubic-bezier(0.4, 0, 0.2, 1) calc(var(--blc-intro-dur) * 0.08) both;
}

/* Trait doré lui-même */
#blc-intro.blc-intro--style-c .blc-intro__line::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent              0%,
    rgba(204, 166, 59, 0.4) 15%,
    var(--blc-gold)          40%,
    var(--blc-gold-bright)   50%,
    var(--blc-gold)          60%,
    rgba(204, 166, 59, 0.4) 85%,
    transparent              100%
  );
}

/* Halo lumineux large (bloom) */
#blc-intro.blc-intro--style-c .blc-intro__line::after {
  content: '';
  position: absolute;
  top: -14px;
  left: 0;
  right: 0;
  height: 30px;
  background: linear-gradient(
    90deg,
    transparent                       0%,
    rgba(204, 166, 59, 0)             10%,
    rgba(204, 166, 59, 0.35)         40%,
    rgba(255, 220, 100, 0.55)        50%,
    rgba(204, 166, 59, 0.35)         60%,
    rgba(204, 166, 59, 0)             90%,
    transparent                       100%
  );
  filter: blur(8px);
}

@keyframes blcLineSweep {
  to { transform: translateX(110%) translateY(-50%); }
}

/* Logo révélé après le passage de la ligne */
#blc-intro.blc-intro--style-c .blc-intro__logo {
  opacity: 0;
  transform: translateY(14px);
  /* Logo : delay 46 %, durée 17 % → visible à 63 %, maintenu jusqu'à l'exit (70 %) */
  animation: blcLogoReveal calc(var(--blc-intro-dur) * 0.17) cubic-bezier(0.22, 1, 0.36, 1) calc(var(--blc-intro-dur) * 0.46) forwards;
}

@keyframes blcLogoReveal {
  to { opacity: 1; transform: translateY(0); }
}

/* Exit : fondu + légère montée */
#blc-intro.blc-intro--style-c.blc-intro--exiting {
  /* Sortie : 30 % de la durée totale */
  animation: blcFadeSlideUp calc(var(--blc-intro-dur) * 0.30) cubic-bezier(0.55, 0, 1, 0.45) forwards;
}

@keyframes blcFadeSlideUp {
  to { opacity: 0; transform: translateY(-18px); }
}


/* ============================================================
   6. INTRO SCREEN — STYLE D : FLASH CINÉMA
   Flash blanc fulgurant depuis le centre, puis assombrissement
   rapide → fond sombre avec logo qui surgit.
   ============================================================ */

#blc-intro.blc-intro--style-d {
  background: var(--blc-dark-mid);
  /* Apparition du fond : 22 % de la durée totale */
  animation: blcFadeIn calc(var(--blc-intro-dur) * 0.22) ease forwards;
}

/* Flash blanc — pseudo-élément qui disparaît vite */
#blc-intro.blc-intro--style-d::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at 50% 45%,
    rgba(255, 255, 255, 1)   0%,
    rgba(255, 255, 255, 0.8) 25%,
    rgba(255, 255, 255, 0)   70%
  );
  /* Flash : 25 % de la durée totale */
  animation: blcFlashBurst calc(var(--blc-intro-dur) * 0.25) ease-out forwards;
  z-index: 2;
  pointer-events: none;
}

@keyframes blcFlashBurst {
  0%   { opacity: 1; transform: scale(0.85); }
  20%  { opacity: 0.9; transform: scale(1.05); }
  100% { opacity: 0; transform: scale(1.2); }
}

/* Logo : surgit après le flash */
#blc-intro.blc-intro--style-d .blc-intro__logo {
  position: relative;
  z-index: 3;
  /* Logo : delay 14 %, durée 22 % → visible à 36 % */
  animation: blcLogoBurst calc(var(--blc-intro-dur) * 0.22) cubic-bezier(0.34, 1.56, 0.64, 1) calc(var(--blc-intro-dur) * 0.14) both;
}

@keyframes blcLogoBurst {
  from { opacity: 0; transform: scale(1.25); filter: blur(3px); }
  to   { opacity: 1; transform: scale(1);    filter: blur(0);   }
}

#blc-intro.blc-intro--style-d.blc-intro--exiting {
  /* Sortie : 30 % de la durée totale */
  animation: blcFlashExit calc(var(--blc-intro-dur) * 0.30) ease forwards;
}

@keyframes blcFlashExit {
  0%   { opacity: 1; }
  40%  { opacity: 1;   filter: brightness(1.5); }
  100% { opacity: 0;   filter: brightness(1); }
}

@keyframes blcFadeIn  { to { opacity: 1; } }
@keyframes blcFadeOut { to { opacity: 0; } }


/* ============================================================
   7. INTRO SCREEN — LOGO & BOUTON PASSER
   ============================================================ */

/* Logo — base commune (position, centrage) */
.blc-intro__logo {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  /* Pas d'animation ici : chaque style définit la sienne dans sa section */
}

/* Animation par défaut (uniquement si aucun style spécifique ne la surcharge) */
@keyframes blcLogoFadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

.blc-overlay-logo__img {
  max-width: 200px;
  max-height: 90px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.blc-overlay-logo__name {
  color: var(--blc-white);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Fondu du logo à l'exit (style B — style A a sa propre règle dans sa section) */
#blc-intro.blc-intro--style-b.blc-intro--exiting .blc-intro__logo {
  animation: blcFadeOut calc(var(--blc-intro-dur) * 0.10) ease forwards;
}

@keyframes blcLogoFadeOut {
  to { opacity: 0; transform: scale(0.94); }
}

/* Bouton passer */
.blc-intro__skip {
  position: absolute;
  bottom: 32px;
  right: 40px;
  z-index: 20;
  background: transparent;
  border: 1px solid var(--blc-gold-dim);
  color: rgba(204, 166, 59, 0.8);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 7px 18px;
  border-radius: 30px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  display: none;
}

.blc-intro__skip:hover {
  border-color: var(--blc-gold);
  color: var(--blc-gold);
  background: rgba(204, 166, 59, 0.07);
}

/* Masquer les éléments non utilisés selon le style */
#blc-intro:not(.blc-intro--style-a) .blc-intro__panel,
#blc-intro:not(.blc-intro--style-a):not(.blc-intro--style-c) .blc-intro__line {
  display: none;
}


/* ============================================================
   8. INTRO SCREEN — ÉTATS JS
   ============================================================ */

.blc-intro-pending body {
  overflow: hidden;
}


/* ============================================================
   9. TRANSITION INTER-PAGES — BASE & COULEURS PAR STYLE
   ============================================================ */

#blc-transition {
  position: fixed;
  inset: 0;
  z-index: var(--blc-z-trans);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  will-change: transform, opacity;
  background: var(--blc-dark-mid);
}

/* Fond sombre pour les rideaux */
#blc-transition.blc-transition--style-2,
#blc-transition.blc-transition--style-3,
#blc-transition.blc-transition--style-4 {
  background: var(--blc-dark-mid);
}

/* Pendant la transition entrante : bloquer les interactions */
.blc-page-loading #blc-transition {
  pointer-events: auto;
}
/* Note : --blc-trans-dur est injecté directement en style inline par PHP */


/* ============================================================
   10. TRANSITION — STYLE 1 : FONDU
   Utilise CSS transition (plus fiable qu'une keyframe pour un fade
   simple — évite les ambiguïtés sur le from implicite).
   ============================================================ */

/* Caché au départ, prêt pour la transition */
#blc-transition.blc-transition--style-1 {
  background: var(--color-bg, #ffffff);
  opacity: 0;
  transition: opacity var(--blc-trans-dur) ease;
}

/* Couverture : ajouter opacity:1 déclenche la transition CSS */
#blc-transition.blc-transition--style-1.blc-covering,
#blc-transition.blc-transition--style-1.blc-covered,
.blc-page-loading #blc-transition.blc-transition--style-1 {
  opacity: 1;
}

/* Révélation : retour à opacity:0 → la transition joue depuis opacity:1 */
#blc-transition.blc-transition--style-1.blc-revealing {
  opacity: 0;
}

@keyframes blcTransFadeOut { from { opacity: 1; } to { opacity: 0; } }


/* ============================================================
   11. TRANSITION — STYLE 2 : RIDEAU HAUT
   L'overlay tombe du haut → couvre → puis remonte.
   ============================================================ */

#blc-transition.blc-transition--style-2 {
  transform: translateY(-100%);
}

#blc-transition.blc-transition--style-2.blc-covering {
  animation: blcCoverFromTop var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

#blc-transition.blc-transition--style-2.blc-covered,
.blc-page-loading #blc-transition.blc-transition--style-2 {
  transform: translateY(0);
}

#blc-transition.blc-transition--style-2.blc-revealing {
  transform: translateY(0);
  animation: blcRevealToTop var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

@keyframes blcCoverFromTop { from { transform: translateY(-100%); } to { transform: translateY(0); } }
@keyframes blcRevealToTop  { from { transform: translateY(0); }    to { transform: translateY(-100%); } }


/* ============================================================
   12. TRANSITION — STYLE 3 : RIDEAU BAS
   L'overlay monte du bas → couvre → puis redescend.
   ============================================================ */

#blc-transition.blc-transition--style-3 {
  transform: translateY(100%);
}

#blc-transition.blc-transition--style-3.blc-covering {
  animation: blcCoverFromBottom var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

#blc-transition.blc-transition--style-3.blc-covered,
.blc-page-loading #blc-transition.blc-transition--style-3 {
  transform: translateY(0);
}

#blc-transition.blc-transition--style-3.blc-revealing {
  transform: translateY(0);
  animation: blcRevealToBottom var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

@keyframes blcCoverFromBottom { from { transform: translateY(100%); } to { transform: translateY(0); } }
@keyframes blcRevealToBottom  { from { transform: translateY(0); }   to { transform: translateY(100%); } }


/* ============================================================
   13. TRANSITION — STYLE 4 : DIAGONAL
   Balayage en diagonale depuis le coin gauche.
   ============================================================ */

/* transform-origin: top left → le coin haut-gauche de l'overlay reste
   à x=-5vw (hors-écran). Avec l'origine au centre (défaut 50% 50%),
   skewX(-8deg) décalerait le bord supérieur de +7vw vers la droite,
   laissant un triangle blanc visible en haut-gauche.
   width: 125vw couvre aussi le coin bas-droit (recul de ≈14vw dû au skew). */
#blc-transition.blc-transition--style-4 {
  left: -5vw;
  width: 125vw;
  transform-origin: top left;
  transform: skewX(-8deg) translateX(calc(-100% - 10vw));
}

#blc-transition.blc-transition--style-4.blc-covering {
  animation: blcDiagCover var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

#blc-transition.blc-transition--style-4.blc-covered,
.blc-page-loading #blc-transition.blc-transition--style-4 {
  transform: skewX(-8deg) translateX(0);
}

#blc-transition.blc-transition--style-4.blc-revealing {
  transform: skewX(-8deg) translateX(0);
  animation: blcDiagReveal var(--blc-trans-dur) cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

@keyframes blcDiagCover {
  from { transform: skewX(-8deg) translateX(calc(-100% - 10vw)); }
  to   { transform: skewX(-8deg) translateX(0); }
}
@keyframes blcDiagReveal {
  from { transform: skewX(-8deg) translateX(0); }
  to   { transform: skewX(-8deg) translateX(calc(100% + 10vw)); }
}


/* ============================================================
   14. RÉDUCTION DE MOUVEMENT
   ============================================================ */
/* Durée minimale cohérente avec getTransDuration() JS (80 ms) */

@media (prefers-reduced-motion: reduce) {
  /* Durée minimale (80ms = cohérent avec getTransDuration() JS réduit)
     pour que l'overlay reste visible sans animation longue. */
  #blc-intro,
  #blc-intro .blc-intro__panel,
  #blc-intro .blc-intro__logo,
  #blc-intro .blc-intro__line,
  #blc-intro::before,
  #blc-intro::after {
    animation-duration:  0.01ms !important;
    animation-delay:     0ms    !important;
  }
  #blc-transition {
    animation-duration:  80ms !important;
    animation-delay:     0ms  !important;
    transition-duration: 80ms !important;
  }
}
