/* All brand tokens, fonts, and surfaces come from CLOSE's actual brand.css
   (loaded first in index.html; root carries class="cc" for the Command Center
   surface). This file is layout/components only — no token redefinition. */
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; }
body { font-family: var(--font); color: var(--ink); background: var(--cc-bg); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
.hidden { display: none !important; }
a { color: var(--brand); text-decoration: none; }
.num, td.num, .v { font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }

/* ── login ── */
.overlay { position: fixed; inset: 0; background: var(--sidebar); z-index: 50; display: flex; align-items: center; justify-content: center; }
.login-card { background: var(--panel); border-radius: 18px; padding: 38px 36px; width: 340px; text-align: center; box-shadow: var(--shadow-card); }
.login-logo { width: 52px; height: 52px; border-radius: 12px; margin-bottom: 10px; }
.login-card h1 { font-size: 26px; font-weight: 800; letter-spacing: .04em; color: var(--brand-deep); }
.login-card p { color: var(--dim); font-size: 12.5px; margin: 4px 0 20px; }
.login-card input { width: 100%; padding: 11px 13px; margin-bottom: 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); font-family: inherit; font-size: 14px; }
.err { color: var(--bad); min-height: 1.2em; margin-top: 10px; font-size: 12.5px; }

button { background: var(--brand); color: #fff; border: 0; border-radius: 11px; padding: 9px 16px; font-size: 13.5px; font-weight: 700; letter-spacing: -.01em; cursor: pointer; font-family: inherit; transition: filter .15s ease; }
button:hover { filter: brightness(1.07); }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
button.ghost { background: var(--panel); border: 1px solid var(--line); color: var(--ink-soft); }
button:disabled { opacity: .5; cursor: not-allowed; }

/* ── shell: sidebar + main ── */
.shell { display: flex; min-height: 100vh; }
.sidebar { width: 232px; flex-shrink: 0; background: var(--sidebar); color: var(--sidebar-ink); padding: 18px 14px 14px; display: flex; flex-direction: column; gap: 18px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; align-items: center; gap: 10px; padding: 2px 6px; }
.brand-logo { width: 34px; height: 34px; border-radius: 9px; }
.brand-text { display: flex; flex-direction: column; }
.brand-group { font-size: 8.5px; font-weight: 700; letter-spacing: .14em; color: var(--sidebar-dim); }
.brand-name { font-size: 15px; font-weight: 800; letter-spacing: .02em; color: #fff; line-height: 1.2; }
.brand-mod { color: var(--sidebar-dim); font-weight: 600; }
nav { display: flex; flex-direction: column; gap: 3px; }
.nav-item { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 9px 10px; border-radius: 10px; background: transparent; color: var(--sidebar-dim); font-size: 13.5px; font-weight: 600; border: 0; cursor: pointer; }
.nav-item:hover { color: var(--sidebar-ink); background: rgba(255,255,255,.04); filter: none; }
.nav-item.active { color: #fff; background: color-mix(in oklab, var(--sidebar-active), transparent 82%); }
.nav-item.active .nav-ic { color: var(--sidebar-active); }
.nav-ic { width: 18px; text-align: center; font-size: 14px; }
.nav-item kbd { margin-left: auto; font-size: 10px; font-family: inherit; color: var(--sidebar-dim); border: 1px solid rgba(255,255,255,.14); border-radius: 5px; padding: 1px 5px; }
.side-stats { display: flex; flex-direction: column; gap: 9px; padding: 12px 10px; border-top: 1px solid rgba(255,255,255,.08); font-size: 12px; color: var(--sidebar-dim); }
.side-stats b { color: var(--sidebar-ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.side-stats .stat { color: var(--sidebar-dim); cursor: pointer; border-radius: 7px; margin: -3px -6px; padding: 3px 6px; transition: background .12s ease; }
.side-stats .stat:hover { background: rgba(255,255,255,.06); }
.side-stats .stat:hover b { color: var(--sidebar-active); }
.side-foot { margin-top: auto; font-size: 10.5px; line-height: 1.5; color: var(--sidebar-dim); padding: 0 10px; }

main { flex: 1; max-width: 1160px; padding: 26px 28px 80px; }
.page-title { font-size: 26px; font-weight: 800; letter-spacing: -.025em; margin-bottom: 2px; }
.page-sub { font-size: 14px; color: var(--dim); margin-bottom: 18px; }

/* ── search bar ── */
.searchbar { display: flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.searchbar input, .searchbar select { padding: 9px 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); font-family: inherit; font-size: 13.5px; }
.searchbar input[type="text"] { flex: 1; min-width: 220px; }

/* ── panels & tables ── */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin-bottom: 14px; box-shadow: var(--shadow-card); }
.panel h3 { font-size: 11.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--dim); margin-bottom: 10px; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); padding: 7px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 9px 10px; border-top: 1px solid var(--line); font-size: 13.5px; }
tr:first-child td { border-top: 0; }
tr.row:hover { background: var(--sand); cursor: pointer; }
.num { text-align: right; }
.muted { color: var(--dim); }
.pill { display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; letter-spacing: .02em; padding: 3px 9px; border-radius: 8px; background: var(--panel-2); color: var(--dim); white-space: nowrap; }
.pill.good { background: var(--good-bg); color: var(--good); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }

/* ── stat cards ── */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 14px 0; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 13px 15px; box-shadow: var(--shadow-card); }
.card .l { font-size: 11.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--dim); }
.card .v { font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: var(--num); margin-top: 4px; line-height: 1.1; }

