/* Alara Resources board dashboard. Colours taken from the Alara logo. */
:root {
  color-scheme: light;
  --brand-ink: #1e363c;      /* ALARA wordmark */
  --brand-orange: #d89054;   /* top chevron */
  --brand-clay: #c65430;     /* lower arc */
  --bg: #f6f2ec;
  --surface: #fffdfa;
  --surface-2: #f3eee6;
  --line: #e6ded2;
  --grid: #ece6dc;
  --text: #1e363c;
  --text-2: #4f5f63;
  --muted: #7b8689;
  --human: #008f80;          /* verified humans (validated vs surface, CVD-safe with --bot) */
  --human-wash: rgba(0, 143, 128, .12);
  --bot: #c65430;
  --unverified: #b9b3a8;
  --up: #1d7a46; --down: #b3261e;
  --shadow: 0 1px 2px rgba(30, 54, 60, .06), 0 4px 16px rgba(30, 54, 60, .05);
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #111a1d; --surface: #172327; --surface-2: #1d2b30; --line: #273a40; --grid: #22343a;
    --text: #eef1ef; --text-2: #c2cbcb; --muted: #8d9a9c;
    --human: #13a093; --human-wash: rgba(19, 160, 147, .16); --bot: #d9603a; --unverified: #5d6a6c;
    --up: #4cc38a; --down: #ff8a80;
    --shadow: none;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 15px/1.5 "Inter", "Segoe UI", system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--brand-clay); }
.wrap { max-width: 1320px; margin: 0 auto; padding: 0 24px; }

/* header */
header.top { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
header.top::after { content: ""; display: block; height: 3px; background: linear-gradient(90deg, var(--brand-orange), var(--brand-clay)); }
.top .wrap { display: flex; align-items: center; gap: 20px; min-height: 72px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.brand { display: flex; align-items: center; gap: 16px; }
.brand img { height: 40px; width: auto; display: block; }
.brand .title { border-left: 1px solid var(--line); padding-left: 16px; }
.brand .title b { display: block; font-size: 17px; letter-spacing: .01em; }
.brand .title span { color: var(--muted); font-size: 13px; }
.controls { margin-left: auto; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.seg button { border: 0; background: transparent; color: var(--text-2); font: inherit; font-size: 13px; padding: 6px 12px; border-radius: 7px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); font-weight: 600; }
.live { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--muted); }
.live i { width: 8px; height: 8px; border-radius: 50%; background: var(--human); box-shadow: 0 0 0 0 var(--human); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(0,143,128,.45); } 70% { box-shadow: 0 0 0 8px rgba(0,143,128,0); } 100% { box-shadow: 0 0 0 0 rgba(0,143,128,0); } }
.btn { border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-size: 13px; padding: 7px 14px; border-radius: 9px; cursor: pointer; }
.btn:hover { border-color: var(--brand-orange); }

/* layout */
main { padding: 24px 0 48px; }
.section-title { display: flex; align-items: baseline; gap: 10px; margin: 28px 0 12px; }
.section-title h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--text-2); margin: 0; font-weight: 700; }
.section-title span { color: var(--muted); font-size: 13px; }
.section-title::before { content: ""; width: 4px; height: 14px; border-radius: 2px; background: var(--brand-orange); align-self: center; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpis { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 1100px) { .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 760px) { .kpis, .g2, .g3 { grid-template-columns: 1fr 1fr; } .g2 > .card, .g3 > .card { grid-column: 1 / -1; } .wrap { padding: 0 16px; } .brand .title span { display: none; } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); min-width: 0; }
.card h3 { margin: 0 0 4px; font-size: 15px; }
.card .sub { color: var(--muted); font-size: 13px; margin: 0 0 14px; }

/* KPI tiles */
.kpi .label { color: var(--text-2); font-size: 13px; display: flex; align-items: center; gap: 8px; }
.kpi .label svg { width: 18px; height: 18px; color: var(--brand-orange); flex: none; }
.kpi .value { font-size: 34px; font-weight: 700; letter-spacing: -.02em; margin: 6px 0 2px; font-variant-numeric: tabular-nums; }
.delta { font-size: 12.5px; color: var(--muted); }
.delta b { font-weight: 600; }
.delta.up b { color: var(--up); } .delta.down b { color: var(--down); }

