html,body{margin:0;background:#111418;color:#E5E5E4}

/* Menu de langues */
details[data-kl-lang]{position:relative}
details[data-kl-lang]>summary{display:flex;align-items:center;gap:8px;padding:9px 11px;border:1px solid #3a4248;color:#E5E5E4;font-size:14px;font-weight:500;line-height:1;cursor:pointer;user-select:none;list-style:none;transition:border-color .2s}
details[data-kl-lang]>summary::-webkit-details-marker{display:none}
details[data-kl-lang]>summary:hover,details[data-kl-lang][open]>summary{border-color:#86B3E3}
details[data-kl-lang] img{display:block;width:24px;height:16px;flex-shrink:0}
[data-kl-caret]{font-size:10px;color:#A4A4A3;transition:transform .2s}
details[data-kl-lang][open] [data-kl-caret]{transform:rotate(180deg)}
[data-kl-panel]{position:absolute;inset-inline-end:0;top:calc(100% + 10px);z-index:30;display:grid;grid-template-columns:repeat(2,max-content);gap:2px 6px;padding:8px;background:#14191E;border:1px solid #3a4248;box-shadow:0 24px 60px rgba(0,0,0,.55)}
[data-kl-panel] a{display:flex;align-items:center;gap:10px;padding:9px 14px 9px 10px;color:#A4A4A3;text-decoration:none;font-size:15px;line-height:1.2;white-space:nowrap}
[data-kl-panel] a:hover,[data-kl-panel] a:focus-visible{background:rgba(134,179,227,.10);color:#E5E5E4}
[data-kl-panel] a[aria-current]{color:#E5E5E4;box-shadow:inset 2px 0 0 #86B3E3}
html[dir="rtl"] [data-kl-panel] a[aria-current]{box-shadow:inset -2px 0 0 #86B3E3}
/* Petit écran : le panneau s'ancre au bandeau (position:sticky) et prend toute la largeur */
@media (max-width:720px){
details[data-kl-lang]{position:static}
[data-kl-panel]{left:16px;right:16px;top:calc(100% + 6px);grid-template-columns:repeat(2,auto);justify-content:space-between}
}

/* Le script du site efface la couleur en ligne des liens du menu après le premier défilement :
   on la redonne ici pour qu'ils ne virent pas au bleu des liens ordinaires. */
header nav a[href^="#"]:not([data-sheen]){color:#A4A4A3}
header nav a[href^="#"]:not([data-sheen]):hover{color:#E5E5E4}

/* Écritures sans capitales ni approche négative : on desserre les titres */
html[lang="ar"] *,html[lang="hi"] *,html[lang="bn"] *{letter-spacing:0!important}
html[lang="ar"] h1,html[lang="ar"] h2,html[lang="ar"] h3,html[lang="hi"] h1,html[lang="hi"] h2,html[lang="hi"] h3,html[lang="bn"] h1,html[lang="bn"] h2,html[lang="bn"] h3{line-height:1.3!important}
html[lang="zh-Hans"] h1,html[lang="zh-Hans"] h2{line-height:1.2!important}

/* Droite à gauche : le terminal et la frise chronologique (dessinée en 3D) restent de gauche à droite */
html[dir="rtl"] [data-type],html[dir="rtl"] div[data-sec="KCore"][data-at]{direction:ltr;text-align:left}
html[dir="rtl"] [data-sec-root="Feuille"] ol{direction:ltr}
html[dir="rtl"] [data-sec-root="Feuille"] ol>li{direction:rtl;text-align:left}
html[dir="rtl"] section[aria-labelledby="titre-heros"]>div:nth-of-type(3){transform:scaleX(-1)}
