/* Invoice Gateway admin — the CRM design system (shadcn-admin, slate theme) in plain CSS.
   Tokens are copied 1:1 from the CRM's theme.css; components mirror shadcn/ui sizes. */

@font-face { font-family: 'Inter'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/static/fonts/inter-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/static/fonts/inter-latin-ext-wght-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --radius: 0.625rem;
  --background: oklch(1 0 0);
  --foreground: oklch(0.129 0.042 264.695);
  --card: oklch(1 0 0);
  --card-foreground: oklch(0.129 0.042 264.695);
  --primary: oklch(0.208 0.042 265.755);
  --primary-foreground: oklch(0.984 0.003 247.858);
  --secondary: oklch(0.968 0.007 247.896);
  --secondary-foreground: oklch(0.208 0.042 265.755);
  --muted: oklch(0.968 0.007 247.896);
  --muted-foreground: oklch(0.554 0.046 257.417);
  --accent: oklch(0.968 0.007 247.896);
  --accent-foreground: oklch(0.208 0.042 265.755);
  --destructive: oklch(0.577 0.245 27.325);
  --border: oklch(0.929 0.013 255.508);
  --input: oklch(0.929 0.013 255.508);
  --ring: oklch(0.704 0.04 256.788);
  --sidebar: var(--background);
  --sidebar-foreground: var(--foreground);
  --sidebar-primary: var(--primary);
  --sidebar-primary-foreground: var(--primary-foreground);
  --sidebar-accent: var(--accent);
  --sidebar-accent-foreground: var(--accent-foreground);
  /* status colours from the CRM (PRO green, PRO+ blue, trial amber) */
  --ok: #158a40; --ok-bg: color-mix(in oklch, #22b455 15%, transparent);
  --info: #1e5cc4; --info-bg: color-mix(in oklch, #2f7cf6 14%, transparent);
  --warn: #9a6a00; --warn-bg: #fff4d6;
  --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
  --sidebar-width: 16rem;
  --font: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
.dark {
  --background: oklch(0.129 0.042 264.695);
  --foreground: oklch(0.984 0.003 247.858);
  --card: oklch(0.14 0.04 259.21);
  --card-foreground: oklch(0.984 0.003 247.858);
  --primary: oklch(0.929 0.013 255.508);
  --primary-foreground: oklch(0.208 0.042 265.755);
  --secondary: oklch(0.279 0.041 260.031);
  --secondary-foreground: oklch(0.984 0.003 247.858);
  --muted: oklch(0.279 0.041 260.031);
  --muted-foreground: oklch(0.704 0.04 256.788);
  --accent: oklch(0.279 0.041 260.031);
  --accent-foreground: oklch(0.984 0.003 247.858);
  --destructive: oklch(0.704 0.191 22.216);
  --border: oklch(1 0 0 / 10%);
  --input: oklch(1 0 0 / 15%);
  --ring: oklch(0.551 0.027 264.364);
  --ok: #5ee08e; --info: #8ab6ff; --warn: #ffd36b; --warn-bg: rgba(255, 196, 0, 0.15);
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; border-color: var(--border); }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100svh; font-family: var(--font); font-size: 0.875rem; line-height: 1.5;
  color: var(--foreground); background: var(--background); -webkit-font-smoothing: antialiased; font-feature-settings: 'cv11'; }
a { color: inherit; text-underline-offset: 4px; }
main a:not(.btn):not(.pill):not(.sb-btn):not([role='tab']) { color: var(--foreground); font-weight: 500; text-decoration: underline; text-decoration-color: color-mix(in oklch, var(--foreground) 30%, transparent); }
main a:not(.btn):hover { text-decoration-color: currentColor; }
h1, h2, h3 { margin: 0; }
h2 { font-size: 1.125rem; font-weight: 600; letter-spacing: -0.015em; margin: 24px 0 12px; }
p { margin: 0 0 8px; }
ul { margin: 0; }
b, strong { font-weight: 600; }
code, .mono { font-family: var(--mono); font-size: 0.8125rem; }
:not(pre) > code { background: var(--muted); border-radius: var(--radius-sm); padding: 0.1rem 0.3rem; }
.muted { color: var(--muted-foreground); font-weight: 400; }
.small { font-size: 0.8125rem; }
.icon { width: 1rem; height: 1rem; flex-shrink: 0; }
::selection { background: var(--primary); color: var(--primary-foreground); }
:focus-visible { outline: none; }
* { scrollbar-width: thin; scrollbar-color: var(--border) transparent; }

