/* button-order-1 (DESIGN.md BUTTON ORDER, Nov 20 2026 ~06:4x and his word "im used to buttons right just"; Apple HIG Alerts/Buttons): the one shared action row
   (IsActionRow.vue; Razor: .ism-action-row[data-ism-action-row] with runtime/action-row.js). The ORDER is set in the DOM by the component/runtime (main action last
   side by side, first when stacked), never here: no `order`, no row-reverse or column-reverse, so the screen, Tab and VoiceOver orders match. This file only lays
   the row out: right-aligned (trailing) by default, data-align="start" for a left toolbar, full-width stack only when the component found the buttons do not fit.
   No page rule may reorder the row's children (tests/button-order-1.test.js). */
/* Unlayered, with no !important (Giles: no new !important): the :not(#ism-ar*) part only lifts specificity (3 ids) above the page rules that style the same
   containers (e.g. html body:not(#ism-ap1):not(#ism-ap2) .ism-ap-bar, button-standard sizes with one id), so the row's own layout always wins. */
.ism-action-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; min-width: 0; }
.ism-action-row[data-align="start"] { justify-content: flex-start; }
/* Stacked (did not fit side by side): the main action first, full width on top; the others share the lines below, each growing to fill (icon-only ones keep their size). */
html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-action-row[data-stacked] { display: flex; flex-direction: row; flex-wrap: wrap; align-items: stretch; justify-content: flex-start; width: 100%; flex: 1 1 100%; align-self: stretch; grid-column: 1 / -1; }
html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-action-row[data-stacked] > * { flex: 1 1 auto; min-width: 0; max-width: none; margin: 0; }
html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-action-row[data-stacked] > :first-child { flex: 1 1 100%; }
html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-action-row[data-stacked] > [data-ism-compact]:not(:first-child) { flex: 0 0 auto; }
html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-action-row[data-stacked] > :is(.ism-button, .ism-button-bare, a, button) { justify-content: center; }

/* button-order-1b (his word Nov 20 on a load-error notice: "we put buttons right just now"): buttons inside notices sit at the trailing edge (right), single or pair. Unlayered, and one step more specific than notices.css / controls-lib-1.css, so it wins over their unlayered rules.
   - IsNoticeBar: the action (and the X after it) is pushed to the trailing edge even when the notice is narrower than its text would make it; a button under
     the text (slot "below") is right-aligned.
   Whole-page empty and error states (IsLoadError, e.g. Documents "did not load") are NOT rows: they stay centred, text and lone button (Apple ContentUnavailableView). */
html body .ism-notice-bar > .ism-notice-text + :is(.ism-notice-action, .ism-notice-dismiss) { margin-inline-start: auto; }
html body .ism-notice-bar.ism-notice-stack .ism-notice-below { justify-content: flex-end; }

/* astra-fix-buttons-3 (Astra review #8, his tap Nov 20 "Fix all, show after", approvals.md 4042; DESIGN.md line 74, his tap Nov 20 ~12:0x "B: Right / full width (Recommended)"):
   a LONE main button is full width on a phone and sits at the trailing (right) edge on desktop, everywhere, set once here for the three shared action containers:
   - IsActionRow (Vue) and its Razor form .ism-action-row[data-ism-action-row]: the row is already right-aligned; on a phone its only button fills the row.
   - .account-actions (the shared legacy form action row, style-b-legacy.css: Profile "Save Profile" / "Save Preferences", Hospital Settings): same.
   - the sign-in family's lone submit (IsButton size="signin", primary, the only button in its form block: Register, Send Link, Set Password ...): full width on a phone,
     trailing at its natural width from 768 px. The sign-in page's stack of sign-in choices is several buttons, not a lone one, and keeps its stack.
   - IsDialogFooter (.ism-ctl-footer: Build Notes, Daily Staffing, Shifts, Checkpoints, Calendar Link ...; fixlane-1120n, design gate Nov 20: Build Notes' lone Add Notes was 108 px at 390): same.
   Unlayered, no important flag: the :not(#ism-ar*) ids lift it over the page rules that size these buttons (account.css 24ch, login.css width 100%). */
@media (max-width: 767px) {
  html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) :is(.ism-action-row:not([data-align="start"]):not([data-stack="never"]), .account-actions, .ism-ctl-footer) > :is(.ism-button, .p-button, .btn, button, a.ism-button):only-child { flex: 1 1 100%; width: 100%; max-width: none; margin-inline: 0; justify-content: center; }
}
@media (min-width: 768px) {
  html body:not(#ism-ar1):not(#ism-ar2):not(#ism-ar3) .ism-login-card :is(form, .ism-login-fields) > .ism-button[data-size="signin"][data-variant="primary"][type="submit"]:only-of-type:not(#ism-ar4) { display: flex; width: auto; max-width: 100%; margin-inline-start: auto; margin-inline-end: 0; justify-self: end; align-self: flex-end; justify-content: center; }
}
