/* ESS portal — "logbook" theme.
   Cool paper, one ballpoint-blue ink accent, ruled rows, borders instead of shadows. */

:root {
  --paper: #f5f6f3;
  --surface: #ffffff;
  --ink: #18212d;
  --ink-2: #485263;
  --ink-3: #788292;
  --rule: #dde1e5;
  --rule-strong: #c2c8d0;
  --blue: #2347a8;
  --blue-deep: #193785;
  --blue-soft: #e9eefb;
  --margin: #d8a19c;          /* faded red margin rule of a logbook page */
  --ok: #2b7a4b;   --ok-soft: #e5f2ea;
  --warn: #9a620c; --warn-soft: #fbf0db;
  --bad: #b3261e;  --bad-soft: #fbe8e6;
  --muted-soft: #eef0f2;
  --radius: 8px;
  --radius-lg: 12px;
  --font: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --sidebar: 248px;
  --topbar: 56px;
  --bottombar: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 16px/1.5 var(--font); font-variant-numeric: tabular-nums;
}
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--blue-deep); }
h1, h2, h3 { line-height: 1.2; margin: 0; font-weight: 700; }
h1 { font-size: 1.5rem; letter-spacing: -0.01em; }
h2 { font-size: 1.1875rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 0.75rem; }
small, .small { font-size: 0.8125rem; }
.muted { color: var(--ink-3); }
.ink2 { color: var(--ink-2); }
.num { text-align: right; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--blue) 45%, transparent); outline-offset: 2px; }
svg.i { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ------------------------------------------------------------ top bar */
.topbar {
  position: sticky; top: 0; z-index: 30; height: var(--topbar);
  display: flex; align-items: center; gap: 12px; padding: 0 16px;
  background: var(--surface); border-bottom: 1px solid var(--rule);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 7px; background: var(--blue); color: #fff;
  display: grid; place-items: center; font-size: 15px; letter-spacing: -0.02em;
}
.brand-sub { font-weight: 400; color: var(--ink-3); }
.topbar .spacer { flex: 1; }
.iconbtn {
  position: relative; display: inline-grid; place-items: center; width: 40px; height: 40px;
  border-radius: 10px; border: 0; background: transparent; color: var(--ink-2); cursor: pointer; text-decoration: none;
}
.iconbtn:hover { background: var(--muted-soft); color: var(--ink); }
.badge-dot {
  position: absolute; top: 4px; right: 3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--bad); color: #fff; font-size: 11px; line-height: 18px; text-align: center; font-weight: 700;
}
.who { font-size: 0.875rem; color: var(--ink-2); text-align: right; line-height: 1.2; }
.who b { display: block; color: var(--ink); font-weight: 600; }

/* ------------------------------------------------------------ employee shell */
.shell-emp main { max-width: 760px; margin: 0 auto; padding: 20px 16px calc(var(--bottombar) + 28px); }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: var(--bottombar);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--surface); border-top: 1px solid var(--rule);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabbar a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--ink-3); text-decoration: none; font-size: 0.75rem; position: relative;
}
.tabbar a.on { color: var(--blue); font-weight: 700; }
.tabbar a.on::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 3px; border-radius: 0 0 3px 3px; background: var(--blue); }
.tabbar .badge-dot { top: 6px; right: calc(50% - 22px); }
@media (min-width: 900px) {
  .tabbar { position: sticky; top: var(--topbar); bottom: auto; height: 48px; grid-template-columns: none;
            display: flex; justify-content: center; gap: 4px; border-top: 0; border-bottom: 1px solid var(--rule); }
  .tabbar a { flex-direction: row; gap: 8px; padding: 0 16px; font-size: 0.9375rem; }
  .tabbar a.on::before { top: auto; bottom: 0; left: 12px; right: 12px; border-radius: 3px 3px 0 0; }
  .tabbar .badge-dot { position: static; }
  .shell-emp main { padding-bottom: 48px; }
}

