/* ============ La valise qui se remplit : vidéos pilotées par le défilement ============ */
.pack { position: relative; height: 340vh; }
.pack-stage { position: sticky; top: 0; height: 100svh; padding: clamp(70px, 10vh, 96px) 12px 12px; }
.pack-media { position: relative; height: 100%; border-radius: 28px; overflow: hidden; background: var(--forest-deep); isolation: isolate; box-shadow: 0 50px 100px -60px rgba(16, 36, 28, .8); }
.pack-clip { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity .7s var(--ease-out), transform 1.4s var(--ease-out); }
.pack-clip.is-on { opacity: 1; transform: none; }
.pack-shade { position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(11, 26, 20, .35) 0%, rgba(11, 26, 20, 0) 30%, rgba(11, 26, 20, 0) 50%, rgba(11, 26, 20, .78) 100%); }
.pack-copy { position: absolute; left: clamp(22px, 4vw, 56px); right: clamp(22px, 4vw, 56px); bottom: clamp(28px, 6vh, 60px); z-index: 2; color: var(--ivory); }
.pack-k { color: rgba(244, 239, 228, .82); }
.pack-k i { color: var(--amber-hi); }
.pack-lines { position: relative; height: 2.4em; margin-top: 10px; font-size: clamp(1.9rem, 4.2vw, 3.8rem); }
.pack-line { position: absolute; inset: auto 0 0; max-width: 18ch; font-size: 1em; line-height: 1.04; letter-spacing: -.04em; opacity: 0; transform: translateY(24px); filter: blur(8px); transition: opacity .6s var(--ease-out), transform .8s var(--ease-out), filter .6s var(--ease-out); }
.pack-line.is-on { opacity: 1; transform: none; filter: none; }
.pack-line em { background: var(--g-text-dark); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: .06em; }
.pack-meter { position: absolute; top: 18px; right: 18px; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 9px 14px; border-radius: 999px; background: rgba(251, 248, 241, .9); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); font-size: .78rem; font-weight: 500; color: var(--ink); box-shadow: 0 14px 30px -18px rgba(0, 0, 0, .5); }
.pack-meter > i { position: relative; display: block; width: 110px; height: 7px; border-radius: 7px; background: rgba(19, 33, 27, .12); overflow: hidden; }
.pack-meter b { position: absolute; inset: 0 auto 0 0; width: calc(var(--fill, 0) * 100%); border-radius: inherit; background: var(--g-amber); transition: background .4s; }
.pack.is-full .pack-meter b { background: linear-gradient(90deg, #e98b4a, #d4502f); }
.pm-ok { display: none; align-items: center; gap: 7px; color: var(--forest); }
.pm-ok img { width: 12px; }
.pack.is-sent .pm-label, .pack.is-sent .pack-meter > i { display: none; }
.pack.is-sent .pm-ok { display: inline-flex; animation: up .5s var(--ease-out); }
.pack-dots { position: absolute; left: 50%; top: 22px; z-index: 2; display: flex; gap: 6px; margin: 0; padding: 0; list-style: none; transform: translateX(-50%); }
.pack-dots li { width: 26px; height: 3px; border-radius: 3px; background: rgba(244, 239, 228, .35); transition: background-color .4s, width .4s var(--ease-out); }
.pack-dots li.is-on { width: 40px; background: var(--ivory); }
@media (max-width: 760px) {
  .pack { height: 300vh; }
  .pack-stage { padding: 66px 10px 10px; }
  .pack-media { border-radius: 22px; }
  .pack-meter { top: auto; bottom: auto; right: 12px; top: 44px; padding: 7px 11px; font-size: .68rem; }
  .pack-meter > i { width: 70px; }
  .pack-dots { top: 16px; }
  .pack-lines { height: 3.4em; font-size: clamp(1.7rem, 8vw, 2.4rem); }
}
@media (prefers-reduced-motion: reduce) { .pack { height: auto; } .pack-stage { position: relative; height: 80svh; } }
.pack-line { max-width: 24ch; }
.pack-lines { height: 2.3em; font-size: clamp(1.8rem, 3.6vw, 3.4rem); }
@media (max-width: 760px) { .pack-lines { height: 3.4em; font-size: clamp(1.6rem, 7.4vw, 2.2rem); } .pack-line { max-width: 16ch; } }

/* v8.7 : lecture directe, plus de défilement image par image */
.pack { height: auto; padding: clamp(40px, 7vh, 80px) 0; }
.pack-stage { position: relative; top: auto; height: min(88svh, 820px); padding: 0 12px; }
.pack-meter b { transition: width .35s linear; }
.pack-dots li { cursor: pointer; }
@media (max-width: 760px) { .pack { height: auto; } .pack-stage { height: 78svh; padding: 0 10px; } }

/* v9.2 : façon « stories » (barres, toucher, pause, Passer) ; le texte est posé sur la vidéo sur grand écran, dessous sur téléphone */
.pack-stage { position: relative; }
.pack-copy { position: absolute; left: calc(12px + clamp(22px, 4vw, 56px)); right: calc(12px + clamp(22px, 4vw, 56px)); bottom: clamp(28px, 6vh, 60px); z-index: 3; color: var(--ivory); pointer-events: none; }
.pack-bars { position: absolute; left: 18px; right: 18px; top: 16px; z-index: 4; display: flex; gap: 6px; }
.pack-bars i { position: relative; flex: 1; height: 3px; border-radius: 3px; background: rgba(244, 239, 228, .32); overflow: hidden; }
.pack-bars b { position: absolute; inset: 0; background: var(--ivory); transform-origin: left; transform: scaleX(0); will-change: transform; }
.pack-meter { top: 34px; }
.pack-tap { position: absolute; top: 0; bottom: 0; z-index: 2; padding: 0; border: 0; background: transparent; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pack-tap.prev { left: 0; width: 32%; cursor: w-resize; }
.pack-tap.next { right: 0; width: 68%; cursor: e-resize; }
.pack-tap:focus-visible { outline: 2px solid var(--amber-hi); outline-offset: -6px; }
.pack-skip { position: absolute; right: 16px; bottom: 16px; z-index: 5; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border: 0; border-radius: 999px; background: rgba(251, 248, 241, .94); color: var(--forest); font: 500 .86rem "Poppins", sans-serif; cursor: pointer; box-shadow: 0 12px 24px -14px rgba(0, 0, 0, .5); transition: transform .12s var(--ease-out); }
.pack-skip:active { transform: scale(.96); }
.pack.is-held .pack-clip.is-on { filter: brightness(.8); }
.pack-dots { display: none; }
@media (max-width: 760px) {
  .pack { padding: 48px 0 24px; }
  .pack-stage { height: auto; padding: 0 10px; }
  .pack-media { height: auto; aspect-ratio: 16 / 9; border-radius: 20px; }
  .pack-shade { background: linear-gradient(180deg, rgba(11, 26, 20, .45) 0%, rgba(11, 26, 20, 0) 35%); }
  .pack-meter { top: 30px; right: 10px; padding: 6px 10px; font-size: .64rem; gap: 7px; }
  .pack-meter > i { width: 54px; height: 5px; }
  .pack-bars { left: 12px; right: 12px; top: 12px; gap: 5px; }
  .pack-skip { right: 10px; bottom: 10px; height: 34px; padding: 0 12px; font-size: .78rem; }
  .pack-copy { position: static; margin: 18px 6px 0; color: var(--ink); pointer-events: auto; }
  .pack-k { color: var(--ink-soft); }
  .pack-lines { height: 2.5em; margin-top: 8px; font-size: clamp(1.55rem, 6.8vw, 2rem); }
  .pack-line { max-width: 20ch; }
  .pack-line em { background: var(--g-text-light); -webkit-background-clip: text; background-clip: text; color: transparent; }
}

/* v9.8 : sur téléphone aussi, le texte est posé sur la carte vidéo, façon story.
   La vidéo reste entière (16:9) en haut, se fond dans le vert profond, et le texte s'y pose. */
@media (max-width: 760px) {
  .pack-media { --txt: 104px; aspect-ratio: auto; height: auto; padding-bottom: var(--txt); }
  .pack-media::before { content: ""; display: block; aspect-ratio: 16 / 9; }
  .pack-clip { inset: 0 0 auto; height: auto; aspect-ratio: 16 / 9; }
  .pack-shade { background: linear-gradient(180deg, rgba(11, 26, 20, .45) 0, rgba(11, 26, 20, 0) 64px, rgba(11, 26, 20, 0) calc(100% - var(--txt) - 96px), var(--forest-deep) calc(100% - var(--txt) - 4px)); }
  .pack-copy { position: absolute; left: 28px; right: 72px; bottom: 18px; margin: 0; color: var(--ivory); pointer-events: none; }
  .pack-k { color: rgba(244, 239, 228, .8); font-size: .78rem; }
  .pack-lines { height: 2.2em; margin-top: 6px; font-size: clamp(1.45rem, 6.4vw, 1.8rem); }
  .pack-line { max-width: 18ch; }
  .pack-line em { background: var(--g-text-dark); -webkit-background-clip: text; background-clip: text; color: transparent; }
  .pack-skip { right: 12px; bottom: 14px; width: 44px; height: 44px; padding: 0; justify-content: center; border-radius: 50%; }
  .pack-skip span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .pack-skip i { font-size: 1.1rem; }
}