/* ── home dashboard ── */
.viz-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
@media (max-width: 900px) { .viz-grid { grid-template-columns: 1fr; } }
.viz-grid .panel { margin-bottom: 0; }
.chart-box { position: relative; height: 230px; }
.covbar { display: flex; align-items: center; gap: 10px; margin: 9px 0; }
.covbar .cl { width: 110px; font-size: 12.5px; color: var(--ink-soft); font-weight: 600; flex-shrink: 0; }
.covbar .ct { flex: 1; height: 10px; background: var(--panel-2); border-radius: 6px; overflow: hidden; }
.covbar .cf { height: 100%; border-radius: 6px; background: var(--brand); }
.covbar .cv { width: 92px; text-align: right; font-size: 12px; color: var(--dim); font-variant-numeric: tabular-nums; flex-shrink: 0; }

.seg { display: inline-flex; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; gap: 2px; }
.seg-btn { background: transparent; color: var(--dim); border: 0; border-radius: 8px; padding: 6px 18px; font-size: 13px; font-weight: 700; cursor: pointer; }
.seg-btn:hover { color: var(--ink); filter: none; }
.seg-btn.active { background: var(--panel); color: var(--brand-deep); box-shadow: var(--shadow-card); }

/* Advisor list: name is the primary action (bold + brand link), firm is a quiet secondary link */
.adv-link { font-weight: 800; color: var(--ink); }
.adv-link:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }
tr.row:hover .adv-link { color: var(--brand); }
.firm-link { color: var(--dim); font-weight: 500; }
.firm-link:hover { color: var(--brand-deep); text-decoration: underline; }

