/*
 * Semantic UI → daisyUI alias layer.
 *
 * The migrated apps still emit elementum-web/Fomantic class names. This file
 * maps each one onto daisy's *design language* (its variables), so the markup
 * needs no rewrite in pass 1 and Fomantic's look is gone completely.
 *
 * ⚠ THE DESIGN SYSTEM IS `ui-system.css` (loaded after this file). Every component it defines —
 * nav, page skeleton, card, table, form, empty state, message, badge, button, footer, stats, tabs
 * — has had this file's rule for it DELETED, because a rule that survives in two places is how the
 * layer became patchy. What remains here is the legacy aliasing this file exists for: the `ui *`
 * and Fomantic-shaped vocabulary, plus the page-specific corrections the other apps still need.
 * Add a component to `ui-system.css`; do not add one here.
 *
 * Rules:
 *   - no hardcoded colours; only daisy variables (--color-*, --radius-*, --border)
 *   - one control height (--control-h), one radius (--radius-field)
 *   - every `ui *` phrase the apps use is either mapped here or listed in
 *     docs/ui/semantic-to-daisy.md as intentionally unstyled
 */
/* ── Page ─────────────────────────────────────────────────────────────────── */
/* Fomantic grid → flex; `stackable` collapses below 768px like it used to. */
.column + .column{ margin-left: 0; }
/* ── Numbered columns — a column's share of the 16-unit grid ────────────────
   Only `.column.wide` (grow 2) existed, so EVERY numbered column (`eleven wide column`,
   `five wide column`) fell back to `flex: 1 1 0` and every layout rendered as equal
   halves at every width — the permission list's 11/5 split became 50/50. Widths are
   Fomantic's: n of 16. Written out because CSS cannot read the number from a class name. */
@media (max-width: 767px) {
  .only:not(.mobile){ display: none !important; }
}
@media (min-width: 768px) and (max-width: 991px) {
  .only:not(.tablet){ display: none !important; }
}
@media (min-width: 992px) {
  .only:not(.computer):not(.large):not(.widescreen){ display: none !important; }
}
/* ── Type ─────────────────────────────────────────────────────────────────── */
/* The page heading: `MigrationPage.pageHeading(...)` emits `<h1 class="eca-heading">` with an
   `__content` wrapper and an optional `__sub`. The old element names were Fomantic's
   (`div.content`, `div.sub.header`) and the block carried the legacy `ui` token.
   SIZE is not set here: `ui-system.css`'s `h1`–`h4` rules own the token ramp, so a heading's
   size cannot depend on which component emitted it. */
.eca-heading{ display: block; margin: 0 0 var(--space-3); font-weight: 650; line-height: 1.25; }
.eca-heading__content{ display: block; }
.eca-heading__sub{
  color: var(--color-base-content);
  opacity: .6;
  font-size: var(--text-sm);
  font-weight: 500;
  text-transform: none;
}
/* `headingDivider(...)` is the Fomantic `dividing header`: a rule under the title. */
.eca-heading--dividing{
  border-bottom: var(--border) solid var(--color-base-300);
  padding-bottom: var(--space-2);
}
.eca-heading--center{ text-align: center; }
/* A rule between blocks — `.eca-divider` (`SemanticUIFrags.divider`), was `ui divider`. */
.eca-divider{
  border: 0;
  border-top: var(--border) solid var(--color-base-300);
  margin: var(--space-4) 0;
  height: 0;
}
/* A divider with a label between two rules (`divider("horizontal")`). Fomantic centred the text
   with a line either side; two flex pseudo-elements do the same without extra markup. */
.eca-divider--horizontal{
  display: flex; align-items: center; gap: var(--space-3);
  border-top: 0; height: auto;
  color: color-mix(in oklab, var(--color-base-content) 65%, transparent);
  font-size: var(--text-xs); font-weight: 650; text-transform: uppercase; letter-spacing: .04em;
}
.eca-divider--horizontal::before,
.eca-divider--horizontal::after{
  content: ""; flex: 1 1 0; height: 0;
  border-top: var(--border) solid var(--color-base-300);
}
/* ── Buttons ──────────────────────────────────────────────────────────────── */
/* ── Labels / badges ──────────────────────────────────────────────────────── */
/* ── Messages (alerts) ────────────────────────────────────────────────────── */
/* ── Segments / cards ─────────────────────────────────────────────────────── */
/* A plain boxed block. `FormSupport.form(..., "inverted")` wraps its form in
   `eca-segment eca-segment--inverted` (it emitted `ui inverted segment`). */
.eca-segment{
  background: var(--color-base-100);
  border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box);
  padding: var(--pad-card);
  margin: 0 0 var(--space-4);
}
.eca-segment--inverted{ background: var(--color-base-200); }
/* ── Tables ───────────────────────────────────────────────────────────────── */
.table-wrapper, .summary-table{ overflow-x: auto; }
/* ── Forms ────────────────────────────────────────────────────────────────── */
.form-field label{
  display: block; margin: 0 0 6px;
  font-size: 13px; font-weight: 600; color: var(--color-base-content); opacity: .8;
  text-transform: none; letter-spacing: 0;
}
.form-field input:not([type=checkbox]), .form-field select, .form-field textarea{
  width: 100%; box-sizing: border-box; height: var(--size-field); min-height: var(--size-field);
  padding: 0 12px; font-family: var(--font-sans); font-size: 14px;
  color: var(--color-base-content); background: var(--color-base-100);
  border: var(--border) solid var(--color-base-300); border-radius: var(--radius-field);
  box-shadow: none; transition: border-color .12s ease, box-shadow .12s ease;
}
.form-field textarea{ height: auto; min-height: 96px; padding: 10px 12px; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus{
  outline: none; border-color: var(--color-primary);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--color-primary) 14%, transparent);
}
.form-fields{ display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin: 0 0 16px; }
/* A button sitting in a filter row aligns to the INPUT baseline, not the label. */
.form-fields > .form-field > button{ margin-bottom: 0; }
.form-fields > .form-field{ flex: 1 1 180px; margin: 0; padding: 0; }
/* Multi-select: `select multiple` keeps posting `name="x[]"`; present it as a
   deliberate list, not a raw OS listbox. */
select[multiple]{
  height: auto; min-height: 96px; padding: 6px;
  background: var(--color-base-100); border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-field);
}
select[multiple] option{ padding: 5px 8px; border-radius: 4px; }
select[multiple] option:checked{ background: color-mix(in oklab, var(--color-primary) 14%, transparent); color: var(--color-base-content); }
/* Checkbox / toggle */
/* Left/right labelled input (Fomantic pattern) */
/* ── Modal / dropdown ─────────────────────────────────────────────────────── */
/* `MenuFrags.dropdown(...)` — a menu item that opens a panel. It emitted
   `ui dropdown item` + `div.menu`; the panel is `__panel` and the caret is `__caret`.
   The panel is CLOSED by default: it used to have no `display: none`, so a dropdown inside a
   nav rendered permanently open. `menu-dropdown.js` toggles `is-open` on the trigger. */
.eca-dropdown{ position: relative; display: inline-block; }
.eca-dropdown__caret{ font-size: .8em; opacity: .7; margin-inline-start: var(--space-1); }
.eca-dropdown__panel{
  position: absolute; right: 0; top: calc(100% + 4px); z-index: 40; min-width: 200px;
  display: none;
  background: var(--color-base-100); border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-field); box-shadow: 0 10px 30px rgba(16,24,40,.12); padding: var(--space-1) 0;
}
.eca-dropdown.is-open > .eca-dropdown__panel,
.eca-dropdown:focus-within > .eca-dropdown__panel{ display: block; }
.eca-dropdown.opens-up > .eca-dropdown__panel{ top: auto; bottom: calc(100% + 4px); }
.eca-dropdown__panel > .item{
  display: block; padding: var(--space-2) var(--space-3);
  color: var(--color-base-content); font-size: var(--text-sm); text-decoration: none;
}
.eca-dropdown__panel > .item:hover{ background: var(--color-base-200); text-decoration: none; }
.eca-dropdown__panel > .eca-divider{ margin: var(--space-1) 0; }
/* ── Menu / nav ───────────────────────────────────────────────────────────── */
/* A tab strip is a *tab* control, not the site nav. Its items are `<button>`s (WCAG 2.1.1:
   the old `<a>` had no href, so the strip was keyboard-unreachable), which needs the native
   button chrome removed — the nav's `.item` rule cannot supply that for the `button` element. */
/* The nav collapses to a hamburger below 900px (see the responsive-menu block); a tab strip
   must NOT — it keeps its items and pans, exactly like `.eca-tabs`. Measured 2026-11-06 on
   elementum-simple's /search at 390: every tab was `display:none` behind a stray hamburger,
   so Users was the only reachable panel. */
.tab.segment[hidden]{ display: none !important; }
/* Multi-select as a checkbox disclosure (see ClaimUI.multiselect). Posts the same
   `name[]` array; <details> gives click-open + outside/Esc close with no JS. */
.eca-multiselect{ position: relative; display: inline-block; }
.eca-multiselect > summary{
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
  height: var(--size-field); padding: 0 12px; white-space: nowrap;
  border: var(--border) solid var(--color-base-300); border-radius: var(--radius-field);
  background: var(--color-base-100); color: var(--color-base-content);
  font-size: 13px; font-weight: 600;
}
.eca-multiselect > summary::-webkit-details-marker{ display: none; }
.eca-multiselect[open] > summary{ border-color: var(--color-primary); }
.eca-multiselect__count{ opacity: .6; font-weight: 500; }
.eca-multiselect__row:hover{ background: var(--color-base-200); }
.eca-multiselect__row input[type=checkbox]{ accent-color: var(--color-primary); margin: 0; }
/* ── Page canvas fills the viewport ─────────────────────────────────────────
   The canvas stopped where the content ended, leaving a white band below — the
   page looked half-baked on short pages. */
html{ background: var(--color-base-200); }
body{ min-height: 100vh; margin: 0; }
/* ── Inline filter rows: one line, laid out with GRID ──────────────────────
   A grid row places From/To/Search in cells, so their boxes align by the row's
   `align-items: end` — no flex baseline arithmetic, no margin collapse, no
   floating button. Each field is itself a 2-column grid: [label][control]. */
.inline.fields{
  display: grid;
  grid-auto-flow: column;
  justify-content: start;
  align-items: end;
  gap: 16px;
}
.inline.fields > .field{
  display: grid;
  grid-template-columns: auto minmax(150px, 180px);
  /* END, not centre: the field cell is taller than the control (label row), and
     centring left ~15px of empty space below the input, which pushed the Search
     button 13px low once the row aligned to the cell bottom. */
  align-items: end;
  gap: 8px;
  margin: 0;
}
/* The button's wrapper is a taller cell than the inputs, which is what kept it
   off-baseline. `display: contents` removes the wrapper from the box tree so the
   button itself becomes a direct grid item — one line, exact alignment. */
/* Position-independent: the button field may not be the last child (hidden
   inputs follow it), so match by CONTENT. */
.inline.fields > .field > label{ margin: 0; white-space: nowrap; font-size: 13px; font-weight: 600; opacity: .8; }
.inline.fields > .field > input,
.inline.fields > .field > select{ width: 100%; margin: 0; }
/* ── FilterBar component ────────────────────────────────────────────────────
   One grid item per control: label + control in one cell, the submit a sibling
   cell. Bottom-aligned by the row; nothing nested to fight. */
/* One control per cell: the label and the control share a cell, the submit is its own cell.
   The elements are `__field`/`__label`/`__submit` — they were `ui filter-field`,
   `ui filter-label` and `ui primary button ui filter-submit`, which is how a `.ui`-free app
   still rendered five legacy tokens on its dashboard.
   The child combinator is load-bearing, not style: a field IS a `<label>`, and the form's
   `label { display: block }` rule is (0,1,1) — it out-specified `.eca-filter-bar__field` (0,1,0)
   and the field rendered as a block with the label *above* the control instead of a 2-column grid
   (measured on claim `/viewClaims/dashboard`). Two classes + a combinator is (0,2,0). */
.eca-filter-bar > .eca-filter-bar__field{ display: grid; gap: var(--space-1); margin: 0; min-width: 0; }
.eca-filter-bar > .eca-filter-bar__field--inline{ grid-auto-flow: column; align-items: center; gap: var(--space-2); }
.eca-filter-bar > .eca-filter-bar__field--stacked{ grid-auto-flow: row; }
.eca-filter-bar__label{
  font-size: var(--text-sm); font-weight: 600; opacity: .8; white-space: nowrap;
}
.eca-filter-bar__field > input,
.eca-filter-bar__field > select{ width: 180px; margin: 0; }
.eca-filter-bar__submit{ margin: 0; }
/* ── Template module vocabulary (it never used `ui *`) ──────────────────────
   `template-class-menu`, `form`, `form-field`, `form-label`, `form-actions`,
   `button`, `button-primary`, `notification`. Unstyled until now, which is why
   the template page read as loose text on a grey field. */