/* ------------------------------------------------------------ admin shell */
.shell-admin .layout { display: flex; min-height: calc(100vh - var(--topbar)); }
.sidebar {
  width: var(--sidebar); flex: none; background: var(--surface); border-right: 1px solid var(--rule);
  padding: 12px 10px 40px; position: sticky; top: var(--topbar); height: calc(100vh - var(--topbar)); overflow-y: auto;
}
.sidebar .grp { margin: 14px 10px 4px; font-size: 0.8125rem; color: var(--ink-3); }
.sidebar a {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px;
  color: var(--ink-2); text-decoration: none; font-size: 0.9375rem;
}
.sidebar a:hover { background: var(--muted-soft); color: var(--ink); }
.sidebar a.on { background: var(--blue-soft); color: var(--blue-deep); font-weight: 700; }
.sidebar a .count { margin-left: auto; font-size: 0.75rem; background: var(--warn-soft); color: var(--warn); border-radius: 10px; padding: 0 7px; font-weight: 700; }
.shell-admin main { flex: 1; min-width: 0; padding: 24px 28px 64px; }
.menu-toggle { display: none; }
@media (max-width: 899px) {
  .menu-toggle { display: inline-grid; }
  .sidebar { position: fixed; z-index: 40; left: 0; top: var(--topbar); transform: translateX(-102%);
             transition: transform .18s ease; box-shadow: 0 0 0 100vmax transparent; }
  body.menu-open .sidebar { transform: none; box-shadow: 0 0 0 100vmax rgba(24, 33, 45, .35); }
  .shell-admin main { padding: 18px 16px 56px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ------------------------------------------------------------ page header */
.pagehead { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; margin-bottom: 20px; }
.pagehead .titles { flex: 1 1 260px; min-width: 0; }
.pagehead p { margin: 4px 0 0; color: var(--ink-2); }
.pagehead .actions { display: flex; flex-wrap: wrap; gap: 8px; }
.crumb { font-size: 0.875rem; margin-bottom: 6px; }
.crumb a { color: var(--ink-3); text-decoration: none; }
.crumb a:hover { color: var(--blue); }

/* ------------------------------------------------------------ surfaces */
.panel { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-lg); padding: 18px; margin-bottom: 18px; }
.panel > h2, .panel > .panel-head { margin-bottom: 12px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.panel.flush { padding: 0; overflow: hidden; }
.panel.flush > .panel-head { padding: 14px 18px 0; }
.section-title { font-size: 1.0625rem; margin: 28px 0 10px; }
.grid2 { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); margin-bottom: 18px; }
.grid2 > .panel { margin-bottom: 0; }
.stack > * + * { margin-top: 12px; }

/* Ledger strip: a row of figures separated by rules (instead of a card grid) */
.ledger {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-lg); margin-bottom: 18px; overflow: hidden;
}
.ledger .fig { padding: 14px 16px; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin: 0 -1px -1px 0; }
.ledger .fig b { display: block; font-size: 1.5rem; line-height: 1.2; font-weight: 700; letter-spacing: -0.01em; }
.ledger .fig span { display: block; font-size: 0.8125rem; color: var(--ink-2); margin-top: 2px; }
.ledger .fig em { display: block; font-style: normal; font-size: 0.8125rem; color: var(--ink-3); }
.ledger .fig.alert b { color: var(--bad); }
.ledger .fig.good b { color: var(--ok); }
.ledger .fig a { color: inherit; text-decoration: none; }
.ledger .fig a:hover b { color: var(--blue); }

