/* ===================================================
   Endowment Reporting Portal — app.css
   Episcopal Church inspired theme
   Episcopal Red · Charcoal · Warm off-white
   =================================================== */

:root {
  /* Episcopal Church palette */
  --ec-red:      #d31245;   /* signature Episcopal red */
  --ec-red-dark: #a50d35;   /* darker red for hovers */
  --ec-red-900:  #7d0a28;   /* deepest red */
  --ec-red-50:   #fdeef2;   /* faint red tint */
  --ec-red-100:  #fadce3;

  --charcoal-900:#1c1c20;   /* near-black charcoal */
  --charcoal-800:#26262c;
  --charcoal-700:#33333b;

  --gray-900:    #20232a;
  --gray-700:    #3d4451;
  --gray-500:    #5f6878;
  --gray-400:    #828c9e;
  --gray-300:    #a8b1c0;
  --gray-200:    #d5dae3;
  --gray-100:    #e9ecf2;
  --gray-50:     #f4f6fa;

  --white:       #ffffff;
  --cream:       #faf8f4;   /* warm off-white background */
  --body-bg:     #f4f2ed;

  --green:       #2e7d4f;
  --green-bg:    #e3f4ea;
  --amber:       #8a5a00;
  --amber-bg:    #fcf0d8;
  --red:         #b3122f;
  --red-bg:      #fbe0e5;

  --pos:         #2e7d4f;
  --neg:         #b3122f;

  --sidebar-w: 240px;
  --topbar-h:  56px;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;

  --shadow-sm: 0 1px 4px rgba(28,28,32,.08);
  --shadow-md: 0 4px 16px rgba(28,28,32,.1);
  --shadow-lg: 0 8px 32px rgba(28,28,32,.14);

  --font: 'DM Sans', system-ui, -apple-system, sans-serif;
  --mono: 'DM Mono', 'Fira Code', monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; }
body {
  font-family: var(--font);
  background: var(--body-bg);
  color: var(--gray-700);
  font-size: 14px; line-height: 1.6; margin: 0;
  -webkit-font-smoothing: antialiased;
}

/* ── Shell ───────────────────────────────────────── */
.shell { display: flex; min-height: 100vh; }

/* ── Sidebar ─────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--charcoal-900);
  display: flex; flex-direction: column;
  position: fixed; inset: 0 auto 0 0;
  z-index: 200; overflow-y: auto;
}
.sidebar-top    { flex: 1; padding-bottom: 12px; }
.sidebar-bottom { padding: 10px 0 16px; border-top: 1px solid rgba(255,255,255,.08); }

.brand {
  display: flex; align-items: center; gap: 11px;
  padding: 18px 16px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 8px;
}
.brand-mark {
  width: 38px; height: 38px; flex-shrink: 0;
  background: var(--ec-red);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; color: #fff;
  box-shadow: 0 4px 12px rgba(211,18,69,.5);
}
.brand-name    { font-size: 14px; font-weight: 700; color: #fff; line-height: 1.2; }
.brand-tagline { font-size: 11px; color: rgba(255,255,255,.45); }

.nav-group { padding: 4px 0; }
.nav-section-label {
  font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 1px; color: rgba(255,255,255,.35);
  padding: 8px 16px 3px; display: block;
}
.nav-link {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 16px;
  color: rgba(255,255,255,.65);
  text-decoration: none; font-size: 13.5px;
  border-right: 2px solid transparent;
  transition: background .12s, color .12s;
}
.nav-link:hover { background: rgba(255,255,255,.07); color: #fff; }
.nav-link.active {
  background: rgba(211,18,69,.22);
  color: #fff; font-weight: 600;
  border-right-color: var(--ec-red);
}
.nav-link-danger { color: #f0a0b0 !important; }
.nav-link-danger:hover { background: rgba(211,18,69,.18) !important; }

.user-card { display: flex; align-items: center; gap: 10px; padding: 10px 16px 6px; }
.user-avatar {
  width: 32px; height: 32px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.user-name { font-size: 12.5px; color: #fff; font-weight: 500; line-height: 1.2; }
.user-role { font-size: 11px; color: rgba(255,255,255,.45); }

/* ── Main ────────────────────────────────────────── */
.main { margin-left: var(--sidebar-w); flex: 1; display: flex; flex-direction: column; min-height: 100vh; }