.template-page{ display: block; }
/* The real split lives in .template-layout (menu + editor), not .template-page. */
.template-layout{ display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 28px; align-items: start; }
.template-content{ min-width: 0; }
.template-content input[type=text], .template-content textarea{ width: 100%; }
.template-class-menu{ display: flex; flex-direction: column; gap: 2px; margin: 0 0 20px; }
.template-class-menu > *{ display: flex; justify-content: space-between; align-items: center;
  padding: 9px 12px; border-radius: var(--radius-field); color: var(--color-base-content);
  font-size: 14px; font-weight: 550; text-decoration: none; }
.template-class-menu > *:hover{ background: var(--color-base-200); text-decoration: none; }
.template-class-menu > .active, .template-class-menu > [aria-current]{
  background: color-mix(in oklab, var(--color-primary) 12%, transparent); color: var(--color-primary); }
.template-class-menu .count{ opacity: .6; font-weight: 500; }
.notification{ margin: 0 0 16px; padding: 12px 16px; border-radius: var(--radius-box);
  border: var(--border) solid var(--color-base-300); font-size: 14px; }
.notification-error{ background: color-mix(in oklab, var(--color-error) 8%, var(--color-base-100));
  border-color: color-mix(in oklab, var(--color-error) 32%, var(--color-base-300)); color: var(--color-error); }
.notification-success{ background: color-mix(in oklab, var(--color-success) 8%, var(--color-base-100));
  border-color: color-mix(in oklab, var(--color-success) 32%, var(--color-base-300)); }
.notification-warning{ background: color-mix(in oklab, var(--color-warning) 10%, var(--color-base-100));
  border-color: color-mix(in oklab, var(--color-warning) 34%, var(--color-base-300)); }
.notification-info{ background: color-mix(in oklab, var(--color-info) 8%, var(--color-base-100));
  border-color: color-mix(in oklab, var(--color-info) 30%, var(--color-base-300)); }
.form-field .field-error, .field-error{ font-size: 13px; color: var(--color-error); }
.form{ display: grid; gap: 16px; margin: 0 0 20px; }
.form-label{ font-size: 13px; font-weight: 600; opacity: .8; }
.form-actions{ display: flex; gap: 10px; align-items: center; margin-top: 4px; }
.button{ display: inline-flex; align-items: center; justify-content: center; height: var(--size-field);
  padding: 0 16px; border-radius: var(--radius-field); border: var(--border) solid var(--color-base-300);
  background: var(--color-base-100); color: var(--color-base-content); font-size: 14px; font-weight: 600;
  cursor: pointer; }
.button:hover{ background: var(--color-base-200); }
.button-primary{ background: var(--color-primary); border-color: var(--color-primary); color: var(--color-primary-content); }
.button-primary:hover{ background: var(--color-accent); border-color: var(--color-accent); }
/* ── Report pages: wide tables, sticky head, real empty state ─────────────── */
.no-data-text{ display: block; padding: 40px 0; text-align: center; font-size: 15px;
  color: var(--color-base-content); opacity: .6; }
/* ── Report page: one filter card, one results card ───────────────────────── */
.report-filters{ padding: 20px 22px; }
.report-filters .eca-filter-bar{ margin: 0 0 16px; gap: 28px; }
.report-filters .eca-filter-bar:last-of-type{ margin-bottom: 4px; }
.report-actions{ display: flex; gap: 10px; align-items: center; margin-top: 8px;
  padding-top: 16px; border-top: var(--border) solid var(--color-base-300); }
.report-results{ margin-top: 20px; }
.no-data-block{ padding: 56px 24px; text-align: center;
  background: var(--color-base-100); border: var(--border) dashed var(--color-base-300);
  border-radius: var(--radius-box); }
.no-data-title{ margin: 0 0 6px; font-size: 16px; font-weight: 650; }
.no-data-hint{ margin: 0; font-size: 14px; opacity: .6; }
/* Segmented selector (template classes / supertypes). */
.template-supertype-menu{ display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 18px; }
.template-supertype-menu a, .template-class-menu a{
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px;
  border: var(--border) solid var(--color-base-300); border-radius: var(--radius-field);
  background: var(--color-base-100); color: var(--color-base-content);
  font-size: 13px; font-weight: 550; text-decoration: none; }
.template-supertype-menu a:hover, .template-class-menu a:hover{ background: var(--color-base-200); }
.template-supertype-menu a.active, .template-class-menu a.active{
  /* Selection must NOT change metrics: same weight/padding, colour only — a
     bolder label widened the tab and shifted the page content. */
  background: color-mix(in oklab, var(--color-primary) 12%, transparent);
  border-color: color-mix(in oklab, var(--color-primary) 35%, var(--color-base-300));
  color: var(--color-primary);
  box-shadow: inset 0 -2px 0 0 var(--color-primary); }
.template-list{ display: flex; flex-direction: column; gap: 2px; }
.template-list a.active{ background: color-mix(in oklab, var(--color-primary) 12%, transparent); color: var(--color-primary); }
.template-variables{ margin-top: 24px; }
/* An empty state that renders the ONLY content of a card collapses the card: a bordered box
   around a bordered dashed box is two frames for one sentence (measured on `/milestones` and
   `/tickets`, 2026-11-08). The section drops its own frame and keeps its title. */
/* Reserve the scrollbar gutter ALWAYS. Without it, a tab whose content is shorter
   loses the scrollbar, the viewport widens, and every element shifts horizontally
   (observed switching ClaimSystem -> DNC on the template page). */
html{ scrollbar-gutter: stable; overflow-y: scroll; }
/* ── Radio / checkbox groups ───────────────────────────────────────────────────
   The legacy markup is `<div class="form-field"><label>Question</label>
   <label class="radio-option"><input type=radio><span>Yes</span></label>…`.
   `.form-field label {display:block}` used to make every option a block, so the
   circles sat in the middle of the page with their text far above — the broken
   "Require Half Day Leave?" panel. Options are chips now. */
.form-field.inline, .form-field.require-half-day{ display: grid; gap: 8px; }
.form-field > label:first-child{ margin: 0; }
.form-field .radio-option{
  display: inline-flex; align-items: center; gap: 8px;
  margin: 0; padding: 8px 14px; width: auto;
  font-size: 14px; font-weight: 500; text-transform: none; letter-spacing: 0;
  background: var(--color-base-100); color: var(--color-base-content);
  border: var(--border) solid var(--color-base-300); border-radius: var(--radius-field);
  cursor: pointer; transition: border-color .12s ease, background-color .12s ease;
}
.form-field .radio-option + .radio-option{ margin-left: 0; }
.form-field .radio-option:hover{ background: var(--color-base-200); }
/* The option's INNER layout is a span, not the <label>: `legacy label{display:block}`
   wins for the label itself, so relying on the label's display leaves the circle on top
   of its text (measured: span started at input+16px, no gap). */
