/* ═══════════════════════════════════════════════════════════════════
   bangladesh.css — Thème : Delta du Gange, vert riz, disque rouge du drapeau
   Couleurs drapeau : vert bouteille + disque rouge — plus tons terre d'alluvions et jute
   Polices : Tiro Bangla (bengali-compatible serif) + Hind Siliguri + JetBrains Mono
   ═══════════════════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Tiro+Bangla:ital@0;1&family=Hind+Siliguri:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --sb:     #03150a;                /* vert foncé riz */
  --sb2:    #061d0f;
  --surf:   #0a2914;
  --surf2:  #0f3620;

  --vert:       #006A4E;            /* vert drapeau Bangladesh */
  --vert-2:     #2ea278;
  --vert-p:     rgba(0,106,78,.14);
  --vert-d:     rgba(0,106,78,.50);
  --rouge:      #F42A41;            /* disque solaire rouge */
  --rouge-2:    #ff5668;
  --rouge-p:    rgba(244,42,65,.12);
  --jute:       #b68754;             /* jute doré */
  --jute-2:     #d9aa73;
  --riz:        #c8d9a4;             /* vert riz clair */
  --sari:       #d4af37;             /* or jamdani */

  --ink:    #eef3e4;
  --ink2:   rgba(238,243,228,.64);
  --ink3:   rgba(238,243,228,.28);

  --brd:    rgba(182,135,84,.22);
  --brdh:   rgba(244,42,65,.45);

  --fd: 'Tiro Bangla', Georgia, serif;
  --fb: 'Hind Siliguri', sans-serif;
  --fm: 'JetBrains Mono', monospace;

  --sw: 272px;
  --r: 6px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--fb);
  background: var(--sb);
  color: var(--ink);
  font-size: 16.5px;
  line-height: 1.78;
  background-image:
    radial-gradient(ellipse at 70% 18%, rgba(244,42,65,.12) 0, transparent 42%),
    radial-gradient(ellipse at 20% 80%, rgba(0,106,78,.14) 0, transparent 50%),
    radial-gradient(ellipse at 55% 50%, rgba(182,135,84,.05) 0, transparent 60%);
  background-attachment: fixed;
}

/* Disque solaire rouge stylisé en fond (symbole drapeau) */
body::before {
  content: ''; position: fixed; top: 50%; right: -180px; width: 360px; height: 360px;
  border-radius: 50%; z-index: -1; pointer-events: none;
  background: radial-gradient(circle, rgba(244,42,65,.06) 0%, transparent 65%);
}

.progress-bar {
  position: fixed; top: 0; left: 0; height: 4px; width: 0%;
  background: linear-gradient(90deg, var(--vert), var(--rouge), var(--sari), var(--rouge), var(--vert));
  z-index: 200; transition: width .08s linear;
  box-shadow: 0 1px 10px rgba(244,42,65,.4);
}

