/**
 * CineAI — peau "Gumroad ciné" (v2.6.1+)
 * Sombre par défaut, clair via html.bw-light (toggle mémorisé).
 * Couche posée PAR-DESSUS les styles existants : on surcharge, on ne réécrit pas
 * le markup. Les !important ciblent les couleurs en dur des <style> inline des
 * templates historiques.
 */

body.cineai-gumroad{
  --g-paper:#121014; --g-card:#1d1a21; --g-card2:#241f2b;
  --g-ink:#f2eee8; --g-dim:#a9a1b1;
  --g-pink:#ff90e8; --g-yellow:#ffc900; --g-green:#23a094; --g-blue:#90a8ed;
  --g-line:#f2eee8; --g-shadow:#000;
  --g-bd:2px solid var(--g-line);
  --g-sh:4px 4px 0 var(--g-shadow);
  --g-sh-big:7px 7px 0 var(--g-shadow);
  --g-font:'Archivo',system-ui,sans-serif;
  --g-display:'Archivo Black','Archivo',system-ui,sans-serif;

  background:var(--g-paper) !important;
  color:var(--g-ink);
  font-family:var(--g-font);
}
html.bw-light body.cineai-gumroad{
  --g-paper:#f4f0e8; --g-card:#ffffff; --g-card2:#efe9df;
  --g-ink:#111111; --g-dim:#575060;
  --g-line:#111111; --g-shadow:#111111;
}

/* ── Typo & base ── */
body.cineai-gumroad h1,
body.cineai-gumroad h2,
body.cineai-gumroad h3,
body.cineai-gumroad .cineai-section-title,
body.cineai-gumroad .cineai-archive-title{
  font-family:var(--g-display) !important;
  color:var(--g-ink) !important;
  letter-spacing:-.01em;
}
body.cineai-gumroad p,
body.cineai-gumroad li{ color:var(--g-ink); }
body.cineai-gumroad .cineai-content-container,
body.cineai-gumroad .cineai-archive-wrapper{ background:transparent !important; }

/* ── Breadcrumb ── */
body.cineai-gumroad .cineai-breadcrumb,
body.cineai-gumroad .cineai-breadcrumb a{
  color:var(--g-dim) !important; font-weight:700; font-size:.82rem;
}

