/* ==========================================================================
   sk-type.css — app-wide typographic standard (2026-08-15).
   Spec: docs/font_size_2026-08-15/DESIGN_SPEC.md  §3, §5.1
   Scale: body/inputs/td 14 · labels/thead/btn 13 · floor 12 · titles 19-20.
   html{font-size:10px} (sk-vendor.css:966) is UNTOUCHED — these tokens are
   px precisely so text-* renders at design size on the 10px root.
   Linked ONLY from layouts/partials/css.blade.php (last line). 16px-root
   layouts (kiosk/catalogue/mes/courier/portals/menu-board) must never load
   this file — their stock-rem Tailwind is already correct.
   :root:root (0-2-0) and html .text-* (0-1-1) win the cascade wherever the
   sheet lands relative to tailwindcss.css / tailwind.min.css (load order
   flips between the app and restaurant layouts).
   ========================================================================== */

/* 1. Tailwind v4 token remap (tailwindcss.css reads var(--text-*)) */
:root:root {
  --text-xs: 12px;   --text-xs--line-height: 1.5;
  --text-sm: 13px;   --text-sm--line-height: 1.5;
  --text-base: 14px; --text-base--line-height: 1.5;
  --text-lg: 16px;   --text-lg--line-height: 1.45;
  --text-xl: 18px;   --text-xl--line-height: 1.4;
  --text-2xl: 20px;  --text-2xl--line-height: 1.35;
  --text-3xl: 24px;  --text-3xl--line-height: 1.3;
  --text-4xl: 28px;  --text-4xl--line-height: 1.25;
}

/* 2. v2 tailwind.min.css class overrides (that build hardcodes rem values;
      consumers: auth, auth2, restaurant, install — loaded twice on auth).
      html prefix (0-1-1) out-ranks the bare utility (0-1-0) without beating
      page-level component rules. Responsive md:/lg: text-* variants keep
      their v2 values; if a verified page misuses them, add the variant
      override here rather than raising specificity elsewhere. */
html .text-xs   { font-size: 12px; }
html .text-sm   { font-size: 13px; }
html .text-base { font-size: 14px; }
html .text-lg   { font-size: 16px; }
html .text-xl   { font-size: 18px; }
html .text-2xl  { font-size: 20px; }
html .text-3xl  { font-size: 24px; }
html .text-4xl  { font-size: 28px; }

/* 3. Floor safety net for relative-sized helpers. max() keeps intentionally
      larger contexts intact (a small inside a 24px KPI stays 19.2px); inline
      styles and !important owners still win — the sweep tasks fix those in
      place, this net only catches the unclassed long tail. */
small { font-size: max(12px, 0.8em); }
.help-block, .form-text { font-size: max(12px, 0.86em); }

/* 4. TABLE-CELL LOCK — the standard says body cells are 14px, but two legacy
      idioms stamp 13px per-cell and cannot be swept file-by-file:
      (a) the arbitrary Tailwind class text-[1.3rem] (thousands of td uses,
          Hrm especially; a text-[1.4rem] class does not exist in the prebuilt
          CSS so re-classing is impossible without a build), and
      (b) JS renderers injecting style="font-size: 1.3rem" on cells.
      (a) needs only specificity; (b) needs !important to beat an inline style
      — scoped strictly to td so th/chips keep their slots. */
html td.text-\[1\.3rem\] { font-size: 14px; }
td[style*="font-size: 1.3rem"],
td[style*="font-size:1.3rem"] { font-size: 14px !important; }
