/* Barre latérale (barre.js). Téléphone : capture 2026-11-16/036 (panneau 290 px pleine hauteur, fond #FCFCFC,
   rangées de 44 px, texte 16 px, voile rgba(0,0,0,.15)) ; iPad : 049 (300 px pleine hauteur, rayon 0, texte 14 px,
   pas de voile visible). Ombre du panneau : celle du relevé (§ 2). Compte : 14 px graisse 600 (relevé), ⌃⌄ à droite ;
   « Documents & Dossiers » actif sur gray-5 rayon 6 ; « Unpinned » 12 px graisse 600 gray-40. Menu du compte : boîte
   blanche, rayon 6, ombre --rn-clr-shadow-menu (styles-remnote.md), entrées 14 px (002) de 44 px (cible tactile).
   Écart : à l'iPad les rangées de 049 font 33 px ; ici 44 px (règle du lot, cibles tactiles). */

.voile { position: fixed; inset: 0; z-index: 30; background: rgba(0, 0, 0, .15); }
.barre {
  position: fixed; top: 0; bottom: 0; left: 0; z-index: 31;
  display: flex; flex-direction: column;
  width: calc(290px + var(--gauche));
  padding: calc(8px + var(--haut)) 8px calc(8px + var(--bas)) calc(8px + var(--gauche));
  overflow-y: auto; overscroll-behavior: contain;
  background: var(--panneau);
  box-shadow: 0 0 0 1px rgba(0, 15, 40, .05), 0 3px 6px rgba(0, 15, 40, .1), 0 9px 24px rgba(0, 15, 40, .2);
  font: 400 16px/24px var(--rn-police);
}
body.barre-ouverte { overflow: hidden; }

.barre-haut { position: relative; }
.barre-compte {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: var(--cible); padding: 0 8px;
  border-radius: 6px; font: 600 14px/20px var(--rn-police); color: var(--rn-texte); text-align: left;
}
.barre-compte img { flex: none; width: 16px; height: 16px; }
.barre-email { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.barre-fleches { flex: none; color: var(--rn-texte-3); }
.barre-fleches svg { width: 16px; height: 16px; }
.barre-menu {
  position: absolute; left: 0; right: 0; top: calc(var(--cible) + 4px); z-index: 2;
  padding: 4px; border-radius: 6px; background: var(--rn-fond);
  box-shadow: 0 8px 16px rgba(65, 65, 85, .2), inset 0 0 0 .5px rgba(65, 65, 85, .1);
}
.barre-menu-entree {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: var(--cible); padding: 0 10px;
  border-radius: 4px; font: 400 14px/20px var(--rn-police); color: var(--rn-texte); text-align: left;
}
.barre-menu-entree:active { background: var(--rn-gris-5); }
.barre-menu-entree svg { width: 16px; height: 16px; flex: none; }
.barre-menu-erreur { margin: 4px 10px 8px; font: 400 13px/18px var(--rn-police); color: #e6193f; }

.barre-entrees { margin-top: 4px; }
.barre-ligne {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: var(--cible);
  padding: 0 8px 0 calc(8px + var(--retrait, 0) * 18px);
  border-radius: 6px; color: var(--rn-texte); text-align: left;
}
.barre-ligne > svg { width: 20px; height: 20px; flex: none; color: var(--rn-texte-2); }
.barre-entree.actif { background: var(--rn-gris-5); }
.barre-nom { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.barre-section { margin: 14px 8px 6px; font: 600 12px/16px var(--rn-police); color: var(--rn-texte-3); }
.barre-chevron, .barre-puce { display: flex; align-items: center; justify-content: center; flex: none; width: 12px; color: var(--rn-texte-3); }
.barre-chevron svg { width: 12px; height: 12px; transition: transform .15s; }
.barre-dossier[aria-expanded="true"] .barre-chevron svg { transform: rotate(90deg); }
.barre-puce::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--rn-gris-30); }
.barre-ic { display: inline-flex; flex: none; width: 18px; height: 18px; align-items: center; justify-content: center; }
.barre-ic svg { width: 18px; height: 18px; }
.barre-ic.ic-dossier { color: rgb(167, 139, 250); }
.barre-ic.ic-pdf { width: 18px; height: 18px; border-radius: 3px; background: var(--rn-bleu-5); }
.barre-ic .emoji { font-size: 15px; line-height: 1; }

@media (min-width: 768px) {
  .voile { background: transparent; }
  .barre { width: calc(300px + var(--gauche)); font-size: 14px; line-height: 20px; }
  .barre-ligne > svg { width: 16px; height: 16px; }
}