/* ------------------------------------------------------------ tables */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.t { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
table.t th { text-align: left; font-weight: 600; color: var(--ink-2); font-size: 0.8125rem; padding: 10px 12px;
             border-bottom: 1px solid var(--rule-strong); white-space: nowrap; background: var(--surface); }
table.t td { padding: 10px 12px; border-bottom: 1px solid var(--rule); vertical-align: top; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr:hover td { background: #fafbfc; }
table.t td.num, table.t th.num { text-align: right; }
table.t tfoot td { font-weight: 700; border-top: 1px solid var(--rule-strong); border-bottom: 0; }
table.t .sub { display: block; color: var(--ink-3); font-size: 0.8125rem; }
table.t tr.row-full td { background: var(--bad-soft); }
table.t tr.row-high td { background: var(--warn-soft); }
table.t tr.row-muted td { color: var(--ink-3); }
.panel.flush table.t th:first-child, .panel.flush table.t td:first-child { padding-left: 18px; }
.panel.flush table.t th:last-child, .panel.flush table.t td:last-child { padding-right: 18px; }
.empty { padding: 28px 18px; text-align: center; color: var(--ink-2); }
.empty b { display: block; color: var(--ink); margin-bottom: 4px; }

/* Card list for phones */
.list { list-style: none; margin: 0; padding: 0; }
.list > li { border-bottom: 1px solid var(--rule); }
.list > li:last-child { border-bottom: 0; }
.list a.item, .list .item { display: flex; gap: 12px; align-items: flex-start; padding: 14px 18px; color: inherit; text-decoration: none; }
.list a.item:hover { background: #fafbfc; }
.item .grow { flex: 1; min-width: 0; }
.item .title { font-weight: 600; }
.item .meta { color: var(--ink-3); font-size: 0.875rem; }
.item .right { text-align: right; white-space: nowrap; }

/* ------------------------------------------------------------ status chips */
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: 0.8125rem;
        font-weight: 600; white-space: nowrap; background: var(--muted-soft); color: var(--ink-2); }
.chip.ok { background: var(--ok-soft); color: var(--ok); }
.chip.warn { background: var(--warn-soft); color: var(--warn); }
.chip.bad { background: var(--bad-soft); color: var(--bad); }
.chip.info { background: var(--blue-soft); color: var(--blue-deep); }

/* ------------------------------------------------------------ meters */
.meter { position: relative; height: 8px; border-radius: 4px; background: var(--muted-soft); overflow: hidden; min-width: 80px; }
.meter > i { position: absolute; inset: 0 auto 0 0; background: var(--blue); border-radius: 4px; }
.meter > i.inv { background: var(--ink-3); }
.meter.high > i { background: var(--warn); }
.meter.full > i { background: var(--bad); }
.meter-label { display: flex; justify-content: space-between; font-size: 0.8125rem; color: var(--ink-2); margin-top: 4px; gap: 8px; }

/* Horizontal bar chart */
.bars { display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: minmax(110px, 34%) 1fr auto; gap: 10px; align-items: center; font-size: 0.875rem; }
.bar-row .lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.bar-track { display: flex; height: 14px; background: var(--muted-soft); border-radius: 4px; overflow: hidden; }
.bar-track > i { display: block; height: 100%; }
.bar-track .s-inv { background: var(--ink-3); }
.bar-track .s-cons { background: var(--blue); }
.bar-track .s-left { background: #b9c7ec; }
.bar-track .s-out { background: var(--bad); }
.bar-track .s-ok { background: var(--ok); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.8125rem; color: var(--ink-2); margin-bottom: 12px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }

/* ------------------------------------------------------------ forms */
.form { display: grid; gap: 14px; }
.form .row { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > label, .lbl-text { font-size: 0.875rem; font-weight: 600; color: var(--ink-2); }
.field .hint { font-size: 0.8125rem; color: var(--ink-3); }
.req::after { content: " *"; color: var(--bad); }
input:not([type]), input[type=text], input[type=password], input[type=email], input[type=number], input[type=date],
input[type=tel], input[type=search], input[type=month], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--rule-strong); border-radius: var(--radius); padding: 9px 11px; min-height: 42px;
}
textarea { min-height: 84px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
input:disabled, select:disabled, textarea:disabled { background: var(--muted-soft); color: var(--ink-3); }
input[type=file] { font: inherit; font-size: 0.9375rem; }
.check { display: flex; align-items: center; gap: 8px; font-size: 0.9375rem; }
.check input { width: 18px; height: 18px; accent-color: var(--blue); }
.checks { display: grid; gap: 6px 16px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding-top: 4px; }
.field-error { color: var(--bad); font-size: 0.8125rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 16px;
  border-radius: var(--radius); border: 1px solid var(--blue); background: var(--blue); color: #fff;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn:hover { background: var(--blue-deep); border-color: var(--blue-deep); color: #fff; }
.btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--rule-strong); }
.btn.secondary:hover { border-color: var(--ink-3); background: #fafbfc; color: var(--ink); }
.btn.danger { background: var(--surface); color: var(--bad); border-color: #e7b9b4; }
.btn.danger:hover { background: var(--bad-soft); }
.btn.ok { background: var(--ok); border-color: var(--ok); }
.btn.ok:hover { background: #20603a; }
.btn.small { min-height: 34px; padding: 0 11px; font-size: 0.875rem; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--blue); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.linkbtn.danger { color: var(--bad); }
form.inline { display: inline; }

/* Filters bar */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-bottom: 16px; }
.filters .field { flex: 1 1 150px; max-width: 240px; }
.filters .btn { flex: none; }

/* ------------------------------------------------------------ flash */
.flashes { display: grid; gap: 8px; margin-bottom: 16px; }
.flash { padding: 11px 14px; border-radius: var(--radius); border: 1px solid; font-size: 0.9375rem; }
.flash.ok { background: var(--ok-soft); border-color: #bcdcc8; color: #1f5a37; }
.flash.error { background: var(--bad-soft); border-color: #efc1bc; color: #8a1d16; }
.flash.info { background: var(--blue-soft); border-color: #c7d3f3; color: var(--blue-deep); }
.flash.warn { background: var(--warn-soft); border-color: #ecd3a5; color: #774a07; }
.note { padding: 12px 14px; border-radius: var(--radius); background: var(--muted-soft); color: var(--ink-2); font-size: 0.9375rem; }
.note.warn { background: var(--warn-soft); color: #774a07; }
.note.bad { background: var(--bad-soft); color: #8a1d16; }
.note.info { background: var(--blue-soft); color: var(--blue-deep); }

/* ------------------------------------------------------------ login */
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card .brand { margin-bottom: 28px; font-size: 1.0625rem; }
.auth-card h1 { margin-bottom: 6px; }
.auth-card .panel { padding: 22px; }

/* ------------------------------------------------------------ logbook (timesheet week) */
.weeknav { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.weeknav .range { flex: 1; text-align: center; font-weight: 700; }
.weeknav .range small { display: block; font-weight: 400; color: var(--ink-3); }
.logbook { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-lg); overflow: hidden; }
.logday { display: grid; grid-template-columns: 64px 1fr; position: relative; border-bottom: 1px solid var(--rule); }
.logday:last-child { border-bottom: 0; }
.logday::after { /* the margin rule */
  content: ""; position: absolute; top: 0; bottom: 0; left: 64px; width: 0; border-left: 2px solid var(--margin); opacity: .7;
}
.logday .date { padding: 14px 6px 12px; text-align: center; line-height: 1.1; }
.logday .date b { display: block; font-size: 1.5rem; font-weight: 700; }
.logday .date span { display: block; font-size: 0.75rem; color: var(--ink-3); margin-top: 3px; }
.logday.today .date b { color: var(--blue); }
.logday .entry { padding: 12px 14px 14px 18px; display: grid; gap: 10px; min-width: 0; }
.logday .entry .dayhead { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 22px; }
.logday .entry .dayhead .tag { font-size: 0.8125rem; color: var(--ink-2); }
.entry-grid { display: grid; gap: 10px; grid-template-columns: 1fr 96px; }
.entry-grid .wide { grid-column: 1 / -1; order: 3; }
@media (min-width: 620px) { .entry-grid { grid-template-columns: 170px 1fr 96px; } .entry-grid .wide { grid-column: auto; order: 0; } }
.entry-foot { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.entry-foot input { flex: 1 1 220px; min-height: 38px; padding: 7px 10px; font-size: 0.9375rem; }
.day-error { color: var(--bad); font-size: 0.875rem; font-weight: 600; }
.hours-input { text-align: center; font-weight: 700; font-size: 1.0625rem; }
/* GMP practice: unused space is struck through with a single diagonal line */
.logday.struck .entry { background:
  linear-gradient(to top right, transparent calc(50% - 1px), var(--rule-strong) calc(50% - 0.5px), var(--rule-strong) calc(50% + 0.5px), transparent calc(50% + 1px)); }
.logday.struck .entry .optin { background: var(--surface); }
.logday.future { color: var(--ink-3); }
.logday.future .entry { background: repeating-linear-gradient(0deg, transparent 0 27px, #eef0f2 27px 28px); }
.logday.locked .entry { background: #fafbfc; }
.lockline { display: flex; gap: 8px; align-items: center; font-size: 0.875rem; color: var(--ink-2); }
.optin summary { cursor: pointer; color: var(--blue); font-size: 0.875rem; list-style: none; display: inline-block; }
.optin summary::-webkit-details-marker { display: none; }
.optin[open] summary { margin-bottom: 10px; }
.savebar {
  position: sticky; bottom: calc(var(--bottombar) + 8px); z-index: 10; margin-top: 14px;
  display: flex; gap: 10px; align-items: center; justify-content: space-between;
  background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--radius-lg); padding: 10px 12px 10px 16px;
}
@media (min-width: 900px) { .savebar { bottom: 12px; } }
.savebar .msg { font-size: 0.875rem; color: var(--ink-2); }

/* ------------------------------------------------------------ attendance register (admin) */
.register { border-collapse: separate; border-spacing: 0; font-size: 0.8125rem; }
.register th, .register td { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 5px 4px; text-align: center; min-width: 34px; }
.register th { background: var(--surface); position: sticky; top: 0; z-index: 2; font-weight: 600; color: var(--ink-2); }
.register th.name, .register td.name { position: sticky; left: 0; z-index: 3; background: var(--surface); text-align: left; min-width: 170px; padding: 6px 10px; }
.register td.name .sub { display: block; color: var(--ink-3); font-size: 0.75rem; }
.register th.wk { background: #f3f4f6; }
.register td.c-P { color: var(--ink); font-weight: 600; }
.register td.c-O { color: var(--blue-deep); background: var(--blue-soft); }
.register td.c-L { color: var(--warn); background: var(--warn-soft); font-weight: 700; }
.register td.c-H { color: var(--ink-3); background: #f0f1f3; }
.register td.c-W { color: var(--ink-3); background: #f6f7f8; }
.register td.c-M { color: var(--bad); background: #fff7f6; }
.register td.out { box-shadow: inset 0 -3px 0 var(--bad); }
.register td.inv { box-shadow: inset 0 -3px 0 var(--ok); }
.register td.tot { font-weight: 700; background: #fafbfc; min-width: 54px; }
.register td a { color: inherit; text-decoration: none; display: block; }

/* ------------------------------------------------------------ misc */
.kv { display: grid; grid-template-columns: minmax(120px, 38%) 1fr; gap: 8px 14px; margin: 0; font-size: 0.9375rem; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.balance-big { display: flex; align-items: baseline; gap: 10px; }
.balance-big b { font-size: 2.5rem; line-height: 1; font-weight: 700; letter-spacing: -0.02em; }
.pill-tabs { display: inline-flex; gap: 4px; background: var(--muted-soft); padding: 4px; border-radius: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.pill-tabs a { padding: 6px 12px; border-radius: 7px; color: var(--ink-2); text-decoration: none; font-size: 0.9375rem; }
.pill-tabs a.on { background: var(--surface); color: var(--ink); font-weight: 700; box-shadow: 0 0 0 1px var(--rule); }
.divider { height: 1px; background: var(--rule); margin: 16px 0; border: 0; }
.hl { background: var(--warn-soft); }
.thumb { max-width: 100%; max-height: 420px; border: 1px solid var(--rule); border-radius: var(--radius); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.8125rem; }
.pager { display: flex; gap: 8px; justify-content: flex-end; margin-top: 12px; }
.dash-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); margin-bottom: 18px; }
.dash-grid > .panel { margin-bottom: 0; }
.trend { width: 100%; height: 170px; }
.trend .axis { stroke: var(--rule); stroke-width: 1; }
.trend text { fill: var(--ink-3); font-size: 11px; font-family: var(--font); }
.trend .col-a { fill: var(--blue); }
.trend .col-b { fill: #b9c7ec; }
.err-page { max-width: 480px; margin: 12vh auto; padding: 0 16px; }
.err-page b { font-size: 3rem; color: var(--rule-strong); display: block; line-height: 1; }
@media print {
  .topbar, .sidebar, .tabbar, .savebar, .actions, .filters, .menu-toggle { display: none !important; }
  .shell-admin main, .shell-emp main { padding: 0; }
  .panel { break-inside: avoid; }
}

/* Claim review: one block per expense, stacks on phones */
.review-line { display: grid; gap: 10px 16px; padding: 14px 18px; grid-template-columns: 1fr auto; align-items: end; }
.review-line .rl-info { grid-column: 1 / -1; }
.review-line .rl-claimed b, .review-line .rl-approve > b { display: block; font-size: 1.0625rem; }
.review-line .rl-approve input { text-align: right; }
.review-line .rl-remark { grid-column: 1 / -1; }
.review-total { background: #fafbfc; }
@media (min-width: 760px) {
  .review-line { grid-template-columns: minmax(220px, 1fr) 120px 140px minmax(160px, 220px); }
  .review-line .rl-info, .review-line .rl-remark { grid-column: auto; }
}
table.t.first-wide td:first-child, table.t.first-wide th:first-child { min-width: 190px; }
table.t.compact td, table.t.compact th { padding: 9px 9px; }