/* ── Pills / tags / meta ── */
body.cineai-gumroad .cineai-meta-pill,
body.cineai-gumroad .cineai-meta-item,
body.cineai-gumroad .cineai-genre-tag{
  background:var(--g-card) !important; color:var(--g-ink) !important;
  border:var(--g-bd) !important; border-radius:999px !important;
  font-weight:700; font-size:.8rem; padding:5px 13px !important;
  text-decoration:none;
}
body.cineai-gumroad a.cineai-genre-tag{ transition:transform .12s, box-shadow .12s; box-shadow:3px 3px 0 var(--g-shadow); }
body.cineai-gumroad a.cineai-genre-tag:hover{ transform:translate(-2px,-2px); box-shadow:5px 5px 0 var(--g-shadow); background:var(--g-pink) !important; color:#111 !important; }

/* ── Boutons ── */
body.cineai-gumroad .cineai-btn,
body.cineai-gumroad .cineai-btn-trailer,
body.cineai-gumroad button[type="submit"]{
  background:var(--g-pink) !important; color:#111 !important;
  border:2px solid #111 !important; border-radius:10px !important;
  font-weight:900 !important; box-shadow:var(--g-sh);
  min-height:44px; padding:11px 20px !important;
  transition:transform .12s, box-shadow .12s;
}
body.cineai-gumroad .cineai-btn:hover,
body.cineai-gumroad .cineai-btn-trailer:hover{ transform:translate(-2px,-2px); box-shadow:var(--g-sh-big); }
body.cineai-gumroad .cineai-btn:active{ transform:translate(3px,3px); box-shadow:1px 1px 0 var(--g-shadow); }
body.cineai-gumroad .cineai-btn-secondary{ background:var(--g-card) !important; color:var(--g-ink) !important; border-color:var(--g-line) !important; }

/* ── Bloc Où regarder ── */
body.cineai-gumroad .cineai-watch-section{
  background:var(--g-card) !important; border:var(--g-bd) !important;
  border-radius:14px !important; box-shadow:var(--g-sh-big);
  padding:22px 24px !important; margin-block:28px;
}
body.cineai-gumroad .cineai-watch-intro,
body.cineai-gumroad .cineai-watch-disclaimer{ color:var(--g-dim) !important; }
body.cineai-gumroad .cineai-watch-bucket-title{
  font-family:var(--g-font) !important; font-weight:900 !important;
  font-size:.72rem !important; text-transform:uppercase; letter-spacing:.1em;
  color:var(--g-dim) !important;
}
body.cineai-gumroad .cineai-provider-badge{
  background:var(--g-card2) !important; border:var(--g-bd) !important;
  border-radius:11px !important; box-shadow:3px 3px 0 var(--g-shadow);
  padding:10px 16px !important; min-height:48px;
  color:var(--g-ink) !important; font-weight:700;
  transition:transform .12s, box-shadow .12s;
}
body.cineai-gumroad .cineai-provider-badge:hover{ transform:translate(-2px,-2px); box-shadow:5px 5px 0 var(--g-shadow); }
body.cineai-gumroad .cineai-provider-badge img{ border-radius:8px; border:2px solid #111; }
body.cineai-gumroad .cineai-provider-name{ color:var(--g-ink) !important; }
body.cineai-gumroad .cineai-watch-unavailable{ background:var(--g-card2) !important; }

/* ── Épisodes ── */
body.cineai-gumroad .cineai-episodes-grid{ gap:16px !important; }
body.cineai-gumroad .cineai-episode-card{
  background:var(--g-card) !important; border:var(--g-bd) !important;
  border-radius:12px !important; box-shadow:var(--g-sh);
  overflow:hidden; transition:transform .12s, box-shadow .12s;
}
body.cineai-gumroad .cineai-episode-card:hover{ transform:translate(-2px,-2px); box-shadow:var(--g-sh-big); }
body.cineai-gumroad .cineai-episode-number{
  background:var(--g-yellow) !important; color:#111 !important;
  border:2px solid #111; border-radius:999px; font-weight:900 !important;
  padding:2px 10px !important; font-size:.75rem !important;
}
body.cineai-gumroad .cineai-episode-title{ color:var(--g-ink) !important; }
body.cineai-gumroad .cineai-episode-overview{ color:var(--g-dim) !important; }
body.cineai-gumroad .cineai-episode-date,
body.cineai-gumroad .cineai-episode-rating{ color:var(--g-dim) !important; font-weight:700; }
body.cineai-gumroad .cineai-episode-runtime{
  background:var(--g-yellow) !important; color:#111 !important;
  border:2px solid #111; border-radius:6px; font-weight:900;
}

/* ── Cartes (carousels, archives, grilles) ── */
body.cineai-gumroad .cineai-card,
body.cineai-gumroad .cineai-serie-card{
  background:var(--g-card) !important; border:var(--g-bd) !important;
  border-radius:12px !important; box-shadow:var(--g-sh);
  overflow:hidden; transition:transform .12s, box-shadow .12s;
}
body.cineai-gumroad .cineai-card:hover,
body.cineai-gumroad .cineai-serie-card:hover{ transform:translate(-2px,-2px); box-shadow:var(--g-sh-big); }
body.cineai-gumroad .cineai-card-title,
body.cineai-gumroad .cineai-card-title a{ color:var(--g-ink) !important; font-weight:700 !important; }
body.cineai-gumroad .cineai-card-subtitle,
body.cineai-gumroad .cineai-card-meta{ color:var(--g-dim) !important; }
body.cineai-gumroad .cineai-rating{
  background:var(--g-yellow) !important; color:#111 !important;
  border:2px solid #111 !important; border-radius:999px !important; font-weight:900 !important;
}
body.cineai-gumroad .cineai-no-poster{ background:var(--g-card2) !important; color:var(--g-dim) !important; border-radius:8px; }

/* ── Sections de contenu (synopsis, analyse IA, avis) ── */
body.cineai-gumroad .cineai-ai-section,
body.cineai-gumroad .cineai-saison-description,
body.cineai-gumroad .cineai-saison-synopsis,
body.cineai-gumroad .cineai-comments-section{
  background:var(--g-card) !important; border:var(--g-bd) !important;
  border-radius:14px !important; padding:22px 24px !important;
  box-shadow:var(--g-sh); margin-block:24px;
  color:var(--g-ink) !important;
}

/* ── Archives : header, filtres, pagination ── */
body.cineai-gumroad .cineai-archive-header{ background:transparent !important; }
body.cineai-gumroad .cineai-archive-title{ color:var(--g-ink) !important; }
body.cineai-gumroad .cineai-archive-count{ color:var(--g-dim) !important; }
body.cineai-gumroad .cineai-archive-filters,
body.cineai-gumroad .cineai-filter-form{
  background:var(--g-card) !important; border:var(--g-bd) !important;
  border-radius:12px !important; box-shadow:var(--g-sh); padding:16px !important;
}
body.cineai-gumroad .cineai-filter-form input,
body.cineai-gumroad .cineai-filter-form select{
  background:var(--g-card2) !important; color:var(--g-ink) !important;
  border:2px solid var(--g-line) !important; border-radius:9px !important;
  min-height:42px; font-family:var(--g-font);
}
body.cineai-gumroad .cineai-pagination a,
body.cineai-gumroad .cineai-pagination span{
  background:var(--g-card) !important; color:var(--g-ink) !important;
  border:var(--g-bd) !important; border-radius:9px !important;
  font-weight:900 !important; min-width:44px; min-height:44px;
  display:inline-flex; align-items:center; justify-content:center;
  box-shadow:3px 3px 0 var(--g-shadow); text-decoration:none;
}
body.cineai-gumroad .cineai-pagination .current{
  background:var(--g-pink) !important; color:#111 !important;
}

/* ── Backdrop des fiches : toujours un scrim lisible ── */
body.cineai-gumroad .cineai-backdrop-overlay{
  background:linear-gradient(to bottom, rgba(10,8,12,.55), var(--g-paper) 96%) !important;
}

/* ── Toggle thème flottant ── */
.bw-toggle-fab{
  position:fixed; right:18px; bottom:18px; z-index:9999;
  background:var(--g-yellow); color:#111; border:2px solid #111;
  border-radius:999px; font-weight:900; font-size:.82rem;
  font-family:'Archivo',system-ui,sans-serif;
  padding:11px 17px; min-height:46px; cursor:pointer;
  box-shadow:4px 4px 0 rgba(0,0,0,.6);
  transition:transform .12s, box-shadow .12s;
}
.bw-toggle-fab:hover{ transform:translate(-2px,-2px); box-shadow:6px 6px 0 rgba(0,0,0,.6); }

@media (prefers-reduced-motion: reduce){
  body.cineai-gumroad *{ transition:none !important; }
}


/* ── Fix textes fantômes (couleurs en dur des templates qui gagnaient) ── */
body.cineai-gumroad .cineai-synopsis-block h2,
body.cineai-gumroad .cineai-synopsis-block h3,
body.cineai-gumroad .cineai-synopsis-block p,
body.cineai-gumroad .cineai-synopsis-block li,
body.cineai-gumroad .cineai-synopsis-block strong,
body.cineai-gumroad .cineai-synopsis-block em,
body.cineai-gumroad .cineai-synopsis-section p,
body.cineai-gumroad .cineai-ai-section h2,
body.cineai-gumroad .cineai-ai-section h3,
body.cineai-gumroad .cineai-ai-section p,
body.cineai-gumroad .cineai-ai-section li,
body.cineai-gumroad .cineai-ai-section strong,
body.cineai-gumroad .cineai-saison-description p,
body.cineai-gumroad .cineai-saison-synopsis p,
body.cineai-gumroad .cineai-watch-intro,
body.cineai-gumroad .cineai-watch-intro strong{
  color:var(--g-ink) !important;
  opacity:1 !important;
}
body.cineai-gumroad .cineai-b2-marquee div{ color:#111 !important; }

/* ── Header & footer Astra assortis (scopés aux pages CineAI) ── */
body.cineai-gumroad #masthead,
body.cineai-gumroad .main-header-bar,
body.cineai-gumroad [data-section*="header"] .ast-builder-grid-row,
body.cineai-gumroad .ast-main-header-wrap,
body.cineai-gumroad .ast-primary-header-bar{
  background:var(--g-paper) !important;
  background-color:var(--g-paper) !important;
}
body.cineai-gumroad #masthead{
  border-bottom:2px solid var(--g-line);
}
body.cineai-gumroad #masthead .main-header-menu a,
body.cineai-gumroad #masthead .menu-item a,
body.cineai-gumroad #masthead .site-title,
body.cineai-gumroad #masthead .site-title a,
body.cineai-gumroad #masthead .site-description,
body.cineai-gumroad #masthead svg{
  color:var(--g-ink) !important;
  fill:var(--g-ink) !important;
}
body.cineai-gumroad #masthead .menu-item a{
  font-weight:700;
}
body.cineai-gumroad #masthead .menu-item a:hover{
  color:var(--g-ink) !important;
  text-decoration:underline;
  text-decoration-color:var(--g-pink);
  text-decoration-thickness:3px;
  text-underline-offset:6px;
}
body.cineai-gumroad #masthead .current-menu-item > a,
body.cineai-gumroad #masthead .current_page_item > a{
  background:var(--g-pink);
  color:#111 !important;
  border:2px solid #111;
  border-radius:999px;
  padding:6px 16px !important;
}
body.cineai-gumroad #masthead .sub-menu{
  background:var(--g-card) !important;
  border:var(--g-bd);
  border-radius:12px;
  box-shadow:var(--g-sh);
  overflow:hidden;
}
body.cineai-gumroad #masthead .sub-menu .menu-item a{
  color:var(--g-ink) !important;
  background:transparent !important;
  border:none;
  border-radius:0;
}
body.cineai-gumroad #masthead .sub-menu .menu-item a:hover{
  background:var(--g-pink) !important;
  color:#111 !important;
  text-decoration:none;
}

