/* Black Olive, page Galerie (refonte 2) : titre, 3 vidéos, mosaïque de photos filtrable, visionneuse.
   S'ajoute à css/style.css (jetons, en-tête, boutons, pied de page). */
:root { --g-top: calc(var(--frame-h) + var(--header-h)); }
.main-nav a.is-here:not(.btn) { color: var(--cream); }
.main-nav a.is-here:not(.btn)::after { transform: scaleX(1); transform-origin: left; }
.g-wrap { width: min(100% - 2 * var(--gutter), 1320px); margin-inline: auto; }

/* ---------- Titre ---------- */
.g-hero {
  padding: calc(var(--g-top) + clamp(36px, 6vw, 84px)) 0 clamp(36px, 5vw, 64px);
  background: radial-gradient(ellipse 70% 60% at 85% 0%, rgba(201, 160, 99, .10) 0%, transparent 70%), linear-gradient(180deg, #152a25 0%, #0e1512 100%);
}
.g-hero .kicker { margin-bottom: 14px; }
.g-title { font-family: var(--font-display); font-weight: 300; font-size: clamp(2.6rem, 8vw, 6rem); line-height: 1.02; text-wrap: balance; color: var(--cream); }
.g-title em { font-style: italic; font-weight: 400; color: var(--gold-soft); }
.g-lead { margin-top: 18px; max-width: 52ch; font-size: clamp(.95rem, 1.2vw, 1.08rem); line-height: 1.65; font-weight: 300; color: var(--cream-muted); }

/* ---------- Entêtes de section ---------- */
.g-videos, .g-photos { padding: clamp(40px, 6vw, 88px) 0; background: var(--ink); }
.g-photos { background: linear-gradient(180deg, #0e1512 0%, #152a25 100%); }
.g-sech { display: flex; align-items: baseline; gap: 18px; margin-bottom: clamp(22px, 3vw, 40px); padding-bottom: 16px; border-bottom: 1px solid var(--hairline); }
.g-sech__n { font-size: .75rem; letter-spacing: .24em; color: var(--gold-soft); }
.g-sech h2 { font-family: var(--font-display); font-weight: 300; font-size: clamp(1.8rem, 4vw, 3rem); line-height: 1.05; color: var(--cream); }
.g-sech h2 em { font-style: italic; font-weight: 400; color: var(--gold-soft); }

/* ---------- Vidéos : une grande à gauche, deux à droite ---------- */
.gv-grid { display: grid; gap: clamp(14px, 2vw, 24px); grid-template-columns: 1fr; }
.gv { margin: 0; }
.gv-frame {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 4px; background: #0b110f;
  box-shadow: 0 0 0 1px rgba(201, 160, 99, .35), 0 30px 50px -30px rgba(0, 0, 0, .8);
}
.gv-frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.gv-empty {
  position: absolute; inset: 10px; display: grid; place-content: center; justify-items: center; gap: 8px; text-align: center;
  border: 1px dashed rgba(201, 160, 99, .45); border-radius: 2px; color: var(--cream-muted);
  background: radial-gradient(ellipse 70% 70% at 50% 40%, rgba(201, 160, 99, .08) 0%, transparent 70%);
}
.gv-empty b { font-family: var(--font-display); font-weight: 400; font-style: italic; font-size: clamp(1.2rem, 2vw, 1.7rem); color: var(--gold-soft); }
.gv-empty small { font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; color: var(--cream-muted); opacity: .75; }
.gv-play { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--gold); color: var(--gold-soft); }
.gv-play svg { width: 22px; height: 22px; margin-left: 3px; }
.gv figcaption { margin-top: 10px; font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; color: var(--cream-muted); }
@media (min-width: 900px) {
  .gv-grid { grid-template-columns: 1.7fr 1fr; grid-template-rows: auto auto; }
  .gv--main { grid-row: 1 / span 2; display: flex; flex-direction: column; }
  .gv--main .gv-frame { aspect-ratio: auto; flex: 1; min-height: 380px; }
}

/* ---------- Raccourcis de catégories ---------- */
.gf { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: clamp(28px, 4vw, 56px); }
.gf-chip {
  font-size: .74rem; letter-spacing: .18em; text-transform: uppercase; padding: 10px 18px; border-radius: 999px;
  color: var(--cream-muted); border: 1px solid rgba(201, 160, 99, .35); text-decoration: none;
  transition: background-color .3s var(--ease-out), color .3s var(--ease-out), border-color .3s var(--ease-out);
}
.gf-chip small { margin-left: 4px; font-size: .7rem; opacity: .7; }
.gf-chip:hover, .gf-chip:focus-visible { background: var(--gold); border-color: var(--gold); color: var(--ink); }
@media (max-width: 640px) {
  .gf { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scrollbar-width: none; }
  .gf::-webkit-scrollbar { display: none; }
  .gf-chip { flex-shrink: 0; }
}

/* ---------- Catégories : grille de carrés, la première photo en grand ---------- */
.g-cat { scroll-margin-top: calc(var(--g-top) + 12px); }
.g-cat + .g-cat { margin-top: clamp(44px, 7vw, 100px); }
.g-cat .g-sech { flex-wrap: wrap; row-gap: 6px; }
.g-sech p { flex-basis: 100%; margin: 0; padding-left: 44px; max-width: 62ch; font-size: .95rem; line-height: 1.55; font-weight: 300; color: var(--cream-muted); }
.gp-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(8px, 1.2vw, 16px); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gp { margin: 0; }
.gp-open { position: relative; display: block; width: 100%; aspect-ratio: 1; padding: 0; border: 0; border-radius: 2px; overflow: hidden; cursor: pointer; background: #0b110f; box-shadow: 0 0 0 1px rgba(201, 160, 99, .3); }
.gp-open img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease-out); }
.gp-cap {
  position: absolute; inset: auto 0 0 0; padding: 44px 14px 12px; text-align: left; font-family: var(--font-display); font-style: italic; font-size: 1.05rem; line-height: 1.2; color: var(--gold-soft);
  background: linear-gradient(0deg, rgba(14, 21, 18, .92) 0%, transparent 100%); opacity: 0; transform: translateY(8px); transition: opacity .4s var(--ease-out), transform .4s var(--ease-out);
}
@media (hover: hover) { .gp-open:hover img { transform: scale(1.05); } .gp-open:hover .gp-cap, .gp-open:focus-visible .gp-cap { opacity: 1; transform: none; } }
@media (hover: none) { .gp-cap { opacity: 1; transform: none; font-size: .9rem; padding: 30px 10px 8px; } }
.gp-open:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
/* téléphone : 2 colonnes ; la première photo prend toute la largeur quand le nombre de photos est impair */
@media (max-width: 759px) {
  .gp-grid.is-odd .gp:first-child { grid-column: 1 / -1; }
  .gp-grid.is-odd .gp:first-child .gp-open { aspect-ratio: 16 / 10; }
}
@media (min-width: 760px) {
  .gp-grid--c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .gp-grid--c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .gp-grid--c3 .gp:first-child { grid-column: span 2; grid-row: span 2; }
  .gp-grid--c3 .gp:first-child .gp-open { height: 100%; aspect-ratio: auto; }
  .gp-grid--lead-wide .gp:first-child { grid-column: span 2; }
  .gp-grid--lead-wide .gp:first-child .gp-open { aspect-ratio: auto; height: 100%; }
}

/* ---------- Visionneuse ---------- */
.lb { border: 0; padding: 0; margin: 0; width: 100%; max-width: none; height: 100%; max-height: none; background: rgba(14, 21, 18, .98); color: var(--cream); }
.lb::backdrop { background: rgba(14, 21, 18, .92); }
.lb[open] { display: grid; grid-template-rows: 1fr auto; animation: lbIn .45s var(--ease-out) both; }
@keyframes lbIn { from { opacity: 0; } to { opacity: 1; } }
.lb__stage { position: relative; display: grid; place-items: center; padding: clamp(56px, 6vw, 80px) clamp(16px, 6vw, 96px) 16px; min-height: 0; touch-action: pan-y; }
.lb__img { max-width: 100%; max-height: 100%; object-fit: contain; box-shadow: 0 32px 80px -16px rgba(0, 0, 0, .6); }
.lb__bar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 16px clamp(16px, 4vw, 48px) 24px; border-top: 1px solid var(--hairline); }
.lb__cap { font-family: var(--font-display); font-style: italic; font-size: clamp(1.2rem, 2vw, 1.6rem); max-width: 40ch; color: var(--gold-soft); }
.lb__count { font-size: .75rem; letter-spacing: .22em; color: var(--gold); white-space: nowrap; }
.lb__btn { position: absolute; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: rgba(248, 246, 240, .06); border: 1px solid rgba(233, 207, 159, .45); color: var(--cream); cursor: pointer; transition: background-color .3s var(--ease-out), color .3s var(--ease-out), transform .2s var(--ease-out); }
.lb__btn:active { transform: scale(.94); }
.lb__btn svg { width: 18px; height: 18px; }
.lb__close { top: 16px; right: 16px; }
.lb__prev { left: clamp(8px, 1.5vw, 24px); top: 50%; translate: 0 -50%; }
.lb__next { right: clamp(8px, 1.5vw, 24px); top: 50%; translate: 0 -50%; }
@media (hover: hover) { .lb__btn:hover { background: var(--gold); color: var(--ink); border-color: var(--gold); } }
@media (max-width: 640px) {
  .lb__stage { padding-inline: 8px; }
  .lb__prev, .lb__next { top: auto; bottom: 8px; translate: none; }
  .lb__bar { flex-direction: column; align-items: flex-start; gap: 8px; padding-bottom: 72px; }
}
@media (prefers-reduced-motion: reduce) { .gp-open img, .gp-cap { transition: none; } .lb[open] { animation: none; } }
