/* ============================================================
   DANS LA NUIT, LE FEU — hero.css
   Section 0 : video plein ecran + baseline + ticker
   ============================================================ */

.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: var(--noir);
  isolation: isolate;          /* contexte de blend = la vidéo dessous */
  z-index: 60;                 /* au-dessus du grain global (vidéo + titre exclus) */
}

/* --- Video plein ecran, muette, loop --- */
.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* --- Titre recodé : positions absolues individuelles (coords éditeur) ---
   Ancrage au CENTRE de chaque mot (translate -50%,-50%), comme l'éditeur. */
.hero__title {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  mix-blend-mode: hard-light;
  filter: url(#hero-grain);            /* grain pellicule dans les lettres */
}

.ht {
  position: absolute;
  transform: translate(-50%, -50%);
  font-family: var(--f-titre);
  text-transform: uppercase;
  letter-spacing: 0;
  line-height: 1;
  color: #ffceaf;
  white-space: nowrap;
}

/* Graisses / styles par mot — les positions/tailles sont dans les 5 media
   queries ci-dessous (ancrage centre via .ht { translate(-50%,-50%) }). */
.ht--dans, .ht--la, .ht--le { font-weight: 100; font-style: italic; }
.ht--nuit { font-weight: 400; font-style: normal; }
.ht--feu  { font-weight: 100; font-style: normal; }

/* Animation séquentielle (déclenchée à la sortie de l'overlay) */
.ht__in { display: inline-block; opacity: 0; }
.hero.is-revealed .ht__in {
  animation-name: riseIn;
  animation-duration: 1.6s;
  animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
  animation-fill-mode: both;
}
.ht--dans .ht__in { animation-delay: 0.3s; }
.ht--la   .ht__in { animation-delay: 0.7s; }
.ht--nuit .ht__in { animation-delay: 1.1s; }
.ht--le   .ht__in { animation-delay: 1.8s; }
.ht--feu  .ht__in { animation-delay: 2.3s; }

@keyframes riseIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ═══ DESKTOP 1440+ ═══ — NE PLUS JAMAIS MODIFIER */
@media (min-width: 1281px) {
  .ht--dans      { left:17%;  top:18%; font-size:3.2vw;  }
  .ht--la        { left:31%;  top:23%; font-size:3.2vw;  }
  .ht--nuit      { left:29%;  top:49%; font-size:24vw;   }
  .ht--le        { left:52%;  top:49%; font-size:3.2vw;  }
  .ht--feu       { left:74%;  top:59%; font-size:24.5vw; }
  .hero__baseline { left:20%; top:92%; font-size:1.7vw;  }
  .scroll-cue    { left:50%;  top:92%; font-size:0.85vw; }
}

/* ═══ LARGE 1280 ═══ — NE PLUS JAMAIS MODIFIER */
@media (min-width:1025px) and (max-width:1280px) {
  .ht--dans      { left:17%;  top:18%; font-size:3.2vw;  }
  .ht--la        { left:31%;  top:24%; font-size:3.2vw;  }
  .ht--nuit      { left:30%;  top:48%; font-size:23.5vw; }
  .ht--le        { left:52%;  top:49%; font-size:3.2vw;  }
  .ht--feu       { left:74%;  top:59%; font-size:24vw;   }
  .hero__baseline { left:20%; top:92%; font-size:1.7vw;  }
  .scroll-cue    { left:50%;  top:92%; font-size:0.85vw; }
}

/* ═══ INTERMÉDIAIRE 1024 ═══ — NE PLUS JAMAIS MODIFIER */
@media (min-width:769px) and (max-width:1024px) {
  .ht--dans      { left:18%;  top:21%; font-size:3.7vw; }
  .ht--la        { left:32%;  top:26%; font-size:3.7vw; }
  .ht--nuit      { left:29%;  top:48%; font-size:24vw;  }
  .ht--le        { left:52%;  top:49%; font-size:3.7vw; }
  .ht--feu       { left:73%;  top:61%; font-size:24vw;  }
  .hero__baseline { left:21%; top:92%; font-size:1.7vw; }
  .scroll-cue    { left:50%;  top:92%; font-size:0.9vw; }
}

/* ═══ TABLETTE 768 ═══ — NE PLUS JAMAIS MODIFIER */
@media (min-width:481px) and (max-width:768px) {
  .ht--dans      { left:35%;  top:13%; font-size:7.2vw;  }
  .ht--la        { left:63%;  top:14%; font-size:7.2vw;  }
  .ht--nuit      { left:51%;  top:32%; font-size:40.5vw; }
  .ht--le        { left:56%;  top:47%; font-size:7.2vw;  }
  .ht--feu       { left:51%;  top:65%; font-size:43vw;   }
  .hero__baseline { left:49%; top:82%; font-size:4.2vw;  }
  .scroll-cue    { left:50%;  top:92%; font-size:1.4vw;  }
}

/* ═══ MOBILE 390 ═══ — NE PLUS JAMAIS MODIFIER */
@media (max-width:480px) {
  .ht--dans      { left:32%;  top:13%; font-size:9.7vw; }
  .ht--la        { left:47%;  top:20%; font-size:9.7vw; }
  .ht--nuit      { left:51%;  top:35%; font-size:50vw;  }
  .ht--le        { left:61%;  top:49%; font-size:9.7vw; }
  .ht--feu       { left:51%;  top:65%; font-size:58vw;  }
  .hero__baseline { left:51%; top:80%; font-size:5.4vw; }
  .scroll-cue    { left:51%;  top:93%; font-size:2.6vw; }
}

@media (prefers-reduced-motion: reduce) {
  .hero.is-revealed .ht__in { animation: none; opacity: 1; }
}

/* --- Baseline — Awesome Serif Light Italic (position/taille : media queries) --- */
.hero__baseline {
  position: absolute;
  transform: translate(-50%, -50%);   /* ancrage centre, comme le titre */
  z-index: 3;
  white-space: nowrap;

  font-family: var(--f-serif);
  font-weight: 300;
  font-style: italic;
  line-height: 1.4;
  color: var(--creme);
  text-shadow: 0 1px 24px rgba(7, 13, 24, 0.55);
}

/* --- Bouton SON / MUET (discret, haut gauche sous le logo) --- */
.hero__sound {
  position: absolute;
  top: clamp(4.2rem, 11vh, 6rem);
  left: clamp(1.5rem, 4vw, 3rem);
  z-index: 3;

  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;

  font-family: var(--f-corps);
  font-weight: 300;
  font-size: 0.66rem;
  letter-spacing: var(--track-nav);
  text-transform: uppercase;
  color: var(--creme);
  mix-blend-mode: difference;
  transition: opacity 0.25s ease;
}
.hero__sound:hover { opacity: 0.72; }

/* Mini equaliseur — 3 barres */
.hero__sound-eq {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  width: 13px;
  height: 12px;
}
.hero__sound-eq i {
  width: 2.5px;
  height: 40%;
  background: currentColor;
  transform-origin: bottom;
}
/* Animation seulement quand le son est actif */
.hero__sound.is-on .hero__sound-eq i {
  animation: hero-eq 0.9s ease-in-out infinite;
}
.hero__sound.is-on .hero__sound-eq i:nth-child(2) { animation-delay: 0.18s; }
.hero__sound.is-on .hero__sound-eq i:nth-child(3) { animation-delay: 0.36s; }
.hero__sound:not(.is-on) .hero__sound-eq i { height: 30%; opacity: 0.7; }

@keyframes hero-eq {
  0%, 100% { height: 25%; }
  50%      { height: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__sound.is-on .hero__sound-eq i { animation: none; height: 70%; }
}

/* --- Indice de scroll : texte (sur la ligne baseline) + liseré dessous --- */
.scroll-cue {
  position: absolute;
  transform: translate(-50%, -50%);   /* ancrage centre = le label, comme la baseline */
  z-index: 3;

  display: inline-block;
  text-align: center;

  background: none;
  border: none;
  cursor: pointer;
  color: var(--creme);
  transition: opacity 0.3s ease;
}
.scroll-cue:hover { opacity: 0.75; }

/* Liseré positionné EN DESSOUS du texte (hors flux) : le label reste donc
   exactement sur la ligne de la baseline, et la ligne descend vers le bas. */
.scroll-cue__track {
  position: absolute;
  left: 50%;
  top: calc(100% + 0.55rem);
  transform: translateX(-50%);
  width: 1px;
  height: clamp(28px, 4vh, 42px);
  overflow: hidden;
}
.scroll-cue__line {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 100%;
  background: var(--ambre2);
  transform: scaleY(0);
  transform-origin: top;
  animation: scroll-line 2s ease-in-out infinite;
}
/* S'allonge depuis le haut, puis se résorbe par le bas — en boucle */
@keyframes scroll-line {
  0%        { transform: scaleY(0);   transform-origin: top; }
  50%       { transform: scaleY(1);   transform-origin: top; }
  50.01%    { transform: scaleY(1);   transform-origin: bottom; }
  100%      { transform: scaleY(0);   transform-origin: bottom; }
}

.scroll-cue__label {
  font-family: var(--f-corps);
  font-weight: 300;
  font-size: 1em;                      /* hérite de la taille posée sur .scroll-cue */
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--creme);
  opacity: 0.55;
  text-shadow: 0 1px 14px rgba(7, 13, 24, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  .scroll-cue__line { animation: none; transform: scaleY(1); }
}

/* ============================================================
   TICKER — separateur architectural autonome (entre sections)
   Bande pleine largeur, fond noir opaque, ~48px, sans mix-blend
   ============================================================ */
.ticker-bar {
  position: relative;
  z-index: 5;
  width: 100%;
  height: 48px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--noir);          /* fond opaque uni */
  border-top: 1px solid rgba(240, 232, 216, 0.1);
  border-bottom: 1px solid rgba(240, 232, 216, 0.1);
}

.ticker-inner {
  display: flex;
  width: max-content;
  white-space: nowrap;
  will-change: transform;
  animation: ticker 28s linear infinite;
}

.ticker-inner span {
  display: inline-block;
  font-family: var(--f-corps);
  font-weight: 400;
  font-size: clamp(0.7rem, 1vw, 0.85rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--creme);
}

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
