/* ═══ Footer « rideau » LyraLex ═══
   Adapté du composant « Cinematic Footer » (React + GSAP) en CSS/JS natif, aux couleurs LyraLex :
   encre chaude, lueur dorée, grille fine, bandeau défilant, logotype LyraLex en filigrane,
   boutons « verre ». Le contenu de la page glisse et découvre le footer, fixé dessous.
   Version compacte : le footer prend la hauteur de son contenu (≈ 480 px), pas tout l'écran. */

.cine-curtain {
  --cf-bg: #17130e;
  --cf-ink: #f5f1e8;
  --cf-muted: #b3a892;
  --cf-gold: #c9a96e;
  --cf-gold-deep: #a18348;
  position: relative; z-index: 0;
  height: 480px;                           /* recalculé en JS d'après la hauteur réelle du footer */
  margin-top: -32px;                       /* passe sous les coins arrondis du contenu */
  clip-path: inset(0);                     /* le footer fixe n'est visible que dans ce cadre */
  background: var(--cf-bg);
}
/* Pause avant le footer : en bas de la page, le contenu reste en place pendant un court défilement
   (≈ 220 px, 120 px sur mobile) et se « décolle » légèrement ; ensuite le rideau découvre le footer.
   Le JS enveloppe <main> dans .cine-hold et calcule --hold-top (hauteur d'écran − hauteur du contenu). */