.topbar {
  height: var(--topbar-h);
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 28px;
  position: sticky; top: 0; z-index: 100;
  box-shadow: var(--shadow-sm);
}
.topbar-left { display: flex; align-items: center; gap: 8px; }
.breadcrumb-dot { width: 8px; height: 8px; background: var(--green); border-radius: 50%; box-shadow: 0 0 6px rgba(46,125,79,.5); }
.topbar-label { font-size: 12.5px; color: var(--gray-400); font-family: var(--mono); }
.db-badge {
  font-size: 12px; color: var(--gray-500);
  display: flex; align-items: center; gap: 6px;
  background: var(--gray-50); border: 1px solid var(--gray-200);
  border-radius: 20px; padding: 4px 12px;
}

.content { padding: 28px; flex: 1; }

/* ── Page header ─────────────────────────────────── */
.page-header, .pw-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 22px;
}
.page-title, .pw-title {
  font-size: 1.5rem; font-weight: 700;
  color: var(--charcoal-900); letter-spacing: -.4px; margin: 0;
}
.page-sub, .pw-sub { font-size: 13px; color: var(--gray-400); margin: 3px 0 0; }

/* ── Card panel ──────────────────────────────────── */
.card-panel {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 20px; margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}
.card-panel.p-0 { padding: 0; overflow: hidden; }

/* ── Buttons ─────────────────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--ec-red); color: #fff;
  border: none; border-radius: var(--radius-md);
  padding: .55rem 1.1rem;
  font-family: var(--font); font-size: 13.5px; font-weight: 600;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  box-shadow: 0 2px 8px rgba(211,18,69,.3);
  transition: background .15s, box-shadow .15s;
}
.btn-primary:hover { background: var(--ec-red-dark); box-shadow: 0 4px 14px rgba(211,18,69,.4); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--white); color: var(--gray-500);
  border: 1px solid var(--gray-200); border-radius: var(--radius-md);
  padding: .5rem .9rem;
  font-family: var(--font); font-size: 13.5px; font-weight: 500;
  cursor: pointer; white-space: nowrap; text-decoration: none;
  transition: background .12s, border-color .12s;
}
.btn-ghost:hover { background: var(--gray-50); border-color: var(--gray-300); color: var(--charcoal-900); }
.btn-ghost:disabled { opacity: .4; cursor: not-allowed; }

.btn-success {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--green-bg); color: var(--green);
  border: 1px solid #bce3cc; border-radius: var(--radius-md);
  padding: .5rem .9rem;
  font-family: var(--font); font-size: 13.5px; font-weight: 500;
  cursor: pointer; white-space: nowrap;
  transition: background .12s;
}
.btn-success:hover { background: #d3edde; }
.btn-success:disabled { opacity: .4; cursor: not-allowed; }

.hstack { display: flex; align-items: center; }
.gap-2  { gap: 8px; }

/* ── Inputs ──────────────────────────────────────── */
.filter-select, .filter-input,
.pw-select, .pw-search-input {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  color: var(--gray-900);
  font-family: var(--font); font-size: 13.5px;
  padding: .48rem .75rem; outline: none; width: 100%;
  transition: border-color .2s, box-shadow .2s;
}
.filter-select:focus, .filter-input:focus,
.pw-select:focus, .pw-search-input:focus {
  border-color: var(--ec-red);
  box-shadow: 0 0 0 3px rgba(211,18,69,.12);
  background: var(--white);
}
.pw-select { min-width: 140px; }

