:root {
  --bg: #f3f5f2;
  --bg-soft: #edf0ec;
  --panel: #ffffff;
  --panel-2: #f5f7f4;
  --line: rgba(24, 39, 40, .12);
  --line-strong: rgba(24, 39, 40, .22);
  --ink: #172426;
  --muted: #647174;
  --dim: #899495;
  --jade: #167a67;
  --red: #c84d3f;
  --amber: #a46b16;
  --violet: #6757c8;
  --blue: #2f6eae;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Avenir Next", Avenir, "Helvetica Neue", sans-serif;
  --mono: "SFMono-Regular", Menlo, Monaco, Consolas, monospace;
  --sidebar: 224px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); min-height: 100vh; overflow-x: hidden; }
button, input, select { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid rgba(22,122,103,.45); outline-offset: 2px; }
.grain { position: fixed; inset: 0; opacity: .035; pointer-events: none; z-index: 99; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E"); }

body.access-locked { overflow: hidden; }
body.access-locked .app-shell,
body.access-locked > .grain { visibility: hidden; }
body.access-unlocked .access-gate { display: none; }
.access-gate { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at 18% 15%, rgba(22,122,103,.09), transparent 34%), linear-gradient(145deg,#f7f8f5,#eef2ed); }
.access-gate:after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .018; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.access-gate-card { position: relative; z-index: 1; width: min(520px,100%); border: 1px solid var(--line); background: rgba(255,255,255,.94); padding: 42px; box-shadow: 0 24px 70px rgba(30,50,47,.12); }
.access-mark { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--jade); color: var(--jade); font: italic 27px var(--serif); }
.access-kicker { margin: 28px 0 8px; color: var(--jade); font: 10px var(--mono); letter-spacing: .15em; }
.access-gate h1 { font: 600 30px/1.25 var(--sans); letter-spacing: -.025em; }
.access-copy { margin: 12px 0 28px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.access-form label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 12px; font-weight: 600; }
.access-input-row { display: grid; grid-template-columns: 1fr auto; }
.access-input-row input { min-width: 0; height: 48px; border: 1px solid var(--line-strong); border-right: 0; background: #fbfcfa; padding: 0 14px; color: var(--ink); font-size: 16px; outline: none; }
.access-input-row input:focus { border-color: var(--jade); box-shadow: inset 0 0 0 1px var(--jade); }
.access-input-row button { min-height: 48px; border: 1px solid var(--jade); background: var(--jade); color: #fff; padding: 0 20px; cursor: pointer; font-size: 13px; font-weight: 600; }
.access-input-row button:hover { background: #116957; }
.access-error { min-height: 22px; margin: 8px 0 0; color: var(--red); font-size: 12px; }
.access-form.shake { animation: accessShake .32s ease; }
@keyframes accessShake { 25% { transform: translateX(-5px); } 50% { transform: translateX(5px); } 75% { transform: translateX(-3px); } }
.access-foot { display: flex; align-items: center; gap: 10px; margin-top: 22px; color: var(--dim); }
.access-foot span { width: 7px; height: 7px; border-radius: 50%; background: var(--jade); }
.access-foot small { font-size: 10px; }

.app-shell { display: grid; grid-template-columns: var(--sidebar) 1fr; min-height: 100vh; }
.sidebar { position: fixed; width: var(--sidebar); inset: 0 auto 0 0; z-index: 20; border-right: 1px solid var(--line); padding: 28px 18px 20px; display: flex; flex-direction: column; background: rgba(10,15,18,.94); backdrop-filter: blur(18px); }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; padding: 0 9px 28px; border-bottom: 1px solid var(--line); }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--jade); color: var(--jade); font-family: var(--serif); font-style: italic; font-size: 22px; }
.brand strong { display: block; font-size: 12px; letter-spacing: .2em; }
.brand small { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.side-nav { display: flex; flex-direction: column; gap: 9px; margin-top: 14px; min-height:0; overflow-y:auto; }
.nav-group { display: grid; gap: 3px; }
.nav-group-label { margin: 0 10px 3px; color: var(--dim); font: 8px var(--mono); letter-spacing: .12em; }
.nav-group-utility { margin-top: 1px; padding-top: 8px; border-top: 1px solid var(--line); }
.nav-item { appearance: none; border: 0; background: transparent; display: grid; grid-template-columns: 28px 1fr; grid-template-rows: 17px 14px; text-align: left; padding: 7px 10px; border-radius: 7px; cursor: pointer; color: var(--muted); transition: .2s ease; }
.nav-item span { grid-row: 1 / 3; font-family: var(--mono); font-size: 9px; color: var(--dim); padding-top: 3px; }
.nav-item b { font-size: 12px; font-weight: 600; color: #bdc5c1; }
.nav-item small { font-size: 9px; letter-spacing: .08em; }
.nav-item:hover { background: rgba(255,255,255,.04); color: var(--ink); }
.nav-item.active { background: #1b262a; box-shadow: inset 2px 0 var(--jade); }
.nav-item.active b { color: var(--ink); }
.nav-item.active span { color: var(--jade); }
.read-only-seal { margin-top: auto; border: 1px solid var(--line); padding: 12px; display: flex; align-items: center; gap: 9px; border-radius: 7px; }
.read-only-seal strong, .read-only-seal small { display: block; }
.read-only-seal strong { font-size: 11px; }.read-only-seal small { color: var(--dim); font: 8px var(--mono); margin-top: 2px; }
.pulse-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--jade); box-shadow: 0 0 0 5px rgba(89,215,176,.09); }

.workspace { grid-column: 2; min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 15; height: 76px; border-bottom: 1px solid var(--line); background: rgba(12,17,21,.86); backdrop-filter: blur(20px); display: flex; align-items: center; padding: 0 34px; gap: 20px; }
.mobile-brand { display: none; }
.search-trigger { width: min(460px, 38vw); display: flex; align-items: center; gap: 11px; border: 1px solid var(--line); border-radius: 6px; background: rgba(255,255,255,.025); color: var(--muted); padding: 10px 12px; cursor: pointer; text-align: left; }
.search-trigger:hover { border-color: var(--line-strong); background: rgba(255,255,255,.04); }
.search-trigger span:nth-child(2) { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12px; }
.search-trigger kbd, .search-input-row kbd { margin-left: auto; font: 10px var(--mono); color: var(--dim); border: 1px solid var(--line); border-radius: 4px; padding: 3px 6px; background: #0d1316; }
.search-icon { width: 13px; height: 13px; border: 1.5px solid currentColor; border-radius: 50%; position: relative; flex: 0 0 auto; }
.search-icon:after { content: ""; width: 5px; height: 1.5px; background: currentColor; position: absolute; right: -4px; bottom: -2px; transform: rotate(45deg); }
.top-controls { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.top-controls label { display: grid; gap: 3px; }.top-controls label > span { color: var(--dim); font-size: 8px; letter-spacing: .12em; }
.top-controls select { border: 0; color: #cdd3cf; background: transparent; font-size: 11px; outline: none; max-width: 105px; }
.asof { border: 1px solid var(--line); background: transparent; border-radius: 5px; padding: 8px 10px; display: flex; align-items: center; gap: 8px; text-align: left; }
.asof i { width: 6px; height: 6px; background: var(--jade); border-radius: 50%; }.asof span { font-size: 8px; color: var(--dim); }.asof small { display: block; font: 9px var(--mono); color: var(--ink); margin-top: 2px; }
.lock-button { border: 0; border-left: 1px solid var(--line); background: transparent; padding: 8px 0 8px 14px; color: var(--muted); cursor: pointer; font-size: 10px; }
.lock-button:hover { color: var(--red); }

main { padding: 42px 38px 70px; max-width: 1580px; margin: 0 auto; }
.page { display: none; }.page.active { display: block; animation: pageIn .42s cubic-bezier(.2,.8,.2,1); }
@keyframes pageIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.page-heading { display: flex; justify-content: space-between; align-items: end; gap: 28px; margin-bottom: 32px; }
.page-heading.compact { align-items: center; }
.eyebrow { margin: 0 0 10px; color: var(--jade); font: 9px var(--mono); letter-spacing: .2em; }
h1 { margin: 0; font: 400 clamp(34px, 4vw, 58px)/1.02 var(--serif); letter-spacing: -.035em; }
.heading-note { margin: 0 0 4px; color: var(--muted); font-size: 12px; line-height: 1.7; text-align: right; }
.reveal { animation: reveal .7s both cubic-bezier(.2,.8,.2,1); }.delay-1 { animation-delay: .08s; }.delay-2 { animation-delay: .16s; }.delay-3 { animation-delay: .24s; }
@keyframes reveal { from { opacity: 0; transform: translateY(15px); } }

.status-strip { display: grid; grid-template-columns: 1.35fr repeat(3,.65fr) .8fr; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); min-height: 58px; margin-bottom: 20px; }
.status-strip > * { border-right: 1px solid var(--line); padding: 10px 14px; }.status-strip > *:last-child { border: 0; }
.status-strip div { display: grid; grid-template-columns: auto 1fr; align-content: center; column-gap: 8px; }.status-strip div b { font: 14px var(--mono); }.status-strip div small { grid-column: 2; font-size: 9px; color: var(--dim); }.status-strip div:not(:first-child) b { grid-row: 1/3; font-size: 20px; }.status-strip .status-warning b { color: var(--amber); }
.status-light { width: 7px; height: 7px; align-self: center; background: var(--jade); border-radius: 50%; }
.status-strip button, .panel-head button { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 10px; }.status-strip button:hover, .panel-head button:hover { color: var(--jade); }

.kpi-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; margin-bottom: 10px; }
.kpi-card { min-height: 154px; border: 1px solid var(--line); background: linear-gradient(150deg, rgba(255,255,255,.035), rgba(255,255,255,.005)); padding: 17px; position: relative; overflow: hidden; cursor: pointer; transition: transform .22s ease, border-color .22s ease; }
.kpi-card:before { content: ""; position: absolute; inset: 0 auto 0 0; width: 2px; background: var(--accent, var(--jade)); }
.kpi-card:hover { transform: translateY(-3px); border-color: var(--line-strong); }
.kpi-card .kpi-top { display: flex; justify-content: space-between; gap: 8px; }.kpi-card .kpi-label b { display: block; font-size: 11px; }.kpi-card .kpi-label small { color: var(--muted); font-size: 9px; }.confidence { font: 7px var(--mono); border: 1px solid currentColor; padding: 3px 5px; height: fit-content; color: var(--accent, var(--jade)); }
.kpi-card strong { display: block; font: 27px/1 var(--mono); margin-top: 28px; letter-spacing: -.04em; }.kpi-card p { margin: 10px 0 0; color: var(--dim); font-size: 9px; }.kpi-card.negative strong { color: var(--red); }.kpi-card.notional { --accent: var(--violet); }.kpi-card.warning { --accent: var(--amber); }
.kpi-card.portfolio-total { grid-column:span 2; background:linear-gradient(135deg,#fff 0%,#f3f8f6 100%); border-color:rgba(47,110,174,.28); }
.kpi-card.portfolio-total strong { color:var(--blue); font-size:34px; }

.dashboard-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 10px; }
.panel { border: 1px solid var(--line); background: var(--panel); padding: 20px; min-width: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: start; margin-bottom: 20px; }.panel-head > div { display: grid; grid-template-columns: 28px 1fr; }.section-index { grid-row: 1/3; width: 20px; height: 20px; border: 1px solid var(--jade); display: grid; place-items: center; color: var(--jade); font: 9px var(--mono); }.section-index.alert,.section-index.loss { border-color: var(--red); color: var(--red); }.panel-head h2 { margin: 0; font: 17px var(--serif); }.panel-head small { color: var(--dim); font-size: 9px; margin-top: 2px; }
.account-allocation { display: grid; gap: 15px; }.allocation-row { display: grid; grid-template-columns: 115px 1fr 90px; align-items: center; gap: 12px; }.allocation-row .label b,.allocation-row .label small { display:block; }.allocation-row .label b { font-size: 11px; }.allocation-row .label small { font-size: 8px; color: var(--dim); }.bar-track { height: 8px; background: #0b1114; position: relative; overflow: hidden; }.bar-fill { height:100%; background: var(--color); transform-origin:left; animation: grow .9s both .35s; }.allocation-row .value { text-align:right; font: 11px var(--mono); }.allocation-row .value small { color:var(--dim); display:block; font-size:8px; margin-top:2px; }
@keyframes grow { from { transform: scaleX(0); } }
.currency-note { display: flex; gap: 10px; align-items: center; border-top: 1px solid var(--line); margin-top: 18px; padding-top: 13px; color: var(--muted); font-size: 9px; }.currency-note b { color: var(--ink); font: 10px var(--mono); }.currency-note i { flex:1; height:1px; background:var(--line); }
.risk-list { display:grid; gap:8px; }.risk-item { display:grid; grid-template-columns: 8px 1fr auto; gap:10px; align-items:start; padding:10px 0; border-bottom:1px solid var(--line); }.risk-item:last-child{border:0}.risk-item i{width:7px;height:7px;border-radius:50%;background:var(--risk);margin-top:5px}.risk-item b,.risk-item small{display:block}.risk-item b{font-size:11px}.risk-item small{color:var(--muted);font-size:9px;margin-top:3px;line-height:1.45}.risk-item strong{font:10px var(--mono);color:var(--risk)}
.timeline-panel,.laggard-panel { min-height: 260px; }.timeline { display:flex; flex-direction:column; }.event { display:grid; grid-template-columns:72px 13px 1fr auto; min-height:45px; }.event time{font:9px var(--mono);color:var(--muted)}.event .line{position:relative;border-left:1px solid var(--line)}.event .line:before{content:"";position:absolute;width:6px;height:6px;border-radius:50%;background:var(--event-color);left:-3.5px;top:2px;box-shadow:0 0 0 4px var(--panel)}.event b{font-size:10px}.event small{display:block;color:var(--dim);font-size:8px;margin-top:2px}.event strong{font:9px var(--mono);color:var(--event-color)}
.laggard-list { display:grid; gap:9px; }.laggard { display:grid; grid-template-columns:1fr 92px; gap:10px; }.laggard b,.laggard small{display:block}.laggard b{font-size:10px}.laggard small{font-size:8px;color:var(--dim);margin-top:2px}.laggard strong{text-align:right;color:var(--red);font:10px var(--mono)}.loss-meter{grid-column:1/3;height:2px;background:#0b1114}.loss-meter i{display:block;height:100%;background:var(--red);opacity:.7}

.method-banner { border:1px solid rgba(240,185,91,.3); background:rgba(240,185,91,.06); padding:12px 15px; display:flex; gap:18px; margin-bottom:14px; font-size:10px; }.method-banner b{color:var(--amber)}.method-banner span{color:var(--muted)}
.return-sections { display:grid; gap:10px; margin-bottom:10px; }
.return-group { border:1px solid var(--line); background:#f8faf7; padding:16px; }
.return-group > header { display:flex; align-items:flex-end; justify-content:space-between; gap:24px; margin-bottom:12px; }
.return-group > header b,.return-group > header small { display:block; }
.return-group > header b { font-size:14px; }
.return-group > header small { margin-top:3px; color:var(--jade); font:9px var(--mono); }
.return-group > header p { max-width:540px; margin:0; color:var(--muted); font-size:11px; line-height:1.55; text-align:right; }
.return-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
.fund-return-group { background:#f5f7fb; }
.fund-return-group > header small { color:var(--blue); }
.fund-return-grid { grid-template-columns:repeat(2,1fr); }
.return-card { border:1px solid var(--line); padding:18px; background:var(--panel); }
.return-card small{color:var(--dim);font-size:9px}.return-card h3{font:13px var(--sans);margin:7px 0 22px}.return-card strong{font:30px var(--mono);color:var(--red)}.return-card.positive strong{color:var(--jade)}.return-card p{margin:8px 0 0;color:var(--muted);font-size:9px}.two-col{display:grid;grid-template-columns:1.15fr .85fr;gap:10px}.return-bars{display:grid;gap:18px;padding:10px 4px}.return-bar-row{display:grid;grid-template-columns:72px 1fr 60px;align-items:center;gap:12px}.return-bar-row b{font-size:10px}.return-axis{height:12px;background:#0c1215;position:relative}.return-axis:after{content:"";position:absolute;left:50%;top:-4px;bottom:-4px;border-left:1px solid var(--line-strong)}.return-fill{position:absolute;height:100%;background:var(--red);right:50%;}.return-fill.positive{left:50%;right:auto;background:var(--jade)}.return-bar-row strong{text-align:right;font:10px var(--mono)}
.performance-chart-full { width:100%; }
.definition-stack { display:grid; gap:0; }.definition-stack div { padding:14px 0; border-bottom:1px solid var(--line); display:grid;grid-template-columns:100px 1fr}.definition-stack div:last-child{border:0}.definition-stack b{font-size:11px}.definition-stack small{grid-column:1;color:var(--jade);font-size:8px}.definition-stack p{grid-column:2;grid-row:1/3;margin:0;color:var(--muted);font-size:9px;line-height:1.5}

.account-card-grid { display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.account-card{border:1px solid var(--line);background:var(--panel);padding:20px;min-height:245px;position:relative;cursor:pointer;transition:.2s}.account-card:hover{transform:translateY(-3px);border-color:var(--accent)}.account-card header{display:flex;justify-content:space-between}.account-code{font:24px var(--mono);letter-spacing:-.06em}.account-card .entity{font-size:8px;color:var(--dim);margin-top:5px}.account-card .mandate{font:7px var(--mono);color:var(--accent);border:1px solid var(--accent);padding:3px 5px;height:fit-content}.account-role{font:19px/1.15 var(--serif);margin:26px 0 8px}.account-desc{font-size:9px;color:var(--muted);line-height:1.55;min-height:42px}.account-stats{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid var(--line);margin-top:18px;padding-top:13px}.account-stats b,.account-stats small{display:block}.account-stats b{font:11px var(--mono)}.account-stats small{font-size:7px;color:var(--dim);margin-top:3px}.account-card.empty{opacity:.56}

.account-asof { align-self:flex-start; border:1px solid var(--line); background:#fff; padding:9px 11px; color:var(--muted); font-size:10px; }
.account-asof b { color:var(--ink); font:10px var(--mono); }
.account-tabs { display:flex; gap:6px; margin-bottom:10px; padding:7px; border:1px solid var(--line); background:#eef2ee; overflow-x:auto; }
.account-tabs button { min-width:92px; border:1px solid transparent; background:transparent; padding:9px 12px; color:var(--muted); cursor:pointer; font-size:11px; white-space:nowrap; }
.account-tabs button small { margin-left:5px; color:var(--dim); font-size:8px; }
.account-tabs button.active { border-color:rgba(22,122,103,.25); background:#fff; color:var(--ink); box-shadow:inset 0 -2px var(--jade); }
.account-tabs button.empty { opacity:.65; }
.account-register-panel { padding:0; overflow:hidden; margin-bottom:10px; }
.account-register-panel > .panel-head { padding:18px 18px 0; }
.account-register-wrap { max-height:none; border-top:1px solid var(--line); }
.account-register-table { min-width:1040px; }
.account-register-table tbody tr { cursor:pointer; transition:background .16s ease; }
.account-register-table tbody tr:hover { background:#f4f7f3; }
.account-register-table tbody tr.selected { background:#eaf2ee; box-shadow:inset 3px 0 var(--jade); }
.account-register-table tbody tr.empty { opacity:.62; }
.account-status { display:inline-block; padding:4px 7px; border:1px solid currentColor; font-size:9px; }
.account-status.active { color:var(--jade); }.account-status.idle { color:var(--dim); }
.no-financing { color:var(--muted); font-size:10px; }
.account-detail { display:grid; gap:10px; }
.account-detail-head { display:flex; justify-content:space-between; align-items:flex-end; gap:24px; padding:22px 2px 12px; border-bottom:1px solid var(--line-strong); }
.account-detail-head small { color:var(--jade); font:9px var(--mono); letter-spacing:.1em; }
.account-detail-head h2 { margin:6px 0 5px; font:600 23px var(--sans); }
.account-detail-head p { margin:0; color:var(--muted); font-size:12px; line-height:1.6; }
.account-detail-head > span { flex:0 0 auto; border:1px solid rgba(22,122,103,.35); color:var(--jade); padding:6px 9px; font-size:10px; }
.account-detail-head > span.idle { border-color:var(--line-strong); color:var(--dim); }
.account-balance-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
.account-balance-grid article { min-height:132px; padding:16px; border:1px solid var(--line); background:#fff; }
.account-balance-grid small,.account-balance-grid b { display:block; }
.account-balance-grid small { min-height:34px; color:var(--muted); font-size:10px; line-height:1.45; }
.account-balance-grid b { margin-top:16px; font:17px/1.3 var(--mono); overflow-wrap:anywhere; }
.account-balance-grid p { margin:7px 0 0; color:var(--dim); font-size:10px; line-height:1.5; }
.account-two-col { display:grid; grid-template-columns:.9fr 1.1fr; gap:10px; }
.account-product-grid { display:grid; }
.account-product-row { display:grid; grid-template-columns:1fr auto 38px; align-items:center; gap:12px; padding:10px 0; border-bottom:1px solid var(--line); }
.account-product-row:last-child { border-bottom:0; }
.account-product-row > span { display:grid; grid-template-columns:12px 1fr; align-items:center; column-gap:8px; }
.account-product-row i { grid-row:1/3; width:8px; height:8px; border-radius:50%; background:var(--dim); }
.account-product-row i.stock{background:var(--jade)}.account-product-row i.fund{background:var(--blue)}.account-product-row i.derivative{background:var(--violet)}.account-product-row i.cash{background:#5c7b67}.account-product-row i.settlement{background:var(--amber)}
.account-product-row b,.account-product-row small { display:block; }
.account-product-row b { font-size:11px; }.account-product-row small { color:var(--dim); font-size:9px; }
.account-product-row strong { font:10px var(--mono); text-align:right; }.account-product-row em { color:var(--dim); font:9px var(--mono); text-align:right; }
.financing-summary { display:grid; grid-template-columns:repeat(3,1fr); border:1px solid var(--line); }
.financing-summary > div { padding:12px; border-right:1px solid var(--line); }
.financing-summary > div:last-child { border-right:0; }
.financing-summary small,.financing-summary b { display:block; }
.financing-summary small { color:var(--muted); font-size:9px; }.financing-summary b { margin-top:7px; font:12px var(--mono); }
.financing-boundary { margin:10px 0; padding:10px 12px; border-left:3px solid var(--amber); background:#f9f6ed; color:var(--muted); font-size:10px; line-height:1.6; }
.account-loan-list { display:grid; }
.account-loan-row { display:grid; grid-template-columns:86px 1fr auto; gap:10px; padding:9px 0; border-bottom:1px solid var(--line); }
.account-loan-row:last-child { border-bottom:0; }
.account-loan-row time { color:var(--amber); font:9px var(--mono); }.account-loan-row b,.account-loan-row small { display:block; }.account-loan-row b { font-size:10px; }.account-loan-row small { margin-top:2px; color:var(--dim); font-size:8px; }.account-loan-row strong { font:10px var(--mono); }
.financing-empty { min-height:238px; display:grid; place-content:center; padding:30px; text-align:center; border:1px dashed var(--line-strong); background:#fafbf9; }
.financing-empty.clear { border-color:rgba(22,122,103,.25); background:#f5faf7; }
.financing-empty b { font-size:14px; }.financing-empty p { max-width:460px; margin:8px auto 0; color:var(--muted); font-size:11px; line-height:1.65; }
.account-holdings-table { margin-top:0; }

.view-toggle { display:flex;border:1px solid var(--line);padding:3px;background:#0a1013}.view-toggle button{border:0;background:transparent;color:var(--muted);padding:8px 14px;cursor:pointer;font-size:10px}.view-toggle button small{display:block;font-size:7px;margin-top:2px}.view-toggle button.active{background:var(--panel-2);color:var(--ink);box-shadow:inset 0 -2px var(--jade)}.view-toggle button[data-view="notional"].active{box-shadow:inset 0 -2px var(--violet)}
.holdings-summary { display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:10px}.summary-card{border:1px solid var(--line);padding:15px;background:var(--panel)}.summary-card b,.summary-card small{display:block}.summary-card b{font:18px var(--mono);margin-top:11px}.summary-card small{font-size:8px;color:var(--muted)}
.asset-breakdown-panel { margin-bottom: 10px; padding: 20px 0 0; overflow: hidden; }
.asset-breakdown-panel > .panel-head,
.asset-breakdown-panel > .breakdown-note,
.asset-breakdown-panel > .product-breakdown-grid,
.asset-breakdown-panel > .overlap-toolbar,
.asset-breakdown-panel > .breakdown-source { margin-left: 20px; margin-right: 20px; }
.breakdown-head { margin-bottom: 14px; }
.breakdown-note { display: grid; grid-template-columns: 170px 1fr; gap: 18px; padding: 13px 15px; border: 1px solid rgba(164,107,22,.25); background: #fbf8ef; color: var(--muted); font-size: 11px; line-height: 1.65; }
.breakdown-note > b { color: var(--amber); font-size: 12px; }
.breakdown-note strong { color: var(--ink); font-weight: 600; }
.product-breakdown-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 12px; }
.product-type-card { min-height: 128px; border: 1px solid var(--line); padding: 14px; background: var(--panel-2); position: relative; overflow: hidden; }
.product-type-card:before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--type-color,var(--jade)); }
.product-type-card header { display: flex; justify-content: space-between; gap: 10px; }
.product-type-card h3 { margin: 0; font-size: 13px; }
.product-type-card h3 small { display: block; margin-top: 3px; color: var(--muted); font-size: 9px; font-weight: 400; }
.product-type-card header span { color: var(--muted); font: 10px var(--mono); white-space: nowrap; }
.product-type-card strong { display: block; margin-top: 22px; font: 17px/1.25 var(--mono); color: var(--ink); }
.product-type-card p { margin: 8px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.overlap-toolbar { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; margin-top: 22px; padding: 16px 0 12px; border-top: 1px solid var(--line); }
.overlap-toolbar b,
.overlap-toolbar small { display: block; }
.overlap-toolbar b { font-size: 13px; }
.overlap-toolbar small { margin-top: 4px; color: var(--muted); font-size: 10px; }
.overlap-controls { display: flex; align-items: center; gap: 8px; }
.overlap-search { display: flex; align-items: center; gap: 9px; min-width: 225px; border: 1px solid var(--line); padding: 8px 10px; background: #fff; }
.overlap-search input { min-width: 0; width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 10px; }
.compact-toggle { display: flex; padding: 3px; background: #eef1ed; }
.compact-toggle button { border: 0; background: transparent; padding: 8px 10px; color: var(--muted); cursor: pointer; font-size: 9px; white-space: nowrap; }
.compact-toggle button.active { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(20,35,36,.09), inset 0 -2px var(--jade); }
.overlap-table-wrap { max-height: 510px; border-top: 1px solid var(--line); }
.overlap-table { min-width: 1120px; }
.overlap-table td { vertical-align: top; }
.underlying-cell { display: flex; gap: 10px; align-items: flex-start; }
.underlying-cell .ticker-mark { min-width: 49px; color: var(--jade); font: 600 11px var(--mono); }
.underlying-cell b { font-size: 11px; }
.relation-pill { display: inline-block; padding: 4px 6px; border: 1px solid var(--line-strong); color: var(--muted); font: 8px var(--mono); white-space: nowrap; }
.relation-pill.mixed { border-color: rgba(22,122,103,.35); background: rgba(22,122,103,.06); color: var(--jade); }
.metric-stack b,
.metric-stack small { display: block; }
.metric-stack b { font: 10px var(--mono); }
.metric-stack small { margin-top: 4px; font-size: 8px; color: var(--dim); line-height: 1.45; }
.metric-stack .negative { color: var(--red); }
.account-path { display: grid; gap: 4px; }
.account-path span { font-size: 8px; color: var(--muted); }
.account-path b { display: inline; margin-right: 4px; color: var(--ink); font-size: 8px; }
.breakdown-source { margin-top: 0; margin-bottom: 0; padding: 12px 0 15px; color: var(--dim); font-size: 9px; line-height: 1.55; }
.breakdown-empty { padding: 34px; text-align: center; color: var(--muted); font-size: 11px; }
.table-panel{padding:0;overflow:hidden}.table-tools{min-height:60px;padding:13px 18px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line)}.table-tools b,.table-tools small{display:block}.table-tools b{font-size:12px}.table-tools small{font-size:8px;color:var(--dim);margin-top:3px}.table-search{display:flex;align-items:center;gap:9px;border:1px solid var(--line);padding:7px 10px}.table-search input{border:0;outline:0;background:transparent;color:var(--ink);font-size:10px;width:170px}.table-wrap{overflow:auto;max-height:560px}table{width:100%;border-collapse:collapse;min-width:850px}th{position:sticky;top:0;background:#11191d;color:var(--muted);font-size:8px;font-weight:500;letter-spacing:.05em;text-align:left;padding:11px 14px;border-bottom:1px solid var(--line);z-index:2}td{padding:12px 14px;border-bottom:1px solid rgba(227,232,226,.07);font-size:9px;color:#cbd1cd}td b,td small{display:block}td b{font-size:10px;color:var(--ink)}td small{font-size:7px;color:var(--dim);margin-top:3px}td.num{font:9px var(--mono)}td.loss{color:var(--red)}td.gain{color:var(--jade)}.type-pill,.status-pill{font:7px var(--mono);padding:3px 5px;border:1px solid var(--line-strong);white-space:nowrap}.type-pill.derivative{color:var(--violet);border-color:rgba(155,140,255,.35)}.status-pill.watch{color:var(--amber)}

.derivative-definition-strip { display:grid; grid-template-columns:repeat(4,1fr); border:1px solid var(--line); background:#fff; margin-bottom:10px; }
.derivative-definition-strip > div { padding:16px 17px; border-right:1px solid var(--line); }
.derivative-definition-strip > div:last-child { border-right:0; }
.derivative-definition-strip b,.derivative-definition-strip small { display:block; }
.derivative-definition-strip b { font-size:13px; }
.derivative-definition-strip small { margin-top:3px; color:var(--violet); font:9px var(--mono); }
.derivative-definition-strip p { margin:10px 0 0; color:var(--muted); font-size:11px; line-height:1.65; }
.derivative-kpis { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; margin-bottom:10px; }
.derivative-kpis article { min-height:145px; padding:17px; border:1px solid var(--line); background:#fff; }
.derivative-kpis small,.derivative-kpis b { display:block; }
.derivative-kpis small { min-height:35px; color:var(--muted); font-size:10px; line-height:1.45; }
.derivative-kpis b { margin-top:18px; font:19px var(--mono); }
.derivative-kpis p { margin:7px 0 0; color:var(--dim); font-size:10px; line-height:1.5; }
.derivative-register-panel { padding:0; overflow:hidden; margin-bottom:10px; }
.derivative-register-panel > .panel-head { padding:18px 18px 0; }
.derivative-filter { display:flex; gap:6px; padding:0 18px 14px; overflow-x:auto; }
.derivative-filter button { border:1px solid var(--line); background:#f5f7f4; padding:8px 11px; color:var(--muted); cursor:pointer; font-size:11px; white-space:nowrap; }
.derivative-filter button.active { border-color:rgba(103,87,200,.4); background:rgba(103,87,200,.08); color:var(--violet); }
.derivative-table-wrap { max-height:none; border-top:1px solid var(--line); }
.derivative-table { min-width:1320px; }
.derivative-table td { vertical-align:top; line-height:1.6; }
.derivative-table td:nth-child(1) { min-width:175px; }
.derivative-table td:nth-child(2) { min-width:230px; }
.derivative-table td:nth-child(5),.derivative-table td:nth-child(8) { min-width:210px; }
.derivative-summary-row { cursor:pointer; transition:background .18s ease,box-shadow .18s ease; }
.derivative-summary-row:hover,.derivative-summary-row.expanded { background:#f7f9f6; }
.derivative-summary-row:hover { box-shadow:inset 3px 0 0 rgba(103,87,200,.24); }
.derivative-summary-row:focus-visible { outline:2px solid rgba(103,87,200,.55); outline-offset:-2px; }
.derivative-category-cell { display:grid; grid-template-columns:16px minmax(0,1fr); gap:10px; align-items:start; color:var(--ink); }
.derivative-category-cell > span:last-child { min-width:0; }
.derivative-category-cell b,.derivative-category-cell small { display:block; }
.derivative-category-cell b { font-size:12px; line-height:1.45; }
.derivative-category-cell small { margin-top:5px; color:var(--muted); font-size:10px; }
.derivative-chevron { width:8px; height:8px; margin:7px 0 0 2px; border-right:1.5px solid var(--violet); border-bottom:1.5px solid var(--violet); transform:rotate(45deg); transition:transform .2s ease,margin .2s ease; }
.derivative-summary-row.expanded .derivative-chevron { margin-top:10px; transform:rotate(225deg); }
.derivative-code { display:inline-block; margin-bottom:7px; padding:3px 6px; border:1px solid currentColor; font:9px var(--mono); font-style:normal; }
.derivative-code.notes,.direction-pill.notes { color:var(--violet); }
.derivative-code.buy,.direction-pill.buy { color:var(--jade); }
.derivative-code.sell,.direction-pill.sell { color:var(--amber); }
.derivative-code.fx,.direction-pill.fx { color:var(--blue); }
.direction-pill { display:inline-block; padding:4px 7px; border:1px solid currentColor; font-size:10px; white-space:nowrap; }
.derivative-detail-row > td { padding:0; background:#f4f7f3; border-bottom:1px solid var(--line-strong); }
.derivative-position-panel { padding:20px 24px 24px 52px; box-shadow:inset 3px 0 0 rgba(103,87,200,.35); }
.derivative-position-panel > header { display:flex; justify-content:space-between; align-items:flex-start; gap:28px; margin-bottom:15px; }
.derivative-position-panel > header b,.derivative-position-panel > header small { display:block; }
.derivative-position-panel > header b { font-size:14px; }
.derivative-position-panel > header small { margin-top:4px; color:var(--violet); font:10px var(--mono); }
.derivative-position-panel > header p { max-width:680px; margin:0; color:var(--muted); font-size:11px; line-height:1.6; text-align:right; }
.derivative-position-list { border:1px solid var(--line); background:#fff; }
.derivative-position-row { display:grid; grid-template-columns:minmax(340px,1.8fr) .8fr .85fr .85fr; gap:18px; align-items:start; padding:14px 16px; border-bottom:1px solid var(--line); }
.derivative-position-row:last-child { border-bottom:0; }
.derivative-position-row > div { min-width:0; }
.derivative-position-row b,.derivative-position-row small,.derivative-position-row span { display:block; }
.derivative-position-row b { font-size:12px; line-height:1.45; overflow-wrap:anywhere; }
.derivative-position-row small { margin-top:4px; color:var(--muted); font-size:10px; line-height:1.55; overflow-wrap:anywhere; }
.derivative-position-row span { margin-bottom:4px; color:var(--dim); font-size:9px; }
.derivative-position-name b { font:12px var(--mono); color:var(--violet); }
.derivative-position-name small { color:var(--ink); font-size:11px; }
.derivative-position-empty { padding:28px; color:var(--muted); font-size:12px; text-align:center; }
.derivative-source { margin:0; padding:13px 18px; border-top:1px solid var(--line); color:var(--dim); font-size:10px; line-height:1.6; }
.derivative-detail-grid { display:grid; grid-template-columns:.9fr 1.1fr; gap:10px; }
.derivative-detail-grid.single { grid-template-columns:1fr; }
.comparison-stack { display:grid; gap:10px; }
.comparison-stack > div { padding:15px; border:1px solid var(--line); background:var(--panel-2); }
.comparison-stack b,.comparison-stack strong { display:block; }
.comparison-stack b { color:var(--jade); font-size:12px; }
.comparison-stack strong { margin-top:8px; font:13px var(--mono); }
.comparison-stack p,.collateral-note { margin:8px 0 0; color:var(--muted); font-size:11px; line-height:1.65; }
.collateral-grid { display:grid; grid-template-columns:1fr 1fr; border:1px solid var(--line); }
.collateral-grid > div { padding:15px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.collateral-grid > div:nth-child(2n) { border-right:0; }
.collateral-grid > div:nth-last-child(-n+2) { border-bottom:0; }
.collateral-grid small,.collateral-grid b { display:block; }
.collateral-grid small { color:var(--muted); font-size:10px; }
.collateral-grid b { margin-top:8px; font:15px var(--mono); }
.collateral-note { padding:12px 14px; background:#f7f4ec; border-left:3px solid var(--amber); }

.financing-hero{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:10px}.financing-hero>div{border:1px solid var(--line);padding:18px;background:linear-gradient(145deg,var(--panel),#10171b)}.financing-hero small,.financing-hero strong,.financing-hero span{display:block}.financing-hero small{font-size:8px;color:var(--muted);line-height:1.45}.financing-hero strong{font:22px var(--mono);margin:22px 0 8px}.financing-hero span{font-size:8px;color:var(--dim)}.financing-hero .purple{border-color:rgba(155,140,255,.3)}.financing-hero .purple strong{color:var(--violet)}.finance-grid{grid-template-columns:1fr 1fr}.loan-list{display:grid}.loan-row{display:grid;grid-template-columns:90px 1fr auto;gap:12px;padding:13px 0;border-bottom:1px solid var(--line)}.loan-row:last-child{border:0}.loan-row time{font:9px var(--mono);color:var(--amber)}.loan-row b,.loan-row small{display:block}.loan-row b{font-size:10px}.loan-row small{font-size:8px;color:var(--dim);margin-top:3px}.loan-row strong{font:10px var(--mono)}.fx-list .loan-row time{color:var(--blue)}

.transaction-kpis{display:grid;grid-template-columns:repeat(4,1fr);border:1px solid var(--line);margin-bottom:10px}.transaction-kpis div{padding:18px;border-right:1px solid var(--line)}.transaction-kpis div:last-child{border:0}.transaction-kpis b,.transaction-kpis span{display:block}.transaction-kpis b{font:24px var(--mono)}.transaction-kpis span{font-size:8px;color:var(--muted);margin-top:6px}.month-chart{margin-bottom:10px}.monthly-chart{height:210px;display:flex;align-items:end;gap:12px;padding:20px 10px 0;border-bottom:1px solid var(--line)}.month-group{flex:1;height:100%;display:flex;gap:3px;align-items:end;position:relative}.month-bar{flex:1;min-width:10px;background:var(--jade);opacity:.75;animation:barUp .8s both}.month-bar.jpy{background:var(--blue)}.month-label{position:absolute;bottom:-20px;width:100%;text-align:center;font:8px var(--mono);color:var(--dim)}@keyframes barUp{from{height:0!important}}

.transaction-range-banner { display:grid; grid-template-columns:1.35fr 1fr .8fr; border:1px solid var(--line); background:var(--panel); margin-bottom:10px; }
.transaction-range-banner > div { padding:15px 18px; border-right:1px solid var(--line); }
.transaction-range-banner > div:last-child { border-right:0; }
.transaction-range-banner small,.transaction-range-banner b,.transaction-range-banner span { display:block; }
.transaction-range-banner small { color:var(--dim); font:8px var(--mono); letter-spacing:.05em; }
.transaction-range-banner b { margin-top:7px; font:14px var(--mono); }
.transaction-range-banner span { margin-top:5px; color:var(--muted); font-size:8px; }
.transaction-table-header { min-height:58px; padding:13px 18px; display:flex; align-items:center; justify-content:space-between; gap:18px; border-bottom:1px solid var(--line); }
.transaction-table-header b,.transaction-table-header small { display:block; }
.transaction-table-header b { font-size:12px; }.transaction-table-header small { margin-top:3px; color:var(--dim); font-size:8px; }
.download-button { border:1px solid var(--line-strong); background:#fff; color:var(--ink); padding:8px 11px; border-radius:4px; cursor:pointer; font-size:9px; }
.download-button:hover { border-color:var(--jade); color:var(--jade); }
.transaction-filters { display:grid; grid-template-columns:minmax(220px,1.6fr) repeat(4,minmax(120px,.7fr)); gap:8px; padding:12px 18px; border-bottom:1px solid var(--line); background:#fafbf9; }
.transaction-filters label { min-width:0; border:1px solid var(--line); background:#fff; padding:6px 9px; }
.transaction-filters label>span { display:block; color:var(--dim); font-size:7px; margin-bottom:3px; }
.transaction-filters input,.transaction-filters select { width:100%; border:0; outline:0; background:transparent; color:var(--ink); font-size:9px; }
.transaction-search { display:flex; align-items:center; gap:9px; }
.transaction-search>span { margin:0!important; flex:0 0 auto; }
.transaction-description { min-width:260px; max-width:440px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; color:var(--muted); }
.transaction-table-panel table { min-width:1180px; }
.table-pagination { min-height:54px; display:flex; align-items:center; justify-content:center; gap:18px; border-top:1px solid var(--line); color:var(--muted); font:9px var(--mono); }
.table-pagination button { border:1px solid var(--line); background:#fff; padding:7px 12px; border-radius:4px; cursor:pointer; font-size:9px; }
.table-pagination button:disabled { opacity:.35; cursor:not-allowed; }

.profile-hero{border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:38px 0;display:grid;grid-template-columns:.7fr 1.1fr 1fr;gap:28px;align-items:center;margin-bottom:10px}.profile-hero>div{display:flex;gap:6px;flex-wrap:wrap}.profile-hero span{font:8px var(--mono);border:1px solid rgba(155,140,255,.35);color:var(--violet);padding:5px 7px}.profile-hero h2{font:28px/1.12 var(--serif);margin:0}.profile-hero p{font-size:10px;line-height:1.7;color:var(--muted);margin:0}.insight-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.insight-card{border:1px solid var(--line);padding:20px;background:var(--panel);min-height:210px}.insight-card .tag{font:8px var(--mono);color:var(--jade)}.insight-card h3{font:20px var(--serif);margin:16px 0 9px}.insight-card p{font-size:9px;color:var(--muted);line-height:1.6}.evidence{border-top:1px solid var(--line);margin-top:15px;padding-top:12px;font:8px var(--mono);color:var(--dim)}

.source-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:10px}.source-grid article{border:1px solid var(--line);background:var(--panel);padding:18px;min-height:175px}.source-badge{font:7px var(--mono);border:1px solid currentColor;padding:3px 5px}.source-badge.official{color:var(--jade)}.source-badge.matrix{color:var(--blue)}.source-badge.derived{color:var(--violet)}.source-badge.estimated{color:var(--amber)}.source-grid h3{font:17px var(--serif);margin:24px 0 8px}.source-grid p{font-size:9px;color:var(--muted);line-height:1.5}.source-grid article>small{font:8px var(--mono);color:var(--dim)}.data-gap ul{list-style:none;padding:0;margin:0}.data-gap li{display:grid;grid-template-columns:190px 1fr;padding:13px 0;border-bottom:1px solid var(--line);font-size:10px}.data-gap li:last-child{border:0}.data-gap span{color:var(--muted)}

.search-overlay { position:fixed;inset:0;z-index:80;display:none;place-items:start center;padding-top:9vh }.search-overlay.open{display:grid}.overlay-backdrop{position:absolute;inset:0;border:0;background:rgba(4,8,10,.72);backdrop-filter:blur(9px)}.search-dialog{position:relative;width:min(760px,calc(100vw - 30px));max-height:78vh;background:#121a1e;border:1px solid var(--line-strong);box-shadow:0 35px 100px rgba(0,0,0,.55);overflow:hidden}.search-input-row{display:flex;align-items:center;gap:14px;padding:18px;border-bottom:1px solid var(--line)}.search-input-row input{flex:1;border:0;outline:0;background:transparent;color:var(--ink);font:18px var(--serif)}.search-meta{display:flex;justify-content:space-between;padding:9px 18px;background:#0e1518;color:var(--dim);font-size:8px;letter-spacing:.08em}.search-results{max-height:62vh;overflow:auto;padding:10px}.search-empty{padding:60px 20px;text-align:center;color:var(--muted)}.search-empty b{display:block;font:26px var(--serif);color:var(--ink);margin-bottom:9px}.result-group h4{font:8px var(--mono);letter-spacing:.14em;color:var(--dim);padding:8px;margin:0}.search-result{width:100%;border:0;border-bottom:1px solid var(--line);background:transparent;padding:12px 10px;display:grid;grid-template-columns:44px 1fr auto;gap:12px;text-align:left;cursor:pointer}.search-result:hover{background:rgba(255,255,255,.035)}.result-symbol{font:10px var(--mono);color:var(--jade)}.search-result b,.search-result small{display:block}.search-result b{font-size:11px}.search-result small{font-size:8px;color:var(--muted);margin-top:3px}.search-result>span:last-child{font:8px var(--mono);color:var(--dim);align-self:center}
.asset-drawer{position:fixed;z-index:90;right:0;top:0;bottom:0;width:min(520px,100vw);background:#11191d;border-left:1px solid var(--line-strong);box-shadow:-30px 0 80px rgba(0,0,0,.45);padding:32px;transform:translateX(102%);transition:.35s cubic-bezier(.2,.8,.2,1);overflow:auto}.asset-drawer.open{transform:none}.drawer-close{position:absolute;right:18px;top:16px;border:0;background:transparent;color:var(--muted);font:26px var(--serif);cursor:pointer}.drawer-eyebrow{font:8px var(--mono);letter-spacing:.18em;color:var(--jade)}.drawer-title{font:42px/1 var(--serif);margin:10px 0 5px}.drawer-sub{color:var(--muted);font-size:10px}.drawer-kpis{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:25px 0}.drawer-kpis div{border:1px solid var(--line);padding:13px}.drawer-kpis small,.drawer-kpis b{display:block}.drawer-kpis small{font-size:7px;color:var(--dim)}.drawer-kpis b{font:14px var(--mono);margin-top:7px}.drawer-section{border-top:1px solid var(--line);padding-top:18px;margin-top:22px}.drawer-section h3{font:16px var(--serif);margin:0 0 12px}.drawer-section p,.drawer-section li{font-size:9px;line-height:1.6;color:var(--muted)}

/* Light, account-owner workspace: quiet hierarchy, functional titles, no campaign styling. */
.grain { opacity: .012; }
.sidebar { background: rgba(250,251,248,.96); }
.nav-item b { color: #506063; }
.nav-item:hover { background: rgba(24,39,40,.045); }
.nav-item.active { background: #e7eeea; }
.topbar { background: rgba(255,255,255,.9); }
.search-trigger { background: #f8f9f7; }
.search-trigger:hover { background: #f2f5f1; }
.search-trigger kbd, .search-input-row kbd { background: #eef1ed; }
.top-controls select { color: #344447; }
main { padding-top: 34px; }
.page.active { animation-duration: .24s; }
.page-heading { margin-bottom: 22px; }
.eyebrow { display: none; }
h1 { font: 600 clamp(23px,2.2vw,30px)/1.2 var(--sans); letter-spacing: -.025em; }
.heading-note { margin: 6px 0 0; font-size: 11px; line-height: 1.5; text-align: left; }
.reveal { animation-duration: .34s; }.delay-1 { animation-delay: .03s; }.delay-2 { animation-delay: .06s; }.delay-3 { animation-delay: .09s; }
.kpi-card { background: var(--panel); box-shadow: 0 1px 2px rgba(20,35,36,.025); }
.kpi-card:hover { transform: translateY(-2px); box-shadow: 0 7px 20px rgba(20,35,36,.07); }
.panel { box-shadow: 0 1px 2px rgba(20,35,36,.025); }
.bar-track, .loss-meter, .return-axis { background: #e8ece8; }
.view-toggle { background: #eef1ed; }
.view-toggle button.active { background: #fff; box-shadow: inset 0 -2px var(--jade),0 1px 3px rgba(20,35,36,.08); }
.view-toggle button[data-view="notional"].active { box-shadow: inset 0 -2px var(--violet),0 1px 3px rgba(20,35,36,.08); }
th { background: #f0f3ef; font-weight: 600; }
td { border-bottom-color: rgba(24,39,40,.075); color: #536164; }
.financing-hero > div { background: linear-gradient(145deg,var(--panel),#f4f6f3); }
.overlay-backdrop { background: rgba(31,42,44,.3); backdrop-filter: blur(7px); }
.search-dialog { background: #fff; box-shadow: 0 28px 80px rgba(26,39,40,.18); }
.search-meta { background: #f1f4f0; }
.search-result:hover { background: rgba(24,39,40,.04); }
.asset-drawer { background: #fff; box-shadow: -24px 0 70px rgba(26,39,40,.16); }

.account-viz-layout { display: grid; grid-template-columns: minmax(190px,.72fr) 1.28fr; gap: 18px; align-items: center; }
.chart-host { width: 100%; min-width: 0; position: relative; }
.donut-host { min-height: 220px; }
.return-chart { min-height: 280px; }
.behavior-chart-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 10px; margin-bottom: 10px; }
.activity-account-chart,.monthly-d3-chart { min-height: 250px; }
.chart-host svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-host .axis text { fill: var(--muted); font: 9px var(--mono); }
.chart-host .axis path,.chart-host .axis line { stroke: var(--line); }
.chart-host .grid line { stroke: var(--line); stroke-dasharray: 2 4; }
.chart-host .grid path { display: none; }
.chart-center-value { font: 600 18px var(--mono); fill: var(--ink); }
.chart-center-label { font: 8px var(--sans); fill: var(--muted); }
.chart-value-label { font: 10px var(--mono); fill: var(--ink); }
.chart-period-label { font: 8px var(--sans); fill: var(--dim); }
.chart-legend { display: flex; justify-content: flex-end; gap: 14px; margin: -3px 2px 8px; color: var(--muted); font-size: 8px; }
.monthly-legend { justify-content: flex-start; margin: -4px 0 2px 30px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 5px; }
.chart-legend i { width: 7px; height: 7px; display: inline-block; border-radius: 2px; }
.usd-dot { background: var(--jade); }.jpy-dot { background: var(--blue); }
.chart-tooltip { position: fixed; z-index: 120; pointer-events: none; opacity: 0; transform: translate(10px,-100%); background: #172426; color: #fff; border-radius: 5px; padding: 8px 10px; box-shadow: 0 8px 28px rgba(20,35,36,.18); font-size: 9px; line-height: 1.5; transition: opacity .12s ease; }
.chart-tooltip.visible { opacity: 1; }
.chart-tooltip b,.chart-tooltip small { display: block; }.chart-tooltip small { color: #c7d0ce; }
.chart-fallback { min-height: 180px; display: grid; place-items: center; color: var(--muted); font-size: 10px; border: 1px dashed var(--line); }
.coverage-panel { margin-bottom: 10px; }
.coverage-grid { display: grid; grid-template-columns: repeat(4,1fr); border-top: 1px solid var(--line); }
.coverage-grid > div { padding: 16px 16px 4px 0; border-right: 1px solid var(--line); }
.coverage-grid > div + div { padding-left: 16px; }
.coverage-grid > div:last-child { border-right: 0; }
.coverage-grid b,.coverage-grid small { display: block; }
.coverage-grid b { margin-top: 10px; font-size: 11px; }
.coverage-grid small { margin-top: 5px; color: var(--muted); font-size: 8px; line-height: 1.55; }
.coverage-status { font: 7px var(--mono); padding: 3px 5px; border: 1px solid currentColor; }
.coverage-status.complete { color: var(--jade); }.coverage-status.partial { color: var(--amber); }
.holding-group-row td { position:sticky; top:35px; z-index:1; background:#e9eeea; color:#435255; font:600 8px var(--mono); letter-spacing:.05em; padding:8px 14px; border-top:1px solid var(--line-strong); border-bottom:1px solid var(--line); }

/* Comfortable personal reading scale: this is a private dashboard, not a dense terminal. */
.heading-note { font-size: 14px; line-height: 1.65; }
.panel-head small { font-size: 11px; line-height: 1.5; margin-top: 4px; }
.panel-head button,
.status-strip button { font-size: 11px; }
.kpi-card .kpi-label b { font-size: 13px; }
.kpi-card .kpi-label small { font-size: 11px; }
.kpi-card p { font-size: 11px; line-height: 1.55; }
.confidence { font-size: 9px; }
.status-strip div small { font-size: 10px; }
.method-banner { align-items: flex-start; padding: 15px 17px; font-size: 13px; line-height: 1.7; }
.method-banner b { flex: 0 0 auto; }
.return-card small { font-size: 11px; }
.return-card h3 { font-size: 15px; }
.return-card p { font-size: 12px; line-height: 1.55; }
.account-card .entity { font-size: 10px; }
.account-card .mandate { font-size: 9px; }
.account-desc { min-height: 60px; font-size: 12px; line-height: 1.7; }
.account-stats b { font-size: 13px; }
.account-stats small { font-size: 10px; }
.risk-item b,
.definition-stack b { font-size: 12px; }
.risk-item small { font-size: 11px; line-height: 1.55; }
.event b,
.laggard b { font-size: 11px; }
.event small,
.laggard small,
.definition-stack small { font-size: 10px; line-height: 1.5; }
.definition-stack p { font-size: 11px; line-height: 1.65; }
.summary-card small,
.table-tools small { font-size: 10px; line-height: 1.45; }
.table-search input { font-size: 11px; }
th { font-size: 10px; line-height: 1.35; }
td { font-size: 11px; line-height: 1.45; }
td b { font-size: 12px; }
td small { font-size: 9px; }
td.num { font-size: 10px; }
.type-pill,
.status-pill { font-size: 9px; }
.financing-hero small,
.financing-hero span { font-size: 10px; }
.loan-row time,
.loan-row small { font-size: 10px; }
.loan-row b,
.loan-row strong { font-size: 11px; }
.transaction-kpis span,
.transaction-range-banner small,
.transaction-table-header small { font-size: 10px; }
.transaction-range-banner span { font-size: 10px; line-height: 1.5; }
.download-button,
.table-pagination,
.table-pagination button { font-size: 11px; }
.transaction-filters label > span { font-size: 9px; }
.transaction-filters input,
.transaction-filters select { font-size: 11px; }
.profile-hero span,
.insight-card .tag { font-size: 10px; }
.profile-hero p { font-size: 12px; line-height: 1.75; }
.insight-card p { font-size: 12px; line-height: 1.7; }
.evidence { font-size: 10px; line-height: 1.5; }
.source-badge { font-size: 9px; }
.source-grid p { font-size: 11px; line-height: 1.6; }
.source-grid article > small { font-size: 10px; }
.data-gap li { font-size: 12px; }
.search-meta,
.result-group h4 { font-size: 10px; }
.result-symbol { font-size: 11px; }
.search-result b { font-size: 12px; }
.search-result small,
.search-result > span:last-child { font-size: 10px; line-height: 1.45; }
.drawer-eyebrow,
.drawer-kpis small { font-size: 10px; }
.drawer-sub { font-size: 12px; }
.drawer-section p,
.drawer-section li { font-size: 12px; line-height: 1.7; }
.chart-host .axis text { font: 11px var(--mono); }
.chart-center-label,
.chart-period-label { font-size: 10px; }
.chart-legend { font-size: 11px; }
.chart-tooltip { font-size: 11px; line-height: 1.6; }
.coverage-grid b { font-size: 12px; }
.coverage-grid small { font-size: 11px; line-height: 1.6; }
.coverage-status { font-size: 9px; }
.holding-group-row td { font-size: 10px; }

/* Holdings are a reading surface, not a dense trading terminal. Use the available space. */
.account-holdings-table .table-tools { min-height: 72px; padding: 16px 20px; }
.account-holdings-table .table-tools b { font-size: 15px; }
.account-holdings-table .table-tools small { margin-top: 5px; font-size: 12px; }
.account-holdings-table .table-search { padding: 10px 13px; }
.account-holdings-table .table-search input { width: 220px; font-size: 13px; }
.account-holdings-table th { padding: 14px 16px; font-size: 12px; line-height: 1.45; }
.account-holdings-table td { padding: 18px 16px; font-size: 13px; line-height: 1.55; }
.account-holdings-table td b { font-size: 14px; }
.account-holdings-table td small { margin-top: 5px; font-size: 11px; line-height: 1.5; }
.account-holdings-table td.num { font-size: 13px; }
.account-holdings-table .type-pill,
.account-holdings-table .status-pill { padding: 4px 7px; font-size: 11px; }
.account-holdings-table .holding-group-row td { padding: 10px 16px; font-size: 11px; }
.account-holdings-table td:first-child { min-width: 390px; padding-top: 18px; padding-bottom: 18px; }
.account-holdings-table td:first-child b { font-size: 14px; line-height: 1.35; }
.account-holdings-table td:first-child small { margin-top: 6px; font-size: 12px; line-height: 1.55; color: var(--muted); }

@media (max-width: 1120px){
  :root{--sidebar:190px}.kpi-grid{grid-template-columns:repeat(2,1fr)}.account-card-grid,.insight-grid,.return-grid{grid-template-columns:repeat(2,1fr)}.source-grid{grid-template-columns:repeat(2,1fr)}.financing-hero,.derivative-kpis,.derivative-definition-strip{grid-template-columns:repeat(2,1fr)}.derivative-definition-strip>div:nth-child(2){border-right:0}.derivative-definition-strip>div:nth-child(-n+2){border-bottom:1px solid var(--line)}.account-viz-layout{grid-template-columns:1fr}.behavior-chart-grid{grid-template-columns:1fr}.coverage-grid{grid-template-columns:repeat(2,1fr)}.transaction-filters{grid-template-columns:1fr 1fr 1fr}.transaction-search{grid-column:1/-1}
  .account-balance-grid{grid-template-columns:repeat(2,1fr)}.account-two-col{grid-template-columns:1fr}
}
@media (max-width: 820px){
  .app-shell{display:block}.sidebar{position:fixed;top:auto;width:100%;height:66px;padding:0;bottom:0;border:0;border-top:1px solid var(--line);z-index:50}.brand,.read-only-seal{display:none}.side-nav{margin:0;display:flex;flex-direction:row;overflow-x:auto;height:100%}.nav-group{display:contents}.nav-group-label{display:none}.nav-item{min-width:75px;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:7px}.nav-item span,.nav-item small{display:none}.workspace{width:100%}.topbar{height:68px;padding:0 16px}.top-controls label{display:none}.asof{display:none}.search-trigger{width:100%}.mobile-brand{display:block;font:9px var(--mono);letter-spacing:.16em}.search-trigger span:nth-child(2){display:none}.search-trigger kbd{display:none}main{padding:26px 16px 95px}.page-heading{display:block}.heading-note{display:block;font-size:13px}h1{font-size:25px}.status-strip{grid-template-columns:1fr 1fr}.status-strip>*:nth-child(4),.status-strip>*:nth-child(5){display:none}.kpi-grid,.dashboard-grid,.return-grid,.two-col,.account-card-grid,.holdings-summary,.financing-hero,.transaction-kpis,.insight-grid,.source-grid,.transaction-range-banner{grid-template-columns:1fr}.transaction-range-banner>div{border-right:0;border-bottom:1px solid var(--line)}.transaction-range-banner>div:last-child{border-bottom:0}.profile-hero{grid-template-columns:1fr}.view-toggle{margin-top:18px;width:100%}.view-toggle button{flex:1}.allocation-row{grid-template-columns:90px 1fr 70px}.data-gap li{grid-template-columns:1fr;gap:4px}.kpi-card{min-height:135px}.panel{padding:16px}.top-controls{margin-left:0}.search-trigger{flex:1}.status-strip div:nth-child(3){border-right:0}.account-viz-layout{grid-template-columns:1fr}.behavior-chart-grid{grid-template-columns:1fr}.donut-host{min-height:190px}.coverage-grid{grid-template-columns:1fr}.coverage-grid>div{border-right:0;border-bottom:1px solid var(--line);padding:14px 0}.coverage-grid>div+div{padding-left:0}.transaction-filters{grid-template-columns:1fr}.transaction-search{grid-column:auto}.transaction-table-header{align-items:flex-start;flex-direction:column}.download-button{width:100%}
}

/* Mobile is a first-class reading layout: cards stack, controls stay reachable, wide data remains scrollable. */
@media (max-width: 820px) {
  body { -webkit-text-size-adjust: 100%; }
  .sidebar { height: calc(72px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: rgba(250,251,248,.98); }
  .side-nav { scrollbar-width: none; scroll-snap-type: x proximity; }
  .side-nav::-webkit-scrollbar { display: none; }
  .nav-item { min-width: 88px; display: flex; padding: 8px 10px; scroll-snap-align: center; text-align: center; }
  .nav-item b { font-size: 12px; white-space: nowrap; }
  .nav-item.active { box-shadow: inset 0 2px var(--jade); }
  .topbar { height: 64px; padding: 0 14px; gap: 10px; }
  .mobile-brand { flex: 0 0 auto; }
  .search-trigger { min-width: 0; padding: 10px; }
  .top-controls { display: none; }
  main { padding: 22px 14px calc(102px + env(safe-area-inset-bottom)); }
  .page-heading { margin-bottom: 20px; }
  .page-heading.compact { align-items: stretch; }
  .page-heading.compact .view-toggle { margin-top: 14px; }
  .method-banner { flex-direction: column; gap: 5px; padding: 14px; }
  .account-asof { margin-top:12px; }
  .account-tabs { margin-left:-14px; margin-right:-14px; padding-left:14px; padding-right:14px; border-left:0; border-right:0; }
  .account-tabs button { min-width:96px; }
  .account-register-panel > .panel-head { padding-left:14px; padding-right:14px; }
  .account-register-wrap { max-height:none; }
  .account-detail-head { align-items:flex-start; flex-direction:column; gap:10px; }
  .account-balance-grid { grid-template-columns:1fr 1fr; gap:8px; }
  .account-two-col { grid-template-columns:1fr; }
  .account-product-row { grid-template-columns:1fr auto 34px; }
  .financing-summary { grid-template-columns:1fr; }
  .financing-summary > div { border-right:0; border-bottom:1px solid var(--line); }
  .financing-summary > div:last-child { border-bottom:0; }
  .account-loan-row { grid-template-columns:72px 1fr; }
  .account-loan-row strong { grid-column:2; }
  .return-group { padding:14px; }
  .return-group > header { align-items:flex-start; flex-direction:column; gap:7px; }
  .return-group > header p { max-width:none; text-align:left; }
  .status-strip { margin-bottom: 14px; }
  .status-strip > * { padding: 10px; }
  .kpi-grid,
  .holdings-summary,
  .financing-hero,
  .transaction-kpis,
  .derivative-kpis { gap: 8px; }
  .kpi-card { min-height: 144px; }
  .kpi-card.portfolio-total { grid-column:span 1; }
  .kpi-card.portfolio-total strong { font-size:29px; }
  .dashboard-grid { gap: 8px; }
  .panel { padding: 15px; }
  .panel-head { gap: 10px; margin-bottom: 16px; }
  .panel-head > div { min-width: 0; }
  .panel-head button { flex: 0 0 auto; }
  .return-card,
  .account-card { min-height: 0; }
  .account-desc { min-height: 0; }
  .account-stats { gap: 8px; }
  .account-stats b { overflow-wrap: anywhere; }
  .view-toggle button { padding: 9px 10px; }
  .table-tools { align-items: stretch; flex-direction: column; gap: 12px; padding: 14px; }
  .table-search { width: 100%; }
  .table-search input { width: 100%; }
  .table-wrap { max-height: none; overscroll-behavior-x: contain; }
  table { min-width: 760px; }
  th,
  td { padding: 10px 11px; }
  th:first-child,
  td:first-child { position: sticky; left: 0; z-index: 1; background: #fff; box-shadow: 1px 0 var(--line); }
  th:first-child { z-index: 3; background: #f0f3ef; }
  .holding-group-row td:first-child { background: #e9eeea; }
  .asset-breakdown-panel { padding-top: 16px; }
  .asset-breakdown-panel > .panel-head,
  .asset-breakdown-panel > .breakdown-note,
  .asset-breakdown-panel > .product-breakdown-grid,
  .asset-breakdown-panel > .overlap-toolbar,
  .asset-breakdown-panel > .breakdown-source { margin-left: 14px; margin-right: 14px; }
  .breakdown-note { grid-template-columns: 1fr; gap: 5px; }
  .product-breakdown-grid { grid-template-columns: 1fr 1fr; }
  .overlap-toolbar { align-items: stretch; flex-direction: column; }
  .overlap-controls { align-items: stretch; flex-direction: column; }
  .overlap-search { width: 100%; min-width: 0; }
  .compact-toggle button { flex: 1; }
  .overlap-table-wrap { max-height: none; }
  .overlap-table { min-width: 1050px; }
  .derivative-definition-strip { grid-template-columns:1fr; }
  .derivative-definition-strip > div { border-right:0; border-bottom:1px solid var(--line); }
  .derivative-definition-strip > div:last-child { border-bottom:0; }
  .derivative-kpis { grid-template-columns:1fr 1fr; }
  .derivative-detail-grid { grid-template-columns:1fr; }
  .derivative-filter { padding-left:14px; padding-right:14px; }
  .derivative-register-panel > .panel-head { padding-left:14px; padding-right:14px; }
  .derivative-table-wrap { max-height:none; }
  .derivative-source { padding:13px 14px; }
  .transaction-range-banner > div { padding: 14px; }
  .transaction-filters { padding: 14px; }
  .transaction-pagination,
  .table-pagination { gap: 8px; }
  .loan-row { grid-template-columns: 76px 1fr; }
  .loan-row strong { grid-column: 2; }
  .profile-hero { padding: 24px 18px; }
  .profile-hero h2 { font-size: 25px; }
  .chart-legend { flex-wrap: wrap; justify-content: flex-start; margin-left: 0; }
  .drawer-title { font-size: 34px; }
  .asset-drawer { padding: 28px 20px 90px; }
  .drawer-kpis { grid-template-columns: 1fr; }
  .search-overlay { padding-top: 4vh; }
  .search-dialog { max-height: 88vh; }
  .search-result { grid-template-columns: 42px minmax(0,1fr); }
  .search-result > span:last-child { grid-column: 2; }
}

@media (max-width: 520px) {
  .access-gate { padding: 14px; }
  .access-gate-card { padding: 28px 20px; }
  .access-gate h1 { font-size: 27px; }
  .access-input-row { grid-template-columns: 1fr; gap: 8px; }
  .access-input-row input { border-right: 1px solid var(--line-strong); }
  .access-input-row button { width: 100%; }
  .status-strip { grid-template-columns: 1fr 1fr; }
  .allocation-row { grid-template-columns: 82px 1fr 66px; gap: 8px; }
  .currency-note { align-items: flex-start; flex-wrap: wrap; }
  .currency-note i { flex-basis: 100%; }
  .event { grid-template-columns: 66px 12px 1fr; }
  .event strong { grid-column: 3; margin-top: 3px; }
  .laggard { grid-template-columns: 1fr 82px; }
  .return-card strong { font-size: 27px; }
  .summary-card b { font-size: 16px; }
  .transaction-kpis b { font-size: 21px; }
  .product-breakdown-grid { grid-template-columns: 1fr; }
  .product-type-card { min-height: 112px; }
  .derivative-kpis { grid-template-columns:1fr; }
  .account-balance-grid { grid-template-columns:1fr; }
  .collateral-grid { grid-template-columns:1fr; }
  .collateral-grid > div { border-right:0; border-bottom:1px solid var(--line); }
  .collateral-grid > div:nth-last-child(-n+2) { border-bottom:1px solid var(--line); }
  .collateral-grid > div:last-child { border-bottom:0; }
}