.radio-option__inner{ display: inline-flex; align-items: center; gap: 8px; }
.form-field .radio-option input{
  width: 16px; height: 16px; min-height: 0; margin: 0; padding: 0;
  accent-color: var(--color-primary); box-shadow: none; border-radius: 50%;
}
.form-field .radio-option:has(input:checked){
  border-color: var(--color-primary);
  background: color-mix(in oklab, var(--color-primary) 10%, var(--color-base-100));
  font-weight: 600;
}
/* A row of option chips needs to wrap as a row, never as a column of blocks. */
.form-field:has(> .radio-option){ display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.form-field:has(> .radio-option) > label:first-child{ flex: 0 0 100%; }
/* ── File input ────────────────────────────────────────────────────────────── */
.form-field input[type=file]{
  width: 100%; box-sizing: border-box; padding: 8px 12px; height: auto; min-height: var(--size-field);
  font-size: 13px; color: var(--color-base-content);
  background: var(--color-base-100); border: var(--border) dashed var(--color-base-300);
  border-radius: var(--radius-field);
}
.form-field input[type=file]::file-selector-button{
  margin-right: 12px; padding: 6px 12px; font: inherit; font-size: 13px; font-weight: 600;
  color: var(--color-base-content); background: var(--color-base-200);
  border: var(--border) solid var(--color-base-300); border-radius: var(--radius-field); cursor: pointer;
}
/* ── A single-column form: one decision per row, actions anchored under it ──── */
.form-actions-bar{
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  padding-top: 16px; border-top: var(--border) solid var(--color-base-300);
}
.form-actions-bar .spacer{ flex: 1 1 auto; }
.half-day-wrapper{ padding: 14px 16px; background: var(--color-base-200); border-radius: var(--radius-box); }
/* ── Links ─────────────────────────────────────────────────────────────────────
   Pages emit bare `<a>` (attachments, row actions, "Back"); before this rule they
   rendered as the browser default and read as unstyled text.

   The rule must not reach a **component**. `.eca-profile__act--primary` is an `<a>`
   too, and this colour beat its own `color: #fff`, painting rgb(15,107,92) on
   rgb(15,107,92) — contrast **1:1**, an invisible primary action (WCAG 1.4.3, measured
   on leave-system 2026-11-07). Naming exclusions one at a time is what caused it: a new
   component stays invisible to this rule until someone remembers to add it. So **any**
   `eca-*` class excludes the anchor — a component states its own colour, and
   `ProfileCssContractSuite` fails when an `.eca-*` anchor does not. */
.eaw-page a:not([class*="eca-"]):not(.button):not(.item){
  color: var(--color-primary); text-decoration: none; font-weight: 550;
}
.eaw-page a:not([class*="eca-"]):not(.button):not(.item):hover{ text-decoration: underline; }
.eaw-page a:not([class*="eca-"]):not(.button):not(.item):focus-visible{
  outline: 2px solid var(--color-primary); outline-offset: 2px; border-radius: 3px;
}
/* ── Key/value meta grid (a request's fields, an entity's summary) ───────────── */
/* ── Duplicate "mobile card" renderings ────────────────────────────────────────
   Six pages render every record twice: a desktop table and a mobile card list.
   The card CSS was never migrated, so BOTH showed at every width (21 duplicate
   cards on the drafts page). Cards are the small-screen rendering only. */
.leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards,
.tiers-mobile-cards, .leave-card{ display: none; }
@media (max-width: 768px) {
  .leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards,
  .tiers-mobile-cards{ display: block; }
}
/* ── A section card must not push the page sideways ──────────────────────────
   Three pages overflowed horizontally at 1440 because a wide table sat inside a
   card with no scroll container. */
/* ── Bare `<table class="table">` renders as a real table ─────────────────────
   Pages emit the legacy bare class; it had borders and nothing else, so it read
   as plain text rows next to a styled table on other pages. */
.eaw-page > *{ min-width: 0; }
/* NEVER put overflow on a card that can host a popover: the multiselect panel is
   absolutely positioned and was clipped by the boxed section on the Reports page.
   Wide content shrinks/wraps instead; a table that must scroll gets `.table-scroll`. */
.eca-section, .leave-content, .eca-filter-bar{ overflow: visible; }
.table-scroll{ overflow-x: auto; }
/* ── Statistics + cards ───────────────────────────────────────────────────────
   Both classes were used by 6 leave pages and had NO styling: numbers and labels
   rendered as bare stacked text ("6 / Total Leave Types"), so a summary row read
   as a rendering failure. */
/* ── Icon messages / plain messages: one look, no Fomantic chrome ───────────── */
/* ── Activity feed (leave history) ──────────────────────────────────────────── */
/* ── Tab strip ─────────────────────────────────────────────────────────────────
   The dashboards emit `<div class="claim-tabs"><nav class="tabs"><a class="draft">…`.
   That had NO styling at all (the only rule lived in a module stylesheet that was
   removed as a design-system override), so six status links rendered as one long
   line of text. A tab is a chip; the active tab changes colour only — never metrics
   (a bolder label widened itself and shifted the page, X76). */
.claim-tabs{ margin: 0 0 18px; }
.claim-tabs .tabs{
  display: flex; flex-wrap: wrap; gap: 6px;
  margin: 0 0 4px; padding: 0;
  border-bottom: var(--border) solid var(--color-base-300);
}
.claim-tabs .tabs > a{
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; margin-bottom: -1px;
  font-size: 13px; font-weight: 550; line-height: 1.2; text-decoration: none;
  color: var(--color-base-content); background: transparent;
  border: var(--border) solid transparent; border-bottom: 0;
  border-radius: var(--radius-field) var(--radius-field) 0 0;
  white-space: nowrap;
}
.claim-tabs .tabs > a:hover{
  background: var(--color-base-200); text-decoration: none;
}
.claim-tabs .tabs > a.active{
  /* selection = paint, not measure */
  color: var(--color-primary);
  background: color-mix(in oklab, var(--color-primary) 10%, var(--color-base-100));
  border-color: var(--color-base-300);
  box-shadow: inset 0 -2px 0 0 var(--color-primary);
}
.tab-content{ padding: 4px 0 0; }
/* ── Multi-select disclosure: never a tall listbox ───────────────────────────── */
.eca-multiselect{ position: relative; display: inline-block; }
.eca-multiselect > summary{ list-style: none; cursor: pointer; }
.eca-multiselect > summary::-webkit-details-marker{ display: none; }
.eca-multiselect__row:hover{ background: var(--color-base-200); }
.eca-multiselect__row input{ width: 15px; height: 15px; margin: 0; accent-color: var(--color-primary); }
.eca-multiselect__caret{ opacity: .5; font-size: 10px; }
/* A raw multiple select should never appear: keep a sane box if one slips through. */
select[multiple]{ height: 38px; min-height: 38px; overflow-y: auto; }
/* Spacing and type are a HARMONIC scale, not an arithmetic one.
   Fibonacci (≈ φ per step) for space: 4 8 13 21 34 55 89.
   Golden-ratio type ramp from a 16px base: 16 × φ ≈ 26, ÷ φ ≈ 10 → 13/16/21/26/34/42.
   Rationale: adjacent steps stay distinguishable (8→13 is +63%, 13→21 is +62%) while
   three steps are a clear hierarchy jump (8→21), which arithmetic 4/8/16 cannot give. */
:root{
  --space-1: 4px;  --space-2: 8px;  --space-3: 13px;
  --space-4: 21px; --space-5: 34px; --space-6: 55px; --space-7: 89px;
  --text-xs: 12px; --text-sm: 13px; --text-base: 16px; --text-lg: 21px;
  --text-xl: 26px; --text-2xl: 34px; --text-3xl: 42px;
  /* ── Density (0.2.14-RC1) ────────────────────────────────────────────────────────────────
     This layer is used by operations tools that are open all day, and it was spaced like a
     marketing page: a card paid 21px on every side, a page header pushed 34px before the first
     block, and a table row measured **59px** on `/spaces` — twelve rows in a 900px viewport.
     A dense tool earns its value from rows per screen, so the block rhythm tightens by one step
     of the same scale (no new numbers): card padding 21→16, header→block 34→21, table row
     59→~44. The scale itself is unchanged, so the type ramp and the spacing steps still relate.
     `--pad-card`/`--gap-section` keep their names because every page already reads them. */
  --pad-card: 16px;                /* was var(--space-4) = 21px; measured dense target */
  --gap-inline: var(--space-3);    /* 13px between inline controls */
  --gap-block: var(--space-3);     /* 13px between blocks (was 21) */
  --gap-section: var(--space-4);   /* 21px after a page header (was 34) */
  /* The row height a dense table aims at: 8px cell padding + a 24px action target + 1px border. */
  --row-dense: 40px;
}
/* Vertical rhythm between page-level blocks (header → tabs → toolbar → content). */
.eaw-page > * + *{ margin-top: var(--gap-block); }
.tab-content + *{ margin-top: var(--space-4); }
.leave-content, .tab-content{ display: flow-root; }
.leave-content > * + *{ margin-top: var(--space-4); }
/* Neighbouring cards need air between them — but a TAB PANEL's siblings are the other panels,
   which are `hidden`; the margin still applied across them, so every panel but the first sat
   16px low and the strip lost its seal (measured on the directory page, 2026-11-06). */
.eca-section + .eca-section,
.eca-section + .eca-empty{ margin-top: var(--space-4); }
/* Forms: label → control, control → next row, and the action row's divider. */
.report-filters .report-actions{ margin-top: var(--space-4); padding-top: var(--space-4); }
.form-fields{ gap: var(--space-4) var(--space-5); margin-bottom: 0; }
.form-actions-bar{ margin-top: var(--space-5); }
/* Tables: readable cell padding, consistent with the card's own padding. */
/* A row action button sits centred and never stretches its cell. */
/* Filter rows read as one line of related controls: they must sit at a consistent
   gutter, not spread to the page edges (labels ended up 100px apart with 80px
   controls). Content-sized cells + one gap keeps the rhythm. */
.eca-multiselect > summary{ min-width: 112px; justify-content: space-between; }
/* ── Statistic colour modifiers ────────────────────────────────────────────────
   The legacy markup bakes Fomantic colour names into the class (`ui three statistics`
   with `statistic green` / `statistic orange`). Map those names onto our tokens so the
   page keeps working without a markup rewrite — and so a "not configured" count reads
   as a warning, not as a random colour. `.number` (count) modifiers are layout only. */
/* The markup was `<div class="<legacy> three statistics"><div class="statistic green">` — the
   child never carried the legacy token, so the parent-scoped colour rules never matched and the
   modifiers fell through to inherited text. Match the child by its own class. */
.statistic.green > .value, .statistic.positive > .value{ color: var(--color-success); }
.statistic.orange > .value, .statistic.warning > .value{ color: var(--color-warning); }
.statistic.red > .value, .statistic.negative > .value{ color: var(--color-error); }
.statistic.blue > .value, .statistic.info > .value{ color: var(--color-info); }
.statistic.green{ border-color: color-mix(in oklab, var(--color-success) 35%, var(--color-base-300)); }
.statistic.orange{ border-color: color-mix(in oklab, var(--color-warning) 40%, var(--color-base-300)); }
.statistic.red{ border-color: color-mix(in oklab, var(--color-error) 35%, var(--color-base-300)); }
.statistic.blue{ border-color: color-mix(in oklab, var(--color-info) 35%, var(--color-base-300)); }
/* ── Module-owned page vocabulary (calendar / public holidays) ─────────────────
   `event-ext-calendar-web-module` emits its own class names — `calendar-page`,
   `page-header`, `page-title`, `page-subtitle`, `year-menu`, `year-link`,
   `calendar-table-section`, `section-title` — none of which existed in the compat
   layer, so that page rendered as unstyled text next to styled pages. Aliased onto
   the same tokens/components as `PageLayout` and `.eca-tabs`, so the module can keep
   its markup for now and the pages look like the rest of the app. */
.calendar-page, .leave-page{ display: flow-root; }
.calendar-page > * + *, .leave-page > * + *{ margin-top: var(--space-4); }
.page-header{
  display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-4);
  flex-wrap: wrap; padding-bottom: var(--space-3);
  border-bottom: var(--border) solid var(--color-base-300); margin: 0;
}
.page-title{ margin: 0; font-size: 22px; font-weight: 700; line-height: 1.25; }
.page-subtitle{ margin: var(--space-1) 0 0; font-size: 14px; opacity: .65; }
.section-title, .calendar-table-section > h2{ margin: 0 0 var(--space-3); font-size: 15px; font-weight: 650; }
.calendar-table-section{ margin: 0; }
/* `.year-menu` is a tab strip of years, not a list of links. */
.year-menu{
  display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2) var(--space-4);
  padding-bottom: 0; border-bottom: var(--border) solid var(--color-base-300);
}
.year-menu-label{ font-size: 12px; font-weight: 650; text-transform: uppercase;
  letter-spacing: .04em; opacity: .55; }
.year-link{
  display: inline-flex; align-items: center; padding: var(--space-2) var(--space-3);
  margin-bottom: -1px; font-size: 13px; font-weight: 550; text-decoration: none;
  color: var(--color-base-content); border: var(--border) solid transparent; border-bottom: 0;
  border-radius: var(--radius-field) var(--radius-field) 0 0;
}
.year-link:hover{ background: var(--color-base-200); text-decoration: none; }
.year-link.active{
  color: var(--color-primary);
  background: color-mix(in oklab, var(--color-primary) 10%, var(--color-base-100));
  border-color: var(--color-base-300);
  box-shadow: inset 0 -2px 0 0 var(--color-primary);
}
/* ── One look for "three summary numbers" ──────────────────────────────────────
   The same concept was built two ways: `ui three statistics` (type config) and
   `ui three stackable cards` with inline `style` hacks and Fomantic hex colours
   (#2185d0/#21ba45/#f2711c) on the entitlements page. Pages now emit the statistic
   component; these rules make any surviving legacy card read identically instead of
   looking like a different product. Inline styles are why `!important` is needed. */
/* A card's numeric header carries a legacy hex colour inline — neutralise the hexes
   used by the migrated pages so they resolve to tokens, not to Fomantic's palette. */
@media (max-width: 640px) {
  /* Touch targets: the 390 contract is 44x44 for every control, including the menu
     toggle, filter selects and the first-tab stop. */
  /* The page gutter shrinks before the content does. This rule named `.ui.container.eaw-page`,
     which no page has emitted since the fleet moved to `.eca-container eaw-page` — it was a dead
     rule that looked alive (it sat in a media block, so it never showed up in a desktop diff). */
  .report-actions{ flex-wrap: wrap; }
}
/* A popover must never be clipped nor hidden behind the next card. */
.eca-multiselect{ position: relative; z-index: 40; }
/* Harmonic rhythm for the remaining containers (Fibonacci steps, not ad hoc px). */
.form-actions-bar{ margin-top: var(--space-4); padding-top: var(--space-3); }
.report-actions{ margin-top: var(--space-3); padding-top: var(--space-3); }
/* `--space-6` (55px) here overrode the component's own 21px and produced the half-page empty box.
   The component states its padding once; this rule exists only to keep the two names in step. */