.cine-hold { position: relative; background: radial-gradient(90% 420px at 50% 100%, #3b2d17 0%, #17130e 70%); }
.cine-hold > main { position: sticky; top: var(--hold-top, 0px); transform-origin: 50% 100%; }
.cine-hold-space { height: 220px; }
@media (max-width: 600px) { .cine-hold-space { height: 120px; } }

/* Le contenu de la page passe au-dessus et s'arrondit en bas, comme un rideau qui se lève. */
body > main { position: relative; }
body > main, .cine-hold > main {
  z-index: 1;
  background: var(--cine-page-bg, #f5f1e8);   /* fond de la page (relevé sur <body> par le JS) */
  border-radius: 0 0 32px 32px;
  box-shadow: 0 24px 48px -28px #00000059;
  overflow: clip;
}

.cine-footer {
  position: fixed; left: 0; right: 0; bottom: 0;
  display: flex; flex-direction: column;
  padding-top: 32px;                       /* compense le recouvrement des coins arrondis */
  overflow: hidden;
  background: var(--cf-bg); color: var(--cf-ink);
  font-family: InterTight, 'Inter', system-ui, sans-serif; -webkit-font-smoothing: antialiased;
  line-height: 1.4;
}
.cine-footer *, .cine-footer *::before, .cine-footer *::after { box-sizing: border-box; margin: 0; padding: 0; }
:where(.cine-footer) a { color: inherit; text-decoration: none; }

/* Écran trop bas pour tout afficher : footer classique, sans effet rideau. */
.cine-curtain.is-static { height: auto !important; clip-path: none; }
.cine-curtain.is-static .cine-footer { position: relative; }

/* Lumière et grille */
.cine-aurora {
  position: absolute; left: 50%; top: 45%; width: 56vw; height: 300px; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle at 50% 50%, #c9a96e2e 0%, #8063381f 40%, transparent 70%);
  filter: blur(70px); pointer-events: none;
  animation: cine-breathe 8s ease-in-out infinite alternate;
}
/* Grille reprise de la section Sécurité : trame de 40 px à peine visible au repos,
   révélée autour du curseur quand la souris passe sur le footer. */
.cine-grid {
  position: absolute; inset: 0; overflow: hidden; pointer-events: none;
  /* La grille est découpée à la forme du logotype : elle ne passe jamais sur « LyraLex ». */
  --logo-w: min(42vw, 600px);
  -webkit-mask: url('lyralex-name-mask.png') 50% calc(100% + 34px) / var(--logo-w) auto no-repeat, linear-gradient(#000, #000);
  -webkit-mask-composite: xor;
          mask: url('lyralex-name-mask.png') 50% calc(100% + 34px) / var(--logo-w) auto no-repeat exclude, linear-gradient(#000, #000);
}
.cine-grid::before, .cine-grid::after {
  content: ''; position: absolute; inset: -40px;
  background-image:
    linear-gradient(#f5f1e859 1px, transparent 1px),
    linear-gradient(90deg, #f5f1e859 1px, transparent 1px);
  background-size: 40px 40px;
  animation: cine-grid-scroll 8s linear infinite;
}
.cine-grid::before { opacity: .035; }
.cine-grid::after {
  opacity: 0; transition: opacity .5s ease;
  -webkit-mask-image: radial-gradient(240px circle at var(--spot-x, 50%) var(--spot-y, 50%), #000, transparent 70%);
          mask-image: radial-gradient(240px circle at var(--spot-x, 50%) var(--spot-y, 50%), #000, transparent 70%);
}
.cine-grid.is-lit::after { opacity: .45; }
@keyframes cine-grid-scroll { to { background-position: 40px 40px; } }

/* Logotype LyraLex fondu en filigrane (le PNG sert de masque, rempli d'un dégradé or qui s'efface vers le bas) */
.cine-giant {
  position: absolute; left: 50%; bottom: -34px; z-index: 1;   /* au-dessus de la grille */
  width: min(42vw, 600px); aspect-ratio: 538 / 147;
  transform: translateX(-50%); transform-origin: 50% 100%;
  pointer-events: none; user-select: none;
  background: linear-gradient(180deg, #c9a96e30 0%, #c9a96e14 50%, #c9a96e00 100%);
  -webkit-mask: url('lyralex-name-mask.png') center / contain no-repeat;
          mask: url('lyralex-name-mask.png') center / contain no-repeat;
  will-change: transform, opacity;
}

/* Bandeau défilant, discret, en haut du footer */
.cine-marquee {
  position: relative; z-index: 2; width: 100%; overflow: hidden;
  padding: 11px 0;
  border-block: 1px solid #f5f1e812;
  background: #1b1712;                     /* opaque : la grille ne passe pas sous le bandeau */
}
.cine-marquee-track {
  display: flex; width: max-content;
  font-size: 11px; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: #9d927d;
  animation: cine-marquee 45s linear infinite;
}
.cine-marquee-group { display: flex; align-items: center; gap: 36px; padding: 0 18px; }
.cine-marquee-group i { font-style: normal; font-size: 10px; color: var(--cf-gold-deep); }

/* Contenu central */
.cine-main {
  position: relative; z-index: 3;
  display: flex; flex-direction: column; align-items: center;
  width: 100%; max-width: 1100px; margin: 0 auto; padding: 52px 24px 0;
}
.cine-title {
  width: 100%; margin-bottom: 26px; text-align: center;
  font: 600 clamp(28px, 3.4vw, 46px)/1.08 SevenSans, 'Inter', sans-serif; letter-spacing: -.035em;
  background: linear-gradient(180deg, #fbf7ee 0%, #ece3d0 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.cine-title .cine-nw { display: inline; white-space: nowrap; }
.cine-title .cine-gold {
  display: block;
  background: linear-gradient(180deg, #e6d1a2 0%, #c9a96e 55%, #a18348 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.cine-links { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; }
.cine-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; width: 100%; }
.cine-title, .cine-links { will-change: transform, opacity; }

/* Boutons « verre » */
.cine-pill {
  display: inline-flex; align-items: center; gap: 9px; border-radius: 999px;
  color: var(--cf-muted); font-size: 13px; font-weight: 500;
  background: linear-gradient(145deg, #f5f1e808 0%, #f5f1e803 100%);
  border: 1px solid #f5f1e812;
  box-shadow: 0 8px 20px -10px #00000080, inset 0 1px 1px #f5f1e814;
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  transition: background .4s cubic-bezier(.16,1,.3,1), border-color .4s, box-shadow .4s, color .3s;
}
.cine-pill:hover, .cine-pill:focus-visible {
  color: var(--cf-ink);
  background: linear-gradient(145deg, #f5f1e812 0%, #f5f1e805 100%);
  border-color: #c9a96e59;
}
.cine-pill:focus-visible { outline: 2px solid var(--cf-gold); outline-offset: 3px; }
.cine-pill svg { width: 16px; height: 16px; flex: none; color: var(--cf-gold); transition: transform .3s ease; }
.cine-pill-lg { padding: 11px 22px; font-size: 13.5px; font-weight: 600; color: var(--cf-ink); }
.cine-pill-sm { padding: 6px 14px; font-size: 12.5px; }
.cine-pill-gold {
  color: #1a1611; border-color: #e2cc9c80;
  background: linear-gradient(145deg, #d4b77c 0%, #b8975a 100%);
  box-shadow: 0 10px 24px -12px #b8975a99, inset 0 1px 1px #fff3d6b3;
}
.cine-pill-gold svg { color: #1a1611; }
.cine-pill-gold:hover, .cine-pill-gold:focus-visible {
  color: #1a1611; border-color: #f0dfb5;
  background: linear-gradient(145deg, #dcc18a 0%, #c4a364 100%);
}
.cine-pill-lg:hover svg { transform: translateX(3px); }
.cine-textlinks { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; font-size: 12.5px; color: var(--cf-muted); }
.cine-textlinks a { transition: color .25s; }
.cine-textlinks a:hover, .cine-textlinks a:focus-visible { color: var(--cf-gold); }

/* Barre du bas */
.cine-bottom {
  position: relative; z-index: 4; width: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  margin-top: 40px; padding: 16px 48px 22px;
}
/* Une seule ligne, comme sur le site publié : copyright à gauche, mentions à droite. */
.cine-legal { flex: 1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; font-size: 12px; color: #8f8574; }
.cine-copy { color: var(--cf-muted); }
.cine-legal a { color: var(--cf-muted); transition: color .25s; }
.cine-legal a:hover, .cine-legal a:focus-visible { color: var(--cf-gold); }
.cine-top { width: 36px; height: 36px; justify-content: center; padding: 0; cursor: pointer; font: inherit; color: var(--cf-muted); }
.cine-top svg { width: 16px; height: 16px; color: currentColor; transition: transform .3s ease; }
.cine-top:hover svg { transform: translateY(-3px); }
/* Réseaux sociaux (Instagram, LinkedIn), groupés avec le bouton « haut de page » */
.cine-end { display: flex; align-items: center; gap: 10px; }
.cine-social { width: 36px; height: 36px; justify-content: center; padding: 0; }
.cine-social svg { width: 16px; height: 16px; color: currentColor; transition: color .25s; }
.cine-social:hover, .cine-social:focus-visible { color: var(--cf-gold); }

/* Animations */
@keyframes cine-breathe { from { transform: translate(-50%, -50%) scale(1); opacity: .6; } to { transform: translate(-50%, -50%) scale(1.1); opacity: 1; } }
@keyframes cine-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.cine-curtain.is-idle .cine-aurora, .cine-curtain.is-idle .cine-marquee-track,
.cine-curtain.is-idle .cine-grid::before, .cine-curtain.is-idle .cine-grid::after { animation-play-state: paused; }

/* Responsive */
@media (max-width: 900px) {
  .cine-bottom { flex-direction: column; gap: 12px; padding: 16px 24px 22px; text-align: center; }
  .cine-legal { order: 2; flex-direction: column; justify-content: center; gap: 4px; }
  .cine-end { order: 1; }
  .cine-giant { width: 72vw; }
  .cine-grid { --logo-w: 72vw; }
}
@media (max-width: 600px) {
  .cine-main { padding-top: 40px; }
  .cine-title { margin-bottom: 22px; }
  .cine-row { gap: 8px; }
  .cine-bottom { margin-top: 32px; }
  body > main, .cine-hold > main { border-radius: 0 0 24px 24px; }
}
@media (prefers-reduced-motion: reduce) {
  .cine-aurora, .cine-marquee-track, .cine-grid::before, .cine-grid::after { animation: none; }
  .cine-giant, .cine-title, .cine-links { transform: none !important; opacity: 1 !important; }
  .cine-giant { transform: translateX(-50%) !important; }
}
.cine-footer .sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