/* ---------- shell: inset sidebar ---------- */
body.app { background: var(--sidebar); }
.sidebar { position: fixed; inset-block: 0; left: 0; z-index: 40; width: var(--sidebar-width); display: flex; flex-direction: column;
  padding: 0.5rem; background: var(--sidebar); color: var(--sidebar-foreground); transition: width .2s linear, transform .2s ease-out; }
.sidebar-header, .sidebar-footer { padding: 0.5rem; }
.sidebar-content { flex: 1; overflow-y: auto; overflow-x: hidden; }
.sb-group { padding: 0.5rem; }
.sb-group-label { height: 2rem; display: flex; align-items: center; padding: 0 0.5rem; font-size: 0.75rem; font-weight: 500;
  color: color-mix(in oklch, var(--sidebar-foreground) 70%, transparent); white-space: nowrap; transition: opacity .2s, margin .2s; }
.sb-group ul { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 0.25rem; }
.sb-btn { display: flex; align-items: center; gap: 0.5rem; width: 100%; height: 2rem; padding: 0.5rem; border-radius: var(--radius-md);
  font-size: 0.875rem; text-decoration: none; color: inherit; white-space: nowrap; overflow: hidden; }
.sb-btn:hover, .sb-btn.active { background: var(--sidebar-accent); color: var(--sidebar-accent-foreground); }
.sb-btn.active { font-weight: 500; }
.sb-btn:focus-visible { box-shadow: 0 0 0 2px var(--ring); }
.sb-text { display: grid; flex: 1; min-width: 0; line-height: 1.25; text-align: start; }
.sb-text b, .sb-text small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-text b { font-weight: 600; font-size: 0.875rem; }
.sb-text small { font-size: 0.75rem; }
.sb-lg { height: 3rem; }
.brand-logo { display: flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; flex-shrink: 0;
  border-radius: var(--radius-lg); background: var(--sidebar-primary); color: var(--sidebar-primary-foreground); }
.sb-badge { margin-left: auto; min-width: 1.25rem; height: 1.25rem; padding: 0 0.3rem; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; background: var(--primary); color: var(--primary-foreground); font-size: 0.75rem; font-weight: 500; font-variant-numeric: tabular-nums; }
.sb-user { display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem; min-height: 3rem; }
.sb-user form { margin: 0; }
.avatar { width: 2rem; height: 2rem; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-lg); background: var(--muted); font-size: 0.75rem; font-weight: 600; }

.inset { position: relative; display: flex; flex-direction: column; min-height: 100svh; background: var(--background); }
.topbar { position: sticky; top: 0; z-index: 20; height: 4rem; display: flex; align-items: center; gap: 1rem; padding: 1rem;
  background: var(--background); transition: box-shadow .15s; }