.page-layout { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sw); flex-shrink: 0;
  background: linear-gradient(180deg, var(--sb2) 0%, var(--sb) 100%);
  border-right: 1px solid var(--brd);
  position: sticky; top: 0; height: 100vh;
  overflow-y: auto; display: flex; flex-direction: column;
  scrollbar-width: thin; scrollbar-color: var(--surf2) transparent;
}
.sidebar-header {
  padding: 30px 22px 22px;
  border-bottom: 1px solid var(--brd);
  position: relative; overflow: hidden;
  background: var(--vert);
}
.sidebar-header::before {
  /* disque rouge décalé à gauche */
  content: ''; position: absolute; width: 42px; height: 42px;
  border-radius: 50%; background: var(--rouge);
  right: 30px; top: 50%; transform: translateY(-50%);
  box-shadow: 0 0 16px rgba(244,42,65,.6);
  opacity: .75;
}
.sidebar-header::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(0,0,0,.55), rgba(0,0,0,.80));
}
.sidebar-header > * { position: relative; z-index: 1; }
.sidebar-back {
  font-family: var(--fm); font-size: .6rem; letter-spacing: .14em;
  color: var(--ink3); text-decoration: none; display: block; margin-bottom: 12px;
}
.sidebar-back:hover { color: var(--jute-2); }
.sidebar-title {
  font-family: var(--fd); font-size: 2rem; font-weight: 400;
  color: var(--riz); line-height: 1.0; letter-spacing: -.01em;
  text-shadow: 0 1px 2px rgba(0,0,0,.7);
}
.toc-nav { padding: 10px 0 14px; flex: 1; }
.toc-section-label {
  font-family: var(--fm); font-size: .58rem; letter-spacing: .2em;
  text-transform: uppercase; color: var(--ink3); padding: 8px 22px 4px;
}
.toc-link {
  display: block; padding: 5px 22px 5px 26px;
  font-family: var(--fb); font-size: .83rem; font-weight: 400;
  color: var(--ink2); text-decoration: none;
  border-left: 2px solid transparent; transition: all .15s;
}
.toc-link:hover, .toc-link.active {
  color: var(--rouge-2); border-left-color: var(--rouge); background: var(--rouge-p);
}
.sidebar-nav { padding: 12px 22px; border-top: 1px solid var(--brd); }
.sidebar-nav p {
  font-family: var(--fm); font-size: .56rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--ink3); margin-bottom: 7px;
}
.sidebar-nav a {
  display: block; font-family: var(--fb); font-size: .8rem;
  color: var(--ink3); text-decoration: none; padding: 2px 0;
}
.sidebar-nav a:hover, .sidebar-nav a.current { color: var(--rouge-2); }
.sidebar-nav a.current { font-weight: 700; }

.main { flex: 1; min-width: 0; padding: 0 58px 100px; max-width: 840px; }

.page-header {
  padding: 54px 0 36px; margin-bottom: 50px;
  border-bottom: 1px solid var(--brd); position: relative;
}
.page-header::before {
  /* bannière drapeau */
  content: ''; position: absolute; top: 12px; right: 0;
  width: 100px; height: 62px;
  background: var(--vert);
  border-radius: 3px;
  box-shadow: inset 0 0 0 2px var(--sari);
}
.page-header::after {
  content: ''; position: absolute; top: 26px; right: 36px;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--rouge);
  box-shadow: 0 0 14px rgba(244,42,65,.6);
}
.subject-tag {
  font-family: var(--fm); font-size: .62rem; letter-spacing: .2em;
  text-transform: uppercase; color: var(--rouge-2); margin-bottom: 12px;
}
h1.page-title {
  font-family: var(--fd); font-size: 3.7rem; font-weight: 400;
  color: var(--ink); line-height: .96; letter-spacing: -.015em;
}
h1.page-title .sub {
  color: var(--jute-2); font-size: 1.05rem;
  display: block; margin-top: 10px;
  font-family: var(--fd); letter-spacing: .01em; font-style: italic;
}
.page-intro { margin-top: 18px; font-size: 1rem; color: var(--ink2); max-width: 570px; }

.section { margin-bottom: 60px; scroll-margin-top: 26px; }
h2.section-title {
  font-family: var(--fd); font-size: 2rem; font-weight: 400;
  color: var(--ink); margin-bottom: 20px; padding-bottom: 8px;
  border-bottom: 1px solid var(--brd);
  display: flex; align-items: baseline; gap: 14px;
  letter-spacing: -.01em;
}
h2.section-title .num {
  font-family: var(--fm); font-size: .7rem;
  color: #fff; background: var(--rouge);
  padding: 3px 11px; border-radius: 3px; font-weight: 500;
  box-shadow: 0 0 8px rgba(244,42,65,.5);
}
h3.sub-title {
  font-family: var(--fd); font-size: 1.3rem; font-weight: 400; font-style: italic;
  color: var(--jute-2); margin: 26px 0 11px;
}
p { margin-bottom: .9em; } ul, ol { padding-left: 1.4em; margin-bottom: .9em; } li { margin-bottom: .3em; }