:root{
  --text-xs:   clamp(11px, 0.62rem + 0.15vw, 12px);
  --text-sm:   clamp(12px, 0.70rem + 0.20vw, 13px);
  --text-base: clamp(15px, 0.92rem + 0.20vw, 16px);
  --text-lg:   clamp(18px, 1.02rem + 0.45vw, 21px);
  --text-xl:   clamp(20px, 1.05rem + 0.75vw, 26px);
  --text-2xl:  clamp(24px, 1.10rem + 1.10vw, 34px);
  --text-3xl:  clamp(28px, 1.15rem + 1.60vw, 42px);
  --focus-ring: 0 0 0 3px color-mix(in oklab, var(--color-primary) 45%, transparent);
}
html{ font-size: 100%; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body{ font-size: var(--text-base); }
/* Every interactive element shows a focus ring — never rely on the UA default. */
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible, [tabindex]:focus-visible{
  outline: 2px solid var(--color-primary); outline-offset: 2px; box-shadow: var(--focus-ring);
}
/* ── Skip link (WCAG 2.4.1): first tab stop, visible only on focus ──────────── */
.eca-skip-link:focus{ top: var(--space-2); }
/* ── Motion discipline (§1.3): 120–240ms, and honour reduced motion ─────────── */
:root{ --motion-fast: 120ms; --motion-base: 180ms; --motion-slow: 240ms; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after{
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}
/* ── Forced colours / high contrast (§1.4): borders survive, colours do not ─── */
@media (forced-colors: active) {
  .eca-page-section, .eca-page-header, .eca-badge, .eca-stats > .eca-stats__item,
  .eca-section, .eca-page-header, .table{ border: 1px solid CanvasText; }
  .eca-skip-link{ border: 2px solid CanvasText; }
}
/* ── Print (§1.15): chrome out, prose links expanded ──────────────────────────
   `@media print` hid the page chrome by the LEGACY name only, so a page on the published
   vocabulary printed its whole navigation bar and page footer; and
   `a[href]::after` appended "(/leave/report)" to every anchor, including buttons — a printed
   sticker or receipt carried the app's route table. The chrome is hidden by its published names,
   and the URL suffix belongs to a PROSE link, never to a control. */
@media print {
  .eca-menu, .eca-page-footer, .eca-tabs, .claim-tabs, .year-menu,
  .eca-filter-bar, .report-actions, .form-actions-bar, .eca-skip-link{ display: none !important; }
  body{ background: #fff; color: #000; }
  .eca-page-section, .eca-section{ border: 1px solid #999; box-shadow: none; }
  a[href]:not(.button):not(.eca-profile__back):not([class*="eca-btn"])::after{
    content: " (" attr(href) ")"; font-size: 11px;
  }
  table{ page-break-inside: avoid; }
}
/* ── RTL readiness (§1.13): logical properties in new components ────────────── */
.eca-badge--count.eca-badge--info{ background: color-mix(in oklab, var(--color-info) 18%, var(--color-base-100)); color: color-mix(in oklab, var(--color-info) 75%, var(--color-base-content)); }
.eca-badge--count.eca-badge--success{ background: color-mix(in oklab, var(--color-success) 18%, var(--color-base-100)); color: color-mix(in oklab, var(--color-success) 75%, var(--color-base-content)); }
.eca-badge--count.eca-badge--warning{ background: color-mix(in oklab, var(--color-warning) 20%, var(--color-base-100)); color: color-mix(in oklab, var(--color-warning) 75%, var(--color-base-content)); }
.eca-badge--count.eca-badge--danger{ background: color-mix(in oklab, var(--color-error) 16%, var(--color-base-100)); color: color-mix(in oklab, var(--color-error) 75%, var(--color-base-content)); }
/* A two-digit count needs a pill, not a stretched circle. */
/* ── Popover stacking: the OPEN disclosure must beat its closed siblings ───────
   Every multiselect had `z-index: 40`, so a LATER closed control (the next filter
   row's "8 selected" trigger) painted over the earlier one's open panel — the panel
   looked "overlapped by another dropdown". Only the open one is elevated now. */
.eca-multiselect{ position: relative; z-index: 1; }
.eca-multiselect[open]{ z-index: 80; }
/* and it must never be clipped by the card it lives in */
.eca-filter-bar, .report-filters, .eca-section{ overflow: visible; }
/* Row = checkbox + label with a real gap (they were touching). */
/* The row's checkbox and label must have a real gap; `gap` on the label alone was
   not enough because the checkbox is a replaced element with default margins reset. */
/* A panel that would be cut off below opens upward instead (collision handling). */
.eca-multiselect.opens-up > .eca-multiselect__panel{
  top: auto; bottom: calc(100% + 6px);
}
/* Cell-level ✓/✗ and emphasis colours are inline hexes in legacy markup; map them to
   tokens so a table cannot show Fomantic's palette. */
.table td span[style*="#21ba45"]{ color: var(--color-success) !important; }
.table td span[style*="#1b1c1d"]{ color: var(--color-base-content) !important; }
.table td span[style*="#a333c8"]{ color: var(--color-info) !important; }
.table td span[style*="#db2828"]{ color: var(--color-error) !important; }
i.icon:empty, span.icon:empty, .icon[aria-hidden="true"]:empty{ display: none !important; }
.eca-btn > .icon:empty + *, .button > .icon:empty + *{ margin-inline-start: 0; }
/* ── Icon glyphs: the icon that CAN render is not hidden ───────────────────────
   The compat layer ships ONE icon font — Material Design Icons — and it is loaded on every
   page (560KB) while `mdIcon` was used nowhere: every `<i class="edit icon">` stayed empty
   and hidden, so an icon-only button had no visible symbol at all and nothing to name it
   (WCAG 1.4.11 + 4.1.2). `mdIcon(...)` emits `.mdi` and the legacy names the fleet still
   emits are aliased onto the same font here. A name that maps to no glyph stays hidden, so
   no page gains a phantom gap.

   Each mapped name MUST appear in the visibility selector AND in its content rule; the pair
   is written together so adding one without the other is obvious. */
i.icon.mdi:empty, i.icon[class*="mdi-"]:empty,
i.icon:is(.edit,.trash,.search,.options,.user,.users,.sitemap,.cube,.photo,.calendar,.attention,.warning,.dropdown,.times,.close,.add,.plus,.eye,.file,.address,.upload,.download,.lock,.key,.clock,.settings,.check):empty{
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  font-family: "Material Design Icons";
  font-style: normal;
  font-weight: normal;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
}
/* The legacy name → MDI codepoint (the same font the `.mdi-*` classes use). */
i.icon.edit::before{ content: "\F3EB"; }
/* mdi-pencil */
i.icon.trash::before{ content: "\F1C0"; }
/* mdi-delete */
i.icon.search::before{ content: "\F349"; }
/* mdi-magnify */
i.icon.options::before{ content: "\F1D9"; }
/* mdi-dots-vertical */
i.icon.user::before{ content: "\F004"; }
/* mdi-account */
i.icon.users::before{ content: "\F00E"; }
/* mdi-account-multiple */
i.icon.sitemap::before{ content: "\F4AA"; }
/* mdi-sitemap */
i.icon.cube::before{ content: "\F1A7"; }
/* mdi-cube-outline */
i.icon.photo::before{ content: "\F2E9"; }
/* mdi-image */
i.icon.calendar::before{ content: "\F0ED"; }
/* mdi-calendar */
i.icon.attention::before{ content: "\F026"; }
/* mdi-alert */
i.icon.warning::before{ content: "\F026"; }
/* mdi-alert */
i.icon.warning.sign::before{ content: "\F028"; }
/* mdi-alert-circle */
i.icon.dropdown::before{ content: "\F140"; }
/* mdi-chevron-down */
i.icon.times::before{ content: "\F156"; }
/* mdi-close */
i.icon.close::before{ content: "\F156"; }
/* mdi-close */
i.icon.add::before{ content: "\F415"; }
/* mdi-plus */
i.icon.plus::before{ content: "\F415"; }
/* mdi-plus */
i.icon.eye::before{ content: "\F208"; }
/* mdi-eye */
i.icon.file::before{ content: "\F224"; }
/* mdi-file-outline */
i.icon.address::before{ content: "\F006"; }
/* mdi-account-box */
i.icon.upload::before{ content: "\F552"; }
/* mdi-upload */
i.icon.download::before{ content: "\F1DA"; }
/* mdi-download */
i.icon.lock::before{ content: "\F33E"; }
/* mdi-lock */
i.icon.key::before{ content: "\F306"; }
/* mdi-key */
i.icon.clock::before{ content: "\F150"; }
/* mdi-clock */
i.icon.settings::before{ content: "\F493"; }
/* mdi-settings */
i.icon.check::before{ content: "\F12C"; }
/* mdi-check */
/* Row-action cells: buttons start at the cell's padding, consistently. */
.table td.action-btns{ text-align: start; }
/* ── Table headers wrap at WORD boundaries, never mid-word — one policy ─────────
   Three rules had accumulated here (`nowrap`, `word-break: break-word`, `overflow-wrap:
   anywhere`), each written to fix a different table, and the last one to load won. The
   visible result was a heading split like `Close / d` and `ENTITLEMEN / T`: a header is a
   LABEL, and a label that breaks mid-word reads as a rendering bug, which is exactly how
   it was reported.

   The policy, applied to the component and to the legacy markup it replaced:
     * a header wraps only at a SPACE ("Date of Payment" → two lines), never inside a word,
       and is never hyphenated;
     * a body cell may break a single unbroken token (a path, a hash) only when the token
       is wider than the cell, and hyphenates rather than chops;
     * numeric cells keep their alignment (`.number`, `.collapsing`). */
/* A single token that genuinely cannot fit (a path, a hash) opts in with `.eca-wrap`. */
.eca-wrap, .eca-code--wrap{ overflow-wrap: anywhere; word-break: break-word; }
/* An actions dropdown keeps a visible caret even though the legacy <i class="dropdown icon">
   is an empty placeholder now. */
/* Wrap at WORD boundaries, never mid-word: `overflow-wrap: anywhere` broke headers into
   "ENTITLEMEN / T" and "M ETHOD". A word that genuinely cannot fit is hyphenated, not
   chopped, and `td` breaks only when a single word exceeds the cell. */
/* `table-layout: fixed` split the width evenly, so a long single word ("Hospitalisation")
   could not fit its column and was chopped. Auto layout gives each column the width its
   content needs while the table still fills (100%) and wraps headers. */
/* ── Popovers must escape their card ───────────────────────────────────────────
   `overflow-x: auto` on a section (added for wide tables) forces the other axis to
   auto too, so the LAST row's Actions menu was clipped by the card edge. Cards that
   can contain a popover never scroll; wide content is the table's own business. */
.leave-content{ overflow: visible !important; }
/* A menu with no room below opens upward (same collision rule as the disclosures). */
/* The TABLE was the clipper: the legacy table set `overflow: hidden` (for rounded corners), so a
   menu opened from the last row was cut at the table's edge. A table never clips: its
   corners come from the card, and a popover must be able to leave it. */
/* ── Search field: full width, icon inside, no empty band ──────────────────────
   The Fomantic pattern `ui search left icon input` is an inline-block sized to its
   content, so on a phone the field sat 200px wide and right-aligned inside a 333px
   column, and the hidden `.results` list left a ~160px empty band above the table. */
/* no live dropdown: the form posts */
/* The legacy inline margin on the search form (1.5rem) must not survive as a band. */
/* One rendering per breakpoint: below 768 the card list replaces the table. */
@media (max-width: 768px) {
  #leaves-table > table{ display: none !important; }
  .leaves-mobile-cards{ display: block; }
}
/* Corrections: (a) the card CHILDREN were still hidden by the duplicate-hiding rule, so
   below 768 the table was hidden and the cards were invisible — no records at all;
   (b) the search wrapper/input kept their intrinsic 200px width. */
@media (max-width: 768px) {
  .leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards, .tiers-mobile-cards{ display: block !important; }
  .leaves-mobile-cards > .leave-card, .leave-card{ display: block !important; }
}
input.search{ width: 100% !important; box-sizing: border-box; }
/* ── Mobile record cards (the list rendering below 768px) ──────────────────────
   The markup is `.leaves-mobile-cards > .leave-card > .card-row > .label/.value` plus
   `.card-actions`. It had NO styling, so on a phone the record was a column of bare
   text ("# / 1 / Leave # / 202610004 / …") — unusable. A card is a bordered surface
   with label→value rows and a full-width action. */
@media (max-width: 768px) {
  .leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards, .tiers-mobile-cards{
    display: grid !important; gap: var(--space-3); margin: 0;
  }
  .leave-card{
    display: block !important; margin: 0; padding: var(--space-3);
    background: var(--color-base-100);
    border: var(--border) solid var(--color-base-300);
    border-radius: var(--radius-box);
  }
  .leave-card .card-row{
    display: flex; align-items: baseline; justify-content: space-between;
    gap: var(--space-3); padding: var(--space-1) 0;
  }
  .leave-card .card-row + .card-row{ border-top: var(--border) solid var(--color-base-200); }
  .leave-card .card-row > .label{
    flex: 0 0 40%; font-size: var(--text-xs); font-weight: 650;
    text-transform: uppercase; letter-spacing: .04em; opacity: .55;
  }
  .leave-card .card-row > .value{ flex: 1 1 auto; font-size: var(--text-sm); text-align: end; }
  .leave-card .card-actions{ margin-top: var(--space-3); }
  .leave-card .card-actions .button{ width: 100%; }
  /* Search: one full-width field, never a 200px box floating right. */
  .field.search-field{ width: 100% !important; margin: 0 !important; }
  input.search{ width: 100% !important; min-width: 0 !important; }
}
/* `admin.css` styles a bare `.label` as a Fomantic pill; inside a record card the label is
   a field name, not a badge — no pill, no padding. */
.leave-card .card-row > .label, .leave-card .label{
  background: transparent !important; border: 0 !important; border-radius: 0 !important;
  padding: 0 !important; color: inherit; font-size: var(--text-xs);
}
/* ── Correction: the TABLE stays on mobile ────────────────────────────────────
   The reported defect was the search field above the table, not the table itself.
   Hiding the table for a card list changed the design without being asked. The table
   stays, scrolls horizontally inside its card (no page overflow), and the card list
   stays hidden at every width. */
#leaves-table > table, .table{ display: table !important; }
.leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards, .tiers-mobile-cards,
.leave-card{ display: none !important; }
@media (max-width: 768px) {
  /* The table owns the horizontal scroll; the page never does. */
  #leaves-table, .leave-content{ overflow-x: auto; -webkit-overflow-scrolling: touch; }
  #leaves-table > table{
    display: table !important; width: 100%; min-width: 640px;   /* columns keep their widths */
  }
  #leaves-table > table th, #leaves-table > table td{ white-space: nowrap; }
  /* Search field above it: full width, the fix that was actually asked for. */
  input.search{ width: 100% !important; min-width: 0 !important; }
}
/* Table scroll box + sticky filter: the table owns both scrollbars inside the viewport,
   and the filter above it never pans with the table nor scrolls out of view. */
/* A table scrolls SIDEWAYS only. A `max-height` here turned every list into a nested scroll
   box: a 21-row server list rendered 8 rows with no scrollbar in sight, so the page looked
   complete (journey X — "a list that hides rows is a list that lies").

   Paging is deliberately NOT the answer (product decision, 2026-10-26): pagination costs a
   round-trip per page for a user who will not page, and it hides the shape of the data. A long
   list is narrowed with a filter and scrolls with the page. Do not add a pagination component. */
.table-scroll{
  overflow-x: auto; overflow-y: visible; -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-box);
  /* A scrollable table must SAY that it scrolls. macOS shows no scrollbar until you scroll, and the
     claim-item table had 431px of DATE/AMOUNT columns off-screen at 390 with nothing on screen
     saying so (measured). "Scrolling shadows", CSS-only: the two `scroll` layers are the shadows
     pinned to the BOX edges; the two `local` layers are card-coloured covers that move WITH the
     content, so a shadow only shows while content continues past that edge. The table must be
     transparent for them to show through — it paints nothing this box does not already paint.
     THE EDGE HAS TO BE A LINEAR BAND, measured: the radial layers below have their centre at the
     box middle, so their strength falls off with the box's HEIGHT. On the 40-row access-control
     matrix at 390 the right edge read `245,245,246` (1.09:1 against the surface) at one row and
     `218,218,219` (1.4:1) further down — no affordance where the reader actually is. A linear band
     is the same weight at every row, and 45% of the ink is 3.0:1 (WCAG 1.4.11's floor for a state
     cue). The radials stay as the soft falloff inside it. */
  background:
    linear-gradient(to right, var(--color-base-100) 30%, transparent) left center / 40px 100% no-repeat local,
    linear-gradient(to left, var(--color-base-100) 30%, transparent) right center / 40px 100% no-repeat local,
    linear-gradient(to right, color-mix(in oklab, var(--color-base-content) 45%, transparent), transparent) left center / 24px 100% no-repeat scroll,
    linear-gradient(to left, color-mix(in oklab, var(--color-base-content) 45%, transparent), transparent) right center / 24px 100% no-repeat scroll,
    radial-gradient(farthest-side at 0 50%, color-mix(in oklab, var(--color-base-content) 30%, transparent), transparent) left center / 22px 100% no-repeat scroll,
    radial-gradient(farthest-side at 100% 50%, color-mix(in oklab, var(--color-base-content) 30%, transparent), transparent) right center / 22px 100% no-repeat scroll,
    var(--color-base-100);
}
.table-scroll > table{ background-color: transparent; }
/* A second, keyboard-independent affordance on platforms that render classic scrollbars
   (Windows/Linux AND, once any scrollbar is styled, Chromium everywhere: styling it turns the
   overlay scrollbar into a classic one that is always on show). It was painted
   `var(--color-base-300)` (#e3e6e9) on a transparent track — 1.09:1 against white, i.e. invisible,
   which is the `access-control-matrix` finding at 390 where the only cue left was the faint shadow.
   The thumb is the ink at 45% mixed with the surface (`#969696`, ~3:1 on the track) so the grab
   area is identifiable, and the track is the sunken plane so the groove reads at all.
   NO `scrollbar-width`/`scrollbar-color` here: in Chromium either standard property makes the
   `::-webkit-scrollbar` rules inert and hands the bar back to the OS overlay scroller, which is
   invisible until dragged — measured as `offsetHeight - clientHeight = 0`. Firefox keeps its own
   native bar, which is visible by default. */
.table-scroll::-webkit-scrollbar{ height: 12px; }
.table-scroll::-webkit-scrollbar-track{ background: var(--color-base-200); border-radius: 999px; }
.table-scroll::-webkit-scrollbar-thumb{
  background: color-mix(in oklab, var(--color-base-content) 45%, var(--color-base-100));
  border-radius: 999px;
}
.table-scroll::-webkit-scrollbar-thumb:hover{ background: color-mix(in oklab, var(--color-base-content) 60%, var(--color-base-100)); }
.table-scroll > table{ margin: 0; }
#leaves-table, .leave-content{ overflow: visible !important; }
.list-filter{
  position: sticky; top: 0; z-index: 5; background: var(--color-base-100);
  padding-block: var(--space-2); margin: 0 0 var(--space-2) !important;
}
@media (max-width: 768px) {
  .table-scroll > table, #leaves-table > table{ min-width: 640px; }
}
/* A single-column form is centred in the page column: it was 720px wide and pinned to the
   left, leaving 24px of space on one side and 436px on the other (reported: "skewed to the
   left"). Balanced margins, not a left-aligned slab. */
/* On a single-column form page the title sits on the same axis as the fields, instead of
   spanning the page while the form is centred. */
.leave-content:has(.form-column) > .eca-page-header,
.eaw-page:has(.form-column) > .eca-page-header{ max-width: 720px; margin-inline: auto; }
@media (max-width: 768px) {
  .leave-content:has(.form-column) > .eca-page-header, .eaw-page:has(.form-column) > .eca-page-header{ max-width: none; }
}
/* The form pages still emit a bare `h1` (NewLeavePage), so the title must follow the same
   720px axis as the fields — otherwise the page reads as skewed left. */
.leave-content:has(.form-column) > h1,
.leave-content:has(.form-column) > .eca-page-header{ max-width: 720px; margin-inline: auto; }
@media (max-width: 768px) {
  .leave-content:has(.form-column) > h1, .leave-content:has(.form-column) > .eca-page-header{ max-width: none; margin-inline: 0; }
}
/* A three-class heading selector out-specifies the page rule and resets the margins, so the
   centred column was left-aligned. The axis is the contract here. */
.leave-content:has(.form-column) > h1,
.leave-content:has(.form-column) > .eca-page-header{ max-width: 720px !important; margin-inline: auto !important; }
:root{ --width-form: min(100%, 45rem); --width-reading: min(100%, 65ch); }
.form-column, .leave-content:has(.form-column) > h1,
.leave-content:has(.form-column) > .eca-page-header{ max-width: var(--width-form) !important; }
/* ── Mobile: filters stack full width, never right-aligned ────────────────────
   A leftover `align-items: flex-end` survived the column switch, so labels and controls hugged
   the right edge on a phone (Report page). */
@media (max-width: 768px) {
  .report-filters{ padding: var(--space-3) !important; }
}
/* ── Narrow tables must not scroll ────────────────────────────────────────────
   I forced `min-width: 640px` + `white-space: nowrap` on every table below 768px, so a
   two-column table (Leave Types: Name + Actions) got a horizontal scrollbar and its first
   column swallowed the slack. A table is 100% wide and its columns flex; only a table with
   many columns keeps a minimum so it can scroll inside its box. */
@media (max-width: 768px) {
  .table-scroll > table, #leaves-table > table{ min-width: 0 !important; width: 100% !important; }
  .table-scroll > table th, .table-scroll > table td,
  #leaves-table > table th, #leaves-table > table td{ white-space: normal !important; }
  /* 4+ columns: the table keeps readable column widths and the box scrolls sideways.
   *
   * The force is scoped to `td` ON PURPOSE, and this is the fix for a real clip: `nowrap` used to
   * cover `th` as well, with `!important`, so **no app sheet could outrank it**. `itrack6`'s header
   * "Pending User Story Acceptance" measured 104 px of a 197 px box at 768 (it needs 205) — a header
   * that cannot wrap clips its label, and the lane's only way out was to delete its own `max-width`
   * below 769. A HEADER is a label: it wraps, and the `white-space: normal !important` in the block
   * above now owns it.
   *
   * A DATA cell is a value — a status, a date, a row action — so it stays on one line and the column
   * keeps a readable width while the box scrolls, which is what this rule is for. `td[colspan]` is
   * the exception inside the exception (a note or empty state spanning the table is prose), and an
   * app whose data column is genuinely prose opts the cell out with `data-wrap` — an attribute, not
   * another app-local `!important`.
   *
   * The cell force lives in the `640px`–`768px` block BELOW, not here, and that is deliberate
   * (0.2.29). Here at `max-width: 768px` it also reached `.eca-table--cards`, and it outranked the
   * card rendering's own `white-space: normal`: this selector measures (0,4,5) — `.table-scroll`,
   * `:has()`, `:not()`, `:not()` = 4 classes over 5 type selectors — against the card block's
   * strongest `white-space: normal !important` at (0,3,5) and its `td` rule at (0,2,2). So a card's
   * `ROLE REFERENCES` label, which is the cell's `::before` and inherits the cell's wrapping, took
   * `nowrap` and clipped: measured on `oauth2-authserver-app`'s `/permissions` at 390, the label
   * needed 121.8 px in its 90.5 px track, painted to x=167.8 while the value cell started at 144.5
   * — text under the value, reading `ROLE REFEREN`. A CARD is not a table: it has no columns and no
   * sideways scroll, so the rule must not reach it at all. Scope, never specificity: raising this
   * selector another rank would fix the symptom and leave the next card rule to lose the same way. */
  .table-scroll > table:has(> thead > tr > th:nth-child(4)){ min-width: 40rem !important; }
}
/* A card owns its own layout below 640 (ui-system.css's one `max-width: 639.98px` block), so the
   data-cell `nowrap` starts where the table comes back: 640–768 is the band this rule was written
   for, and a card is never in it. */
@media (min-width: 640px) and (max-width: 768px) {
  .table-scroll > table:has(> thead > tr > th:nth-child(4)) td:not([colspan]):not([data-wrap]){ white-space: nowrap !important; }
}
/* ── Component names, not page names ───────────────────────────────────────────
   Audit of this file: 70+ rules selected a page's own hooks (`#leaves-table` 15,
   `.leave-card` 15, `.leave-content` 16, `.leaves-mobile-cards` 8, `.report-filters` 7,
   `.claim-tabs` 6). A component library must not know a page's id. The generic names below
   are the contract; the page hooks stay as aliases until the modules emit the generic ones
   (they go with the legacy vocabulary, not before).

   .list-region  – a page region that holds a filter and a table/card list
   .list-filter  – the sticky filter above a list (never inside its scroll box)
   .record-list  – the card rendering of rows below 768px
   .record-card  – one row as a card (label/value rows + actions)
   .filter-card  – a card containing filter rows + actions */
.list-region, .leave-content, #leaves-table{ position: relative; }
.list-filter{
  position: sticky; top: 0; z-index: 5; background: var(--color-base-100);
}
.record-list, .leaves-mobile-cards, .balance-mobile-cards, .config-mobile-cards, .tiers-mobile-cards{
  display: none;
}
.record-card, .leave-card{
  background: var(--color-base-100); border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box); padding: var(--space-3);
}
.filter-card, .report-filters{
  background: var(--color-base-100); border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box); padding: var(--pad-card);
}
/* ── Page note (static guidance) vs message (feedback) ────────────────────────
   Recommendation made concrete: STATIC guidance is a `.page-note` placed directly under
   the page header — one component, two tones (info / warning), always followed by the
   normal block rhythm. An `eca-message` is for transient feedback (flash, errors), not for
   explaining a screen. The type-config page used a message as a note, and the note's
   bottom edge touched the statistics below because I had zeroed message margins. */
