/* Options d'accessibilité : bouton flottant + panneau. Indépendant du thème de la page (site public, espace demandeur, back-office). */
.a11y-invert-media img, .a11y-invert-media video, .a11y-invert-media picture, .a11y-invert-media svg image {
  filter: invert(1) hue-rotate(180deg);
}

#a11y-toggle {
  position: fixed;
  z-index: 2147483000;
  right: 16px;
  bottom: 16px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 2px solid #173642;
  background: #fff;
  color: #173642;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .22);
  padding: 0;
}
#a11y-toggle:hover { background: #f4f7fb; }
#a11y-toggle:focus-visible { outline: 3px solid #dfa14f; outline-offset: 2px; }
#a11y-toggle svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

#a11y-panel {
  position: fixed;
  z-index: 2147483000;
  right: 16px;
  bottom: 70px;
  width: 260px;
  max-width: calc(100vw - 32px);
  background: #fff;
  color: #2f3a40;
  border: 1px solid #e3e6ea;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .22);
  padding: 14px 16px 10px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 14px;
}
#a11y-panel h2 { margin: 0 0 10px; font-size: 14px; font-weight: 700; color: #173642; }
#a11y-panel .a11y-row { display: flex; align-items: center; gap: 10px; padding: 7px 2px; cursor: pointer; }
#a11y-panel .a11y-row input { width: 16px; height: 16px; flex: 0 0 auto; }
#a11y-panel .a11y-row span { flex: 1; }
#a11y-panel .a11y-size { display: flex; align-items: center; gap: 10px; padding: 7px 2px; }
#a11y-panel .a11y-size span { flex: 1; }
#a11y-panel .a11y-size button {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid #c7ccd1; background: #f4f7fb; color: #173642;
  font-size: 16px; font-weight: 700; line-height: 1; cursor: pointer;
}
#a11y-panel .a11y-size button:hover { background: #e9edf2; }
#a11y-panel .a11y-size button:focus-visible, #a11y-panel .a11y-row input:focus-visible { outline: 3px solid #dfa14f; outline-offset: 1px; }
#a11y-panel hr { border: 0; border-top: 1px solid #eceef0; margin: 6px 0; }

@media (max-width: 480px) {
  #a11y-toggle { right: 10px; bottom: 10px; }
  #a11y-panel { right: 10px; bottom: 64px; }
}