/* ── Filter bars ─────────────────────────────────── */
.filter-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.pw-filter-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-md); padding: 12px 16px; margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}
.search-box, .pw-search-wrap { position: relative; flex: 1; min-width: 220px; }
.search-icon, .pw-search-icon {
  position: absolute; left: 11px; top: 50%; transform: translateY(-50%);
  color: var(--gray-300); font-size: 14px; pointer-events: none;
}
.search-input, .pw-search-input { padding-left: 2.2rem !important; }
.search-input::placeholder, .pw-search-input::placeholder { color: var(--gray-300); }

.filter-panel { margin-bottom: 14px; }
.filter-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; align-items: end; }
.filter-field { display: flex; flex-direction: column; gap: 5px; }
.filter-label { font-size: 11px; font-weight: 700; color: var(--gray-400); text-transform: uppercase; letter-spacing: .5px; }
.filter-actions { display: flex; gap: 8px; align-items: flex-end; }

/* ── Data tables ─────────────────────────────────── */
.table-wrap, .pw-table-wrap { overflow-x: auto; }
.data-table, .pw-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }

.data-table thead tr, .pw-table thead tr {
  background: var(--ec-red-50);
  border-bottom: 2px solid var(--ec-red-100);
}
.data-table thead th, .pw-table thead th {
  padding: 11px 14px;
  color: var(--ec-red-900);
  font-size: 11.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px;
  white-space: nowrap; cursor: pointer; user-select: none;
  transition: color .15s, background .15s;
}
.data-table thead th:hover, .pw-table thead th:hover { color: var(--ec-red); background: var(--ec-red-100); }

.data-table tbody tr, .pw-table tbody tr {
  border-bottom: 1px solid var(--gray-100);
  transition: background .1s;
}
.data-table tbody tr:hover, .pw-table tbody tr:hover { background: var(--ec-red-50); }
.data-table tbody tr:last-child, .pw-table tbody tr:last-child { border-bottom: none; }
.data-table tbody td, .pw-table tbody td { padding: 10px 14px; color: var(--gray-700); vertical-align: middle; }

.table-footer, .pw-table-footer {
  padding: 11px 16px; font-size: 12.5px; color: var(--gray-400);
  background: var(--gray-50); border-top: 1px solid var(--gray-100);
}
.table-footer strong, .pw-table-footer strong { color: var(--charcoal-900); }

.sort-active  { color: var(--ec-red); margin-left: 3px; font-size: 10px; }
.sort-idle    { color: var(--gray-300); margin-left: 3px; font-size: 10px; opacity: .6; }

.num { text-align: right !important; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.fw, .pw-fw { font-weight: 600; color: var(--charcoal-900) !important; }
.muted { color: var(--gray-400) !important; }
.pos { color: var(--pos) !important; }
.neg { color: var(--neg) !important; }
.center, .pw-center { text-align: center !important; }
.pw-desc { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--gray-400) !important; font-size: 12.5px; }

.acct-badge, .pw-acct-badge {
  font-family: var(--mono); font-size: 12px;
  background: var(--ec-red-50);
  border: 1px solid var(--ec-red-100);
  border-radius: var(--radius-sm);
  padding: 2px 8px;
  color: var(--ec-red); font-weight: 600; white-space: nowrap;
}

.status-chip, .pw-status {
  display: inline-block; font-size: 11.5px; font-weight: 600;
  padding: 3px 10px; border-radius: 20px; white-space: nowrap;
}
.chip-green, .pw-status-green { background: var(--green-bg); color: var(--green); }
.chip-amber, .pw-status-amber { background: var(--amber-bg); color: var(--amber); }
.chip-red,   .pw-status-red   { background: var(--red-bg); color: var(--red); }
.chip-gray,  .pw-status-gray  { background: var(--gray-100); color: var(--gray-500); }

