/* Small single-purpose helpers. The utilities layer wins over components. */
@layer utilities {
  .muted { color: var(--ink-3); }
  .small { font-size: 12px; }
  .nowrap { white-space: nowrap; }
  .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
  .mono { font-family: var(--font-mono); font-size: 12.5px; }
  .grow { flex: 1; min-width: 0; }
  .icon { flex: none; }
  .text-ok { color: var(--ok); }
  .text-warn { color: var(--warn); }
  .text-bad { color: var(--bad); }

  /* Hidden on screen, read by screen readers */
  .visually-hidden {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
  }

  /* "Skip to content" — first focusable element of every layout (T0.5) */
  .skip-link {
    position: absolute; left: 8px; top: -48px; z-index: 100; padding: 8px 14px; border-radius: var(--radius-sm);
    background: var(--primary); color: var(--primary-ink); font-weight: 600;
  }
  .skip-link:focus { top: 8px; text-decoration: none; }

  @media (max-width: 860px) {
    .hide-mobile { display: none !important; }
    /* In stacked tables a number sits under its caption, so it aligns with it (beats .num) */
    .table--stack td.num { text-align: left; }
  }
  /* Phones: the topbar keeps the language switch; the theme switch moves into the drawer */
  @media (max-width: 480px) {
    .hide-phone { display: none !important; }
  }
  @media (min-width: 481px) {
    .show-phone { display: none !important; }
  }
}
