/* ============================================================================
   tour-lk.css — décor cinématographique en arrière-plan de la landing LK Studio
   À charger APRÈS css/style.css.
   ========================================================================== */

/* --- La vidéo occupe tout l'écran, derrière le contenu --------------------
   object-fit: cover reproduit le cadrage plein écran quel que soit le ratio
   de la fenêtre. z-index -2 la place sous tout le contenu de la page.       */
#tour-lk-video {
  position: fixed;
  inset: 0;
  z-index: -2;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .8s ease;
  pointer-events: none;
}
#tour-lk-video.pret { opacity: 1; }

/* --- Voile : retiré ---------------------------------------------------------
   Un voile sombre (body::after, variable --voile) assombrissait le décor pour
   garder le texte clair lisible. Retiré à la demande : le coucher de soleil
   sort maintenant à sa luminosité réelle.
   Pour le remettre, réintroduire :
       :root { --voile: .58; }
       body::after { content:""; position:fixed; inset:0; z-index:-1;
                     pointer-events:none;
                     background: linear-gradient(180deg,
                       rgba(5,5,8,calc(var(--voile) + .12)) 0%,
                       rgba(5,5,8,var(--voile))            35%,
                       rgba(5,5,8,var(--voile))            65%,
                       rgba(5,5,8,calc(var(--voile) + .10)) 100%); }
   ::after et non ::before : index.html pose déjà body.studio-home::before.  */

/* --- Laisser passer le décor ---------------------------------------------- */
html, body { background: transparent !important; }


/* Les sections ne doivent pas masquer le décor. */
main, section, .section, .hero-content { background: transparent; }
footer { background: rgba(2, 2, 4, .82); }

/* ============================================================================
   LES TROIS PLANS
   Chaque plan occupe l'écran et n'apparaît que sur son étape. Le pilotage se
   fait entièrement par l'attribut data-etape posé sur <body> par tour-lk.js :
   aucun JavaScript de plus à écrire ici.
   ========================================================================== */
.plan {
  position: fixed;
  inset: 0;
  z-index: 2;
  display: grid;
  padding: clamp(1.75rem, 4.2vw, 4rem);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  /* Durée de DISPARITION : c'est l'état vers lequel on transite quand le plan
     cesse d'être actif. Volontairement court — sinon, le mouvement de caméra
     retour étant devenu rapide, on voyait encore le plan précédent s'effacer
     alors qu'on était déjà arrivé sur le suivant. */
  transition: opacity .12s ease, visibility .12s;
}

/* Durée d'APPARITION, portée par l'état actif : plus posée. */
body[data-etape="tour"]         .plan-tour,
body[data-etape="atelier"]      .plan-atelier,
body[data-etape="flightledger"] .plan-fl {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity .45s ease, visibility .45s;
}

/* Apparition : montée + net progressif, décalée élément par élément via --d.
   L'état de repos est porté par [data-anim], l'état d'arrivée par le plan
   actif — donc tout se rejoue à chaque passage, dans les deux sens. */
.plan [data-anim] {
  opacity: 0;
  transform: translateY(26px);
  filter: blur(7px);
  transition:
    opacity .75s cubic-bezier(.16, 1, .3, 1),
    transform .75s cubic-bezier(.16, 1, .3, 1),
    filter .75s cubic-bezier(.16, 1, .3, 1);
  transition-delay: var(--d, 0s);
}

body[data-etape="tour"]         .plan-tour [data-anim],
body[data-etape="atelier"]      .plan-atelier [data-anim],
body[data-etape="flightledger"] .plan-fl [data-anim] {
  opacity: 1;
  transform: none;
  filter: none;
}

/* ---- Transit : écran nu pendant le mouvement de caméra -------------------
   tour-lk.js pose .en-transit sur <body> dès le geste et l'enlève quand la
   caméra se pose. Le plan courant s'efface donc immédiatement, sans attendre
   le changement de data-etape qui n'intervient qu'à l'arrivée.
   Ces règles doivent rester APRÈS celles ci-dessus : elles ont la même
   spécificité, c'est l'ordre de la feuille qui les fait gagner.            */
body.en-transit .plan {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition-duration: .12s;
}

/* remise à l'état de départ, pour que l'entrée se rejoue entièrement */
body.en-transit .plan [data-anim] {
  opacity: 0;
  transform: translateY(26px);
  filter: blur(7px);
  transition-duration: .12s;
  transition-delay: 0s;
}

/* Exception : le carnet 3D ne se coupe pas. Il se referme et ressort du cadre
   pendant le mouvement de caméra, il faut donc que le plan 3 reste affiché le
   temps de cette sortie. Uniquement quand on QUITTE l'étape flightledger —
   d'où le sélecteur d'attribut, sans lequel le plan 3 apparaîtrait pendant
   toutes les autres transitions. */