.topbar.scrolled { box-shadow: var(--shadow); background: color-mix(in oklch, var(--background) 85%, transparent);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.vsep { width: 1px; height: 1.5rem; background: var(--border); }
.topbar-title { font-size: 1rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 0.5rem; }
.main { width: 100%; max-width: 80rem; margin: 0 auto; padding: 1.5rem 1rem; }
.page-head { margin-bottom: 1.5rem; }
.page-title { font-size: 1.5rem; line-height: 2rem; font-weight: 700; letter-spacing: -0.025em; }
.page-desc { margin: 0.25rem 0 0; color: var(--muted-foreground); font-size: 0.9375rem; }
.sidebar-backdrop { display: none; }
.dark .when-dark, :root:not(.dark) .when-light { display: block; }
.dark .when-light, :root:not(.dark) .when-dark { display: none; }

@media (min-width: 768px) {
  .inset { margin: 0.5rem 0.5rem 0.5rem var(--sidebar-width); min-height: calc(100svh - 1rem); border-radius: var(--radius-xl); box-shadow: var(--shadow-sm); }
  .topbar { border-radius: var(--radius-xl) var(--radius-xl) 0 0; }
  .main { padding: 1.5rem; }
  /* collapsed to icons */
  .sb-collapsed { --sidebar-width: calc(3rem + 1rem + 2px); }
  .sb-collapsed .sidebar .sb-text, .sb-collapsed .sidebar .sb-badge, .sb-collapsed .sidebar .avatar { display: none; }
  .sb-collapsed .sb-group-label { opacity: 0; margin-top: -2rem; pointer-events: none; }
  .sb-collapsed .sb-btn { width: 2rem; padding: 0.5rem; }
  .sb-collapsed .sb-lg { height: 2rem; padding: 0; }
  .sb-collapsed .sb-user { padding: 0.5rem 0; justify-content: center; }
}
@media (max-width: 767.98px) {
  .sidebar { width: 18rem; transform: translateX(-100%); border-right: 1px solid var(--border); box-shadow: var(--shadow-sm); background: var(--background); }
  .sb-open .sidebar { transform: none; }
  .sb-open .sidebar-backdrop { display: block; position: fixed; inset: 0; z-index: 30; background: rgb(0 0 0 / 0.5); }
  .topbar [data-sidebar-toggle] { transform: scale(1.15); }
  .topbar-right .pill { display: none; }
  input, select, textarea { font-size: 16px !important; }
}

/* ---------- card ---------- */
.card { background: var(--card); color: var(--card-foreground); border: 1px solid var(--border); border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm); padding: 1.5rem; margin: 0 0 1rem; }
.card > h2:first-child, .card-title { font-size: 1rem; font-weight: 600; line-height: 1.2; letter-spacing: normal; margin: 0 0 0.75rem; }
.card-header { display: grid; gap: 0.375rem; margin-bottom: 1.5rem; }
.card-header .card-title { margin: 0; font-size: 1.125rem; letter-spacing: -0.015em; }
.card-desc { margin: 0; color: var(--muted-foreground); font-size: 0.875rem; }
.card p:last-child { margin-bottom: 0; }
.card.narrow { max-width: 380px; }
.danger-card { border-color: color-mix(in oklch, var(--destructive) 45%, transparent); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); gap: 1rem; margin-bottom: 1rem; }
.grid .card { margin: 0; }
.stat { display: flex; flex-direction: column; gap: 0.25rem; padding: 1.25rem 1.5rem; }
.stat-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; padding-bottom: 0.5rem; }
.stat-title { font-size: 0.875rem; font-weight: 500; }
.stat-head .icon { color: var(--muted-foreground); }
.stat-value { font-size: 1.5rem; line-height: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-sub { font-size: 0.75rem; color: var(--muted-foreground); }
a.stat-sub { display: inline-flex; align-items: center; gap: 0.25rem; text-decoration: none !important; font-weight: 400 !important; color: var(--muted-foreground) !important; }
a.stat-sub:hover { color: var(--foreground) !important; }
a.stat-sub .icon { width: 0.75rem; height: 0.75rem; }
.stat.alert { border-color: color-mix(in oklch, var(--destructive) 45%, transparent); }
.stat.alert .stat-value, .stat.alert .stat-head .icon { color: var(--destructive); }
.split { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.split .card { margin: 0; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 0.5rem 1rem; align-items: center; margin: 0; }
.kv dt { color: var(--muted-foreground); }
.kv dd { margin: 0; display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 0.75rem; }

/* ---------- forms ---------- */
.row { display: flex; flex-wrap: wrap; gap: 0.75rem 1rem; align-items: flex-end; margin: 0 0 0.75rem; }
.row > label { flex: 1 1 12rem; margin: 0; }
.row > label.shrink { flex: 0 1 auto; }
.row.spread { justify-content: space-between; align-items: baseline; }
.row .grow, label.grow { flex: 3 1 16rem; }
form.inline { display: inline-flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; margin: 0; }
form { margin: 0; }
label { display: flex; flex-direction: column; gap: 0.5rem; margin: 0 0 1rem; font-size: 0.875rem; font-weight: 500; line-height: 1; }
label .muted { line-height: 1.4; }
label.check { flex-direction: row; align-items: center; gap: 0.625rem; font-weight: 400; line-height: 1.4; margin: 0 0 0.75rem; }
fieldset { border: 1px solid var(--border); border-radius: var(--radius-lg); margin: 0 0 1rem; padding: 0.75rem 1rem 0.25rem; }
legend { font-size: 0.875rem; font-weight: 500; padding: 0 0.375rem; }
input, select, textarea { font: inherit; font-size: 0.875rem; color: var(--foreground); background: transparent; height: 2.25rem; min-width: 0; max-width: 100%;
  padding: 0.25rem 0.75rem; border: 1px solid var(--input); border-radius: var(--radius-md); box-shadow: var(--shadow-xs);
  transition: color .15s, box-shadow .15s, border-color .15s; }
.dark input, .dark select, .dark textarea { background: color-mix(in oklch, var(--input) 30%, transparent); }
label > input, label > select, label > textarea, .field input { width: 100%; font-weight: 400; }
textarea { height: auto; padding: 0.5rem 0.75rem; line-height: 1.5; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--muted-foreground); }
input:focus-visible, select:focus-visible, textarea:focus-visible { border-color: var(--ring); box-shadow: 0 0 0 3px color-mix(in oklch, var(--ring) 50%, transparent); }
input[readonly] { background: var(--muted); }
select { appearance: none; -webkit-appearance: none; padding-right: 2rem; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 0.625rem center; }
input[type='checkbox'] { width: 1rem; height: 1rem; padding: 0; margin: 0; box-shadow: none; accent-color: var(--primary); flex-shrink: 0; cursor: pointer; }
.input-group { position: relative; }
.input-group input { width: 100%; padding-right: 2.5rem; }
.input-group .reveal { position: absolute; right: 0; top: 0; height: 100%; width: 2.5rem; border: 0; background: none; box-shadow: none; color: var(--muted-foreground); }
.input-group .reveal:hover { background: none; color: var(--foreground); }
.copy-row { display: flex; gap: 0.5rem; }
.copy-row input { flex: 1; }

/* ---------- buttons (default = outline, .primary, .danger, .ghost, .link) ---------- */
button, .btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; height: 2.25rem; padding: 0.5rem 1rem;
  font: inherit; font-size: 0.875rem; font-weight: 500; white-space: nowrap; text-decoration: none; cursor: pointer;
  color: var(--foreground); background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-md);
  box-shadow: var(--shadow-xs); transition: background .15s, color .15s, box-shadow .15s; }
