/* Watson app illustrations: HTML recreations of the desktop app, drawn
   from the app's own theme tokens (postatar ui/src/styles.css). Each
   frame is laid out at a fixed native size and scaled to its slot, so
   proportions and type stay true at any width. Sample data only. */

.wf-slot {
  position: relative;
  width: 100%;
  container-type: inline-size;
}
.wf-stage {
  position: absolute;
  inset: 0 auto auto 0;
  transform-origin: 0 0;
}
.wf-layer { position: absolute; inset: 0; }
.wf-layer-dark { will-change: clip-path; }

.wf {
  --bg: #ffffff; --bg-alt: #f4f5f7; --bg-hover: #eceef1; --bg-selected: #dde6f5;
  --border: #e1e4e8; --text: #1c2127; --text-dim: #6a737d; --accent: #2f6fdb;
  --danger: #c0392b; --ok: #1e874b; --warn: #a8690a; --unread: #0b1f3a;
  --acct-1: #2f6fdb; --acct-2: #2e9e5b; --acct-3: #7c5cd6; --acct-4: #d97706;
  --winter: #6aa8e0; --spring: #59b56e; --summer: #e0a83a; --autumn: #d1794a;
  --t-reply: #e2603a; --t-important: #d99a2b; --t-fyi: #6b93c4; --t-low: #9aa1ab;
  --shadow: 0 1px 2px rgb(16 24 40 / 0.06), 0 12px 32px -8px rgb(16 24 40 / 0.18);
  color-scheme: light;
  position: absolute; inset: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font: 13px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif;
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px var(--border);
  text-align: left;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}