body.en-transit[data-etape="flightledger"] .plan-fl {
  opacity: 1;
  visibility: visible;
}
body.en-transit[data-etape="flightledger"] .plan-fl .carnet-legende {
  opacity: 0;
}

/* --- Plan 1 : la tour ----------------------------------------------------- */
.plan-tour {
  grid-template-rows: 1fr auto;
  gap: clamp(1.5rem, 3vw, 3rem);
}

.plan-tour .plan-gauche {
  align-self: center;
  max-width: min(48vw, 640px);   /* la tour occupe le centre : on reste à gauche */
}

.plan-tour .marque {
  display: block;
  margin-bottom: clamp(1rem, 2vw, 1.75rem);
  font-family: 'DM Mono', monospace;
  font-size: .72rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .72);
}

/* Typographie reprise du grand titre d'origine : même graisse 500, même
   chasse très resserrée (-.07em), même interligne compact (.85), capitales.
   Seule la couleur change — blanc plutôt que crème. */
.plan-tour .titre-tour {
  margin: 0;
  font-family: var(--hero-sans);
  font-weight: 500;
  font-size: clamp(2.6rem, 6vw, 5.6rem);
  line-height: .85;
  letter-spacing: -.07em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 2px 40px rgba(0, 0, 0, .45);
}

.plan-tour .texte-ludens {
  margin: clamp(1.2rem, 2.4vw, 2rem) 0 0;
  max-width: 34em;
  font-family: var(--hero-sans);
  font-size: clamp(.86rem, 1.02vw, 1rem);
  line-height: 1.62;
  color: rgba(255, 255, 255, .9);
  text-shadow: 0 1px 22px rgba(0, 0, 0, .55);
}
.plan-tour .texte-ludens strong { color: #fff; font-weight: 600; }

.plan-tour .trois-textes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 3.4vw, 4rem);
  max-width: 1500px;
}

.plan-tour .trois-textes .num {
  display: block;
  padding-bottom: .55rem;
  margin-bottom: .8rem;
  border-bottom: 1px solid rgba(255, 255, 255, .28);
  font-family: 'DM Mono', monospace;
  font-size: .64rem;
  letter-spacing: .17em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .68);
}

.plan-tour .trois-textes h2 {
  margin: 0 0 .5rem;
  font-family: var(--hero-sans);
  font-weight: 600;
  font-size: clamp(1rem, 1.35vw, 1.3rem);
  letter-spacing: -.015em;
  color: #fff;
  text-shadow: 0 1px 20px rgba(0, 0, 0, .5);
}

.plan-tour .trois-textes p {
  margin: 0;
  font-family: var(--hero-sans);
  font-size: clamp(.8rem, .92vw, .9rem);
  line-height: 1.55;
  color: rgba(255, 255, 255, .84);
  text-shadow: 0 1px 18px rgba(0, 0, 0, .55);
}

/* Les deux appels à l'action du plan 1, empilés : « Convoquer un agent »
   en plein, « Nous contacter » en contour juste dessous. */
.plan-tour-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .7rem;
  margin-top: clamp(1.4rem, 2.6vw, 2.2rem);
}


/* Bouton secondaire du plan 1 : contour seul, pour ne pas concurrencer
   l'appel à l'action plein juste au-dessus. */
.bouton-contact,
.bouton-agent {
  display: inline-flex;
  align-items: center;
  gap: .8rem;
  padding: .68rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, .6);
  border-radius: 999px;
  background: transparent;
  color: #fff;
  font-family: var(--hero-sans);
  font-size: clamp(.82rem, .95vw, .94rem);
  font-weight: 500;
  cursor: pointer;
  transition: background .35s ease, color .35s ease, gap .35s ease, border-color .35s ease;
}
.bouton-contact:hover,
.bouton-agent:hover {
  background: #fff;
  border-color: #fff;
  color: #101010;
  gap: 1.1rem;
}

/* « Convoquer un agent » est un <a> et non un <button> : il faut lui retirer
   le soulignement. Sa graisse un peu plus marquée le laisse passer en premier
   à l'œil, sans rompre l'unité des deux boutons.
   Déclaré APRÈS la règle commune, sinon la graisse 500 l'écraserait. */
.bouton-agent {
  text-decoration: none;
  font-weight: 600;
}
.bouton-contact-fleche { display: flex; }
.bouton-contact-fleche svg { width: .95rem; height: .95rem; }

/* --- Plan 2 : l'atelier --------------------------------------------------- */
.plan-atelier { place-items: center; }

.plan-atelier .bloc-atelier { text-align: center; }

