/*
 * ESAP / infolettre du 20 novembre 2026 / accessibilite transversale.
 * Les preferences sont gerees par l'extension ESAP Semantique et accessibilite
 * via html[data-esap-theme], data-esap-contrast, data-esap-font, etc.
 * Les mises en page sont des variantes et jamais une seconde barre d'accessibilite.
 * Aucune couleur ne depend des seules preferences du systeme.
 */

/* 1. Contrastes garantis dans la composition claire, meme si d'autres
      feuilles Divi ou un ancien mode sombre ont laisse des styles residuels. */
body.esap-nov20-issue .newsletter-page.esap-nov20 .hero-card :is(h1,p,.hero-date,.tagline){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .hero-card .eyebrow{color:#075f83!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .transition-card :is(h2,p){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .transition-card .rubric{color:#466325!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .intro-spread :is(p,strong,em){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .intro-spread .rubric{color:#075f83!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .intro-spread .margin-note :is(p,strong){color:#315466!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .summary :is(h2,.summary-card .label){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .summary .summary-card:first-child :is(.number,.label){color:#fff!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .story :is(h2,p,strong,em,.story-number){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .story .rubric{color:#075f83!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-date :is(p,strong,em,.esap-number){color:#fff!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-date .esap-detail{color:#e3f2f8!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-date .rubric{color:#a6e5f8!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-theme :is(p,strong,.esap-theme),
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-note :is(p,strong,.esap-serif),
body.esap-nov20-issue .newsletter-page.esap-nov20 .esap-nov20-quotation :is(p,strong){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .footer :is(p,strong,small,span,a){color:#def0f8!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar :is(strong,small,span,a,button){color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar a.esap-reading-home{background:#e7f3fa!important;color:#13394b!important}
body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar a.esap-reading-home :is(span,svg){color:inherit!important}

/* 2. Modes Nuit et Sepia : tout l'espace editorial change ENSEMBLE.
      La feuille globale ESAP rend les textes clairs sous .entry-content.
      Des surfaces non adaptees produisaient du blanc sur blanc. */
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20{
  --n20-page:var(--esap-a11y-page,#091625);
  --n20-surface:var(--esap-a11y-surface,#152c40);
  --n20-raised:var(--esap-a11y-raised,#214158);
  --n20-text:var(--esap-a11y-text,#fbfbf5);
  --n20-secondary:var(--esap-a11y-secondary,#d5e2ee);
  --n20-link:var(--esap-a11y-link,#a3e9ff);
  --n20-border:var(--esap-a11y-border,#92b4c7);
  --n20-emphasis:var(--esap-a11y-emphasis,#f8d377);
  color:var(--n20-text)!important;
  background:var(--n20-page)!important;
  border-color:var(--n20-border)!important;
  color-scheme:inherit!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.summary,.story,.shell){
  background:var(--n20-page)!important;
  color:var(--n20-text)!important;
  border-color:var(--n20-border)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card,.transition-card,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-date,.esap-nov20-quotation,.summary-card,.margin-note){
  background:var(--n20-surface)!important;
  color:var(--n20-text)!important;
  border-color:var(--n20-border)!important;
  background-image:none!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.summary-card:first-child,.summary-card:nth-child(4),.summary-card:nth-child(5),.esap-nov20-date,.esap-nov20-quotation,.esap-nov20-note){
  background:var(--n20-raised)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card,.transition-card,.intro-spread,.summary,.story,.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation,.summary-card,.margin-note,.footer) :is(h1,h2,h3,h4,h5,h6,p,span,strong,em,small,time,.label,.number,.rubric,.eyebrow,.story-number,.esap-number,.editorial-label,.tagline){
  color:var(--n20-text)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .footer{
  background:var(--n20-surface)!important;
  color:var(--n20-text)!important;
  border-top:1px solid var(--n20-border)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.reading-bar,.reading-top,.reading-menu){
  background:var(--n20-surface)!important;
  color:var(--n20-text)!important;
  border-color:var(--n20-border)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar :is(a,button,strong,small,span,svg){
  color:var(--n20-text)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar :is(a.esap-reading-home,button){
  background:var(--n20-raised)!important;
  color:var(--n20-text)!important;
  border:1px solid var(--n20-border)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.footer,.story,.intro-spread,.summary) a:not(.summary-card){
  color:var(--n20-link)!important;
}
/* Les pastilles du premier element du sommaire sont blanches en mode Jour :
   ecarter cet heritage sur le fond Sepia et respecter le mode Nuit. */
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .summary .summary-card:first-child :is(.number,.label){
  color:var(--n20-text)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .story-number{
  color:var(--n20-emphasis)!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.stripe,.reading-progress){
  filter:none!important;opacity:1!important;
}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .stripe span:nth-child(1){background:#25b4df!important}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .stripe span:nth-child(2){background:#8cc63f!important}
html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 .stripe span:nth-child(3){background:#fff200!important}

/* 3. Mode contraste renforce, de jour ou de nuit : palette et bordures
      qui restent contrastantes apres activation du controle global. */
html[data-esap-contrast='on'] body.esap-nov20-issue .newsletter-page.esap-nov20{
  background:var(--esap-a11y-page,#fff)!important;
  color:var(--esap-a11y-text,#051b29)!important;
}
html[data-esap-contrast='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card,.transition-card,.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation,.summary-card){
  border:2px solid var(--esap-a11y-border,#315368)!important;
}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.summary,.story){
  background:var(--esap-a11y-page,#fff)!important;
}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card,.transition-card,.summary-card,.esap-nov20-theme,.esap-nov20-date,.esap-nov20-note,.esap-nov20-quotation,.margin-note){
  background:var(--esap-a11y-raised,#e9f5fb)!important;
  color:var(--esap-a11y-text,#051b29)!important;
}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card,.transition-card,.intro-spread,.summary,.story,.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation,.summary-card,.margin-note,.footer) :is(h1,h2,h3,h4,h5,h6,p,span,strong,em,small,.label,.number,.rubric,.eyebrow,.story-number,.esap-number,.tagline){
  color:var(--esap-a11y-text,#051b29)!important;
}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 .footer{
  background:var(--esap-a11y-surface,#fff)!important;
  color:var(--esap-a11y-text,#051b29)!important;
  border-top:2px solid var(--esap-a11y-border,#315368)!important;
}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.footer,.story,.intro-spread,.summary) a:not(.summary-card){color:var(--esap-a11y-link,#00577a)!important}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.reading-bar,.reading-top,.reading-menu){background:var(--esap-a11y-surface,#fff)!important;color:var(--esap-a11y-text,#051b29)!important}
html[data-esap-contrast='on']:not([data-esap-theme='night']) body.esap-nov20-issue .newsletter-page.esap-nov20 .reading-bar :is(a,button,strong,small,span){color:var(--esap-a11y-text,#051b29)!important}

/* 4. Options transversales : police, taille, espacement, longueur de lignes,
      lecteur en une colonne. Le panneau flottant reste celui du site. */
html[data-esap-font='sans'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(h1,h2,h3,h4,h5,h6,p,li,blockquote,a,button,label,small,span,summary){font-family:Verdana,Tahoma,Arial,sans-serif!important}
html[data-esap-font='open'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(h1,h2,h3,h4,h5,h6,p,li,blockquote,a,button,label,small,span,summary){font-family:'ESAP OpenDyslexic','OpenDyslexic',Verdana,Arial,sans-serif!important}
html[data-esap-size='large'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card h1,.transition-card h2,.story h2){font-size:clamp(2.75rem,5.7vw,6rem)!important}
html[data-esap-size='xl'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-card h1,.transition-card h2,.story h2){font-size:clamp(2.8rem,6.2vw,6.3rem)!important}
html[data-esap-size='large'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.intro p,.story p,.margin-note p){font-size:max(1rem,1.09em)!important}
html[data-esap-size='xl'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.intro p,.story p,.margin-note p){font-size:max(1rem,1.16em)!important}
html[data-esap-spacing='comfortable'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(p,li){line-height:1.8!important;letter-spacing:.04em!important;word-spacing:.07em!important}
html[data-esap-spacing='maximum'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(p,li){line-height:1.92!important;letter-spacing:.1em!important;word-spacing:.13em!important}
html[data-esap-width='comfortable'] body.esap-nov20-issue .newsletter-page.esap-nov20 .copy-tile p{max-inline-size:min(100%,68ch)!important}
html[data-esap-width='narrow'] body.esap-nov20-issue .newsletter-page.esap-nov20 .copy-tile p{max-inline-size:min(100%,54ch)!important}
html[data-esap-reader='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.editorial-grid,.summary-grid){display:grid!important;grid-template-columns:minmax(0,1fr)!important}
html[data-esap-reader='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.editorial-grid,.summary-grid)>*{grid-column:auto!important;grid-row:auto!important;width:100%!important;min-width:0!important}
html[data-esap-reader='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 .transition-card{min-height:0!important}
html[data-esap-reader='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 .copy-tile{padding:0!important;max-width:76ch!important}
html[data-esap-reader='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation){min-height:0!important}
html[data-esap-motion='off'] body.esap-nov20-issue .newsletter-page.esap-nov20 *{scroll-behavior:auto!important;transition:none!important;animation:none!important}

/* 5. Impression claire meme si le lecteur a selectionne Nuit ou Sepia. */
@media print{
  html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20,
  html[data-esap-contrast='on'] body.esap-nov20-issue .newsletter-page.esap-nov20{
    background:#fff!important;color:#111!important;color-scheme:light!important
  }
  html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.story,.summary,.hero-card,.transition-card,.summary-card,.copy-tile,.footer,.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation),
  html[data-esap-contrast='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(.hero-bento,.intro-spread,.story,.summary,.hero-card,.transition-card,.summary-card,.copy-tile,.footer,.esap-nov20-date,.esap-nov20-theme,.esap-nov20-note,.esap-nov20-quotation){background:#fff!important;color:#111!important;border-color:#777!important}
  html:is([data-esap-theme='night'],[data-esap-theme='sepia']) body.esap-nov20-issue .newsletter-page.esap-nov20 :is(h1,h2,h3,h4,p,li,span,strong,em,small),
  html[data-esap-contrast='on'] body.esap-nov20-issue .newsletter-page.esap-nov20 :is(h1,h2,h3,h4,p,li,span,strong,em,small){color:#111!important}
}