.dark button, .dark .btn { background: color-mix(in oklch, var(--input) 30%, transparent); border-color: var(--input); }
button:hover, .btn:hover { background: var(--accent); color: var(--accent-foreground); }
button:focus-visible, .btn:focus-visible { border-color: var(--ring); box-shadow: 0 0 0 3px color-mix(in oklch, var(--ring) 50%, transparent); }
button.primary, .btn.primary { background: var(--primary); color: var(--primary-foreground); border-color: transparent; }
button.primary:hover, .btn.primary:hover { background: color-mix(in oklch, var(--primary) 90%, transparent); }
button.danger, .btn.danger { background: var(--destructive); color: #fff; border-color: transparent; }
.dark button.danger { background: color-mix(in oklch, var(--destructive) 60%, transparent); }
button.danger:hover { background: color-mix(in oklch, var(--destructive) 90%, transparent); }
button.ghost, .btn.ghost { background: transparent; border-color: transparent; box-shadow: none; }
button.ghost:hover, .btn.ghost:hover { background: var(--accent); }
button.link, .btn.link { background: none; border: 0; box-shadow: none; padding: 0; height: auto; color: var(--foreground); text-decoration: underline; text-decoration-color: color-mix(in oklch, var(--foreground) 30%, transparent); }
button.link:hover { background: none; text-decoration-color: currentColor; }
button.link.danger { color: var(--destructive); background: none; }
button.small, .btn.small { height: 2rem; padding: 0.25rem 0.75rem; gap: 0.375rem; }
button.icon-btn, .btn.icon-btn { width: 2.25rem; padding: 0; flex-shrink: 0; }
.block { display: flex; width: 100%; }
button:disabled { opacity: 0.5; pointer-events: none; }

/* ---------- table (data-table look) ---------- */
.table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-md); margin: 0 0 1rem; background: var(--card); }
.card .table-wrap { margin-bottom: 0.75rem; }
table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
th { height: 2.5rem; padding: 0 0.75rem; text-align: left; vertical-align: middle; font-weight: 500; white-space: nowrap; color: var(--foreground); border-bottom: 1px solid var(--border); }
td { padding: 0.625rem 0.75rem; vertical-align: middle; border-bottom: 1px solid var(--border); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: color-mix(in oklch, var(--muted) 50%, transparent); }
tr.inactive { opacity: 0.55; }
tr.warnrow td { background: color-mix(in oklch, var(--destructive) 6%, transparent); }
td.details { max-width: 26rem; word-break: break-all; color: var(--muted-foreground); }
table.lines td:last-child, table.lines td:nth-child(2) { white-space: nowrap; }
table.lines td:last-child { text-align: right; font-weight: 500; }
td input:not([type='checkbox']) { height: 2rem; }

/* ---------- badge ---------- */
.pill { display: inline-flex; align-items: center; gap: 0.25rem; width: fit-content; padding: 0.125rem 0.5rem; border: 1px solid transparent;
  border-radius: var(--radius-md); font-size: 0.75rem; font-weight: 500; line-height: 1rem; white-space: nowrap;
  background: var(--secondary); color: var(--secondary-foreground); text-decoration: none; vertical-align: middle; }
