/* Wealth Signal site chrome. Extends the generated report's own tokens; standalone pages redefine them below. */

:root {
  --paper: #f1f3f0; --surface: #f8f9f7; --surface-2: #e6eae5;
  --ink: #121816; --ink-2: #3d4744; --ink-3: #6d7a75;
  --rule: #cdd5cf; --rule-soft: #dfe5de;
  --accent: #0c5f4f; --accent-2: #0a4a3e;
  --warn: #8a3b1f; --warn-bg: #f0e4dd; --ok: #2f6b3a;
  --band: #12181a; --band-ink: #dde4df; --band-rule: #2b3735;
  --ff-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --ff-body: "Newsreader", Georgia, "Times New Roman", serif;
  --ff-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0d1211; --surface: #141a18; --surface-2: #1b2321;
    --ink: #e3e9e5; --ink-2: #b3bfba; --ink-3: #7e8b86;
    --rule: #2a3532; --rule-soft: #202927;
    --accent: #4fb79c; --accent-2: #6ecab2;
    --warn: #d9835f; --warn-bg: #2a1d16; --ok: #6fb87c;
    --band: #060a09; --band-ink: #c9d4cf; --band-rule: #1e2725;
  }
}
:root[data-theme="dark"] {
  --paper: #0d1211; --surface: #141a18; --surface-2: #1b2321;
  --ink: #e3e9e5; --ink-2: #b3bfba; --ink-3: #7e8b86;
  --rule: #2a3532; --rule-soft: #202927;
  --accent: #4fb79c; --accent-2: #6ecab2;
  --warn: #d9835f; --warn-bg: #2a1d16; --ok: #6fb87c;
  --band: #060a09; --band-ink: #c9d4cf; --band-rule: #1e2725;
}

/* ---------- standalone pages (login, archive, saved) get the report's base ---------- */
body.ws-standalone { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--ff-body); font-size: 17px; line-height: 1.62; -webkit-font-smoothing: antialiased; }
.ws-standalone * { box-sizing: border-box; }
.ws-standalone .wrap { max-width: 820px; margin: 0 auto; padding: 0 22px 72px; }
.ws-standalone a { color: var(--accent); text-decoration-color: var(--rule); text-underline-offset: 2px; }
.ws-standalone a:hover { text-decoration-color: var(--accent); }
.ws-standalone p { margin: 0 0 14px; }
.ws-standalone footer { margin-top: 54px; padding-top: 20px; border-top: 2px solid var(--ink); font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; }
.ws-head { border-bottom: 2px solid var(--ink); padding: 40px 0 14px; margin-bottom: 26px; }
.ws-head h1 { font-family: var(--ff-display); font-weight: 700; font-size: clamp(34px, 7vw, 48px); line-height: 0.96; letter-spacing: -0.035em; margin: 0 0 14px; }
.ws-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; font-family: var(--ff-mono); font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.ws-kicker { font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); margin: 0 0 14px; }
.ws-lede { font-size: 18.5px; color: var(--ink-2); }
.ws-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ws-inline { display: contents; }
*:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- top bar ---------- */
.ws-topbar { background: var(--surface); border-bottom: 1px solid var(--rule); }
.ws-topbar-in { max-width: 820px; margin: 0 auto; padding: 0 22px; height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.ws-brand { font-family: var(--ff-mono); font-size: 11px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink); text-decoration: none; white-space: nowrap; }
.ws-nav { display: flex; align-items: center; gap: 22px; font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; }
.ws-nav a { color: var(--ink-3); text-decoration: none; border-bottom: 1px solid transparent; padding-bottom: 2px; }
.ws-nav a:hover, .ws-nav a.on { color: var(--accent); border-bottom-color: var(--accent); }
.ws-who { display: flex; align-items: center; gap: 10px; font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-2); }
.ws-avatar { width: 28px; height: 28px; background: var(--accent); color: var(--paper); font-family: var(--ff-display); font-weight: 600; font-size: 12px; display: flex; align-items: center; justify-content: center; letter-spacing: 0; flex-shrink: 0; text-transform: uppercase; }
.ws-linkbtn { background: none; border: 0; padding: 0 0 2px; font: inherit; letter-spacing: inherit; text-transform: inherit; color: var(--ink-3); cursor: pointer; border-bottom: 1px solid transparent; }
.ws-linkbtn:hover { color: var(--accent); border-bottom-color: var(--accent); }
.ws-signin { display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border: 1px solid var(--ink); color: var(--ink); font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none; white-space: nowrap; }
.ws-signin:hover { background: var(--ink); color: var(--paper); }