.action-icon, .pw-icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px;
  background: var(--ec-red-50);
  border: 1px solid var(--ec-red-100);
  border-radius: var(--radius-sm);
  color: var(--ec-red); text-decoration: none;
  transition: background .12s, color .12s;
}
.action-icon:hover, .pw-icon-btn:hover { background: var(--ec-red); color: #fff; border-color: var(--ec-red); }

/* ── Summary cards ───────────────────────────────── */
.summary-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.sum-card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-md); padding: 16px;
  box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
}
.sum-card--accent { border-color: rgba(211,18,69,.35); background: linear-gradient(135deg, var(--ec-red-50), var(--white)); }
.sum-card--green { border-color: #bce3cc; }
.sum-card--red   { border-color: #f4bcc8; }
.sum-card--amber { border-color: #f0d9a8; }
.sum-label { font-size: 11px; font-weight: 700; color: var(--gray-400); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 6px; }
.sum-value { font-size: 1.1rem; font-weight: 700; font-family: var(--mono); color: var(--charcoal-900); }
.sum-indicator { position: absolute; right: 12px; top: 12px; font-size: 16px; color: var(--gray-300); opacity: .5; }

/* ── Pagination ──────────────────────────────────── */
.pagination-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-top: 1px solid var(--gray-100);
  background: var(--gray-50); flex-wrap: wrap; gap: 8px;
}
.pag-info { font-size: 12.5px; color: var(--gray-400); }
.pag-controls { display: flex; align-items: center; gap: 6px; }
.pag-size { width: auto !important; min-width: 110px; }
.pag-num { font-size: 12.5px; color: var(--gray-500); min-width: 52px; text-align: center; }
.pag-btn {
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm); color: var(--gray-500); cursor: pointer;
  transition: background .12s, color .12s, border-color .12s; font-size: 13px;
}
.pag-btn:hover:not(:disabled) { background: var(--ec-red); color: #fff; border-color: var(--ec-red); }
.pag-btn:disabled { opacity: .35; cursor: not-allowed; }

/* ── Dashboard stats ─────────────────────────────── */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.stat-card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); padding: 20px;
  box-shadow: var(--shadow-sm); display: flex; align-items: flex-start; gap: 14px;
  position: relative; transition: box-shadow .15s;
}
.stat-card:hover { box-shadow: var(--shadow-md); }
.stat-icon {
  width: 44px; height: 44px; flex-shrink: 0; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: #fff;
}
.stat-icon--blue  { background: linear-gradient(135deg, var(--ec-red), var(--ec-red-dark)); box-shadow: 0 4px 12px rgba(211,18,69,.3); }
.stat-icon--teal  { background: linear-gradient(135deg, var(--charcoal-700), var(--charcoal-900)); box-shadow: 0 4px 12px rgba(28,28,32,.3); }
.stat-icon--green { background: linear-gradient(135deg, #2e7d4f, #1f5e3a); box-shadow: 0 4px 12px rgba(46,125,79,.3); }

.stat-body { flex: 1; }
.stat-label { font-size: 12px; color: var(--gray-400); font-weight: 600; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 4px; }
.stat-value { font-size: 1.8rem; font-weight: 700; color: var(--charcoal-900); line-height: 1; }
.stat-link { position: absolute; right: 16px; bottom: 14px; font-size: 12.5px; color: var(--gray-400); text-decoration: none; display: flex; align-items: center; gap: 4px; transition: color .15s; }
.stat-link:hover { color: var(--ec-red); }
.stat-skeleton { height: 28px; width: 80px; background: var(--gray-100); border-radius: var(--radius-sm); animation: pulse 1.4s ease-in-out infinite; }

.section-heading { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--gray-400); margin-bottom: 14px; }
.action-row { display: flex; flex-wrap: wrap; gap: 10px; }
.action-btn {
  display: inline-flex; align-items: center; gap: 7px; padding: .5rem 1rem;
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-md); color: var(--gray-500); text-decoration: none;
  font-size: 13.5px; transition: background .12s, color .12s, border-color .12s, box-shadow .12s;
}
.action-btn:hover { background: var(--ec-red-50); color: var(--ec-red); border-color: rgba(211,18,69,.3); box-shadow: 0 2px 8px rgba(211,18,69,.1); }

