.treasury-overview { display: grid; gap: 1rem; }
.treasury-kpi-strip { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: hidden; }
.treasury-kpi-strip a {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: .25rem;
  min-width: 0;
  padding: .875rem 1rem;
  border-right: 1px solid var(--f-line);
  border-bottom: 1px solid var(--f-line);
  color: var(--f-ink);
}
.treasury-kpi-strip a::before { position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--treasury-kpi-accent); content: ''; }
.treasury-kpi-strip a:hover { background: var(--f-hover); }
.treasury-kpi-strip a:nth-child(2n) { border-right: 0; }
.treasury-kpi-strip a:nth-child(n+3) { border-bottom: 0; }
.treasury-kpi-label, .treasury-kpi-note { color: var(--f-muted); font-size: .75rem; }
.treasury-kpi-label { display: flex; align-items: center; gap: .375rem; font-weight: 500; }
.treasury-kpi-strip strong { font-family: var(--font-mono, 'IBM Plex Mono', monospace); font-size: clamp(1rem, 2vw, 1.5rem); font-weight: 600; letter-spacing: -.025em; overflow-wrap: anywhere; }
.treasury-kpi-strip strong small { padding-left: .25rem; color: var(--f-muted); font-family: var(--font-sans, inherit); font-size: .75rem; font-weight: 500; white-space: nowrap; }
.treasury-overview-grid, .treasury-overview-grid > div, .treasury-overview-grid > aside { display: grid; align-content: start; min-width: 0; gap: 1rem; }
.treasury-portlet { overflow: hidden; }
.treasury-portlet .he-panel-head a { color: var(--f-teal); font-size: .75rem; font-weight: 500; white-space: nowrap; }
.treasury-portlet .he-panel-head a:hover { text-decoration: underline; }
.treasury-launcher { display: grid; }
.treasury-launcher > section { min-width: 0; padding: .5rem; }
.treasury-launcher > section + section { border-top: 1px solid var(--f-line); }
.treasury-launcher h3 {
  padding: .25rem .5rem .375rem;
  color: var(--f-muted);
  font-size: .6875rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.treasury-launcher a, .treasury-overview-queue a { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.treasury-launcher a { padding: .5rem; border-radius: .125rem; }
.treasury-launcher a:hover, .treasury-overview-queue a:hover { background: var(--f-hover); }
.treasury-launcher a > span, .treasury-overview-queue a > span:first-child { flex: 1; min-width: 0; }
.treasury-launcher strong, .treasury-overview-queue strong { display: block; overflow: hidden; font-size: .8125rem; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.treasury-launcher strong { color: var(--f-teal); }
.treasury-launcher a:hover strong { text-decoration: underline; }
.treasury-launcher small, .treasury-overview-queue small { display: block; overflow: hidden; color: var(--f-muted); font-size: .75rem; text-overflow: ellipsis; white-space: nowrap; }
.treasury-launcher b { min-width: 2.25rem; padding: .125rem .375rem; border-radius: .125rem; background: var(--f-fill); font-size: .75rem; font-weight: 600; text-align: center; }
.treasury-launcher b.urgent { background: color-mix(in oklch, var(--destructive) 10%, var(--f-surface)); color: var(--destructive); }
.treasury-launcher a svg { opacity: 0; color: var(--f-muted); }
.treasury-launcher a:hover svg, .treasury-launcher a:focus-visible svg { opacity: 1; }
.treasury-overview-queue { margin: 0; padding: 0; list-style: none; }
.treasury-overview-queue li + li { border-top: 1px solid var(--f-line); }
.treasury-overview-queue a { padding: .625rem .875rem; }
.treasury-queue-amount, .treasury-list-money, .treasury-document-ref {
  font-family: var(--font-mono, 'IBM Plex Mono', monospace);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.treasury-queue-amount { font-size: .8125rem; font-weight: 500; }
.treasury-queue-empty { padding: 1rem .875rem; color: var(--f-muted); font-size: .8125rem; }
.treasury-view .f-panelhead h2 { font-size: .8125rem; }
.treasury-view .f-panel > .treasury-tabs { margin: 0; }
.treasury-view .f-panel > .f-actions { padding: .5rem .875rem; }
.treasury-student-statement { padding-bottom: .875rem; }
.treasury-student-statement > .f-pairs { padding: .625rem .875rem; }
.treasury-student-statement > .f-pairs + .f-pairs { border-top: 1px solid var(--f-line); }
.treasury-student-statement .f-subhead { margin-top: 1.25rem; }
.treasury-document-ref { font-size: .75rem; }
.treasury-list-tools .btn { min-height: 2rem; padding-inline: .75rem; font-size: .8125rem; }
.treasury-search { position: relative; flex: 1 1 12rem; max-width: 20rem; padding: 0; }
.treasury-search svg { position: absolute; top: 50%; left: .5rem; color: var(--f-muted); transform: translateY(-50%); pointer-events: none; }
.treasury-view .treasury-search input[type=search] { width: 100%; padding-left: 1.75rem; }
.treasury-compare { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.5fr); gap: .875rem; }
.treasury-compare > aside { align-self: start; padding: .625rem; border: 1px solid var(--f-line); border-radius: .375rem; }
.treasury-compare > div { min-width: 0; }
.treasury-form-section { display: grid; gap: .75rem; padding: 1rem 0; border-bottom: 1px solid var(--f-line); }
.treasury-form-section:first-child { padding-top: 0; }
.treasury-form-section:last-child { border-bottom: 0; }
.treasury-form-section h3 { color: var(--f-muted); font-size: .6875rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.treasury-charge-heading, .treasury-charge-line { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.4fr); gap: .75rem; }
.treasury-charge-line { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.3fr) minmax(0, 1fr); }
.treasury-charge-total { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem .625rem; border-radius: .25rem; background: var(--f-fill); color: var(--f-muted); font-size: .8125rem; }
.treasury-charge-total strong { color: var(--f-ink); font-family: var(--font-mono, 'IBM Plex Mono', monospace); }
.he-record-drawer:has([data-charge-total]) { width: min(48rem, 100%); }
.workspace-task-foot .treasury-charge-total {
  display: grid;
  gap: .125rem;
  margin-right: auto;
  padding: 0;
  background: transparent;
  color: var(--muted-foreground);
  font-size: .75rem;
}
.workspace-task-foot .treasury-charge-total strong { color: var(--foreground); font-size: .875rem; white-space: nowrap; }
.workspace-task-fields .f-allocate { width: 110px; text-align: right; }
.workspace-task-fields [data-fee-rows], .workspace-task-fields [data-fee-total],
.workspace-task-fields [data-allocate-total], .workspace-task-fields .finance-view > h3 { margin-top: .875rem; }
.workspace-task-fields [data-allocate-search] { margin-top: .5rem; }
.workspace-task-fields .f-filter:has([data-allocate-search]) { padding: 0 0 .5rem; }

@media (min-width: 1024px) {
  .treasury-kpi-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .treasury-kpi-strip a, .treasury-kpi-strip a:nth-child(2n) { border-right: 1px solid var(--f-line); border-bottom: 0; }
  .treasury-kpi-strip a:last-child { border-right: 0; }
  .treasury-launcher { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .treasury-launcher > section:nth-child(2) { border-top: 0; }
  .treasury-launcher > section:nth-child(2n) { border-left: 1px solid var(--f-line); }
}
@media (min-width: 1280px) { .treasury-overview-grid { grid-template-columns: minmax(0, 1fr) 340px; } }
@media (max-width: 720px) {
  .treasury-compare, .workspace-task-fields .f-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 500px) {
  .treasury-kpi-strip a { padding: .75rem; }
  .treasury-charge-heading, .treasury-charge-line { grid-template-columns: minmax(0, 1fr); }
  .workspace-task-foot:has(.treasury-charge-total) { flex-wrap: wrap; }
}
@media print {
  body:has(.treasury-student-statement) .he-page-header { display: none !important; }
  .treasury-student-statement .f-pairs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .treasury-student-statement .f-subhead { break-after: avoid; }
  .treasury-student-statement .f-table { overflow: visible; }
  .treasury-student-statement .f-table table { min-width: 0; }
}
