/* Séries photo : défilement horizontal (ordinateur, iPad, téléphone couché),
   vertical sur téléphone debout. Sans « gap » ni « inset » (anciens iPad). */
html.page-serie, body.serie { height: 100%; overflow: hidden; }
body.serie { display: flex; flex-direction: column; }
body.serie > header { flex: 0 0 auto; padding-top: 24px; padding-bottom: 18px; }
.serie-titre { flex: 0 0 auto; text-align: left; padding: 0 var(--marge) 14px; }
.serie-titre h1 { font-size: 30px; font-weight: 300; letter-spacing: 0.06em; text-transform: uppercase; }
.serie-titre p { color: var(--gris); font-size: 14px; margin-top: 4px; }

/* Hors téléphone debout : sous-titre à côté du titre, sur la même ligne de base */
@media (min-width: 761px), (orientation: landscape) {
  .serie-titre { display: flex; flex-wrap: wrap; align-items: baseline; }
  .serie-titre h1 { margin-right: 18px; }
  .serie-titre p { margin: 0; }
}

/* Sous-titre sur deux lignes : les deux lignes tiennent dans la hauteur du titre,
   la seconde posée sur la même ligne de base */
@media (min-width: 900px) and (min-height: 501px) {
  .serie-titre p.deux-lignes { font-size: 12px; line-height: 13px; position: relative; top: -13px; }
}

main.bande {
  flex: 1 1 auto; min-height: 0;
  display: flex; align-items: center;
  overflow-x: auto; overflow-y: hidden;
  padding: 0 var(--marge);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.bande::-webkit-scrollbar { display: none; }
.bande > * { flex: 0 0 auto; margin-right: 16px; }
.bande > :last-child { margin-right: 0; padding-right: var(--marge); }
.bande img { display: block; }
.vue { display: block; }
a.vue, .vue a { cursor: zoom-in; }
.diptyque { display: flex; align-items: center; }
.diptyque > * + * { margin-left: 6px; }

.bande .texte-serie, .bande .poeme, .bande .note-fin {
  width: 460px; max-width: none; max-height: 100%; overflow-y: auto;
  margin: 0 16px 0 0; padding: 0 24px; border: 0;
}
.bande .texte-serie { font-size: 16px; line-height: 1.7; }
.bande .poeme { font-size: 17px; }
.bande .note-fin { width: 480px; font-size: 14px; line-height: 1.6; }
.bande .dn-livre { margin: 0 16px 0 0; max-width: none; }
.bande .dn-livre video { width: 100%; height: auto; background: #000; }
.bande .dn-livre .legende-video { font-size: 13px; margin-top: 8px; }

.serie-suite {
  display: flex; flex-direction: column; align-items: flex-start;
  padding-left: 40px; color: var(--gris); font-size: 15px; white-space: nowrap;
}
.serie-suite a + a { margin-top: 18px; }
.serie-suite a:hover { color: var(--texte); }

.pied { flex: 0 0 auto; display: flex; align-items: center; padding: 6px var(--marge) 0; }
.pied button { background: none; border: 0; font: inherit; font-size: 24px; color: var(--texte); cursor: pointer; padding: 4px 12px; }
.pied .debut { display: flex; align-items: center; padding: 4px 8px 4px 0; }
.piste { flex: 1; height: 1px; background: var(--filet); margin: 0 18px; position: relative; }
.piste span { position: absolute; top: -1px; left: 0; height: 3px; background: var(--texte); }
.num { color: var(--gris); font-size: 14px; min-width: 60px; text-align: right; }
.lancer { flex: 0 0 auto; text-align: center; padding-bottom: 12px; }
.lancer .auto { background: none; border: 0; cursor: pointer; font: inherit; font-size: 14px; color: var(--gris); padding: 4px 12px; }
.lancer .auto:hover, .lancer .auto[aria-pressed="true"] { color: var(--texte); }

/* Téléphone couché : tout est resserré pour laisser la place aux images */
@media (max-height: 500px) and (orientation: landscape) {
  body.serie > header { flex-direction: row; flex-wrap: wrap; padding-top: 8px; padding-bottom: 4px; }
  body.serie header > nav, .sans-gap body.serie header > nav { margin-top: 0; }
  body.serie nav a { margin: 0 0 0 14px; font-size: 14px; }
  body.serie nav a.reseau, body.serie nav a.reseau.instagram { margin: 0 0 0 14px; }
  body.serie nav > * { margin-bottom: 0; }
  .serie-titre { padding-bottom: 4px; }
  .serie-titre h1 { font-size: 18px; display: inline; }
  .serie-titre p { font-size: 12px; }
  .pied { padding-top: 0; }
  .pied button { font-size: 20px; padding: 0 10px; }
  .pied .debut { padding: 0 6px 0 0; }
  .lancer { padding-bottom: 4px; }
  .lancer .auto { padding: 0 12px; }
  .bande .texte-serie, .bande .note-fin { font-size: 13px; line-height: 1.5; }
  .bande .poeme { font-size: 14px; line-height: 1.5; }
  .bande .dn-livre .legende-video { display: none; }
}

/* Téléphone couché (écran tactile) : les images prennent toute la place.
   Menu, flèches, barre et « Auto » disparaissent ; on fait défiler au doigt. */
@media (max-height: 500px) and (orientation: landscape) and (pointer: coarse) {
  body.serie > header, .pied, .lancer { display: none; }
  .serie-titre { padding-top: 8px; padding-bottom: 6px; }
  main.bande { padding-bottom: 8px; }
}

/* Téléphone debout : la page défile de haut en bas */
@media (max-width: 760px) and (orientation: portrait) {
  html.page-serie, body.serie { height: auto; overflow: visible; overflow-x: hidden; }
  body.serie { display: block; }
  .serie-titre h1 { font-size: 24px; }
  main.bande { display: block; overflow: visible; padding: 0 var(--marge) 48px; }
  .bande > *, .bande > :last-child { margin: 0 0 8px; padding-right: 0; }
  .bande img { width: 100%; height: auto; }
  .bande .vue.fac { max-width: 300px; margin: 28px auto; }
  .diptyque > .vue { flex: var(--r) 1 0; min-width: 0; }
  .bande .texte-serie, .bande .poeme, .bande .note-fin {
    width: auto; max-height: none; overflow: visible; margin: 28px 0 36px; padding: 0;
  }
  .bande .poeme { width: -webkit-fit-content; width: fit-content; margin-left: auto; margin-right: auto; }
  .bande .dn-livre { margin: 24px 0 32px; width: auto !important; }
  .serie-suite { flex-direction: row; justify-content: space-between; padding: 24px 0 0; margin-top: 48px; border-top: 1px solid var(--filet); white-space: normal; }
  .serie-suite a + a { margin: 0 0 0 16px; text-align: right; }
  .pied, .lancer { display: none; }
}
