/* #2683 — le bandeau « limite du plan » sur l'ATLAS : dans le flux en tête de #app-shell (idiome du bandeau de l'Œil et du
   mode aide), marge de la sidebar. Le LOOK est celui de l'Accueil (.home-quota, home.css) — mêmes crans, mêmes couleurs ;
   la garde test-2683-bandeau-quota-atlas compare les styles calculés des deux pour qu'ils ne dérivent pas. */
.quota-bandeau[hidden] { display: none !important; }
.quota-bandeau {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin: 0 0 0 var(--sidebar-w, 220px);
  position: relative; z-index: 31;
  padding: 11px 20px; text-align: center;
  font-family: var(--font);
  font-size: 13.5px; font-weight: 600;
  /* #2688 : le rouge est celui de l'anneau de « Votre espace privé » (--color-danger) ; reste 3 → 1 monte, le plan atteint est PLEIN, texte blanc */
  background: color-mix(in srgb, var(--color-danger, #e11d48) 12%, white);
  color: color-mix(in srgb, var(--color-danger, #e11d48) 80%, black);
}
@media (max-width: 760px) { .quota-bandeau { flex-direction: column; gap: 10px; } }
@media (max-width: 700px) { .quota-bandeau { margin-left: 0; } }
.quota-bandeau[data-montee="2"] { background: color-mix(in srgb, var(--color-danger, #e11d48) 26%, white); }
.quota-bandeau[data-montee="3"] { background: color-mix(in srgb, var(--color-danger, #e11d48) 46%, white); }
.quota-bandeau[data-montee="4"] { background: var(--color-danger, #e11d48); color: #fff; }
.quota-bandeau .home-quota-lien {
  appearance: none; cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 700;
  padding: 6px 13px; border-radius: 999px; border: 1px solid currentColor;
  background: none; color: inherit;
}
.quota-bandeau .home-quota-lien:hover { background: color-mix(in srgb, currentColor 12%, transparent); }

/* ══ RIEN NE PASSE SOUS LE BANDEAU ══
   Les éléments fixes ancrés à top:0 descendent de la hauteur de TOUS les bandeaux en tête (Œil, mode aide, quota — chacun a
   sa hauteur MESURÉE) : une seule somme, --bandeaux-h, à partir des classes que chaque bandeau pose sur <body>. */
body { --d-oeil: 0px; --d-aide: 0px; --d-quota: 0px; --bandeaux-h: calc(var(--d-oeil) + var(--d-aide) + var(--d-quota)); }
body.has-oeil-bandeau { --d-oeil: var(--oeil-h, 44px); }
body.has-mode-aide { --d-aide: var(--mode-aide-h, 44px); }
body.has-quota-bandeau { --d-quota: var(--quota-h, 44px); }
/* le rail de l'Atlas (#topnav est <header> de #app-shell) : spécificité au-dessus des règles de l'Œil et du mode aide */
body.has-quota-bandeau:not(#x) #app-shell > header { top: var(--bandeaux-h); }
body.has-quota-bandeau:not(#x) #atlas-ctx { top: var(--bandeaux-h); }
body.has-quota-bandeau:not(#x) #atlas-search { top: var(--bandeaux-h); }
body.has-quota-bandeau:not(#x) #style-fabs { top: calc(var(--loge-top, 18px) + var(--loge-item, 38px) + 12px + var(--bandeaux-h)); }
body.has-quota-bandeau:not(#x) #look-carousel { top: calc(var(--loge-top, 18px) + var(--bandeaux-h)
  + (100% - var(--loge-top, 18px) - var(--bandeaux-h) - var(--loge-bottom, 20px)) * ((1 - var(--rail-h, 0.62)) / 2)); }
/* mobile : la barre du haut est FIXE et le bandeau vient dessous (#app-shell a un padding-top) — la barre ne descend donc pas */
@media (max-width: 768px) {
  body.has-quota-bandeau:not(#x) #app-shell > header { top: 0; }
  body.has-quota-bandeau:not(#x) #atlas-ctx { top: calc(72px + var(--bandeaux-h)); }
}