/* share price */
.market { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 24px; }
@media (max-width: 900px) { .market { grid-template-columns: 1fr; } }
.price-hero .code { display: inline-flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; }
.price-hero .code b { background: var(--brand-ink); color: #fff; border-radius: 6px; padding: 2px 8px; letter-spacing: .04em; }
.price-last { font-size: 46px; font-weight: 700; letter-spacing: -.02em; margin: 8px 0 0; font-variant-numeric: tabular-nums; min-height: 56px; }
.price-move { font-size: 16px; font-weight: 600; display: flex; gap: 8px; align-items: center; min-height: 24px; }
.price-move.up { color: var(--up); } .price-move.down { color: var(--down); }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; margin-top: 18px; }
.facts div { border-top: 1px solid var(--line); padding-top: 8px; }
.facts dt { font-size: 12px; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-weight: 600; font-variant-numeric: tabular-nums; min-height: 20px; }
.chart-box { min-height: 320px; }
.note { font-size: 12.5px; color: var(--muted); margin-top: 12px; }
.placeholder { border: 1px dashed var(--line); border-radius: 10px; padding: 18px; color: var(--muted); font-size: 14px; background: var(--surface-2); }

/* columns chart */
.cols { position: relative; height: 220px; display: flex; align-items: flex-end; gap: 2px; padding-left: 36px; border-bottom: 1px solid var(--grid); }
.cols .gridline { position: absolute; left: 36px; right: 0; border-top: 1px solid var(--grid); }
.cols .gridline span { position: absolute; left: -36px; top: -9px; width: 30px; text-align: right; font-size: 11px; color: var(--muted); }
.cols .col { flex: 1; display: flex; align-items: flex-end; justify-content: center; height: 100%; position: relative; z-index: 1; cursor: default; }
.cols .col i { display: block; width: 100%; max-width: 24px; background: var(--human); border-radius: 4px 4px 0 0; min-height: 2px; }
.cols .col:hover i { filter: brightness(1.12); }
.axis-x { display: flex; justify-content: space-between; padding-left: 36px; font-size: 11px; color: var(--muted); margin-top: 6px; }

/* quality bar */
.qbar { display: flex; gap: 2px; height: 28px; margin: 6px 0 12px; }
.qbar div { height: 100%; min-width: 3px; }
.qbar div:first-child { border-radius: 6px 0 0 6px; } .qbar div:last-child { border-radius: 0 6px 6px 0; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: 13.5px; color: var(--text-2); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 7px; vertical-align: -1px; }
.legend b { color: var(--text); }

/* bar lists */
.bars { list-style: none; margin: 0; padding: 0; }
.bars li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 7px 0; border-bottom: 1px solid var(--grid); font-size: 14px; }
.bars li:last-child { border-bottom: 0; }
.bars .name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bars .name small { color: var(--muted); margin-left: 6px; }
.bars .num { font-variant-numeric: tabular-nums; font-weight: 600; }
.bars .track { grid-column: 1 / -1; height: 6px; background: var(--surface-2); border-radius: 3px; }
.bars .track i { display: block; height: 100%; background: var(--human); border-radius: 0 4px 4px 0; }
.empty { color: var(--muted); font-size: 14px; padding: 8px 0; }

/* investor activity */
.feed { list-style: none; margin: 0; padding: 0; }
.feed li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--grid); }
.feed li:last-child { border-bottom: 0; }
.feed time { font-size: 12.5px; color: var(--muted); line-height: 1.35; }
.feed .who { font-weight: 600; }
.feed .who small { font-weight: 400; color: var(--muted); }
.feed .what { font-size: 13.5px; color: var(--text-2); margin-top: 2px; }
.chip { display: inline-block; font-size: 11.5px; padding: 1px 8px; border-radius: 99px; margin: 4px 4px 0 0; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--line); }
.chip.dl { background: rgba(216, 144, 84, .14); border-color: rgba(216, 144, 84, .35); color: var(--text); }
.chip.enq { background: var(--human-wash); border-color: rgba(0,143,128,.35); color: var(--text); font-weight: 600; }

/* campaigns */
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
.t th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 8px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.t td { padding: 10px 8px; border-bottom: 1px solid var(--grid); vertical-align: middle; }
.t td.n, .t th.n { text-align: right; font-variant-numeric: tabular-nums; }
.rate { display: inline-flex; align-items: center; gap: 8px; }
.rate .mini { width: 70px; height: 6px; background: var(--surface-2); border-radius: 3px; }
.rate .mini i { display: block; height: 100%; background: var(--brand-orange); border-radius: 0 4px 4px 0; }