/* ── States ──────────────────────────────────────── */
.table-loading, .empty-state, .pw-loading, .pw-empty {
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 10px; padding: 60px 0; color: var(--gray-400);
}
.pw-loading, .pw-empty { background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-lg); }
.empty-state i, .pw-empty i { font-size: 2.5rem; opacity: .3; display: block; margin-bottom: 10px; }

.spinner, .pw-spinner {
  width: 22px; height: 22px;
  border: 2px solid var(--gray-200);
  border-top-color: var(--ec-red);
  border-radius: 50%; animation: spin .7s linear infinite;
}

.alert-error, .pw-alert-error {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px; background: var(--red-bg);
  border: 1px solid #f4bcc8; border-radius: var(--radius-md);
  color: var(--red); font-size: 13.5px;
}
.alert-error { margin: 16px; }
.pw-alert-error { margin-bottom: 12px; }

.pw-card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden;
}

.not-found { text-align: center; padding: 80px 0; }
.not-found-code { font-size: 6rem; font-weight: 800; color: var(--ec-red-100); line-height: 1; }
.not-found-msg { font-size: 1.1rem; color: var(--gray-400); margin-top: -8px; }
.btn-back { display: inline-flex; align-items: center; color: var(--ec-red); text-decoration: none; font-size: 13.5px; margin-top: 12px; }
.btn-back:hover { text-decoration: underline; }

.mt-4 { margin-top: 1.25rem !important; }

#blazor-error-ui {
  background: var(--ec-red-900); color: #fff;
  bottom: 0; left: 0; right: 0; padding: 10px 20px;
  position: fixed; z-index: 9999; display: none; font-size: 13.5px;
}
#blazor-error-ui .reload { color: #fff; font-weight: 700; margin-left: 6px; }
#blazor-error-ui .dismiss { margin-left: auto; cursor: pointer; }

@keyframes spin  { to { transform: rotate(360deg); } }
@keyframes pulse { 0%,100%{opacity:.4} 50%{opacity:.8} }

/* ===================================================
   Investment Statement View
   =================================================== */
.stmt-actions-bar {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px; flex-wrap: wrap; gap: 10px;
}

.statement {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  max-width: 820px;
  margin: 0 auto;
  padding: 0;
  overflow: hidden;
}

/* Header band */
.stmt-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 28px 36px;
  background: var(--charcoal-900);
  color: #fff;
  flex-wrap: wrap; gap: 16px;
}
.stmt-brand { display: flex; align-items: center; gap: 13px; }
.stmt-brand-mark {
  width: 44px; height: 44px;
  background: var(--ec-red);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; color: #fff;
}
.stmt-brand-name { font-size: 17px; font-weight: 700; letter-spacing: -.2px; }
.stmt-brand-sub  { font-size: 12px; color: rgba(255,255,255,.55); text-transform: uppercase; letter-spacing: 1px; }
.stmt-period { text-align: right; }
.stmt-period-label { font-size: 11px; color: rgba(255,255,255,.5); text-transform: uppercase; letter-spacing: 1px; }
.stmt-period-value { font-size: 14px; font-weight: 600; margin-top: 3px; }

/* Account identity */
.stmt-account {
  padding: 24px 36px 18px;
  border-bottom: 1px solid var(--gray-100);
}
.stmt-account-name { font-size: 1.4rem; font-weight: 700; color: var(--charcoal-900); letter-spacing: -.3px; }
.stmt-account-num  { font-size: 13px; color: var(--gray-400); font-family: var(--mono); margin-top: 3px; }