.page-note, .note-info, .note-warning{
  background: color-mix(in oklab, var(--color-info) 7%, var(--color-base-100));
  border: var(--border) solid color-mix(in oklab, var(--color-info) 28%, var(--color-base-300));
  border-radius: var(--radius-box);
  padding: var(--space-3) var(--space-4);
  margin: 0 0 var(--space-4);
  font-size: var(--text-sm);
}
.page-note > .header, .page-note > strong{ display: block; font-weight: 650; margin-bottom: var(--space-1); }
.note-warning{
  background: color-mix(in oklab, var(--color-warning) 8%, var(--color-base-100));
  border-color: color-mix(in oklab, var(--color-warning) 30%, var(--color-base-300));
}
/* A legacy info message behaves like a note when it sits directly under the header. */
/* Whatever follows a note starts on the same rhythm. */
.page-note + *, .statistics{ margin-top: 0; }
/* ── Tab strip (§3.4): `.eca-tabs` existed in the print/RTL rules but was never styled,
      so a "tab strip" rendered as a line of plain words with no current item. ──────────── */
.eca-tabs > .item:hover,
.eca-tabs > a.item:hover{ color: var(--color-primary); }
.eca-tabs > .item.active,
.eca-tabs > a.item.active{
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
}
.eca-tabs .eca-badge--count{
  min-width: 1.5rem;
  justify-content: center;
}
/* Cell gutters are the largest cost in a 390px row: four columns spent 112px of a 333px box
   on padding, which pushed the actions column out of the table and cut the buttons in half
   (measured on the campus list: table 360px inside a 333px box). */
/* ── Public page header (§3.1): the facility's own logo, then the heading. The logo is a file
      upload, so its aspect ratio is unknown — cap the height and let the width follow. ──────── */
.public-page-header{ margin-bottom: var(--space-4); }
/* A public page is a single form column; its header must sit on the same axis as the fields,
   not at the page's left edge (the existing `:has(.form-column) > .eca-page-header` rule only
   reaches a DIRECT child, and the public header wraps its logo and heading). */
.eaw-page:has(.form-column) > .public-page-header{ max-width: var(--width-form); margin-inline: auto; }
.public-page-logo{
  display: block;
  max-height: 4.5rem;
  max-width: min(100%, 14rem);
  width: auto;
  object-fit: contain;
  margin-bottom: var(--space-3);
}
/* A table inside its scroll box must NOT clip: `overflow: hidden` on the table (used for the
   rounded corners) makes the table the sticky containing block, so `position: sticky` on the
   actions cell never pins — the cell sat at x=569 in a 333px box. The box owns the radius. */
.table-scroll > table{ overflow: visible; }
/* ── Actions stay reachable on a narrow table (§4.3): a table with six or more columns keeps a
      640px minimum and pans inside its box, which pushed the actions column — the only one a
      phone user needs — off-screen. The actions column is pinned to the right; the data pans
      underneath it, and the shadow says so. ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  .table-scroll > table > thead > tr > th.action-btns,
  .table-scroll > table > tbody > tr > td.action-btns{
    position: sticky;
    right: 0;
    z-index: 2;
    background: var(--color-base-100);
    box-shadow: -8px 0 8px -8px color-mix(in oklab, var(--color-base-content) 25%, transparent);
  }
  /* The table header was `opacity: .85`, which let the scrolled header text show through the pinned
     cell ("ACTIONS" over "REGISTERED"). The pinned header must be fully opaque. */
  .table-scroll > table > thead > tr > th.action-btns{ background: var(--color-base-200); opacity: 1; z-index: 3; }
  /* The pinned cell stacks its buttons; at 390 three buttons in a row do not fit, and a button
     label that cannot wrap ("Facilities") used to run past the cell and off the screen. */
  .table-scroll > table > tbody > tr > td.action-btns{ min-width: 0; }
  .table-scroll > table > tbody > tr > td.action-btns > .flex{ flex-direction: column; align-items: stretch; }
  .table-scroll > table > tbody > tr > td.action-btns .button,
  .table-scroll > table > tbody > tr > td.action-btns .eca-btn{
    width: 100%;
    white-space: normal;
    text-align: center;
    height: auto;
    /* Card mode is TOUCH mode: `--size-field` (38) is the dense pointer height and out-specifies the
     * shared touch contract, so three rows of table actions measured 38 px at 390 (48 findings on
     * `/roles`, 2026-11-09). */
    min-height: var(--control-h-touch);
    padding-block: var(--space-1);
  }
}
/* ═══ The `eca-*` component vocabulary (§5) ══════════════════════════════════════════════════
   The legacy prefix is removed completely (AGENTS.md class policy: it goes to zero, from markup,
   CSS and builders alike). These are the names apps emit. Where a component already existed under
   both names (`.eca-btn`/the legacy button, `.eca-tabs`, `.eca-empty`, `.eca-section`,
   `.eca-page-header`) the pair was already in the selector list; the rules below add the missing
   ones, using the same tokens and the same design —
   they are renames, not a new look. */