/* ---------- edition number bar ---------- */
.ws-editions { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 12px; padding: 12px 0; border-bottom: 1px solid var(--rule); font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.08em; }
.ws-editions.bottom { border-bottom: 0; border-top: 1px solid var(--rule); margin-top: 20px; }
.ws-editions .lbl { color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.12em; font-size: 10.5px; }
.ws-pages { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.ws-pg { display: flex; align-items: center; justify-content: center; min-width: 28px; height: 28px; padding: 0 8px; border: 1px solid var(--rule); color: var(--ink-2); text-decoration: none; font-variant-numeric: tabular-nums; }
.ws-pg:hover { border-color: var(--accent); color: var(--accent); }
.ws-pg.cur { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.ws-pg.more { border-color: transparent; color: var(--ink-3); min-width: 20px; padding: 0 2px; }
.ws-pg.next { letter-spacing: -0.1em; padding: 0 10px 0 8px; }
.ws-report .mast-strip { padding-top: 14px; }

/* ---------- items in the report ---------- */
.ws-report .heads li, .ws-report .entry, .ws-report .act { padding-bottom: 10px; }
.ws-report .topic { padding: 18px 0 10px; border-top: 1px solid var(--rule-soft); }
.ws-report .topic + .topic { margin-top: 0; }
.ws-report .topic:last-of-type { border-bottom: 1px solid var(--rule-soft); }
.ws-report .topic h3 { margin-top: 0; }
.ws-report .heads li { row-gap: 2px; }
.ws-report .heads li > .ws-ibar { grid-column: 2; margin-top: 4px; }
.ws-item { cursor: pointer; transition: background 0.12s; }
.ws-item:hover { background: var(--surface); box-shadow: -14px 0 0 var(--surface), 14px 0 0 var(--surface); }
.ws-report .band .ws-item:hover { background: #1a2321; box-shadow: -14px 0 0 #1a2321, 14px 0 0 #1a2321; }
.ws-cell { min-width: 0; }

/* ---------- action bar ---------- */
.ws-ibar { display: flex; align-items: center; gap: 4px; margin: 6px 0 0 -8px; flex-wrap: wrap; }
.ws-ib { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 8px; color: var(--ink-3); text-decoration: none; font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.04em; font-variant-numeric: tabular-nums; background: none; border: 0; cursor: pointer; line-height: 1; white-space: nowrap; }
.ws-ib:hover { color: var(--accent); background: var(--surface-2); }
.ws-ib svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ws-ib.liked { color: var(--accent); }
.ws-ib.liked svg { fill: currentColor; }
.ws-ib.disliked { color: var(--warn); }
.ws-ib.disliked svg { fill: currentColor; }
.ws-ib.saved { color: var(--accent); }
.ws-ib.saved svg { fill: currentColor; }
.ws-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.ws-avatar.anon, .ws-resp .av.anon { background: var(--surface-2); color: var(--ink-2); border: 1px dashed var(--rule); }
.ws-resp .av.anon.me { border-color: var(--accent); color: var(--accent); }
.ws-compose .ws-err { margin-bottom: 10px; }
.ws-ib.static { cursor: default; }
.ws-ib.static:hover { color: var(--ink-3); background: none; }
.ws-report .band .ws-ib { color: #7d8c87; }
.ws-report .band .ws-ib:hover { color: #6ecab2; background: var(--band-rule); }
.ws-report .band .ws-ib.liked { color: #6ecab2; }
.ws-report .band .ws-ib.disliked { color: var(--warn); }
.ws-report .band .ws-ib.saved { color: #6ecab2; }
.ws-report .band .ws-ib.static:hover { color: #7d8c87; background: none; }

/* ---------- item page ---------- */
.ws-crumb { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 22px 0 14px; border-bottom: 1px solid var(--rule); font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
.ws-crumb a { color: var(--ink-3); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.ws-crumb a:hover { color: var(--accent); }
.ws-crumb svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ws-crumb .sep { color: var(--rule); }
.ws-focus { padding: 34px 0 12px; border-bottom: 1px solid var(--ink); }
.ws-focus .heads li, .ws-focus .heads li:first-child, .ws-focus .entry, .ws-focus .entry:last-of-type, .ws-focus .act, .ws-focus .act:last-of-type, .ws-focus .topic, .ws-focus .trend-row, .ws-focus .trend-row:last-child { border: 0; padding: 0; }
.ws-focus .heads .body, .ws-focus .entry p, .ws-focus .act p, .ws-focus .topic p, .ws-focus .trend-row .what { font-size: 18.5px; line-height: 1.6; }
.ws-focus .heads .body b, .ws-focus .act h3, .ws-focus .topic h3 { font-size: 22px; line-height: 1.25; display: block; margin: 0 0 12px; }
.ws-focus .ws-ibar { margin-top: 14px; }
.ws-focus .ws-ib { height: 36px; padding: 0 10px; letter-spacing: 0.06em; text-transform: uppercase; }

.ws-compose, .ws-gate { display: grid; grid-template-columns: 28px 1fr; gap: 16px; padding: 26px 0 22px; border-bottom: 1px solid var(--rule-soft); }
.ws-compose textarea { display: block; width: 100%; box-sizing: border-box; border: 1px solid var(--rule); background: var(--surface); padding: 14px 16px; min-height: 96px; font: 16.5px/1.55 var(--ff-body); color: var(--ink); resize: vertical; }
.ws-compose textarea::placeholder { color: var(--ink-3); font-style: italic; }
.ws-compose textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.ws-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; flex-wrap: wrap; }
.ws-hint { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.ws-hint a { color: var(--accent); text-decoration: none; }
.ws-replying { margin-bottom: 8px; }
.ws-btn { display: inline-flex; align-items: center; justify-content: center; height: 36px; padding: 0 16px; background: var(--accent); color: var(--paper); font-family: var(--ff-display); font-weight: 600; font-size: 13px; letter-spacing: 0.01em; text-decoration: none; border: 1px solid var(--accent); cursor: pointer; white-space: nowrap; }
.ws-btn:hover { background: var(--accent-2); border-color: var(--accent-2); color: var(--paper); }
.ws-btn.wide { width: 100%; height: 44px; font-size: 14px; }
.ws-btn.alt { background: transparent; color: var(--ink); border-color: var(--ink); gap: 10px; }
.ws-btn.alt:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.ws-btn.alt svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ws-or { display: flex; align-items: center; gap: 12px; margin: 18px 0 10px; font-family: var(--ff-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); }
.ws-or .rule { flex: 1; height: 1px; background: var(--rule-soft); }
.ws-static { height: 44px; border: 1px solid var(--rule-soft); background: var(--surface-2); padding: 0 12px; display: flex; align-items: center; font: 13px var(--ff-mono); color: var(--ink-2); }
.ws-lock { width: 28px; height: 28px; border: 1px solid var(--rule); color: var(--ink-3); display: flex; align-items: center; justify-content: center; }
.ws-lock svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ws-gate .box { border: 1px dashed var(--rule); padding: 16px 18px; display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.ws-gate .t { font-family: var(--ff-display); font-weight: 600; font-size: 15px; margin: 0 0 4px; }
.ws-gate .d { font-size: 15.5px; color: var(--ink-2); margin: 0; line-height: 1.5; }
.ws-gate .cta { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.ws-lnk { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); text-decoration: none; border-bottom: 1px solid var(--rule); padding-bottom: 2px; }
.ws-lnk:hover { color: var(--accent); border-bottom-color: var(--accent); }

.ws-resp-head { display: flex; align-items: baseline; gap: 14px; padding: 30px 0 8px; border-bottom: 1px solid var(--ink); margin-bottom: 4px; }
.ws-resp-head h2 { font-family: var(--ff-display); font-weight: 600; font-size: 19px; letter-spacing: -0.02em; margin: 0; flex: 1; }
.ws-resp-head .tag { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); }
.ws-resp { display: grid; grid-template-columns: 28px 1fr; gap: 16px; padding: 18px 0 8px; border-bottom: 1px solid var(--rule-soft); }
.ws-resp .av { width: 28px; height: 28px; background: var(--surface-2); color: var(--ink-2); font-family: var(--ff-display); font-weight: 600; font-size: 12px; display: flex; align-items: center; justify-content: center; }
.ws-resp .av.me { background: var(--accent); color: var(--paper); }
.ws-resp-meta { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.ws-resp-meta .name { color: var(--ink); font-weight: 600; letter-spacing: 0.06em; }
.ws-resp p { margin: 0 0 6px; font-size: 16px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.ws-resp .ws-ibar { margin-top: 2px; }
.ws-resp .ws-ib { height: 30px; font-size: 10.5px; }
.ws-resp.nest { margin-left: 44px; }
.ws-empty { padding: 22px 0; color: var(--ink-3); font-size: 15.5px; font-style: italic; }
.ws-itempage footer { margin-top: 44px; }

/* ---------- sign in / register ---------- */
.ws-card { max-width: 420px; margin: 72px auto 0; background: var(--surface); border: 1px solid var(--rule); padding: 36px 36px 30px; }
.ws-card .ws-kicker { margin-bottom: 12px; }
.ws-card h1 { font-family: var(--ff-display); font-weight: 700; font-size: 30px; line-height: 1.05; letter-spacing: -0.03em; margin: 0 0 10px; }
.ws-card .sub { font-size: 16px; color: var(--ink-2); margin: 0 0 26px; line-height: 1.5; }
.ws-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.ws-field label { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); }
.ws-input { height: 44px; width: 100%; border: 1px solid var(--rule); background: var(--paper); padding: 0 12px; font: 13px var(--ff-mono); color: var(--ink); }
.ws-input::placeholder { color: var(--ink-3); }
.ws-input:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.ws-err { border: 1px solid var(--warn); background: var(--warn-bg); color: var(--warn); padding: 10px 12px; font-size: 14.5px; line-height: 1.45; margin-bottom: 16px; }
.ws-foot { margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--rule-soft); font-size: 14.5px; color: var(--ink-3); line-height: 1.5; }
.ws-foot a { text-decoration: none; border-bottom: 1px solid var(--rule); }
.ws-note { max-width: 420px; margin: 18px auto 0; font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); text-align: center; }
.ws-note a { color: var(--ink-3); text-decoration: none; border-bottom: 1px solid var(--rule); }
.ws-note a:hover { color: var(--accent); }

/* ---------- archive & saved lists ---------- */
.ws-list { list-style: none; margin: 0; padding: 0; }
.ws-list li { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--rule-soft); align-items: baseline; }
.ws-list li:first-child { border-top: 1px solid var(--rule-soft); }
.ws-list .n { font-family: var(--ff-mono); font-size: 11px; font-weight: 600; color: var(--accent); letter-spacing: 0.08em; font-variant-numeric: tabular-nums; }
.ws-list .t { font-family: var(--ff-display); font-weight: 600; font-size: 16px; color: var(--ink); text-decoration: none; }
.ws-list a.t:hover { color: var(--accent); }
.ws-list .m { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-3); text-align: right; }

/* ---------- phone ---------- */
@media (max-width: 640px) {
  .ws-topbar-in { padding: 0 18px; }
  .ws-nav { gap: 14px; }
  .ws-handle { display: none; }
  .ws-editions { flex-direction: column; align-items: flex-start; }
  .ws-pg { min-width: 36px; height: 36px; }
  .ws-ib { height: 44px; padding: 0 10px; }
  .ws-ib svg { width: 18px; height: 18px; }
  .ws-ibar { justify-content: space-between; margin-right: 0; }
  .ws-focus .ws-ibar { justify-content: flex-start; }
  .ws-resp.nest { margin-left: 22px; }
  .ws-card { margin-top: 32px; padding: 26px 22px 24px; }
  .ws-list li { grid-template-columns: auto 1fr; }
  .ws-list .m { grid-column: 2; text-align: left; }
}

@media (prefers-reduced-motion: reduce) { .ws-item { transition: none; } }

/* Generic cards (kinds card / bandcard: e.g. the anomaly board and the log). The item page shows the element itself,
   flush like the other kinds; band cards keep their dark band. */
.ws-focus-card > :first-child, .ws-focus-bandcard .inner > :first-child { border-top: 0; border-bottom: 0; padding-top: 0; padding-bottom: 0; }
.ws-focus-bandcard .band { padding: 28px 22px 24px; margin: 0; }
.ws-focus-card .ws-ibar, .ws-focus-bandcard .band .ws-ibar { margin-top: 14px; }
