.theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:1px solid #dae5eb;background:#f5f8fa;color:#435e72;border-radius:999px;min-height:38px;padding:8px 12px;font-size:11px;font-weight:600;white-space:nowrap}
.theme-toggle svg,#sidebarToggle svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}.theme-moon{display:none}:root[data-theme=dark] .theme-sun{display:none}:root[data-theme=dark] .theme-moon{display:block}:root[data-theme=dark] .theme-toggle{background:#223247;border-color:#3b5067;color:#d4e5f2}
.sidebar-tools{display:flex;justify-content:flex-end;margin:-14px 0 12px}#sidebarToggle{display:grid;place-items:center;width:34px;height:34px;border:1px solid #46536a;border-radius:9px;background:transparent;color:#c7d9e8}#sidebarToggle:hover{background:#303e53;color:#fff}.brand-compact{display:none}.sidebar .nav .nav-text,.sidebar .nav-group-label .nav-text{width:auto;font:inherit;line-height:1.4;min-width:0}.sidebar nav>.nav>span:first-child{flex:none;text-align:center}.sidebar .nav-group-label>span:first-child:not(.nav-text){width:19px;text-align:center;flex:none}
@media(min-width:761px){
.sidebar-collapsed .sidebar{width:76px;padding:24px 12px}.sidebar-collapsed .sidebar-tools{justify-content:center;margin:-10px 0 18px}.sidebar-collapsed #sidebarToggle svg{transform:rotate(180deg)}.sidebar-collapsed .brand{padding:0 0 18px}.sidebar-collapsed .brand-artwork,.sidebar-collapsed .brand small,.sidebar-collapsed .side-label,.sidebar-collapsed .side-bottom,.sidebar-collapsed .tenant-selector,.sidebar-collapsed .sidebar .nav-text,.sidebar-collapsed .sidebar .chevron{display:none}.sidebar-collapsed .brand-compact{display:grid;place-items:center;margin:auto;width:40px;height:40px;border-radius:12px;background:#eaf7fa;color:#193648;font-size:25px;font-weight:800}.sidebar-collapsed .sidebar nav>.nav,.sidebar-collapsed .nav-group-title{justify-content:center;width:100%;padding:13px 0;gap:0}.sidebar-collapsed .nav-group-label{gap:0}.sidebar-collapsed .nav-group-title .nav-group-icon{width:19px;height:19px}.sidebar-collapsed .nav-submenu{display:none!important}.sidebar-collapsed .nav-group{margin:4px 0}.sidebar-collapsed .content{max-width:none}
}
@media(max-width:760px){.sidebar-tools{display:none}}
:root:root[data-theme=dark]{color-scheme:dark;background:#101923;color:#dce7f1;--kb-muted:#a5b8c9;--kb-support:#b5c5d4;--kb-surface:#1d3040}
:root[data-theme=dark] .brand-artwork{background:#fff}
:root[data-theme=dark] svg text{fill:#b9cede}
:root[data-theme=dark] .js-plotly-plot svg text{fill:unset}
:root[data-theme=dark] .sidebar{background:#151e2d}
:root[data-theme=dark] .topbar,:root[data-theme=dark] .user-dropdown{background:#192535;border-color:#304154}
:root[data-theme=dark] .toast{background:#294057;color:#edf6fc}
:root[data-theme=dark] :focus-visible{outline-color:#69d3e7}
@media(prefers-reduced-motion:reduce){.theme-toggle,#sidebarToggle{transition:none}}

:root[data-theme=dark] .sidebar .nav.active,:root[data-theme=dark] .sidebar .nav:hover,:root[data-theme=dark] .sidebar .nav-group[open]>.nav-group-title,:root[data-theme=dark] .sidebar .nav-group:has(.subnav.active)>.nav-group-title{background:#293e53;color:#f2f7fc}
:root[data-theme=dark] .button.dark{background:#286d87;border-color:#3a8ba6;color:#fff}
:root[data-theme=dark] .button.dark:hover{background:#327f99}

/* Supplied square isotype: exact artwork, with matched alignment at every size. */
.sidebar .brand-artwork,:root[data-theme=dark] .sidebar .brand-artwork{width:64px;height:64px;padding:0;margin:0 auto;background:#0e1524;border-radius:14px;overflow:hidden}
.sidebar .brand-artwork img{display:block;width:64px;height:64px;max-width:100%;object-fit:contain}
.sidebar .brand-compact img{display:block;width:40px;height:40px;max-width:100%;object-fit:contain}
.sidebar-collapsed .sidebar .brand-compact{background:#0e1524;border-radius:10px;overflow:hidden}
#userAvatar.user-avatar,:root[data-theme=dark] #userAvatar.user-avatar{width:40px;height:40px;flex:none;border-radius:50%;background:#0e1524 url('/brand-icon.svg') center/contain no-repeat;font-size:0;line-height:0;overflow:hidden}
.top-actions{align-items:center}.user-menu>summary{display:grid;place-items:center;padding:0;width:40px;height:40px}
#mobileApp .mb-header .mb-brand-icon{display:block;width:40px;height:40px;max-width:40px;border-radius:10px;object-fit:contain}
/* Match the supplied isotype's navy background in both appearance modes. */
.sidebar,:root[data-theme=dark] .sidebar{background:#0e1525}
.sidebar .brand-artwork,:root[data-theme=dark] .sidebar .brand-artwork,.sidebar-collapsed .sidebar .brand-compact{background:#0e1525}

/* Compact brand header: logo, identity and collapse control share a single row. */
.sidebar-brand-row{display:flex;align-items:center;gap:10px;margin:0 3px 20px;min-height:40px}
.sidebar-brand-row .brand{display:flex;align-items:center;gap:10px;flex:1;min-width:0;padding:0}
.sidebar-brand-row .brand-artwork,:root[data-theme=dark] .sidebar-brand-row .brand-artwork{width:40px;height:40px;margin:0;flex:none;border-radius:10px}
.sidebar-brand-row .brand-artwork img{width:40px;height:40px}
.sidebar-brand-row .brand-copy{min-width:0}.sidebar-brand-row .brand-copy strong{font-size:13px;letter-spacing:.02em;line-height:1.3;color:#edf6fc;white-space:nowrap}.sidebar-brand-row .brand-copy small{margin:4px 0 0;font-size:9px;letter-spacing:.08em;text-align:left;color:#9eb6c9}
.sidebar-brand-row .sidebar-tools{margin:0;flex:none;align-items:center}
.rail-tooltip{position:fixed;z-index:1500;max-width:240px;padding:9px 13px;border:1px solid #3b5269;border-radius:8px;background:#203348;color:#f2f7fc;font-size:12px;font-weight:600;line-height:1.5;box-shadow:0 5px 18px #07142233;pointer-events:none;overflow-wrap:anywhere}.rail-tooltip[hidden]{display:none}
@media(min-width:761px){.sidebar-collapsed .sidebar-brand-row{flex-direction:column;gap:9px;margin:0 0 15px}.sidebar-collapsed .sidebar-brand-row .brand{padding:0;flex:none}.sidebar-collapsed .sidebar-brand-row .brand-copy{display:none}.sidebar-collapsed .sidebar-brand-row .sidebar-tools{margin:0}.sidebar-collapsed .sidebar-brand-row #sidebarToggle{width:30px;height:28px}}

/* Mobile-only horizontal artwork, centered on its original white surface. */
@media(max-width:760px){
#mobileApp .mb-header,:root[data-theme=dark] #mobileApp .mb-header{display:grid;grid-template-columns:44px minmax(0,1fr) 44px;align-items:center;gap:8px;background:#fff;border-bottom-color:#e5edf1}
#mobileApp .mb-header .mb-brand-wordmark{display:block;width:124px;max-width:100%;height:49px;object-fit:contain;margin:0 auto;border-radius:0;background:#fff}
#mobileApp .mb-header button,:root[data-theme=dark] #mobileApp .mb-header button{color:#29495d;background:transparent}
}

/* Icon-only sidebar controls: clear chevrons without combined panel glyphs. */
#sidebarToggle{color:#e3f1fc;border:1px solid #3a5068;background:#16263a;border-radius:9px}
#sidebarToggle{width:36px;height:36px}
#sidebarToggle svg{display:block;width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round}
#sidebarToggle:hover{background:#264159;border-color:#6fabc8;color:#fff}
@media(min-width:761px){.sidebar-collapsed .sidebar-brand-row #sidebarToggle{width:36px;height:36px}.sidebar-collapsed .sidebar-brand-row{gap:10px}}

/* Identity fills the space between the isotype and arrow in the expanded menu. */
.sidebar-brand-row .brand-copy{display:flex;flex-direction:column;justify-content:center;gap:4px;min-width:0}
.sidebar-brand-row .brand-copy strong{font-size:12px;letter-spacing:.07em;line-height:1.3}
.sidebar-brand-row .brand-copy small{margin:0;font-size:8px;letter-spacing:0;line-height:1.4;white-space:nowrap}
@media(min-width:761px) and (max-width:1100px){.sidebar-brand-row{gap:8px;margin-inline:0}.sidebar-brand-row .brand{gap:8px}.sidebar-brand-row .brand-copy small{font-size:7.3px}}
@media(min-width:761px){.sidebar-collapsed .sidebar-brand-row .brand-copy{display:none}}

#communicationsNav{position:relative}#communicationsNav .communications-nav-badge{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;min-width:23px;height:22px;margin-left:auto;padding:0 6px;border-radius:12px;background:#45d69c;color:#102e27;font-size:11px;font-weight:800;font-variant-numeric:tabular-nums;box-sizing:border-box}#communicationsNav .communications-nav-badge[hidden]{display:none}.sidebar-collapsed #communicationsNav .communications-nav-badge{position:absolute;top:3px;right:1px;min-width:17px;height:17px;padding:0 4px;font-size:9px;box-shadow:0 0 0 2px #0e1525}
#communicationsNav .communications-nav-badge{background:#dc2626!important;color:#fff!important}

.message-attachment-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:12px 0 6px}.message-attachment-actions button{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--line,#cbd5e1);border-radius:8px;padding:9px 12px;background:var(--surface,#fff);color:var(--ink,#17334b);font:inherit;cursor:pointer}.message-attachment-actions small{color:var(--muted,#64748b);font-size:12px}.message-attachment-list{list-style:none;padding:0;margin:6px 0;display:grid;gap:6px}.message-attachment-list li{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid var(--line,#dbe4ed);border-radius:8px;background:var(--surface,#f8fafc)}.message-attachment-list span{min-width:0;overflow-wrap:anywhere}.message-attachment-list strong{font-size:13px}.message-attachment-list small{display:block;font-size:11px;color:var(--muted,#64748b)}.message-attachment-list button{flex:none;border:0;background:transparent;color:#b91c1c;font:inherit;font-size:12px;cursor:pointer}[data-attach-error]{font-size:12px;color:#b91c1c;margin:4px 0}.message-attachment-actions button:disabled,.message-attachment-list button:disabled{opacity:.5;cursor:default}

/* Collapsed rail: one logo and one expand button, each with its own row. */
@media(min-width:761px){
 .sidebar-collapsed .sidebar-brand-row{display:grid;grid-template-columns:1fr;grid-template-rows:40px 36px;justify-items:center;gap:12px;margin:0 0 20px;min-height:88px;flex-shrink:0}
 .sidebar-collapsed .sidebar-brand-row .brand{display:block;width:40px;height:40px;margin:0;padding:0}
 .sidebar-collapsed .sidebar-brand-row .brand-artwork,.sidebar-collapsed .sidebar-brand-row .brand-copy,.sidebar-collapsed .sidebar .tenant-selector{display:none}
 .sidebar-collapsed .sidebar-brand-row .brand-compact{display:grid;margin:0;width:40px;height:40px}
 .sidebar-collapsed .sidebar-brand-row .sidebar-tools{display:flex;position:static;margin:0;padding:0;flex-shrink:0}
 .sidebar-collapsed .sidebar-brand-row #sidebarToggle{position:static;margin:0;width:36px;height:36px;padding:0}
}

/* Page shortcut stays above the mobile bottom navigation and respects safe areas. */
.back-to-top{position:fixed;right:24px;bottom:24px;z-index:80;display:grid;place-items:center;width:46px;height:46px;padding:0;border:1px solid #14768b;border-radius:50%;background:#087d94;color:#fff;box-shadow:0 4px 16px #0f34442b;cursor:pointer;transition:background .15s,transform .15s}.back-to-top[hidden]{display:none}.back-to-top svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}.back-to-top:hover{background:#09677b;transform:translateY(-2px)}.back-to-top:focus-visible{outline:3px solid #42cbe7;outline-offset:4px}:root[data-theme=dark] .back-to-top{background:#147f97;border-color:#53b9cc;color:#fff}@media(max-width:760px){.back-to-top{right:16px;bottom:calc(88px + env(safe-area-inset-bottom,0px));width:44px;height:44px}}@media(prefers-reduced-motion:reduce){.back-to-top{transition:none}}