/* ── Table ──────────────────────────────────────────────────────────────────────────────── */
.eca-table{
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 0;
  font-size: var(--text-sm);
  background: var(--color-base-100);
  color: var(--color-base-content);
  border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box);
  overflow: hidden;
}
/* ── Table: moved to `ui-system.css` ───────────────────────────────────────────────────────────
   The table was TWO components here: `.table` (the legacy bare class) and `.eca-table` (a block
   scroll box with its own header and cell rules). The second out-specified both the first and the
   design system's single policy — `.eca-table > tbody > tr > td` is (0,2,3) — so a card-mode cell
   still took the table's padding and a hairline `border-top` between a label and its value
   (measured on the ticket detail at 390: the card read as a stack of rules). One policy, one place.
   What remains are the ELEMENT hooks pages emit that are not the component's own anatomy. */
.eca-table > tbody > tr.positive > td{ background: color-mix(in oklab, var(--color-success) 9%, transparent); }
.eca-table > tbody > tr.negative > td{ background: color-mix(in oklab, var(--color-error) 9%, transparent); }
/* A link that is a BUTTON keeps the component's own ink and weight. Without `:not(.eca-btn)` this
 * rule (0,1,1) beat `.eca-btn` (0,1,0), so a table row's "View" anchor rendered at weight 500 while
 * the "Delete" <button> beside it kept 600 — the same action pair, two weights. */
.eca-table a:not(.eca-btn){ color: var(--color-base-content); font-weight: 500; }
.eca-table a:not(.eca-btn):hover{ color: var(--color-primary); }
.eca-table td.collapsing, .eca-table th.collapsing{ width: 1%; white-space: nowrap; }
.eca-table td.action-btns{ text-align: start; }
.eca-table td.action-btns > .eca-btn{ margin: 0; }

/* ── Form controls: moved to `ui-system.css` ──────────────────────────────────────────────────
   `.eca-form input:not([type=checkbox]):not([type=radio]):not([type=file])` is specificity (0,4,1):
   it out-ranked every class-based control rule the design system states, so a control inside a form
   kept THIS file's height (`--size-field`, 38px) at 390 — below the 44px touch target — and its own
   border and radius, while the same control outside a form took the system's. Two controls, one app.
   The system styles the control itself, so a control is the same box wherever it sits.
   Still here, because they are ELEMENT hooks rather than the component's anatomy: the required
   marker, the input group, the action spacer and the row's min-width floor. */
/* The marker is painted on whatever element names the field. A text field's name is a `<label>`;
   a multiselect's is a `span.eca-label` (the disclosure is not a labelable element, so a `<label>`
   could never point at it) — without the `span` selector the ONE control whose summary states the
   selection carried no visible "required" at all, which is why its summary has to say what it says. */
.eca-form .eca-required > label::after, .eca-form label.eca-required::after,
.eca-form .eca-required > .eca-label::after{
  content: " *";
  color: var(--color-error);
}
/* One column of fields, centred, with a readable measure — the form-column shape. */
.eca-form--column{ width: 100%; max-width: var(--width-form); margin-inline: auto; }
.eca-form--rows > .eca-section + .eca-section{ margin-top: var(--space-5); }
/* A grid child defaults to `min-width: auto`, i.e. its content's intrinsic width; a <select>
   with long option text then pushed the row wider than the page (305px overflow at 390px on
   the batch-update screen). Zero the floor and let the control shrink. */
.eca-field-row > *, .eca-facts > *{ min-width: 0; }
.eca-field-row input, .eca-field-row select, .eca-field-row textarea{ max-width: 100%; }
/* Actions bar: primary first, destructive/back pushed to the far end. */
.eca-actions .spacer{ flex: 1 1 auto; }

/* A labelled input group (prefix + field on one line). */
.eca-input-group{ display: flex; align-items: stretch; width: 100%; }
.eca-input-group > .eca-label{
  display: inline-flex; align-items: center;
  padding: 0 var(--space-2);
  border: var(--border) solid var(--color-base-300);
  border-inline-end: 0;
  border-radius: var(--radius-field) 0 0 var(--radius-field);
  background: var(--color-base-200);
  font-size: var(--text-sm);
}
.eca-input-group > input{
  border-start-start-radius: 0 !important;
  border-end-start-radius: 0 !important;
}
@media (max-width: 768px) {
  .eca-form--column{ margin-inline: 0; }
}
/* ── Small labels / chips ──────────────────────────────────────────────────────────────── */
/* A field label: quiet text above the control, no box. (It used to be a chip — grey pill, border,
   radius — because the class was styled for a badge and then adopted by every form in five apps.)
   A chip is `.eca-badge`; a label is a label. */
.eca-label{
  display: block;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  color: var(--color-base-content);
  font-size: var(--text-sm);
  font-weight: 600;
  line-height: 1.3;
  margin: 0 0 var(--space-1);
}
/* `.eca-label--sm` is gone: nothing emitted it, and a small label is just a smaller font. */
/* ── Checkbox and radio groups (native controls, no plugin) ────────────────────────────── */
.eca-checkbox, .eca-radio-choice{
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  cursor: pointer;
}
/* Inside a form these are labels, and `.eca-form label { display: block }` is (0,1,1) — it beat the
   component rule (0,1,0), so the choice rendered as a block, `gap` was inert and the indicator
   touched its text (measured at 390 on `/site/media/edit`: input.right == span.left, 0px). Same
   specificity trap as the filter field; the fix is the ancestor class, not `!important`. */
.eca-form .eca-checkbox,
.eca-form .eca-radio-choice{ display: inline-flex; align-items: center; gap: var(--space-2); }
.eca-radio-group{ display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-4); }
.eca-radio-group--stacked{ flex-direction: column; }
/* A choice is a control plus its text: the input's size belongs to the component, not to the
   `.eca-form` it may or may not sit in — scoping it to the form left a bare 13px OS radio on
   every page that does not use `FormSupport.form`. */
.eca-checkbox > input[type="checkbox"], .eca-radio-choice > input[type="radio"]{
  width: 1.05rem; height: 1.05rem; margin: 0; flex: 0 0 auto; accent-color: var(--color-primary);
}
.eca-form input[type="checkbox"], .eca-form input[type="radio"]{
  width: 1.05rem; height: 1.05rem; margin: 0; accent-color: var(--color-primary);
}
/* `.eca-menu__right` is a STRUCTURAL wrapper (it owns `margin-inline-start: auto`), not a different
   kind of item — so the item rules above name its children explicitly. They did not: the sheet
   styled `.eca-menu > .item` by DIRECT CHILD and the wrapper's container only, so a `div.right.menu`
   account run inside the nav (the member's name and its three links) rendered as bare, unpadded,
   unstyled text — a class emitted with no rule for its children (X107). Two apps hit it
   independently (leave-system, nex) and both dropped the wrapper instead of reporting it. */
.eca-menu .eca-menu__right{
  margin-inline-start: auto;
  display: flex;
  align-items: center;
  gap: var(--space-1);
  border: 0;
}
@media (max-width: 900px) {
  .eca-menu .eca-menu__right{ margin-inline-start: 0; flex-direction: column; align-items: stretch; width: 100%; }
}
.eca-menu .context-label{ color: color-mix(in oklab, var(--color-base-content) 65%, transparent); }
/* A DENSE nav must still read as ONE row at desktop widths. `claim-system`'s 15-item nav wrapped at
   1440 and orphaned `Site` + `New User` *below* `eca-menu__right`, so two primary items read as if
   they belonged to the account group (measured on a fresh JVM; pre-existing behaviour — the base
   `.eca-menu` has always been `flex-wrap: wrap`). The fix is density, not information architecture:
   a tighter gap and inline padding above 1200 let the whole primary run fit one row, so the wrap
   never happens on the width it was reported at. Below 1200 the nav wraps as it always has. */
@media (min-width: 1200px) {
  .eca-menu > .item,
  .eca-menu__right > .item{ padding-inline: var(--space-2); }
}
/* A DENSE nav (≈9+ top-level items) never leaves an orphaned primary item on the account row.
   Density alone cannot guarantee it: `claim-system` needs ~1730px for its 15 items plus the account
   run, so at 1425px the wrap is unavoidable. The contract is therefore the GROUPING — the primary
   run wraps first, and `eca-menu__right` is a block of its own after it. Keyed on the nav's own
   density (`:has`), not on an app class, and only where the nav is horizontal (≥901px; below that
   the hamburger owns the layout). */
@media (min-width: 901px) {
  .eca-menu:has(> .item:nth-child(9)) > .eca-menu__right{
    flex-basis: 100%;
    justify-content: flex-end;
  }
}
/* `MenuFrags.menuHeader(...)` — a non-interactive label inside a menu. It is an element of the
   menu block, NOT another `.item` (the old markup put `item` on it so the item box did the work). */
.eca-menu > .eca-menu__header,
.eca-menu__header{
  display: inline-flex; align-items: center;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-xs); font-weight: 650; letter-spacing: .04em; text-transform: uppercase;
  opacity: .65;
}
/* `MenuFrags.menu("vertical" | "right")` — modifiers, not words appended to the class list. */
.eca-menu--vertical{ flex-direction: column; align-items: stretch; }
.eca-menu--right{ margin-inline-start: auto; }
/* ── Flash / status message ────────────────────────────────────────────────────────────── */
/* A nav group (e.g. "System Admin") is a `<details>` disclosure: its panel floats over the page
   instead of pushing the layout, and it closes on outside click via the shared disclosure script. */
.eca-menu__group[open]{ z-index: 80; }
/* A group boundary is a hairline, not a dot: the bar is read as "Create | Search | Tickets". */
.eca-menu__group.opens-up > .eca-menu__panel{
  top: auto;
  bottom: calc(100% + 6px);
}
/* ── Statistic strip: moved to `ui-system.css` ─────────────────────────────────────────────────
   The strip, its tile, its value/label and its state modifiers are one component and live in the
   design system. What was here — a `@media (min-width: 1024px)` block that forced 3 or 4 columns
   with `!important`, keyed on the tile count — is the clearest example of why this file became
   patchy: it out-ranked the base rule it was correcting, so the strip could not be laid out at any
   width without knowing how many tiles a page happened to render. The system states 2 / 3 / 6 (and
   4 for a strip of 8+) at the published breakpoints instead. */

/* ── Fact list (§3.17) ─────────────────────────────────────────────────────────
   A detail page states label/value pairs (IP addresses, created date, owner). The
   legacy pages emitted a Fomantic card per pair, which read as eight equal-weight
   buttons. A definition list is the honest shape: labels quiet, values loud, one
   column at 480px so a long value never squeezes to 3 characters. */
.eca-facts{
  display: grid;
  grid-template-columns: minmax(9rem, max-content) 1fr;
  gap: var(--space-2) var(--space-4);
  margin: 0;
}
.eca-facts dt{
  font-size: var(--text-sm);
  color: var(--color-base-content);
  opacity: 0.7;
}
.eca-facts dd{ margin: 0; overflow-wrap: anywhere; }
@media (max-width: 480px) {
  .eca-facts{ grid-template-columns: 1fr; gap: var(--space-1) 0; }
  .eca-facts dd{ margin-bottom: var(--space-2); }
}
/* ── Progress bar (§3.18) ──────────────────────────────────────────────────────
   Distributions (instances per environment, disk usage) were drawn with a div whose
   width was an inline `style` — the one thing a CSP and the no-inline-style rule both
   forbid, and invisible to a screen reader. `<progress value max>` carries the same
   information natively; only the look is ours. */