.avatar { width: 58px; height: 58px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 2px solid var(--line); background: var(--panel-2); }
.avatar-mono { display: flex; align-items: center; justify-content: center; background: var(--brand-deep); color: #fff; font-size: 21px; font-weight: 800; border-color: var(--brand-deep); }
.logo { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 7px; background: var(--brand-deep); color: #fff; font-size: 12px; font-weight: 800; }
.logo-img { width: 26px; height: 26px; border-radius: 7px; object-fit: contain; background: #fff; border: 1px solid var(--line); }
.leaflet-popup-content { font-family: var(--font); font-size: 12.5px; }
.leaflet-container { font-family: var(--font); }

.enrich-btn { background: var(--panel); border: 1px solid var(--brand); color: var(--brand); border-radius: 8px; padding: 4px 10px; font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.enrich-btn:hover { background: var(--brand); color: #fff; filter: none; }
.enrich-btn:disabled { border-color: var(--line); color: var(--dim); background: var(--panel-2); }

.firm-head h2 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.firm-head .sub { color: var(--dim); font-size: 13px; margin-top: 2px; }
.links { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; font-size: 13px; font-weight: 600; }
.pager { display: flex; gap: 10px; align-items: center; margin-top: 12px; color: var(--dim); font-size: 13px; }

/* ── chat dock ── */
#chat { position: fixed; right: 0; top: 0; bottom: 0; width: 400px; max-width: 92vw; z-index: 40; background: var(--panel); border-left: 1px solid var(--line); display: flex; flex-direction: column; box-shadow: -8px 0 32px rgba(8,28,40,.12); }
.chat-head { display: flex; justify-content: space-between; align-items: center; padding: 13px 16px; border-bottom: 1px solid var(--line); background: var(--sidebar); }
.chat-title { font-weight: 800; font-size: 14px; color: #fff; letter-spacing: .02em; display: flex; align-items: center; gap: 8px; }
.andi-dot-static { width: 8px; height: 8px; border-radius: 9px; background: var(--peak-1); display: inline-block; }
.chat-head button { background: transparent; color: var(--sidebar-dim); font-size: 20px; padding: 0 6px; }
#chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--panel-2); }
.msg { padding: 10px 13px; border-radius: 13px; font-size: 13.5px; white-space: pre-wrap; word-wrap: break-word; line-height: 1.5; }
.msg.user { background: var(--brand); color: #fff; align-self: flex-end; max-width: 85%; }
.msg.bot { background: var(--panel); border: 1px solid var(--line); align-self: flex-start; max-width: 95%; }
.msg.steps { background: transparent; color: var(--dim); font-size: 10.5px; padding: 0 4px; font-variant-numeric: tabular-nums; }
#chat-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: var(--panel); }
#chat-form input { flex: 1; padding: 9px 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); font-family: inherit; font-size: 13.5px; }
.spinner { color: var(--dim); font-size: 12.5px; padding: 6px 10px; }
.spinner::after { content: "···"; color: var(--brand); animation: dotPulse 1s ease-in-out infinite; margin-left: 4px; }
@keyframes dotPulse { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }

@media (max-width: 900px) {
  .sidebar { width: 64px; padding: 18px 8px 14px; }
  .nav-label, .brand-text, .side-stats, .side-foot, .nav-item kbd { display: none; }
  .nav-item { justify-content: center; }
  main { padding: 18px 14px 60px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* ══════════════════════════════════════════════════════════════
   Advisor Section — design handoff (CLOSE · RIA "Today's targets"
   worklist + Dossier profile). Tokens from brand.css; these three
   aren't defined there, so derive them locally.
   ══════════════════════════════════════════════════════════════ */
:root { --brand-tint: #E2F4F6; --line-soft: #EDF2F7; --gold-bg: #FBF2DC; }

.adv-eyebrow { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.adv-eyebrow .src { font-weight: 700; opacity: .7; }

@keyframes adv-shimmer { 0% { background-position: -180% 0; } 100% { background-position: 180% 0; } }
.shimmer { background: linear-gradient(100deg, var(--panel-2) 38%, color-mix(in srgb, var(--brand) 9%, var(--panel-2)) 50%, var(--panel-2) 62%); background-size: 200% 100%; animation: adv-shimmer 1.5s ease-in-out infinite; border-radius: 7px; display: block; }
@keyframes adv-pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .45; transform: scale(.82); } }
.livedot { width: 7px; height: 7px; border-radius: 50%; background: var(--good); display: inline-block; animation: adv-pulse 1.8s ease-in-out infinite; }
@keyframes adv-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.fadein { animation: adv-fade .4s cubic-bezier(.22,1,.36,1) both; }

/* signal chips */
.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 700; letter-spacing: -.01em; padding: 4px 9px; border-radius: 7px; white-space: nowrap; line-height: 1; }
.chip svg { flex: 0 0 auto; }
.chip-on { background: var(--good-bg); color: var(--good); }
.chip-off { background: var(--panel-2); color: var(--dim); border: 1px dashed var(--line); }
.chip-brand { background: var(--brand-tint); color: var(--brand); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips.dense .chip { font-size: 11px; padding: 3px 8px; }

/* fit verdict */
.fit-badge { display: inline-flex; align-items: center; gap: 7px; border-radius: 9px; padding: 6px 12px; font-weight: 800; font-size: 14px; letter-spacing: -.01em; line-height: 1; }
.fit-badge .dot { width: 9px; height: 9px; border-radius: 50%; background: currentColor; }
.fit-good { background: var(--good-bg); color: var(--good); }
.fit-warn { background: var(--warn-bg); color: var(--warn); }
.fit-dim  { background: var(--panel-2); color: var(--dim); }
.fit-meter { display: flex; flex-direction: column; gap: 7px; }
.fit-meter .row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.fit-meter .score { font-weight: 800; font-size: 18px; line-height: 1; }
.fit-track { height: 6px; border-radius: 4px; background: var(--panel-2); overflow: hidden; }
.fit-fill { height: 100%; border-radius: 4px; transition: width .5s cubic-bezier(.22,1,.36,1); }

/* design buttons (distinct from the global solid button) */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-family: inherit; font-weight: 700; font-size: 14px; letter-spacing: -.01em; border-radius: 11px; border: 1px solid transparent; cursor: pointer; padding: 12px 18px; transition: all .15s; white-space: nowrap; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 88%, #000); filter: none; }
.btn-ghost { background: var(--panel); color: var(--ink-soft); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); filter: none; }
.btn[disabled] { opacity: .7; cursor: default; }
.btn.full { width: 100%; }

/* ── Worklist "Today's targets" ── */
.wl-head h1 { font-size: 27px; font-weight: 800; letter-spacing: -.03em; }
.wl-live { display: inline-flex; align-items: center; gap: 6px; background: var(--brand-tint); color: var(--brand); border-radius: 8px; padding: 5px 10px; font-size: 12px; font-weight: 800; white-space: nowrap; }
.wl-utility { display: flex; gap: 10px; align-items: center; margin: 18px 0 20px; }
.wl-search { flex: 1; display: flex; align-items: center; gap: 9px; background: var(--panel); border: 1px solid var(--line); border-radius: 11px; padding: 10px 14px; }
.wl-search input { border: 0; background: transparent; flex: 1; font-family: inherit; font-size: 13.5px; color: var(--ink); }
.wl-search input::placeholder { color: var(--dim); }
.selectish { display: flex; align-items: center; gap: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: 11px; padding: 9px 12px; font-size: 13px; font-weight: 600; color: var(--ink-soft); white-space: nowrap; }
.selectish select { border: 0; background: transparent; font-family: inherit; font-size: 13px; font-weight: 600; color: var(--ink-soft); cursor: pointer; }
.wl-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-card); overflow: hidden; }
.wl-grid { display: grid; grid-template-columns: 52px 1.55fr 1.4fr 232px 152px 116px 18px; gap: 16px; align-items: center; }
.wl-thead { padding: 13px 22px; border-bottom: 1px solid var(--line); background: var(--panel-2); font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.wl-row { padding: 15px 22px; border-bottom: 1px solid var(--line-soft); cursor: pointer; transition: background .12s; }
.wl-row:last-child { border-bottom: 0; }
.wl-row:hover { background: var(--panel-2); }
.wl-row:hover .wl-name { color: var(--brand); }
.wl-score { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.wl-score .n { font-weight: 800; font-size: 19px; line-height: 1; }
.wl-score .lbl { font-size: 9px; font-weight: 800; letter-spacing: .06em; color: var(--dim); text-transform: uppercase; }
.wl-name { font-weight: 800; font-size: 15.5px; letter-spacing: -.015em; color: var(--ink); transition: color .12s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wl-sub { font-size: 12.5px; color: var(--dim); margin-top: 2px; }
.wl-firm { font-size: 13.5px; color: var(--ink-soft); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wl-fact { font-size: 12.5px; color: var(--dim); }
.wl-fact b { color: var(--ink-soft); font-weight: 700; }
.wl-stat { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; }
.wl-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; font-size: 13px; color: var(--dim); }

/* ── Dossier profile ── */
.dossier { display: grid; grid-template-columns: 300px 1fr; gap: 20px; align-items: start; }
@media (max-width: 860px) { .dossier { grid-template-columns: 1fr; } }
.crumb { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.crumb-back { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); background: var(--panel); border-radius: 9px; padding: 7px 12px; font-size: 12.5px; font-weight: 700; color: var(--ink-soft); cursor: pointer; }
.crumb-back:hover { border-color: var(--brand); color: var(--brand); filter: none; }
.crumb-firm { font-size: 12.5px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--brand); }
.rail { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 16px; }
@media (max-width: 860px) { .rail { position: static; } }
.adv-av { width: 56px; height: 56px; border-radius: 50%; background: var(--brand-deep); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 20px; }
.adv-sq { width: 30px; height: 30px; border-radius: 8px; background: var(--brand-deep); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; flex: 0 0 auto; }
.rail-name { font-weight: 800; font-size: 21px; letter-spacing: -.025em; line-height: 1.1; }
.rail-stat { display: flex; align-items: center; justify-content: space-between; }
.rail-stat .k { font-size: 12.5px; color: var(--dim); font-weight: 600; }
.rail-stat .v { font-weight: 800; font-size: 16px; color: var(--num); }
.opening { border-left: 3px solid var(--brand); background: var(--sand); border-radius: 0 12px 12px 0; padding: 14px 18px 14px 16px; }
.opening .txt { font-size: 15px; line-height: 1.55; color: var(--ink); font-weight: 500; }
.enrich-gate { border: 1px solid var(--brand); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow-card); }
.enrich-gate .body { padding: 22px 24px 24px; background: linear-gradient(180deg, var(--brand-tint), var(--panel) 60%); }
.enrich-gate h4 { font-weight: 800; font-size: 16.5px; letter-spacing: -.02em; margin-bottom: 11px; display: flex; align-items: center; gap: 9px; }
.enrich-gate .unlocks { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 20px; margin: 16px 0 20px; }
.enrich-gate .unlocks div { display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--ink-soft); }
.disc-chip { display: inline-flex; align-items: center; gap: 7px; border-radius: 9px; padding: 7px 12px; font-weight: 700; font-size: 12.5px; letter-spacing: -.01em; border: 0; }
.disc-clean { background: var(--good-bg); color: var(--good); cursor: default; }
.disc-has { background: var(--warn-bg); color: var(--warn); cursor: pointer; }
.dossier .panel { margin-bottom: 0; }
.dcol { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.stat-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-card); padding: 16px 18px; flex: 1; min-width: 0; }
.stat-card .l { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); margin-bottom: 8px; }
.stat-card .v { font-weight: 800; font-size: 26px; letter-spacing: -.02em; color: var(--num); line-height: 1; }
.stat-row { display: flex; gap: 14px; }

/* advisor drill-down facet chips */
.facetbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--panel-2); }
.facetbar-l { font-size: 10.5px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--dim); margin-right: 2px; }
.facet-chip { background: var(--panel); border: 1px solid var(--line); color: var(--ink-soft); border-radius: 999px; padding: 5px 11px; font-size: 12.5px; font-weight: 600; cursor: pointer; transition: all .12s; }
.facet-chip:hover { border-color: var(--brand); color: var(--brand); filter: none; }
.facet-chip .num { color: var(--dim); font-weight: 700; margin-left: 3px; }
.facet-chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.facet-chip.on .num { color: rgba(255,255,255,.8); }
.facet-chip:disabled { opacity: .4; cursor: default; }
.facet-chip.clear { border-style: dashed; color: var(--dim); }

/* sidebar saved badge */
.nav-badge { margin-left: auto; font-size: 11px; font-weight: 800; background: var(--brand); color: #fff; border-radius: 999px; padding: 1px 7px; min-width: 18px; text-align: center; }

/* ── Advisor sales cards ── */
.adv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 12px; padding: 14px; }
.adv-card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 15px 16px 13px; box-shadow: var(--shadow-card); cursor: pointer; transition: border-color .12s, box-shadow .12s; display: flex; flex-direction: column; gap: 10px; }
.adv-card:hover { border-color: var(--brand); box-shadow: 0 4px 16px rgba(16,160,176,.13); }
.ac-head { display: flex; gap: 12px; align-items: flex-start; }
.ac-av { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex: 0 0 46px; border: 1px solid var(--line); }
.ac-mono { display: flex; align-items: center; justify-content: center; background: var(--brand-deep); color: #fff; font-weight: 800; font-size: 16px; border-color: var(--brand-deep); }
.ac-name { font-weight: 800; font-size: 15.5px; letter-spacing: -.01em; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adv-card:hover .ac-name { color: var(--brand); }
.ac-sub { font-size: 12.5px; color: var(--ink-soft); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac-sub2 { font-size: 12px; color: var(--dim); margin-top: 1px; }
.ac-score { flex: 0 0 auto; font-weight: 800; font-size: 16px; padding: 3px 9px; border-radius: 9px; font-variant-numeric: tabular-nums; }
.ac-score.good { background: var(--good-bg); color: var(--good); }
.ac-score.warn { background: var(--warn-bg); color: var(--warn); }
.ac-score.dim { background: var(--panel-2); color: var(--dim); }
.ac-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.ac-chip { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 7px; background: var(--panel-2); color: var(--dim); white-space: nowrap; }
.ac-chip.on { background: var(--good-bg); color: var(--good); }
.ac-chip.bad { background: var(--bad-bg); color: var(--bad); }
.ac-chip.gold { background: var(--gold-bg); color: var(--gold); }
.ac-why { font-size: 12.5px; color: var(--ink-soft); line-height: 1.4; border-left: 2px solid var(--brand); padding-left: 9px; }
.ac-ctas { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 1px; }
.ac-cta { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 7px 12px; border-radius: 9px; border: 1px solid var(--line); color: var(--ink-soft); background: var(--panel); }
.ac-cta:hover { border-color: var(--brand); color: var(--brand); text-decoration: none; }
.ac-cta.call { background: var(--brand); color: #fff; border-color: var(--brand); }
.ac-cta.call:hover { background: var(--brand-deep); color: #fff; }
.ac-cta.mail { background: var(--brand-tint); color: var(--brand); border-color: transparent; }
.ac-save { position: absolute; top: 11px; right: 12px; background: transparent; border: 0; font-size: 19px; line-height: 1; color: var(--line); cursor: pointer; padding: 2px; z-index: 2; }
.ac-save:hover { color: var(--gold); filter: none; }
.ac-save.on { color: var(--gold); }

/* bulk-select checkbox (top-right of card) */
.ac-check { position: absolute; top: 10px; right: 11px; z-index: 3; display: inline-flex; padding: 3px; cursor: pointer; }
.ac-check input { width: 17px; height: 17px; accent-color: var(--brand); cursor: pointer; }
.adv-card.sel { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand-tint), var(--shadow-card); }

/* per-card action row: Target + Enrich */
.ac-actions { display: flex; gap: 7px; margin-top: 2px; padding-top: 10px; border-top: 1px solid var(--line); }
.ac-tgt, .ac-enr { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 5px; font-family: inherit; font-size: 12.5px; font-weight: 700; padding: 8px 10px; border-radius: 9px; cursor: pointer; white-space: nowrap; transition: all .13s; }
.ac-tgt { background: var(--panel); border: 1px solid var(--line); color: var(--ink-soft); }
.ac-tgt:hover { border-color: var(--gold); color: var(--gold); filter: none; }
.ac-tgt.on { background: var(--gold); border: 1px solid var(--gold); color: #3a2c00; }
.ac-enr { background: var(--brand-tint); border: 1px solid transparent; color: var(--brand-deep); }
.ac-enr:hover { background: var(--brand); color: #fff; filter: none; }
.ac-enr.re { background: var(--panel); border: 1px solid var(--line); color: var(--ink-soft); }
.ac-enr.re:hover { background: var(--brand-tint); color: var(--brand-deep); border-color: transparent; }

/* floating bulk action bar */
#bulk-bar { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 60; display: flex; align-items: center; gap: 10px; background: var(--sidebar); color: #fff; padding: 10px 12px 10px 18px; border-radius: 14px; box-shadow: 0 10px 34px rgba(8,28,40,.32); animation: bbpop .16s ease; }
@keyframes bbpop { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }
#bulk-bar .bb-n { font-size: 13px; font-weight: 700; letter-spacing: -.01em; }
#bulk-bar .bb-btn { padding: 8px 14px; font-size: 13px; }
#bulk-bar .bb-x { background: transparent; border: 0; color: #9fb6c2; font-size: 15px; padding: 4px 6px; cursor: pointer; }
#bulk-bar .bb-x:hover { color: #fff; filter: none; }

/* toast */
#toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%) translateY(8px); z-index: 70; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 11px; font-size: 13px; font-weight: 600; box-shadow: 0 8px 24px rgba(8,28,40,.28); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* confirm modal */
.modal-ov { position: fixed; inset: 0; z-index: 80; background: rgba(8,28,40,.42); display: flex; align-items: center; justify-content: center; padding: 20px; animation: bbpop .12s ease; }
.modal { background: var(--panel); border-radius: 16px; max-width: 420px; width: 100%; padding: 22px 22px 18px; box-shadow: 0 20px 60px rgba(8,28,40,.3); }
.modal-title { font-size: 17px; font-weight: 800; letter-spacing: -.01em; color: var(--brand-deep); margin-bottom: 8px; }
.modal-body { font-size: 13.5px; color: var(--ink-soft); line-height: 1.55; margin-bottom: 18px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; }
.modal-actions .btn { padding: 9px 16px; font-size: 13px; }

@media (max-width: 560px) { .adv-grid { grid-template-columns: 1fr; } }

/* printable marketing brief — hide chrome, keep the one-pager */
@media print {
  .sidebar, #chat, [data-noprint] { display: none !important; }
  body { background: #fff; }
  main { max-width: none; padding: 0; }
  .panel { box-shadow: none; border: 0; }
}

/* ════ Breakaway Radar v2 (from Claude Design handoff) ════ */
:root{
  --lane-pinnacle:#B57305; --lane-pinnacle-bg:#FBF0DC;
  --lane-riava:#0F8C5D;    --lane-riava-bg:#E4F4ED;
  --lane-finspire:#7C53D6; --lane-finspire-bg:#EFE9FB;
  --lane-clientgen:#0E8FBF;--lane-clientgen-bg:#E2F1F9;
  --heat-cool:#10A0B0; --heat-warm:#D9730D; --heat-hot:#C53030;
  --heat-cool-bg:#E2F4F6; --heat-warm-bg:#FBE9D6; --heat-hot-bg:#FBE3E3;
  --rebrand:#7A8A99; --rebrand-bg:#EEF2F6;
}
.bw-brief{ display:flex; align-items:stretch; gap:24px; flex-wrap:wrap; background:var(--panel);
  border:1px solid var(--line); border-radius:14px; padding:15px 20px; margin-bottom:16px; box-shadow:var(--shadow-card); }
.bw-stat{ display:flex; flex-direction:column; gap:2px; padding-right:24px; border-right:1px solid var(--line); cursor:pointer; }
.bw-stat:last-child{ border-right:0; }
.bw-stat .bn{ font-size:23px; font-weight:800; letter-spacing:-.02em; font-variant-numeric:tabular-nums; color:var(--ink); line-height:1; }
.bw-stat .bl{ font-size:11.5px; font-weight:600; color:var(--dim); }
.bw-stat.on .bn, .bw-stat:hover .bn{ color:var(--brand); }
.bw-grid2{ display:grid; grid-template-columns:212px minmax(0,1fr); gap:20px; align-items:start; }
@media (max-width:900px){ .bw-grid2{ grid-template-columns:1fr; } .bw-rail{ display:none; } }
.bw-rail{ position:sticky; top:14px; }
.facet{ display:flex; align-items:center; justify-content:space-between; gap:8px; padding:7px 10px; border-radius:8px;
  cursor:pointer; font-size:13px; color:var(--ink-soft); transition:background .12s; }
.facet:hover{ background:var(--panel-2); }
.facet.on{ background:var(--brand-tint); color:var(--brand); font-weight:700; }
.facet .ct{ font-size:11.5px; font-weight:700; color:var(--dim); font-variant-numeric:tabular-nums; }
.facet.on .ct{ color:var(--brand); }
.facet-head{ font-size:10.5px; font-weight:800; letter-spacing:.09em; text-transform:uppercase; color:var(--dim); margin:16px 0 6px; }
.facet-head:first-child{ margin-top:0; }
.lens{ display:inline-flex; gap:3px; background:var(--panel-2); border:1px solid var(--line); border-radius:11px; padding:3px; flex-wrap:wrap; }
.lens button{ border:0; background:transparent; font:inherit; font-size:12.5px; font-weight:700; color:var(--dim); padding:7px 12px;
  border-radius:8px; cursor:pointer; letter-spacing:-.01em; transition:all .14s; white-space:nowrap; display:inline-flex; align-items:center; gap:6px; }
.lens button:hover{ color:var(--ink); }
.lens button[aria-pressed="true"]{ background:var(--panel); color:var(--ink); box-shadow:0 1px 2px rgba(12,32,48,.12); }
.lens .lct{ font-size:11px; font-weight:800; font-variant-numeric:tabular-nums; opacity:.75; }
.bw-newdiv{ display:flex; align-items:center; gap:10px; padding:4px 0; font-size:11.5px; font-weight:800; letter-spacing:.04em; color:var(--brand); text-transform:uppercase; }
.bw-newdiv::after{ content:""; flex:1; height:1px; background:linear-gradient(90deg,var(--brand),transparent); opacity:.4; }
.pulse-dot{ width:7px; height:7px; border-radius:50%; background:var(--brand); display:inline-block; animation:bwpulse 1.8s ease-in-out infinite; }
@keyframes bwpulse{ 0%,100%{ opacity:1 } 50%{ opacity:.3 } }
/* cluster hero */
.bw-cluster{ background:var(--panel); border:1px solid var(--line); border-left:4px solid var(--brand); border-radius:16px;
  box-shadow:var(--shadow-card); overflow:hidden; transition:box-shadow .15s; margin-bottom:14px; }
.bw-cluster:hover{ box-shadow:var(--shadow-pop); }
.bw-cluster.advw{ border-left-color:var(--warn); }
.bw-cluster.rebrand{ opacity:.85; border-left-color:var(--rebrand); }
.bw-clbody{ padding:17px 19px; }
.bw-clhead{ margin:0 0 8px; font-size:18px; font-weight:800; letter-spacing:-.02em; line-height:1.2; }
.bw-clmembers{ display:grid; grid-template-columns:1fr 1fr; gap:9px; padding:12px 19px 16px; border-top:1px solid var(--line); }
.bw-member{ display:flex; align-items:center; gap:10px; padding:9px 11px; border-radius:10px; border:1px solid var(--line); background:var(--panel); cursor:pointer; }
.bw-member:hover{ border-color:var(--brand); }
.bw-clexp{ width:100%; border:0; border-top:1px solid var(--line); background:var(--panel-2); font:inherit; font-size:12.5px;
  font-weight:700; color:var(--ink-soft); padding:9px; cursor:pointer; }
/* mover row */
.bw-row{ background:var(--panel); border:1px solid var(--line); border-radius:13px; display:grid; grid-template-columns:50px 1fr auto;
  gap:15px; align-items:start; padding:13px 15px; cursor:pointer; transition:border-color .12s, box-shadow .12s; margin-bottom:10px; }
.bw-row:hover{ border-color:var(--brand); box-shadow:var(--shadow-card); }
.bw-row.worked{ grid-template-columns:1fr auto; opacity:.6; padding:9px 15px; align-items:center; }
.heat{ display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; width:50px; height:50px; border-radius:12px; flex:0 0 50px; }
.heat .hn{ font-weight:800; font-size:20px; line-height:1; font-variant-numeric:tabular-nums; }
.heat .hl{ font-size:8px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; opacity:.85; }
.rstack{ display:flex; flex-wrap:wrap; gap:6px; }
.rpill{ display:inline-flex; align-items:center; gap:5px; font-size:11px; font-weight:700; letter-spacing:-.01em; padding:3px 8px;
  border-radius:6px; line-height:1.3; white-space:nowrap; background:var(--panel-2); color:var(--ink-soft); }
.rpill.amber{ background:var(--warn-bg); color:var(--warn); }
.rpill.amber::before{ content:""; width:5px; height:5px; border-radius:50%; background:currentColor; }
.lane{ display:inline-flex; align-items:center; gap:6px; font-size:11px; font-weight:800; letter-spacing:-.01em; padding:4px 9px; border-radius:7px; line-height:1; white-space:nowrap; }
.lane::before{ content:""; width:6px; height:6px; border-radius:50%; background:currentColor; }
.bw-why{ display:flex; align-items:flex-start; gap:8px; background:var(--warn-bg); color:var(--warn); border-radius:9px;
  padding:8px 11px; font-size:12px; font-weight:600; line-height:1.4; margin-top:8px; }
.bw-btn{ display:inline-flex; align-items:center; justify-content:center; gap:6px; font:inherit; font-weight:700; font-size:12.5px;
  border-radius:9px; border:1px solid var(--line); cursor:pointer; padding:8px 12px; background:var(--panel); color:var(--ink-soft); transition:all .14s; white-space:nowrap; }
.bw-btn:hover{ border-color:var(--brand); color:var(--brand); }
.bw-btn.primary{ background:var(--brand); color:#fff; border-color:transparent; }
.bw-btn.primary:hover{ filter:brightness(.92); color:#fff; }
.bw-btn.icon{ padding:8px; }
.bw-aum{ display:inline-flex; align-items:center; gap:7px; background:var(--panel-2); border-radius:8px; padding:5px 10px; font-size:12px; font-weight:700; color:var(--ink-soft); }
.bw-newshop{ font-size:9.5px; font-weight:800; letter-spacing:.05em; text-transform:uppercase; background:var(--brand-tint); color:var(--brand); border-radius:5px; padding:2px 6px; }
.bw-rebtoggle{ align-self:flex-start; border:1px dashed var(--line); background:transparent; font:inherit; font-size:12px;
  font-weight:700; color:var(--rebrand); padding:8px 13px; border-radius:9px; cursor:pointer; display:inline-flex; align-items:center; gap:8px; margin-bottom:14px; }

/* ── Breakaway Radar: destination/prior firm detail panel ── */
.firm-panel { display:flex; gap:12px; align-items:flex-start; margin-top:11px; padding:11px 12px; background:var(--panel-2); border:1px solid var(--line); border-radius:12px; }
.firm-logo-wrap { flex:0 0 auto; display:inline-block; position:relative; }
.firm-logo { object-fit:contain; border-radius:9px; background:#fff; border:1px solid var(--line); padding:3px; box-sizing:border-box; }
.firm-logo-fb { align-items:center; justify-content:center; border-radius:9px; background:var(--brand-deep,#072530); color:#fff; font-weight:800; letter-spacing:.01em; }
.firm-panel-lbl { font-size:10.5px; font-weight:800; letter-spacing:.05em; text-transform:uppercase; color:var(--dim); margin-bottom:2px; display:flex; align-items:center; gap:6px; }
.firm-panel-nm { font-size:14.5px; font-weight:800; letter-spacing:-.015em; color:var(--ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.firm-panel-meta { font-size:12px; color:var(--dim); margin-top:2px; }
.firm-panel-brief { margin-top:6px; display:flex; gap:6px; flex-wrap:wrap; align-items:center; }
.fp-tag { font-size:12px; font-style:italic; color:var(--ink-soft); }
.fp-niche { font-size:10.5px; font-weight:700; padding:2px 7px; border-radius:7px; background:var(--brand-wash,rgba(16,160,176,.1)); color:var(--brand); }
.fp-briefbadge { font-size:9.5px; font-weight:800; padding:1px 6px; border-radius:6px; background:rgba(16,160,176,.12); color:var(--brand); letter-spacing:.02em; text-transform:none; }
.firm-panel-nobrief { font-size:11.5px; color:var(--dim); margin-top:4px; font-style:italic; opacity:.8; }
.firm-site { font-weight:800; color:var(--brand); font-size:13px; }

/* ── Breakaway Radar P2: Exodus/Magnet insights rail ── */
#bw-insights { margin-bottom: 16px; }
.bw-insights-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lb-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; box-shadow: var(--shadow-card); }
.lb-card.exodus { border-top: 3px solid var(--rebrand, #d97757); }
.lb-card.magnet { border-top: 3px solid var(--brand); }
.lb-head { font-size: 13px; font-weight: 800; letter-spacing: -.01em; color: var(--ink); display: flex; align-items: center; gap: 7px; margin-bottom: 8px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.lb-ic { font-size: 15px; }
.lb-card.exodus .lb-ic { color: var(--rebrand, #d97757); }
.lb-card.magnet .lb-ic { color: var(--brand); }
.lb-hsub { font-size: 10.5px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; color: var(--dim); }
.lb-row { display: flex; align-items: center; gap: 9px; padding: 5px 4px; border-radius: 8px; color: inherit; }
.lb-row:hover { background: var(--panel-2); }
.lb-nm { flex: 1; min-width: 0; }
.lb-firm { font-size: 12.5px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-sub { font-size: 10.5px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-ct { font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; flex: 0 0 auto; padding: 1px 7px; border-radius: 7px; }
.lb-ct.exodus { color: var(--rebrand, #d97757); background: rgba(217,119,87,.1); }
.lb-ct.magnet { color: var(--brand); background: rgba(16,160,176,.1); }
.bw-geo { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 12px; padding: 9px 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 11px; }
.bw-geo-lbl { font-size: 10.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--dim); }
.geo-pip { font-size: 11.5px; font-weight: 600; color: var(--ink-soft); }
.geo-pip b { color: var(--num); font-weight: 800; margin-left: 3px; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .bw-insights-grid { grid-template-columns: 1fr; } }

/* company logo with initials fallback (career · via ClientGen) */
.logo-wrap { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; flex: 0 0 26px; }
.logo-img { padding: 2px; box-sizing: border-box; }