/* Value band */
.stmt-value-band {
  display: flex; align-items: center; gap: 24px;
  padding: 24px 36px;
  background: var(--ec-red-50);
  border-bottom: 1px solid var(--ec-red-100);
  flex-wrap: wrap;
}
.stmt-value-block { }
.stmt-value-label { font-size: 11px; color: var(--gray-500); text-transform: uppercase; letter-spacing: .5px; font-weight: 600; margin-bottom: 5px; }
.stmt-value-amt { font-size: 1.25rem; font-weight: 700; font-family: var(--mono); color: var(--charcoal-900); }
.stmt-value-amt--lg { font-size: 1.6rem; color: var(--ec-red); }
.stmt-value-arrow { color: var(--gray-300); font-size: 20px; }
.stmt-value-change { margin-left: auto; text-align: right; }

/* Activity section */
.stmt-section-title {
  padding: 22px 36px 10px;
  font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px;
  color: var(--gray-400);
}
.stmt-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 8px;
}
.stmt-table td { padding: 11px 36px; font-size: 14px; }
.stmt-row-label { color: var(--gray-700); }
.stmt-row-label i { margin-right: 7px; font-size: 12px; }
.stmt-row-note { color: var(--gray-300); font-size: 12px; font-style: italic; }
.stmt-row-amt {
  text-align: right; font-family: var(--mono);
  font-variant-numeric: tabular-nums; color: var(--gray-900);
}
.stmt-row-detail td { border-bottom: 1px solid var(--gray-50); }
.stmt-row-detail .stmt-row-label { padding-left: 48px; }
.stmt-row-total td {
  border-top: 2px solid var(--charcoal-900);
  font-weight: 700; font-size: 15px;
  color: var(--charcoal-900);
  padding-top: 14px; padding-bottom: 14px;
}
.stmt-row-total .stmt-row-amt { color: var(--ec-red); }

/* Book value */
.stmt-book {
  display: flex; align-items: center; justify-content: space-between;
  margin: 0 36px 8px; padding: 14px 18px;
  background: var(--gray-50);
  border-radius: var(--radius-md);
}
.stmt-book-label { font-size: 13px; color: var(--gray-500); font-weight: 600; }
.stmt-book-amt { font-family: var(--mono); font-weight: 700; color: var(--gray-900); }

/* Footer */
.stmt-footer {
  padding: 22px 36px 28px;
  border-top: 1px solid var(--gray-100);
  margin-top: 12px;
}
.stmt-footer p { font-size: 11.5px; color: var(--gray-400); line-height: 1.6; margin: 0 0 6px; }
.stmt-footer-gen { font-style: italic; }

/* Print styles */
@media print {
  .sidebar, .stmt-actions-bar { display: none !important; }
  .main { margin-left: 0 !important; }
  .content { padding: 0 !important; }
  .statement { box-shadow: none; border: none; max-width: 100%; }
  body { background: #fff; }
}

/* ── Statement: ending book row (before market total) ── */
.stmt-row-book td {
  border-top: 0.5px solid var(--gray-200);
  color: var(--gray-700);
}

/* ── Statement: Units & NAV band ───────────────────── */
.stmt-units-band {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 0.5px solid var(--gray-200);
  background: var(--gray-50);
}
.stmt-units-block {
  padding: 16px 36px;
}
.stmt-units-block:first-child {
  border-right: 0.5px solid var(--gray-200);
}
.stmt-units-label {
  font-size: 11px; color: var(--gray-500);
  text-transform: uppercase; letter-spacing: .5px; font-weight: 600;
}
.stmt-units-note { text-transform: none; font-style: italic; font-weight: 400; }
.stmt-units-amt {
  font-size: 1.15rem; font-weight: 700;
  font-family: var(--mono); color: var(--charcoal-900); margin-top: 4px;
}
.stmt-nav { color: var(--blue-700); }
/* ── Logo styling ─────────────────────────────────── */
.brand-logo {
    width: 56px;
    height: 56px;
    flex-shrink: 0;
    background: #fff;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    overflow: hidden;
}

    .brand-logo img {
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        display: block;
    }

.stmt-brand-logo {
  width: 62px; height: 62px; flex-shrink: 0;
  background: #fff;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  padding: 6px; overflow: hidden;
}

    .stmt-brand-logo img {
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        display: block;
    }
