/**
 * STCD Film — Correctifs UI pour vraies pages Divi générées
 * Version: 1.0.6
 *
 * Cette feuille n'est chargée que sur les pages créées par STCD Film.
 * Elle ne modifie pas le reste de pictospot.com.
 */

body.stcd-film-divi-page{
  margin:0!important;
  padding:0!important;
  overflow-x:hidden;
  background:#11110f;
}

body.stcd-film-divi-page #page-container,
body.stcd-film-divi-page #et-main-area,
body.stcd-film-divi-page #main-content{
  margin:0!important;
  padding:0!important;
  background:transparent!important;
}

/* ------------------------------------------------------------
 * 1. Typographie : Divi applique parfois la couleur globale des
 *    headings par-dessus text_text_color du module.
 *    Les titres doivent donc hériter de la couleur de leur bloc.
 * ------------------------------------------------------------ */
body.stcd-film-divi-page .gb-webdoc .gb-title,
body.stcd-film-divi-page .gb-webdoc .gb-title em,
body.stcd-film-divi-page .gb-webdoc .gb-h2,
body.stcd-film-divi-page .gb-webdoc h1,
body.stcd-film-divi-page .gb-webdoc h2,
body.stcd-film-divi-page .gb-webdoc h3,
body.stcd-film-divi-page .gb-webdoc h4,
body.stcd-film-divi-page .gb-webdoc h5,
body.stcd-film-divi-page .gb-webdoc h6,
body.stcd-film-divi-page .rgb-app .title,
body.stcd-film-divi-page .rgb-app .h2,
body.stcd-film-divi-page .rgb-app h1,
body.stcd-film-divi-page .rgb-app h2,
body.stcd-film-divi-page .rgb-app h3,
body.stcd-film-divi-page .rgb-app h4{
  color:inherit!important;
}

/* Le corps de texte doit également suivre le bloc lorsqu'une
   couleur claire a été définie sur un module sombre. */
body.stcd-film-divi-page .gb-webdoc .gb-body,
body.stcd-film-divi-page .gb-webdoc .gb-lead,
body.stcd-film-divi-page .gb-webdoc .gb-quote,
body.stcd-film-divi-page .rgb-app .body,
body.stcd-film-divi-page .rgb-app .lead,
body.stcd-film-divi-page .rgb-app .quote{
  color:inherit!important;
}

/* ------------------------------------------------------------
 * 2. Sections sombres : contraste systématique.
 * ------------------------------------------------------------ */
body.stcd-film-divi-page .gb-webdoc.gb-screen-dark,
body.stcd-film-divi-page .gb-webdoc.dark,
body.stcd-film-divi-page .gb-webdoc.legacy,
body.stcd-film-divi-page .rgb-app.screen-dark{
  color:#fff5e3!important;
}

body.stcd-film-divi-page .gb-webdoc.gb-screen-dark .gb-kicker,
body.stcd-film-divi-page .gb-webdoc.dark .gb-kicker,
body.stcd-film-divi-page .rgb-app.screen-dark .kicker,
body.stcd-film-divi-page .rgb-app.screen-dark .year{
  color:#e74b40!important;
}

body.stcd-film-divi-page .gb-card-dark,
body.stcd-film-divi-page .rgb-app .card-dark{
  background:#151513!important;
  color:#fff5e3!important;
  border-color:rgba(255,245,227,.16)!important;
}

body.stcd-film-divi-page .gb-card-dark h3,
body.stcd-film-divi-page .gb-card-dark p,
body.stcd-film-divi-page .rgb-app .card-dark h3,
body.stcd-film-divi-page .rgb-app .card-dark p{
  color:inherit!important;
}

/* ------------------------------------------------------------
 * 3. Section bordeaux : texte ivoire, repères plus clairs.
 *    Le fond lui-même reste celui défini dans le layout Divi.
 * ------------------------------------------------------------ */
body.stcd-film-divi-page .gb-webdoc[style*="background-color: #9d201b"],
body.stcd-film-divi-page .gb-webdoc[style*="background-color:#9d201b"]{
  color:#fff5e3!important;
}

/* Divi ne conserve pas toujours le background en inline : la section
   Mireille Darc du modèle a un module texte clair, donc on cible aussi
   le bloc contenant le dessin .gb-dress grâce à :has(). */
body.stcd-film-divi-page .et_pb_section:has(.gb-dress){
  color:#fff5e3!important;
}
body.stcd-film-divi-page .et_pb_section:has(.gb-dress) .gb-h2,
body.stcd-film-divi-page .et_pb_section:has(.gb-dress) .gb-lead,
body.stcd-film-divi-page .et_pb_section:has(.gb-dress) p{
  color:#fff5e3!important;
}
body.stcd-film-divi-page .et_pb_section:has(.gb-dress) .gb-kicker{
  color:#f3c7a2!important;
}

/* Le dessin abstrait de robe n'est plus utile depuis que la photo est
   intégrée et produit un grand trait diagonal sur smartphone. */
body.stcd-film-divi-page .gb-dress{
  display:none!important;
}

/* ------------------------------------------------------------
 * 4. Navigation et dock mobile.
 * ------------------------------------------------------------ */
body.stcd-film-divi-page .gb-mobile-dock,
body.stcd-film-divi-page .rgb-dock{
  bottom:max(14px, env(safe-area-inset-bottom))!important;
  z-index:99999!important;
}

body.stcd-film-divi-page .gb-webdoc:last-of-type,
body.stcd-film-divi-page .rgb-app:last-of-type{
  padding-bottom:120px!important;
}

/* ------------------------------------------------------------
 * 5. Images / cartes.
 * ------------------------------------------------------------ */
body.stcd-film-divi-page .gb-webimg,
body.stcd-film-divi-page .rgb-app .webimg{
  width:100%!important;
  max-width:100%!important;
  height:auto;
  display:block;
}

body.stcd-film-divi-page .gb-img-caption,
body.stcd-film-divi-page .rgb-app .caption{
  line-height:1.45!important;
}

/* ------------------------------------------------------------
 * 6. Mobile : rythme plus compact et lisibilité.
 * ------------------------------------------------------------ */
@media(max-width:767px){
  body.stcd-film-divi-page .gb-webdoc .et_pb_row,
  body.stcd-film-divi-page .rgb-app .et_pb_row{
    width:94%!important;
    max-width:94%!important;
  }

  body.stcd-film-divi-page .gb-webdoc .gb-title,
  body.stcd-film-divi-page .rgb-app .title{
    font-size:clamp(45px,12vw,58px)!important;
    line-height:.95!important;
  }

  body.stcd-film-divi-page .gb-webdoc .gb-h2,
  body.stcd-film-divi-page .rgb-app .h2{
    font-size:clamp(34px,9.5vw,46px)!important;
    line-height:1!important;
  }

  body.stcd-film-divi-page .gb-webdoc .gb-lead,
  body.stcd-film-divi-page .rgb-app .lead{
    font-size:19px!important;
    line-height:1.5!important;
  }

  body.stcd-film-divi-page .gb-webdoc .gb-body,
  body.stcd-film-divi-page .rgb-app .body{
    font-size:16px!important;
    line-height:1.65!important;
  }

  body.stcd-film-divi-page .gb-card-dark,
  body.stcd-film-divi-page .rgb-app .card-dark,
  body.stcd-film-divi-page .gb-card,
  body.stcd-film-divi-page .rgb-app .card{
    min-height:0!important;
  }
}
