/* TAG Legal Desk: Fred's alarm banner (register J72 Part B2 and J325, js/alarm.js). A full width red band at the top
   of every screen, under the restart countdown when both show. Colours are the theme's own: the danger token for the
   ground and the solid token for the words (light themes: white on #B3261E; dark themes: near black on #FF8A80; High
   contrast: white on #9A0000; at least 6 to 1 in every desk theme). */
:root { --al-h: 0px; }
.al-bar {
  position: fixed; left: 0; right: 0; top: var(--rs-h, 0px); z-index: 2147482000;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 20px 10px 20px;
  background: var(--danger); color: var(--solid);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
}
body.rs-on-count .al-bar { padding-top: 10px; }
.al-in { display: flex; align-items: center; gap: 12px 16px; max-width: 1160px; margin: 0 auto; flex-wrap: wrap; }
.al-lines { flex: 1 1 320px; min-width: 0; }
.al-line { margin: 0; font-size: 1.0625rem; font-weight: 800; line-height: 1.35; overflow-wrap: anywhere; }
.al-line + .al-line { margin-top: 4px; }
.al-note { margin: 4px 0 0; font-size: .9375rem; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.al-hide {
  flex: none; font: inherit; font-size: .875rem; font-weight: 700; min-height: 36px; padding: 6px 14px;
  border: 2px solid currentColor; border-radius: 999px; background: transparent; color: inherit; cursor: pointer;
}
.al-hide:hover { background: color-mix(in srgb, currentColor 14%, transparent); }
.al-hide:focus-visible { outline: 3px solid currentColor; outline-offset: 2px; }
@media (forced-colors: active) { .al-bar { border-bottom: 3px solid CanvasText; } }

/* While the band shows, the whole page moves down by its height (--al-h, measured by js/alarm.js), as the restart
   countdown moves it by --rs-h, so the header, the practice band, every job panel, the welfare views, side sheets, the
   sideboard and Back to the board stay in sight and pressable. With the countdown up too, both heights add (this file
   loads after styles/v21_restart.css, so these rules win where both apply). */
body.al-on { padding-top: calc(var(--rs-h, 0px) + var(--al-h)); --top: calc(var(--hdr-h) + var(--band-h) + var(--rs-h, 0px) + var(--al-h)); }
body.al-on .hdr { top: calc(var(--rs-h, 0px) + var(--al-h)); }
body.al-on .pband { top: calc(var(--hdr-h) + var(--rs-h, 0px) + var(--al-h)); }
body.al-on .sheet { top: calc(var(--rs-h, 0px) + var(--al-h)); }
body.al-on .wf-over-cover { top: calc(16px + var(--rs-h, 0px) + var(--al-h)); }
body.al-on .v21pl-panel { top: calc(12px + var(--rs-h, 0px) + var(--al-h)); }
body.al-on .v21sb-dock { top: calc(96px + var(--rs-h, 0px) + var(--al-h)); max-height: calc(100vh - 116px - var(--rs-h, 0px) - var(--al-h)); max-height: calc(100dvh - 116px - var(--rs-h, 0px) - var(--al-h)); }

@media (max-width: 600px) {
  .al-bar { padding-left: 16px; padding-right: 16px; }
  .al-line { font-size: 1rem; }
}