.wf[data-theme="dark"] {
  --bg: #1b1e23; --bg-alt: #22262c; --bg-hover: #2a2f36; --bg-selected: #2c3a52;
  --border: #33383f; --text: #e4e7eb; --text-dim: #9aa2ac; --accent: #6ea1f5;
  --danger: #ef7368; --ok: #5fbe85; --warn: #e9a13c; --unread: #ffffff;
  --acct-1: #6ea1f5; --acct-2: #5cc98a; --acct-3: #a78bfa; --acct-4: #f5a742;
  --winter: #4d7ba8; --spring: #3f8a54; --summer: #ddc63c; --autumn: #ec8236;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 16px 40px -8px rgb(0 0 0 / 0.55);
  color-scheme: dark;
}
.wf * { box-sizing: border-box; }
.wf svg.i { width: 16px; height: 16px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.wf .dim { color: var(--text-dim); }
.wf .num { font-variant-numeric: tabular-nums; }
.wf .up { color: var(--ok); }
.wf .down { color: var(--danger); }

/* ---------- window chrome ---------- */
.wf-shell { position: absolute; inset: 0; display: grid; grid-template-rows: 46px minmax(0, 1fr); grid-template-columns: minmax(0, 1fr); }
.wf-title {
  display: grid; grid-template-columns: 300px minmax(0, 1fr) 300px; align-items: center;
  border-bottom: 1px solid var(--border); background: var(--bg); padding: 0 14px;
}
.wf-title-left { display: flex; align-items: center; gap: 12px; color: var(--text-dim); }
.wf-lights { display: flex; gap: 7px; margin-right: 6px; }
.wf-lights span { width: 11px; height: 11px; border-radius: 50%; background: var(--bg-hover); box-shadow: inset 0 0 0 1px var(--border); }
.wf-brand { font-weight: 700; color: var(--text); font-size: 13.5px; }
.wf-badge { font-size: 9.5px; font-weight: 700; letter-spacing: 0.08em; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); padding: 2px 6px; border-radius: 6px; }
.wf-search {
  justify-self: center; width: min(560px, 100%); height: 32px; border-radius: 9px;
  background: color-mix(in srgb, var(--text) 7%, transparent);
  display: flex; align-items: center; gap: 9px; padding: 0 12px; color: var(--text-dim);
}
.wf-search .chip { margin-left: 4px; font-size: 11.5px; padding: 2px 8px; border-radius: 6px; background: var(--bg-selected); color: var(--text); }
.wf-title-right { justify-self: end; display: flex; gap: 14px; color: var(--text-dim); align-items: center; }
.wf-avatar { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 650; color: #fff; flex: none; }

.wf-body { display: grid; min-height: 0; }
.wf-mail { grid-template-columns: 206px 330px minmax(0, 1fr) 280px; }

/* ---------- sidebar ---------- */
.wf-side { background: var(--bg-alt); border-right: 1px solid var(--border); display: flex; flex-direction: column; min-height: 0; }
.wf-side-scroll { padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.wf-side h6 { margin: 12px 8px 4px; font-size: 10.5px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); display: flex; align-items: center; gap: 6px; }
.wf-side h6 i { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.wf-folder { display: flex; align-items: center; gap: 9px; padding: 5px 8px; border-radius: 7px; color: var(--text); }
.wf-folder .n { margin-left: auto; font-size: 11.5px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.wf-folder.on { background: var(--bg-selected); font-weight: 600; }
.wf-folder.on .n { color: var(--accent); font-weight: 650; }
.wf-folder svg.i { color: var(--text-dim); width: 15px; height: 15px; }
.wf-tabs { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border-top: 1px solid var(--border); height: 48px; background: var(--bg-alt); }
.wf-tabs span { display: grid; place-items: center; align-content: center; gap: 2px; font-size: 10.5px; color: var(--text-dim); position: relative; }
.wf-tabs span.on { color: var(--accent); }
.wf-tabs span.on::before { content: ""; position: absolute; top: -1px; left: 0; right: 0; height: 2px; background: var(--accent); }
.wf-tabs svg.i { width: 17px; height: 17px; }

/* ---------- list ---------- */
.wf-list { border-right: 1px solid var(--border); display: flex; flex-direction: column; min-height: 0; }
.wf-list-head { height: 44px; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-bottom: 1px solid var(--border); }
.wf-list-head b { font-size: 14.5px; }
.wf-seg { margin-left: auto; display: flex; background: color-mix(in srgb, var(--text) 7%, transparent); border-radius: 8px; padding: 2px; font-size: 11.5px; }
.wf-seg span { padding: 3px 9px; border-radius: 6px; color: var(--text-dim); }
.wf-seg span.on { background: var(--bg); color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgb(0 0 0 / 0.12); }
.wf-row { display: grid; grid-template-columns: 6px 1fr auto; column-gap: 10px; padding: 9px 14px 9px 10px; border-bottom: 1px solid var(--border); position: relative; }
.wf-row .acct { width: 3px; border-radius: 3px; align-self: stretch; }
.wf-row .from { font-size: 13px; color: var(--text); display: flex; align-items: center; gap: 6px; min-width: 0; white-space: nowrap; }
.wf-row .from b { overflow: hidden; text-overflow: ellipsis; }
.wf-row .time { font-size: 11.5px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.wf-row .subj { grid-column: 2 / 4; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-row .snip { grid-column: 2 / 4; font-size: 12px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-row.unread .from b, .wf-row.unread .subj { font-weight: 650; color: var(--unread); }
.wf-row.sel { background: var(--bg-selected); }
.wf-triage { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.wf-tag { font-size: 10.5px; padding: 1px 6px; border-radius: 5px; font-weight: 600; }

/* ---------- reading pane ---------- */
.wf-read { display: flex; flex-direction: column; min-height: 0; background: var(--bg); }
.wf-read-head { padding: 16px 22px 12px; border-bottom: 1px solid var(--border); display: grid; gap: 10px; }
.wf-read-head h3 { margin: 0; font-size: 17px; font-weight: 650; letter-spacing: -0.01em; }
.wf-meta { display: flex; align-items: center; gap: 10px; }
.wf-meta .who { display: grid; line-height: 1.3; }
.wf-meta .who b { font-size: 13px; }
.wf-meta .who span { font-size: 11.5px; color: var(--text-dim); }
.wf-meta .when { margin-left: auto; font-size: 11.5px; color: var(--text-dim); }
.wf-actions { display: flex; gap: 6px; }
.wf-btn { white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; height: 27px; padding: 0 10px; border-radius: 8px; font-size: 12px; font-weight: 550; background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text); }
.wf-btn.primary { background: var(--accent); color: #fff; }
.wf[data-theme="dark"] .wf-btn.primary { color: #0d1726; }
.wf-btn svg.i { width: 14px; height: 14px; }
.wf-summary { margin: 14px 22px 0; padding: 11px 13px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 9%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent); display: grid; gap: 4px; font-size: 12.5px; }
.wf-summary b { display: flex; gap: 6px; align-items: center; color: var(--accent); font-size: 11.5px; font-weight: 650; }
.wf-msg { padding: 16px 22px; font-size: 13px; line-height: 1.6; display: grid; gap: 10px; color: var(--text); }
.wf-msg p { margin: 0; }
.wf-attach { display: flex; gap: 8px; }
.wf-attach span { white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 9px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; }
.wf-attach em { font-style: normal; color: var(--text-dim); font-size: 11px; }

/* security bar */
.wf-secbar { margin: 12px 22px 0; border-radius: 10px; background: color-mix(in srgb, var(--danger) 12%, var(--bg)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--danger) 40%, transparent); padding: 11px 13px; display: grid; gap: 6px; font-size: 12.5px; }
.wf-secbar b { color: var(--danger); display: flex; align-items: center; gap: 7px; font-size: 13px; }
.wf-secbar ul { margin: 0; padding-left: 18px; display: grid; gap: 3px; }
.wf-secbar code { font: 11.5px ui-monospace, "Cascadia Code", Menlo, monospace; background: color-mix(in srgb, var(--danger) 10%, transparent); padding: 0 4px; border-radius: 4px; }
.wf-secbar .row { display: flex; gap: 6px; margin-top: 2px; }
.wf-imgbar { margin: 8px 22px 0; display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-dim); padding: 7px 11px; border-radius: 9px; background: var(--bg-alt); }
.wf-imgbar .wf-btn { margin-left: auto; height: 23px; font-size: 11.5px; }
.wf-fake-cta { margin-top: 4px; justify-self: start; padding: 9px 18px; border-radius: 6px; background: #245a3b; color: #fff; font-weight: 600; font-size: 12.5px; }
.wf-pixel { height: 72px; border-radius: 8px; background: repeating-linear-gradient(135deg, var(--bg-alt) 0 8px, var(--bg) 8px 16px); box-shadow: inset 0 0 0 1px var(--border); display: grid; place-items: center; color: var(--text-dim); font-size: 11.5px; }

/* ---------- right panel ---------- */
.wf-panel { border-left: 1px solid var(--border); background: var(--bg); display: flex; flex-direction: column; min-height: 0; }
.wf-panel-body { flex: 1; min-height: 0; overflow: hidden; padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.wf-panel h5 { margin: 0; font-size: 10.5px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); }
.wf-glance { font-size: 13px; line-height: 1.45; }
.wf-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.wf-chips span { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); }
.wf-event { display: grid; grid-template-columns: 44px 1fr auto; gap: 8px; align-items: center; font-size: 12.5px; }
.wf-event .t { color: var(--text-dim); font-variant-numeric: tabular-nums; font-size: 11.5px; }
.wf-event .join { font-size: 11px; font-weight: 650; color: #fff; background: var(--ok); padding: 3px 9px; border-radius: 6px; }
.wf[data-theme="dark"] .wf-event .join { color: #0d1a12; }
.wf-person { display: flex; align-items: center; gap: 9px; font-size: 12.5px; }
.wf-person .wf-avatar { width: 24px; height: 24px; font-size: 10px; }
.wf-person span.dim { font-size: 11.5px; }

/* ---------- casebook ---------- */
/* ---------- the Casebook (round 5): a feed of posts, from Casebook.tsx and its cb-* rules ---------- */
.wf-cb { grid-template-columns: 60px minmax(0, 1fr) 280px; }
.wf-mrail { gap: 1px; padding-top: 12px; }
.wf-mrail span { width: 34px; height: 27px; }
.wf-mrail span.acc { height: 30px; }
.wf-atile { width: 20px; height: 20px; border-radius: 6px; display: inline-grid; place-items: center; font: 700 11px/1 system-ui, sans-serif; color: #fff; flex: none; }
.wf-atile.m { background: linear-gradient(135deg, #ea4335, #bb271a); }
.wf-atile.o { background: linear-gradient(135deg, #28a8ea, #0364b8); }
.wf-cbf { min-width: 0; background: var(--bg-alt); overflow: hidden; display: flex; flex-direction: column; }
.wf-cbf > * { flex: none; }
.wf-cbf .cbt { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; padding: 13px 22px; background: color-mix(in srgb, var(--bg-alt) 78%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--border) 55%, transparent); }
.wf-cbf .br { display: flex; align-items: center; gap: 12px; }
.wf-cbf .bd { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent); }
.wf-cbf .bd svg.i { width: 19px; height: 19px; }
.wf-cbf h4 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.15; }
.wf-cbf .br p { margin: 1px 0 0; font-size: 11.5px; color: var(--text-dim); }
.wf-cbf .ctl { display: flex; align-items: center; gap: 8px; align-self: flex-end; }
.wf-cbf .ctl .lbl { font-size: 13px; margin: 0 6px 0 1px; }
.wf-cbf .ctl .wf-pick { font-size: 12.5px; font-weight: 550; color: var(--text-dim); padding: 6px 12px 6px 14px; border-radius: 11px; }
.wf-cbf .srt { margin: 0; padding: 3px; gap: 3px; border-radius: 11px; font-size: 12.5px; }
.wf-cbf .srt span { display: inline-flex; gap: 5px; align-items: center; padding: 5px 12px; border-radius: 8px; font-weight: 550; }
.wf-cbf .srt span.on { color: var(--accent); font-weight: 650; }
.wf-cbf .srt svg.i { width: 13px; height: 13px; }
/* a row is a full-width band behind its card; the band is tinted while the mail is unread */
.wf-cbf .cbr { padding: 11px 22px; background: color-mix(in srgb, var(--text) 7%, var(--bg-alt)); }
.wf-cbf .cbr.un { background: color-mix(in srgb, var(--accent) 9%, var(--bg-alt)); }
.wf-cbf .cbr.day { display: flex; justify-content: center; padding: 10px 22px 1px; }
.wf-cbf .dy { padding: 5px 14px; border-radius: 15px; background: var(--bg); border: 1px solid var(--border); box-shadow: 0 1px 3px rgb(20 26 40 / 0.08); font-size: 12px; font-weight: 700; color: var(--text-dim); letter-spacing: 0.01em; }
.wf-post { position: relative; border-radius: 14px; overflow: hidden; background: color-mix(in srgb, var(--bg-alt) 45%, var(--bg)); border: 1px solid color-mix(in srgb, var(--border) 35%, transparent); box-shadow: 0 1px 2px rgb(20 26 40 / 0.04), 0 1px 8px rgb(20 26 40 / 0.05); }
.wf-post.unread { background: var(--bg); border-color: color-mix(in srgb, var(--accent) 22%, var(--border)); }
/* the cap: unread only; the triage grade overrides the accent */
.wf-post.unread::after { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--accent); }
.wf-post.unread.tr-reply::after { background: #e2603a; }
.wf-post.unread.tr-important::after { background: #d99a2b; }
.wf-post .pb { padding: 18px 20px 15px; }
.wf-post .ph { display: flex; align-items: center; gap: 14px; }
.wf-post .ph > .wf-avatar { width: 46px; height: 46px; font-size: 19px; font-weight: 600; }
.wf-post.t-hi .ph > .wf-avatar { width: 52px; height: 52px; font-size: 22px; }
.wf-post .who { min-width: 0; flex: 1; }
.wf-post .wt { display: flex; align-items: center; gap: 7px; font-size: 14px; }
.wf-post .wt b { font-weight: 500; }
.wf-post.unread .wt b { font-weight: 700; color: var(--unread); }
.wf-post .ud { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.wf-post .gr { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; padding: 1px 6px; border-radius: 4px; color: #e2603a; background: color-mix(in srgb, #e2603a 18%, transparent); }
.wf-post .gr.im { color: #b27a14; background: color-mix(in srgb, #d99a2b 18%, transparent); }
.wf-post .wt > svg.i { width: 13px; height: 13px; color: var(--text-dim); }
.wf-post .tm { margin-left: auto; font-size: 12px; color: var(--text-dim); }
.wf-post .ad { font-size: 12px; color: var(--text-dim); margin-top: 1px; }
.wf-post .ac { display: inline-flex; align-items: center; gap: 7px; margin-top: 7px; padding: 3px 11px 3px 3px; border-radius: 999px; font-size: 12.5px; font-weight: 650; color: color-mix(in srgb, var(--acct) 62%, var(--text)); background: color-mix(in srgb, var(--acct) 13%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acct) 32%, transparent); }
.wf-post .sj { margin: 12px 0 3px; font-size: 16px; font-weight: 500; line-height: 1.35; }
.wf-post.t-hi .sj { font-size: 19px; font-weight: 600; }
.wf-post.unread .sj { font-weight: 700; color: var(--unread); }
.wf-post .gs { margin: 0; font-size: 14px; line-height: 1.5; opacity: 0.85; }
.wf-post .rt { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; color: #e2603a; margin-right: 7px; }
/* the email itself: a sandboxed page, always on white, clipped with a fade into the card */
.wf-post .pv { position: relative; margin: 12px -20px 0; border-top: 1px solid var(--border); background: #fff; overflow: hidden; }
.wf-post .pvd { padding: 16px; font-size: 14px; line-height: 1.5; color: #1c2127; }
.wf-post .pvd p { margin: 0 0 10px; }
.wf-post .pvd table { border-collapse: collapse; margin: 0 0 12px; font-size: 13px; }
.wf-post .pvd th, .wf-post .pvd td { padding: 4px 16px 4px 0; border-bottom: 1px solid #e1e4e8; text-align: right; font-variant-numeric: tabular-nums; }
.wf-post .pvd th:first-child, .wf-post .pvd td:first-child { text-align: left; }
.wf-post .pvd th { font-weight: 600; color: #6a737d; font-size: 12px; }
.wf-post .pv > i { position: absolute; inset: auto 0 0 0; height: 56px; background: linear-gradient(180deg, transparent, var(--bg)); }
.wf-post .docs { display: flex; gap: 8px; margin-top: 8px; }
.wf-post .docs span { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 9px; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12.5px; }
.wf-post .docs svg.i { width: 13px; height: 13px; color: var(--text-dim); }
.wf-post .docs em { font-style: normal; font-size: 11.5px; color: var(--text-dim); }
.wf-post .pf { display: flex; align-items: center; gap: 12px; padding: 9px 15px; border-top: 1px solid var(--border); background: var(--bg-alt); }
.wf-post .pr { display: inline-flex; align-items: center; gap: 7px; }
.wf-post .pr > svg.i { width: 15px; height: 15px; }
.wf-post .pr.hi > svg.i { color: #d99a2b; } .wf-post .pr.nm > svg.i { color: var(--accent); } .wf-post .pr.lo > svg.i { color: var(--text-dim); }
.wf-post .pr .cap { font-size: 10px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-dim); }
.wf-post .pr .sel { display: inline-flex; align-items: center; gap: 8px; padding: 5px 9px 5px 11px; border-radius: 8px; border: 1px solid var(--border); background: var(--bg); font-size: 12.5px; font-weight: 550; }
.wf-post .pr .sel svg.i { width: 12px; height: 12px; color: var(--text-dim); }
.wf-post .acts { margin-left: auto; display: flex; gap: 1px; }
.wf-post .acts span { display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 6px; font-size: 12.5px; color: var(--text-dim); }
.wf-post .acts svg.i { width: 16px; height: 16px; }
/* the Digest (round 5) */
.wf-dg { background: var(--bg-alt); }
.wf-dg .wf-panel-body { gap: 7px; padding: 12px 12px; }
.wf-dg .dgh { display: flex; justify-content: space-between; align-items: center; color: var(--text-dim); }
.wf-dg .dgh b { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.wf-dg .dgh svg.i { width: 14px; height: 14px; }
.wf-dg .gl { display: flex; gap: 9px; align-items: flex-start; padding: 10px 11px; border-radius: 8px; background: color-mix(in srgb, var(--accent) 8%, transparent); font-size: 12.5px; line-height: 1.4; }
.wf-dg .gl svg.i { width: 15px; height: 15px; color: var(--accent); margin-top: 1px; }
.wf-dg h5 { margin: 8px 0 0; font-size: 13px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--text); }
.wf-dg h6 { margin: 2px 0 0 4px; font-size: 10.5px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); }
.wf-dg .ev { display: grid; grid-template-columns: 9px 40px minmax(0, 1fr); gap: 7px; align-items: center; padding: 0 4px; font-size: 12.5px; }
.wf-dg .ev i { width: 9px; height: 9px; border-radius: 2px; }
.wf-dg .ev span { color: var(--text-dim); }
.wf-dg .ev b { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-dg .pp { display: flex; align-items: center; gap: 9px; margin-top: 4px; font-size: 12.5px; }
.wf-dg .pp .wf-avatar { width: 26px; height: 26px; font-size: 10.5px; }
.wf-dg .pp b { font-weight: 650; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-dg .pp em { font-style: normal; font-size: 11px; font-weight: 600; color: var(--accent); }
.wf-dg .pm { display: grid; grid-template-columns: 7px minmax(0, 1fr) auto; gap: 7px; align-items: center; padding-left: 35px; font-size: 12px; }
.wf-dg .pm i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.wf-dg .pm i.r { background: transparent; }
.wf-dg .pm span:first-of-type { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-dg .pm span.num { color: var(--text-dim); font-size: 11px; }
.wf-prio { grid-row: span 3; align-self: start; font-size: 11px; padding: 3px 8px; border-radius: 7px; background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text-dim); }
.wf-prio.hi { background: color-mix(in srgb, var(--t-reply) 16%, transparent); color: var(--t-reply); font-weight: 650; }

/* ---------- assistant panel ---------- */
.wf-asst { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--bg); }
.wf-asst-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.wf-asst-head b { font-size: 13.5px; }
.wf-asst-head .model { margin-left: auto; font-size: 11px; display: inline-flex; gap: 5px; align-items: center; padding: 3px 8px; border-radius: 999px; background: color-mix(in srgb, var(--ok) 13%, transparent); color: var(--ok); font-weight: 600; }
.wf-asst-body { flex: 1; min-height: 0; padding: 14px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.wf-q { align-self: flex-end; max-width: 84%; background: var(--accent); color: #fff; padding: 8px 12px; border-radius: 14px 14px 4px 14px; font-size: 12.5px; }
.wf[data-theme="dark"] .wf-q { color: #0d1726; }
.wf-a { font-size: 12.5px; line-height: 1.55; display: grid; gap: 7px; }
.wf-a p { margin: 0; }
.wf-cite { display: inline-grid; place-items: center; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 5px; font-size: 10px; font-weight: 700; background: var(--bg-selected); color: var(--accent); vertical-align: 1px; }
.wf-think { font-size: 11.5px; color: var(--text-dim); font-style: italic; display: flex; gap: 6px; align-items: center; }
.wf-think i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); display: inline-block; }
.wf-draft { border-radius: 12px; box-shadow: inset 0 0 0 1px var(--border); background: var(--bg-alt); padding: 11px 12px; display: grid; gap: 8px; font-size: 12.5px; }
.wf-draft .lbl { font-size: 10.5px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); display: flex; align-items: center; gap: 6px; }
.wf-draft .row { display: flex; gap: 6px; }
.wf-input { margin: 0 14px 12px; height: 38px; border-radius: 11px; background: color-mix(in srgb, var(--text) 7%, transparent); display: flex; align-items: center; padding: 0 12px; gap: 8px; color: var(--text-dim); font-size: 12.5px; }
.wf-input .send { margin-left: auto; width: 26px; height: 26px; border-radius: 8px; background: var(--accent); color: #fff; display: grid; place-items: center; }
.wf-input .send svg.i { width: 14px; height: 14px; }

/* ---------- season view ---------- */
.wf-season { position: absolute; inset: 46px 0 0 0; padding: 12px 14px 12px; display: grid; grid-template-columns: 58px 1fr 58px; grid-template-rows: 58px 1fr 58px; gap: 6px; }
.wf-season-bar { position: absolute; top: 0; left: 0; right: 0; height: 46px; display: flex; align-items: center; gap: 14px; padding: 0 14px; border-bottom: 1px solid var(--border); }
.wf-band { display: grid; gap: 6px; }
.wf-band.h { grid-auto-flow: column; grid-auto-columns: 1fr; }
.wf-band.v { grid-auto-flow: row; grid-auto-rows: 1fr; }
.wf-month { border-radius: 7px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); position: relative; overflow: hidden; display: flex; }
.wf-month b { font-size: 10.5px; font-weight: 650; padding: 3px 0; text-align: center; }
.wf-band.h .wf-month { flex-direction: column; }
.wf-band.v .wf-month { flex-direction: row; }
.wf-band.v .wf-month b { writing-mode: vertical-rl; padding: 0 3px; text-align: center; }
.wf-band.v.left .wf-month b { transform: rotate(180deg); }
.wf-days { flex: 1; display: grid; gap: 1px; padding: 3px; }
.wf-band.h .wf-days { grid-auto-flow: column; grid-auto-columns: 1fr; }
.wf-band.v .wf-days { grid-auto-flow: row; grid-auto-rows: 1fr; }
.wf-days i { border-radius: 2px; background: color-mix(in srgb, var(--text) 5%, transparent); position: relative; }
.wf-days i.we { background: color-mix(in srgb, var(--text) 10%, transparent); }
.wf-days i.ev::after { content: ""; position: absolute; inset: auto 1px 1px 1px; height: 3px; border-radius: 2px; background: var(--ev, var(--accent)); }
.wf-band.v .wf-days i.ev::after { inset: 1px 1px 1px auto; width: 3px; height: auto; }
.wf-days i.today { box-shadow: 0 0 0 1.5px var(--accent); background: color-mix(in srgb, var(--accent) 20%, transparent); }
.wf-band.winter .wf-month b { background: color-mix(in srgb, var(--winter) 30%, transparent); }
.wf-band.spring .wf-month b { background: color-mix(in srgb, var(--spring) 30%, transparent); }
.wf-band.summer .wf-month b { background: color-mix(in srgb, var(--summer) 30%, transparent); }
.wf-band.autumn .wf-month b { background: color-mix(in srgb, var(--autumn) 30%, transparent); }
.wf-board { border-radius: 12px; box-shadow: inset 0 0 0 1px var(--border); position: relative; overflow: hidden;
  background:
    radial-gradient(circle at 30% 40%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 55%),
    radial-gradient(circle at 75% 70%, color-mix(in srgb, var(--autumn) 10%, transparent), transparent 50%),
    var(--bg); }
.wf-board-name { position: absolute; top: 12px; left: 14px; display: flex; gap: 6px; }
.wf-board-name span { font-size: 11.5px; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text-dim); }
.wf-board-name span.on { background: var(--bg-selected); color: var(--text); font-weight: 600; }
.wf-pin { position: absolute; width: 230px; border-radius: 12px; background: var(--bg); box-shadow: var(--shadow), inset 0 0 0 1px var(--border); overflow: hidden; }
.wf-pin header { padding: 8px 12px; display: grid; gap: 1px; }
.wf-pin header b { font-size: 12.5px; }
.wf-pin header span { font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-dim); font-weight: 650; }
.wf-pin .ev { margin: 0 8px 8px; padding: 7px 9px; border-radius: 8px; background: var(--bg-alt); display: flex; gap: 8px; align-items: center; font-size: 12px; }
.wf-pin .ev i { width: 3px; align-self: stretch; border-radius: 2px; }
.wf-pin .ev .t { color: var(--text-dim); font-size: 11px; }
.wf-pin .ev .wf-event .join { margin-left: auto; }

/* ---------- news wall ---------- */
.wf-wall { position: absolute; inset: 46px 0 0 0; padding: 14px 28px; overflow: hidden; font-size: 12px; }
.wf-wall-top { display: flex; align-items: baseline; gap: 10px; }
.wf-wall-top b { font-size: 15px; }
.wf-wall-top .open { margin-left: auto; font-size: 10.5px; font-weight: 650; color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, transparent); padding: 2px 7px; border-radius: 5px; }
.wf-rule2 { border-top: 3px double var(--text); margin: 8px 0 0; }
.wf-mast { text-align: center; padding: 8px 0 2px; }
.wf-mast small { font-size: 9.5px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--text-dim); }
.wf-mast h4 { margin: 2px 0 0; font: 800 38px/1 Georgia, "Iowan Old Style", "Times New Roman", serif; letter-spacing: 0.02em; }
.wf-dateline { display: flex; justify-content: space-between; font-size: 9.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-dim); padding: 4px 0 6px; border-bottom: 1px solid var(--text); }
.wf-intel { display: grid; grid-template-columns: repeat(5, 1fr); padding: 8px 0; border-bottom: 1px solid var(--border); }
.wf-intel div { padding: 0 12px; border-left: 1px solid var(--border); display: grid; gap: 1px; }
.wf-intel div:first-child { border-left: 0; padding-left: 0; }
.wf-intel span { font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-dim); font-weight: 650; }
.wf-intel b { font: 700 18px/1.15 Georgia, "Iowan Old Style", serif; }
.wf-intel em { font: italic 11px Georgia, serif; color: var(--text-dim); }
.wf-idx { display: flex; justify-content: center; gap: 18px; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.wf-hold { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; padding-top: 10px; }
.wf-hold > div { padding: 0 14px; border-left: 1px solid var(--border); display: grid; gap: 4px; align-content: start; }
.wf-hold > div:first-child { border-left: 0; padding-left: 0; }
.wf-hold .tk { display: flex; justify-content: space-between; font-size: 11.5px; border-bottom: 1px solid var(--text); padding-bottom: 3px; }
.wf-hold .tk b { font-size: 12px; }
.wf-hold .tk span { font-weight: 650; padding: 0 4px; border-radius: 3px; }
.wf-hold .tk span.up { background: color-mix(in srgb, var(--ok) 14%, transparent); }
.wf-hold .tk span.down { background: color-mix(in srgb, var(--danger) 14%, transparent); }
.wf-hold svg.spark { width: 100%; height: 32px; }
.wf-hold h5 { margin: 0; font: 600 13.5px/1.3 Georgia, "Iowan Old Style", serif; color: var(--text); text-transform: none; letter-spacing: 0; }
.wf-hold p { margin: 0; font-size: 10.5px; color: var(--text-dim); }
.wf-setups { margin-top: 12px; display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; border-top: 1px solid var(--text); padding-top: 8px; }
.wf-setups h6, .wf-cal h6 { margin: 0 0 4px; font-size: 9.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-dim); font-weight: 650; }
.wf-setups table { width: 100%; border-collapse: collapse; font-size: 11.5px; font-variant-numeric: tabular-nums; }
.wf-setups td { padding: 3px 4px; border-bottom: 1px solid var(--border); }
.wf-score { display: inline-block; width: 44px; height: 4px; border-radius: 2px; background: var(--bg-hover); vertical-align: middle; margin-right: 6px; position: relative; overflow: hidden; }
.wf-score i { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 2px; }
.wf-cal div { display: flex; gap: 12px; font-size: 11.5px; border-bottom: 1px solid var(--border); padding: 4px 0; }
.wf-cal span { color: var(--text-dim); font-size: 10px; letter-spacing: 0.08em; width: 70px; }

/* ---------- settings / models ---------- */
.wf-settings { position: absolute; inset: 0; display: grid; grid-template-columns: 200px 1fr; }
.wf-snav { background: var(--bg-alt); border-right: 1px solid var(--border); padding: 14px 10px; display: flex; flex-direction: column; gap: 1px; }
.wf-snav h6 { margin: 10px 8px 3px; font-size: 10px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim); font-weight: 650; }
.wf-snav span { display: flex; gap: 9px; align-items: center; padding: 5px 8px; border-radius: 7px; font-size: 12.5px; }
.wf-snav span svg.i { width: 14px; height: 14px; color: var(--text-dim); }
.wf-snav span.on { background: var(--bg-selected); font-weight: 600; }
.wf-snav span.on svg.i { color: var(--accent); }
.wf-spane { padding: 20px 24px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.wf-spane h4 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }
.wf-spane > p { margin: -8px 0 0; font-size: 12.5px; color: var(--text-dim); }
/* Settings › Models (round 5): the library, the encoder, and "Add your own model" */
.wf-mpane { gap: 10px; padding: 18px 22px; }
.wf-msrc { display: flex; gap: 8px; align-items: flex-start; font-size: 11.5px; color: var(--text-dim); line-height: 1.4; }
.wf-msrc svg.i { width: 14px; height: 14px; color: var(--ok); flex: none; margin-top: 1px; }
.wf-mhead { display: grid; gap: 1px; margin-top: 4px; }
.wf-mhead b { font-size: 13px; font-weight: 650; }
.wf-mhead .dim { font-size: 11.5px; }
.wf-models { display: grid; gap: 6px; }
.wf-model { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; align-items: center; padding: 8px 12px; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12.5px; }
.wf-model.rec { box-shadow: inset 0 0 0 1.5px var(--accent); background: color-mix(in srgb, var(--bg-selected) 55%, var(--bg)); }
.wf-model .name { display: flex; align-items: baseline; gap: 8px; min-width: 0; white-space: nowrap; }
.wf-model .name b { font-size: 13.5px; font-weight: 700; }
.wf-model .name .dim { font-size: 11.5px; }
.wf-model .cls { font-size: 10.5px; font-weight: 650; padding: 0 5px; border-radius: 5px; color: var(--text-dim); box-shadow: inset 0 0 0 1px var(--border); font-variant-numeric: tabular-nums; }
.wf-model .rec { font-size: 10.5px; font-weight: 650; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); padding: 1px 7px; border-radius: 10px; }
.wf-model p { grid-column: 1 / 2; margin: 0; font-size: 11.5px; color: var(--text-dim); line-height: 1.35; }
.wf-model p.why { display: flex; gap: 6px; align-items: center; color: var(--text); font-size: 11px; }
.wf-model p.why svg.i { width: 12px; height: 12px; color: var(--accent); }
.wf-model .state { grid-row: 1 / 3; grid-column: 2; justify-self: end; display: flex; align-items: center; gap: 8px; font-size: 11.5px; }
.wf-model .state .ok { color: var(--ok); display: inline-flex; gap: 5px; align-items: center; font-weight: 600; }
.wf-model .state svg.i { width: 14px; height: 14px; }
.wf-model.rec .state .wf-btn { height: 24px; }
.wf-prog { display: grid; gap: 4px; width: 118px; font-size: 10.5px; color: var(--text-dim); }
.wf-prog i { height: 5px; border-radius: 3px; background: var(--bg-hover); position: relative; overflow: hidden; display: block; }
.wf-prog i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--p, 60%); background: var(--accent); border-radius: 3px; }
.wf-menc .wf-model { padding-block: 7px; }
.wf-own { display: flex; gap: 8px; align-items: center; }
.wf-own .field { flex: 1; height: 30px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); display: flex; align-items: center; padding: 0 10px; font-size: 12px; color: var(--text-dim); }
.wf-own .wf-btn { height: 30px; }
.wf-mine { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; white-space: nowrap; min-width: 0; }
.wf-mine b { font-weight: 600; font-size: 12px; }
.wf-mine .pill { font-size: 10.5px; font-weight: 650; color: var(--ok); background: color-mix(in srgb, var(--ok) 13%, transparent); padding: 1px 7px; border-radius: 10px; }
.wf-mine .chip { display: inline-flex; gap: 4px; align-items: center; font-size: 11px; padding: 1px 7px; border-radius: 6px; background: var(--bg-hover); }
.wf-mine .chip svg.i { width: 12px; height: 12px; }
.wf-mine .path { font-size: 11px; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* =====================================================================
   Stocks frames (round 3): ticker, setup, studies, workbench, scorers,
   channels, watch. Tokens copied from the app (ui/src/styles.css): the
   moving-average ramp, the sector bars, and whose a study is.
   ===================================================================== */
.wf {
  --ma-1: #da7d00; --ma-2: #995700; --ma-3: #5e3300;
  --scope-private: #7c5cd6; --scope-shared: #0e8f8f;
  --sector-energy: #965719; --sector-technology: #3c6aa7; --sector-industrials: #6e893a;
  --sector-utilities: #038bad; --sector-real-estate: #994b6d; --sector-healthcare: #17a7a2;
  --sector-communication-services: #9086d1; --sector-consumer-cyclical: #9b66a4;
  --code-k: #0b4fc4; --code-s: #1a7f37; --code-n: #b35c00; --code-c: #6a737d;
}
.wf[data-theme="dark"] {
  --ma-1: #9d5900; --ma-2: #dd7f00; --ma-3: #ffba7d;
  --scope-private: #a78bfa; --scope-shared: #3fc1c1;
  --sector-energy: #b6753b; --sector-technology: #5988c8; --sector-industrials: #8eab5c;
  --sector-utilities: #40add1; --sector-real-estate: #b9698a; --sector-healthcare: #51cec8;
  --sector-communication-services: #b5acfa; --sector-consumer-cyclical: #be87c7;
  --code-k: #7aa7ff; --code-s: #7ecb95; --code-n: #e6a55a; --code-c: #8b949e;
}

/* ---------- stocks shell ---------- */
.wf-stk-t { grid-template-columns: 184px 236px minmax(0, 1fr) 262px; }
.wf-stk-s { grid-template-columns: 184px 236px minmax(0, 1fr); }
.wf-stk-b { grid-template-columns: 184px 252px minmax(0, 1fr); }
.wf-stk-c { grid-template-columns: 184px 300px minmax(0, 1fr); }
.wf-wb-body { grid-template-columns: 184px minmax(0, 1fr) 236px; }
.wf-sside .wf-side-scroll { padding: 10px 8px; gap: 1px; }
.wf-sside .wf-folder { padding: 4px 8px; font-size: 12.5px; white-space: nowrap; min-width: 0; }
.wf-sside .wf-folder svg.i { width: 14px; height: 14px; }
.wf-sdiv { height: 1px; background: var(--border); margin: 6px 8px; }
.wf-sgrp { margin: 10px 8px 3px !important; }
.wf-sgrp svg.i { width: 12px; height: 12px; }
.wf-sgrp svg.i:last-child { margin-left: auto; }
.wf-cdot { width: 8px; height: 8px; border-radius: 50%; flex: none; margin: 0 3px; display: inline-block; }
.wf-swatch { margin-top: 8px; border-top: 1px solid var(--border); border-radius: 0 !important; padding-top: 8px !important; }
.wf-tlogo { width: 20px; height: 20px; border-radius: 50%; flex: none; display: inline-grid; place-items: center; font-size: 10px; font-weight: 700; color: var(--text-dim); background: var(--bg-hover); }
.wf-tlogo.xl { width: 40px; height: 40px; font-size: 17px; color: #fff; background: #76b900; }
.wf-chg { font-size: 11.5px; font-weight: 650; padding: 1px 6px; border-radius: 5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wf-chg.up { color: var(--ok); background: color-mix(in srgb, var(--ok) 13%, transparent); }
.wf-chg.down { color: var(--danger); background: color-mix(in srgb, var(--danger) 12%, transparent); }
.wf-chg.xl { font-size: 13px; padding: 2px 8px; }
.wf-spill { font-size: 11px; font-weight: 600; min-width: 26px; text-align: center; padding: 1px 6px; border-radius: 999px; background: var(--bg-hover); color: var(--text-dim); font-variant-numeric: tabular-nums; }
.wf-pick { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; }
.wf-pick svg.i { width: 12px; height: 12px; }
.wf-pick.box { padding: 4px 10px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; background: var(--bg); }
.wf-link { font-size: 12px; color: var(--text); text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-ibtn { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: var(--text-dim); background: color-mix(in srgb, var(--text) 7%, transparent); }
.wf-ibtn svg.i { width: 15px; height: 15px; }
.wf-btn.ghost { background: transparent; box-shadow: inset 0 0 0 1px var(--border); }
.wf-stk .wf-btn svg.i:last-child:not(:first-child) { width: 12px; height: 12px; }

/* list column */
.wf-slist { border-right: 1px solid var(--border); display: flex; flex-direction: column; min-height: 0; background: var(--bg); }
.wf-slist-head { display: flex; align-items: flex-start; gap: 8px; padding: 12px 12px 6px; color: var(--text-dim); }
.wf-slist-head div { flex: 1; display: grid; gap: 2px; min-width: 0; }
.wf-slist-head b { font-size: 14.5px; color: var(--text); }
.wf-slist-head span { font-size: 11.5px; line-height: 1.35; }
.wf-slist-head svg.i { width: 14px; height: 14px; margin-top: 3px; }
.wf-slist-sort { display: flex; align-items: center; gap: 6px; padding: 4px 12px 8px; font-size: 11.5px; border-bottom: 1px solid var(--border); }
.wf-slist-sort svg.i { width: 13px; height: 13px; color: var(--text-dim); }
.wf-slist-sort .wf-ext { margin-left: auto; font-style: italic; }
.wf-srow { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; align-items: center; padding: 7px 12px 7px 14px; border-bottom: 1px solid var(--border); }
.wf-srow .wsct { position: absolute; left: 0; top: 5px; bottom: 5px; width: 3px; border-radius: 0 2px 2px 0; }
.wf-srow .id { display: grid; min-width: 0; line-height: 1.25; }
.wf-srow .id b { font-size: 13px; }
.wf-srow .id span { font-size: 11px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-srow .px { display: grid; justify-items: end; gap: 2px; }
.wf-srow .px b { font-size: 12.5px; font-weight: 600; display: flex; align-items: baseline; gap: 4px; }
.wf-srow .px em, .wf-thead .p em { font-style: normal; font-size: 9.5px; font-weight: 650; letter-spacing: 0.04em; color: var(--warn); }
.wf-srow .wf-chg { font-size: 10.5px; padding: 0 5px; }
.wf-srow.sel { background: var(--bg-selected); }
.wf-slist-add { white-space: nowrap; overflow: hidden; margin: 10px 12px; height: 30px; border-radius: 8px; display: flex; align-items: center; gap: 7px; padding: 0 10px; font-size: 11.5px; color: var(--text-dim); background: color-mix(in srgb, var(--text) 6%, transparent); }
.wf-slist-add svg.i { width: 13px; height: 13px; }

/* the dashboard */
.wf-tmain { min-width: 0; padding: 14px 20px 0; display: flex; flex-direction: column; gap: 10px; overflow: hidden; }
.wf-thead { display: flex; align-items: center; gap: 10px; }
.wf-thead .nme { display: grid; line-height: 1.2; min-width: 0; }
.wf-thead h4 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; }
.wf-thead .nme span { font-size: 11.5px; }
.wf-thead .q { margin-left: auto; display: grid; justify-items: end; gap: 2px; }
.wf-thead .p { display: flex; align-items: baseline; gap: 7px; }
.wf-thead .p b { font-size: 22px; font-weight: 700; letter-spacing: -0.01em; }
.wf-thead .p em { font-size: 10.5px; white-space: nowrap; }
.wf-thead.narrow { flex-wrap: wrap; row-gap: 6px; }
.wf-thead.narrow .nme { flex: 1; }
.wf-thead.narrow .q { flex-basis: 100%; margin-left: 50px; display: flex; align-items: baseline; gap: 8px; justify-items: start; white-space: nowrap; }
.wf-thead .q > span { font-size: 11.5px; }
.wf-ttabs { margin: 0 !important; align-self: flex-start; font-size: 12.5px; }
.wf-ttabs span { padding: 4px 14px; }
.wf-cbar { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 550; }
.wf-cbar .wf-seg { margin: 0; font-size: 11.5px; }
.wf-cbar .wf-seg span { padding: 3px 8px; font-weight: 600; }
.wf-cbar .wf-seg span.on { color: var(--accent); }
.wf-toggle { width: 30px; height: 17px; border-radius: 999px; background: var(--bg-hover); position: relative; margin-left: 6px; }
.wf-toggle.on { background: var(--accent); }
.wf-toggle i { position: absolute; top: 2px; left: 2px; width: 13px; height: 13px; border-radius: 50%; background: #fff; }
.wf-toggle.on i { left: 15px; }
.wf-legend { display: flex; gap: 14px; font-size: 12px; align-items: center; margin-top: -2px; }
.wf-legend span { display: inline-flex; align-items: center; gap: 5px; }
.wf-legend .sw { width: 12px; height: 2.5px; border-radius: 2px; display: inline-block; }
.wf-legend .sw.px { background: var(--accent); } .wf-legend .sw.ma1 { background: var(--ma-1); } .wf-legend .sw.ma2 { background: var(--ma-2); } .wf-legend .sw.ma3 { background: var(--ma-3); }
.wf-legend .cb { width: 14px; height: 14px; border-radius: 4px; box-shadow: inset 0 0 0 1.5px var(--border); display: grid; place-items: center; }
.wf-legend .cb.on { background: var(--accent); box-shadow: none; color: #fff; }
.wf[data-theme="dark"] .wf-legend .cb.on { color: #0d1726; }
.wf-legend .cb svg.i { width: 10px; height: 10px; stroke-width: 3; }
.wf-cwrap { margin: 0 -4px; }
.wf-cwrap.strip { margin-top: -2px; }

/* the chart */
.wf-chart { display: block; overflow: visible; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.wf-chart .g { stroke: color-mix(in srgb, var(--text) 9%, transparent); stroke-width: 1; }
.wf-chart .ax { fill: var(--text-dim); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.wf-chart .axl, .wf-chart .pane { stroke: var(--border); stroke-width: 1; }
.wf-chart .base { fill: color-mix(in srgb, var(--text) 9%, transparent); }
.wf-chart .fill { fill: color-mix(in srgb, var(--accent) 8%, transparent); }
.wf-chart .px { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; }
.wf-chart .px.post { stroke-opacity: 0.45; }
.wf-chart .dot { fill: var(--accent); }
.wf-chart .ma { fill: none; stroke-width: 1.2; }
.wf-chart .ma.ma1 { stroke: var(--ma-1); } .wf-chart .ma.ma2 { stroke: var(--ma-2); } .wf-chart .ma.ma3 { stroke: var(--ma-3); stroke-width: 2; }
.wf-chart .mat { font-size: 11px; font-weight: 650; }
.wf-chart .mat.ma1 { fill: var(--ma-1); } .wf-chart .mat.ma2 { fill: var(--ma-2); } .wf-chart .mat.ma3 { fill: var(--ma-3); }
.wf-chart .lv { stroke-width: 1; stroke-dasharray: 3 3; }
.wf-chart .lv.rew { stroke: color-mix(in srgb, var(--ok) 65%, transparent); }
.wf-chart .lv.rsk { stroke: color-mix(in srgb, var(--danger) 65%, transparent); }
.wf-chart .lv.str { stroke: color-mix(in srgb, var(--text) 38%, transparent); }
.wf-chart .lvn { font-size: 12px; font-weight: 650; }
.wf-chart .lvn.rew { fill: var(--ok); } .wf-chart .lvn.rsk { fill: var(--danger); } .wf-chart .lvn.str { fill: var(--text-dim); }
.wf-chart .ptag text { font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; fill: #fff; }
.wf-chart .ptag.str rect { fill: var(--text); } .wf-chart .ptag.str text { fill: var(--bg); }
.wf-chart .ptag.rew rect { fill: var(--ok); } .wf-chart .ptag.rsk rect { fill: var(--danger); } .wf-chart .ptag.last rect { fill: var(--accent); }
.wf[data-theme="dark"] .wf-chart .ptag.rew text, .wf[data-theme="dark"] .wf-chart .ptag.rsk text, .wf[data-theme="dark"] .wf-chart .ptag.last text { fill: #111418; }
.wf-chart .pl { fill: var(--text-dim); font-size: 10px; font-weight: 600; letter-spacing: 0.04em; }
.wf-chart .vb { fill: color-mix(in srgb, var(--text) 26%, transparent); }
.wf-chart .rband { fill: color-mix(in srgb, var(--text) 5%, transparent); }
.wf-chart .rsi { fill: none; stroke: var(--accent); stroke-width: 1.1; }
.wf-chart .tm { fill: var(--text-dim); font-size: 11px; font-weight: 600; }
.wf-chart .tm.d { font-weight: 400; }
/* candles, as PriceChart styles them: hollow with a green border when the session closed up, filled red when it closed down */
.wf-chart .cb.u { fill: none; stroke: var(--ok); stroke-width: 1; }
.wf-chart .cb.d { fill: var(--danger); stroke: var(--danger); stroke-width: 1; }
.wf-chart .wk { stroke-width: 1; }
.wf-chart .wk.u { stroke: var(--ok); } .wf-chart .wk.d { stroke: var(--danger); }
.wf-legend .sw.cu { width: 8px; height: 11px; border-radius: 1px; background: none; box-shadow: inset 0 0 0 1.2px var(--ok); }
.wf-legend .sw.cd { width: 8px; height: 11px; border-radius: 1px; background: var(--danger); }

.wf-keys { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 18px; }
.wf-keys div { display: flex; justify-content: space-between; gap: 8px; padding: 5px 0; border-bottom: 1px solid var(--border); font-size: 12px; white-space: nowrap; }
.wf-keys b { font-weight: 650; }
.wf-range { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 10px; align-items: center; font-size: 12px; padding: 8px 0 0; border-top: 1px solid var(--border); }
.wf-range .rbar { position: relative; height: 6px; border-radius: 3px; background: var(--bg-hover); }
.wf-range .rbar i { position: absolute; top: 0; bottom: 0; border-radius: 3px; background: color-mix(in srgb, var(--accent) 30%, transparent); }
.wf-range .rbar b { position: absolute; top: -3px; width: 3px; height: 12px; border-radius: 2px; background: var(--accent); }
.wf-range .rbar em { position: absolute; top: -2px; width: 1.5px; height: 10px; background: var(--ma-1); }
.wf-range .rbar em + em { background: var(--ma-3); }

/* movers panel */
.wf-movers .wf-panel-body { gap: 9px; padding: 12px 12px; }
.wf-mv-top { display: flex; align-items: center; color: var(--text-dim); }
.wf-mv-top svg.i { margin-left: auto; width: 14px; height: 14px; }
.wf-movers h5 .by { text-transform: none; letter-spacing: 0; font-weight: 500; }
.wf-mv-run { font-size: 11px; margin-top: 2px; }
.wf-mv-rows { display: grid; gap: 1px; margin-top: -3px; }
.wf-mv { display: grid; grid-template-columns: 20px 40px minmax(0, 1fr) auto auto; gap: 7px; align-items: center; font-size: 12px; padding: 3px 0; }
.wf-mv .nme { color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11.5px; }
.wf-mv .p { font-size: 11.5px; }
.wf-mv > .wf-spill { grid-column: 4 / 6; justify-self: end; }
.wf-movers .wf-link { margin-top: -4px; }

/* ---------- setup ---------- */
.wf-setupmain { gap: 8px; }
.wf-setup { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 26px; }
.wf-setup .scol { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.wf-shead { display: flex; gap: 16px; align-items: center; padding-bottom: 6px; }
.wf-sscore { display: grid; grid-template-columns: auto auto; align-items: baseline; column-gap: 3px; }
.wf-sscore b { font-size: 40px; line-height: 1; font-weight: 750; letter-spacing: -0.03em; }
.wf-sscore > span { font-size: 13px; }
.wf-sscore .meter { grid-column: 1 / 3; height: 4px; border-radius: 2px; background: var(--bg-hover); margin-top: 6px; position: relative; overflow: hidden; }
.wf-sscore .meter i { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 2px; }
.wf-shead .id { display: grid; gap: 3px; }
.wf-shead h4 { margin: 0; font-size: 17px; font-weight: 700; }
.wf-shead .id span { font-size: 11.5px; line-height: 1.35; }
.wf-stitle { font-size: 10.5px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); margin-top: 4px; }
.wf-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.wf-stats div { display: grid; gap: 1px; padding: 7px 9px; border-radius: 9px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); }
.wf-stats span { font-size: 11px; }
.wf-stats b { font-size: 15px; font-weight: 700; }
.wf-stats em { font-style: normal; font-size: 10.5px; line-height: 1.3; color: var(--text-dim); }
.wf-snote { margin: 0; font-size: 11.5px; color: var(--text-dim); }
.wf-flags { display: grid; gap: 4px; }
.wf-flag { display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 6px; font-size: 12px; line-height: 1.4; align-items: baseline; }
.wf-flag > b { font-weight: 800; text-align: center; }
.wf-flag.pos > b { color: var(--ok); } .wf-flag.neg > b { color: var(--danger); }
.wf-flag .lift { font-size: 11px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.wf-bars { display: grid; gap: 5px; }
.wf-sbar { display: grid; grid-template-columns: 124px minmax(0, 1fr) 24px; gap: 1px 8px; align-items: center; font-size: 12px; }
.wf-sbar > i { height: 6px; border-radius: 3px; background: var(--bg-hover); position: relative; overflow: hidden; }
.wf-sbar > i b { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 3px; }
.wf-sbar .v { text-align: right; font-weight: 650; }
.wf-sbar em { grid-column: 2 / 4; font-style: normal; font-size: 10.5px; color: var(--text-dim); }
.wf-sbar.muted { opacity: 0.55; }
.wf-sbar.muted > i b { background: var(--text-dim); }
.wf-setup .wf-link { margin-top: 4px; font-weight: 600; }
.wf-fall { display: grid; border-radius: 9px; box-shadow: inset 0 0 0 1px var(--border); overflow: hidden; }
.wf-fall div { display: flex; justify-content: space-between; gap: 10px; padding: 4px 10px; font-size: 12px; border-top: 1px solid var(--border); align-items: baseline; }
.wf-fall div:first-child { border-top: 0; }
.wf-fall em { display: block; font-style: normal; font-size: 10.5px; color: var(--text-dim); }
.wf-fall b { font-weight: 650; }
.wf-fall .tot { background: var(--bg-alt); font-weight: 700; }
.wf-fall .tot b { font-size: 14px; }
.wf-caveat { margin: 2px 0 0; font-size: 11.5px; line-height: 1.45; color: var(--text-dim); }

/* ---------- studies ---------- */
.wf-studiesmain { gap: 10px; }
.wf-stbar { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.wf-stbar > span:first-child { margin-right: auto; }
.wf-stbar .wf-btn { font-weight: 650; }
.wf-stbar em { font-style: normal; font-size: 10.5px; font-weight: 650; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); padding: 1px 6px; border-radius: 6px; }
.wf-study { display: grid; grid-template-columns: 170px minmax(0, 1fr); border-radius: 12px; box-shadow: inset 0 0 0 1px var(--border); overflow: hidden; flex: none; }
.wf-study .stt { background: var(--bg-alt); padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.wf-study .stt .lbl { font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-dim); }
.wf-study .stt b { font-size: 26px; font-weight: 750; letter-spacing: -0.02em; line-height: 1.1; }
.wf-study .stt .ms { margin-top: auto; display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: var(--text-dim); padding-top: 10px; }
.wf-study .stt .ms svg.i { width: 13px; height: 13px; }
.wf-study .bd { padding: 12px 16px 10px; display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.wf-study .hd { display: flex; align-items: center; gap: 8px; }
.wf-study h5 { margin: 0; font-size: 14.5px; font-weight: 700; margin-right: auto; }
.wf-scope { display: inline-flex; align-items: center; gap: 4px; font-size: 9.5px; font-weight: 700; letter-spacing: 0.06em; padding: 2px 7px; border-radius: 999px; }
.wf-scope svg.i { width: 11px; height: 11px; }
.wf-scope.pub { color: var(--scope-shared); background: color-mix(in srgb, var(--scope-shared) 13%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--scope-shared) 40%, transparent); }
.wf-scope.prv { color: var(--scope-private); background: color-mix(in srgb, var(--scope-private) 13%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--scope-private) 40%, transparent); }
.wf-study .ds { margin: 0; font-size: 12px; display: flex; gap: 6px; min-width: 0; }
.wf-study .ds span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.wf-study u, .wf-wb u, .wf-reader u { text-decoration-color: var(--border); text-underline-offset: 3px; color: var(--text); }
.wf-study .ds u { flex: none; }
.wf-figs { display: grid; grid-template-columns: 1fr 1fr; gap: 0 26px; }
.wf-fig { display: flex; justify-content: space-between; align-items: baseline; padding: 5px 0; border-bottom: 1px solid var(--border); font-size: 12.5px; }
.wf-fig b { font-size: 14px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.wf-fig i.yes { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); display: inline-block; }
.wf-study .ft { display: flex; gap: 14px; font-size: 11.5px; color: var(--text-dim); }
.wf-stretch { display: grid; gap: 4px; }
.wf-stretch .r { display: flex; justify-content: space-between; font-size: 12px; align-items: baseline; }
.wf-stretch .r b { font-size: 14px; font-weight: 700; }
.wf-stretch .r em { font-style: normal; font-weight: 400; color: var(--text-dim); font-size: 11.5px; }
.wf-stretch .ticks { font-size: 10.5px; color: var(--text-dim); margin-top: -2px; }
.wf-stretch .scale { position: relative; height: 4px; border-radius: 2px; background: var(--bg-hover); margin: 6px 0 2px; }
.wf-stretch .scale .z { position: absolute; top: 0; bottom: 0; width: 25%; background: color-mix(in srgb, var(--warn) 55%, var(--bg-hover)); border-radius: 2px; }
.wf-stretch .scale .z.l { left: 0; } .wf-stretch .scale .z.r { right: 0; }
.wf-stretch .scale b { position: absolute; top: -5px; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--bg); }
.wf-sline { display: block; max-width: 100%; }
.wf-sline .zero { stroke: color-mix(in srgb, var(--text) 25%, transparent); stroke-dasharray: 3 3; }
.wf-sline .area { fill: color-mix(in srgb, var(--accent) 10%, transparent); }
.wf-sline .ln { fill: none; stroke: var(--accent); stroke-width: 1.8; }
.wf-sline .end { fill: var(--accent); }

/* ---------- workbench ---------- */
.wf-wb { min-width: 0; padding: 12px 18px 12px; display: flex; flex-direction: column; gap: 9px; overflow: hidden; }
.wf-wb-top { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--text-dim); }
.wf-wb-top .crumb { display: inline-flex; align-items: center; gap: 2px; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--border); }
.wf-wb-top .crumb svg.i { width: 13px; height: 13px; }
.wf-wb-top .ttl { display: grid; line-height: 1.2; margin-right: auto; }
.wf-wb-top h4 { margin: 0; font-size: 16px; font-weight: 700; color: var(--text); }
.wf-wb-top .ttl span { font-size: 11.5px; }
.wf-wb-top .wf-pick { color: var(--text); }
.wf-wb-top > svg.i { width: 15px; height: 15px; }
.wf-wb-top .how { display: inline-flex; align-items: center; gap: 4px; }
.wf-wb-top .how svg.i { width: 13px; height: 13px; }
.wf-wb-banner { display: flex; align-items: center; gap: 9px; padding: 8px 12px; border-radius: 10px; font-size: 12px; background: color-mix(in srgb, var(--ok) 10%, var(--bg)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ok) 22%, transparent); }
.wf-wb-banner svg.i { color: var(--ok); width: 15px; height: 15px; }
.wf-wb-banner span { flex: 1; }
.wf-wb-banner u { font-size: 11.5px; color: var(--text-dim); }
.wf-wb-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 14px; flex: 1; min-height: 0; }
.wf-wb .ed { display: flex; flex-direction: column; gap: 6px; min-height: 0; }
.wf-wb .edh { display: flex; justify-content: space-between; align-items: center; font-size: 11.5px; }
.wf-wb .code { flex: 1; min-height: 0; overflow: hidden; border-radius: 10px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); padding: 6px 0; font: 11.5px/1.5 ui-monospace, "SF Mono", "Cascadia Code", Menlo, monospace; white-space: pre; color: var(--text); }
.wf-wb .code div { display: grid; grid-template-columns: 30px minmax(0, 1fr); }
.wf-wb .code i { font-style: normal; text-align: right; padding-right: 9px; color: var(--text-dim); opacity: 0.8; }
.wf-wb .code span { overflow: hidden; text-overflow: clip; }
.wf-wb .code k { color: var(--code-k); } .wf-wb .code s { color: var(--code-s); text-decoration: none; } .wf-wb .code n { color: var(--code-n); } .wf-wb .code f { color: var(--code-k); } .wf-wb .code c, .wf-wb .code .cm span { color: var(--code-c); font-style: italic; }
.wf-wb .code .ds span { color: var(--code-s); }
.wf-wb .code div:first-child { background: color-mix(in srgb, var(--accent) 7%, transparent); }
.wf-wb .vers { display: flex; gap: 6px; font-size: 11.5px; font-weight: 600; }
.wf-wb .vers span { padding: 2px 10px; border-radius: 999px; color: var(--text-dim); }
.wf-wb .vers span::before { content: "● "; font-size: 8px; vertical-align: 1px; }
.wf-wb .vers .on { color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.wf-wb .rs { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.wf-wb .rs-in { display: grid; grid-template-columns: minmax(0, 1fr) 124px; gap: 6px; align-items: end; }
.wf-wb .rs-in .go { grid-column: 1 / 3; display: flex; gap: 6px; justify-content: flex-end; }
.wf-wb .rs-in label { display: grid; gap: 3px; font-size: 11.5px; color: var(--text-dim); }
.wf-wb .fld, .wf-watch .fld { height: 30px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); background: var(--bg); display: flex; align-items: center; justify-content: space-between; padding: 0 9px; font-size: 12.5px; color: var(--text); white-space: nowrap; }
.wf-wb .fld svg.i { width: 13px; height: 13px; color: var(--text-dim); }
.wf-wb .rs-in .wf-btn { height: 30px; font-weight: 650; }
.wf-wb .rs-tabs { margin: 0; font-size: 12px; }
.wf-wb .rs-tabs span { flex: 1; text-align: center; padding: 4px 0; }
.wf-wb .rs-meta { font-size: 11.5px; }
.wf-res { display: grid; grid-template-columns: 46px minmax(0, 1fr) minmax(0, 1fr); gap: 3px 10px; align-items: center; padding: 9px 11px; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; }
.wf-res .tk { font-size: 13px; }
.wf-res div { display: grid; gap: 1px; }
.wf-res .lbl { font-size: 9.5px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim); }
.wf-res div b { font-size: 16px; font-weight: 700; }
.wf-res .log { grid-column: 2 / 4; font-size: 11px; color: var(--text-dim); }
.wf-state { justify-self: start; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; padding: 2px 8px; border-radius: 6px; }
.wf-state.good { color: var(--ok); background: color-mix(in srgb, var(--ok) 13%, transparent); }
.wf-state.neutral { color: var(--text-dim); background: var(--bg-hover); }
.wf-wb-foot { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 11px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; }
.wf-wb-foot > svg.i { color: var(--accent); width: 15px; height: 15px; }
.wf-wb-foot div:not(.wf-seg) { display: grid; line-height: 1.3; margin-right: auto; }
.wf-wb-foot .dim { font-size: 11.5px; }
.wf-wb-foot .wf-seg { margin: 0; }
.wf-wb-foot .wf-seg span { display: inline-flex; gap: 4px; align-items: center; font-weight: 600; }
.wf-wb-foot .wf-seg span.on { color: var(--accent); }
.wf-wb-foot svg.i { width: 13px; height: 13px; }
.wf-wb-foot .wf-btn { font-weight: 650; }
.wf-wb-asst { display: flex; flex-direction: column; }
.wf-wb-asst .wf-asst-body { flex: 1; }
.wf-wb-asst .wf-asst-head b { font-size: 13px; }

/* ---------- top scorers ---------- */
.wf-anal { border-right: 1px solid var(--border); padding: 10px 10px 10px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.wf-anal .hd { display: flex; align-items: center; gap: 6px; }
.wf-anal .hd b { font-size: 13.5px; font-weight: 600; }
.wf-anal .hd .dim { font-size: 11px; margin-left: auto; }
.wf-anal .hd svg.i { width: 14px; height: 14px; color: var(--text-dim); }
.wf-tc h6 { margin: 0; font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); }
/* the legend: every stock drawn, its colour and its score; "All" is the one picked */
.wf-anal .lg { display: flex; flex-wrap: wrap; gap: 3px 10px; margin: 2px 0 8px; font-size: 11px; font-weight: 500; line-height: 1.3; }
.wf-anal .lg span { display: inline-flex; align-items: center; gap: 5px; padding: 1px 3px; white-space: nowrap; }
.wf-anal .lg i { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.wf-anal .lg em { font-style: normal; color: var(--text-dim); }
.wf-anal .lg .all i { background: var(--text-dim); outline: 2px solid var(--text); outline-offset: 1px; }
.wf-pc { width: 100%; height: auto; display: block; font-family: system-ui, sans-serif; }
.wf-pc .tk { fill: var(--text-dim); font-size: 10.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.wf-pc .gr { stroke: color-mix(in srgb, var(--text) 22%, transparent); stroke-width: 1; stroke-dasharray: 5 4; }
.wf-pc .sep { stroke: var(--border); stroke-width: 1; }
.wf-pc .al { fill: var(--text); font-size: 11.5px; font-weight: 500; }
.wf-pc .al.minor { fill: var(--text-dim); font-style: italic; }
.wf-pc .pl { fill: none; stroke-width: 1.6; stroke-linecap: round; opacity: 0.4; }
.wf-tboard { min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.wf-tboard-head { padding: 12px 18px 10px; border-bottom: 1px solid var(--border); display: grid; gap: 8px; position: relative; }
.wf-tboard-head .ttl { display: flex; align-items: center; gap: 9px; }
.wf-tboard-head .ttl .wf-pick svg.i:first-child { width: 13px; height: 13px; color: var(--text-dim); }
.wf-tboard-head .ttl .fill { background: color-mix(in srgb, var(--text) 7%, transparent); box-shadow: none; }
.wf-tboard-head h4 { margin: 0; font-size: 17px; font-weight: 700; }
.wf-tboard-head .run { font-size: 12px; }
.wf-tboard-head .tools { display: flex; gap: 6px; align-items: center; justify-content: flex-end; }
.wf-tboard-head .tools .wf-ibtn { width: 28px; height: 28px; background: transparent; }
.wf-tboard-head .tools .wf-ibtn svg.i { width: 14px; height: 14px; }
.wf-tboard-head .tools .fld { width: 168px; height: 28px; border-radius: 8px; display: flex; align-items: center; gap: 6px; padding: 0 9px; font-size: 12px; color: var(--text-dim); background: color-mix(in srgb, var(--text) 6%, transparent); }
.wf-tboard-head .tools .fld svg.i { width: 13px; height: 13px; }
.wf-tboard-head .tools .wf-btn { height: 28px; }
.wf-tboard-head .tools .wf-seg { margin: 0; }
.wf-tboard-head .tools .wf-seg svg.i { width: 13px; height: 13px; display: block; }
.wf-runs { position: absolute; z-index: 2; top: 44px; left: 150px; width: 300px; padding: 10px 12px; border-radius: 12px; background: var(--bg); box-shadow: var(--shadow), inset 0 0 0 1px var(--border); display: grid; gap: 7px; font-size: 11.5px; }
.wf-runs .mo { font-weight: 650; font-size: 11px; letter-spacing: 0.02em; }
.wf-runs .days { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; }
.wf-runs .days span { display: grid; justify-items: center; gap: 3px; padding: 4px 0 5px; border-radius: 7px; grid-template-columns: 1fr 1fr; }
.wf-runs .days b { grid-column: 1 / 3; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.wf-runs .days i { width: 5px; height: 5px; border-radius: 50%; }
.wf-runs .days i.pre { justify-self: end; margin-right: 1px; } .wf-runs .days i.cl { justify-self: start; margin-left: 1px; }
.wf-runs i.pre { background: #d97706; } .wf-runs i.cl { background: var(--accent); }
.wf-runs .days span.on { background: var(--bg-selected); }
.wf-runs .both { display: grid; gap: 3px; border-top: 1px solid var(--border); padding-top: 7px; }
.wf-runs .both span { display: flex; align-items: center; gap: 7px; padding: 3px 6px; border-radius: 6px; }
.wf-runs .both span.on { background: var(--bg-selected); font-weight: 650; }
.wf-runs .both i { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.wf-runs .both .dim { padding-left: 0; font-weight: 600; }
.wf-cards { padding: 12px 18px; display: grid; gap: 12px; }
.wf-tc { display: grid; grid-template-columns: 146px minmax(0, 1fr) 210px; gap: 10px 18px; padding: 14px 16px 12px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--border), 0 1px 2px rgb(0 0 0 / 0.04); }
.wf-tc .tcl { display: flex; flex-direction: column; gap: 3px; align-items: flex-start; }
.wf-ring { width: 52px; height: 52px; }
.wf-ring .rt { fill: none; stroke: var(--bg-hover); stroke-width: 5; }
.wf-ring .rf { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; }
.wf-ring text { fill: var(--text); font-size: 16px; font-weight: 750; font-variant-numeric: tabular-nums; }
.wf-tc .tk { font-size: 15px; margin-top: 3px; }
.wf-tc .tcl > .dim { font-size: 11px; line-height: 1.3; }
.wf-verdict { font-size: 10.5px; font-weight: 600; padding: 1px 7px; border-radius: 10px; display: inline-flex; align-items: center; gap: 3px; }
.wf-verdict svg.i { width: 10px; height: 10px; stroke-width: 2.4; }
.wf-verdict.pos { color: var(--ok); background: color-mix(in srgb, var(--ok) 13%, transparent); }
.wf-verdict.neu { color: var(--text-dim); background: var(--bg-hover); }
.wf-tc .now { font-size: 11.5px; display: flex; gap: 5px; align-items: baseline; }
.wf-tc .now em { font-style: normal; font-size: 10.5px; font-weight: 700; padding: 0 5px; border-radius: 5px; background: var(--bg-hover); }
.wf-tc .now em.up { color: var(--ok); } .wf-tc .now em.down { color: var(--danger); }
.wf-tc .three { display: grid; gap: 2px; margin-top: 4px; width: 100%; }
.wf-tc .three div { display: flex; justify-content: space-between; font-size: 11.5px; }
.wf-tc .three span { color: var(--text-dim); }
.wf-tc .tcm { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.wf-tc .co { display: grid; line-height: 1.3; }
.wf-tc .co b { font-size: 13.5px; }
.wf-tc .co span { font-size: 11.5px; }
.wf-mini { width: 100%; height: auto; display: block; }
.wf-mini .vb rect { fill: color-mix(in srgb, var(--text) 18%, transparent); }
.wf-mini .area { fill: color-mix(in srgb, var(--ok) 10%, transparent); }
.wf-mini .ln { fill: none; stroke: var(--ok); stroke-width: 1.6; }
.wf-mini line { stroke-width: 1; stroke-dasharray: 4 3; }
.wf-mini line.tg { stroke: var(--ok); } .wf-mini line.en { stroke: var(--accent); } .wf-mini line.sp { stroke: var(--danger); }
.wf-mini text { font-size: 10.5px; font-weight: 600; }
.wf-mini text.tg { fill: var(--ok); } .wf-mini text.en { fill: var(--accent); } .wf-mini text.sp { fill: var(--danger); }
.wf-mini .rd { fill: var(--danger); } .wf-mini .gd { fill: var(--ok); }
.wf-tc .lad { display: grid; grid-template-columns: auto auto 1fr; gap: 1px 14px; font-size: 11.5px; }
.wf-tc .lad span { color: var(--text); }
.wf-tc .lad b { font-weight: 600; }
.wf-tc .lad em { font-style: normal; text-align: right; color: var(--text-dim); }
.wf-tc .lad em.up { color: var(--ok); } .wf-tc .lad em.down { color: var(--danger); }
.wf-tc .lad .tg { color: var(--ok); } .wf-tc .lad .sp { color: var(--danger); }
.wf-tc .lad i { grid-column: 1 / 4; height: 1px; background: var(--border); margin: 3px 0; }
.wf-tc .an { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-dim); border-top: 1px solid var(--border); padding-top: 4px; }
.wf-tc .an b { color: var(--text); }
.wf-tc .an em { font-style: normal; font-weight: 650; }
.wf-tc .tcr { display: flex; flex-direction: column; gap: 3px; }
.wf-an { display: grid; grid-template-columns: 84px minmax(0, 1fr) 22px; gap: 8px; align-items: center; font-size: 11px; font-weight: 500; }
.wf-an em { font-style: normal; text-align: right; }
.wf-an i { height: 5px; border-radius: 3px; background: var(--bg-hover); position: relative; overflow: hidden; }
.wf-an i b { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 3px; }
.wf-an.minor { font-weight: 400; font-style: italic; color: var(--text-dim); }
.wf-an.minor i b { background: color-mix(in srgb, var(--accent) 45%, transparent); }
.wf-an span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-tc .tcu { grid-column: 1 / 4; display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: 6px 18px; border-top: 1px solid var(--border); padding-top: 9px; font-size: 11.5px; line-height: 1.4; }
.wf-tc .tcu p { margin: 3px 0 0; }
.wf-tc .fa p { display: flex; gap: 6px; }
.wf-tc .fa b { color: var(--ok); font-weight: 800; } .wf-tc .fa b.n { color: var(--danger); }
.wf-tc .chips { grid-column: 1 / 4; display: flex; gap: 6px; flex-wrap: wrap; }
.wf-tc .chips span { font-size: 11px; padding: 2px 8px; border-radius: 6px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); display: inline-flex; align-items: center; gap: 6px; }
.wf-tc .chips i { width: 3px; height: 11px; border-radius: 2px; }

/* ---------- channels ---------- */
.wf-chq { border-right: 1px solid var(--border); padding: 12px 12px; display: flex; flex-direction: column; gap: 7px; min-width: 0; overflow: hidden; }
.wf-chq .hd { display: flex; align-items: center; gap: 8px; color: var(--text-dim); }
.wf-chq .hd b { font-size: 14px; color: var(--text); }
.wf-chq .hd .dim { margin-right: auto; font-size: 11.5px; }
.wf-chq .hd svg.i { width: 14px; height: 14px; }
.wf-pick.wide { justify-content: space-between; width: 100%; background: color-mix(in srgb, var(--text) 6%, transparent); box-shadow: none; }
.wf-chq .qst { font-size: 11px; line-height: 1.35; }
.wf-vrow { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 10px; padding: 8px 8px 8px 10px; border-radius: 8px; position: relative; font-size: 12px; line-height: 1.35; }
.wf-vrow::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 3px; border-radius: 2px; background: var(--ch); }
.wf-vrow.sel { background: var(--bg-selected); }
.wf-vrow .th { height: 38px; border-radius: 6px; background: linear-gradient(135deg, color-mix(in srgb, var(--ch) 38%, var(--bg-hover)), var(--bg-hover)); position: relative; }
.wf-vrow .th.ring::after { content: ""; position: absolute; left: 50%; top: 50%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; border: 2px solid var(--text-dim); border-right-color: transparent; }
.wf-vrow div { display: grid; gap: 1px; min-width: 0; }
.wf-vrow b { font-weight: 600; font-size: 12.5px; }
.wf-vrow .dim { font-size: 11px; }
.wf-vrow .nme { display: flex; gap: 6px; align-items: center; font-size: 11px; margin-top: 2px; min-width: 0; }
.wf-vrow .nme span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-vrow .nme em { font-size: 11px; }
.wf-tone { font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 5px; text-transform: lowercase; flex: none; }
.wf-tone.bullish { color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, transparent); }
.wf-tone.bearish { color: var(--danger); background: color-mix(in srgb, var(--danger) 13%, transparent); }
.wf-tone.mixed { color: var(--warn); background: color-mix(in srgb, var(--warn) 15%, transparent); }
.wf-tone.neutral { color: var(--text-dim); background: var(--bg-hover); }
.wf-reader { min-width: 0; padding: 12px 26px; display: flex; flex-direction: column; gap: 10px; overflow: hidden; }
.wf-reader .crumb { display: inline-flex; align-items: center; gap: 2px; font-size: 12px; color: var(--text-dim); text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; align-self: flex-start; }
.wf-reader .crumb svg.i { width: 13px; height: 13px; }
.wf-reader .top { display: grid; grid-template-columns: 264px minmax(0, 1fr); gap: 18px; align-items: start; }
.wf-reader .pstr { height: 148px; border-radius: 10px; position: relative; background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--ch) 45%, transparent), transparent 60%), linear-gradient(160deg, color-mix(in srgb, var(--ch) 22%, var(--bg-alt)), var(--bg-hover)); box-shadow: inset 0 0 0 1px var(--border); }
.wf-reader .pstr .pl { position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%; background: rgb(0 0 0 / 0.55); color: #fff; display: grid; place-items: center; }
.wf-reader .pstr .pl svg.i { width: 18px; height: 18px; fill: #fff; margin-left: 2px; }
.wf-reader .pstr em { position: absolute; right: 8px; bottom: 8px; font-style: normal; font-size: 10.5px; font-weight: 650; color: #fff; background: rgb(0 0 0 / 0.6); padding: 1px 5px; border-radius: 4px; }
.wf-reader .meta { display: flex; flex-direction: column; gap: 8px; }
.wf-reader h4 { margin: 0; font-size: 18px; font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; }
.wf-reader .who { display: flex; align-items: center; gap: 4px; font-size: 12.5px; }
.wf-reader .row { display: flex; gap: 6px; }
.wf-reader .row .wf-btn svg.i { width: 13px; height: 13px; }
.wf-reader .row .wf-btn.primary svg.i { fill: currentColor; }
.wf-reader .figs { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 22px; padding: 10px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.wf-reader .figs > div { display: grid; gap: 5px; align-content: start; justify-items: start; font-size: 12.5px; }
.wf-reader .figs .dim { font-size: 10.5px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; }
.wf-reader .figs .wf-tone { font-size: 12px; padding: 2px 8px; }
.wf-reader .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.wf-name { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 9px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; background: var(--bg); }
.wf-name em { font-style: italic; color: var(--text-dim); }
.wf-name b { font-weight: 700; }
.wf-name i { width: 18px; height: 18px; border-radius: 5px; display: grid; place-items: center; background: var(--bg-hover); color: var(--text-dim); }
.wf-name i svg.i { width: 11px; height: 11px; }
.wf-reader h5 { margin: 2px 0 -4px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim); }
.wf-reader .sum { margin: 0; font-size: 13px; line-height: 1.55; }
.wf-reader .pts { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 12.5px; line-height: 1.45; }
.wf-reader .rdft { font-size: 11.5px; margin-top: 2px; }
.wf-trans { display: grid; gap: 6px; padding: 10px 12px; border-radius: 10px; background: var(--bg-alt); box-shadow: inset 0 0 0 1px var(--border); }
.wf-trans .wf-seg { margin: 0 0 2px; justify-self: start; font-size: 11px; }
.wf-trans p { margin: 0; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; font-size: 12.5px; line-height: 1.45; }
.wf-trans p b { color: var(--accent); font-weight: 600; font-size: 11.5px; padding-top: 1px; }

/* ---------- the watch dialog ---------- */
.wf-watch { position: absolute; inset: 0; background: var(--bg); padding: 14px 16px; display: flex; flex-direction: column; gap: 9px; font-size: 12.5px; border-radius: 12px; }
.wf-watch .hd { display: flex; justify-content: space-between; align-items: center; }
.wf-watch .hd b { font-size: 15px; }
.wf-watch .hd svg.i { width: 15px; height: 15px; color: var(--text-dim); }
.wf-watch .ab { margin: 0; color: var(--text-dim); }
.wf-watch .ab b { color: var(--text); }
.wf-watch .cond { display: grid; grid-template-columns: 62px minmax(0, 1.35fr) minmax(0, 1.2fr) 58px; gap: 6px; align-items: center; }
.wf-watch .cond .j { font-size: 12px; color: var(--text-dim); text-align: center; }
.wf-watch .cond .wf-seg.j { margin: 0; font-size: 11px; }
.wf-watch .cond .wf-seg span { padding: 2px 6px; }
.wf-watch .sel, .wf-watch .val { height: 28px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); display: flex; align-items: center; justify-content: space-between; padding: 0 8px; font-size: 12px; white-space: nowrap; overflow: hidden; }
.wf-watch .sel svg.i { width: 12px; height: 12px; color: var(--text-dim); flex: none; }
.wf-watch .val { justify-content: flex-end; font-weight: 600; }
.wf-watch .add { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--text-dim); }
.wf-watch .add svg.i { width: 13px; height: 13px; }
.wf-watch label { display: grid; gap: 4px; font-size: 12px; font-weight: 600; }
.wf-watch .fld { font-weight: 400; }
.wf-watch .hint { margin: -4px 0 0; font-size: 11px; color: var(--text-dim); line-height: 1.4; }
.wf-watch .wdisc { font-size: 12px; color: var(--text); text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-watch .act { margin-top: auto; display: flex; justify-content: flex-end; gap: 6px; }
.wf-watch .act .wf-btn { height: 30px; padding: 0 14px; font-weight: 650; }

/* =====================================================================
   Round 4: video thumbnails (channels), seasonmap, edition.
   Every new class is wf-prefixed; nothing above this line changed.
   ===================================================================== */

/* ---------- video thumbnails: authored illustrations ---------- */
.wf-thumb { position: absolute; inset: 0; width: 100%; height: 100%; display: block; border-radius: inherit; }
.wf-thumb text { font-family: system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif; font-weight: 900; paint-order: stroke; stroke-width: 3px; stroke-linejoin: round; letter-spacing: 0; }
/* the app's ring on a video that is waiting its turn (stocks-spinner) */
.wf-vrow .th.ring::after { border-color: rgb(255 255 255 / 0.55); border-top-color: var(--accent); background: rgb(0 0 0 / 0.35); box-shadow: 0 0 0 4px rgb(0 0 0 / 0.35); }

/* ---------- seasonmap: the Season view over the map ----------
   The bands are `season`'s own. Here the months let the pinned day's number
   stand proud of its cell, and summer and spring carry their labels on the
   outer edge, as the app does, so every day cell faces the board. */
.wf-sm { --wf-sm-head: 40%; --wf-sm-body: 11%; }
.wf[data-theme="dark"] .wf-sm { --wf-sm-head: 62%; --wf-sm-body: 20%; }
.wf-sm .wf-month { overflow: visible; }
.wf-sm .wf-band.h .wf-month b { border-radius: 7px 7px 0 0; }
.wf-sm .wf-band.summer .wf-month { flex-direction: column-reverse; }
.wf-sm .wf-band.summer .wf-month b { border-radius: 0 0 7px 7px; }
.wf-sm .wf-band.summer .wf-days i.ev::after { inset: 1px 1px auto 1px; }
.wf-sm .wf-band.v .wf-month b { border-radius: 0 7px 7px 0; }
.wf-sm .wf-band.spring .wf-month { flex-direction: row-reverse; }
.wf-sm .wf-band.spring .wf-days i.ev::after { inset: 1px auto 1px 1px; }
.wf-sm .wf-days i.wf-sm-day { background: var(--bg-selected); z-index: 1; }
/* the number's outline stands for today's ring, and covers a side band's tick */
.wf-sm .wf-days i.wf-sm-day.today { box-shadow: none; }
.wf-sm .wf-band.v .wf-days i.wf-sm-day.ev::after { content: none; }
.wf-sm-num {
  position: absolute; font: 700 12px/1 system-ui, -apple-system, "Segoe UI", sans-serif; font-variant-numeric: tabular-nums;
  color: var(--accent); background: var(--bg); padding: 1px 6px; border-radius: 6px; white-space: nowrap;
  box-shadow: 0 0 0 1.5px var(--accent), 0 2px 6px rgb(0 0 0 / 0.35);
}
.wf-band.h .wf-sm-num { left: 50%; transform: translateX(-50%); }
.wf-band.winter .wf-sm-num { top: 2px; }
.wf-band.summer .wf-sm-num { bottom: 2px; }
.wf-band.v .wf-sm-num { top: 50%; transform: translateY(-50%); }
.wf-band.v.left .wf-sm-num { left: 2px; }
.wf-band.spring .wf-sm-num { right: 2px; }
/* the lead inside the day, from its number to the edge the connector leaves from */
.wf-sm .wf-band.h .wf-sm-day::before { content: ""; position: absolute; left: 50%; width: 1.5px; margin-left: -0.75px; border-radius: 2px; background: color-mix(in srgb, var(--text) 42%, transparent); }
.wf-sm .wf-band.summer .wf-sm-day::before { top: 0; bottom: 17px; }
.wf-sm .wf-band.winter .wf-sm-day::before { bottom: 0; top: 17px; }

.wf-sm-board, .wf-sm-cards { grid-area: 2 / 2; position: relative; min-width: 0; min-height: 0; border-radius: 12px; overflow: hidden; }
.wf-sm-board { background: var(--bg); }
.wf-sm-board::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px var(--border); }
.wf-sm-map { position: absolute; inset: 0; background: var(--wf-sm-light) center / cover no-repeat; }
.wf[data-theme="dark"] .wf-sm-map { background-image: var(--wf-sm-dark); }
.wf-sm-search { position: absolute; top: 10px; left: 10px; width: 250px; padding: 6px 11px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg); color: var(--text-dim); font-size: 13px; line-height: 1.4; }
.wf-sm-conn { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; overflow: visible; pointer-events: none; }
.wf-sm-conn path { fill: none; stroke: var(--text-dim); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; opacity: 0.9; }
.wf-sm-conn circle { fill: var(--text-dim); }
.wf-sm-cards { z-index: 3; }
.wf-sm-winter { --wf-sm-tint: var(--winter); }
.wf-sm-spring { --wf-sm-tint: var(--spring); }
.wf-sm-summer { --wf-sm-tint: var(--summer); }
.wf-sm-autumn { --wf-sm-tint: var(--autumn); }
.wf-sm-card {
  position: absolute; display: flex; flex-direction: column; overflow: visible; border: 1px solid var(--border); border-radius: 10px;
  background: color-mix(in srgb, var(--wf-sm-tint) var(--wf-sm-body), var(--bg)); box-shadow: 0 10px 30px rgb(0 0 0 / 0.35);
}
.wf-sm-head { display: flex; align-items: center; gap: 2px; padding: 7px 7px 7px 11px; border-radius: 9px 9px 0 0; border-bottom: 1px solid var(--border); background: color-mix(in srgb, var(--wf-sm-tint) var(--wf-sm-head), var(--bg)); color: color-mix(in srgb, var(--text) 74%, transparent); }
.wf-sm-when { display: grid; min-width: 0; margin-right: auto; }
.wf-sm-date { font-size: 11.5px; line-height: 1.35; font-weight: 650; color: var(--text); white-space: nowrap; }
.wf-sm-sub { font-size: 9.5px; line-height: 1.35; text-transform: uppercase; letter-spacing: 0.07em; margin-top: 1px; white-space: nowrap; }
.wf-sm-card svg.i { width: 13px; height: 13px; margin: 3.5px; stroke-width: 2.2; }
.wf-sm-body { padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.wf-sm-ev { display: flex; align-items: center; gap: 6px; padding: 8px 6px 8px 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--bg-alt); color: var(--text-dim); }
.wf-sm-rail { flex: none; width: 3px; border-radius: 3px; align-self: stretch; margin-right: 4px; }
.wf-sm-main { flex: 1; min-width: 0; min-height: 20px; display: flex; flex-direction: column; justify-content: center; }
.wf-sm-top { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.wf-sm-time { font-size: 11px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.wf-sm-title { font-size: 12px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-sm-loc { font-size: 10.5px; margin-top: 2px; }
.wf-sm-ev svg.i { opacity: 0.7; }
.wf-sm-loc { display: flex; align-items: center; gap: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-sm-card .wf-sm-loc svg.i { width: 10px; height: 10px; margin: 0; flex: none; }
/* the pin on an event with a place (ev-locate): faint until the row is pointed at; the row takes an accent edge */
.wf-sm-locate { position: relative; width: 20px; height: 20px; border-radius: 7px; display: grid; place-items: center; flex: none; opacity: 0.4; }
.wf-sm-card .wf-sm-locate svg.i { margin: 0; opacity: 1; }
.wf-sm-ev.on { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.wf-sm-ev.on .wf-sm-locate { opacity: 1; background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text); }
.wf-sm-tip { position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%); padding: 3px 7px; border-radius: 5px; background: #1c2127; color: #fff; font: 500 10.5px/1.3 system-ui, sans-serif; font-style: normal; white-space: nowrap; box-shadow: 0 4px 12px rgb(0 0 0 / 0.25); z-index: 5; }
.wf[data-theme="dark"] .wf-sm-tip { background: #e4e7eb; color: #1c2127; }
.wf-sm-search.on { color: var(--text); }
/* the map's one marker, where the place was found: at the centre, where the map flew */
.wf-sm-marker { position: absolute; left: 50%; top: 50%; width: 27px; height: 41px; transform: translate(-50%, -50%) translateY(-14px); z-index: 1; overflow: visible; }
.wf-sm-marker .mk { fill: var(--accent); }

/* ---------- edition: the news wall at the close ----------
   The wall's own setting (stocks-wall in the app): serif for the masthead,
   headlines, standfirst and copy; the system face for labels and figures. */
.wf-stk-e { grid-template-columns: 184px minmax(0, 1fr); }
.wf-ed {
  --wf-ed-serif: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --wf-ed-rule: color-mix(in srgb, var(--text) 82%, transparent);
  --wf-ed-hair: color-mix(in srgb, var(--text) 12%, transparent);
  min-width: 0; min-height: 0; overflow: hidden; padding: 8px 30px 0;
}
.wf-ed em { font-style: normal; }
.wf-ed-up { color: var(--ok); }
.wf-ed-dn { color: var(--danger); }
.wf-ed-dim { color: var(--text-dim); }
.wf-ed-num { font-variant-numeric: tabular-nums; }
.wf-ed-top { display: flex; align-items: center; gap: 10px; height: 26px; color: var(--text-dim); }
.wf-ed-top b { font-size: 15px; color: var(--text); }
.wf-ed-top svg.i { width: 14px; height: 14px; }
.wf-ed-state { margin-left: auto; font-size: 10.5px; font-weight: 650; color: color-mix(in srgb, var(--text) 78%, transparent); background: var(--bg-hover); padding: 2px 7px; border-radius: 5px; }
.wf-ed-pick { display: inline-flex; align-items: center; gap: 14px; font-size: 12px; font-weight: 600; color: var(--text); padding: 4px 8px 4px 11px; border-radius: 8px; background: color-mix(in srgb, var(--text) 6%, transparent); }
.wf-ed-top .wf-ed-pick svg.i { width: 12px; height: 12px; }
.wf-ed-paper { font-family: var(--wf-ed-serif); margin-top: 8px; }
.wf-ed-mast { text-align: center; border-top: 3px double var(--wf-ed-rule); padding-top: 7px; }
.wf-ed-over { font: 10px/1.3 system-ui, -apple-system, "Segoe UI", sans-serif; letter-spacing: 0.22em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 4px; }
.wf-ed-name { font-size: 35px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; line-height: 1; }
.wf-ed-run { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 5px 0 6px; border-bottom: 1px solid var(--wf-ed-rule); font: 10.5px/1.3 system-ui, -apple-system, "Segoe UI", sans-serif; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-dim); white-space: nowrap; }
.wf-ed-toc { text-transform: none; letter-spacing: 0; font-size: 11px; }
.wf-ed-label { display: block; font: 600 10px/1.3 system-ui, -apple-system, "Segoe UI", sans-serif; text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-dim); }
.wf-ed-intel { border-bottom: 1px solid var(--wf-ed-rule); padding: 5px 0 6px; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.wf-ed-ihead { display: flex; align-items: baseline; gap: 10px; margin-bottom: 5px; font-size: 10px; line-height: 1.3; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-dim); }
.wf-ed-ihead b { font-weight: 700; color: var(--text); }
.wf-ed-cells { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); column-gap: 22px; }
.wf-ed-icell { display: flex; flex-direction: column; gap: 2px; min-width: 0; border-left: 1px solid var(--wf-ed-hair); padding-left: 14px; }
.wf-ed-icell:first-child { border-left: 0; padding-left: 0; }
.wf-ed-ival { font: 700 19px/1.1 var(--wf-ed-serif); letter-spacing: -0.01em; }
.wf-ed-inote { font: italic 11.5px/1.3 var(--wf-ed-serif); color: var(--text-dim); }
.wf-ed-wx { display: flex; justify-content: center; gap: 22px; border-bottom: 1px solid var(--wf-ed-rule); padding: 4px 0; font: 11.5px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wf-ed-wx b { font-weight: 600; }
.wf-ed-wx em { padding: 0 3px; border-radius: 3px; }
.wf-ed-wx em.wf-ed-up { background: color-mix(in srgb, var(--ok) 12%, transparent); }
.wf-ed-wx em.wf-ed-dn { background: color-mix(in srgb, var(--danger) 12%, transparent); }
.wf-ed-money { display: flex; align-items: flex-end; gap: 26px; border-bottom: 1px solid var(--wf-ed-rule); padding: 7px 0 8px; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.wf-ed-cell { display: flex; flex-direction: column; gap: 1px; min-width: 0; white-space: nowrap; }
.wf-ed-cell .wf-ed-label { font-weight: 500; letter-spacing: 0.07em; }
.wf-ed-cv { font-size: 13.5px; line-height: 1.3; font-weight: 600; font-variant-numeric: tabular-nums; }
.wf-ed-big .wf-ed-cv { font-size: 22px; line-height: 1.05; letter-spacing: -0.01em; }
.wf-ed-gain .wf-ed-cv { color: var(--ok); }
.wf-ed-weather { margin-left: auto; align-self: stretch; display: flex; align-items: flex-end; gap: 26px; border-left: 1px solid var(--wf-ed-hair); padding-left: 24px; }
.wf-ed-sec { display: flex; align-items: baseline; gap: 14px; margin: 11px 0 8px; border-bottom: 2px solid var(--wf-ed-rule); padding-bottom: 2px; }
.wf-ed-letter { font-size: 24px; line-height: 1.15; font-weight: 700; }
.wf-ed-title { font-size: 19px; font-weight: 700; }
.wf-ed-kind { font: 10.5px system-ui, -apple-system, "Segoe UI", sans-serif; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-dim); }
.wf-ed-tail { margin-left: auto; font: 11.5px system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.wf-ed-stand { font-style: italic; font-size: 14.5px; line-height: 1.45; margin-bottom: 12px; max-width: 960px; }
/* the second row takes what the column beside the lead needs, so the lead's row is no taller than the lead */
.wf-ed-flow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: auto 1fr; column-gap: 24px; align-items: start; }
.wf-ed-lead { grid-column: 1 / 3; grid-row: 1; min-width: 0; }
.wf-ed-col { min-width: 0; }
.wf-ed-c1 { grid-column: 1; grid-row: 2; }
.wf-ed-c2 { grid-column: 2; grid-row: 2; }
.wf-ed-c3 { grid-column: 3; grid-row: 1 / 3; }
.wf-ed-c2, .wf-ed-c3 { border-left: 1px solid var(--wf-ed-hair); margin-left: -12px; padding-left: 12px; }
.wf-ed-c1, .wf-ed-c2 { margin-top: 14px; border-top: 1px solid var(--wf-ed-hair); padding-top: 10px; }
.wf-ed-hl { font-weight: 700; }
.wf-ed-lead .wf-ed-hl { font-size: 28px; line-height: 1.1; letter-spacing: -0.01em; margin-bottom: 8px; }
.wf-ed-sub .wf-ed-hl { font-size: 18px; line-height: 1.18; margin-bottom: 6px; }
.wf-ed-deck { font-size: 15px; line-height: 1.45; margin-bottom: 8px; }
.wf-ed-sub .wf-ed-deck { font-size: 13.5px; margin-bottom: 6px; }
.wf-ed-sub { padding-bottom: 10px; }
.wf-ed-by { font: 11px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); }
.wf-ed-srcs { margin-top: 6px; }
.wf-ed-src { font: 11.5px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; padding: 4px 0; border-top: 1px dotted var(--wf-ed-hair); }
.wf-ed-src b { font-weight: 600; }
.wf-ed-syms { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.wf-ed-sym { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; line-height: 1.3; font-weight: 650; padding: 1px 7px; border-radius: 6px; background: var(--bg-hover); font-variant-numeric: tabular-nums; }
.wf-ed-held { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 55%, transparent); }
.wf-ed-c3 > .wf-ed-label { margin-bottom: 6px; }
.wf-ed-theme { font-size: 13.5px; line-height: 1.45; padding-bottom: 10px; }
.wf-ed-brief { padding: 8px 0; border-bottom: 1px dotted var(--wf-ed-hair); }
.wf-ed-label + .wf-ed-brief { padding-top: 0; }
.wf-ed-bt { display: block; font-size: 14px; line-height: 1.25; font-weight: 700; }
.wf-ed-meta { display: block; font: 11px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--text-dim); margin-top: 2px; }

/* =====================================================================
   Round 5: the assistant's conversations, the omnibar, People, and a
   study written from plain words with its workings. Structure and
   strings from AssistantTab, MailList, StockSearch, Contacts,
   StudyPrompt, Workbench and StudyWorkings.
   ===================================================================== */
/* ---------- the assistant panel: chat history, new chat and profile; the status strip; the transcript ---------- */
.wf-ah { display: flex; align-items: center; gap: 6px; padding: 9px 10px 7px; }
.wf-ah .hist { display: inline-flex; align-items: center; gap: 6px; min-width: 0; flex: 1; font-size: 12.5px; color: var(--text-dim); }
.wf-ah .hist b { color: var(--text); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-ah .hist svg.i { width: 14px; height: 14px; }
.wf-ah .wf-ibtn { width: 26px; height: 26px; background: transparent; }
.wf-ah .wf-pick { font-size: 11.5px; white-space: nowrap; }
.wf-pick.box.fill { background: color-mix(in srgb, var(--text) 7%, transparent); box-shadow: none; }
.wf-astat { margin: 0 10px 4px; padding: 4px 9px; border-radius: 7px; display: flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 550; color: var(--ok); background: color-mix(in srgb, var(--ok) 10%, transparent); }
.wf-astat i { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); flex: none; }
.wf-asst .wf-asst-body { padding: 8px 12px 10px; gap: 8px; }
.wf-a { padding: 8px 11px; border-radius: 12px 12px 12px 4px; box-shadow: inset 0 0 0 1px var(--border); align-self: stretch; }
.wf-a ul { margin: 0; padding-left: 15px; display: grid; gap: 2px; }
.wf-a table { border-collapse: collapse; font-size: 11.5px; width: 100%; }
.wf-a td { padding: 2px 8px 2px 0; border-bottom: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.wf-a td:first-child { color: var(--text-dim); width: 44%; }
.wf-acts { display: flex; gap: 12px; font-size: 11px; color: var(--text-dim); margin-top: -3px; padding-left: 3px; }
.wf-acts u, .wf-tools u, .wf-write u { text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-tools { display: grid; gap: 3px; justify-items: start; }
.wf-tools > span { display: inline-flex; align-items: flex-start; gap: 5px; max-width: 100%; font-size: 11px; line-height: 1.35; color: var(--text-dim); background: var(--bg-hover); padding: 2px 7px; border-radius: 5px; }
.wf-tools svg.i { width: 11px; height: 11px; flex: none; margin-top: 2px; }
.wf-tools .hold { color: var(--text); background: color-mix(in srgb, var(--warn) 13%, transparent); }
.wf-tools .hold u { color: var(--text); font-weight: 600; margin-left: 4px; }
.wf-think { gap: 4px; }
.wf-think em { display: inline-flex; gap: 3px; margin-left: 2px; }
.wf-think em i { width: 4px; height: 4px; background: var(--text-dim); opacity: 0.7; }
.wf-mref { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 8px; padding: 6px 8px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--border); background: var(--bg-alt); }
.wf-mref .wf-avatar { grid-row: 1 / 4; width: 28px; height: 28px; font-size: 10.5px; }
.wf-mref .top { display: flex; align-items: center; gap: 5px; font-size: 11.5px; min-width: 0; }
.wf-mref .top b { font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-mref .top span { margin-left: auto; color: var(--text-dim); font-size: 10.5px; white-space: nowrap; }
.wf-mref .top svg.i { width: 11px; height: 11px; color: var(--text-dim); }
.wf-mref .sj, .wf-mref .sn { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-mref .sj { font-size: 11.5px; }
.wf-mref .sn { font-size: 11px; color: var(--text-dim); }
.wf-write { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 7px 8px; padding: 9px 11px; border-radius: 10px; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 50%, transparent); background: color-mix(in srgb, var(--accent) 8%, var(--bg)); font-size: 12px; line-height: 1.4; }
.wf-write > svg.i { width: 15px; height: 15px; color: var(--accent); }
.wf-write .row { grid-column: 2; display: flex; gap: 12px; align-items: center; font-size: 11.5px; }
.wf-write .wf-btn { height: 24px; }
.wf-starters { display: flex; flex-wrap: wrap; gap: 5px; padding: 0 12px 7px; }
.wf-starters span { font-size: 11px; padding: 3px 10px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--border); }
.wf-asst .wf-input { margin: 0 12px 10px; }
/* the Setup tab with the assistant beside it */
.wf-stk-o { grid-template-columns: minmax(0, 1fr) 340px; }
.wf-oscr { position: relative; border-left: 1px solid var(--border); padding: 0; }

/* ---------- the omnibar: the title-bar search, with plain words in it ---------- */
.wf-omni { background: var(--bg); box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.wf-omni svg.i { width: 14px; height: 14px; }
.wf-omni svg.i:first-child { color: var(--accent); width: 16px; height: 16px; }
.wf-omni .q { flex: 1; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-omail { grid-template-columns: 206px 408px minmax(0, 1fr); }
.wf-side h6 svg.i { width: 12px; height: 12px; }
.wf-reads { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; padding: 8px 12px 9px; border-bottom: 1px solid var(--border); font-size: 11.5px; }
.wf-reads .lbl { color: var(--text-dim); font-weight: 600; margin-right: 1px; }
.wf-fchip { display: inline-flex; gap: 4px; align-items: center; padding: 2px 5px 2px 9px; border-radius: 999px; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 60%, transparent); white-space: nowrap; }
.wf-fchip svg.i { width: 11px; height: 11px; color: var(--text-dim); }
.wf-fchip.wide { padding-right: 9px; color: var(--warn); box-shadow: none; background: color-mix(in srgb, var(--warn) 14%, transparent); font-weight: 600; }
/* …and in Stocks, where it looks tickers up */
.wf-osk { position: absolute; inset: 0; padding: 12px; display: flex; flex-direction: column; gap: 8px; background: var(--bg-alt); }
.wf-osk > .wf-search { width: 100%; flex: none; }
.wf-odrop { border-radius: 12px; background: var(--bg); box-shadow: var(--shadow), inset 0 0 0 1px var(--border); padding: 8px; display: grid; gap: 4px; }
.wf-odrop .st { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-dim); padding: 2px 6px 4px; }
.wf-ocard { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; grid-template-areas: "lg id qt" "lg ac ac"; gap: 6px 11px; padding: 9px 10px; border-radius: 10px; }
.wf-ocard.on { background: var(--bg-hover); box-shadow: inset 0 0 0 1px var(--border); }
.wf-ocard .wf-tlogo { grid-area: lg; width: 36px; height: 36px; font-size: 14px; }
.wf-ocard .id { grid-area: id; display: grid; gap: 1px; font-size: 12px; min-width: 0; }
.wf-ocard .id div { display: flex; gap: 6px; align-items: center; }
.wf-ocard .id b { font-size: 13.5px; }
.wf-ocard .id .dim { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-ocard .kind { font-size: 9.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 0 5px; border-radius: 4px; box-shadow: inset 0 0 0 1px var(--border); color: var(--text-dim); }
.wf-ocard .in { display: inline-flex; gap: 4px; align-items: center; font-size: 11px; color: var(--ok); }
.wf-ocard .in svg.i { width: 12px; height: 12px; }
.wf-ocard .qt { grid-area: qt; display: grid; justify-items: end; gap: 3px; }
.wf-ocard .qt b { font-size: 16px; font-weight: 650; }
.wf-ocard .acts { grid-area: ac; display: flex; gap: 6px; }
.wf-ocard .acts .wf-btn { height: 24px; font-size: 11.5px; }
.wf-ocard .acts svg.i { width: 12px; height: 12px; }

/* ---------- People (Contacts): the directory built from the mail in every account ---------- */
.wf-ppl { grid-template-columns: 206px 300px minmax(0, 1fr); }
.wf-plist { background: var(--bg-alt); border-right: 1px solid var(--border); padding: 10px; display: flex; flex-direction: column; gap: 7px; min-width: 0; overflow: hidden; }
.wf-seg.full { margin: 0; font-size: 12px; }
.wf-seg.full span { flex: 1; text-align: center; }
.wf-plist .tb { display: flex; align-items: center; gap: 10px; color: var(--text-dim); }
.wf-plist .tb .wf-seg { margin: 0 auto 0 0; font-size: 11px; }
.wf-plist .tb svg.i { width: 14px; height: 14px; }
.wf-plist .bn { display: flex; align-items: center; gap: 7px; font-size: 12px; padding: 6px 9px; border-radius: 8px; background: color-mix(in srgb, var(--accent) 11%, transparent); }
.wf-plist .bn svg.i { width: 14px; height: 14px; color: var(--accent); }
.wf-plist .bn u { margin-left: auto; color: var(--accent); font-weight: 600; text-decoration: none; }
.wf-plist .pr { display: flex; align-items: center; gap: 9px; padding: 4px 7px; border-radius: 7px; }
.wf-plist .pr.sel { background: var(--bg-selected); }
.wf-plist .pr.vend { box-shadow: 0 6px 0 -5px var(--border); margin-bottom: 4px; }
.wf-plist .pr .wf-avatar { width: 30px; height: 30px; }
.wf-plist .pr div { display: grid; min-width: 0; line-height: 1.3; }
.wf-plist .pr b { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 5px; }
.wf-plist .pr b svg.i, .wf-pd .pa .wf-btn:nth-child(2) svg.i { width: 12px; height: 12px; color: #d9a514; fill: #d9a514; }
.wf-plist .pr em { font-style: normal; font-size: 10px; font-weight: 700; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); padding: 0 5px; border-radius: 6px; }
.wf-plist .pr div span { font-size: 11px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-pd { padding: 20px 26px; display: flex; flex-direction: column; gap: 8px; min-width: 0; overflow: hidden; }
.wf-pd .ph { display: flex; gap: 14px; align-items: center; }
.wf-pd .ph .wf-avatar { width: 56px; height: 56px; font-size: 19px; }
.wf-pd .ph h4 { margin: 0; font-size: 20px; font-weight: 650; letter-spacing: -0.01em; }
.wf-pd .ph .dim { font-size: 12px; }
.wf-pd .pa { display: flex; gap: 6px; align-items: center; margin: 4px 0 4px; }
.wf-pd .pa .wf-seg { margin: 0; }
.wf-pd .pa svg.i { width: 13px; height: 13px; }
.wf-pd h6 { margin: 8px 0 0; font-size: 11px; font-weight: 650; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-dim); display: flex; gap: 6px; align-items: center; }
.wf-pd h6 em { font-style: normal; letter-spacing: 0; color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); padding: 0 6px; border-radius: 6px; }
.wf-pd .hint { margin: -3px 0 0; font-size: 12px; }
.wf-pd .mg, .wf-pd .ad { display: flex; align-items: center; gap: 10px; font-size: 12px; }
.wf-pd .mg { padding: 7px 10px; border-radius: 9px; box-shadow: inset 0 0 0 1px var(--border); }
.wf-pd .ad { padding: 5px 2px 6px; border-bottom: 1px solid var(--border); }
.wf-pd .mg .wf-avatar, .wf-pd .ad .wf-avatar { width: 24px; height: 24px; font-size: 9.5px; }
.wf-pd .mg div, .wf-pd .ad div { display: grid; line-height: 1.3; margin-right: auto; min-width: 0; }
.wf-pd .mg div span, .wf-pd .ad div span { font-size: 11px; color: var(--text-dim); }
.wf-pd .mg .wf-btn { height: 25px; }
.wf-pd .ad > .dim { font-size: 11px; }
.wf-pd u { font-size: 11.5px; text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-pd .two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.wf-pd .nt, .wf-pd .rm { margin-top: 6px; min-height: 44px; padding: 8px 10px; border-radius: 8px; font-size: 12px; line-height: 1.4; }
.wf-pd .nt { box-shadow: inset 0 0 0 1px var(--border); }
.wf-pd .rm { display: flex; gap: 7px; align-items: flex-start; background: var(--bg-alt); }
.wf-pd .rm svg.i { width: 13px; height: 13px; color: var(--accent); flex: none; margin-top: 1px; }
.wf-pd .rm svg.i:last-child { margin-left: auto; color: var(--text-dim); }
.wf-pd .cc { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 6px 10px; border-radius: 9px; box-shadow: inset 0 0 0 1px var(--border); font-size: 12px; }
.wf-pd .cc.out { background: color-mix(in srgb, #3a9d5d 7%, var(--bg)); }
.wf-pd .cc .dir { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.wf-pd .cc.out .dir { background: color-mix(in srgb, #3a9d5d 16%, transparent); color: #3a9d5d; }
.wf-pd .cc .dir svg.i { width: 12px; height: 12px; }
.wf-pd .cc div { display: grid; min-width: 0; line-height: 1.3; }
.wf-pd .cc div b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-pd .cc div span { color: var(--text-dim); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-pd .cc > .dim { font-size: 11px; }

/* ---------- a study from plain words: the Write a study dialog ---------- */
.wf-sp { position: absolute; inset: 0; display: grid; grid-template-columns: 150px minmax(0, 1fr); background: var(--bg); }
.wf-sp aside { background: var(--bg-alt); padding: 14px 10px 12px; display: flex; flex-direction: column; gap: 4px; border-right: 1px solid var(--border); }
.wf-sp .tt { display: flex; gap: 7px; align-items: center; font-size: 13px; margin: 0 4px 8px; }
.wf-sp .tt svg.i { color: var(--accent); width: 15px; height: 15px; }
.wf-sp .stp { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--text-dim); padding: 4px 6px; border-radius: 7px; }
.wf-sp .stp.on { background: var(--bg-selected); color: var(--text); font-weight: 600; }
.wf-sp .stp i { font-style: normal; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 10.5px; font-weight: 700; box-shadow: inset 0 0 0 1.5px currentColor; }
.wf-sp aside p { margin: auto 0 0; font-size: 10.5px; color: var(--text-dim); line-height: 1.35; display: flex; gap: 5px; }
.wf-sp aside p svg.i { width: 12px; height: 12px; flex: none; margin-top: 1px; }
.wf-sp .mn { padding: 18px 20px 14px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.wf-sp .mn h4 { margin: 0; font-size: 16px; font-weight: 700; }
.wf-sp .mn p { margin: 0; font-size: 12px; line-height: 1.45; }
.wf-sp .ta { min-height: 84px; padding: 10px 12px; border-radius: 9px; box-shadow: inset 0 0 0 1.5px var(--accent), 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); font-size: 13px; line-height: 1.45; }
.wf-sp .mn .sm { font-size: 11.5px; }
.wf-sp .go2 { margin-top: auto; display: flex; justify-content: space-between; }
.wf-sp .go2 .wf-btn { height: 30px; padding: 0 14px; font-weight: 650; }
/* the workbench, with Watson writing the draft */
.wf-wb2 { grid-template-columns: 184px minmax(0, 1fr) 300px; }
.wf-wb-asst { position: relative; }
.wf-wb2 .vers span::before { color: var(--ok); }
.wf-wb2 .vers .bad::before { color: var(--danger); }
.wf-wb2 .wf-res .log { display: flex; gap: 10px; align-items: center; text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-wb2 .wf-res .log .wf-state { text-decoration: none; }
.wf-wb2 .wf-wb-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }

/* ---------- the workings, docked beside the editor (Workbench › Workings; StudyWorkings' sw-* rules) ---------- */
.wf-wbk { grid-template-columns: 46px minmax(0, 1fr); }
.wf-rail { background: var(--bg-alt); border-right: 1px solid var(--border); display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 0 0; color: var(--text-dim); }
.wf-rail span { width: 30px; height: 28px; border-radius: 7px; display: grid; place-items: center; }
.wf-rail span.on { background: var(--bg-selected); color: var(--accent); }
.wf-rail svg.i { width: 15px; height: 15px; }
.wf-rail > i { width: 22px; height: 1px; background: var(--border); margin: 4px 0; }
.wf-rail .bt { margin-top: auto; width: 100%; border-top: 1px solid var(--border); display: grid; justify-items: center; gap: 4px; padding: 8px 0; }
.wf-wbk .wf-wb { padding: 12px 18px; }
.wf-wbk .wf-wb-banner u { margin-left: 4px; }
.wf-wbk .wf-wb-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); gap: 16px; }
.wf-wbk .rs { min-height: 0; }
/* a band of lines picked from outside: the workings step being read */
.wf-wb .code div.band { background: color-mix(in srgb, var(--accent) 10%, transparent); box-shadow: inset 3px 0 0 var(--accent); }
.wf-wb .code div.band i { color: var(--text); }
.wf-dock { flex: 1; min-height: 0; display: flex; flex-direction: column; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--border); overflow: hidden; }
.wf-dock .dh { display: flex; align-items: center; gap: 10px; padding: 8px 10px; font-size: 12px; }
.wf-dock .dh .dim { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wf-dock .dh .wf-btn { height: 26px; font-weight: 650; }
.wf-dock .dst { display: flex; align-items: center; gap: 10px; padding: 7px 12px; background: var(--bg-alt); border-block: 1px solid var(--border); font-size: 12px; }
.wf-dock .dst i { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); flex: none; }
.wf-dock .dst span { flex: 1; }
.wf-dock .dst em { font-style: normal; font-size: 11px; color: var(--text-dim); }
.wf-dock .dsc { padding: 0 14px 14px; overflow: hidden; display: flex; flex-direction: column; min-height: 0; }
.wf-dock .dsc > * { flex: none; }
.wf-dock .call { padding: 8px 12px; border: 1px solid var(--border); border-top: 0; border-radius: 0 0 8px 8px; font-size: 12px; }
.wf-dock .bh { font-size: 12px; }
.wf-dock .bh b { font-weight: 700; }
.wf-vspark { display: block; width: 100%; margin: 4px 0 6px; color: var(--accent); overflow: visible; }
.wf-vspark polyline { fill: none; stroke: currentColor; stroke-width: 1.6px; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.wf-dock .fold { font-size: 11.5px; color: var(--text-dim); }
.wf-dock h3 { margin: 14px 0 4px; font-size: 13.5px; font-weight: 600; }
.wf-dock .ws { position: relative; padding: 10px 0 6px 36px; border-top: 1px dashed color-mix(in srgb, var(--border) 80%, transparent); }
.wf-dock h3 + .ws { border-top: 0; }
.wf-dock .ws > i { position: absolute; left: 0; top: 9px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 11.5px; font-weight: 600; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.wf-dock .wsh { display: flex; align-items: baseline; gap: 10px; margin-bottom: 6px; font-size: 11px; color: var(--text-dim); }
.wf-dock .wsh h4 { flex: 1; min-width: 0; margin: 0; font-size: 13px; font-weight: 600; color: var(--text); }
.wf-dock .wsh u { color: var(--text); text-decoration-color: var(--border); text-underline-offset: 3px; }
.wf-dock .ws.on .wsh u { color: var(--accent); text-decoration-color: currentColor; }
.wf-dock .wv { padding: 7px 11px; border-radius: 8px; background: color-mix(in srgb, var(--text) 3.5%, transparent); margin-bottom: 6px; }
.wf-dock .wvh { display: flex; align-items: baseline; gap: 8px; margin-bottom: 3px; font-size: 11.5px; }
.wf-dock .wvh code { font: 600 12px ui-monospace, "SF Mono", "Cascadia Code", Menlo, monospace; }
.wf-dock .wvh .bdg { padding: 0 6px; border-radius: 999px; font-size: 10px; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.wf-dock .wvh .knd { margin-left: auto; font-size: 10.5px; color: var(--text-dim); }
.wf-dock .sc { font: 12px ui-monospace, "SF Mono", "Cascadia Code", Menlo, monospace; }
.wf-dock .sum { font-size: 11px; color: var(--text-dim); }
