/* ---------- Éventail de cartes (inspiré de landonorris.com) : le défilement ouvre les cartes ---------- */
.eventail { --ouv: 0; --pas: clamp(64px, 11.5vw, 178px); --chute: clamp(5px, 1.05vw, 16px); --angle: 6.4deg;
  position: relative; width: 100%; height: clamp(430px, 64vw, 780px); margin-top: clamp(24px, 4vw, 56px); }
.eventail-liste { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; }
.carte { position: absolute; left: 50%; bottom: 7%; width: clamp(150px, 23vw, 310px); aspect-ratio: 3 / 4.15; z-index: calc(20 - var(--a) * 4);
  transform-origin: 50% 100%;
  transform: translate3d(calc(-50% + var(--i) * var(--ouv) * var(--pas)), calc(var(--a) * var(--a) * var(--ouv) * var(--chute)), 0) rotate(calc(var(--i) * var(--ouv) * var(--angle))) scale(calc(1 + (1 - var(--ouv)) * -0.04));
  transition: transform .75s var(--ease, cubic-bezier(.2, .8, .2, 1)), filter .5s; }
.carte-bouton { position: relative; display: block; width: 100%; height: 100%; padding: 0; border: 0; border-radius: clamp(22px, 3vw, 40px); overflow: hidden; cursor: pointer; background: #14101c; color: #fff;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35), 0 0 0 1px rgba(255, 255, 255, .08); -webkit-tap-highlight-color: transparent; }
.carte-bouton img, .carte-bouton video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; border: 0; border-radius: 0; background: none; scale: 1; translate: none; }
.carte-bouton video { opacity: 0; transition: opacity .5s; }
.carte.joue video { opacity: 1; }
.carte-bouton::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 55%, rgba(8, 6, 14, .72)); pointer-events: none; }
.carte-nom, .carte-etat { position: absolute; left: 16px; right: 16px; z-index: 2; text-align: left; pointer-events: none; }
.carte-nom { bottom: 38px; font: 700 clamp(15px, 1.5vw, 21px)/1.1 var(--serif); letter-spacing: -.02em; }
.carte-etat { bottom: 16px; font: 10px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: rgba(255, 255, 255, .72); }
.carte:hover, .carte:focus-within, .carte.joue { z-index: 40; }
@media (hover: hover) { .carte:hover { transform: translate3d(calc(-50% + var(--i) * var(--ouv) * var(--pas)), -34px, 0) rotate(0deg) scale(1.07); } }
.carte.joue { transform: translate3d(calc(-50% + var(--i) * var(--ouv) * var(--pas) * .6), -34px, 0) rotate(0deg) scale(1.07); }
.carte-bouton:focus-visible { outline: 2px solid var(--peche); outline-offset: 4px; }
/* à plat : les cartes de côté s'éloignent un peu quand une carte est active */
.eventail:has(.carte.joue) .carte:not(.joue) { filter: saturate(.7) brightness(.82); }
html[data-theme="light"] .carte-bouton { box-shadow: 0 24px 60px rgba(78, 60, 144, .22), 0 0 0 1px rgba(78, 60, 144, .1); }
/* mobile : rail horizontal, cartes légèrement inclinées en alternance */
@media (max-width: 760px) {
  .eventail { height: auto; }
  .eventail-liste { position: static; display: flex; gap: 14px; overflow-x: auto; padding: 24px var(--marge) 30px; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .eventail-liste::-webkit-scrollbar { display: none; }
  .carte { position: relative; left: auto; bottom: auto; flex: 0 0 66vw; width: 66vw; scroll-snap-align: center; transform: rotate(calc(var(--i) / var(--a, 1) * 1.6deg)) !important; z-index: 1; }
  .carte.joue { transform: scale(1.03) !important; }
}
/* Visuels fixes (publications, photos) : cartes 4/5 pour garder le texte des publications */
.eventail.carre .carte { aspect-ratio: 4 / 5; }
.eventail.carre { --pas: clamp(110px, 17vw, 262px); height: clamp(400px, 58vw, 700px); }
@media (max-width: 760px) { .eventail.carre { height: auto; } }
@media (prefers-reduced-motion: reduce) { .carte { transition: none; } }

/* Cartes cliquables : pastille « lecture » (vidéo) ou « agrandir » (image) en haut à droite */
.carte-bouton::before { content: "⤢"; position: absolute; top: 12px; right: 12px; z-index: 3; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; font-size: 15px; line-height: 1; color: #fff;
  background: rgba(12, 10, 22, .55); border: 1px solid rgba(255, 255, 255, .24); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); pointer-events: none; transition: opacity .3s, transform .4s cubic-bezier(.2, .8, .2, 1); }
.carte:has(video[data-src]) .carte-bouton::before { content: "▶"; font-size: 12px; padding-left: 2px; }
.carte.joue .carte-bouton::before { opacity: 0; transform: scale(.8); }