p.pill { white-space: normal; }
.pill .icon { width: 0.75rem; height: 0.75rem; }
.pill:empty { display: none; }
.pill.ok { background: var(--ok-bg); color: var(--ok); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.info { background: var(--info-bg); color: var(--info); }
.pill.bad { background: color-mix(in oklch, var(--destructive) 12%, transparent); color: var(--destructive); }

/* ---------- tabs ---------- */
.tabs { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 2px; min-height: 2.25rem; padding: 3px; margin: 0 0 1rem;
  border-radius: var(--radius-lg); background: var(--muted); color: var(--muted-foreground); }
.tabs a { display: inline-flex; align-items: center; gap: 0.375rem; height: 1.75rem; padding: 0.25rem 0.625rem; border-radius: var(--radius-md);
  font-size: 0.875rem; font-weight: 500; white-space: nowrap; text-decoration: none; color: inherit; border: 1px solid transparent; }
.tabs a:hover { color: var(--foreground); }
.tabs a.active { background: var(--background); color: var(--foreground); box-shadow: var(--shadow-sm); }
.dark .tabs a.active { background: color-mix(in oklch, var(--input) 30%, transparent); border-color: var(--input); }
.tabs .icon { width: 0.875rem; height: 0.875rem; }

/* ---------- alert ---------- */
.alert { display: grid; grid-template-columns: 1rem 1fr; gap: 0.75rem; align-items: start; margin: 0 0 1rem; padding: 0.75rem 1rem;
  border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--card); font-size: 0.875rem; }
.alert .icon { margin-top: 0.125rem; }
.alert.success { color: var(--ok); }
.alert.success div { color: var(--card-foreground); }
.alert.destructive { color: var(--destructive); }
.alert.destructive.strong { background: color-mix(in oklch, var(--destructive) 8%, var(--card)); border-color: color-mix(in oklch, var(--destructive) 40%, transparent); }
.reasons { list-style: none; margin: 0.75rem 0; padding: 0.75rem 1rem; border-radius: var(--radius-lg); background: var(--warn-bg); color: var(--warn); display: grid; gap: 0.25rem; }
.reasons li::before { content: '⚠ '; }
.reasons:empty { display: none; }

pre { white-space: pre-wrap; word-break: break-word; background: var(--muted); padding: 0.75rem 1rem; border-radius: var(--radius-md);
  border: 1px solid var(--border); max-height: 32rem; overflow: auto; margin: 0 0 0.75rem; font-size: 0.8125rem; }
details summary { cursor: pointer; font-weight: 500; margin: 0.5rem 0; }

/* ---------- invoice card (approvals) ---------- */
.inv-head { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; justify-content: space-between; align-items: flex-start; margin-bottom: 1rem; }
.inv-title { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; font-size: 1rem; font-weight: 600; }
.inv-total { font-size: 1.25rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.inv-meta { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; margin: 0 0 0.25rem; padding: 0; list-style: none; color: var(--muted-foreground); font-size: 0.8125rem; }
.inv-meta b { color: var(--foreground); font-weight: 500; }
.inv-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; padding-top: 1rem; margin-top: 1rem; border-top: 1px solid var(--border); }
.inv-actions form.inline input { width: 14rem; }
.empty { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; padding: 3rem 1rem; text-align: center; color: var(--muted-foreground); }
.empty .icon { width: 2rem; height: 2rem; }

/* ---------- auth & public pages ---------- */
body.auth { display: flex; }
.auth-wrap { width: 100%; max-width: 30rem; margin: auto; padding: 2rem 1rem; display: flex; flex-direction: column; align-items: center; }
.auth-brand { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; font-size: 1.25rem; font-weight: 500; }
.auth-brand .icon { width: 1.5rem; height: 1.5rem; }
.auth-card { width: 100%; max-width: 24rem; margin: 0; }
.auth-card label { margin-bottom: 1rem; }
.public-top { display: flex; align-items: center; gap: 0.75rem; height: 4rem; padding: 1rem 1.5rem; border-bottom: 1px solid var(--border); }
.public-top .auth-brand { margin: 0; font-size: 1rem; font-weight: 600; }
.public-top nav { margin-left: auto; display: flex; gap: 0.5rem; }
body.sandbox .main { max-width: 64rem; }
.reveal .icon + .icon, .reveal.on .icon:first-child { display: none; }
.reveal.on .icon + .icon { display: block; }
td form.inline { flex-wrap: nowrap; }
td input[size] { width: 7.5rem; }