/* announcements widget container */
.ann { min-height: 160px; }

details.table-view { margin-top: 12px; font-size: 13px; }
details.table-view summary { cursor: pointer; color: var(--text-2); }
details.table-view table { margin-top: 8px; }

footer { color: var(--muted); font-size: 12.5px; padding: 20px 0 40px; border-top: 1px solid var(--line); margin-top: 32px; }
footer p { margin: 6px 0; max-width: 980px; }

#tip { position: fixed; pointer-events: none; z-index: 50; background: var(--brand-ink); color: #fff; font-size: 12.5px; padding: 7px 10px; border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.18); opacity: 0; transition: opacity .1s; white-space: nowrap; }
#tip.on { opacity: 1; }
.banner { background: rgba(198, 84, 48, .1); border: 1px solid rgba(198, 84, 48, .35); color: var(--text); padding: 12px 16px; border-radius: 10px; margin-top: 16px; }

/* present mode (for board meetings / TV) */
body.present { font-size: 17px; }
body.present .controls .seg, body.present #refreshBtn { display: none; }
body.present .kpi .value { font-size: 44px; }
body.present .wrap { max-width: 1680px; }

/* before the Investi key is set: hide the empty price fields */
body.no-investi .price-last, body.no-investi .price-move, body.no-investi .facts, body.no-investi .price-hero .note { display: none; }
body.no-investi .market { grid-template-columns: 260px minmax(0, 1fr); align-items: center; }
body.no-investi .chart-box { min-height: 0; }
@media (max-width: 900px) { body.no-investi .market { grid-template-columns: 1fr; } }
@media (prefers-color-scheme: dark) { .price-hero .code b { background: #2f4a51; } }
@media (max-width: 760px) { header.top { position: static; } }

/* ---------- tabs (single app) ---------- */
nav.tabs { display: flex; gap: 4px; padding-top: 0; padding-bottom: 0; overflow-x: auto; }
nav.tabs a { padding: 10px 14px; font-size: 14px; color: var(--text-2); text-decoration: none; border-bottom: 3px solid transparent; white-space: nowrap; font-weight: 600; }
nav.tabs a:hover { color: var(--text); }
nav.tabs a[aria-current="page"] { color: var(--text); border-bottom-color: var(--brand-clay); }
header.top::after { margin-top: -3px; }
body:not([data-tab="summary"]):not([data-tab="market"]):not([data-tab="website"]) .controls .seg,
body:not([data-tab="summary"]):not([data-tab="market"]):not([data-tab="website"]) #presentBtn { display: none; }

/* ---------- shared bits ---------- */
.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 12.5px; }
.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.center { text-align: center; }
.scroll-x { overflow-x: auto; }
.sub2 { margin-top: 3px; color: var(--muted); font-size: 12.5px; }
.btn.primary { background: var(--brand-ink); color: #fff; border-color: var(--brand-ink); }
.btn.primary:hover { border-color: var(--brand-orange); }
.btn.small { padding: 3px 10px; font-size: 12px; }
@media (prefers-color-scheme: dark) { .btn.primary { background: var(--brand-clay); border-color: var(--brand-clay); } }
.tag { display: inline-block; font-size: 11.5px; line-height: 1.5; padding: 0 8px; border-radius: 99px; margin: 2px 4px 2px 0; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--line); white-space: nowrap; vertical-align: 1px; }
.tag.hm, .tag.hi { background: var(--human-wash); border-color: rgba(0,143,128,.35); color: var(--text); }
.tag.hi { font-weight: 700; }
.tag.md { background: rgba(216,144,84,.14); border-color: rgba(216,144,84,.4); color: var(--text); }
.tag.dl { background: rgba(216,144,84,.10); border-color: rgba(216,144,84,.3); color: var(--text); }
.tag.bot { background: rgba(198,84,48,.12); border-color: rgba(198,84,48,.4); color: var(--text); }
.tag.un { color: var(--muted); }
.tag.wt { background: rgba(30,54,60,.08); border-color: rgba(30,54,60,.3); color: var(--text); font-weight: 600; }
.tag.px, .tag.co { color: var(--text-2); }
.tags { margin-top: 3px; }
tr.watch td { background: rgba(216,144,84,.07); }
tr.faded td { opacity: .55; }
.t td { font-size: 13.5px; }

/* ---------- visitors ---------- */
.filters { padding: 14px 16px; }
.frow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.frow + .frow { margin-top: 10px; }
.frow select, .frow input[type=search], .frow input[type=date], .form input, .form select, .inline input, #s-users select {
  font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--text); }
