/* Cookie consent banner.
 *
 * A CLASS, not inline styles, for two reasons that are the same reason: the
 * gui palette paints registered surfaces with explicit `!important` rules
 * (apps/gui/services.generate_color_css never redefines --bs-body-bg), and an
 * inline style beats every one of them. The banner shipped inline and stayed
 * theme-default white under a custom palette — the same bug the harness
 * progress toast had.
 *
 * .consent-banner is registered in generate_color_css beside .card, so it
 * rides the CARD surface: it is a raised sheet over the page, not the page.
 */
.consent-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  /* Above the app's own banners and the offcanvas menu, below SweetAlert
     (1060+ in this theme) so a modal opened from it is still reachable. */
  z-index: 1091;
  background: var(--bs-card-bg, var(--bs-body-bg));
  color: var(--bs-body-color);
  border-top: 1px solid var(--bs-border-color);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, .22);
  /* Respect the notch/home indicator on phones — a consent bar that sits
     under the iOS gesture area cannot be dismissed with one thumb. */
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.consent-banner .consent-actions { flex-shrink: 0; }
/* Under ~576px the three buttons need the full width or they wrap into a
   ragged stack that pushes the text off-screen. */
@media (max-width: 575.98px) {
  .consent-banner .consent-actions { width: 100%; }
  .consent-banner .consent-actions .btn { flex: 1 1 auto; }
}
/* Keyboard users land here first on an unanswered page; make that visible. */
.consent-banner .btn:focus-visible {
  outline: 2px solid var(--bs-primary);
  outline-offset: 2px;
}