.eca-progress{
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: 0.6rem;
  border: none;
  border-radius: 999px;
  background: var(--color-base-200);
  overflow: hidden;
}
.eca-progress::-webkit-progress-bar{ background: var(--color-base-200); }
.eca-progress::-webkit-progress-value{ background: var(--color-primary); }
.eca-progress::-moz-progress-bar{ background: var(--color-primary); }
.eca-progress--success::-webkit-progress-value{ background: var(--color-success); }
.eca-progress--success::-moz-progress-bar{ background: var(--color-success); }
.eca-progress--warning::-webkit-progress-value{ background: var(--color-warning); }
.eca-progress--warning::-moz-progress-bar{ background: var(--color-warning); }
.eca-progress--danger::-webkit-progress-value{ background: var(--color-error); }
.eca-progress--danger::-moz-progress-bar{ background: var(--color-error); }
.eca-progress-row{
  display: grid;
  grid-template-columns: 6.5rem 1fr 3.5rem;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}
.eca-progress-row__label{ font-size: var(--text-sm); }
.eca-progress-row__value{ font-size: var(--text-sm); text-align: end; font-variant-numeric: tabular-nums; }
/* ── Activity list (§3.19) ─────────────────────────────────────────────────────
   "Recent activity" on a dashboard: a timestamp and one sentence per row. The legacy
   version used an icon + coloured Fomantic label per row, which read as six buttons. */
.eca-activity{ list-style: none; margin: 0; padding: 0; }
.eca-activity__row{
  display: grid;
  grid-template-columns: 11rem 1fr;
  gap: var(--space-3);
  padding: var(--space-2) 0;
  border-bottom: var(--border) solid var(--color-base-300);
}
.eca-activity__row:last-child{ border-bottom: none; }
.eca-activity__time{
  font-size: var(--text-sm);
  color: var(--color-base-content);
  opacity: 0.7;
  font-variant-numeric: tabular-nums;
}
.eca-activity__text{ overflow-wrap: anywhere; }
@media (max-width: 480px) {
  .eca-activity__row{ grid-template-columns: 1fr; gap: var(--space-1); }
}
/* ── Code / config block (§3.20) ───────────────────────────────────────────────
   Config snapshots, deployment logs and generated SQL. The legacy pages wrapped these
   in inline-styled `<pre>` blocks with hardcoded colours; one class keeps long lines
   scrollable inside the content column instead of pushing the page wide. */
.eca-code{
  display: block;
  max-width: 100%;
  overflow-x: auto;
  margin: 0 0 var(--space-3);
  padding: var(--space-3);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: var(--text-sm);
  line-height: 1.5;
  white-space: pre;
  background: var(--color-base-200);
  border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-field);
}
.eca-code--inline{ display: inline-block; margin: 0; padding: 0 0.35rem; white-space: pre-wrap; }
/* Long single lines (a config value, a stack trace, a generated SQL statement) panned
   sideways with no way to read them whole. `--wrap` keeps the indentation of a `pre` block
   but breaks the long line, so the whole value is visible without a horizontal scrollbar.
   `overflow-wrap: anywhere` breaks an unbroken token (a path, a hash) that no space can. */
.eca-code--wrap{ white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-word; overflow-x: hidden; }
/* ── Disclosure block for snapshots (§3.21) ────────────────────────────────────
   A configuration snapshot is a lot of text nobody reads until they need it: a native
   `<details>` states the version and opens in place, with no script. */
.eca-snapshot{
  border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box);
  margin-bottom: var(--space-2);
  background: var(--color-base-100);
}
.eca-snapshot__summary{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: baseline;
  padding: var(--space-3) var(--space-4);
  cursor: pointer;
}
.eca-snapshot__meta{ font-size: var(--text-sm); opacity: 0.7; }
.eca-snapshot__body{ padding: 0 var(--space-4) var(--space-3); }
.eca-snapshot__body h4{ margin: var(--space-3) 0 var(--space-1); font-size: var(--text-sm); }
/* ── Message lists (§3.22) ─────────────────────────────────────────────────────
   `.eca-message` centres its text, which is right for one sentence and wrong for the
   "needs attention" list: three problems rendered as one run-on line. A list inside a
   message keeps the reading edge and gets real bullets. */
.eca-message ul, .eca-message ol{
  text-align: start;
  margin: var(--space-2) 0 0;
  padding-inline-start: 1.25rem;
}
.eca-message li{ margin: 0 0 var(--space-1); }
.eca-message li:last-child{ margin-bottom: 0; }
/* Desktop nav rows are pointer rows too; keep the same 44px target as the mobile
   menu so the audit can state one number at both widths. */
.eca-menu > .item, .eca-menu__right > .item, .eca-menu__group > summary.item{ min-height: 44px; }
/* ── Menu disclosure marker (§3.23) ────────────────────────────────────────────
   A `<details>` summary renders the platform's own triangle, which in a horizontal nav
   reads as a stray dot after the label ("Deployments ·"). The group is discoverable by
   hover/focus and announced by the summary itself, so the marker is removed. */
.eca-menu__group > summary::marker{ content: ""; }
/* ── Form and section boxes never exceed the page column (§3.24) ───────────────
   A section that holds a wide table sized itself to the table's `min-width`, so the form
   grew to 674px inside a 390px viewport and the page scrolled sideways. The scroll box
   owns the overflow; every box above it is clamped to its container. */
.eca-form, .eca-section, .table-scroll, .eca-page-section{ min-width: 0; max-width: 100%; }
/* ── Mobile card table (§4.1) ──────────────────────────────────────────────────
   Dense tables lose the column context when they are squeezed into 390. Opt-in tables keep
   the comparison inside each card: one row per card, every cell labelled by its header. */
.eca-table--cards{ min-width: 0; }
/* The card rendering is in `ui-system.css` (base = cards, `min-width: 640px` = the table). What was
   here was a `max-width: 640px` rewrite with `.eca-table--cards > tbody > tr > td` selectors — one
   rank above the system's, so every card kept the table's cell padding and a hairline between each
   label and its value. */

/* ── Tap targets in a table (§4.1) ─────────────────────────────────────────────
   A cell link was a bare text run 15px tall: below the 24×24 pointer minimum (WCAG 2.2
   2.5.8 — the inline exception covers links *in a sentence*, not a list of rows) and hard
   to hit on a phone. Cell actions get the box they deserve. */
.eca-table td a, .eca-table td button, .eca-table td summary{
  display: inline-flex;
  align-items: center;
  min-height: 1.75rem;
  min-width: 1.75rem;
}
.eca-table td.action-btns, .eca-table td .eca-btn{ vertical-align: middle; }
/* The action cell stacks its buttons with a real gap instead of relying on a space character. */
.eca-table td > .eca-btn + .eca-btn,
.eca-table td > form + .eca-btn,
.eca-table td > .eca-btn + form,
.eca-table td > form + form{ margin-inline-start: var(--space-1); }
/* ── Menu: the current page (§4.2) ─────────────────────────────────────────────
   `.active`/`aria-current` were emitted by the app but had no rule, so "you are here" was
   announced to a screen reader and invisible to everyone else. */
.eca-menu a.item[aria-current="page"],
.eca-menu summary.item[aria-current="page"]{
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.25em;
}
.eca-menu__group.active > summary.item{ font-weight: 700; }
/* ── Links inside a message list (§4.3) ────────────────────────────────────────
   The "needs attention" rows are links a reader taps to go somewhere; at 15px tall they were
   below the 24×24 pointer minimum. The inline exception does not apply — each link is a list
   item of its own, not a word inside a sentence. */
.eca-message li a{
  display: inline-flex;
  align-items: center;
  min-height: 1.75rem;
}
/* ── Classes the pages emit, now actually styled (§3.25) ───────────────────────
   `scripts/check-ecaw-components.py` found eleven class names emitted by code with no rule
   outside the print/RTL blocks — the same failure as `.eca-statistics`: the markup says the
   component exists, the page renders without it. Either style it here or stop emitting it. */
.eca-page-heading{ display: flex; flex-direction: column; gap: var(--space-1); min-width: 0; }
/* The account block sits at the far end of the nav, whether or not the menu wraps. */
/* `.eca-input` is emitted on inputs that are not inside `.eca-form`; give it the same box. */
/* `.eca-select` is the sibling of `.eca-input` and carries the same box, whether or not the page
   wraps it in `.eca-form`: the Fomantic dropdown it replaces had no stylesheet behind it after the
   plugin went away, so the control was a browser-default `<select>` in a dead class. */
.eca-btn.eca-btn-secondary,
.eca-btn.eca-btn--secondary{
  background: transparent;
  color: color-mix(in oklab, var(--color-base-content) 78%, transparent);
  border-color: var(--color-base-300);
}
.eca-btn.eca-btn-secondary:hover,
.eca-btn.eca-btn--secondary:hover{
  background: var(--color-base-200);
  border-color: var(--color-primary);
  color: var(--color-base-content);
}
/* ── A destructive action's confirmation (§3.9a) ──────────────────────────────
   Four pages built the same thing by hand: a `<details>` whose `<summary>` is the danger button,
   holding the "are you sure?" sentence and a Yes/No form. Without a component the three pieces
   were styled by whatever class the author remembered — which is how two of the four ended up as
   `ui modal`s that never opened (`jQuery.fn.modal` is a shim here, and `confirmModal.setModal` is
   a no-op), so "Delete Role" submitted the *edit* form instead.
   The panel is absolutely positioned from the summary, so opening it does not re-flow the
   `.eca-actions` row it sits in, and there is no overlay to dismiss: no JS, no focus trap, no
   z-index war. `[open]` is the state, so the trigger is what shows it opened. */
.eca-confirm{
  position: relative;
  display: inline-block;
}
.eca-confirm > summary{
  list-style: none;
  cursor: pointer;
}
/* The platform's own marker (▸ / triangle) on a control that already looks like a button. */
.eca-confirm > summary::-webkit-details-marker{ display: none; }
.eca-confirm[open] > summary{ border-color: var(--color-error); }
.eca-confirm__panel{
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + var(--space-2));
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  min-inline-size: min(20rem, calc(100vw - 2rem));
  max-inline-size: 26rem;
  padding: var(--space-4);
  background: var(--color-base-100);
  border: var(--border) solid var(--color-base-300);
  border-radius: var(--radius-box);
  box-shadow: 0 12px 32px rgb(16 24 40 / 18%);
  text-align: start;
}
.eca-confirm__text{
  margin: 0;
  font-size: var(--text-sm);
  line-height: 1.5;
  color: var(--color-base-content);
}
.eca-confirm__actions{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  /* the action rhythm (ui-system.css §1), which this panel borrowed from the inline scale */
  gap: var(--gap-actions);
}
.eca-confirm__actions > *{ margin: 0; }
/* The same rule as `ui-system.css` §action rows, for this row: a form that holds nothing but a
 * submit button is not a layout element. Measured on `/issue/1` at 1440: "Yes, delete" (inside
 * `<form class="eca-form eca-inline-form">`) at y=2197 and "No" at y=2205 — 8 px apart, because the
 * form's box was taller than the link and `align-items:center` centred the BUTTON inside it. */
.eca-confirm__actions > form:not(:has(input:not([type="hidden"]), select, textarea)){ display: contents; }
/* A confirm sits in the page's final action bar, so "below the trigger" is off the bottom of the
   viewport: `disclosure-group.js` measures and sets `opens-up`, exactly as it does for the
   multiselect and the nav group (§ deterministic placement — never a measured-height guess). */
.eca-confirm.opens-up > .eca-confirm__panel{
  top: auto;
  bottom: calc(100% + var(--space-2));
}
@media (max-width: 480px) {
  /* At 390 the panel is a column above the trigger: an absolutely positioned card wider than the
     viewport is how a confirmation becomes unreadable. */
  .eca-confirm__panel{
    position: static;
    margin-top: var(--space-2);
    min-inline-size: 0;
    max-inline-size: none;
    box-shadow: none;
  }
}
/* A leading paragraph under a page title, a value being confirmed, a terms block, and a column
   that should stop at a readable measure. */
.eca-lead{ font-size: var(--text-lg); line-height: 1.5; max-width: var(--width-reading); }
.eca-reading-column{ max-width: var(--width-reading); }
.eca-confirm-value{ font-weight: 700; font-variant-numeric: tabular-nums; }
.eca-terms-text{ font-size: var(--text-sm); opacity: 0.8; max-width: var(--width-reading); }
/* The sign-in page lists dev identities; the list needs rows, not a run-on line. */
.eca-pid-list{ display: flex; flex-direction: column; gap: var(--space-1); margin: 0; padding: 0; list-style: none; }
/* The label of a multiselect disclosure. */
.eca-multiselect__label{ font-weight: 600; }
/* ── Field error text (§3.26) ───────────────────────────────────────────────────
   FormSupport emitted `ui pointing red basic label` for a field error — the last legacy class on a
   migrated form. A field error is text under the control, not a Fomantic corner label. */
.eca-hint--error{
  display: block;
  margin: var(--space-1) 0 0;
  font-size: var(--text-sm);
  color: var(--color-error);
}
/* ── Flash message (§3.27) ─────────────────────────────────────────────────────
   The one place a migrated page still emitted `ui success icon message` with Fomantic icons and a
   jQuery dismiss handler. A flash is an eca-message: tone on the container, a bold title and the
   text under it, an optional close button that needs no script. */