.frow input[type=search] { min-width: 210px; flex: 1 1 210px; }
.frow.checks label { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--text-2); margin-right: 8px; }
.vkpis { grid-template-columns: repeat(5, minmax(0, 1fr)); margin-top: 12px; }
@media (max-width: 1100px) { .vkpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .vkpis { grid-template-columns: 1fr 1fr; } }
.kpi.small { padding: 12px 16px; }
.kpi.small .label { font-size: 12.5px; }
.kpi.small .value { font-size: 24px; margin: 2px 0 0; }
.cols.compact { height: 160px; padding-left: 0; }
.cols.compact .col i { max-width: 18px; }
.axis-x { padding-left: 0; }
details.explain { margin-top: 10px; font-size: 13px; }
details.explain summary { cursor: pointer; color: var(--brand-clay); }
details.explain p { margin: 6px 0 0; color: var(--text-2); }

/* ---------- email & settings ---------- */
.form { display: grid; gap: 12px; }
.form label { display: grid; gap: 4px; font-size: 13px; color: var(--text-2); }
.form-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 760px) { .form-row { grid-template-columns: 1fr 1fr; } }
.form .btn { justify-self: start; padding: 9px 18px; }
.inline { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.inline input { flex: 1 1 200px; }
ul.plain { list-style: none; margin: 8px 0 0; padding: 0; }
ul.plain li { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--grid); font-size: 14px; }
ul.plain li span:first-child { flex: 1; }
.mini-kpis { gap: 14px 18px; }
.mini-kpis .label { font-size: 12.5px; color: var(--muted); }
.mini-kpis .value { font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
.form input { width: 100%; min-width: 0; }
section.tab { padding-top: 6px; }
#tab-visitors > .filters { margin-top: 10px; }
header.top nav.tabs { flex-wrap: nowrap; min-height: 0; padding-top: 0; padding-bottom: 0; gap: 2px; }
@media (max-width: 760px) { nav.tabs a { padding: 10px 10px; font-size: 13.5px; } }

/* email markers on the daily chart */
.cols .col.marked { position: relative; }
.cols .col .mk { position: absolute; bottom: -9px; left: 50%; transform: translateX(-50%); width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; border-bottom: 7px solid var(--brand-orange); }

/* People tab */
.badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 1px 9px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text-2); }
.badge.ok { background: var(--human-wash); border-color: rgba(0,143,128,.4); color: var(--text); }
.badge.warn { background: rgba(216,144,84,.16); border-color: rgba(216,144,84,.45); color: var(--text); }
.small { font-size: 12px; }
.p-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
table.people td { vertical-align: top; }
#p-search { width: 220px; max-width: 100%; }
#p-go-out { width: 100%; }
@media (max-width: 760px) { .p-kpis { grid-template-columns: 1fr 1fr; } }

/* IP address column */
.t a.ip { font-size: 12.5px; color: var(--text-2); text-decoration: none; word-break: break-all; display: inline-block; max-width: 180px; }
.t a.ip:hover { color: var(--text); text-decoration: underline; }
.checks li { padding: 6px 0; }
.checks label { display: flex; gap: 8px; align-items: center; cursor: pointer; }