body.cineai-gumroad #colophon,
body.cineai-gumroad .site-footer,
body.cineai-gumroad .site-footer .ast-builder-grid-row{
  background:var(--g-paper) !important;
  background-color:var(--g-paper) !important;
  color:var(--g-dim) !important;
}
body.cineai-gumroad #colophon{
  border-top:2px solid var(--g-line);
}
body.cineai-gumroad #colophon a{ color:var(--g-ink) !important; font-weight:700; }
body.cineai-gumroad #colophon a:hover{ text-decoration:underline; text-decoration-color:var(--g-pink); text-decoration-thickness:3px; }
body.cineai-gumroad #colophon .widget-title{ color:var(--g-ink) !important; font-family:var(--g-display) !important; }

/* ── Pages génériques (Contact…) : formulaires et contenu assortis ── */
body.cineai-gumroad .entry-content h1,
body.cineai-gumroad .entry-title{ color:var(--g-ink) !important; font-family:var(--g-display) !important; }
body.cineai-gumroad input[type="text"],
body.cineai-gumroad input[type="email"],
body.cineai-gumroad input[type="search"],
body.cineai-gumroad textarea,
body.cineai-gumroad select,
body.cineai-gumroad .ff-el-form-control{
  background:var(--g-card) !important; color:var(--g-ink) !important;
  border:2px solid var(--g-line) !important; border-radius:10px !important;
  min-height:44px; font-family:var(--g-font) !important;
}
body.cineai-gumroad textarea{ min-height:120px; }
body.cineai-gumroad input::placeholder,
body.cineai-gumroad textarea::placeholder{ color:var(--g-dim) !important; opacity:1; }
body.cineai-gumroad .ff-btn-submit,
body.cineai-gumroad input[type="submit"],
body.cineai-gumroad button[type="submit"]{
  background:var(--g-pink) !important; color:#111 !important;
  border:2px solid #111 !important; border-radius:10px !important;
  font-weight:900 !important; box-shadow:var(--g-sh);
  min-height:46px; padding:11px 22px !important;
  transition:transform .12s, box-shadow .12s;
}
body.cineai-gumroad .ff-btn-submit:hover{ transform:translate(-2px,-2px); box-shadow:var(--g-sh-big); }