.eca-message__body{ display: flex; flex-direction: column; gap: var(--space-1); min-width: 0; }
.eca-message__title{ font-weight: 700; }
.eca-message__text{ margin: 0; }
.eca-message--error{ border-color: var(--color-error); }
.eca-message--info{ border-color: var(--color-info); }
.eca-message:has(.eca-message__close){
  display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-3);
}
.eca-message__close{
  flex: 0 0 auto; min-width: 1.75rem; min-height: 1.75rem;
  background: none; border: 0; cursor: pointer; font-size: var(--text-lg); line-height: 1;
  color: inherit; opacity: .7;
}
.eca-message__close:hover{ opacity: 1; }
/* ── Search inside a toolbar (§3.28) ───────────────────────────────────────────
   A GET form that narrows a list: the field and its buttons sit on the toolbar's line and wrap
   together on a phone, so the search never becomes a lone box above the table. */
.eca-toolbar__search{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin: 0 var(--space-2) 0 0;
}
.eca-toolbar__search .eca-input{ min-width: 14rem; width: auto; }
@media (max-width: 600px) {
  .eca-toolbar__search{ width: 100%; margin: 0 0 var(--space-2); }
  .eca-toolbar__search .eca-input{ min-width: 0; width: 100%; }
}
/* Final mobile touch contract: these rules sit after the component blocks so a later
   `height`/`min-height` on `.eca-btn` or a cell link cannot reduce the 44px target. */
@media (max-width: 640px) {
  .table-scroll > table.eca-table--cards,
  .table-scroll > table.eca-table--cards:has(> thead > tr > th:nth-child(4)){
    min-width: 0 !important; width: 100% !important;
  }
  .table-scroll > table.eca-table--cards:has(> thead > tr > th:nth-child(4)) th,
  .table-scroll > table.eca-table--cards:has(> thead > tr > th:nth-child(4)) td,
  .table-scroll > table.eca-table--cards th,
  .table-scroll > table.eca-table--cards td{ white-space: normal !important; }
  .eca-table--cards td.collapsing{ width: auto !important; min-width: 0; }
  .eca-table td a,
  .eca-table td button,
  .eca-table td summary{
    display: inline-flex; align-items: center;
    min-height: 44px; min-width: 44px;
  }
  .eca-table.eca-table--cards td a,
  .eca-table.eca-table--cards td button{
    display: inline-flex; align-items: center;
    min-height: 44px; min-width: 44px;
  }
}
/* The tree container and its row are emitted by MDTree; `mdtree2.min.css` styles the nodes,
   columns and controls inside them, but the two structural classes had no rule of their own
   (X107: a class emitted and never styled). They only establish the block context the tree's
   own layout works in. */
.eca-mdtree{ display: block; }
.eca-mdtree__row{ display: block; }
/* ── action rows ──────────────────────────────────────────────────────────────
   A group of buttons needs ONE gap from the spacing scale, not the legacy
   legacy button `margin: .1rem` (1.6px) that made adjacent actions look stuck together.
   Pages must wrap their actions in this; a bare pair of buttons has no owner for the gap. */
.eca-actions > .button, .eca-actions > .eca-btn,
.eca-actions > button{ margin: 0; }
/* the row owns the spacing, not each control */
.eca-actions--end{ justify-content: flex-end; }
/* Fallback for a page that forgot the row: two adjacent actions still get a gap from
   the scale instead of admin.css's legacy button `margin: .1rem` (1.6px). This is a
   safety net, not a substitute for `.eca-actions` (which also owns the block margins). */
.button + .button, .eca-btn + .eca-btn{ margin-left: var(--space-2); }
/* inside an action row the gap is the row's, so the safety net must not stack on it
   (13px + 8px measured as 21px before this line) */
.eca-actions > .button + .button,
.eca-actions > .eca-btn + .eca-btn{ margin-left: 0; }
/* …and the same inside a button GROUP: the group owns its gap (`var(--space-2)`) and states
   `margin: 0` for its children above, but this safety net is declared later in the file at equal
   specificity, so it won anyway — measured in the two-column split, where the group is a column:
   the second and third buttons sat 8px right of the first and fourth (x 893 vs 885, all 380 wide),
   and in a row the gap read as 16px instead of 8. */
.eca-btn-group > .button + .button,
.eca-btn-group > .eca-btn + .eca-btn{ margin-left: 0; }
/* ── form field layout (restored) ───────────────────────────────────────────
   The migrated pages emit SUI's grid vocabulary inside forms — `two fields`,
   `five wide` / `eleven wide`, `inline field`, `right floated` — and only
   a `right floated` rule existed, which does nothing outside a flex
   row, so the action buttons stacked against the last control. The width modifiers had
   no rules at all outside the legacy grid, so a 5/11 split rendered as two equal columns.
   Fixing it here fixes every page that emits the vocabulary, instead of per page. */
:is(.eca-form) .fields{
  display: flex; flex-wrap: wrap; align-items: flex-start;
  gap: 12px 16px;
  margin-bottom: 8px;   /* the row's own air; its children carry no margin */
}
:is(.eca-form) .fields > .field{ flex: 1 1 12rem; min-width: 0; margin-bottom: 0; }
/* `wide` in a form is a share of the row, the same idea as a grid column */
:is(.eca-form) .fields > .field.wide{ flex-grow: 1; flex-basis: 0; }
:is(.eca-form) .fields > .field.two.wide{ flex-grow: 2; }
:is(.eca-form) .fields > .field.three.wide{ flex-grow: 3; }
:is(.eca-form) .fields > .field.four.wide{ flex-grow: 4; }
:is(.eca-form) .fields > .field.five.wide{ flex-grow: 5; }
:is(.eca-form) .fields > .field.six.wide{ flex-grow: 6; }
:is(.eca-form) .fields > .field.seven.wide{ flex-grow: 7; }
:is(.eca-form) .fields > .field.eight.wide{ flex-grow: 8; }
:is(.eca-form) .fields > .field.nine.wide{ flex-grow: 9; }
:is(.eca-form) .fields > .field.ten.wide{ flex-grow: 10; }
:is(.eca-form) .fields > .field.eleven.wide{ flex-grow: 11; }
:is(.eca-form) .fields > .field.twelve.wide{ flex-grow: 12; }
:is(.eca-form) .fields > .field.thirteen.wide{ flex-grow: 13; }
:is(.eca-form) .fields > .field.fourteen.wide{ flex-grow: 14; }
:is(.eca-form) .fields > .field.fifteen.wide{ flex-grow: 15; }
:is(.eca-form) .fields > .field.sixteen.wide{ flex-grow: 16; }
/* a field row needs air under it, and an inline field is a row of its own */
:is(.eca-form) > .field, :is(.eca-form) > .inline.field{ margin-bottom: 14px; }
:is(.eca-form) .inline.field{ display: flex; align-items: center; gap: 8px; }
:is(.eca-form) .inline.field > label{ margin-bottom: 0; }
/* actions: `right floated` only floats inside a block formatting context, and two
   floated buttons need a gap of their own */
:is(.eca-form)::after{ content: ""; display: block; clear: both; }
:is(.eca-form) > .right.floated{ margin-top: 6px; }
:is(.eca-form) > .right.floated{ float: right; margin-left: 8px; }
@media (max-width: 720px) {
  :is(.eca-form) .fields{ flex-direction: column; gap: 12px; }
  :is(.eca-form) .fields > .field{ flex: 0 0 auto; width: 100%; }
}
/* ═══ New components (§5) — added with the `/permissions`, `/roles` and `/spaces` passes ════════
   Each one exists because a migrated page needed it and no published name covered it. A component
   is a BLOCK with `__elements`, and it is written here (the shared layer) rather than in a page. */
/* ── Two-column page split (§3.2): main content + a side panel of actions ──────
   The legacy shape was a Fomantic grid (`ten wide column` / `six wide column`). A grid ties the two
   columns to a 16ths scale and stacks them only below 768; this is the same idea with a readable
   minimum for the side panel, and it is one column below 900 — where the side panel's buttons are
   full width instead of a narrow strip beside the main form.

   The two `__elements` were emitted with **no rule** for a cut (X107: a class emitted but never
   styled is a component that does not exist — both were inert hooks and the "full width" the
   comment above promised never happened). Each one now carries the work its name claims:
   `__main` states the grid item's `min-width` (a grid item defaults to `auto`, i.e. its own
   max-content, so a table in the main column widened the page instead of scrolling inside it),
   and `__side` is the vertical stack of action panels, whose button group fills the column. */
.eca-split{
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(min(100%, 17rem), 1fr);
  gap: var(--space-4);
  align-items: start;
}
.eca-split > *{ min-width: 0; }
.eca-split__main{ min-width: 0; }
.eca-split__side{
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--gap-block);
}
/* The side panel is one control per row: a wrapped button group in a ~17rem column reads as two
   ragged rows of unequal widths, and the destructive action in its own form below would be the
   shortest of them. Both are `.eca-btn`s inside the column, so the rule names the component, not
   the two wrappers it happens to sit in today. */
.eca-split__side .eca-btn-group{
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.eca-split__side .eca-btn{ width: 100%; }
@media (max-width: 900px) {
  .eca-split{ grid-template-columns: minmax(0, 1fr); }
}
/* ── A list of links inside a section (§3.14) ─────────────────────────────────
   Child spaces, related records, "see also": a vertical list of navigable rows. A bare `<ul>`
   inherited a 40px UA indent and read as an indented paragraph; as a component it is flush, evenly
   spaced, and each row is a 32px target. */
.eca-link-list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.eca-link-list > li > a{
  display: inline-flex;
  align-items: center;
  /* Touch is the base; a pointer gets the 24 px minimum (WCAG 2.2 2.5.8).
     BOTH axes: the row was 44 px TALL and only as wide as its label, so `/system/help`'s "Roles"
     measured 39x44 at 390 — a short word is the smallest target on the page, and the audit counts
     `width < 44 || height < 44`. A link's box is not its text: the floor belongs to the box, and a
     `min-width` costs nothing visible (no background, no border, the underline still covers only
     the glyphs). Same token as the height, so the row is one square target at every width. */
  min-height: var(--control-h-touch);
  min-width: var(--control-h-touch);
}
@media (min-width: 1200px) {
  .eca-link-list > li > a{ min-height: 1.5rem; min-width: 1.5rem; }
}
/* ── `hidden` must actually hide ──────────────────────────────────────────────
   The permission catalogue renders every resource panel and switches them without a round trip
   (one page, `hidden` on the inactive ones). `hidden` is only a UA `display: none`, so any class
   rule on the same element — `.eca-tabs > .item`, `.eca-section` — beats it and the "hidden" panel
   stays on screen (measured on `/permissions`: two panels visible at once). Stated once, here, for
   the two components that toggle it. */
.eca-section[hidden],
.eca-tabs > .item[hidden],
.eca-tabs > a.item[hidden]{ display: none !important; }
/* ── The page title owns no rule of its own ───────────────────────────────────
   `admin.css` gives every `h1` a bottom border (the legacy "dividing header" look). Inside
   `.eca-page-header` that drew a second rule under the title, a few pixels above the header's
   own — two lines that mean nothing. The design-system title is plain; the header carries the
   rule. */
/* ── A search field with its glyph INSIDE it (§3.28) ─────────────────────────
   The tree page emitted `<div class="search"><input><i class="search icon"></i></div>`; the
   flex row put the magnifier *after the box*, on its own line (measured on /spaces, before and
   after the `eca-*` port — the icon was never inside the field). One wrapper that positions the
   glyph and pads the input is the whole fix, and any search field can use it. */
.eca-search{ position: relative; display: block; min-width: 0; }
.eca-search > .mdi,
.eca-search > i{
  position: absolute;
  inset-inline-start: .75rem;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  opacity: .5;
  pointer-events: none;
}
.eca-search > .eca-input{ padding-inline-start: 2.25rem; }
/* ── A form that is ONE row of controls, submitting in place (§3.9) ──────────
   Row actions that take input (unassign + remarks, move + target + reason) used Fomantic's
   `.inline` variation, which this layer never styled: three forms collapsed into a narrow
   table cell with `width:100%` inputs and were clipped mid-placeholder ("Move reas").
   A flex row per form, wrapping only when the cell is genuinely too narrow, and the forms
   stack as blocks in the cell. */
.eca-form.eca-inline-form{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin: 0 0 var(--space-2);
}
.eca-form.eca-inline-form:last-child{ margin-bottom: 0; }
.eca-form.eca-inline-form > input:not([type="hidden"]),
.eca-form.eca-inline-form > select{
  width: auto;
  flex: 1 1 8rem;
  min-width: 7rem;
}
.eca-form.eca-inline-form > .eca-btn{ flex: 0 0 auto; }
/* ── Air between a fact list and the form under it, and above a form's submit ─
   Both were flush: the first field label touched the last fact row, and "Save Configuration"
   sat directly on its input row. */
.eca-facts + .eca-form{ margin-top: var(--space-5); }
.eca-form > .eca-field-row + .eca-btn,
.eca-form > .eca-field + .eca-btn,
.eca-form > .eca-field-row + button{ margin-top: var(--space-3); }