/* Market and website chart */
svg.market { display: block; overflow: visible; font-family: inherit; }
.mk-title { font-size: 12.5px; font-weight: 600; fill: var(--text-2); }
.mk-lab { font-size: 11px; fill: var(--muted); text-anchor: end; }
.mk-val { font-size: 12px; font-weight: 700; fill: var(--text); text-anchor: end; }
.mk-lab.start { text-anchor: start; }
.mk-lab.mid { text-anchor: middle; }
.mk-grid { stroke: var(--grid); stroke-width: 1; }
.mk-price { fill: none; stroke: var(--brand-ink); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.mk-dot { fill: var(--brand-ink); stroke: var(--surface); stroke-width: 2; }
.mk-vol { fill: var(--unverified); }
.mk-hum { fill: var(--human); }
.mk-untracked { fill: var(--surface-2); }
.mk-ann { stroke: var(--brand-orange); stroke-width: 1; stroke-dasharray: 3 3; opacity: .8; }
.mk-tri { fill: var(--surface); stroke: var(--brand-orange); stroke-width: 1.5; }
.mk-tri.sens { fill: var(--brand-orange); }
.mk-hit { fill: transparent; cursor: default; }
.mk-hit:hover { fill: var(--text); fill-opacity: .06; }
.legend i.tri { display: inline-block; width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-top: 9px solid var(--brand-orange); background: none; border-radius: 0; margin-right: 6px; vertical-align: 0; }
.legend i.tri:not(.sens) { border-top-color: var(--brand-orange); opacity: .45; }
@media (prefers-color-scheme: dark) { .mk-price { stroke: var(--text); } .mk-dot { fill: var(--text); stroke: var(--surface); } }

/* Announcement reaction: standout rows */
table.reaction tr.standout td { background: rgba(216,144,84,.09); }
table.reaction tr.standout td:first-child { box-shadow: inset 3px 0 0 var(--brand-orange); }
.standout-why { margin-top: 4px; font-size: 12px; font-weight: 600; color: var(--brand-clay, #c65430); }
@media (prefers-color-scheme: dark) { table.reaction tr.standout td { background: rgba(216,144,84,.12); } .standout-why { color: var(--brand-orange); } }

/* Social media tab */
.so-seg { margin-left: auto; }
.section-title .so-seg button { font-size: 12.5px; padding: 4px 10px; }
.so-company { margin-top: 26px; }
.so-brand { display: flex; align-items: center; gap: 16px; padding: 14px 0 12px; border-bottom: 2px solid var(--line); margin-bottom: 14px; }
.so-brand img { height: 46px; width: auto; display: block; }
.so-brand h2 { margin: 0; font-size: 20px; letter-spacing: -.01em; }
.so-cards { display: grid; gap: 16px; grid-template-columns: 1fr; }
.so-card .so-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; font-size: 16px; }
.so-icon { width: 22px; height: 22px; color: var(--brand-ink); display: inline-flex; }
.so-icon svg { width: 22px; height: 22px; }
@media (prefers-color-scheme: dark) { .so-icon { color: var(--text); } }
.so-period { color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.so-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px 16px; }
.so-kpi { display: flex; flex-direction: column; gap: 2px; }
.so-kpi > b { font-size: 24px; font-weight: 700; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.so-chart { margin-top: 16px; }
.so-bars { display: flex; align-items: flex-end; gap: 3px; height: 110px; border-bottom: 1px solid var(--grid); }
.so-bar { flex: 1; height: 100%; display: flex; align-items: flex-end; cursor: default; }
.so-bar i { display: block; width: 100%; background: var(--brand-orange); border-radius: 4px 4px 0 0; min-height: 2px; }
.so-bar:hover i { filter: brightness(1.1); }
.so-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 4px; }
.so-posts { margin-top: 16px; overflow-x: auto; }
.so-posts table { margin-top: 6px; }
.so-title { max-width: 420px; }
.so-title a { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.so-source { margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }
/* Settings: social media uploads */
.sa-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 10px; }
@media (max-width: 760px) { .sa-grid { grid-template-columns: 1fr; } }
.sa-box { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: var(--surface-2); }
.sa-ig { margin-top: 12px; }
.sa-title { margin-bottom: 8px; }
.sa-drop { display: block; border: 2px dashed var(--line); border-radius: 10px; padding: 14px; text-align: center; cursor: pointer; background: var(--surface); font-size: 14px; }
.sa-drop:hover { border-color: var(--brand-orange); }
.sa-drop input { display: block; margin: 0 auto 6px; max-width: 100%; }
.sa-status { margin: 8px 0 4px; min-height: 18px; }
.sa-box details { margin: 4px 0; }
.sa-card { grid-column: 1 / -1; }


/* Tables: sortable headings, column filters, pages (tables.js) */
th.tf-sort { cursor: pointer; user-select: none; white-space: nowrap; }
th.tf-sort:hover { color: var(--text); }
th.tf-sort::after { content: "\2195"; opacity: .35; margin-left: 4px; font-size: .85em; }
th.tf-asc::after { content: "\25B2"; opacity: .9; }
th.tf-desc::after { content: "\25BC"; opacity: .9; }
th.tf-sort:focus-visible { outline: 2px solid var(--brand-orange); outline-offset: -2px; }
tr.tf-row th { padding-top: 0; padding-bottom: 8px; }
.tf-in { width: 100%; min-width: 70px; font: inherit; font-size: 12.5px; font-weight: 400; padding: 4px 7px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--text); }
.tf-in:focus { outline: none; border-color: var(--brand-orange); }
.tf-pager { position: sticky; left: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; font-size: 13px; color: var(--text-2); }
.tf-nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tf-nav select { font: inherit; padding: 2px 4px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.tf-pager .btn[disabled] { opacity: .4; cursor: default; }
@media print { tr.tf-row, .tf-pager { display: none; } }

/* Board summary */
.bs-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); }
@media (max-width: 960px) { .bs-top { grid-template-columns: 1fr; } }
.bs-insights { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 10px; }
.bs-insights li { display: grid; grid-template-columns: 18px 1fr; gap: 8px; line-height: 1.45; font-size: 14.5px; }
.bs-insights li i { font-style: normal; color: var(--muted); text-align: center; }
.bs-insights li.bs-up i { color: var(--up); } .bs-insights li.bs-down i { color: var(--down); }
.bs-insights li.bs-star i, .bs-insights li.bs-org i { color: var(--brand-orange); } .bs-insights li.bs-person i { color: var(--human); }
.bs-cols .col { flex-direction: column-reverse; justify-content: flex-start; align-items: center; }
.bs-cols .col i { border-radius: 0; min-height: 0; }
.bs-cols .col i:last-of-type { border-radius: 4px 4px 0 0; }
.bs-cols .col i.bs-dl, .bs-dl-key { background: var(--brand-orange) !important; opacity: .85; }
.bs-dl-key { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 7px; vertical-align: -1px; }
#bs-trend .legend { margin-top: 10px; }
#bs-foot { line-height: 2; }
.bs-src { display: inline-block; max-width: 100%; padding: 1px 9px; border-radius: 12px; border: 1px solid var(--line); margin: 0 4px 0 0; font-size: 12.5px; line-height: 1.6; }
.bs-src.ok { background: var(--human-wash); border-color: rgba(0,143,128,.35); }
.bs-src.warn { background: rgba(216,144,84,.14); border-color: rgba(216,144,84,.45); }
/* wide tables scroll inside their card instead of widening the page */
#bs-people, #bs-anns, .table-view { overflow-x: auto; }
.grid > .card { min-width: 0; }