.box { padding: 15px 18px 13px; margin: 16px 0; border-radius: var(--r); border: 1px solid var(--brd); background: rgba(255,255,255,.03); }
.box-label { font-family: var(--fm); font-size: .62rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; display: block; margin-bottom: 8px; }
.box.def       { background: var(--vert-p); border-color: var(--vert-d); } .box.def .box-label { color: var(--vert-2); }
.box.histoire  { background: var(--rouge-p); border-left: 4px solid var(--rouge); } .box.histoire .box-label { color: var(--rouge-2); }
.box.technique { background: rgba(182,135,84,.10); border-left: 4px solid var(--jute); } .box.technique .box-label { color: var(--jute-2); }
.box.conseil   { background: rgba(200,217,164,.08); border-left: 4px solid var(--riz); } .box.conseil .box-label { color: var(--riz); }
.box.attention { background: rgba(244,42,65,.14); border-left: 4px solid var(--rouge); } .box.attention .box-label { color: var(--rouge-2); }
.box.chiffres  { background: rgba(0,0,0,.44); border-color: var(--brdh); } .box.chiffres .box-label { color: var(--jute-2); }
.box.remark    { background: transparent; border-left: 3px solid var(--brd); padding-left: 20px; } .box.remark .box-label { color: var(--ink3); }

.detail-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--fb); font-weight: 600; font-size: .88rem;
  color: var(--rouge-2); border: 1px solid var(--rouge);
  padding: 4px 14px; border-radius: 3px; cursor: pointer;
  background: transparent; margin-top: 8px; transition: all .18s; user-select: none;
  text-transform: uppercase; letter-spacing: .08em;
}
.detail-toggle:hover { background: var(--rouge); color: #fff; }
.detail-toggle .arrow { transition: transform .2s; }
.detail-toggle.open .arrow { transform: rotate(90deg); }
.detail-content { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.detail-content.open { max-height: 900px; }
.detail-inner { margin-top: 10px; padding: 13px 18px; background: rgba(0,0,0,.38); border: 1px dashed var(--brd); border-radius: var(--r); color: var(--ink2); font-size: .93rem; }

.data-table { width: 100%; border-collapse: collapse; margin: 14px 0; font-size: .89rem; border-radius: var(--r); overflow: hidden; border: 1px solid var(--brd); }
.data-table th { background: var(--vert); color: var(--riz); padding: 9px 14px; text-align: left; font-family: var(--fm); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; border-bottom: 1px solid var(--brdh); }
.data-table td { padding: 8px 14px; border-bottom: 1px solid var(--brd); vertical-align: top; }
.data-table tr:hover td { background: var(--vert-p); }
.data-table td:first-child { font-family: var(--fm); font-size: .8rem; color: var(--jute-2); }

code { font-family: var(--fm); font-size: .82em; background: rgba(0,0,0,.35); color: var(--jute-2); padding: 2px 6px; border-radius: 3px; border: 1px solid var(--brd); }
em { color: var(--jute-2); font-style: italic; }
strong { color: var(--ink); font-weight: 700; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 14px 0; } .two-col .box { margin: 0; }

.mobile-header { display: none; position: sticky; top: 0; z-index: 50; background: var(--vert); border-bottom: 3px solid var(--rouge); padding: 12px 18px; align-items: center; justify-content: space-between; }
.mobile-menu-btn { background: none; border: none; color: var(--riz); font-size: 1.3rem; cursor: pointer; }
.mobile-title { font-family: var(--fd); font-size: 1.1rem; color: var(--riz); font-weight: 400; }
.mobile-drawer { display: none; position: fixed; inset: 0; z-index: 100; } .mobile-drawer.open { display: flex; }
.drawer-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.8); }
.drawer-panel { position: relative; z-index: 1; width: 272px; background: var(--sb2); height: 100%; overflow-y: auto; padding: 14px 0; border-right: 1px solid var(--brd); }

@media (max-width: 960px) {
  .sidebar { display: none; }
  .mobile-header { display: flex; }
  .main { padding: 0 20px 70px; }
  h1.page-title { font-size: 2.6rem; }
  .page-header::before, .page-header::after { display: none; }
  .two-col { grid-template-columns: 1fr; }
}
