/* MLC Software Solutions: "classic" look (Dec 2026).
   Simple and traditional: system font at 13px, white panels on light grey, thin borders, small corners, one calm blue,
   dense tables. Loaded after app.css and overrides it; the two-level header and the menu panels are defined here. */
:root {
  --bg: #f2f4f7;
  --panel: #ffffff;
  --panel-2: #f7f8fa;
  --ink: #1f2937;
  --ink-strong: #111827;
  --ink-2: #374151;
  --ink-3: #4b5563;
  --muted: #6b7280;
  --faint: #9ca3af;
  --line: #d9dde3;
  --line-2: #e9ecf0;
  --field-line: #c6ccd5;
  --accent: #1f5fae;
  --accent-strong: #174a88;
  --accent-hover: #174a88;
  --accent-soft: #e8f0fa;
  --muted-bg: #f1f3f6;
  --radius: 4px;
  --radius-sm: 3px;
  --shadow: none;
  --header-h: 44px;
  --nav: #1b2a41;
}
html { font-size: 13px; }
body { font: 13px/1.45 "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif; background: var(--bg); }
h1 { font-size: 20px; font-weight: 600; letter-spacing: 0; }
h2 { font-size: 14px; font-weight: 600; letter-spacing: 0; margin-bottom: 8px; }
h3 { font-size: 13px; font-weight: 600; }
.hint { font-size: 12px; }
code { font-size: 12px; border-radius: 3px; }
:focus-visible { outline: 2px solid rgba(31, 95, 174, .5); outline-offset: 1px; }
.empty { padding: 26px 16px; border-radius: var(--radius); }
.empty b { font-size: 14px; }
.loading { padding: 40px 20px; font-weight: 500; }

/* buttons */
.btn { height: 30px; padding: 0 12px; gap: 6px; font-size: 13px; font-weight: 600; border-radius: var(--radius-sm); border-color: var(--field-line); background: #fff; color: var(--ink-strong); }
.btn:hover { background: #f5f7fa; border-color: #aeb6c2; }
.btn.pri { box-shadow: none; background: var(--accent); border-color: var(--accent); }
.btn.pri:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.btn.danger { background: #c62828; border-color: #c62828; }
.btn.danger:hover { background: #a61f1f; border-color: #a61f1f; }
.btn.small { height: 26px; padding: 0 9px; font-size: 12px; border-radius: var(--radius-sm); }
.btn.block { height: 34px; }
.btn svg { width: 14px; height: 14px; }
.icon-btn { min-width: 30px; height: 30px; padding: 0 6px; border-radius: var(--radius-sm); font-size: 13px; }
.icon-btn:hover { background: #fff; border-color: var(--line); }
.count { font-size: 11px; font-weight: 700; padding: 0 6px; line-height: 16px; border-radius: 8px; margin-left: 6px; }

/* status labels: small rectangles */
.pill { padding: 1px 7px; border-radius: 3px; font-size: 11px; font-weight: 600; gap: 4px; }
.pill.gap { padding: 0 6px; border-width: 1px; }

/* forms */
input, select, textarea { font-size: 13px; padding: 5px 8px; border-radius: var(--radius-sm); min-height: 30px; background: #fff; border-color: var(--field-line); }
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(31, 95, 174, .22); border-color: var(--accent); }
:is(table.grid-edit, table.hb-table, .tpl-item, .fb-row, .hb-hz, .hb-flow-line) :is(input, select, textarea) { min-height: 28px; padding: 4px 7px; }
input:disabled, select:disabled, textarea:disabled { background: var(--panel-2); }
input[type=checkbox], input[type=radio] { width: 15px; height: 15px; }
label { font-size: 12px; font-weight: 600; color: var(--ink-2); margin-bottom: 3px; }
.check { font-size: 13px; font-weight: 500; gap: 6px; }
.readonly { padding: 5px 8px; min-height: 30px; border-radius: var(--radius-sm); }
.grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 14px; }
.row { margin-top: 10px; gap: 8px; }
.chips { min-height: 30px; padding: 3px; border-radius: var(--radius-sm); background: #fff; gap: 4px; }
.chip { font-size: 12px; padding: 1px 4px 1px 8px; border-radius: 3px; }
.chip-add { min-height: 24px; padding: 2px 8px; font-size: 12px; }
.why-n { font-size: 11px; }

/* ---------- header: navy top bar + white menu bar ---------- */
.chrome { position: sticky; top: 0; z-index: 40; }
header.top { position: relative; height: var(--header-h); gap: 12px; padding: 0 14px; background: var(--nav); border-bottom: 0; color: #e5e9f0; }
.brand { color: #fff; font-size: 14.5px; font-weight: 600; letter-spacing: 0; gap: 8px; }
.brand:hover { color: #fff; }
.brand .mlc-icon { width: 28px; height: 28px; }
.company-pill { height: 28px; padding: 0 10px; gap: 6px; border-radius: var(--radius-sm); background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .2); color: #fff; font-size: 12.5px; font-weight: 600; }
.company-pill select { height: 26px; color: #fff; font-weight: 600; }
.company-pill select option { color: var(--ink); }
.company-pill svg { right: 9px; color: #c7cfdb; }
.company-pill .co-logo { height: 18px; max-width: 54px; background: #fff; border-radius: 2px; padding: 1px; }
.company-pill .co-logo.placeholder { height: 20px; }
.goto { flex: 0 1 380px; display: flex; align-items: center; gap: 8px; height: 28px; margin-left: 6px; padding: 0 8px 0 10px; border: 1px solid rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .07); color: #c3ccd9; border-radius: var(--radius-sm); cursor: pointer; font-size: 12.5px; }
.goto:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.goto > span { flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
kbd { font: 600 10.5px/1.6 "Segoe UI", system-ui, sans-serif; padding: 0 5px; border: 1px solid #c6ccd5; border-bottom-width: 2px; border-radius: 3px; background: #fff; color: var(--ink-2); white-space: nowrap; }
.goto kbd { background: transparent; border-color: rgba(255, 255, 255, .28); color: #c3ccd9; }
.bell { width: 32px; height: 32px; border-radius: var(--radius-sm); background: transparent; border-color: transparent; color: #dbe2ec; }
.bell:hover { background: rgba(255, 255, 255, .1); border-color: transparent; color: #fff; }
.bell .dot { top: 6px; right: 6px; border-color: var(--nav); }
.avatar { width: 30px; height: 30px; font-size: 13px; font-weight: 700; background: #3a74c8; }
header.top .menu { top: calc(100% + 4px); }
.hamburger { color: #fff; }
.hamburger:hover { background: rgba(255, 255, 255, .1); color: #fff; border-color: transparent; }

.navwrap { position: relative; background: #fff; border-bottom: 1px solid var(--line); }
.menubar { display: flex; align-items: stretch; height: 36px; padding: 0 8px; gap: 0; }
.mb-item { display: inline-flex; align-items: center; gap: 6px; padding: 0 12px; border: 0; border-bottom: 2px solid transparent; border-top: 2px solid transparent; background: none;
  color: var(--ink-2); font-size: 13px; font-weight: 600; cursor: pointer; text-decoration: none !important; white-space: nowrap; }
.mb-item svg { color: var(--muted); }
.mb-item:hover, .mb-item[aria-expanded=true] { background: #f2f5f9; color: var(--ink-strong); }
.mb-item.on { color: var(--accent); border-bottom-color: var(--accent); }
.mb-item.on svg { color: var(--accent); }
.mb-item[aria-expanded=true] { border-bottom-color: #aeb6c2; }
.mb-item.subtle { color: var(--muted); font-weight: 500; }
.mi-count { display: inline-block; min-width: 17px; padding: 0 5px; border-radius: 8px; background: #e7edf6; color: var(--accent-strong); font-size: 10.5px; font-weight: 700; line-height: 16px; text-align: center; }
.mb-item .mi-count { background: var(--accent); color: #fff; }

/* the panel a menu opens: the group's pages in columns, with quick add and recently viewed on the right */
.mega-panel { position: absolute; left: 0; right: 0; top: 100%; z-index: 45; background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 14px 28px rgba(17, 24, 39, .14); }
.mp-inner { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 22px; max-width: 1380px; margin: 0 auto; padding: 14px 20px 16px; }
.mp-title { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); margin: 0 0 6px; }
.mp-grid { display: grid; grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); gap: 1px 16px; }
.mp-item { display: flex; align-items: flex-start; gap: 9px; padding: 6px 8px; border-radius: var(--radius-sm); color: var(--ink); text-decoration: none !important; min-width: 0; }
.mp-item:hover { background: #eef3fa; }
.mp-item.on { background: var(--accent-soft); }
.mp-item .mp-ico { width: 26px; height: 26px; border-radius: 4px; margin-top: 1px; }
.mp-text { display: flex; flex-direction: column; min-width: 0; }
.mp-text b { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-strong); }
.mp-text small { font-size: 11.5px; color: var(--muted); line-height: 1.35; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-side { border-left: 1px solid var(--line-2); padding-left: 18px; display: flex; flex-direction: column; }
.mp-quick { display: flex; align-items: center; gap: 6px; padding: 4px 6px; font-size: 13px; color: var(--accent); border-radius: var(--radius-sm); }
.mp-quick:hover { background: #eef3fa; text-decoration: none; }
.mp-recent { margin-top: 12px; }
.mp-recent:empty { display: none; }
.mp-recent a { display: block; padding: 3px 6px; font-size: 12.5px; color: var(--ink); border-radius: var(--radius-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-recent a span { color: var(--accent); font-weight: 600; }
.mp-recent a:hover { background: #eef3fa; text-decoration: none; }

/* "Go to…" (Ctrl+K) */
.pal-overlay { position: fixed; inset: 0; z-index: 200; display: flex; justify-content: center; align-items: flex-start; padding-top: 11vh; background: rgba(17, 24, 39, .38); }
.pal { width: min(640px, calc(100vw - 24px)); background: #fff; border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 24px 60px rgba(0, 0, 0, .28); overflow: hidden; }
.pal-head { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line-2); color: var(--muted); }
.pal-head input { border: 0; min-height: 0; padding: 6px 0; font-size: 15px; background: transparent; }
.pal-head input:focus { outline: none; }
.pal-list { max-height: 56vh; overflow: auto; padding: 4px 0 6px; }
.pal-group { padding: 8px 14px 3px; font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.pal-item { display: flex; align-items: center; gap: 10px; padding: 6px 14px; cursor: pointer; color: var(--ink); }
.pal-item svg { color: var(--muted); flex: none; }
.pal-item .pal-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-item small { margin-left: auto; padding-left: 12px; color: var(--muted); font-size: 11.5px; white-space: nowrap; }
.pal-item.active { background: var(--accent-soft); }
.pal-item.active svg { color: var(--accent); }
.pal-empty { padding: 18px 14px; color: var(--muted); }
.pal-foot { padding: 6px 12px; border-top: 1px solid var(--line-2); background: var(--panel-2); color: var(--muted); font-size: 11px; }

/* ---------- page layout ---------- */
.shell { min-height: calc(100vh - 80px - 40px); }
main { max-width: none; padding: 14px 20px 28px; }
.app-foot { padding: 10px 16px 14px; font-size: 11px; font-weight: 500; }
.page-head { margin-bottom: 10px; gap: 10px 16px; align-items: center; }
.ph-text { gap: 2px; }
.ph-title { gap: 9px; }
.page-head h1 { font-size: 20px; }
.page-sub { font-size: 12.5px; color: var(--muted); }
.page-icon { width: 28px; height: 28px; border-radius: 4px; }
.page-icon svg { width: 16px; height: 16px; }
.crumbs { font-size: 11.5px; font-weight: 500; }
.crumbs .sep { margin: 0 4px; }
.page-actions { gap: 6px; }

/* tabs: a classic tab strip */
.tabs { display: flex; gap: 0; padding: 0; margin-bottom: 12px; background: transparent; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
.tab { height: 32px; padding: 0 14px; border-radius: 0; font-size: 13px; font-weight: 600; color: var(--ink-3); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab:hover { background: #f2f5f9; color: var(--ink-strong); }
.tab.on { background: transparent; color: var(--accent); border-bottom-color: var(--accent); }
.tab.on .count { background: var(--accent-soft); color: var(--accent-strong); }

.card { padding: 12px 14px; margin-bottom: 12px; border-radius: var(--radius); }
.card-head { margin-bottom: 8px; }
.banner { padding: 7px 10px; border-radius: var(--radius-sm); font-size: 12.5px; margin-bottom: 10px; }
.banner.info { background: #eef3fa; border-color: #cfdcef; color: #1d3c66; }
.toolbar { gap: 8px; margin-bottom: 10px; }
.seg { padding: 2px; gap: 2px; border-radius: var(--radius); }
.seg-btn { height: 26px; padding: 0 10px; font-size: 12.5px; border-radius: var(--radius-sm); }
.seg-btn.on { box-shadow: 0 0 0 1px var(--line); }

/* stat cards: a compact strip */
.tiles, .stats { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin-bottom: 12px; }
.tile, .stat { padding: 8px 12px; gap: 1px; border-radius: var(--radius); }
.tile b, .stat .st-value { font-size: 20px; font-weight: 600; letter-spacing: 0; }
.tile span, .stat .st-label { font-size: 11.5px; font-weight: 600; gap: 6px; }
.tile span::before, .stat .st-label i { width: 7px; height: 7px; }
.stat .st-cap { font-size: 11px; }
.tile.hero, .stat.hero { background: #fff; border-color: var(--line); border-left: 3px solid var(--accent); color: var(--ink); }
.tile.hero b, .tile.hero span, .stat.hero .st-value, .stat.hero .st-label { color: var(--ink-strong); }
.stat.hero .st-label { opacity: 1; }
.stat.hero .st-cap { color: var(--muted); }
.stat .meter { height: 4px; margin-top: 3px; background: #e5e9f0; }
.stat .meter i { height: 4px; background: var(--accent); }
.stat.on { box-shadow: 0 0 0 2px var(--accent-soft); }

/* filters */
.filterbar { gap: 6px; padding: 6px 8px; margin-bottom: 10px; border-radius: var(--radius); }
.filterbar .searchbox { flex: 1 1 220px; height: 30px; gap: 6px; padding: 0 8px; border-radius: var(--radius-sm); background: #fff; border-color: var(--field-line); }
.filterbar .searchbox input { height: 26px; }
.filterbar .searchbox:focus-within { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(31, 95, 174, .15); }
.filterbar select { width: 150px; }
.filterbar select.set { border-color: #9fb9de; background: var(--accent-soft); }
.filterbar .yearnav { padding: 2px; }
.filterbar .seg-btn { height: 24px; }
.fb-note { font-size: 12px; font-weight: 500; }
.fb-tools { gap: 6px; }

/* tables: dense, striped */
.list-card { border-radius: var(--radius); margin-bottom: 12px; }
.table-wrap { border-radius: var(--radius); max-height: calc(100vh - 200px); }
table.data { font-size: 12.5px; }
table.data th { padding: 6px 10px; font-size: 11.5px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--ink-2); background: #f1f3f6; border-bottom: 1px solid var(--line); }
table.data td { padding: 5px 10px; }
table.data:not(.compact) tr > :first-child { padding-left: 12px; }
table.data:not(.compact) tr > :last-child { padding-right: 12px; }
table.data td:first-child a { font-weight: 600; }
table.data tbody tr:nth-child(even) > td { background: #fafbfc; }
table.data tbody tr:hover > td { background: #edf3fb; }

/* help panels: smaller */
.help-panel { padding: 7px 12px; font-size: 12.5px; border-radius: var(--radius); background: #f6f8fb; border-color: #dfe5ee; color: var(--ink-2); }
.help-panel ol { gap: 1px; line-height: 1.4; padding-left: 18px; }
.help-btn { color: var(--accent) !important; }

/* dashboard */
.dash-tiles { gap: 10px; margin-bottom: 16px; }
.tile-group h2 { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; margin-bottom: 5px; }
.tile-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 6px; }
.dash-tile { padding: 8px 10px; gap: 10px; border-radius: var(--radius); }
.dash-tile:hover { box-shadow: none; transform: none; border-color: #9fb9de; background: #fbfcfe; }
.dash-tile .page-icon { width: 28px; height: 28px; border-radius: 4px; }
.dt-text { gap: 1px; padding-right: 22px; }
.dt-text b { font-size: 13px; font-weight: 600; }
.dt-text span { font-size: 11.5px; -webkit-line-clamp: 1; }
.dt-badge { top: 8px; right: 8px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; font-size: 11px; font-weight: 700; line-height: 18px; }
.dash-section { font-size: 14px; margin: 4px 0 8px; }
.dash-grid { gap: 12px; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
.dash-stats .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.dash-note { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin: 10px 0 0; padding-top: 8px; border-top: 1px solid var(--line-2); color: var(--ink-2); font-size: 12.5px; }
.dash-note svg { color: var(--muted); }
#attention .card-head { flex-wrap: wrap; }
.attn-what { margin: -4px 0 8px; }
table.attn tr.grp > td { background: #f1f3f6 !important; font-size: 11.5px; font-weight: 700; color: var(--ink-2); padding-top: 6px; padding-bottom: 6px; cursor: default; }
table.attn tr.grp .count { margin-left: 6px; }
table.attn td.due-cell { text-align: right; font-size: 12px; line-height: 1.3; }
/* dashboard calendar */
.cal-nav { display: flex; align-items: center; gap: 4px; margin: -2px 0 6px; }
.cal-nav .icon-btn { min-width: 26px; height: 26px; font-size: 16px; line-height: 1; }
.cal-title { min-width: 130px; text-align: center; font-size: 13px; font-weight: 600; }
.cal-nav .btn.ghost { margin-left: auto; }
.cal-week, .cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-week span { font-size: 10.5px; font-weight: 600; color: var(--muted); text-align: center; padding-bottom: 3px; }
.cal-grid { border-top: 1px solid var(--line-2); border-left: 1px solid var(--line-2); }
.cal-cell { position: relative; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; height: 44px; padding: 3px 4px;
  border: 0; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); background: #fff; cursor: pointer; text-align: left; font: inherit; color: var(--ink); }
.cal-cell:hover { background: #f3f6fb; }
.cal-cell.other { background: #fafbfc; color: var(--faint); }
.cal-cell.today .cal-n { background: var(--accent); color: #fff; border-radius: 9px; padding: 0 5px; }
.cal-cell.sel { box-shadow: inset 0 0 0 2px var(--accent); }
.cal-n { font-size: 11.5px; font-weight: 600; line-height: 17px; }
.cal-dots { display: flex; align-items: center; gap: 2px; }
.cal-dots small { font-size: 10px; color: var(--muted); margin-left: 2px; }
.cal-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; flex: none; }
.cal-dot.late { background: #dc2626; }
.cal-dot.due { background: #f59e0b; }
.cal-dot.expires { background: #2f7bea; }
.cal-dot.meeting { background: #7c3aed; }
.cal-legend { display: flex; gap: 12px; flex-wrap: wrap; margin: 6px 0 0; font-size: 11px; color: var(--muted); }
.cal-legend span { display: inline-flex; align-items: center; gap: 4px; }
.cal-day { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line-2); }
.cal-day-head { font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.cal-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; font-size: 12.5px; }
.cal-list li { display: flex; align-items: center; gap: 6px; min-width: 0; }
.cal-list a { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-what { color: var(--muted); white-space: nowrap; }
.cal-links { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0 12px; }
.outlook-dlg p { margin: 0 0 10px; }
details.dash-fold { padding: 0; }
details.dash-fold > summary { display: flex; align-items: center; gap: 8px; padding: 10px 14px; cursor: pointer; list-style: none; }
details.dash-fold > summary::-webkit-details-marker { display: none; }
details.dash-fold > summary::before { content: "▸"; color: var(--muted); font-size: 11px; width: 10px; }
details.dash-fold[open] > summary::before { content: "▾"; }
details.dash-fold > summary h2 { margin: 0; }
details.dash-fold[open] > summary { border-bottom: 1px solid var(--line-2); }
details.dash-fold > :not(summary) { margin: 0; padding: 8px 14px 12px; }
details.dash-fold .activity { list-style: none; display: grid; gap: 5px; font-size: 12.5px; }
#attention .card-head .link, #expiring .card-head .link { font-size: 12.5px; font-weight: 600; }
@media (max-width: 760px) { .dash-stats .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .dash-grid { grid-template-columns: 1fr; } }

/* one record */
.rec-head { gap: 3px 12px; margin-bottom: 10px; }
.rec-title { gap: 8px; }
.rec-title h1 { font-size: 20px; }
.rec-sub { font-size: 13px; }
.rec-meta { font-size: 11.5px; }
.rec-actions { gap: 6px; }
.rec-bottom { padding: 8px 12px; gap: 8px; }

/* dialogs */
dialog.dlg { border-radius: 6px; box-shadow: 0 24px 60px rgba(17, 24, 39, .3); }
dialog.dlg::backdrop { background: rgba(17, 24, 39, .4); }
.dlg-hd { padding: 10px 16px; font-size: 15px; font-weight: 600; }
.dlg-bd { padding: 14px 16px; }
.dlg-bd .field + .field { margin-top: 10px; }
.dlg-ft { padding: 10px 16px; gap: 8px; border-radius: 0 0 6px 6px; }

/* sign-in */
.auth-card { border-radius: 6px; }

@media (min-width: 981px) { .brand-name { display: inline; } }

/* ---------- small screens: the menu bar folds into the menu button ---------- */
@media (max-width: 980px) {
  .menubar, .mega-host { display: none; }
  .hamburger { display: inline-flex; }
  .goto { flex: 0 0 auto; margin-left: auto; }
  .goto > span, .goto kbd { display: none; }
  .mobile-nav { top: var(--header-h); }
  .mobile-nav a { padding: 6px; border-radius: var(--radius-sm); font-weight: 600; }
  .mobile-nav .page-icon { width: 26px; height: 26px; border-radius: 4px; }
  main { padding: 12px 12px 48px; }
  h1 { font-size: 18px; }
  .page-head h1, .rec-title h1 { font-size: 18px; }
}
@media (max-width: 560px) {
  .company-pill { max-width: 150px; }
  .brand-name { display: none; }
}
@media print {
  .chrome, .navwrap, .mega-panel, .pal-overlay { display: none !important; }
}

/* internal audit: "What to check" under each SQF element */
table.data.audit td { vertical-align: top; }
table.data.audit td.el { width: 38%; min-width: 260px; font-weight: 400; }
table.data.audit td.el > b { font-weight: 600; }
table.data.audit textarea { min-height: 54px; }
details.el-guide { margin-top: 4px; }
details.el-guide > summary { cursor: pointer; color: var(--accent); font-size: 11.5px; list-style: none; user-select: none; }
details.el-guide > summary::-webkit-details-marker { display: none; }
details.el-guide > summary::before { content: '\25B8  '; }
details.el-guide[open] > summary::before { content: '\25BE  '; }
details.el-guide ul, .guide-box ul { margin: 4px 0 0; padding-left: 16px; color: var(--ink-2, #3b4554); font-size: 12px; line-height: 1.45; }
details.el-guide li, .guide-box li { margin: 1px 0; }
.guide-box { background: #f5f8fc; border: 1px solid #dbe4ef; border-radius: var(--radius); padding: 8px 12px; margin: 0 0 12px; }
.guide-box > b { font-size: 12px; }
@media print { details.el-guide ul { display: block; } }

/* meeting minutes: "what to review" note under a standard agenda item */
.row-guide { margin-top: 3px; color: var(--ink-3, #5b6575); font-size: 11.5px; line-height: 1.35; }
.row-guide:empty { display: none; }

/* list pages: one Filters button with a drop-down panel, and a tag for each filter in use */
.filter-wrap { position: relative; }
.filter-btn { gap: 6px; }
.filter-btn.on { border-color: var(--accent); color: var(--accent); background: #eef4fc; }
.filter-btn .count { background: var(--accent); color: #fff; border-radius: 9px; padding: 0 6px; font-size: 11px; line-height: 16px; min-width: 16px; text-align: center; }
.filter-pop { position: absolute; z-index: 40; top: calc(100% + 6px); left: 0; width: min(560px, calc(100vw - 32px)); background: #fff;
  border: 1px solid var(--line, #d7dde5); border-radius: var(--radius); box-shadow: 0 10px 28px rgba(16, 32, 56, .16); padding: 12px 14px; }
.filter-pop[hidden] { display: none; }
.fp-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 4px 0 10px; border-bottom: 1px solid #eef1f5; margin-bottom: 10px; }
.fp-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-3, #5b6575); min-width: 54px; }
.fp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.fp-field { display: flex; flex-direction: column; gap: 3px; }
.fp-field select { width: 100%; }
.fp-field select.set { border-color: var(--accent); }
.fp-foot { display: flex; justify-content: space-between; gap: 8px; margin-top: 12px; padding-top: 10px; border-top: 1px solid #eef1f5; }
.ftags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ftag { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 4px 0 9px; border-radius: 12px; background: #eef4fc; color: #1d4f8f;
  border: 1px solid #cfe0f5; font-size: 12px; white-space: nowrap; }
.ftag:not(:has(.ftag-x)) { padding-right: 9px; }
.ftag-x { border: 0; background: transparent; color: inherit; cursor: pointer; width: 18px; height: 18px; border-radius: 50%; font-size: 14px; line-height: 1; padding: 0; }
.ftag-x:hover { background: #d6e5f8; }
@media (max-width: 560px) { .fp-grid { grid-template-columns: 1fr; } }
@media print { .filter-wrap, .ftag-x { display: none !important; } }
.filterbar > .searchbox { flex: 0 1 340px; min-width: 200px; }
.filterbar > .fb-tools { margin-left: auto; }
table.grid-edit td:has(> .row-guide) { width: 42%; }

/* SQF modules picker (Add company, and SQF modules on Setup › Companies) */
.add-company .sub-head { margin: 14px 0 6px; padding-top: 10px; border-top: 1px solid var(--line-2); }
.mod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 6px; margin-bottom: 8px; }
.mod-opt { display: flex; gap: 8px; align-items: flex-start; padding: 7px 9px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; cursor: pointer; }
.mod-opt:hover { border-color: #aeb6c2; }
.mod-opt input { margin-top: 2px; flex: none; }
.mod-opt b { display: block; font-weight: 600; color: var(--ink-strong); }
.mod-opt small { display: block; color: var(--muted); font-size: 11.5px; line-height: 1.35; }
.mod-opt.on { border-color: var(--accent); background: var(--accent-soft); }
.mod-opt.off { opacity: .45; cursor: default; }
.mod-opt:has(input:disabled):not(.off) { cursor: default; }
.mod-none { margin: 4px 0 8px; }
.mod-picker .banner { margin-top: 6px; }
button.mod-cell { font-weight: 600; white-space: nowrap; }
button.mod-cell.unset { color: #a15c00; }
.mod-load { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 4px 0 8px; }
@media (max-width: 560px) { .mod-grid { grid-template-columns: 1fr; } }