/* Investor profile */
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--text); cursor: pointer; text-align: left; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.linkish:hover { text-decoration-color: var(--brand-orange); }
.pp-open { margin-top: 6px; }
dialog.pp { width: min(1000px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 0; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); color: var(--text); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
dialog.pp::backdrop { background: rgba(10, 20, 22, .45); }
.pp-in { position: relative; padding: 24px 26px 28px; }
.pp-x { position: sticky; top: 0; float: right; margin: -8px -10px 0 0; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-size: 22px; line-height: 1; cursor: pointer; z-index: 2; }
.pp-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.pp-head h2 { margin: 0 0 4px; font-size: 26px; letter-spacing: -.01em; }
.pp-note { margin: 8px 0 4px; padding: 8px 12px; border-left: 3px solid var(--brand-orange); background: var(--surface); border-radius: 6px; }
.pp-saved { color: var(--up); margin: 2px 0 6px; }
.pp-form { margin: 0 0 16px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.pp-kpis { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.pp-kpis .kpi { padding: 12px 14px; }
.pp-kpis .kpi .value { font-size: 22px; }
.pp-cols { margin-top: 16px; }
.pp-list { list-style: none; margin: 6px 0 0; padding: 0; }
.pp-list li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.pp-tl { list-style: none; margin: 10px 0 0; padding: 0 0 0 14px; border-left: 2px solid var(--line); }
.pp-ev { display: grid; grid-template-columns: 26px 1fr; gap: 8px; margin: 0 0 16px -26px; }
.pp-ev > i { font-style: normal; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); display: grid; place-items: center; font-size: 11px; color: var(--human); }
.pp-email > i { color: var(--brand-orange); }
.pp-when { font-size: 12.5px; color: var(--muted); margin-bottom: 2px; }
.pp-pages { margin: 6px 0 0; padding-left: 18px; }
.pp-pages li { display: flex; justify-content: space-between; gap: 12px; padding: 2px 0; }
.pp-dl { margin-top: 4px; }
@media (max-width: 640px) { .pp-in { padding: 18px 16px; } .pp-pages li { flex-direction: column; gap: 0; } }
.pp-form[hidden] { display: none; }
.pp-kpis .kpi .value.pp-date { font-size: 17px; line-height: 1.3; }

/* Roles: admin sees everything; user sees everything except Settings (only "My account") and People editing */
html:not(.is-admin) .admin-only { display: none !important; }

/* Executive summary polish */
.section-title .bs-pdf { margin-left: auto; }
.bs-printed { display: none; }
.bs-kpi .label { justify-content: space-between; }
.bs-tip-i { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--line); font-size: 10.5px; font-weight: 700; font-style: italic; font-family: Georgia, serif; color: var(--muted); cursor: help; flex: none; }
.bs-tip-i:hover, .bs-tip-i:focus-visible { color: var(--text); border-color: var(--muted); outline: none; }
.bs-spark { display: block; width: 100%; height: 26px; margin: 2px 0 6px; overflow: visible; }
.bs-spark-empty { height: 26px; margin: 2px 0 6px; }
.bs-spark-line { fill: none; stroke: var(--human); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.bs-spark-area { fill: var(--human-wash); stroke: none; }
.bs-spark-dot { fill: var(--human); }
.clip1 { max-width: 460px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-ann .tag { margin-top: 4px; display: inline-block; }
.bs-named td { vertical-align: middle; }
.bs-did-cell { max-width: 360px; }
.bs-did { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13.5px; color: var(--text-2); }
.bs-did.dl { color: var(--text); }
@media (max-width: 760px) { .clip1 { max-width: 220px; } .bs-did-cell { max-width: 200px; } }

/* "Download PDF": a clean one-page print of the Executive summary */
@media print {
  body.print-summary { background: #fff !important; color: #111 !important; font-size: 11px; }
  body.print-summary header, body.print-summary #banner, body.print-summary .tf-row, body.print-summary .tf-pager,
  body.print-summary .bs-pdf, body.print-summary footer, body.print-summary #tip, body.print-summary section.tab:not(#tab-summary) { display: none !important; }
  body.print-summary #tab-summary { display: block !important; }
  body.print-summary .wrap { max-width: none; padding: 0; }
  body.print-summary .bs-printed { display: block; margin: 0 0 8px; color: #555; font-size: 10px; }
  body.print-summary .card { box-shadow: none !important; border: 1px solid #ddd !important; background: #fff !important; break-inside: avoid; padding: 10px 12px; }
  body.print-summary .grid { gap: 8px; }
  body.print-summary .kpi .value { font-size: 22px; }
  body.print-summary .section-title { margin: 12px 0 6px; }
  body.print-summary .cols { height: 140px; }
  body.print-summary a { color: #111; text-decoration: none; }
  body.print-summary .clip1 { max-width: 330px; }
  body.print-summary .kpis { grid-template-columns: repeat(6, minmax(0, 1fr)) !important; }
  body.print-summary .kpi { padding: 8px 9px; }
  body.print-summary .kpi .value { font-size: 18px; margin: 2px 0; }
  body.print-summary .kpi .label { font-size: 9.5px; }
  body.print-summary .bs-tip-i, body.print-summary th.tf-sort::after { display: none !important; }
  body.print-summary .bs-top, body.print-summary .g2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important; }
  body.print-summary .g2 > .card { grid-column: auto !important; }
  body.print-summary .bs-insights li { font-size: 10.5px; gap: 5px; }
  body.print-summary .cols { height: 120px; }
  body.print-summary #bs-people, body.print-summary #bs-anns, body.print-summary .scroll-x { overflow: visible !important; }
  body.print-summary table.t { width: 100%; font-size: 9.5px; }
  body.print-summary table.t th, body.print-summary table.t td { padding: 4px 5px; }
  body.print-summary .clip1, body.print-summary .bs-did { max-width: 240px; }
  body.print-summary .bars li { padding: 3px 0; font-size: 10px; }
  body.print-summary .sub { font-size: 9.5px; margin-bottom: 4px; }
  body.print-summary h3 { font-size: 12px; }
  body.print-summary #bs-foot { font-size: 9px; line-height: 1.7; }
  body.print-summary main > p.note, body.print-summary .page-note { display: none; }
  @page { size: A4 portrait; margin: 10mm; }
}

.pp-why { margin: 6px 0 2px; padding: 6px 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; color: var(--text-2); }
.p-reason { max-width: 520px; }

.pp-review { margin: 8px 0 4px; padding: 8px 12px; border-left: 3px solid var(--brand-orange); background: var(--surface-2); border-radius: 6px; font-size: 14px; }