.plan-atelier .titre-atelier {
  margin: 0 0 clamp(1.6rem, 3vw, 2.6rem);
  font-family: var(--hero-sans);
  font-weight: 600;
  font-size: clamp(2rem, 4.4vw, 4rem);
  letter-spacing: -.04em;
  color: #fff;
  text-shadow: 0 2px 40px rgba(0, 0, 0, .5);
}

.bouton-galerie {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  padding: .95rem 1rem .95rem 2rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .55);
  backdrop-filter: blur(6px);
  color: #fff;
  font-family: var(--hero-sans);
  font-size: clamp(.9rem, 1.1vw, 1.05rem);
  font-weight: 500;
  text-decoration: none;
  overflow: hidden;
  transition: color .45s ease, border-color .45s ease, gap .45s ease;
}

/* remplissage qui balaie le bouton au survol */
.bouton-galerie::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #fff;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s cubic-bezier(.16, 1, .3, 1);
}
.bouton-galerie:hover { color: #101010; gap: 1.35rem; border-color: #fff; }
.bouton-galerie:hover::before { transform: scaleX(1); }

.bouton-galerie-texte,
.bouton-galerie-fleche { position: relative; z-index: 1; }

.bouton-galerie-fleche {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 999px;
  background: #fff;
  color: #101010;
  transition: background .45s ease, color .45s ease;
}
.bouton-galerie-fleche svg { width: 1.05rem; height: 1.05rem; }
.bouton-galerie:hover .bouton-galerie-fleche { background: #101010; color: #fff; }

/* --- Plan 3 : le carnet de vol, seul et centré -----------------------------
   Le cartouche militaire a été retiré : le carnet porte lui-même ses deux
   liens sur ses pages. */
.plan-fl { place-items: center; }

/* Le canvas occupe TOUT l'écran, sans quoi le carnet apparaîtrait et
   disparaîtrait au bord d'un cadre de 760 px posé au milieu de la page. Sa
   taille apparente n'est plus donnée par ce cadre mais par la distance de la
   caméra, recalculée à chaque redimensionnement dans carnet-fl.js. */
.plan-fl .carnet-colonne {
  position: absolute;
  inset: 0;
  min-width: 0;
}
.plan-fl .carnet-zone {
  position: absolute;
  inset: 0;
  width: auto;
  height: auto;
  max-width: none;
  aspect-ratio: auto;
  margin: 0;
}

/* la légende retrouve sa place, au-dessus du canvas */
.plan-fl .carnet-legende {
  position: absolute;
  left: 0;
  right: 0;
  bottom: clamp(1.5rem, 4vh, 3rem);
  z-index: 1;
}

.carnet-legende {
  transition: opacity .2s ease;
  margin: .8rem 0 0;
  text-align: center;
  font-family: 'DM Mono', monospace;
  font-size: .62rem;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: #8b9a6b;
  text-shadow: 0 1px 14px rgba(0, 0, 0, .6);
}

/* Le cartouche militaire (.dossier) a été retiré du plan 3 : le carnet
   porte désormais lui-même ses deux liens. Ses styles ont suivi. */

/* ============================================================================
   PANNEAU DE CONTACT — même typologie que le hero : grotesque, blanc,
   aucun cartouche brun, le décor reste visible derrière le flou.
   ========================================================================== */
.panneau {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 3vw, 2.5rem);
}
.panneau[hidden] { display: none; }

.panneau-fond {
  position: absolute;
  inset: 0;
  background: rgba(6, 8, 12, .74);
  backdrop-filter: blur(16px);
  opacity: 0;
  transition: opacity .4s ease;
}

.panneau-corps {
  position: relative;
  width: min(980px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  padding: clamp(1.6rem, 3.2vw, 3rem);
  font-family: var(--hero-sans);
  color: #fff;
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity .5s cubic-bezier(.16, 1, .3, 1),
    transform .5s cubic-bezier(.16, 1, .3, 1);
}

body.panneau-ouvert .panneau-fond { opacity: 1; }
body.panneau-ouvert .panneau-corps { opacity: 1; transform: none; }

.panneau-fermer {
  position: absolute;
  top: clamp(.6rem, 1.6vw, 1.2rem);
  right: clamp(.6rem, 1.6vw, 1.2rem);
  width: 2.4rem;
  height: 2.4rem;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 999px;
  background: transparent;
  color: #fff;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  transition: background .3s ease, color .3s ease;
}
.panneau-fermer:hover { background: #fff; color: #101010; }

.panneau-sur-titre {
  display: block;
  margin-bottom: .7rem;
  font-family: 'DM Mono', monospace;
  font-size: .66rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .68);
}

/* Préfixé par .studio-home : le <style> inline d'index.html est déclaré APRÈS
   cette feuille et impose 'DM Serif Display' à tous les h1/h2/h3. Sans ce
   surcroît de spécificité, les titres du panneau repassaient en serif. */
.studio-home .panneau-titre {
  margin: 0 0 clamp(1.6rem, 3vw, 2.4rem);
  font-family: var(--hero-sans);
  font-weight: 500;
  font-size: clamp(1.8rem, 3.6vw, 3rem);
  line-height: .95;
  letter-spacing: -.05em;
  color: #fff;
}

.panneau-grille {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(1.6rem, 3.4vw, 3.4rem);
  align-items: start;
}

.panneau-intro {
  margin: 0 0 1.6rem;
  font-size: .92rem;
  line-height: 1.62;
  color: rgba(255, 255, 255, .82);
}

.panneau-liens { margin: 0 0 1.6rem; padding: 0; list-style: none; }
.panneau-liens li {
  padding: .7rem 0;
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: .92rem;
}
.panneau-liens li:last-child { border-bottom: 1px solid rgba(255, 255, 255, .14); }
.panneau-liens a { color: #fff; text-decoration: none; transition: opacity .25s ease; }
.panneau-liens a:hover { opacity: .68; text-decoration: underline; }
.panneau-liens span { color: rgba(255, 255, 255, .78); }

.panneau-citation {
  margin: 0;
  font-size: .82rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, .55);
}

/* Mentions légales : le footer ayant été supprimé, le panneau de contact est
   devenu leur seul point d'accès. */
.panneau-legal {
  margin: 1.4rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: .74rem;
  color: rgba(255, 255, 255, .5);
}
.panneau-legal a { color: rgba(255, 255, 255, .75); }
.panneau-legal a:hover { color: #fff; }

.studio-home .panneau-formulaire h3 {
  margin: 0 0 1.2rem;
  font-family: var(--hero-sans);
  font-weight: 500;
  font-size: 1.05rem;
  letter-spacing: -.02em;
  color: #fff;
}

/* Le formulaire sort de #contact : ses styles d'origine, portés par cet
   ancêtre, ne s'appliquent plus. On les redonne ici, en clair sur sombre. */
.panneau label {
  font-family: var(--hero-sans);
  font-size: .78rem;
  color: rgba(255, 255, 255, .72);
}
.panneau .form-control {
  width: 100%;
  padding: .78rem .9rem;
  border: 1px solid rgba(255, 255, 255, .22) !important;
  border-radius: 2px;
  background: rgba(255, 255, 255, .06) !important;
  color: #fff;
  font-family: var(--hero-sans);
  font-size: .9rem;
  box-sizing: border-box;
}
.panneau .form-control::placeholder { color: rgba(255, 255, 255, .38); }
.panneau .form-control:focus {
  outline: none;
  border-color: rgba(255, 255, 255, .6) !important;
  background: rgba(255, 255, 255, .1) !important;
}
/* même raison : .studio-home .btn impose DM Mono en capitales espacées */
.studio-home .panneau .btn {
  width: 100%;
  padding: .85rem 1rem;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #101010;
  font-family: var(--hero-sans);
  font-size: .9rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  cursor: pointer;
  transition: opacity .3s ease;
}
.studio-home .panneau .btn:hover { opacity: .85; background: #fff; }

@media (max-width: 820px) {
  .panneau-grille { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .panneau-fond, .panneau-corps { transition: none; }
}

/* Sections d'origine conservées mais hors parcours.
   Le footer est masqué lui aussi : les plans étant en position fixed, le flux
   normal est vide et il remontait s'afficher en haut de l'écran.
   ATTENTION : il portait le lien « Mentions légales ». À reloger. */
.hors-parcours { display: none; }
body.studio-home footer { display: none; }

@media (max-width: 900px) {
  .plan-tour .plan-gauche { max-width: none; }
  .plan-tour .trois-textes { grid-template-columns: 1fr; gap: 1rem; }
  .plan-tour .trois-textes article:nth-child(n + 3) { display: none; }

  /* le carnet reste affiché mais prend toute la largeur disponible */
  .plan-fl .carnet-zone { max-width: 92vw; }
}

@media (prefers-reduced-motion: reduce) {
  .plan, .plan [data-anim] { transition: none; }
}

/* --- Boutons révélés par l'étape du parcours ------------------------------
   Le script pose data-etape sur <body> : aucun JavaScript à écrire.          */
.cta-atelier,
.cta-flightledger {
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity .55s ease, transform .55s ease;
}
body[data-etape="atelier"] .cta-atelier,
body[data-etape="flightledger"] .cta-flightledger {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

@media (prefers-reduced-motion: reduce) {
  #tour-lk-video, .cta-atelier, .cta-flightledger {
    transition: none;
  }
}

