/* 4Cee.ai. Layout: a sticky command bar, then one column of dense panels. Numbers are monospaced; a deep green is the brand accent (the logo, buttons, what is selected), amber marks anything that wants attention, and a brighter green and red are reserved for up and down. Charts never use the brand green for data, so it cannot be read as "up". */
:root {
  --bg: #f5f6f8; --panel: #ffffff; --panel-2: #f1f3f6; --line: #e2e5ea; --fg: #0f141a; --muted: #586373; --accent-ink: #ffffff; --seg-on: #ffffff;
  --accent: #0a5c43; --accent-soft: #e3f2ea; --warn-soft: #fbefd9; --up: #0a7a45; --down: #c4292f; --s1: #1f5fbf; --s2: #a15c00; --s3: #b8327f;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; --head: "Outfit", "Inter", ui-sans-serif, system-ui, sans-serif;
  /* Figures are set in the same face as the words, with digits of equal width so columns line up. */
  --mono: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 12px; --shadow: 0 1px 2px rgba(15, 20, 26, .05), 0 1px 3px rgba(15, 20, 26, .04); --pop: 0 14px 36px rgba(15, 20, 26, .16), 0 2px 6px rgba(15, 20, 26, .06); color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 14px/1.45 var(--sans); }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.up { color: var(--up); } .down { color: var(--down); } .muted { color: var(--muted); }

.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1360px; margin: 0 auto; padding: 10px max(16px, env(safe-area-inset-right, 0px)) 10px max(16px, env(safe-area-inset-left, 0px)); display: flex; align-items: center; gap: 10px 18px; flex-wrap: wrap; }
/* The mark is four letter Cs set one inside the other: an iris, and the name said aloud ("foresee"). */
.brand { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.brand-mark { width: 19.5px; height: 22px; flex: none; fill: none; stroke: var(--accent); stroke-width: 2.1; stroke-linecap: round; }
/* The name is set in Outfit, whose round C and e echo the mark. Only the seven characters of the name are downloaded. */
.brand-name { font: 600 19px/1 var(--head); letter-spacing: -.025em; color: var(--fg); }
.brand-name span { color: var(--accent); font-weight: 500; }
.nav { display: flex; gap: 4px; }
.nav a { padding: 6px 12px; border-radius: 999px; color: var(--muted); font-weight: 500; }
.nav a:hover { color: var(--fg); }
.nav a[aria-current="page"] { background: var(--panel); color: var(--fg); box-shadow: inset 0 0 0 1px var(--line); }
.search { position: relative; flex: 1 1 240px; max-width: 460px; min-width: 0; }
.search input { width: 100%; padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); }
.search input::placeholder { color: var(--muted); }
.search-results { position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: 0 14px 40px rgba(0, 0, 0, .22); overflow: hidden; z-index: 30; }
.search-results[hidden] { display: none; }
.sr { display: grid; grid-template-columns: 76px 1fr auto; gap: 10px; align-items: center; padding: 9px 12px; cursor: pointer; border: 0; background: none; width: 100%; text-align: left; }
.sr:hover, .sr[aria-selected="true"] { background: var(--panel-2); }
.sr b { font-family: var(--mono); font-weight: 600; }
.sr span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.sr small { color: var(--muted); }
.sr-empty { padding: 12px; margin: 0; color: var(--muted); }
.sr small:empty { display: none; }
.status { margin-left: auto; font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); display: inline-block; }
.dot.live { background: var(--up); }

.view { max-width: 1360px; margin: 0 auto; padding: 20px max(16px, env(safe-area-inset-right, 0px)) 40px max(16px, env(safe-area-inset-left, 0px)); display: flex; flex-direction: column; gap: 20px; outline: none; min-height: 70vh; }
.foot { max-width: 1360px; margin: 0 auto; padding: 0 16px 36px; color: var(--muted); font-size: 12px; }
.foot p { max-width: 90ch; margin: 0; }
.foot .foot-brand { display: flex; align-items: center; gap: 4px; margin-bottom: 6px; }
.foot .foot-brand .brand-mark { width: 14.2px; height: 16px; }
.foot .foot-brand .brand-name { font-size: 15px; }
.foot .foot-brand small { color: var(--muted); font-size: 12px; margin-left: 6px; }
.h1 { font-size: clamp(22px, 3vw, 30px); font-weight: 600; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
.h2 { font-size: 12px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin: 0; }
.sub { color: var(--muted); margin: 4px 0 0; max-width: 80ch; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; min-width: 0; }
.panel-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 12px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 430px), 1fr)); gap: 20px; }
.grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 20px; }
.msg { color: var(--muted); padding: 18px 4px; }
.msg.err { color: var(--down); }
.skel { height: 14px; border-radius: 4px; background: linear-gradient(90deg, var(--panel-2), var(--line), var(--panel-2)); background-size: 200% 100%; }
@media (prefers-reduced-motion: no-preference) { .skel { animation: sk 1.4s linear infinite; } @keyframes sk { to { background-position: -200% 0; } } }

/* index tiles */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 10px; }
.tile { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 12px 13px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); min-width: 0; }
.tile:hover { border-color: var(--muted); }
.tile-n { font-size: 12px; color: var(--muted); grid-column: 1 / -1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tile-p { font-family: var(--mono); font-size: 17px; font-weight: 500; }
.tile-c { font-family: var(--mono); font-size: 12px; align-self: end; text-align: right; }
.tile svg { grid-column: 1 / -1; width: 100%; height: 30px; margin-top: 4px; display: block; }

/* sector heat map */
.heat { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.heat a { display: flex; flex-direction: column; justify-content: space-between; gap: 10px; min-height: 76px; padding: 10px 11px; border-radius: 8px; border: 1px solid transparent; }
.heat a:hover { border-color: var(--fg); }
.heat span { font-size: 12px; font-weight: 500; }
.heat b { font-family: var(--mono); font-size: 16px; font-weight: 500; }
.heat-key { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); }
.heat-key i { width: 90px; height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--down), color-mix(in srgb, var(--muted) 25%, var(--panel)), var(--up)); display: inline-block; }

/* lists and tables */
.rows { display: flex; flex-direction: column; }
.row { display: grid; grid-template-columns: 64px 1fr auto auto; gap: 10px; align-items: center; padding: 8px 4px; border-top: 1px solid var(--line); }
.row:first-child { border-top: 0; }
.row:hover { background: var(--panel-2); }
.row b { font-family: var(--mono); font-weight: 600; }
.row .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); min-width: 0; }
.row .pc { min-width: 68px; text-align: right; }
.tblwrap { overflow-x: auto; }
table.wl { width: 100%; border-collapse: collapse; min-width: 760px; }
.wl th { text-align: right; font-size: 11px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.wl th:first-child, .wl td:first-child { text-align: left; }
.wl th button:not(.help) { all: unset; cursor: pointer; }
.wl th button:not(.help):hover, .wl th[aria-sort] button:not(.help) { color: var(--fg); }
.wl td { padding: 10px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
.wl tr:hover td { background: var(--panel-2); }
.wl .sym { font-family: var(--mono); font-weight: 600; }
.wl .co { display: block; font-size: 12px; color: var(--muted); max-width: 240px; overflow: hidden; text-overflow: ellipsis; }
.wl svg { width: 96px; height: 28px; display: block; margin-left: auto; }
.rng { position: relative; width: 110px; height: 6px; border-radius: 3px; background: var(--line); margin-left: auto; }
.rng i { position: absolute; top: -3px; width: 3px; height: 12px; border-radius: 2px; background: var(--fg); transform: translateX(-50%); }
.rng-l { display: flex; justify-content: space-between; width: 110px; margin: 4px 0 0 auto; font: 10px var(--mono); color: var(--muted); }
.btn { border: 1px solid var(--line); background: var(--panel); border-radius: 8px; padding: 7px 12px; cursor: pointer; font-weight: 500; }
.btn:hover { border-color: var(--muted); }
.btn.pri { background: var(--accent); border-color: var(--accent); color: var(--bg); }
.btn.sm { padding: 3px 8px; font-size: 12px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.seg button { border: 0; background: none; padding: 5px 10px; cursor: pointer; font: 500 12px var(--mono); color: var(--muted); }
.seg button:hover { color: var(--fg); }
.seg button[aria-pressed="true"] { background: var(--fg); color: var(--bg); }
.news a { display: block; padding: 10px 4px; border-top: 1px solid var(--line); }
.news a:first-child { border-top: 0; }
.news a:hover { background: var(--panel-2); }
.news small { display: block; color: var(--muted); margin-top: 2px; font-size: 12px; }

/* company page */
.co-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.co-sym { font: 600 12px var(--mono); letter-spacing: .08em; color: var(--accent); }
.co-px { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.co-px .p { font: 500 clamp(30px, 5vw, 44px)/1 var(--mono); }
.co-px .c { font: 500 16px var(--mono); }
.chart { position: relative; height: 420px; }
.chart-leg { position: absolute; left: 6px; top: 4px; z-index: 3; font: 12px var(--mono); color: var(--muted); pointer-events: none; background: color-mix(in srgb, var(--panel) 80%, transparent); padding: 2px 6px; border-radius: 4px; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.stat { background: var(--panel); padding: 12px 13px; min-width: 0; }
.stat span { display: block; font-size: 11px; color: var(--muted); letter-spacing: .04em; }
.stat b { display: block; font: 500 17px var(--mono); margin-top: 3px; }
.stat small { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }
.fchart { position: relative; min-height: 250px; }
.fchart svg { display: block; width: 100%; height: auto; overflow: visible; }
.ax { font: 11px var(--mono); fill: var(--muted); }
.lab { font: 11px var(--mono); fill: var(--fg); }
.tip { position: absolute; z-index: 5; pointer-events: none; background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 9px; font-size: 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); max-width: 240px; }
.tip[hidden] { display: none; }
.tip b { display: block; margin-bottom: 2px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; margin-right: 6px; vertical-align: -1px; }
.filing { display: grid; grid-template-columns: 62px 1fr auto; gap: 10px; align-items: center; padding: 8px 4px; border-top: 1px solid var(--line); }
.filing:first-child { border-top: 0; }
.filing:hover { background: var(--panel-2); }
.badge { font: 600 11px var(--mono); border: 1px solid var(--line); border-radius: 5px; padding: 2px 6px; text-align: center; }
.filing .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.note { background: var(--warn-soft); border: 1px solid color-mix(in srgb, var(--s2) 35%, transparent); border-radius: var(--r); padding: 10px 13px; font-size: 13px; }
@media (max-width: 560px) { .chart { height: 320px; } .status { display: none; } .panel { padding: 13px; } }

/* signals and alerts */
.count { display: inline-block; min-width: 18px; margin-left: 6px; padding: 0 5px; border-radius: 9px; background: var(--s2); color: var(--bg); font: 600 11px/18px var(--mono); text-align: center; }
.count[hidden] { display: none; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line); background: none; border-radius: 999px; padding: 5px 12px; cursor: pointer; font-size: 13px; }
.chip:hover { border-color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.sel, .inp { border: 1px solid var(--line); background: var(--panel); border-radius: 8px; padding: 7px 10px; max-width: 100%; }
.inp { width: 150px; }
.inp[hidden] { display: none; }
.earn { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.earn-c { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); }
.earn-c:hover { border-color: var(--muted); }
.earn-c.soon { border-color: var(--s2); background: var(--warn-soft); }
.earn-c b { font-family: var(--mono); }
.earn-c small { color: var(--muted); font-size: 12px; }
.earn-line { color: var(--s2); font-weight: 500; }
.ev-day { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 16px 4px 6px; border-bottom: 1px solid var(--fg); }
.ev-day:first-child { padding-top: 2px; }
.ev { display: grid; grid-template-columns: 70px 58px 74px 1fr auto; gap: 10px; align-items: center; padding: 9px 4px; border-bottom: 1px solid var(--line); }
.ev:not(:has(.ev-s)) { grid-template-columns: 58px 74px 1fr auto; }
.ev.hot { background: var(--warn-soft); }
.ev:hover { background: var(--panel-2); }
.ev-s { font: 600 13px var(--mono); }
.ev-s:hover { text-decoration: underline; }
.ev-b { min-width: 0; }
.ev-b:hover .ev-h { text-decoration: underline; }
.ev-h { display: block; }
.ev-b small { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; }
.pill-hot { font-size: 11px; font-weight: 600; color: var(--s2); border: 1px solid var(--s2); border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.al-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.al-rule { display: grid; grid-template-columns: 64px 1fr auto auto; gap: 10px; align-items: center; padding: 9px 4px; border-top: 1px solid var(--line); }
.al-rule:first-child { border-top: 0; }
.al-grid { align-items: start; }
.al-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.al-hit { display: grid; grid-template-columns: 64px 1fr auto; gap: 10px; align-items: baseline; padding: 9px 4px; border-top: 1px solid var(--line); }
.al-hit:first-child { border-top: 0; }
.al-hit:hover { background: var(--panel-2); }
.al-hit.new { background: var(--warn-soft); }
.al-hit b { font-family: var(--mono); }
.toasts { position: fixed; right: max(16px, env(safe-area-inset-right, 0px)); bottom: max(16px, env(safe-area-inset-bottom, 0px)); z-index: 40; display: flex; flex-direction: column; gap: 8px; max-width: min(360px, calc(100vw - 32px)); }
.toast { display: block; background: var(--panel); border: 1px solid var(--s2); border-radius: var(--r); padding: 10px 13px; box-shadow: 0 12px 32px rgba(0, 0, 0, .3); font-size: 13px; }
.toast b { display: block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--s2); margin-bottom: 2px; }
@media (max-width: 620px) { .ev { grid-template-columns: 58px 1fr auto; } .ev-t { grid-column: 1; } .ev .badge { justify-self: start; } .ev-b { grid-column: 1 / -1; } .ev:not(:has(.ev-s)) { grid-template-columns: 58px 1fr auto; } .nav a { padding: 6px 8px; } }
.setup { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 5px; }
.setup li { padding-left: 22px; position: relative; }
.setup li::before { content: ""; position: absolute; left: 3px; top: 6px; width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--muted); }
.setup li.ok::before { background: var(--up); border-color: var(--up); }
.setup li.todo { color: var(--muted); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* engine screens */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tab { padding: 9px 14px; color: var(--muted); font-weight: 500; white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab:hover { color: var(--fg); }
.tab[aria-current="page"] { color: var(--fg); border-bottom-color: var(--accent); }
.eng { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.lead { font-size: 16px; line-height: 1.5; margin: 0 0 12px; max-width: 80ch; }
.lead b { font-family: var(--mono); font-weight: 600; }
.psub { margin: -6px 0 12px; }
.fine { font-size: 12px; color: var(--muted); margin: 12px 0 0; max-width: 95ch; }
.gap { margin-top: 18px; margin-bottom: 8px; }
.grid2.g64 { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
.grid2.tight { gap: 8px 24px; }
@media (max-width: 900px) { .grid2.g64 { grid-template-columns: minmax(0, 1fr); } }
.wf { display: flex; flex-direction: column; }
.wf-row { display: grid; grid-template-columns: minmax(120px, 30%) 1fr 70px; gap: 12px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); }
.wf-row:first-child { border-top: 0; }
.wf-row b { text-align: right; font-weight: 500; }
.wf-total { border-top: 1px solid var(--fg); font-weight: 600; }
.wf-l small { display: block; color: var(--muted); font-size: 11px; font-weight: 400; }
.wf-t { position: relative; height: 16px; }
.wf-zero { position: absolute; top: -7px; bottom: -7px; border-left: 1px dashed var(--muted); }
.wf-bar { position: absolute; top: 0; bottom: 0; border-radius: 3px; }
.wf-bar.pos, .split-t i.pos, .ftrack i.pos { background: var(--up); }
.wf-bar.neg, .split-t i.neg, .ftrack i.neg { background: var(--down); }
.wf-bar.tot { background: var(--fg); }
.daycard { display: flex; flex-direction: column; gap: 10px; }
.day-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.day-m { display: flex; align-items: baseline; gap: 10px; }
.day-m b { font: 500 30px/1 var(--mono); }
.splits { display: flex; flex-direction: column; gap: 6px; }
.split { display: grid; grid-template-columns: minmax(96px, 38%) 1fr 62px; gap: 8px; align-items: center; font-size: 13px; }
.split b { text-align: right; font-weight: 500; }
.split-t, .ftrack { position: relative; height: 12px; }
.split-t::before, .ftrack::before { content: ""; position: absolute; left: 50%; top: -3px; bottom: -3px; border-left: 1px solid var(--muted); }
.split-t i, .ftrack i { position: absolute; top: 0; bottom: 0; border-radius: 3px; }
.mv { display: grid; grid-template-columns: 104px 74px 1fr auto; gap: 10px; align-items: center; padding: 8px 6px; border: 0; border-top: 1px solid var(--line); background: none; text-align: left; cursor: pointer; width: 100%; }
.mv:first-child { border-top: 0; }
.mv:hover, .mv[aria-pressed="true"] { background: var(--panel-2); }
.mv[aria-pressed="true"] { box-shadow: inset 3px 0 0 var(--accent); }
.mv-l { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-box { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; background: var(--panel-2); }
.ai-h { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.ai-t { margin: 0 0 8px; white-space: pre-line; max-width: 85ch; }
.ai-src { display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.ai-src a, .drv a { text-decoration: underline; color: var(--muted); }
.wl.tb td:first-child { white-space: normal; min-width: 190px; }
.wl.tb { min-width: 640px; }
.wl.radar { min-width: 1080px; }
.wl tr.on td { background: var(--accent-soft); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 10px; }
.pcard { display: flex; flex-direction: column; gap: 6px; text-align: left; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); cursor: pointer; min-width: 0; }
.pcard.static { cursor: default; }
.pcard:not(.static):hover { border-color: var(--muted); }
.pcard[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.pcard small { font-size: 12px; color: var(--fg); }
.pcard small.muted { color: var(--muted); }
.ev-pill { align-self: flex-start; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 1px 8px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.ev-pill.strong, .ev-pill.pos { color: var(--up); border-color: var(--up); }
.ev-pill.neg { color: var(--down); border-color: var(--down); }
.ev-pill.some { color: var(--s2); border-color: var(--s2); }
.meter { margin-bottom: 12px; }
.meter-h { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; margin-bottom: 4px; }
.meter-t { position: relative; height: 8px; border-radius: 4px; background: var(--line); }
.meter-t i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 4px; background: var(--s1); }
.meter-t u { position: absolute; top: -4px; bottom: -4px; border-left: 2px solid var(--fg); }
.meter small { font-size: 11px; }
.fhead { display: grid; grid-template-columns: minmax(130px, 38%) 1fr 62px; gap: 10px; font-size: 11px; color: var(--muted); padding: 0 6px 6px; }
.fhead div:nth-child(2) { display: flex; justify-content: space-between; }
.frow { display: grid; grid-template-columns: minmax(130px, 38%) 1fr 62px; gap: 10px; align-items: center; width: 100%; padding: 9px 6px; border: 0; border-top: 1px solid var(--line); background: none; text-align: left; cursor: pointer; }
.frow:hover, .frow[aria-expanded="true"] { background: var(--panel-2); }
.frow b { text-align: right; font-weight: 500; }
.fname { font-weight: 500; font-size: 13px; }
.fdetail { grid-column: 1 / -1; font-size: 13px; max-width: 80ch; }
.drv { display: grid; grid-template-columns: 86px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); align-items: start; }
.drv:first-child { border-top: 0; }
.drv small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.mini { margin: 2px 0 0; padding-left: 16px; font-size: 12px; color: var(--muted); display: flex; flex-direction: column; gap: 3px; }
.mini.big { font-size: 14px; color: var(--fg); gap: 6px; max-width: 80ch; }
.gaps { margin-top: 14px; }
.gaps summary { cursor: pointer; font-weight: 500; }
.chipx { display: inline-block; font-size: 11px; border: 1px solid var(--line); border-radius: 999px; padding: 1px 7px; margin: 1px 3px 1px 0; white-space: nowrap; }
.wl td.setups { white-space: normal; text-align: left; min-width: 230px; }
@media (max-width: 560px) { .mv { grid-template-columns: 92px 64px 1fr; } .mv span:last-child { display: none; } .wf-row { grid-template-columns: minmax(104px, 36%) 1fr 62px; } }

/* ---------- health tab, annual-report changes, economy panel, portfolio ---------- */
.hbig { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 10px; margin: 0 0 8px; }
.hbig b { font: 600 28px/1 var(--mono); }
.setup.checks { gap: 9px; margin-top: 12px; }
.setup li.no::before { background: var(--down); border-color: var(--down); }
.setup li small { display: block; color: var(--muted); font-size: 12px; }
.setup.checks li.todo span { color: var(--muted); }
.gauge-w { position: relative; margin: 14px 0 10px; }
.gauge { display: flex; height: 10px; border-radius: 5px; overflow: hidden; gap: 2px; }
.gauge i { display: block; height: 100%; }
.gauge i.bad { background: color-mix(in srgb, var(--down) 60%, var(--panel)); }
.gauge i.mid { background: var(--line); }
.gauge i.good { background: color-mix(in srgb, var(--up) 60%, var(--panel)); }
.gauge-m { position: absolute; top: -5px; width: 4px; height: 20px; border-radius: 2px; background: var(--fg); transform: translateX(-50%); box-shadow: 0 0 0 2px var(--panel); }
.gauge-l { display: flex; justify-content: space-between; gap: 8px; margin-top: 8px; font: 11px var(--mono); color: var(--muted); }
.frow.flat { cursor: default; }
.frow.flat:hover { background: none; }
.ftrack i.warm { background: var(--s2); }
.ftrack i.cool { background: var(--s1); }
.ulink, .wl.macro td a { text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.ulink:hover, .wl.macro td a:hover { text-decoration-color: var(--fg); }
.dgroup { border-top: 1px solid var(--line); padding: 10px 0 4px; margin-top: 12px; }
.dgroup summary { cursor: pointer; font-weight: 500; }
.dpara { margin: 10px 0 0; padding: 2px 0 2px 12px; border-left: 3px solid var(--line); font-size: 13px; max-width: 95ch; }
.dpara.add { border-color: var(--up); }
.dpara.del { border-color: var(--down); color: var(--muted); }
.dpara small { display: block; font-size: 11px; font-weight: 600; letter-spacing: .03em; color: var(--muted); }
.dchg { margin-top: 14px; }
.dlead { margin: 0; font-size: 12px; color: var(--muted); max-width: 95ch; }
.wl.macro tr.grp th { text-align: left; font: 600 12px var(--sans); color: var(--fg); padding-top: 16px; letter-spacing: .02em; }
.wl.macro td { white-space: normal; }
.wl.macro td:first-child { min-width: 220px; }
.wl.macro svg { width: 96px; height: 26px; display: block; margin-left: auto; }
.pf-rows { display: flex; flex-direction: column; }
.pf-row { display: grid; grid-template-columns: minmax(64px, 110px) 1fr auto; gap: 10px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); }
.pf-row:first-child { border-top: 0; }
.pf-row label { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pbar { display: grid; grid-template-columns: minmax(90px, 1fr) 44px; gap: 4px 8px; align-items: center; min-width: 170px; }
.pbar span { position: relative; height: 7px; border-radius: 4px; background: var(--line); overflow: hidden; font-size: 11px; }
.pbar span i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 4px; }
.pbar .w i { background: var(--muted); }
.pbar .r i { background: var(--s1); }
.pbar b { font-weight: 400; font-size: 12px; text-align: right; }
.hbar { display: grid; grid-template-columns: minmax(110px, 34%) 1fr 48px; gap: 10px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); font-size: 13px; }
.hbar:first-child { border-top: 0; }
.hbar .t { position: relative; height: 10px; border-radius: 5px; background: var(--line); overflow: hidden; }
.hbar .t i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 5px; background: var(--s1); }
.hbar b { text-align: right; font-weight: 400; }
@media (max-width: 760px) { .nav { overflow-x: auto; scrollbar-width: none; max-width: 100%; } .nav a { white-space: nowrap; } }
.cards.fit { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

/* ---------- proving grounds ---------- */
.lab-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px 16px; margin: 14px 0 12px; }
.lab-f { display: flex; flex-direction: column; gap: 4px; min-width: 0; font-size: 12px; color: var(--muted); }
.lab-f .inp, .lab-f .sel { width: 100%; font-size: 14px; color: var(--fg); }
.lab-f small { font-size: 11px; }
.inp.area { width: 100%; resize: vertical; font: inherit; font-size: 14px; line-height: 1.45; }
.jr { border-top: 1px solid var(--line); padding: 14px 0 6px; }
.jr:first-child { border-top: 0; padding-top: 2px; }
.jr-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; margin-bottom: 6px; font-size: 13px; }
.jr-a { border-top: 1px solid var(--line); padding: 8px 0; }
.jr-a:first-child { border-top: 0; }
.jr-a summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; cursor: pointer; font-size: 13px; }
.jr-a summary .ev-pill { align-self: center; }
.jr-t { flex: 1 1 260px; min-width: 0; }
.jr-a .mini { margin: 8px 0 4px 6px; }
.pbar.one { grid-template-columns: minmax(70px, 1fr) 46px; min-width: 130px; }
.wl td.thesis { white-space: normal; text-align: left; min-width: 240px; max-width: 420px; font-size: 13px; }
.wl.simtb tr.grp th { text-align: left; text-transform: none; letter-spacing: 0; font: 600 14px var(--sans); color: var(--fg); padding: 20px 10px 8px; white-space: normal; }
.wl.simtb tr.grp th .co { max-width: 95ch; font-weight: 400; white-space: normal; overflow: visible; margin-top: 3px; }
.wl.simtb td:first-child .co { max-width: 320px; white-space: normal; }

/* ---------- the board: the Proving Grounds scoreboard as one picture ---------- */
/* Mark colors were checked with a palette validator against the page: ahead and behind stay apart for red-green color
   blindness (and position always says the same thing), and the three list colors pass on every pairing. */
.bd { --bd-ahead: #1a9a66; --bd-behind: #dd5327; --bd-flat: #5d6676; --bd-l1: #2a78d6; --bd-l2: #eb6834; --bd-l3: #1baf7a; --bd-ink: #0b0f17; --bd-on-flat: #fff; --bd-on-l1: #fff; --bd-wash: .06; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.bd .c-ahead { --c: var(--bd-ahead); --on: var(--bd-ink); } .bd .c-behind { --c: var(--bd-behind); --on: var(--bd-ink); } .bd .c-flat { --c: var(--bd-flat); --on: var(--bd-on-flat); }
.bd .c-l1 { --c: var(--bd-l1); --on: var(--bd-on-l1); } .bd .c-l2 { --c: var(--bd-l2); --on: var(--bd-ink); } .bd .c-l3 { --c: var(--bd-l3); --on: var(--bd-ink); } .bd .c-rand { --c: var(--muted); }
.bd-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.bd-hero { display: grid; grid-template-columns: minmax(250px, 1.5fr) repeat(5, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.bd-tile { background: var(--panel); padding: 12px 14px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.bd-tile span { font-size: 11px; color: var(--muted); letter-spacing: .04em; }
.bd-tile b { font: 600 17px/1.25 var(--sans); overflow-wrap: anywhere; }
.bd-tile small { font-size: 11px; color: var(--muted); }
.bd-tile.big b { font: 600 clamp(38px, 4.4vw, 52px)/1.05 var(--sans); letter-spacing: -.02em; }
.bd-strip { display: flex; flex-wrap: wrap; gap: 3px; margin: 8px 0 4px; }
.bd-strip i { width: 9px; height: 9px; border-radius: 2px; background: var(--c); }
.bd-meter { height: 6px; border-radius: 3px; background: var(--line); margin-top: 6px; overflow: hidden; }
.bd-meter i { display: block; height: 100%; border-radius: 3px; background: var(--accent); }
@media (max-width: 1180px) { .bd-hero { grid-template-columns: repeat(3, minmax(0, 1fr)); } .bd-tile.big { grid-column: 1 / -1; } .bd-tile:last-child { grid-column: span 2; } }
@media (max-width: 560px) { .bd-hero { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.bd-bar { display: flex; flex-direction: column; gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.bd-barrow { display: flex; flex-wrap: wrap; gap: 10px 24px; align-items: center; }
.bd-ctl { display: flex; align-items: center; gap: 8px; min-width: 0; max-width: 100%; }
.bd-k { font-size: 11px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); min-width: 46px; flex: none; }
.bd .bd-chips { gap: 5px; align-items: center; min-width: 0; }
.bd .bd-chips .chip { padding: 4px 10px; font-size: 12.5px; white-space: nowrap; }
.bd-sep { width: 1px; height: 18px; background: var(--line); margin: 0 4px; flex: none; }
.bd .seg { flex-wrap: wrap; }
.bd .seg button { font: 500 12.5px var(--sans); padding: 6px 11px; }
.bd .sel { padding: 5px 8px; font-size: 12.5px; }
.bd-lead { margin: 2px 2px 0; max-width: 115ch; font-size: 15px; }
.bd-main { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; align-items: start; }
.bd-panel { padding: 12px 12px 14px; }
.bd-stage { position: relative; overflow: hidden; min-height: 300px; }
.bd-svg { display: block; touch-action: pan-y; }
.bd-svg text { user-select: none; -webkit-user-select: none; }
.bd-side { position: sticky; top: 76px; max-height: calc(100vh - 96px); overflow-y: auto; }
@media (max-width: 1120px) { .bd-main { grid-template-columns: minmax(0, 1fr); } .bd-side { position: static; max-height: none; } }
.bd > *, .bd-bar > *, .bd-main > * { min-width: 0; }
@media (max-width: 640px) { .bd .bd-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; max-width: 100%; padding-bottom: 2px; } .bd .bd-chips > * { flex: none; } .bd-ctl { align-items: stretch; flex-direction: column; gap: 5px; flex: 1 1 100%; } .bd-ctl .seg { align-self: flex-start; } .bd-barrow { gap: 10px 16px; } .bd-lead { font-size: 14px; } .bd-rl { font-size: 11.5px; } }
.bd-grid { stroke: var(--line); stroke-width: 1; shape-rendering: crispEdges; }
.bd-grid.day { stroke: color-mix(in srgb, var(--muted) 40%, var(--line)); }
.bd-zero { stroke: var(--muted); stroke-width: 1.25; }
.bd-mkt { stroke: var(--fg); stroke-width: 1.5; }
.bd-mk { fill: none; stroke: var(--fg); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.bd-cap { font: 11px var(--sans); fill: var(--muted); }
.bd-cap.strong { fill: var(--fg); font-weight: 500; }
.bd-cap.halo { paint-order: stroke; stroke: var(--panel); stroke-width: 3px; stroke-linejoin: round; }
.bd .ax.dimmer { opacity: .7; font-size: 10px; }
.bd-rl { font: 500 12.5px var(--sans); fill: var(--fg); }
.bd-rl.soft { font-weight: 400; fill: var(--muted); }
.bd-row { fill: transparent; }
.bd-row.hot { fill: var(--panel-2); }
.bd-band { fill: var(--muted); fill-opacity: .1; }
.bd-spread { stroke: color-mix(in srgb, var(--muted) 28%, var(--panel)); stroke-width: 6; stroke-linecap: round; }
.bd-mean { stroke: var(--fg); stroke-width: 2; stroke-linecap: round; }
.bd-wash.up { fill: var(--bd-ahead); fill-opacity: var(--bd-wash); }
.bd-wash.down { fill: var(--bd-behind); fill-opacity: var(--bd-wash); }
.bd-ring { fill: var(--panel); stroke: var(--fg); stroke-width: 2; }
.bd-link { fill: var(--muted); fill-opacity: .05; stroke: var(--muted); stroke-opacity: .32; stroke-width: 1; stroke-linejoin: round; transition: opacity .2s; }
.bd-link.hot { fill-opacity: .13; stroke-opacity: .95; stroke-width: 1.5; }
.bd-link.dim { opacity: .25; }
.bd-nm { font: 11px var(--sans); fill: var(--fg); paint-order: stroke; stroke: var(--panel); stroke-width: 3px; stroke-linejoin: round; transition: opacity .2s; }
.bd-nm.dim { opacity: .18; }
.bd-nm.hot { font-weight: 600; }
.bd-leader { stroke: var(--muted); stroke-opacity: .5; stroke-width: 1; }
.bd-leader.dim { opacity: .12; }
.bd-cross { stroke: var(--muted); stroke-width: 1; }
.bd-m { cursor: pointer; outline: none; }
.bd-m .sh { fill: var(--c); stroke: var(--panel); stroke-width: 2px; paint-order: stroke; transition: fill .35s, opacity .2s; }
.bd-m .dg { font: 600 10.5px var(--mono); fill: var(--on); pointer-events: none; transition: opacity .2s; }
.bd-m.k-rand .sh { stroke: none; fill-opacity: .6; }
.bd-m.dim .sh, .bd-m.dim .dg { opacity: .15; }
.bd-m.hot .sh, .bd-m.pin .sh { stroke: var(--fg); }
.bd-m.pin .sh { stroke-width: 3px; }
.bd-m:focus-visible .sh { stroke: var(--accent); stroke-width: 3px; }
.bd-ln { fill: none; stroke: var(--c); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; opacity: .6; transition: opacity .2s; }
.bd-ln.k-rule { stroke: var(--bd-flat); stroke-dasharray: 5 4; }
.bd-ln.hot { opacity: 1; stroke-width: 2.25; }
.bd-ln.top { stroke-width: 3; }
.bd-ln.dim { opacity: .08; }
.bd-trade { fill: var(--fg); stroke: var(--panel); stroke-width: 1; opacity: .75; transition: opacity .2s; }
.bd-trade.dim { opacity: .06; }
.bd-cell { fill: var(--s1); cursor: pointer; transition: opacity .2s; }
.bd-cell.cash { fill: var(--muted); }
.bd-cell.up { fill: var(--bd-ahead); }
.bd-cell.down { fill: var(--bd-behind); }
.bd-cell.flat { fill: var(--bd-flat); }
.bd-cell.dim { opacity: .3; }
.bd-col { fill: transparent; }
.bd-col.hot { fill: var(--accent-soft); }
.bd-ct { font: 11px var(--mono); fill: var(--muted); }
.bd-ct.hot, a:hover > .bd-ct { fill: var(--fg); font-weight: 600; }
.bd .bd-tip { max-width: 300px; min-width: 210px; display: flex; flex-direction: column; gap: 2px; }
.bd .bd-tip[hidden] { display: none; }
.bd-tip small { color: var(--muted); font-size: 11px; }
.bd-kv { display: flex; justify-content: space-between; gap: 16px; align-items: baseline; font-size: 12.5px; padding: 1px 0; }
.bd-kv span { color: var(--muted); }
.bd .bd-kv b { font-weight: 500; display: inline; margin: 0; white-space: nowrap; }
.bd-kv.on span { color: var(--fg); font-weight: 600; }
.bd .bd-kv.on b { font-weight: 600; }
.bd-time { display: flex; align-items: center; gap: 10px; padding: 10px 4px 2px; flex-wrap: wrap; }
.bd-time[hidden], .bd-time [hidden] { display: none; }
.bd-range { flex: 1 1 200px; min-width: 120px; accent-color: var(--accent); }
.bd-stamp { font-size: 12px; color: var(--muted); }
.bd-play { min-width: 66px; }
.bd .bd-legend { padding: 10px 4px 0; gap: 6px 16px; align-items: center; }
.bd .bd-sw { width: 11px; height: 11px; display: inline-block; margin-right: 6px; vertical-align: -1px; background: var(--c); border-radius: 50%; flex: none; }
.bd .bd-sw.k-rule.p-equal { border-radius: 1px; transform: rotate(45deg) scale(.82); }
.bd .bd-sw.k-rule.p-momentum { border-radius: 0; background: none; width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-bottom: 11px solid var(--c); }
.bd .bd-sw.k-rand { width: 7px; height: 7px; opacity: .6; vertical-align: 1px; }
.bd .bd-sw.band { border-radius: 2px; width: 22px; background: color-mix(in srgb, var(--muted) 24%, transparent); }
.bd .bd-sw.cellk { border-radius: 2px; background: var(--s1); }
.bd .bd-sw.cellk.up { background: var(--bd-ahead); }
.bd .bd-sw.cellk.down { background: var(--bd-behind); }
.bd .bd-sw.meank { width: 2px; height: 14px; border-radius: 1px; background: var(--fg); vertical-align: -3px; margin: 0 9px 0 4px; }
.bd-side .h2.gap { margin-top: 16px; margin-bottom: 6px; }
.bd-help { margin: 6px 0 0; font-size: 13px; }
.bd-li { display: grid; grid-template-columns: 16px 1fr auto; gap: 8px; align-items: center; width: 100%; padding: 7px 4px; border: 0; border-top: 1px solid var(--line); background: none; text-align: left; cursor: pointer; font-size: 13px; }
.bd-li:first-child { border-top: 0; }
.bd-li:hover { background: var(--panel-2); }
.bd-li b { font-weight: 500; }
.bd-dh { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.bd-dn { font-size: 19px; font-weight: 600; margin: 2px 0 0; }
.bd-figs { margin: 12px 0 4px; border-top: 1px solid var(--line); }
.bd-figs .bd-kv { padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.bd-spark svg { display: block; width: 100%; height: 54px; margin-top: 10px; }
.bd-spark path, .bd-spark line { vector-effect: non-scaling-stroke; }
.bd-cap2 { font-size: 11px; color: var(--muted); margin: 4px 0 0; }
.bd-hb { display: grid; grid-template-columns: 52px 1fr 46px 52px; gap: 8px; align-items: center; padding: 5px 0; border-top: 1px solid var(--line); font-size: 12.5px; }
.bd-hb:first-child { border-top: 0; }
.bd-hb .t { height: 7px; border-radius: 4px; background: var(--line); overflow: hidden; }
.bd-hb .t i { display: block; height: 100%; border-radius: 4px; background: var(--s1); }
.bd-hb .t i.cash { background: var(--muted); }
.bd-hb b { font-weight: 400; text-align: right; }
.bd-tr { display: grid; grid-template-columns: 1fr auto; gap: 1px 10px; padding: 6px 0; border-top: 1px solid var(--line); font-size: 12.5px; }
.bd-tr:first-child { border-top: 0; }
.bd-tr b { font-weight: 500; text-align: right; }
.bd-tr .muted { font-size: 11px; }
.bd-tr .muted:last-child { text-align: right; }
.bd-view { font-size: 13px; margin: 0; }
.bd-syms { display: flex; flex-wrap: wrap; gap: 2px; margin: 6px 0 0; }


/* ---------- design refresh: clearer hierarchy, calmer surfaces, controls that look pressable ---------- */
body { font: 14px/1.5 var(--sans); font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
.h1 { font-family: var(--head); font-weight: 600; letter-spacing: -.02em; font-size: clamp(25px, 3vw, 33px); line-height: 1.15; }
.h2 { font: 600 15px/1.3 var(--sans); letter-spacing: -.005em; text-transform: none; color: var(--fg); }
.sub { font-size: 14px; line-height: 1.55; max-width: 84ch; }
.panel { padding: 18px 20px; box-shadow: var(--shadow); }
.panel-h { margin-bottom: 10px; }
.top { background: color-mix(in srgb, var(--panel) 88%, transparent); }
.nav { gap: 2px; }
.nav a { padding: 7px 12px; border-radius: 8px; transition: background .12s, color .12s; }
.nav a:hover { background: var(--panel-2); }
.nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); box-shadow: none; font-weight: 600; }
.search input, .inp, .sel { border-radius: 8px; padding: 8px 11px; transition: border-color .12s, box-shadow .12s; }
.search input:focus, .inp:focus, .sel:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
.btn { border-radius: 8px; padding: 8px 14px; box-shadow: 0 1px 1px rgba(15, 20, 26, .04); transition: background .12s, border-color .12s, transform .06s; }
.btn:hover { background: var(--panel-2); }
.btn:active { transform: translateY(1px); }
.btn.pri { color: var(--accent-ink); font-weight: 600; }
.btn.pri:hover { background: color-mix(in srgb, var(--accent) 86%, var(--fg)); border-color: transparent; }
.btn.sm { padding: 5px 10px; font-size: 12.5px; }
.btn[aria-pressed="true"] { background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 45%, transparent); color: var(--accent); }
.seg { background: var(--panel-2); padding: 2px; gap: 2px; border-radius: 9px; overflow: visible; }
.seg button { border-radius: 7px; padding: 5px 11px; font: 500 13px var(--sans); transition: background .12s, color .12s; }
.seg button[aria-pressed="true"] { background: var(--seg-on); color: var(--fg); box-shadow: 0 1px 2px rgba(15, 20, 26, .16), 0 0 0 1px var(--line); }
.chip { background: var(--panel); transition: background .12s, border-color .12s, color .12s; }
.chip:hover { background: var(--panel-2); border-color: var(--line); }
.chip[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); font-weight: 600; }
.wl th { text-transform: none; letter-spacing: 0; font-size: 12px; font-weight: 600; padding: 10px 12px; }
.wl td { padding: 12px; }
.wl .sym, .row b, .sr b, .ev-s, .al-rule b, .al-hit b, .earn-c b, .badge { font-family: var(--sans); font-weight: 600; letter-spacing: .01em; }
.stat b { font: 600 19px/1.25 var(--sans); }
.stat span { font-size: 12px; letter-spacing: 0; }
.tile, .stats, .bd-hero, .bd-bar { box-shadow: var(--shadow); }
.tile-p { font: 600 18px var(--sans); }
.tab { font-size: 14px; padding: 10px 14px; }
.ev-pill { border: 0; background: var(--panel-2); padding: 2px 9px; }
.ev-pill.strong, .ev-pill.pos { background: color-mix(in srgb, var(--up) 13%, transparent); }
.ev-pill.neg { background: color-mix(in srgb, var(--down) 12%, transparent); }
.ev-pill.some { background: color-mix(in srgb, var(--s2) 15%, transparent); }
.co-px .p { font: 600 clamp(30px, 5vw, 44px)/1 var(--head); font-variant-numeric: normal; letter-spacing: -.02em; }
.co-sym { font-family: var(--sans); letter-spacing: .06em; }
.lead { line-height: 1.55; }
.search-results, .tip, .toast { box-shadow: var(--pop); }
.bd-tile.big b { font-family: var(--head); font-variant-numeric: normal; }
.bd-dn { font-family: var(--head); }

/* ---------- the scoreboard table ---------- */
.viewsw { display: inline-flex; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; gap: 2px; flex: none; }
.viewsw a { padding: 7px 18px; border-radius: 7px; font-weight: 500; color: var(--muted); transition: background .12s, color .12s; }
.viewsw a:hover { color: var(--fg); }
.viewsw a[aria-current="page"] { background: var(--seg-on); color: var(--fg); font-weight: 600; box-shadow: 0 1px 2px rgba(15, 20, 26, .16), 0 0 0 1px var(--line); }
.panel.sb { padding: 0; }
.sb-bar { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px 10px; }
.sb-row { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; }
.sb-popwrap { position: relative; display: inline-flex; }
.sb-grow { flex: 1 1 0; }
.sb-lbl { font-size: 12px; font-weight: 600; color: var(--muted); }
.sb-search { flex: 1 1 260px; max-width: 340px; width: auto; padding-left: 34px; background-repeat: no-repeat; background-position: 11px 50%; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='%238a94a3' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.6-3.6'/%3E%3C/svg%3E"); }
.sb .chips { gap: 5px; align-items: center; }
.sb .chip { padding: 5px 11px; font-size: 12.5px; white-space: nowrap; }
.sb .sel { padding: 7px 9px; font-size: 13px; }
.sb-btn { display: inline-flex; align-items: center; gap: 6px; }
.sb-chev { font-style: normal; font-size: 10px; color: var(--muted); }
.sb-badge { display: inline-block; min-width: 17px; padding: 0 5px; margin-left: 6px; border-radius: 9px; background: var(--accent); color: var(--accent-ink); font: 600 11px/17px var(--sans); text-align: center; }
.sb-pop { position: absolute; z-index: 30; top: calc(100% + 6px); left: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--pop); padding: 10px; width: max-content; min-width: 280px; max-width: min(720px, calc(100vw - 40px)); max-height: min(70vh, 640px); overflow: auto; }
.sb-pop.right { left: auto; right: 0; }
.sb-opt { display: flex; gap: 9px; align-items: flex-start; padding: 6px; border-radius: 7px; cursor: pointer; font-size: 13px; font-weight: 500; }
.sb-opt:hover { background: var(--panel-2); }
.sb-opt small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 400; line-height: 1.35; max-width: 300px; }
.sb-opt input { margin: 3px 0 0; accent-color: var(--accent); flex: none; }
.sb-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 12px; }
.sb-gh { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 10px 6px 3px; }
.sb-gh:first-child { margin-top: 2px; }
.sb-popf { display: flex; gap: 8px; justify-content: flex-end; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.sb-act:not(:empty) { padding: 0 16px 12px; }
.sb-meta { margin: 0; padding: 0 16px 10px; font-size: 12.5px; color: var(--muted); }
.sb-meta b { color: var(--fg); font-weight: 600; }
.sb-note { color: var(--s2); font-weight: 500; }
.sb-scroll { overflow: auto; max-height: min(76vh, 1040px); border-top: 1px solid var(--line); border-radius: 0 0 var(--r) var(--r); }
.sb-t { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 13.5px; }
.sb-t th { position: sticky; top: 0; z-index: 3; background: var(--panel-2); border-bottom: 1px solid var(--line); padding: 0; text-align: left; white-space: nowrap; font-weight: 600; }
.sb-t th.r { text-align: right; }
.sb-th { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 5px; width: 100%; padding: 10px 12px; cursor: pointer; font-size: 12px; font-weight: 600; color: var(--muted); position: relative; }
th.r .sb-th { justify-content: flex-end; }
.sb-th:hover, th.on .sb-th { color: var(--fg); }
.sb-th:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: 4px; }
.sb-car { font-style: normal; font-size: 9px; opacity: .4; }
th.on .sb-car { opacity: 1; color: var(--accent); }
.sb-t td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; white-space: nowrap; background: var(--panel); transition: background .1s; }
.sb-t td.r { text-align: right; }
.sb-t td.wrap { white-space: normal; }
.sb-t td.on { background: color-mix(in srgb, var(--accent-soft) 42%, var(--panel)); }
.sb-t tr.sb-r.k-ai, .sb-t tr.sb-r.k-rule { cursor: pointer; }
.sb-t tbody tr.sb-r:hover td { background: var(--panel-2); }
.sb-t th:first-child, .sb-t td:first-child { position: sticky; left: 0; z-index: 2; box-shadow: 1px 0 0 var(--line); }
.sb-t th:first-child { z-index: 4; }
.sb-t.dense td { padding: 5px 12px; }
.sb-t.dense .sb-sub { display: none; }
.sb-t.dense .sb-mk { width: 18px; height: 18px; }
.sb-t .num.muted, .sb-t .muted { color: var(--muted); }
.sb-name { display: flex; align-items: center; gap: 10px; min-width: 216px; }
.sb-nm { font-weight: 600; display: block; }
a.sb-nm:hover { text-decoration: underline; text-underline-offset: 3px; }
.sb-sub { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-top: 1px; }
.sb-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); flex: none; display: inline-block; }
.sb-dot.on { background: var(--up); }
.sb-dot.hold, .sb-dot.wait { background: var(--s2); }
.sb-dot.busy { background: var(--s1); }
.sb-dot.off { background: color-mix(in srgb, var(--muted) 45%, transparent); }
@media (prefers-reduced-motion: no-preference) { .sb-dot.busy { animation: sbpulse 1.4s ease-in-out infinite; } @keyframes sbpulse { 50% { opacity: .3; } } }
.sb-state { display: inline-flex; align-items: center; gap: 7px; }
.sb-mk { width: 24px; height: 24px; flex: none; }
.sb-mk .sh { fill: var(--fg); }
.sb-mk.k-rule .sh, .sb-mk.k-rand .sh { fill: var(--muted); }
.sb-mk.k-bench .sh { fill: none; stroke: var(--fg); stroke-width: 2.5; }
.sb-mk text { font: 600 11.5px var(--sans); fill: var(--panel); }
.sb-t tr.k-bench td { background: var(--panel-2); }
.sb-t tr.k-bench .sb-nm { font-weight: 700; }
.sb-t tr.sb-g td { background: var(--panel-2); color: var(--muted); font-size: 12.5px; padding-top: 7px; padding-bottom: 7px; }
.sb-gl { all: unset; display: flex; align-items: center; gap: 8px; cursor: pointer; color: var(--fg); font-weight: 600; font-size: 13.5px; }
.sb-gl small { font-weight: 500; color: var(--muted); background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 0 7px; font-size: 11px; }
.sb-gl:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.sb-tog { font-style: normal; width: 12px; color: var(--muted); }
.sb-t tfoot td { position: sticky; bottom: 0; z-index: 2; background: var(--panel-2); border-top: 1px solid var(--line); border-bottom: 0; font-weight: 600; box-shadow: 0 -1px 0 var(--line); }
.sb-t tfoot td:first-child { z-index: 3; }
.sb-avg { font-size: 12px; font-weight: 500; color: var(--muted); }
.tks { display: flex; flex-wrap: wrap; gap: 4px; width: max-content; max-width: 430px; min-width: 190px; }
.tk { display: inline-flex; align-items: baseline; gap: 5px; padding: 1px 7px; border-radius: 6px; background: var(--panel-2); border: 1px solid var(--line); font-size: 12px; line-height: 1.6; color: var(--fg); transition: border-color .12s; }
a.tk:hover { border-color: var(--muted); }
.tk b { font-weight: 600; letter-spacing: .01em; }
.tk i { font-style: normal; font-size: 11px; color: var(--muted); }
.tk.fund { background: color-mix(in srgb, var(--s1) 9%, var(--panel)); border-color: color-mix(in srgb, var(--s1) 24%, var(--line)); }
.tk.cash { background: none; border-style: dashed; color: var(--muted); }
.tk.cash b { font-weight: 500; }
.tk.more { cursor: pointer; font-family: inherit; color: var(--muted); background: none; }
.tk.more:hover { color: var(--fg); border-color: var(--muted); }
.sb-hold { display: inline-flex; gap: 7px; align-items: baseline; }
.tk-s { font-weight: 600; }
.tk-s:hover { text-decoration: underline; text-underline-offset: 3px; }
.sb-db { display: inline-flex; align-items: center; justify-content: flex-end; gap: 8px; }
.sb-dbar { display: inline-block; position: relative; width: 46px; height: 6px; border-radius: 3px; background: var(--line); flex: none; }
.sb-dbar::before { content: ""; position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1px; background: var(--muted); }
.sb-dbar i { position: absolute; top: 0; bottom: 0; border-radius: 3px; }
.sb-dbar i.up { background: var(--up); left: 50%; }
.sb-dbar i.down { background: var(--down); right: 50%; }
.sb-meter { display: inline-block; width: 44px; height: 6px; border-radius: 3px; background: var(--line); vertical-align: middle; overflow: hidden; flex: none; }
.sb-meter i { display: block; height: 100%; background: var(--s1); border-radius: 3px; }
.sb-luck { display: inline-flex; align-items: center; gap: 2px; }
.sb-luck small { color: var(--muted); font-size: 11.5px; margin-right: 8px; }
.sb-inv { display: inline-flex; align-items: center; gap: 8px; }
.sb-spark { width: 92px; height: 26px; display: block; }
.sb-spark .a { fill: none; stroke: var(--fg); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.sb-spark .m { fill: none; stroke: var(--muted); stroke-width: 1.2; opacity: .6; stroke-linejoin: round; }
.sb-spark .z { stroke: var(--line); stroke-width: 1; }
.sb-spark .e { fill: var(--fg); stroke: var(--panel); stroke-width: 1.5; }
.sb-empty { padding: 44px 16px; text-align: center; color: var(--muted); }
.sb-empty b { display: block; color: var(--fg); font: 600 16px var(--head); margin-bottom: 4px; }
.sb-empty p { margin: 0 0 12px; }
.sb-new > summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; cursor: pointer; list-style: none; }
.sb-new > summary::-webkit-details-marker { display: none; }
.sb-new > summary::before { content: "+"; font: 600 18px/1 var(--sans); color: var(--accent); width: 14px; }
.sb-new[open] > summary::before { content: "−"; }
.sb-new > summary .sub { margin: 0; }
.sb-new[open] > summary { margin-bottom: 12px; }
@media (max-width: 640px) { .sb-name { min-width: 168px; } .sb-search { max-width: none; flex-basis: 100%; } .sb-grow { display: none; } .sb-cols { grid-template-columns: minmax(0, 1fr); } .sb-pop { max-width: calc(100vw - 32px); } .viewsw a { padding: 7px 14px; } .panel { padding: 14px; } }

/* One page width everywhere, as on app.nvestra.ai: every screen fills from the menu's edge up to 1760px, so the margins
   are the same 24px on every page and on any monitor (the Board, Radar and the scoreboard used to be the only wide ones). */
body .top-in, body .view, body .foot { max-width: 1760px; }
.bd-hero.five { grid-template-columns: minmax(250px, 1.5fr) repeat(4, minmax(0, 1fr)); }
@media (max-width: 1180px) { .bd-hero.five { grid-template-columns: repeat(4, minmax(0, 1fr)); } .bd-hero.five .bd-tile:last-child { grid-column: auto; } }
@media (max-width: 560px) { .bd-hero.five { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tks { max-width: 372px; }
.sb-name { min-width: 204px; }

/* Figure grids: cells draw their own dividing lines, so a short last row leaves clean space, not a grey block. */
.stats, .bd-hero { background: var(--panel); gap: 0; }
.stat, .bd-tile { box-shadow: 1px 0 0 var(--line), 0 1px 0 var(--line); }
.tks { max-width: 336px; }
.sb-t td, .sb-th { padding-left: 11px; padding-right: 11px; }
@media (max-width: 640px) { .sb-name { min-width: 148px; gap: 8px; } .sb-nm { white-space: normal; } .sb-t td, .sb-th { padding-left: 9px; padding-right: 9px; } .sb-mk { width: 20px; height: 20px; } }


/* ---------- pieces every screen shares ---------- */
.pg-h { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.pg-h .sub { margin-top: 6px; }
.pg-side { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.help { all: unset; box-sizing: border-box; display: inline-grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; border: 1px solid color-mix(in srgb, var(--muted) 55%, transparent); color: var(--muted); font: 600 10px/1 var(--sans); cursor: help; position: relative; vertical-align: 1px; margin-left: 6px; flex: none; }
.help:hover, .help:focus-visible { color: var(--fg); border-color: var(--fg); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.kpis:empty { display: none; }
.kpi { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.kpi > span { font-size: 12px; color: var(--muted); font-weight: 500; display: flex; align-items: center; }
.kpi > b { font: 600 22px/1.2 var(--head); letter-spacing: -.01em; font-variant-numeric: normal; overflow-wrap: anywhere; }
.kpi > small { font-size: 12px; color: var(--muted); }
.chg { display: inline-block; padding: 1px 7px; border-radius: 6px; font-weight: 600; font-size: 12.5px; background: var(--panel-2); color: var(--muted); white-space: nowrap; }
.chg.up { background: color-mix(in srgb, var(--up) 12%, transparent); color: var(--up); }
.chg.down { background: color-mix(in srgb, var(--down) 11%, transparent); color: var(--down); }
.empty { padding: 34px 16px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--fg); font: 600 16px var(--head); margin-bottom: 4px; }
.empty p { margin: 0 auto 12px; max-width: 46ch; }
.panel.flush { padding: 0; overflow: hidden; }
.panel-h.pad { padding: 16px 20px 0; }
.panel.flush .wl th:first-child, .panel.flush .wl td:first-child { padding-left: 20px; }
.panel.flush .wl th:last-child, .panel.flush .wl td:last-child { padding-right: 20px; }
.panel.flush .wl tr:last-child td { border-bottom: 0; }
.wl.hov tbody tr { cursor: pointer; }
.wl th button:not(.help) { display: inline-flex; align-items: center; gap: 5px; }
.wl th .car::after { content: "↕"; font-style: normal; font-size: 9px; opacity: .4; }
.wl th[aria-sort="ascending"] .car::after { content: "▲"; opacity: 1; color: var(--accent); }
.wl th[aria-sort="descending"] .car::after { content: "▼"; opacity: 1; color: var(--accent); }
.xbtn { all: unset; box-sizing: border-box; width: 26px; height: 26px; display: inline-grid; place-items: center; border-radius: 7px; color: var(--muted); font-size: 17px; line-height: 1; cursor: pointer; opacity: .55; transition: background .12s, color .12s, opacity .12s; }
tr:hover .xbtn, .xbtn:focus-visible { opacity: 1; }
.xbtn:hover { background: color-mix(in srgb, var(--down) 12%, transparent); color: var(--down); }
.xbtn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.row { grid-template-columns: 64px 1fr auto 74px; border-radius: 6px; }
.row .chg { justify-self: end; }

/* ---------- market overview ---------- */
.mk-lead { margin: 0; max-width: 110ch; font-size: 16px; }
.mk-idx { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.mk-tile { display: flex; flex-direction: column; gap: 6px; padding: 14px 14px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); min-width: 0; transition: border-color .12s, transform .12s; }
.mk-tile:hover { border-color: var(--muted); transform: translateY(-1px); }
.mk-n { font-size: 12.5px; font-weight: 500; color: var(--muted); }
.mk-p { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.mk-p b { font: 600 24px/1.1 var(--head); letter-spacing: -.01em; font-variant-numeric: normal; }
.mk-tile svg { width: 100%; height: 46px; display: block; margin-top: 2px; }
.mk-rows { display: flex; flex-direction: column; }
.mk-row { display: grid; grid-template-columns: minmax(0, 1fr) 76px auto 74px; gap: 12px; align-items: center; padding: 9px 6px; border-top: 1px solid var(--line); border-radius: 6px; }
.mk-row:first-child { border-top: 0; }
.mk-row:hover { background: var(--panel-2); }
.mk-rn b { display: block; font-weight: 600; }
.mk-rn small { display: block; font-size: 11.5px; color: var(--muted); line-height: 1.35; }
.mk-row svg { width: 76px; height: 26px; display: block; }
.mk-row .chg { justify-self: end; }
.secs { display: flex; flex-direction: column; gap: 1px; }
.sec { display: grid; grid-template-columns: minmax(min(172px, 46%), 34%) 1fr 64px; gap: 12px; align-items: center; padding: 6px; border-radius: 6px; }
.sec:hover { background: var(--panel-2); }
.sec-n { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sec-t { position: relative; height: 10px; }
.sec-t::before { content: ""; position: absolute; left: 50%; top: -4px; bottom: -4px; width: 1px; background: var(--line); }
.sec-t i { position: absolute; top: 0; bottom: 0; border-radius: 3px; min-width: 2px; }
.sec-t i.up { left: 50%; background: var(--up); }
.sec-t i.down { right: 50%; background: var(--down); }
.sec b { text-align: right; font-weight: 600; }
@media (max-width: 560px) { .mk-row { grid-template-columns: minmax(0, 1fr) auto 70px; } .mk-row svg { display: none; } .sec { grid-template-columns: minmax(100px, 40%) 1fr 58px; } }
.mk-idx { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mk-tile svg { height: 54px; }


/* ---------- company page ---------- */
.co-px { align-items: center; }
.co-px .c { font: 600 14px var(--sans); padding: 3px 9px; border-radius: 7px; background: var(--panel-2); white-space: pre; }
.co-px .c.up { background: color-mix(in srgb, var(--up) 12%, transparent); }
.co-px .c.down { background: color-mix(in srgb, var(--down) 11%, transparent); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; align-items: start; }
.facts-c { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px 18px 6px; min-width: 0; }
.facts-c h3 { margin: 0; font: 600 15px/1.3 var(--sans); }
.facts-c > p { margin: 2px 0 8px; font-size: 12.5px; color: var(--muted); }
.facts-c dl { margin: 0; }
/* Four groups on a wide page (row 26): three columns, the two short groups (cash and debt, trading) stacked in the
   third, so the cards end nearly level instead of leaving a ragged gap under the short ones. */
@media (min-width: 901px) {
  .view:not(.narrow) .facts:has(> .facts-c:nth-child(4)) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .view:not(.narrow) .facts:has(> .facts-c:nth-child(4)) > .facts-c:nth-child(-n+2) { grid-row: span 2; }
}
.co-note:empty { display: none; }
.fact { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); }
.fact dt { font-size: 13px; min-width: 0; }
.fact dt > span { display: inline-flex; align-items: center; }
.fact dt small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.fact dd { margin: 0; font-weight: 600; font-size: 15px; white-space: nowrap; }
.filing { border-radius: 6px; }
.chart-leg { font-family: var(--sans); }

/* ---------- alerts and signals ---------- */
.al-say { font-weight: 600; }
.al-rule { grid-template-columns: 64px 1fr auto auto; border-radius: 6px; }
.al-rule .btn.sm[aria-pressed="false"] { color: var(--muted); }
.earn-c { border-radius: 10px; transition: border-color .12s, transform .12s; }
.earn-c:hover { transform: translateY(-1px); }
.ev { border-radius: 6px; }
.ev-day { font-size: 12px; letter-spacing: 0; text-transform: none; color: var(--fg); border-bottom-color: var(--line); }
.setup li { padding-left: 24px; }
.pbar .r i { background: var(--s2); }
.wl.tb td:first-child a:hover .sym { text-decoration: underline; text-underline-offset: 3px; }
.pf-row { grid-template-columns: minmax(64px, 110px) 1fr 28px; }
.pf-holdings { display: grid; gap: 12px; }
.pf-holdings > * { min-width: 0; }
.pf-holdings > .panel-h { margin-bottom: 0; flex-wrap: wrap; }
.pf-toolbar, .pf-actions { display: flex; gap: 8px; align-items: center; }
.pf-toolbar { flex-wrap: wrap; position: relative; }
.pf-toolbar[hidden] { display: none; }
.pf-workspace, .pf-card-layout, .pf-risk-card { display: grid; gap: 12px; min-width: 0; }
.pf-dashboard-item { min-width: 0; }
.pf-card-layout[hidden], .pf-dashboard-item[hidden], .pf-card-layout .empty[hidden], .pf-risk-card > .eng:empty { display: none; }
.pf-cards-menu { position: absolute; z-index: 12; inset-inline-end: 0; top: calc(100% + 6px); width: min(22rem, calc(100vw - 32px)); padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); box-shadow: var(--pop); }
.pf-cards-menu[hidden] { display: none; }
.pf-cards-menu .pf-column-options { margin: 0; }
.pf-toolbar button[aria-expanded="true"] { border-color: var(--accent); color: var(--accent); }
.pf-unlock { display: grid; gap: 12px; max-width: 380px; }
.pf-remember { display: flex; align-items: center; gap: 6px; font-size: 13px; cursor: pointer; }
.pf-holdings .tblwrap, .pf-holdings .kpis { margin: 0; }
.pf-account-mix { container-type: inline-size; display: grid; gap: 6px; margin-top: 6px; }
.pf-mix-bar { display: flex; height: 8px; overflow: hidden; border-radius: 99px; }
.pf-mix-bar span { background: var(--mix-color); }
.pf-mix-bar span + span { box-shadow: inset 2px 0 var(--panel); }
.pf-mix-invested { --mix-color: var(--s1); }
.pf-mix-cash { --mix-color: var(--s2); }
.pf-account-mix-debit .pf-mix-cash { --mix-color: var(--down); }
.pf-mix-values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 8px; row-gap: 3px; margin: 0; }
.pf-mix-item dt, .pf-mix-item dt > span:first-child { display: flex; align-items: center; gap: 4px; }
.pf-mix-item dt { flex-wrap: wrap; font-size: 11px; color: var(--muted); }
.pf-mix-item i { width: 7px; height: 7px; flex: none; border-radius: 50%; background: var(--mix-color); }
.pf-mix-pct { font-size: 10px; color: var(--mix-color); font-weight: 600; }
.pf-mix-item dd { margin: 0; font-size: 11px; font-weight: 600; overflow-wrap: anywhere; }
@container (max-width: 184px) {
  .pf-mix-values { grid-template-columns: 1fr; }
  .pf-mix-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 0 6px; }
  .pf-mix-item dd { text-align: end; }
}
@container (max-width: 155px) {
  .pf-mix-item { grid-template-columns: 1fr; }
  .pf-mix-item dd { text-align: start; }
}
.pf-table th, .pf-table .num { white-space: nowrap; }
.pf-table th, .pf-table td { padding: 8px; }
.pf-actions .btn { padding: 4px 7px; }
.pf-position-view { min-width: 0; }
.pf-chart { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.pf-chart-header { padding: 12px 14px 10px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 14px; }
.pf-chart-title, .pf-chart-readouts, .pf-chart-legend { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; min-width: 0; }
.pf-chart-title .h2 { margin: 0; }
.pf-chart-title .muted { font-size: 12px; }
.pf-chart-window { font-variant-numeric: tabular-nums; }
.pf-chart-window:empty { display: none; }
.pf-chart-legend-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 8px 14px; padding: 0 14px 12px; }
.pf-chart-ranges { justify-self: end; }
.pf-chart-ranges button { padding: 5px 7px; }
.pf-chart-readouts > .btn { padding: 5px 9px; font-size: 12px; }
.pf-chart-readouts > [hidden] { display: none; }
@media (max-width: 670px) { .pf-chart-legend-row { grid-template-columns: minmax(0, 1fr); } .pf-chart-ranges { justify-self: start; } }
.pf-chart-legend { gap: 5px; }
.pf-chart-chip { display: inline-flex; align-items: center; gap: 4px; min-height: 30px; padding: 4px 7px; border-radius: 7px; border: 1px solid var(--line); background: var(--panel-2); color: var(--fg); font: inherit; font-size: 12px; cursor: pointer; }
.pf-chart-chip[aria-pressed="false"] { background: transparent; color: var(--muted); }
.pf-chart-chip[aria-pressed="false"] .pf-chart-swatch { opacity: .36; }
.pf-chart-chip:focus-visible, .pf-chart-plot:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.pf-chart-swatch { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.pf-chart-value, .pf-chart-change { white-space: nowrap; text-align: right; font-size: 11px; }
.pf-chart-value { min-width: 7ch; }
.pf-chart-change { min-width: 5.4ch; }
.pf-chart-value:empty, .pf-chart-change:empty { display: none; }
.pf-chart-frame { position: relative; border-block: 1px solid var(--line); }
.pf-chart-plot { height: clamp(280px, 35vw, 390px); min-width: 0; }
.pf-chart-state { position: absolute; inset: 0; display: grid; place-content: center; padding: 16px; text-align: center; color: var(--muted); background: var(--panel); }
.pf-chart-state[hidden] { display: none; }
.pf-trade-tip { position: absolute; z-index: 3; pointer-events: none; max-width: min(300px, calc(100% - 16px)); max-height: calc(100% - 16px); overflow: hidden; padding: 9px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); box-shadow: var(--pop); color: var(--fg); font-size: 11px; overflow-wrap: anywhere; }
.pf-trade-tip[hidden] { display: none; }
.pf-trade-tip-row + .pf-trade-tip-row { border-top: 1px solid var(--line); margin-top: 5px; padding-top: 5px; }
.pf-trade-tip-head { display: flex; align-items: center; flex-wrap: wrap; gap: 3px 6px; margin-bottom: 3px; }
.pf-trade-tip-side { border-radius: 4px; padding: 0 5px; background: color-mix(in srgb, currentColor 12%, var(--panel)); font-weight: 700; }
.pf-trade-tip-price { margin-inline-start: auto; }
.pf-chart-footer { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; padding: 9px 14px; }
.pf-chart-date { font-size: 12px; font-weight: 600; }
.pf-candle-readout { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; }
.pf-candle-readout[hidden] { display: none; }
.pf-candle-readout > span { display: inline-flex; gap: 4px; }
.pf-candle-readout b { color: var(--muted); font-weight: 500; }
.pf-chart-trade-bar { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; flex-basis: 100%; border-top: 1px solid var(--line); padding-top: 7px; }
.pf-chart-trade-bar > .btn { margin-inline-start: auto; }
.pf-chart-trades { min-width: 0; flex: 1 1 16rem; }
.pf-chart-trades > summary, .pf-trade-import > summary { cursor: pointer; font-weight: 600; }
.pf-chart-trades-list { max-height: 16rem; overflow-y: auto; list-style: none; padding: 0; margin: 4px 0; }
.pf-chart-trade { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; width: 100%; text-align: left; font: inherit; font-size: 12px; color: var(--muted); background: transparent; border: 0; border-radius: 4px; padding: 6px 4px; cursor: pointer; }
.pf-chart-trade:hover, .pf-chart-trade:focus-visible { background: var(--panel-2); }
.pf-trade-import { margin-top: 12px; }
.pf-view-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 0; }
.pf-view-bar .h2 { margin: 0; }
.pf-view-count { margin-right: auto; font-size: 12px; }
.pf-search { flex: 1 1 170px; max-width: 255px; min-width: 145px; }
.pf-view-actions, .pf-column-heading { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.pf-column-heading .sub { margin: 0; }
.pf-view-bar [aria-expanded="true"] { border-color: var(--accent); color: var(--accent); }
.pf-view-panel { padding: 12px; margin: 0 0 10px; border: 1px solid var(--line); border-radius: 8px; }
.pf-view-panel[hidden], .pf-position-scroll[hidden], .pf-view-panel .msg[hidden] { display: none; }
.pf-freeze-setting { display: grid; gap: 4px; margin-bottom: 12px; }
.pf-freeze-setting .pf-field { width: min(100%, 18rem); }
.pf-freeze-setting .sub { margin: 0; }
.pf-position-scroll .pf-table .pf-frozen { position: sticky; z-index: 1; background: var(--panel); }
.pf-position-scroll .pf-table tbody tr:hover > .pf-frozen { background: var(--panel-2); }
.pf-position-scroll .pf-table .pf-frozen-edge { box-shadow: 1px 0 var(--line), 3px 0 4px rgb(0 0 0 / .06); }
.pf-position-view .pf-table th.l, .pf-position-view .pf-table td.l { text-align: left; }
.pf-position-view .pf-table th button:focus-visible, .pf-position-scroll:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pf-trend { display: inline-flex; align-items: center; gap: 8px; border-radius: 3px; color: var(--muted); }
.pf-trend.up { color: var(--up); }
.pf-trend.down { color: var(--down); }
.pf-trend:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pf-trend:hover .num { text-decoration: underline; }
.wl .pf-trend svg { width: 106px; height: 30px; }
.wl .pf-trend-short svg { width: 150px; height: 42px; }
.pf-trend .spark-line { stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.pf-trend .spark-area { fill: currentColor; opacity: .12; }
.pf-trend .spark-end { fill: currentColor; stroke: var(--panel); stroke-width: 1; }
.pf-trend .num { min-width: 7ch; font-size: 12px; }
.pf-sort-mark { color: var(--accent); font-size: 10px; }
.pf-column-options { list-style: none; margin: 10px 0; display: grid; gap: 6px; }
.pf-column-options { grid-template-columns: minmax(0, 1fr); max-width: 28rem; max-height: min(24rem, 52vh); overflow-y: auto; scrollbar-gutter: stable; padding: 3px 6px 3px 2px; }
.pf-column-options li { display: flex; align-items: center; gap: 5px; min-width: 0; }
.pf-column-options label { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; }
.pf-column-options .btn { min-width: 30px; padding: 4px 7px; }
.pf-group-toggle { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.pf-view-panel .pf-field[hidden] { display: none; }
.pf-account-toggle { font: inherit; color: var(--accent); border: 0; background: transparent; padding: 2px 0; cursor: pointer; }
.pf-account-toggle::before { content: '▸'; margin-right: 5px; }
.pf-account-toggle[aria-expanded="true"]::before { content: '▾'; }
.pf-account-toggle:hover { text-decoration: underline; }
.pf-account-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pf-account-detail > td { padding: 8px 16px 12px; background: var(--panel-2); }
.pf-account-breakdown { width: 100%; border-collapse: collapse; }
.pf-account-breakdown th[scope="row"] { text-align: left; color: var(--fg); }
.pf-account-breakdown :is(th, td) { font-size: 12px; }
.pf-option-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pf-option-actions .btn:last-child { margin-inline-start: auto; }
.pf-account-totals th[scope="row"] { font-size: inherit; }
.pf-phone-only, .pf-swipe-hint { display: none; }
.pf-view-panel input[aria-invalid="true"] { border-color: var(--down); }
.pf-form { min-width: 0; border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px; }
.pf-form > summary { cursor: pointer; font-weight: 600; }
.pf-form .al-form, .pf-fields, .pf-form textarea { margin-top: 12px; }
.pf-tool-dialog { width: min(36rem, calc(100% - 24px)); max-width: none; max-height: calc(100dvh - 24px); padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: var(--fg); }
.pf-tool-dialog::backdrop { background: rgba(8, 12, 18, .45); }
.pf-tool-header { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.pf-tool-header .h2 { margin: 0; }
.pf-tool-body textarea { display: block; width: 100%; margin-top: 12px; }
.pf-tool-body .al-form { margin-top: 12px; }
.pf-tool-dialog .msg:not(:empty) { margin-top: 8px; }
.pf-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(155px, 100%), 1fr)); gap: 10px; }
.pf-field { display: grid; min-width: 0; gap: 4px; color: var(--muted); font-size: 12px; }
.pf-field > *, .pf-form textarea { width: 100%; min-width: 0; }
.pf-holdings .pf-quote-note, .pf-holdings .msg { margin: 0; }
.pf-holdings .msg:empty, .pf-quote-note:empty { display: none; }
@media (max-width: 640px), (max-width: 900px) and (pointer: coarse) {
  .pf-holdings { padding: 10px; }
  .pf-holdings .btn, .pf-risk-card .btn { min-height: 44px; }
  .pf-toolbar { display: grid; grid-template-columns: repeat(3, minmax(0, auto)); gap: 6px; width: 100%; }
  .pf-toolbar > .btn, .pf-toolbar > div > .btn { width: 100%; padding: 6px; line-height: 1.2; white-space: normal; }
  .pf-cards-menu { inset-inline-start: 0; inset-inline-end: auto; width: 100%; max-width: 24rem; }
  .pf-summary .kpis { gap: 8px; }
  .pf-summary .kpi { padding: 9px; }
  .pf-summary .kpi > b { font-size: clamp(14px, 4vw, 18px); }
  .pf-chart-header { padding: 10px; }
  .pf-chart-legend-row { padding: 0 10px 10px; }
  .pf-chart-legend { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(112px, 100%), 1fr)); width: 100%; }
  .pf-chart-chip { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 1px 4px; min-height: 44px; text-align: left; }
  .pf-chart-chip b { grid-column: 2 / 4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .pf-chart-chip .pf-chart-value { grid-column: 1 / 3; min-width: 0; text-align: left; }
  .pf-chart-chip .pf-chart-change { grid-column: 3; min-width: 0; }
  .pf-chart-ranges { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; }
  .pf-chart-ranges button, .pf-chart-styles button { min-height: 44px; }
  .pf-candle-readout { flex-basis: 100%; }
  .pf-chart-trade, .pf-chart-trades > summary, .pf-trade-import > summary { min-height: 44px; align-content: center; }
  .pf-chart-plot { height: 255px; }
  .pf-chart-footer { padding: 8px 10px; }
  .pf-view-count { margin: 0 0 0 auto; }
  .pf-search { flex: 1 0 100%; max-width: none; }
  .pf-view-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; gap: 5px; }
  .pf-view-actions .btn, .pf-option-actions .btn { padding-inline: 7px; font-size: 13px; white-space: normal; line-height: 1.2; }
  .pf-holdings :is(.inp, .sel), .pf-risk-card :is(.inp, .sel) { min-height: 44px; font-size: 16px; }
  .pf-column-options label, .pf-group-toggle, .pf-remember { min-height: 44px; cursor: pointer; }
  .pf-column-options input[type="checkbox"], .pf-group-toggle input, .pf-remember input { width: 18px; height: 18px; flex-shrink: 0; }
  .pf-column-options .btn { min-width: 44px; }
  .pf-position-scroll .pf-table { min-width: 100%; }
  .pf-holdings .pf-table td:first-child { min-width: 0; }
  .pf-account-totals .pf-table tr > :first-child {
    position: sticky; inset-inline-start: 0; z-index: 1; background: var(--panel); box-shadow: 1px 0 var(--line);
  }
  .pf-table .pf-ticker { white-space: nowrap; }
  .pf-account-totals .pf-table tr > :first-child { min-width: 6.5rem; max-width: 42vw; white-space: normal; overflow-wrap: anywhere; }
  .pf-account-totals .pf-table tr:hover > :first-child { background: var(--panel-2); }
  .pf-position-scroll .pf-table td, .pf-position-scroll .pf-table th { padding: 3px 8px; }
  .pf-position-scroll .pf-table th button:not(.help), .pf-position-scroll :is(.ev-s, .pf-trend, .pf-account-toggle, .xbtn) {
    display: inline-flex; align-items: center; min-height: 44px;
  }
  .pf-position-scroll .xbtn { min-width: 44px; justify-content: center; }
  .pf-position-scroll .pf-trend { gap: 4px; }
  .pf-position-scroll .pf-trend svg { width: 92px; }
  .pf-position-scroll .pf-trend-short svg { width: 114px; height: 34px; }
  .pf-phone-only, .pf-swipe-hint:not([hidden]) { display: block; }
  .pf-swipe-hint { margin: 0 0 3px; font-size: 12px; }
  .pf-form { padding-block: 2px; }
  .pf-form > summary { min-height: 44px; line-height: 44px; }
}
.seg { flex-wrap: wrap; max-width: 100%; }
.panel-h > *, .pg-h > * { min-width: 0; max-width: 100%; }
@media (max-width: 640px) { .co-px .p { font-size: 30px; } .facts { grid-template-columns: minmax(0, 1fr); } .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .kpi > b { font-size: 19px; } .mk-p b { font-size: 20px; } }
.kpi, .fact { position: relative; }
/* The index tiles grow to the height of the card beside them, so the two cards end level. */
.grid2.g64 > .panel { display: flex; flex-direction: column; }
.mk-idx { flex: 1; grid-auto-rows: 1fr; }
.mk-tile svg { flex: 1 1 46px; height: auto; min-height: 46px; }


/* ---------- the app shell: a menu down the left, the page beside it ---------- */
body { display: flex; align-items: flex-start; min-height: 100vh; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--fg); color: var(--bg); padding: 8px 12px; border-radius: 8px; font-weight: 600; }
.skip:focus { left: 8px; }
.ic { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.side { position: sticky; top: 0; height: 100vh; height: 100dvh; width: 244px; flex: none; display: flex; flex-direction: column; gap: 18px; padding: 16px 12px 12px; background: var(--panel); border-right: 1px solid var(--line); z-index: 40; transition: width .2s ease; }
.side-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 2px 0 2px 8px; min-height: 36px; }
.side-btn { all: unset; box-sizing: border-box; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 8px; color: var(--muted); cursor: pointer; flex: none; transition: background .12s, color .12s; }
.side-btn:hover { background: var(--panel-2); color: var(--fg); }
.side-btn:focus-visible, :is(.side-nav > a, .side-sub > a):focus-visible, .side-item:focus-visible, .side-menu [role="menuitem"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.side-btn .chev { transform-box: fill-box; transform-origin: center; transition: transform .2s; }
.side-nav { display: flex; flex-direction: column; gap: 3px; flex: 1; min-height: 0; }
/* The menu's own links only: the now-playing controls under Radio carry links of their own styling. */
.side-nav > a, .side-sub > a, .side-item { all: unset; box-sizing: border-box; position: relative; display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 10px; border-radius: 9px; color: var(--muted); font-weight: 500; font-size: 14px; cursor: pointer; white-space: nowrap; transition: background .12s, color .12s; }
.side-nav > a:hover, .side-sub > a:hover, .side-item:hover { background: var(--panel-2); color: var(--fg); }
.side-nav > a[aria-current="page"], .side-sub > a[aria-current="page"], .side-item.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.side-nav > a[aria-current="page"]::before, .side-sub > a[aria-current="page"]::before, .side-item.on::before { content: ""; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: var(--accent); }
.lbl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.side-foot { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--line); padding-top: 10px; }
.side .status { display: flex; margin: 0; padding: 2px 10px; font-size: 11.5px; line-height: 1.35; white-space: normal; align-items: flex-start; min-height: 18px; }
.side .status .dot { margin-top: 4px; flex: none; }
.side-set { position: relative; }
.side-item .up { width: 16px; height: 16px; opacity: .7; transition: transform .15s; }
.side-item[aria-expanded="true"] { background: var(--panel-2); color: var(--fg); }
.side-item[aria-expanded="true"] .up { transform: rotate(180deg); }
.side .count { margin-left: 0; }
/* The settings menu opens upward, because it sits at the foot of the menu. */
.side-menu { position: absolute; left: 0; right: 0; bottom: calc(100% + 8px); z-index: 50; display: flex; flex-direction: column; gap: 2px; padding: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--pop); transform-origin: bottom center; }
.side-menu[hidden] { display: none; }
.side-menu-separator { border-top: 1px solid var(--line); margin: 3px 4px; }
.side-menu [role="menuitem"] { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border: 0; border-radius: 8px; color: var(--fg); background: transparent; text-align: start; cursor: pointer; transition: background .12s; }
.side-menu [role="menuitem"][hidden] { display: none; }
.side-menu [role="menuitem"]:hover, .side-menu [role="menuitem"]:focus-visible { background: var(--panel-2); }
.side-menu .ic { color: var(--muted); }
.side-menu [role="menuitem"] > span:not(.count) { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.side-menu b { font-weight: 600; font-size: 13.5px; }
.side-menu small { font-size: 11.5px; color: var(--muted); line-height: 1.35; }
.side-menu a[aria-current="page"] { background: var(--accent-soft); }
.side-menu a[aria-current="page"] .ic, .side-menu a[aria-current="page"] b { color: var(--accent); }
.app-install-dialog { width: min(360px, calc(100% - 32px)); max-height: calc(100dvh - 32px); overflow: auto; padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); color: var(--fg); box-shadow: var(--pop); }
.app-install-dialog::backdrop { background: rgba(8, 12, 18, .45); }
.app-install-dialog img { display: block; border-radius: 12px; }
.app-install-dialog h2 { margin: 12px 0 0; font: 600 22px/1.2 var(--head); }
.app-install-dialog p { margin: 8px 0 16px; color: var(--muted); }
.app-install-dialog form { display: flex; justify-content: flex-end; }
.app-install-dialog .btn { min-height: 44px; min-width: 68px; }
@media (prefers-reduced-motion: no-preference) { .side-menu { animation: menu-up .14s ease-out; } @keyframes menu-up { from { opacity: 0; transform: translateY(6px) scale(.98); } } }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
.top-in { width: 100%; padding: 10px 24px; flex-wrap: nowrap; gap: 10px; }
.view { width: 100%; padding: 22px 24px 40px; flex: 1; }
#view:has(> .pf-workspace) {
  --portfolio-gutter: clamp(6px, 1vw, 14px);
  max-width: none;
  padding-left: max(var(--portfolio-gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--portfolio-gutter), env(safe-area-inset-right, 0px));
}
.pf-workspace .pf-holdings, .pf-workspace .pf-risk { padding-inline: clamp(8px, 1.1vw, 14px); }
.foot { width: 100%; padding: 0 24px 32px; }
.search { max-width: 520px; flex: 1 1 320px; }
.search input { padding-left: 34px; padding-right: 36px; background-repeat: no-repeat; background-position: 11px 50%; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='%238a94a3' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.6-3.6'/%3E%3C/svg%3E"); }
.search-k { position: absolute; right: 9px; top: 50%; transform: translateY(-50%); font: 500 11px/18px var(--sans); color: var(--muted); border: 1px solid var(--line); border-radius: 5px; padding: 0 6px; background: var(--panel-2); pointer-events: none; }
.search input:focus ~ .search-k, .search input:not(:placeholder-shown) ~ .search-k { display: none; }
.pg-h .search input, .al-form .search input { background-image: none; padding-left: 11px; padding-right: 11px; }
.top-brand, .side-close, .side-mobile-heading, .mobile-nav, .side-nav .side-mobile-link { display: none; }
.scrim { position: fixed; inset: 0; z-index: 35; background: rgba(8, 12, 18, .45); }
.scrim[hidden] { display: none; }
.offline-banner { width: min(calc(100% - 28px), 1360px); margin: 10px auto 0; padding: 8px 12px; border: 1px solid color-mix(in srgb, var(--s2) 32%, var(--line)); border-radius: 9px; background: var(--warn-soft); color: var(--fg); font-size: 13px; }
.top-search { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 13px; border: 1px solid var(--line); border-radius: 100px; background: var(--panel-2); color: var(--muted); cursor: pointer; font-weight: 600; }
.top-search .ic { width: 17px; height: 17px; }
.ticker-search { inset: max(10px, env(safe-area-inset-top)) 0 auto; margin: 0 auto; width: min(560px, calc(100% - 24px)); max-height: calc(var(--search-height, 100dvh) - max(24px, env(safe-area-inset-top) + 16px)); overflow-y: auto; overscroll-behavior: contain; padding: 14px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); color: var(--fg); box-shadow: var(--pop); }
.ticker-search::backdrop { background: rgb(8 12 18 / .5); }
.ticker-search-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.ticker-search-head h2, .side-mobile-heading { margin: 0; font: 600 23px/1.2 var(--head); }
.ticker-search .side-btn { width: 44px; height: 44px; }
.ticker-search .search { max-width: none; }
.ticker-search input { min-height: 48px; font-size: 16px; background-color: var(--panel-2); }
.ticker-search .search-results { position: static; margin-top: 8px; border: 0; border-radius: 8px; box-shadow: none; }
.ticker-search .sr { grid-template-columns: auto minmax(0, 1fr); row-gap: 2px; min-height: 52px; border-radius: 8px; }
.ticker-search .sr span { white-space: normal; overflow-wrap: anywhere; }
.ticker-search .sr small { grid-column: 2; }

/* Collapsed to icons: the names appear beside an icon when it is pointed at or reached with the keyboard. */
@media (min-width: 901px) {
  html.nav-min .side { width: 68px; }
  html.nav-min .side .lbl, html.nav-min .side .brand-name, html.nav-min .side .status, html.nav-min .side-item .up { display: none; }
  html.nav-min .side-top { flex-direction: column; padding: 2px 0; gap: 10px; }
  html.nav-min .side-nav > a, html.nav-min .side-sub > a, html.nav-min .side-item { justify-content: center; padding: 10px 0; }
  html.nav-min .side-btn .chev { transform: rotate(180deg); }
  html.nav-min .side-item .count { position: absolute; top: 2px; right: 6px; min-width: 16px; font-size: 10px; line-height: 16px; }
  html.nav-min .side-menu { left: calc(100% + 10px); right: auto; bottom: 0; width: 252px; transform-origin: bottom left; }
  html.nav-min .side [data-label]:hover::after, html.nav-min .side [data-label]:focus-visible::after { content: attr(data-label); position: absolute; left: calc(100% + 12px); top: 50%; transform: translateY(-50%); z-index: 60; background: var(--fg); color: var(--bg); font: 500 12px var(--sans); padding: 5px 9px; border-radius: 7px; white-space: nowrap; box-shadow: var(--pop); pointer-events: none; }
  html.nav-min .side-item[aria-expanded="true"]::after { display: none; }
}
/* Primary destinations stay within reach and the rest of the menu opens above them. */
@media (max-width: 900px) {
  :root { --mobile-nav-height: calc(60px + env(safe-area-inset-bottom, 0px)); scroll-padding-top: calc(70px + env(safe-area-inset-top, 0px)); scroll-padding-bottom: var(--mobile-nav-height); }
  body { display: block; }
  html.nav-open, html:has(.ticker-search[open]) { overflow: hidden; }
  .side { position: fixed; inset: auto 0 0; width: min(100%, 520px); height: auto; max-height: calc(100dvh - max(12px, env(safe-area-inset-top))); margin: 0 auto; padding: 10px max(14px, env(safe-area-inset-right)) max(14px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left)); gap: 8px; border: 1px solid var(--line); border-radius: 20px 20px 0 0; overflow-y: auto; overscroll-behavior: contain; transform: translateY(100%); visibility: hidden; pointer-events: none; transition: transform .2s ease, visibility 0s .2s; }
  html.nav-open .side { transform: none; visibility: visible; pointer-events: auto; box-shadow: var(--pop); transition: transform .2s ease; }
  .side-mobile-heading { display: block; }
  .side-top { position: sticky; top: -10px; z-index: 1; padding: 5px 2px; background: var(--panel); }
  .side-top .brand, #side-toggle, .side #search, .side .search, .side-nav :is([data-nav="market"], [data-nav="portfolio"], [data-nav="watchlist"]) { display: none; }
  .side-close { display: grid; width: 44px; height: 44px; }
  .side-nav { flex: none; }
  .side-nav .side-mobile-link { display: flex; }
  .side-foot { gap: 5px; padding-top: 6px; }
  .side-foot .status { order: 1; }
  .side-foot .status:empty { display: none; }
  .side .status { padding-block: 4px; }
  .side-menu { position: static; border: 0; padding: 4px 0 0 13px; box-shadow: none; animation: none; }
  .side-menu :is(a[data-nav]:not(.side-keep), .side-menu-separator) { display: none; }
  .side-item .up { transform: rotate(180deg); }
  .side-item[aria-expanded="true"] .up { transform: none; }
  .side-menu [role="menuitem"], .side-nav > a, .side-sub > a, .side-item { min-height: 46px; }
  .top-brand { display: inline-flex; min-height: 44px; }
  .top .top-in { justify-content: space-between; padding: max(7px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 7px max(14px, env(safe-area-inset-left)); gap: 8px; }
  .mobile-nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: fixed; z-index: 28; inset: auto 0 0; min-height: var(--mobile-nav-height); padding: 3px max(6px, env(safe-area-inset-right)) max(3px, env(safe-area-inset-bottom)) max(6px, env(safe-area-inset-left)); border-top: 1px solid var(--line); background: var(--panel); }
  .mobile-nav > * { position: relative; display: grid; place-items: center; align-content: center; min-width: 0; min-height: 53px; border: 0; border-radius: 10px; padding: 3px 0; gap: 2px; background: transparent; color: var(--muted); cursor: pointer; font-size: .75rem; font-weight: 600; line-height: 1.1; }
  .mobile-nav .ic { box-sizing: content-box; width: 20px; height: 20px; padding: 4px 13px; border-radius: 99px; }
  .mobile-nav [aria-current="page"], .mobile-nav .on { color: var(--accent); font-weight: 700; }
  .mobile-nav [aria-current="page"] .ic, .mobile-nav .on .ic { background: var(--accent-soft); }
  .mobile-nav .count { position: absolute; margin: 0; top: 2px; inset-inline-start: calc(50% + 12px); }
  .view { padding: 16px max(12px, env(safe-area-inset-right)) calc(var(--mobile-nav-height) + 20px) max(12px, env(safe-area-inset-left)); gap: 14px; }
  .toasts { bottom: calc(var(--mobile-nav-height) + 10px); }
  .foot { padding: 0 16px 28px; }
  .search-k { display: none; }
  .main { min-height: 100dvh; }
  .view :is(.btn, .tab, .seg button, .chip) { min-height: 44px; }
  .view :is(input:not([type=checkbox]):not([type=radio]), select, textarea) { font-size: 16px; }
  .side .side-menu .ic { flex-shrink: 0; }
}
@media (prefers-reduced-motion: reduce) { .side, html.nav-open .side { transition: none; } }

/* ---------- market: what the radar and the signals found, on the front page ---------- */
.attn .grid3 { gap: 14px 32px; }
.attn-h { margin: 0 0 4px; font: 600 12.5px var(--sans); color: var(--muted); display: flex; align-items: center; position: relative; }
.attn-ev { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 1px 10px; padding: 8px 4px; border-top: 1px solid var(--line); border-radius: 6px; }
.attn-ev:first-child { border-top: 0; }
.attn-ev:hover { background: var(--panel-2); }
.attn-ev b { font-weight: 600; }
.attn-ev span { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.attn-ev small { grid-column: 2; color: var(--muted); font-size: 12px; }
.attn-n { margin: 6px 4px 0; font-size: 12.5px; color: var(--muted); }
.more { display: inline-block; margin: 8px 4px 0; font-size: 12.5px; font-weight: 600; color: var(--accent); }
.more::after { content: " \2192"; }
.more:hover { text-decoration: underline; text-underline-offset: 3px; }
.attn .row { grid-template-columns: 56px 1fr 0 auto; }


/* ---------- the company cockpit: verdict tiles, the layered chart with the selected day beside it, the evidence ---------- */
.rd-lead { max-width: 112ch; margin: 2px 0 0; }
.rd-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 12px; }
@media (min-width: 1240px) { .rd-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.rd { all: unset; box-sizing: border-box; position: relative; display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 14px 16px 15px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); cursor: pointer; transition: border-color .12s, transform .12s; }
a.rd:hover, button.rd:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); transform: translateY(-1px); }
.rd:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.rd[aria-busy] { cursor: default; }
.rd-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; font: 600 13.5px var(--sans); color: var(--fg); min-height: 22px; }
.rd-h .ev-pill { align-self: center; }
.rd-b { display: flex; flex-direction: column; gap: 1px; }
.rd-b b { font: 600 26px/1.15 var(--head); letter-spacing: -.01em; }
.rd-b b.txt { font-size: 17px; line-height: 1.3; }
.rd-b small { font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.rd-l { margin: 0; font-size: 12.5px; line-height: 1.45; color: var(--muted); }
.rd-key { display: flex; flex-wrap: wrap; gap: 2px 12px; }
.rd-key i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }
.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.clamp6 { display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
.rd-ck { display: flex; flex-direction: column; gap: 4px; margin-top: 2px; }
.rd-ck div { display: grid; grid-template-columns: 8px minmax(0, 1fr) auto; gap: 8px; align-items: center; font-size: 12.5px; }
.rd-ck i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.rd-ck .pos i { background: var(--up); }
.rd-ck .neg i { background: var(--down); }
.rd-ck .some i { background: var(--s2); }
.rd-ck em { font-style: normal; color: var(--muted); }
.rb { margin: 4px 0 2px; }
.rb-t { position: relative; height: 8px; border-radius: 4px; background: var(--panel-2); }
.rb-t em, .rb-t i { position: absolute; top: 0; bottom: 0; border-radius: 4px; }
.rb-t em { background: color-mix(in srgb, var(--s1) 22%, transparent); }
.rb-t i { background: color-mix(in srgb, var(--s1) 58%, transparent); }
.rb-t u { position: absolute; top: -3px; bottom: -3px; width: 3px; margin-left: -1.5px; border-radius: 2px; background: var(--fg); box-shadow: 0 0 0 2px var(--panel); }
.rb-l { display: flex; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.stk { display: flex; gap: 2px; height: 8px; margin: 4px 0 2px; }
.stk i { border-radius: 3px; min-width: 3px; }
.stk-m { background: color-mix(in srgb, var(--muted) 62%, transparent); }
.stk-s { background: color-mix(in srgb, var(--muted) 28%, transparent); }
.stk-x { background: var(--s1); }
.ck { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: stretch; }
.ck > .panel { min-width: 0; }
.ck-day { display: flex; flex-direction: column; }
.ck-day .daycard { flex: 1; }
.ck-day .seg button { padding: 3px 12px; font-size: 16px; line-height: 1.2; }
.ck-layers { align-items: center; margin: 0 0 10px; }
.ck-lab { font-size: 12.5px; font-weight: 600; color: var(--muted); margin-right: 4px; }
.ck-layers .chip { padding: 4px 11px; font-size: 12.5px; }
.ck-leg { margin-top: 10px; min-height: 16px; }
@media (max-width: 1180px) { .ck { grid-template-columns: minmax(0, 1fr); } }
.ah { display: flex; flex-direction: column; }
.ah-r { display: grid; grid-template-columns: 96px 76px minmax(0, 1fr) 62px; gap: 12px; align-items: center; padding: 9px 4px; border-top: 1px solid var(--line); font-size: 13.5px; }
.ah-r > :nth-child(2), .ah-r > :nth-child(4) { text-align: right; }
.ah-h { border-top: 0; font-size: 11.5px; color: var(--muted); padding-top: 0; }
.ah-r .rb { margin: 0 0 3px; }
.ah-r small { font-size: 11.5px; }
.su { display: grid; grid-template-columns: minmax(0, 1fr) auto 64px; gap: 12px; align-items: center; padding: 10px 4px; border-top: 1px solid var(--line); }
.su:first-child { border-top: 0; }
.su > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.su small { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.su > b { text-align: right; font-weight: 600; }
.su .ev-pill { align-self: center; }
.rx { display: flex; gap: 6px; align-items: stretch; margin: 4px 0; }
.rx-c { flex: 1; min-width: 0; display: grid; grid-template-rows: 38px 38px auto auto; text-align: center; }
.rx-c i { display: flex; justify-content: center; }
.rx-c i:first-child { align-items: flex-end; border-bottom: 1px solid var(--muted); }
.rx-c i:nth-child(2) { align-items: flex-start; }
.rx-c u { width: min(26px, 70%); border-radius: 3px 3px 0 0; }
.rx-c u.pos { background: var(--up); }
.rx-c u.neg { background: var(--down); border-radius: 0 0 3px 3px; }
.rx-c b { font-size: 11.5px; font-weight: 600; margin-top: 3px; }
.rx-c small { font-size: 10.5px; color: var(--muted); white-space: nowrap; overflow: hidden; }
@media (max-width: 560px) {
  .ah-r { grid-template-columns: 76px 62px minmax(0, 1fr) 44px; gap: 8px; }
  .su { grid-template-columns: minmax(0, 1fr) 56px; }
  .su .ev-pill { grid-column: 1; grid-row: 2; justify-self: start; }
  .su > b { grid-column: 2; grid-row: 1; }
  .rd-b b { font-size: 23px; }
  .rx-c small { font-size: 9.5px; }
}


/* ---------- page headings and desktop search ---------- */
.vh { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.pg-h.bare { justify-content: space-between; }
.side { gap: 14px; }
.side .search { flex: none; max-width: none; }
.side .search input { background-color: var(--panel-2); border-color: transparent; }
.side .search input:focus { background-color: var(--panel); }
.side .search-results { right: auto; width: 330px; max-width: calc(100vw - 32px); z-index: 60; }
.side-find { display: none; }
@media (min-width: 901px) {
  .top { display: none; }
  .view { padding-top: 26px; }
  .bd-side { top: 20px; max-height: calc(100vh - 40px); }
  html.nav-min .side .search { display: none; }
  html.nav-min .side-find { display: flex; }
}
@media (max-width: 900px) {
  .top-in { justify-content: flex-start; }
  .top-brand { margin-left: 2px; }
}

/* ---------- explanations on demand ---------- */
/* One floating note serves every "?" and every explained column heading. It is fixed to the window and placed by script,
   so a panel or a scrolling table never clips it and it never widens the page. */
.note-pop { position: fixed; z-index: 120; left: 0; top: 0; box-sizing: border-box; width: max-content; max-width: 290px; background: var(--fg); color: var(--bg); font: 400 12.5px/1.5 var(--sans); letter-spacing: 0; text-transform: none; text-align: left; white-space: normal; overflow-wrap: anywhere; padding: 9px 12px; border-radius: 9px; box-shadow: var(--pop); pointer-events: none; }
.note-pop[hidden] { display: none; }
@media (prefers-reduced-motion: no-preference) { .note-pop { animation: note-in .12s ease-out; } @keyframes note-in { from { opacity: 0; transform: translateY(3px); } } }
/* The mark is small; the area that answers a finger is not. A mark whose note is held open is filled in. */
.help::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; }
.help:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.help[data-open] { background: var(--fg); border-color: var(--fg); color: var(--bg); }
.h2 .help { vertical-align: 2px; margin-left: 7px; }
.ai-h .help, .wl th .help, .sub .help { vertical-align: 0; }
.al-form > .help { margin-left: 0; }

/* ---------- orders: the real-money account ---------- */
.ord { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.ord .lead { margin: 0; }
.kpi > b a:hover { text-decoration: underline; text-underline-offset: 3px; }
.kpi > b.warn { color: var(--s2); }
.ord-side { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.ord-mkt { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.ord-mkt i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.ord-mkt.on { color: var(--fg); }
.ord-mkt.on i { background: var(--up); }
.ord-mkt small { font-size: 12px; color: var(--muted); }
.ord-t th.l, .ord-t td.l { text-align: left; }
.ord-t td { vertical-align: middle; }
.ord-t.wl.tb td:first-child { min-width: 0; white-space: nowrap; }
.ord-t.wl.tb tr.ord-x td { white-space: normal; }
.ord-t tfoot td { border-bottom: 0; font-weight: 600; }
.ord-n { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--panel-2); color: var(--muted); font: 600 11px var(--mono); }
.ord-o { display: inline-flex; flex-direction: column; gap: 3px; align-items: flex-start; }
.ord-o small, .ord-px small, .ord-w small { font: 400 11.5px var(--sans); color: var(--muted); }
.ord-px, .ord-w { display: inline-flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.ord-w { flex-direction: row; flex-wrap: wrap; justify-content: flex-end; align-items: baseline; gap: 2px 6px; max-width: 150px; color: var(--muted); }
.ord-w i { font-style: normal; }
.ord-w b { color: var(--fg); font-weight: 600; }
.ord-w small { flex-basis: 100%; text-align: right; }
.ord-r { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; font-family: var(--sans); color: var(--muted); }
.ord-more { all: unset; cursor: pointer; font: 600 12px var(--sans); color: var(--accent); border-radius: 4px; }
.ord-more:hover { text-decoration: underline; text-underline-offset: 3px; }
.ord-more:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ord-px small.ord-stop { color: var(--s2); }
.ord-t th, .ord-t td { padding-left: 9px; padding-right: 9px; }
.ord-t td.thesis { min-width: 220px; }
.ord-act { display: inline-flex; gap: 6px; }
.ord-t tr.on td { border-bottom-color: transparent; background: color-mix(in srgb, var(--panel-2) 55%, transparent); }
.ord-x td { white-space: normal; text-align: left; font-family: var(--sans); background: color-mix(in srgb, var(--panel-2) 55%, transparent); padding: 4px 16px 18px 46px; }
/* What opens under an order fills the row without being allowed to widen the table. */
.ord-x td > .ord-why, .ord-x td > .ord-form { width: 0; min-width: 100%; box-sizing: border-box; }
.ord-why { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px 28px; }
.ord-why b { font-weight: 600; font-size: 12.5px; }
.ord-why p { margin: 3px 0 0; font-size: 14px; line-height: 1.5; }
.ord-why > .ord-flag, .ord-why > .ord-facts { grid-column: 1 / -1; }
.ord-flag { margin: 0; padding: 8px 12px; border-radius: 8px; background: var(--warn-soft); font-size: 13.5px; }
.ord-facts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; font-size: 13px; color: var(--muted); padding-top: 12px; border-top: 1px solid var(--line); }
.ord-facts b { color: var(--fg); }
.ord-copy { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; }
.ord-copy code { font: 500 12.5px var(--mono); color: var(--fg); background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 4px 8px; }
.ord-form { display: grid; grid-template-columns: repeat(3, minmax(0, 170px)) minmax(0, 1fr); gap: 12px 16px; align-items: end; padding-top: 4px; }
.ord-form .al-form .msg, .ord-acct .msg, .ord-setup .msg { padding: 0; }
.ord-skips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 14px 0 0; font-size: 13px; }
.ord-skips .chipx { font-size: 12px; padding: 3px 4px 3px 10px; margin: 0; display: inline-flex; align-items: center; gap: 6px; }
.ord-back { all: unset; cursor: pointer; font-weight: 600; color: var(--accent); padding: 1px 7px; border-radius: 999px; }
.ord-back:hover, .ord-back:focus-visible { background: var(--accent-soft); }
.ord-notes { margin-top: 14px; font-size: 13px; }
.ord-acct { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: 22px 36px; }
.ord-h3 { margin: 0 0 8px; font: 600 13px var(--sans); display: flex; align-items: center; }
.ord-acct .sub, .ord-rec { font-size: 13px; margin-top: 8px; }
.ord-rec:empty { display: none; }
.ord-ck { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.ord-setup .lab-form { max-width: 720px; }
@media (max-width: 760px) { .ord-form { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ord-form .al-form { grid-column: 1 / -1; } .ord-x td { padding-left: 16px; } .ord-copy { margin-left: 0; } }

.watch-search { width: 300px; max-width: 100%; }
.watch-search input { min-height: 44px; }
.watch-status { margin: 0; }
.watch-status:empty, .pf-quote-status:empty, .pf-scope:empty, .pf-jump[hidden], .pf-jump-btn[hidden] { display: none; }
.mk-lead { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; min-height: 27px; }
.mk-lead > b { font-weight: 600; }
.mk-lead > span { color: var(--muted); font-size: 13px; }
.mk-tile-loading { min-height: 150px; pointer-events: none; }
.mk-lead > .rows { width: min(295px, 100%); }
.watch-scroll:focus-visible { outline-offset: -2px; }
.co-actions { display: grid; justify-items: end; gap: 8px; min-width: 0; }
.stock-price .panel-h { align-items: center; }
.stock-price .panel-h > .seg { margin-inline-start: auto; }
.chart-mode-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.stock-price .chart-mode-controls { margin-inline-start: auto; }
.chart-mode-controls [hidden], .chart-session-legend[hidden], .regular-quote-label[hidden] { display: none; }
.chart-session-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 14px; margin-top: 7px; font-size: 12px; color: var(--muted); }
.chart-session-legend > span { display: inline-flex; align-items: center; gap: 5px; }
.chart-session-legend i { width: 9px; height: 9px; border-radius: 3px; }
.pf-chart-footer .chart-session-legend { flex-basis: 100%; margin: 0; }
.regular-quote-label { font-size: 12px; color: var(--muted); }
.stock-ranges { margin-bottom: 8px; }
.pf-heading { align-items: center; }
.pf-scope { margin: 3px 0 0; color: var(--fg); font-size: 13px; font-weight: 600; }
.pf-quote-status { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.pf-unlock { width: min(100%, 440px); max-width: none; margin: clamp(12px, 5dvh, 48px) auto; padding: clamp(14px, 4vw, 28px); gap: 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel-2); }
.pf-unlock .h2, .pf-unlock .sub { margin: 0; }
.pf-unlock .sub { margin-top: 4px; }
.pf-unlock .pf-actions .btn { width: 100%; min-height: 44px; }
.pf-jump { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 5px; border-top: 1px solid var(--line); }
.pf-jump-btn { min-height: 34px; padding: 6px 12px; border: 1px solid transparent; border-radius: 8px; background: var(--panel-2); color: var(--fg); font-weight: 600; cursor: pointer; }
.pf-jump-btn:hover { border-color: var(--line); color: var(--accent); }
.pf-dashboard-item[tabindex]:focus-visible { outline-offset: 3px; border-radius: 10px; }
.pf-summary .kpi:first-child { background: linear-gradient(130deg, color-mix(in srgb, var(--accent-soft) 64%, var(--panel)), var(--panel) 82%); }
.pf-summary .kpi > b { font-variant-numeric: tabular-nums; }
.pf-summary .pf-cumulative { border-color: color-mix(in srgb, var(--accent) 32%, var(--line)); }
.pf-cumulative-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; }
.pf-cumulative-cell small { display: block; color: var(--muted); margin-top: 2px; }
.pf-funding-form > .sub { margin: 10px 0 0; }
.pf-trade-costs[hidden], .pf-sale-form .pf-field[hidden] { display: none; }
.pf-sale-form > .sub { margin-block: 9px 0; }
.pf-sale-form > .pf-group-toggle { margin-top: 10px; }
.pf-position-status { display: inline-block; padding: 2px 7px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-size: 11px; font-weight: 600; }
.pf-position-status.closed { background: var(--panel-2); color: var(--muted); }
.pf-last-sale small { display: block; margin-top: 2px; color: var(--muted); }
.pf-sale-link { color: var(--accent); border: 0; background: transparent; font-weight: 500; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.pf-filter-groups { display: grid; gap: 10px; }
.pf-filter-group { min-width: 0; padding: 8px 10px 11px; margin: 0; border: 1px solid var(--line); border-radius: 8px; }
.pf-filter-group legend { padding: 0 4px; color: var(--fg); font-size: 13px; font-weight: 600; }
.pf-filter-group .pf-fields { margin: 0; }
.pf-filter-group .pf-group-toggle { align-self: center; }

@media (max-width: 900px) {
  .mobile-nav > *, .top-search, #side :is(a, button) { -webkit-tap-highlight-color: transparent; }
  .pf-sale-link, .pf-sale-form > .pf-group-toggle { min-height: 44px; }
  .mobile-nav > :active, .top-search:active { background: var(--accent-soft); }
  .view > .pg-h > .pg-side { min-width: 0; }
  .view[data-page="watchlist"] > .pg-h > .pg-side { flex: 1 0 min(100%, 235px); }
  .watch-scroll :is(th, td):first-child { position: sticky; inset-inline-start: 0; z-index: 1; max-width: 44vw; background: var(--panel); box-shadow: 1px 0 var(--line); }
  .watch-scroll tbody tr:hover td:first-child { background: var(--panel-2); }
  .watch-scroll th button:not(.help), .watch-scroll .xbtn { min-height: 44px; }
  .watch-scroll th button:focus-visible { outline: 2px solid var(--accent); }
  .watch-scroll td:first-child a { display: grid; align-content: center; min-height: 44px; }
  .watch-scroll .co { max-width: 100%; }
  .watch-scroll .xbtn { min-width: 44px; }
  .watch-scroll .wl { min-width: 560px; }
  #view .watch-scroll .wl :is(th, td) { padding: 4px 9px; }
  .co-head { align-items: start; }
  .co-head > div { max-width: 100%; }
  .co-head .h1 { overflow-wrap: anywhere; }
  .co-actions { justify-items: start; }
  .co-actions .pg-side { flex-wrap: wrap; }
  .stock-ranges, .pf-chart-ranges { display: flex; flex-wrap: nowrap; justify-content: space-between; width: 100%; overflow-x: auto; overscroll-behavior-x: contain; }
  :is(.stock-ranges, .pf-chart-ranges) > button { min-width: 44px; flex: 1 0 auto; padding-inline: 5px; }
  :is(.stock-ranges, .pf-chart-ranges) > button:focus-visible { outline-offset: -3px; }
  .ck-layers { flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; padding: 3px; }
  .ck-layers > * { flex: none; }
  .pf-jump { gap: 4px; }
  .pf-jump-btn { flex: 1 0 auto; min-height: 44px; }
  .pf-summary .kpi:first-child { grid-column: 1 / -1; padding: 13px; }
  .pf-summary .kpi:first-child > b { font-size: clamp(25px, 7vw, 34px); }
  .pf-summary .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pf-summary .kpi { padding: 8px; }
  .pf-summary .kpi > span { font-size: 11.5px; }
  .pf-summary .kpi > b { font: 600 clamp(13px, 3.8vw, 18px)/1.2 var(--sans); }
  .pf-summary .kpi > small { font-size: 11px; }
  .pf-summary .pf-cumulative { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; padding: 10px 12px; }
  .pf-summary .pf-cumulative > small { grid-column: 1 / -1; }
  .pf-summary .pf-cumulative > b { font-size: clamp(16px, 4.8vw, 21px); }
  .pf-chart-header { gap: 4px 10px; }
  .pf-chart-title { flex: 1 0 12rem; gap: 4px 10px; }
  .pf-chart-title .h2 { flex-basis: 100%; }
  .pf-chart-legend-row { grid-template-columns: minmax(0, 1fr); }
  .pf-chart-legend { display: flex; flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-x: contain; padding: 2px; }
  .pf-chart-chip { min-width: 116px; flex: 0 0 auto; }
  .pf-chart-plot { height: clamp(235px, 36dvh, 360px); }
  .pf-view-bar .pf-view-actions { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; }
  .pf-filter-group .pf-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-filter-group .pf-group-toggle { align-self: end; }
}

@media (max-width: 450px) {
  .pf-summary .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-summary .kpi:last-child { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; }
  .pf-summary .kpi:last-child > small { grid-column: 1 / -1; }
  .pf-chart-ranges > button, .stock-ranges > button { min-width: 39px; }
}

@media (max-width: 360px) {
  .mobile-nav > * { font-size: 11px; }
  .pf-summary .kpi > b { font-size: 12px; }
  .pf-filter-group .pf-fields { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Voices on X: the room at a glance, who is talking, and each post's signals ---------- */
/* Green and red mean bullish and bearish only; amber marks attention; blue is for neutral measures such as reputation. */
:root { --x-blue: #1d9bf0; --x-gold: #c9a10b; --x-grey: #829aab; }
.xf-head { align-items: center; }
.xf-head .h2 { display: inline-flex; align-items: center; }
.xf-status { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; margin-right: auto; }
.xf-state { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; }
.xf-state small { font-weight: 400; color: var(--muted); font-size: 12px; }
.xf-state.live { color: var(--up); }
.xf-state.busy { color: var(--fg); }
.xf-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); display: inline-block; flex: none; }
.xf-dot.live { background: var(--up); box-shadow: 0 0 0 3px color-mix(in srgb, var(--up) 22%, transparent); }
@media (prefers-reduced-motion: no-preference) { .xf-dot.live { animation: xfpulse 1.8s ease-in-out infinite; } @keyframes xfpulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--up) 0%, transparent); } } }
.xf-spend { font-size: 12px; padding: 2px 8px; border-radius: 999px; background: var(--panel-2); }
.xf-right { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.xf-ctl { display: flex; align-items: center; gap: 6px; }
.xf-cap { padding: 6px 8px; font-size: 13px; }
.xf-err { padding: 6px 2px; }

.xf-room { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 10px; margin-bottom: 16px; }
.xf-cell { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); text-align: left; }
.xf-k { display: inline-flex; align-items: center; font: 600 11px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.xf-big { font: 600 20px/1.2 var(--head); letter-spacing: -.01em; }
.xf-big.pos { color: var(--up); } .xf-big.neg { color: var(--down); } .xf-big.some { color: var(--s2); }
.xf-big.xf-quiet { font-size: 16px; color: var(--muted); }
.xf-l { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.xf-l.up, .xf-l .up { color: var(--up); } .xf-l.down, .xf-l .down { color: var(--down); }
.xf-hot { color: var(--s2); font-weight: 600; }
.xf-shift { font-weight: 600; }
.xf-bal { display: flex; height: 10px; border-radius: 5px; overflow: hidden; gap: 2px; background: var(--panel); }
.xf-bal i { display: block; min-width: 0; }
.xf-bal .b { background: var(--up); } .xf-bal .n { background: color-mix(in srgb, var(--muted) 38%, transparent); } .xf-bal .r { background: var(--down); }
.xf-pulse { width: 100%; height: 52px; display: block; }
.xf-pulse .pb { fill: var(--up); } .xf-pulse .pn { fill: color-mix(in srgb, var(--muted) 45%, transparent); } .xf-pulse .pr { fill: var(--down); }
.xf-pulse .pa { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.xf-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); }
.xf-themes { display: flex; flex-direction: column; gap: 5px; }
.xf-theme { display: grid; grid-template-columns: minmax(70px, auto) 1fr 14px; align-items: center; gap: 8px; font-size: 12.5px; }
.xf-tbar { display: block; height: 6px; border-radius: 3px; background: var(--panel); overflow: hidden; }
.xf-tbar u { display: block; height: 100%; border-radius: 3px; background: color-mix(in srgb, var(--s1) 60%, transparent); }
.xf-theme em { font-style: normal; font-size: 11px; text-align: center; }
.xf-cell .rb-t { background: var(--panel); }
.xf-who { all: unset; box-sizing: border-box; display: flex; flex-direction: column; gap: 8px; min-width: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); cursor: pointer; }
.xf-who:hover { border-color: var(--muted); }
.xf-who:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.xf-whohead { display: flex; align-items: center; gap: 10px; min-width: 0; }
.xf-whohead > span:not(.xf-rep):not(.xf-av) { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.xf-whohead .xf-rep { margin-left: auto; align-self: flex-start; }
.xf-whohead b { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; line-height: 1.25; }
.xf-whohead .xf-name { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.xf-whohead small { color: var(--muted); font-size: 12px; }
.xf-whosig { display: flex; flex-direction: column; gap: 5px; align-items: flex-start; }

.xf-av { width: 36px; height: 36px; border-radius: 50%; flex: none; object-fit: cover; background: var(--line); }
.xf-av-i { display: inline-grid; place-items: center; background: hsl(var(--h, 210) 38% 44%); color: #fff; font: 600 13px/1 var(--sans); letter-spacing: .02em; }
.xf-check { width: 14px; height: 14px; flex: none; vertical-align: -2px; margin-left: 3px; }
.xf-check circle { fill: var(--x-blue); } .xf-check path { stroke: #fff; }
.xf-check-business circle { fill: var(--x-gold); } .xf-check-government circle { fill: var(--x-grey); }
.xf-gist { font-size: 13px; line-height: 1.4; color: var(--muted); }
.xf-gist.strong { color: var(--fg); font-weight: 500; }
.xf-dots { display: inline-flex; gap: 2px; align-items: center; }
.xf-dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--line); }
.xf-dots i.on { background: var(--fg); }

.xf-tabs { display: none; margin-bottom: 10px; }
.xf-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 18px; align-items: start; }
.xf-colh { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 10px; margin-bottom: 8px; min-height: 32px; }
.xf-colh .h2 { margin-right: 2px; }
.xf-colh .seg { margin-left: auto; }
.xf-only { font-size: 12px; padding: 3px 10px; }
.xf-vlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.xf-v { all: unset; box-sizing: border-box; width: 100%; display: grid; grid-template-columns: 18px 36px minmax(0, 1fr) 74px; grid-template-areas: "rank av who rep" "rank av sig sig" ". . gist gist"; gap: 2px 10px; align-items: center; padding: 10px 8px; border-top: 1px solid var(--line); cursor: pointer; border-radius: 8px; }
.xf-vlist li:first-child .xf-v { border-top: 0; }
.xf-v:hover { background: var(--panel-2); }
.xf-v[aria-pressed="true"] { background: color-mix(in srgb, var(--s1) 10%, var(--panel)); box-shadow: inset 3px 0 0 var(--s1); }
.xf-v:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.xf-rank { grid-area: rank; color: var(--muted); font-size: 12px; text-align: right; align-self: start; padding-top: 9px; }
.xf-v .xf-av { grid-area: av; align-self: start; }
.xf-vwho { grid-area: who; display: flex; flex-direction: column; min-width: 0; }
.xf-vwho b, .xf-pwho b { display: inline-flex; align-items: center; min-width: 0; font-size: 13.5px; }
.xf-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.xf-vwho small, .xf-pwho small { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xf-rep { display: inline-flex; align-items: center; gap: 6px; justify-self: end; font-size: 12px; cursor: help; }
.xf-v .xf-rep { grid-area: rep; }
.xf-repbar { display: block; width: 38px; height: 5px; border-radius: 3px; background: var(--panel-2); overflow: hidden; }
.xf-repbar u { display: block; height: 100%; background: var(--s1); }
.xf-rep.sm { padding: 1px 7px; border-radius: 999px; background: color-mix(in srgb, var(--s1) 12%, transparent); color: var(--s1); font-weight: 600; }
.xf-vsig { grid-area: sig; display: flex; align-items: center; gap: 8px; min-width: 0; }
.xf-vsig small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.xf-v .xf-gist { grid-area: gist; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.xf-more { display: block; margin: 10px auto 0; }

.xf-plist { position: relative; display: flex; flex-direction: column; gap: 10px; }
.xf-p { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; background: var(--panel); display: flex; flex-direction: column; gap: 8px; }
@media (prefers-reduced-motion: no-preference) { .xf-p.fresh { animation: xffresh 6s ease-out; } @keyframes xffresh { from { background: var(--warn-soft); border-color: var(--s2); } } }
@media (prefers-reduced-motion: reduce) { .xf-p.fresh { box-shadow: inset 3px 0 0 var(--s2); } }
.xf-ph { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto auto; gap: 10px; align-items: center; }
.xf-pav { display: block; line-height: 0; }
.xf-pwho { display: flex; flex-direction: column; min-width: 0; }
.xf-pwho a:hover .xf-name { text-decoration: underline; }
.xf-time { font-size: 12px; color: var(--muted); white-space: nowrap; }
.xf-time:hover { color: var(--fg); }
.xf-psig { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; }
.xf-text { margin: 0; font-size: 14px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.xf-text a, .xf-link { color: var(--s1); }
.xf-text a:hover { text-decoration: underline; }
.xf-tag { font-weight: 600; }
.xf-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.xf-chip { font-size: 11.5px; padding: 2px 9px; border-radius: 999px; background: var(--panel-2); color: var(--muted); white-space: nowrap; }
.xf-chip.strong { color: var(--fg); font-weight: 600; box-shadow: inset 0 0 0 1px var(--line); background: var(--panel); }
.xf-chip.up { color: var(--up); font-weight: 600; } .xf-chip.down { color: var(--down); font-weight: 600; }
.xf-empty { padding: 26px 12px; text-align: center; color: var(--muted); }
.xf-empty b { display: block; color: var(--fg); font: 600 16px var(--head); margin-bottom: 4px; }
.xf-empty p { margin: 4px auto 0; max-width: 60ch; }

@media (max-width: 980px) {
  .xf-tabs { display: inline-flex; }
  .xf-body { grid-template-columns: minmax(0, 1fr); }
  .xf-col { display: none; }
  .xf-col.on { display: flex; }
}
@media (max-width: 640px) {
  .xf-right { width: 100%; justify-content: space-between; }
  .xf-room { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .xf-room > :first-child { grid-column: 1 / -1; }
  .xf-ph { grid-template-columns: 32px minmax(0, 1fr) auto; }
  .xf-ph .xf-rep { display: none; }
  .xf-av { width: 32px; height: 32px; }
  .xf-v { grid-template-columns: 16px 32px minmax(0, 1fr) 60px; }
}
@media (max-width: 420px) { .xf-room { grid-template-columns: minmax(0, 1fr); } }

/* ---------- the price chart's markers: circles for company events, squares for insider trades, coloured by signal ---------- */
/* Green and red are bullish and bearish (up and down), grey is neutral. Bullish badges sit below the price and point up to it. */
:root { --neutral-mark: #8a94a3; }
.cm-layer { position: absolute; inset: 0; pointer-events: none; z-index: 4; overflow: hidden; }
.cm-b { all: unset; box-sizing: border-box; position: absolute; left: 0; top: 0; width: 22px; height: 22px; display: grid; place-items: center; pointer-events: auto; cursor: pointer;
  --c: var(--neutral-mark); background: var(--c); color: #fff; border-radius: 50%; font: 700 11px/1 var(--sans); box-shadow: 0 0 0 2px var(--panel), 0 1px 3px rgba(15, 20, 26, .3); }
.cm-b[hidden] { display: none; }
.cm-b.bull { --c: var(--up); } .cm-b.bear { --c: var(--down); } .cm-b.neutral { --c: var(--neutral-mark); }
.cm-b.cm-trade { border-radius: 5px; font-size: 10px; }
.cm-b.c1 { opacity: .8; }
.cm-b.c3 { box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px color-mix(in srgb, var(--c) 45%, transparent), 0 1px 3px rgba(15, 20, 26, .3); }
.cm-b::after { content: ''; position: absolute; left: 50%; margin-left: -4px; border: 4px solid transparent; pointer-events: none; }
.cm-b:not(.below)::after { top: calc(100% - 1px); border-top-color: var(--c); }
.cm-b.below::after { bottom: calc(100% - 1px); border-bottom-color: var(--c); }
.cm-b.static { position: relative; pointer-events: none; flex: none; }
.cm-b.static::after { display: none; }
.cm-b:hover, .cm-b:focus-visible { z-index: 2; opacity: 1; box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--c), 0 2px 6px rgba(15, 20, 26, .3); outline: none; }
.cm-b.sel { z-index: 1; opacity: 1; box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--fg); }
.cm-g { pointer-events: none; }
.cm-n { position: absolute; top: -8px; right: -10px; padding: 2px 4px; border-radius: 8px; background: var(--fg); color: var(--bg); font: 700 9px/1 var(--sans); pointer-events: none; }
.cm-tip { position: absolute; left: 0; top: 0; z-index: 5; display: flex; align-items: center; gap: 7px; max-width: min(340px, 90%); padding: 6px 10px; border-radius: 8px;
  background: var(--fg); color: var(--bg); font-size: 12px; line-height: 1.35; box-shadow: var(--pop); pointer-events: none; }
.cm-tip[hidden] { display: none; }
.cm-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; display: inline-block; background: var(--neutral-mark); }
.cm-dot.bull { background: var(--up); } .cm-dot.bear { background: var(--down); }
.cm-tip .cm-dot { box-shadow: 0 0 0 1.5px var(--bg); }
.cm-key { display: inline-flex; align-items: center; gap: 5px; }
.legend .cm-key i { width: auto; height: auto; }
.legend .cm-key .cm-dot { width: 9px; height: 9px; }
.cm-shape { width: 10px !important; height: 10px !important; border: 1.5px solid var(--muted); display: inline-block; background: none !important; }
.cm-shape.round { border-radius: 50%; } .cm-shape.square { border-radius: 3px; }

.cm-card { position: absolute; z-index: 20; width: min(370px, calc(100% - 16px)); max-height: 72vh; overflow: auto; display: flex; flex-direction: column; gap: 10px;
  padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--pop); }
.cm-card.sheet { position: fixed; left: 8px; right: 8px; bottom: calc(8px + var(--mobile-nav-height, env(safe-area-inset-bottom, 0px))); top: auto !important; width: auto; max-height: calc(78vh - var(--mobile-nav-height, 0px)); }
@media (prefers-reduced-motion: no-preference) { .cm-card { animation: cmin .14s ease-out; } @keyframes cmin { from { opacity: 0; transform: translateY(4px); } } }
.cm-head { display: flex; align-items: center; gap: 10px; }
.cm-title { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.cm-title b { font: 600 15px/1.25 var(--head); }
.cm-title small { color: var(--muted); font-size: 12px; }
.cm-x { opacity: 1; flex: none; }
.cm-sig { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; }
.cm-why, .cm-note { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.cm-gist { font-weight: 500; font-size: 13px; line-height: 1.4; }
.cm-rows { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.cm-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.cm-row span { color: var(--muted); }
.cm-files { display: flex; flex-direction: column; gap: 5px; }
.cm-file { display: grid; grid-template-columns: 58px 1fr; gap: 8px; align-items: center; font-size: 12.5px; }
.cm-file:hover span:last-child { text-decoration: underline; }
.cm-who { display: flex; align-items: center; gap: 10px; }
.cm-who > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.cm-who small { color: var(--muted); font-size: 12px; }
.cm-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.cm-others { display: flex; flex-direction: column; gap: 6px; border-top: 1px solid var(--line); padding-top: 10px; }
.cm-other { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }

/* ---------- insider trades card: the Voices on X layout, with a few insider-specific pieces ---------- */
.ins-roles { display: flex; flex-direction: column; gap: 6px; }
.ins-role { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 12.5px; }
.ins-role span { color: var(--muted); }
.ins-role b { white-space: nowrap; }
.xf-rep.ins-role-tag, .xf-rep.sm.ins-role-tag { cursor: default; padding: 1px 8px; border-radius: 999px; background: var(--panel-2); color: var(--muted); font-weight: 600; font-size: 11.5px; }
.ins-t.routine { opacity: .82; }
.ins .xf-pulse .pn { fill: color-mix(in srgb, var(--muted) 55%, transparent); }

/* ---------- SEC filings: tags on the chart and the filings card ---------- */
.cm-b.cm-filing { width: auto; min-width: 26px; height: 20px; padding: 0 6px; border-radius: 6px; font: 700 9.5px/1 var(--sans); letter-spacing: .02em; white-space: nowrap; }
.cm-b.cm-filing.static { height: 22px; min-width: 34px; font-size: 10px; }
.cm-shape.tag { width: 16px !important; height: 9px !important; border-radius: 3px; }
.cm-items { display: flex; flex-direction: column; gap: 4px; }
.cm-items .mini { margin: 0; padding-left: 18px; font-size: 12.5px; }
.xf-v .cm-b.static { grid-area: av; justify-self: center; align-self: start; margin-top: 4px; }
.fil-ph { grid-template-columns: auto minmax(0, 1fr) auto auto; }
.fil-ph .xf-time + .xf-time { margin-left: 2px; }
button.cm-other { background: none; border: 0; margin: 0 -6px; padding: 5px 6px; border-radius: 7px; color: inherit; font: inherit; font-size: 12.5px; text-align: left; cursor: pointer; }
button.cm-other:hover { background: var(--panel-2); }
.cm-n[hidden] { display: none; }
/* ---------- Headlines: speech-bubble markers and the headlines card ---------- */
.cm-b.cm-news { border-radius: 11px 11px 11px 3px; font-size: 10px; }
.cm-b.cm-news.below { border-radius: 3px 11px 11px 11px; }
.cm-shape.bubble { border-radius: 6px 6px 6px 1px; }
.cm-headline { font: 600 14px/1.35 var(--head); color: var(--fg); text-decoration: none; }
.cm-headline:hover { text-decoration: underline; }
.cm-newslist { display: flex; flex-direction: column; gap: 5px; }
.cm-newslist a { color: var(--fg); text-decoration: none; } .cm-newslist a:hover { text-decoration: underline; }
.cm-newslist small { color: var(--muted); }
.hl-cover { margin: -6px 0 12px; font-size: 12px; color: var(--muted); }
.xf-chip.warn { color: var(--down); font-weight: 600; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--down) 40%, var(--line)); background: var(--panel); }
button.hl-topic { all: unset; box-sizing: border-box; display: grid; grid-template-columns: minmax(70px, auto) 1fr 14px; align-items: center; gap: 8px; font-size: 12.5px; cursor: pointer; border-radius: 6px; padding: 1px 4px; margin: 0 -4px; }
button.hl-topic:hover { background: var(--panel); } button.hl-topic[aria-pressed="true"] { background: var(--panel); box-shadow: inset 0 0 0 1px var(--line); font-weight: 600; }
button.hl-topic:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.hl-title { display: block; margin: 0; font: 600 14.5px/1.4 var(--head); color: var(--fg); text-decoration: none; }
.hl-title:hover { text-decoration: underline; }
.hl-tier { color: var(--muted); letter-spacing: -1px; font-size: 9px; }
.hl-p:not(.major) .hl-title { font-weight: 500; }
.hl-lead { display: flex; flex-direction: column; gap: 6px; margin: 0 0 16px; padding: 12px 14px 4px; border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 10px; background: var(--panel-2); }
.hl-lead .xf-p { border: 0; padding: 0 0 8px; margin: 0; background: none; }
.hl-lead .hl-title { font-size: 16px; }

/* ---------- The signal cards' two lists (Voices on X, Headlines, Insider trades, SEC filings) ---------- */
/* Each column is as tall as its header and about five rows of the left list; its list scrolls inside, with a slim scrollbar
   that is always there to say so, and a soft fade at an edge with more beyond it. A "Show more" button at the end of a list
   loads the next page once it is scrolled into view (keepScroll in signal-ui.js). */
.xf { --xf-col-h: 552px; --xf-bar: 12px; }
.xf-col { display: flex; flex-direction: column; min-width: 0; max-height: var(--xf-col-h); }
.xf-col > .xf-colh { flex: none; }
.xf-vlist, .xf-plist {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; padding-right: 6px;
  --ft: 0px; --fb: 0px;
  -webkit-mask: linear-gradient(#000 0 0) right / var(--xf-bar) 100% no-repeat, linear-gradient(to bottom, transparent 0, #000 var(--ft), #000 calc(100% - var(--fb)), transparent 100%) left / calc(100% - var(--xf-bar)) 100% no-repeat;
  mask: linear-gradient(#000 0 0) right / var(--xf-bar) 100% no-repeat, linear-gradient(to bottom, transparent 0, #000 var(--ft), #000 calc(100% - var(--fb)), transparent 100%) left / calc(100% - var(--xf-bar)) 100% no-repeat;
}
.xf-vlist.more-above, .xf-plist.more-above { --ft: 18px; }
.xf-vlist.more-below, .xf-plist.more-below { --fb: 28px; }
.xf-plist > .xf-more { flex: none; margin: 2px auto 6px; }
.xf-vlist::-webkit-scrollbar, .xf-plist::-webkit-scrollbar { width: var(--xf-bar); }
.xf-vlist::-webkit-scrollbar-track, .xf-plist::-webkit-scrollbar-track { background: color-mix(in srgb, var(--line) 55%, transparent); border: 4px solid var(--panel); border-radius: 99px; }
.xf-vlist::-webkit-scrollbar-thumb, .xf-plist::-webkit-scrollbar-thumb { min-height: 44px; background: color-mix(in srgb, var(--muted) 42%, transparent); border: 3px solid transparent; border-radius: 99px; background-clip: padding-box; }
.xf-vlist:hover::-webkit-scrollbar-thumb, .xf-plist:hover::-webkit-scrollbar-thumb { background-color: color-mix(in srgb, var(--muted) 70%, transparent); }
.xf-vlist::-webkit-scrollbar-thumb:active, .xf-plist::-webkit-scrollbar-thumb:active { background-color: var(--fg); }
.xf-vlist::-webkit-scrollbar-button, .xf-plist::-webkit-scrollbar-button { display: none; height: 0; }
@supports not selector(::-webkit-scrollbar) { .xf-vlist, .xf-plist { scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--muted) 55%, transparent) transparent; } }
/* On a touch screen, reaching the end of a list carries on scrolling the page. */
@media (hover: none) { .xf-vlist, .xf-plist { overscroll-behavior-y: auto; } }
/* One column at a time below 980px (the Posts/Voices style tabs choose which); this follows the flex rule above. */
@media (max-width: 980px) { .xf-col:not(.on) { display: none; } }
@media (max-width: 640px) { .xf { --xf-col-h: min(552px, 74vh); } }

/* ---------- Radio: the page ---------- */
/* The stage: one live channel big on its own brand colour, with every channel's logo under it. */
.rx-hero { --brand: #1f2937; position: relative; overflow: hidden; border-radius: var(--r); color: #fff; padding: 28px 28px 20px;
  background: radial-gradient(130% 160% at 0% 0%, color-mix(in srgb, var(--brand) 80%, #0b0f14) 0%, color-mix(in srgb, var(--brand) 32%, #0b0f14) 48%, #0b0f14 100%);
  box-shadow: 0 18px 40px -26px color-mix(in srgb, var(--brand) 80%, transparent); }
.rx-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(115deg, transparent 45%, rgba(255, 255, 255, .05) 62%, transparent 78%); pointer-events: none; }
.rx-stage { position: relative; z-index: 1; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 26px; align-items: center; }
.rx-plate { display: inline-grid; place-items: center; width: 64px; height: 44px; padding: 6px 8px; border-radius: 10px; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .14); flex: none; box-sizing: border-box; }
.rx-plate img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.rx-plate.lg { width: 176px; height: 120px; padding: 18px 20px; border-radius: 16px; box-shadow: 0 12px 32px -14px rgba(0, 0, 0, .7); }
.rx-on { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.rx-tag { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rx-live { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: #e5484d; color: #fff; font: 800 11px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.rx-live i { width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.rx-live.part { background: rgba(255, 255, 255, .16); }
@media (prefers-reduced-motion: no-preference) { .rx-live:not(.part) i { animation: lpdot 1.4s ease-in-out infinite; } }
.rx-by { font-size: 13px; color: rgba(255, 255, 255, .72); }
.rx-name { margin: 0; font: 700 clamp(24px, 3vw, 34px)/1.1 var(--head); letter-spacing: -.01em; color: #fff; }
.rx-about { margin: 0; max-width: 60ch; font-size: 14.5px; line-height: 1.5; color: rgba(255, 255, 255, .8); }
.rx-act { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; margin-top: 6px; }
.rx-watch { all: unset; box-sizing: border-box; display: inline-flex; align-items: center; gap: 9px; height: 46px; padding: 0 22px 0 18px; border-radius: 999px; background: #fff; color: #0b0f14; font: 700 15px var(--sans); cursor: pointer; box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .6); transition: transform .12s; }
.rx-watch:hover { transform: translateY(-1px); }
.rx-watch:active { transform: none; }
.rx-watch .lp-ic { width: 18px; height: 18px; }
.rx-ghost { all: unset; box-sizing: border-box; height: 40px; padding: 0 16px; display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .35); color: #fff; font: 600 13.5px var(--sans); cursor: pointer; }
.rx-ghost:hover { background: rgba(255, 255, 255, .1); }
.rx-watch:focus-visible, .rx-ghost:focus-visible, .rx-ch:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.rx-hours { font-size: 12.5px; color: rgba(255, 255, 255, .65); }
.rx-note { grid-column: 1 / -1; margin: 8px 0 0; font-size: 12px; color: rgba(255, 255, 255, .55); display: flex; align-items: center; gap: 6px; }
.rx-note .help { color: inherit; border-color: rgba(255, 255, 255, .35); background: transparent; }
.rx-chs { position: relative; z-index: 1; display: flex; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .12); overflow-x: auto; scrollbar-width: none; }
.rx-chs::-webkit-scrollbar { display: none; }
.rx-ch { all: unset; box-sizing: border-box; position: relative; display: flex; align-items: center; gap: 10px; flex: none; padding: 8px 14px 8px 8px; border-radius: 14px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); cursor: pointer; transition: background .15s, border-color .15s, transform .12s; }
.rx-ch:hover { background: rgba(255, 255, 255, .13); transform: translateY(-1px); }
.rx-ch[aria-pressed="true"] { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .5); }
.rx-ch.on { border-color: #fff; }
.rx-chn { display: flex; flex-direction: column; line-height: 1.25; }
.rx-chn b { font: 600 13.5px var(--sans); color: #fff; }
.rx-chn small { font-size: 11.5px; color: rgba(255, 255, 255, .6); }
.rx-eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.rx-eq i { width: 3px; height: 5px; border-radius: 2px; background: currentColor; }
.rx-eq i:nth-child(2) { height: 11px; } .rx-eq i:nth-child(3) { height: 8px; } .rx-eq i:nth-child(4) { height: 13px; }
@media (prefers-reduced-motion: no-preference) {
  body.radio-playing .rx-eq i { animation: eqb .9s ease-in-out infinite alternate; }
  body.radio-playing .rx-eq i:nth-child(2) { animation-duration: .7s; animation-delay: -.2s; }
  body.radio-playing .rx-eq i:nth-child(3) { animation-duration: 1.1s; animation-delay: -.5s; }
  body.radio-playing .rx-eq i:nth-child(4) { animation-duration: .8s; animation-delay: -.35s; }
}
.rx-ch .rx-eq { color: #fff; margin-left: 2px; }
.rx-mark { display: inline-grid; place-items: center; background: hsl(var(--h, 210) 38% 44%); color: #fff; font: 700 14px/1 var(--sans); border-radius: 10px; }

/* Continue listening: what you were part-way through. */
.rx-resume[hidden] { display: none; }
.rx-h2 { margin: 2px 0 10px; }
.rx-cards { display: flex; gap: 12px; overflow-x: auto; padding: 2px 2px 8px; scrollbar-width: thin; }
.rx-card { all: unset; box-sizing: border-box; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; width: 320px; flex: none; padding: 10px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.rx-card:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); box-shadow: var(--shadow); }
.rx-card.on { border-color: var(--accent); }
.rx-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.rx-cardart, .rx-cover, .rx-epart { position: relative; display: block; }
.rx-cimg { width: 100%; aspect-ratio: 1; height: auto; border-radius: 10px; object-fit: cover; display: block; box-shadow: 0 0 0 1px var(--line); }
.rx-cardart { width: 64px; }
.rx-cardt { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.rx-cardt b { font: 600 13.5px/1.3 var(--head); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rx-cardt small { font-size: 12px; color: var(--muted); }
.rx-prog { display: block; height: 3px; border-radius: 3px; background: linear-gradient(var(--accent), var(--accent)) left / var(--p, 0%) 100% no-repeat, var(--line); }
.rx-cardt .rx-prog { margin-top: 4px; }
/* The play mark over cover art. */
.rx-cplay { position: absolute; inset: 0; display: grid; place-items: center; border-radius: 10px; background: rgba(0, 0, 0, .38); color: #fff; opacity: 0; transition: opacity .15s; }
.rx-cplay .lp-ic { width: 22px; height: 22px; }
.rx-card:hover .rx-cplay, .rx-card.on .rx-cplay, .rx-epart:hover .rx-cplay, .rx-ep.on .rx-cplay { opacity: 1; }

/* Podcasts: the shows as covers by kind, then the episodes. */
.rx-pods { display: flex; flex-direction: column; gap: 12px; }
.rx-podh { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.rx-shelf { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 12px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.rx-show { all: unset; box-sizing: border-box; display: flex; flex-direction: column; gap: 6px; width: 112px; flex: none; cursor: pointer; scroll-snap-align: start; }
.rx-cover { width: 112px; transition: transform .15s; }
.rx-cover .rx-cimg { border-radius: 14px; box-shadow: 0 0 0 1px var(--line), 0 6px 16px -10px rgba(15, 20, 26, .5); }
.rx-show:hover .rx-cover { transform: translateY(-2px); }
.rx-show[aria-pressed="true"] .rx-cimg { box-shadow: 0 0 0 2.5px var(--accent), 0 6px 16px -10px rgba(15, 20, 26, .5); }
.rx-show b { font: 600 12.5px/1.3 var(--head); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rx-show small { font-size: 11.5px; color: var(--muted); margin-top: -3px; }
.rx-show:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 14px; }
.rx-onair { position: absolute; right: 6px; bottom: 6px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); }
.rx-showcard { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 16px; align-items: center; padding: 14px; border-radius: 14px; background: var(--panel-2); }
.rx-scimg { width: 88px; height: 88px; border-radius: 12px; object-fit: cover; box-shadow: 0 0 0 1px var(--line); }
.rx-sct { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.rx-sct small { font-size: 12px; color: var(--muted); }
.rx-sct b { font: 700 18px/1.25 var(--head); }
.rx-scact { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.rx-scact .btn { display: inline-flex; align-items: center; gap: 4px; }
.rx-eph { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.rx-h3 { margin: 0 auto 0 0; font: 600 15px var(--head); }
.rx-mine { display: inline-flex; align-items: center; gap: 6px; }
.rx-mine[disabled] { opacity: .5; cursor: default; }
.rx-n { font-size: 11px; opacity: .75; }
.rx-q { width: min(240px, 100%); }
.rx-list { max-height: 640px; gap: 0; }
.rx-ep { display: grid; grid-template-columns: 72px minmax(0, 1fr) 44px; gap: 14px; align-items: center; padding: 12px 8px; border-top: 1px solid var(--line); transition: background .15s; }
.rx-ep:first-child { border-top: 0; }
.rx-ep:hover { background: var(--panel-2); border-radius: 12px; }
.rx-ep.on { background: color-mix(in srgb, var(--accent) 8%, var(--panel)); border-radius: 12px; }
.rx-ep.done .rx-ept { color: var(--muted); }
.rx-epart { all: unset; position: relative; display: block; width: 72px; cursor: pointer; }
.rx-epart .rx-cimg { border-radius: 12px; }
.rx-epm { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.rx-eps { font-size: 12px; color: var(--muted); }
.rx-eps b { color: var(--fg); font-weight: 600; }
.rx-ept { font: 600 14.5px/1.35 var(--head); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rx-epsum { margin: 0; font-size: 12.5px; line-height: 1.45; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rx-epx { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 4px; }
.rx-epx a { text-decoration: none; }
.rx-left { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--accent); font-weight: 600; }
.rx-left .rx-prog { width: 80px; }
.rx-played { font-size: 12px; color: var(--muted); }
.rx-epbtn { all: unset; box-sizing: border-box; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line); color: var(--fg); cursor: pointer; transition: background .15s, border-color .15s, color .15s; }
.rx-epbtn:hover { border-color: var(--accent); color: var(--accent); }
.rx-epbtn.playing { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.rx-epbtn .lp-ic { width: 17px; height: 17px; }
.rx-epbtn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (max-width: 640px) {
  .rx-hero { padding: 20px 18px 16px; }
  .rx-stage { grid-template-columns: minmax(0, 1fr); }
  .rx-plate.lg { width: 132px; height: 88px; padding: 12px 14px; }
  .rx-podh .seg { flex-wrap: nowrap; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
  .rx-podh .seg button { flex: none; }
  .rx-q { width: 100%; }
  .rx-ep { grid-template-columns: 56px minmax(0, 1fr) 40px; gap: 10px; }
  .rx-epart { width: 56px; }
  .rx-epbtn { width: 40px; height: 40px; }
  .rx-card { width: 270px; }
}

/* ---------- Radio: the player in the corner ---------- */
/* One card: what is playing and from whom at the top (with minimize and close), then the episode or the live picture, a
   seek bar with the time on each side, and the controls centred under it. */
.lp { position: fixed; right: 20px; bottom: 20px; z-index: 26; width: min(380px, calc(100vw - 40px)); display: flex; flex-direction: column; gap: 10px; padding: 12px 14px 14px;
  border: 1px solid var(--line); border-radius: 16px; background: var(--panel); box-shadow: var(--pop); }
.lp[hidden] { display: none; }
@media (prefers-reduced-motion: no-preference) { .lp { animation: lpin .18s ease-out; } @keyframes lpin { from { opacity: 0; transform: translateY(8px); } } }
body.radio-on .view { padding-bottom: 150px; }
.lp-h { display: flex; align-items: center; gap: 8px; min-width: 0; }
.lp-kind { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; border-radius: 999px; background: var(--panel-2); color: var(--muted); font: 700 10.5px/1.2 var(--sans); letter-spacing: .06em; text-transform: uppercase; flex: none; }
.lp-kind.live { background: color-mix(in srgb, var(--down) 14%, var(--panel)); color: var(--down); }
.lp-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
@media (prefers-reduced-motion: no-preference) { body.radio-playing .lp-dot { animation: lpdot 1.4s ease-in-out infinite; } @keyframes lpdot { 50% { opacity: .35; } } }
.lp-from { flex: 1; min-width: 0; color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lp-b { all: unset; box-sizing: border-box; display: inline-grid; place-items: center; cursor: pointer; border-radius: 9px; color: var(--fg); flex: none; }
.lp-b:hover:not(:disabled) { background: var(--panel-2); }
.lp-b:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.lp-b:disabled { opacity: .35; cursor: default; }
.lp-h .lp-b { width: 30px; height: 30px; color: var(--muted); }
.lp-h .lp-b:hover { color: var(--fg); }
.lp-ic { width: 20px; height: 20px; display: block; }
.lp-ic.sm { width: 16px; height: 16px; }
.lp-ep { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 12px; align-items: center; }
.lp-art { width: 56px; height: 56px; border-radius: 11px; object-fit: cover; background: var(--panel-2); box-shadow: 0 0 0 1px var(--line); }
.lp-mark { display: grid; place-items: center; color: #fff; background: hsl(210 38% 44%); font: 700 14px/1 var(--sans); }
.lp-meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lp-title { font: 600 14px/1.3 var(--head); color: var(--fg); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lp-title:hover { text-decoration: underline; }
.lp-meta small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* YouTube's embedded player must stay at least 200 by 200 pixels. */
.lp-vf { position: relative; width: 100%; aspect-ratio: 16 / 9; min-height: 200px; border-radius: 10px; overflow: hidden; background: #000; }
.lp-vf iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.lp-restore { position: absolute; top: 6px; right: 6px; width: 30px; height: 30px; background: rgba(0, 0, 0, .55) !important; color: #fff !important; display: none; }
.lp-s { display: flex; flex-direction: column; gap: 4px; }
.lp-s.off { opacity: .45; }
.lp-times { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); min-height: 14px; }
.lp-left.is-live, .np-left.is-live { color: var(--down); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-size: 10.5px; }
.lp-seek, .np-seek { -webkit-appearance: none; appearance: none; width: 100%; height: 5px; border-radius: 5px; margin: 6px 0; cursor: pointer;
  background: linear-gradient(var(--accent), var(--accent)) left / var(--p, 0%) 100% no-repeat, var(--line); }
.lp-seek:disabled, .np-seek:disabled { cursor: default; }
.lp-seek::-webkit-slider-thumb, .np-seek::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%; background: var(--panel); border: 3px solid var(--accent); box-shadow: 0 1px 3px rgba(15, 20, 26, .25); transition: transform .12s; }
.lp-seek:hover::-webkit-slider-thumb, .np-seek:hover::-webkit-slider-thumb { transform: scale(1.2); }
.lp-seek::-moz-range-thumb, .np-seek::-moz-range-thumb { width: 10px; height: 10px; border-radius: 50%; background: var(--panel); border: 3px solid var(--accent); }
.lp-seek:focus-visible, .np-seek:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.lp-c { display: grid; grid-template-columns: 1fr auto auto auto 1fr; align-items: center; gap: 10px; }
.lp-cside { min-width: 1px; }
.lp-c > :first-child { justify-self: start; } .lp-c > :last-child { justify-self: end; }
.lp-skip { width: 40px; height: 40px; border-radius: 50%; }
.lp-skip .lp-ic { width: 26px; height: 26px; }
.lp-play { width: 52px; height: 52px; border-radius: 50%; background: var(--accent) !important; color: var(--accent-ink); box-shadow: 0 2px 8px color-mix(in srgb, var(--accent) 35%, transparent); }
.lp-play:hover { background: color-mix(in srgb, var(--accent) 86%, var(--fg)) !important; }
.lp-play .lp-ic { width: 22px; height: 22px; }
.lp-rate { min-width: 46px; height: 30px; padding: 0 9px; border: 1px solid var(--line); border-radius: 999px; font-size: 12.5px; font-weight: 600; }
.lp-golive { height: 30px; padding: 0 10px 0 8px; gap: 4px; grid-auto-flow: column; border: 1px solid color-mix(in srgb, var(--down) 45%, var(--line)); border-radius: 999px; color: var(--down); font-size: 12px; font-weight: 700; }
.lp-golive.at { border-color: var(--line); color: var(--muted); }
.lp-err { margin: 0; font-size: 12.5px; color: var(--down); }
/* Live TV: a slim bar (logo, Live, the channel, and minimize, size and close) over the picture. YouTube's own controls
   show on the picture itself. */
.lp.video { width: min(440px, calc(100vw - 40px)); padding: 8px; gap: 8px; }
.lp.video.big { width: min(900px, calc(100vw - 40px)); }
.lp-vh { padding: 0 0 0 2px; gap: 7px; }
.lp-logo { display: inline-grid; place-items: center; width: 42px; height: 26px; padding: 3px 5px; border-radius: 6px; background: #fff; box-shadow: 0 0 0 1px var(--line); box-sizing: border-box; flex: none; }
.lp-logo img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.lp-vh .lp-from { color: var(--fg); font-weight: 600; font-size: 13px; }
/* Minimized into the menu: only the picture, laid over the space kept for it under Radio. */
.lp.video.inpanel { right: auto; bottom: auto; z-index: 41; padding: 0; gap: 0; border: 0; border-radius: 10px; overflow: hidden; box-shadow: 0 0 0 1px var(--line); animation: none; }
/* The menu (Settings) opens over it while it is open. */
.lp.video.inpanel.under { z-index: 26; }
.lp.video.inpanel > :not(.lp-vf) { display: none; }
.lp.video.inpanel .lp-vf { height: 100%; aspect-ratio: auto; border-radius: 10px; }
/* Minimized live TV: only the picture, at the smallest size YouTube allows, with a button to bring the player back. */
.lp.video.mini { width: 360px; padding: 0; gap: 0; border-radius: 12px; overflow: hidden; }
.lp.video.mini > :not(.lp-vf) { display: none; }
.lp.video.mini .lp-vf { border-radius: 0; }
.lp.video.mini .lp-restore { display: grid; }

/* ---------- Radio: the equalizer and the controls under Radio in the menu ---------- */
.side-nav .eq { display: none; width: 20px; height: 20px; align-items: flex-end; justify-content: center; gap: 2px; padding-bottom: 3px; box-sizing: border-box; flex: none; color: var(--accent); }
.side-nav .eq i { display: block; width: 3px; border-radius: 2px; background: currentColor; height: 5px; }
.side-nav .eq i:nth-child(2) { height: 11px; } .side-nav .eq i:nth-child(3) { height: 8px; } .side-nav .eq i:nth-child(4) { height: 13px; }
body.radio-on .side-nav .radio-ic { display: none; }
body.radio-on .side-nav .eq { display: inline-flex; }
@media (prefers-reduced-motion: no-preference) {
  body.radio-playing .side-nav .eq i { animation: eqb .9s ease-in-out infinite alternate; }
  body.radio-playing .side-nav .eq i:nth-child(2) { animation-duration: .7s; animation-delay: -.2s; }
  body.radio-playing .side-nav .eq i:nth-child(3) { animation-duration: 1.1s; animation-delay: -.5s; }
  body.radio-playing .side-nav .eq i:nth-child(4) { animation-duration: .8s; animation-delay: -.35s; }
  @keyframes eqb { 0% { height: 3px; } 100% { height: 14px; } }
}
/* Under Radio in the menu, at the menu's own width: the cover or logo under the Radio icon, the title in line with the
   Radio label, then a thin seek line and small controls. Minimized live TV sits above them at the full width, 200 pixels
   tall (YouTube's minimum), with one compact row of controls under it. */
.side-np { margin: 0 0 6px; padding: 2px 0; display: flex; flex-direction: column; gap: 2px; }
.side-np[hidden] { display: none; }
.np-frame { margin: 2px 0 4px; width: 100%; height: 200px; border-radius: 10px; background: #000; }
.np-frame[hidden] { display: none; }
.np-body { display: flex; flex-direction: column; gap: 2px; }
.np-meta { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 7px; align-items: center; padding: 4px 6px 4px 5px; border-radius: 8px; color: var(--fg); text-decoration: none; min-width: 0; }
.np-meta:hover { background: var(--panel-2); }
.np-art { width: 30px; height: 30px; border-radius: 7px; object-fit: cover; box-shadow: 0 0 0 1px var(--line); font-size: 10px; }
.np-logo { display: grid; place-items: center; padding: 3px; background: #fff; box-sizing: border-box; }
.np-logo img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.np-live { display: grid; place-items: center; background: var(--down); color: #fff; font: 800 8.5px/1 var(--sans); letter-spacing: .06em; box-shadow: none; }
.np-text { display: flex; flex-direction: column; min-width: 0; }
.np-text b { font: 600 13px/1.3 var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-text small { display: flex; align-items: center; gap: 5px; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--down); flex: none; }
@media (prefers-reduced-motion: no-preference) { body.radio-playing .np-dot { animation: lpdot 1.4s ease-in-out infinite; } }
.np-s { padding: 0 6px 0 42px; }
.np-s.off { display: none; }
.np-s .np-seek { margin: 3px 0 1px; height: 3px; }
.np-seek::-webkit-slider-thumb { width: 11px; height: 11px; border-width: 2px; }
.np-times { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--muted); }
.np-c { display: flex; align-items: center; gap: 0; padding: 0 2px 0 4px; }
.np-gap { flex: 1; }
.np-b { all: unset; box-sizing: border-box; display: inline-grid; grid-auto-flow: column; place-items: center; gap: 3px; min-width: 28px; height: 30px; padding: 0 2px; border-radius: 8px; color: var(--muted); cursor: pointer; font-size: 11.5px; font-weight: 600; flex: none; }
.np-b:hover:not(:disabled) { background: var(--panel-2); color: var(--fg); }
.np-b:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.np-b:disabled { opacity: .35; cursor: default; }
.np-b[hidden] { display: none; }
.np-b .lp-ic { width: 17px; height: 17px; }
.np-play { width: 30px; height: 30px; padding: 0; border-radius: 50%; background: var(--accent) !important; color: var(--accent-ink) !important; margin-right: 3px; }
.np-play .lp-ic { width: 13px; height: 13px; }
.np-skip .lp-ic { width: 19px; height: 19px; }
.np-rate { padding: 0 5px; }
.np-golive { padding: 0 6px; color: var(--down); }
/* "Live" appears only once the stream is rewound behind live; at the live edge the row above already says Live. */
.np-golive.at { display: none; }
@media (pointer: coarse) { .np-b { min-width: 36px; height: 36px; } .np-play { width: 36px; height: 36px; } }
.np-cname { display: none; }
/* Minimized live TV: one row under the picture. */
.side-np.np-min .np-meta, .side-np.np-min .np-s { display: none; }
.side-np.np-min .np-golive span { display: none; }
.side-np.np-min .np-cname { display: block; flex: 1; min-width: 0; padding: 0 4px; font: 600 12.5px/30px var(--sans); color: var(--fg); text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-np.np-min .np-cname:hover { text-decoration: underline; }
.side-np.np-min .np-gap { display: none; }
/* While the volume slider is open, the row makes room for it. */
.np-c.vol-open :is(.np-skip, .np-rate, .np-golive, .np-cname) { display: none; }
.np-c.vol-open .np-gap { display: block; }
html.nav-min .side-np { display: none; }

/* Volume: a speaker that mutes on a press, with a slider that opens beside it on hover or focus. */
.np-vol, .lp-vol { display: inline-flex; align-items: center; flex: none; }
.np-vol-range, .lp-vol-range { -webkit-appearance: none; appearance: none; width: 0; height: 4px; margin: 0; padding: 0; border-radius: 4px; opacity: 0; cursor: pointer;
  background: linear-gradient(var(--fg), var(--fg)) left / var(--p, 100%) 100% no-repeat, var(--line); transition: width .18s ease, opacity .18s ease, margin .18s ease; }
.np-vol.open .np-vol-range, .lp-vol.open .lp-vol-range { width: 64px; opacity: 1; margin: 0 6px 0 4px; }
.side-np, .np-body, .np-c { min-width: 0; }
.np-vol-range::-webkit-slider-thumb, .lp-vol-range::-webkit-slider-thumb { -webkit-appearance: none; width: 11px; height: 11px; border-radius: 50%; background: var(--fg); border: 0; }
.np-vol-range::-moz-range-thumb, .lp-vol-range::-moz-range-thumb { width: 11px; height: 11px; border-radius: 50%; background: var(--fg); border: 0; }
.np-vol-range:focus-visible, .lp-vol-range:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.lp-vol .np-b { min-width: 34px; height: 34px; color: var(--fg); }
.lp-vol .np-b .lp-ic { width: 20px; height: 20px; }
@media (prefers-reduced-motion: reduce) { .np-vol-range, .lp-vol-range { transition: none; } }

/* The menu scrolls when a short window cannot show it all (the minimized picture is kept in view). */
.side-nav { overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; margin: 0 -12px; padding: 0 12px; scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--muted) 35%, transparent) transparent; }
html.nav-min .side-nav { overflow: visible; }
/* On the small picture in the menu, YouTube's own controls fall back to a cramped phone layout, so they are switched off
   there: the row under it has the controls, and a press on the picture brings it back to the corner. */
.lp.video.inpanel .lp-vf { cursor: pointer; }
.lp.video.inpanel .lp-vf iframe { pointer-events: none; }
/* On a phone the menu is a drawer: a dot on its button says something is playing. */
@media (prefers-reduced-motion: no-preference) { @keyframes npdot { 50% { transform: scale(.6); opacity: .5; } } }
body.radio-playing #menu-btn { position: relative; }
body.radio-playing #menu-btn::after { content: ''; position: absolute; top: 9px; right: calc(50% - 16px); width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--panel); animation: npdot 1.4s ease-in-out infinite; }
@media (max-width: 980px) {
  .lp, .lp.video, .lp.video.big { left: 8px; right: 8px; width: auto; bottom: calc(var(--mobile-nav-height, 0px) + 8px); }
  .lp.video.mini { left: auto; width: 300px; }
  body.radio-on .view { padding-bottom: calc(var(--mobile-nav-height, 0px) + 170px); }
}
@media (max-width: 640px) {
  .lp-ep { grid-template-columns: 48px minmax(0, 1fr); }
  .lp-art { width: 48px; height: 48px; }
  .lp.video.mini { width: min(356px, calc(100vw - 16px)); }
}


/* Comparison lines on the price chart: the market (S&P 500) and the sector, picked with the palette validator against the
   price line (green or red), the forecast blue and the two averages. Each also has its own dash. */
:root { --cmp-mkt: #d97706; --cmp-sec: #1baf7a; }

/* ---------- Market's pages under Market in the menu ---------- */
.side-sub { display: flex; flex-direction: column; gap: 1px; margin: 0 0 6px 30px; padding-left: 10px; border-left: 1px solid var(--line); }
.side-sub a { padding: 6px 10px; border-radius: 8px; font-size: 13px; color: var(--muted); text-decoration: none; }
.side-sub a:hover { color: var(--fg); background: var(--panel-2); }
.side-sub a[aria-current="page"] { color: var(--fg); font-weight: 600; background: var(--panel-2); }
html.nav-min .side-sub { display: none; }

/* ---------- Radar: the S&P 500 through a choice of lenses ---------- */
.rd-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; margin-bottom: 6px; }
.rd-lenses { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 12px; background: var(--panel-2); }
.rd-lens { all: unset; box-sizing: border-box; padding: 8px 14px; border-radius: 9px; font: 600 13.5px/1 var(--sans); color: var(--muted); cursor: pointer; }
.rd-lens:hover { color: var(--fg); }
.rd-lens[aria-selected="true"] { background: var(--panel); color: var(--fg); box-shadow: var(--shadow); }
.rd-lens:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.rd-status { font-size: 12.5px; }
.rd-q { margin: 6px 0 12px; color: var(--muted); font-size: 13.5px; max-width: 80ch; }
.rd-ctl { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-bottom: 12px; }
.rd-ctl .seg button { display: inline-flex; align-items: center; gap: 6px; }
.rd-n { font-size: 11px; opacity: .7; }
.rd-quick { margin: 0; }
.rd-find { margin-left: auto; width: 190px; }
.rd-t td.rd-sec .chipx { white-space: nowrap; }
.rd-t th button { white-space: nowrap; }
.rd-sectors tbody tr { cursor: pointer; }
.rd-bar { display: inline-grid; grid-template-columns: 70px auto; align-items: center; gap: 8px; }
.rd-bar i { display: block; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.rd-bar u { display: block; height: 100%; border-radius: 3px; background: var(--s1); }
.rd-bar b { font-weight: 500; font-size: 12.5px; }
.rd-nm { text-decoration: none; color: var(--fg); white-space: nowrap; }
.rd-nm:hover b { text-decoration: underline; }
/* The company (or sector) stays in view while a wide table is swiped sideways. */
.rd-t th:first-child, .rd-t td:first-child { position: sticky; left: 0; z-index: 1; background: var(--panel); }
@media (max-width: 900px) { .rd-t th:first-child, .rd-t td:first-child { box-shadow: inset -1px 0 0 var(--line); } }
@media (max-width: 640px) { .wl.tb.rd-t td:first-child { min-width: 0; } .rd-t td:first-child .co { max-width: 112px; white-space: nowrap; } .rd-sectors td:first-child { min-width: 112px; max-width: 132px; } }
@media (max-width: 640px) { .rd-find { margin-left: 0; width: 100%; } .rd-lens { padding: 8px 11px; } }

/* ---------- Portfolio: the round + and the New order window ---------- */
/* nvestra.ai's round +: an accent circle with a soft glow, top right of the page. */
.pf-add { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%; box-shadow: 0 6px 18px -8px color-mix(in srgb, var(--accent) 70%, transparent); transition: transform .12s, box-shadow .12s; }
.pf-add:hover { transform: translateY(-1px); box-shadow: 0 8px 22px -8px color-mix(in srgb, var(--accent) 80%, transparent); }
.pf-add:active { transform: none; }
.pf-add:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.pf-add-i { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; }
@media (max-width: 640px) { .pf-add { width: 40px; height: 40px; } .pf-add-i { width: 20px; height: 20px; } }
.pf-order-sides { display: flex; width: 100%; margin-bottom: 14px; }
.pf-order-sides button { flex: 1; padding: 9px 12px; font: 600 14px var(--sans); }
.pf-order-sides button.pf-side-buy[aria-pressed="true"] { background: var(--up); color: #fff; }
.pf-order-sides button.pf-side-sell[aria-pressed="true"] { background: var(--down); color: #fff; }
.pf-order .pf-order-f[hidden], .pf-order-cash[hidden] { display: none; }
.pf-order-last { color: var(--muted); font-size: 11.5px; min-height: 1.2em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-order-cash { margin-top: 12px; font-size: 13px; }
.pf-order-sum { margin: 12px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--panel-2); font-size: 13.5px; line-height: 1.45; }
.pf-order-sum:empty { display: none; }
.pf-order-sum.warn { background: var(--warn-soft); }
.pf-order .al-form { margin-top: 14px; }
.pf-order-more { margin: 14px 0 0; font-size: 12.5px; }
.pf-order-more button { all: unset; cursor: pointer; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.pf-order-more button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }
.sb-real { align-self: center; font-size: 13px; font-weight: 600; color: var(--accent); }
.pf-order .pf-order-wide { grid-column: 1 / -1; }
/* On a phone, Market is in the tab bar, so its pages sit in the More sheet under a caption of their own. */
@media (max-width: 900px) {
  .side-sub { margin: 0; padding: 0; border-left: 0; gap: 0; }
  .side-sub::before { content: "Market"; padding: 6px 12px 2px; font: 600 11px var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
  .side-sub a { display: flex; align-items: center; min-height: 46px; padding: 0 12px; font-size: 15px; color: var(--muted); }
}

/* ---------- Worth a look on your watchlist: one row per signal, with what it could mean ---------- */
.attn-h2 { align-items: flex-start; gap: 10px 16px; flex-wrap: wrap; }
.attn-sub { margin: 3px 0 0; font-size: 13px; }
.attn-chips { margin: 0; }
.attn-t { table-layout: auto; }
.attn-t th { text-align: left; }
.attn-t td { text-align: left; vertical-align: top; white-space: normal; padding-top: 12px; padding-bottom: 12px; }
.attn-co { white-space: nowrap; }
.attn-co .sym { display: block; font-family: var(--mono); font-weight: 600; color: var(--fg); text-decoration: none; }
.attn-co .sym:hover { text-decoration: underline; text-underline-offset: 3px; }
.attn-co .chg { display: inline-block; margin-top: 3px; font-size: 12px; }
.attn-kind { white-space: nowrap; }
.attn-what { min-width: 200px; max-width: 340px; font-size: 13.5px; line-height: 1.45; }
.attn-what a { color: var(--fg); text-decoration: none; }
.attn-what a:hover { text-decoration: underline; text-underline-offset: 3px; }
.attn-means { min-width: 240px; max-width: 440px; color: var(--muted); font-size: 13px; line-height: 1.45; }
.attn-when { white-space: nowrap; color: var(--muted); font-size: 12.5px; text-align: right !important; }
.attn-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 10px; }
.attn-foot .more { margin: 0; }
.attn-t { width: 100%; }
.attn-co, .attn-kind { width: 1%; }
@media (max-width: 640px) {
  .attn-t, .attn-t tbody { display: block; width: 100%; }
  .wl.tb.attn-t, .wl.tb.attn-t td:first-child { min-width: 0; }
  .attn-t thead { display: none; }
  .attn-t tr { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "co kind when" "what what what" "means means means"; align-items: center; gap: 6px 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .attn-t td { display: block; width: auto; padding: 0; border: 0; min-width: 0; max-width: none; }
  .attn-co { grid-area: co; display: flex !important; align-items: baseline; gap: 8px; }
  .attn-co .chg { margin: 0; }
  .attn-kind { grid-area: kind; }
  .attn-when { grid-area: when; }
  .attn-what { grid-area: what; }
  .attn-means { grid-area: means; }
}


/* ---------- The watchlist's filings, insider trades and headlines, on the overview ---------- */
.sig-feed { display: flex; flex-direction: column; min-width: 0; }
.sig-sum { margin: 3px 0 0; font-size: 13px; }
.sig-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; }
.sig-filters .chips { margin: 0; }
.sig-scroll { --xf-bar: 12px; max-height: 560px; }
.sig-results .row { grid-template-columns: 56px minmax(0, 1fr) 0 auto; }
.sig-results .sig-soon .chg { color: var(--s2); font-weight: 600; }
@media (max-width: 640px) { .sig-scroll { max-height: 70vh; } }
.mk-side { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
/* Two columns: the feed's list takes the height the column beside it sets, rather than its own 560 pixels. */
@media (min-width: 901px) {
  .view:not(.narrow) .sig-row .sig-scroll { flex: 1 1 0; min-height: 420px; max-height: none; }
  .view:not(.narrow) .sig-row .sig-scroll > .empty { margin: auto 0; }
}
.sig-results .nm { white-space: normal; overflow: visible; text-overflow: clip; }

/* ---------- Phone polish, to nvestra.ai's phone standard ---------- */
@media (max-width: 900px) {
  /* One set of sizes: buttons and tabs 38px, chips, segments and small buttons 34px, fields 40px. Round buttons stay
     round (a min-height alone stretches them into ovals). */
  .view :is(.btn, .tab) { min-height: 38px; }
  .view :is(.chip, .seg button, .btn.sm) { min-height: 34px; }
  .view :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]), select) { min-height: 40px; }
  .view :is(.btn.ib, .pf-add, .rx-epbtn) { min-height: 0; aspect-ratio: 1; flex: none; }
  .view, .mobile-nav, .side, .top { -webkit-tap-highlight-color: transparent; }
  .mobile-nav > :active .ic { background: var(--accent-soft); }
  /* A table that scrolls sideways shows a soft shadow at the edge where more columns wait. */
  .view .tblwrap { background:
    linear-gradient(90deg, var(--panel) 40%, transparent) left / 28px 100% no-repeat local,
    linear-gradient(270deg, var(--panel) 40%, transparent) right / 28px 100% no-repeat local,
    radial-gradient(farthest-side at 0 50%, color-mix(in srgb, var(--fg) 14%, transparent), transparent) left / 10px 100% no-repeat scroll,
    radial-gradient(farthest-side at 100% 50%, color-mix(in srgb, var(--fg) 14%, transparent), transparent) right / 10px 100% no-repeat scroll; }
  /* A tab strip wider than the screen fades at the edge where more tabs wait (fitTabs in app.js). */
  .tabs.fade-r { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); }
  .tabs.fade-l { -webkit-mask-image: linear-gradient(90deg, transparent, #000 36px); mask-image: linear-gradient(90deg, transparent, #000 36px); }
  .tabs.fade-l.fade-r { -webkit-mask-image: linear-gradient(90deg, transparent, #000 36px, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, transparent, #000 36px, #000 calc(100% - 36px), transparent); }
  /* Portfolio: the title on the left, Cards and the round + on the right, on one line. */
  .pf-heading { flex-wrap: nowrap; align-items: flex-start; gap: 12px; }
  .pf-toolbar { display: flex; width: auto; flex: none; gap: 8px; align-items: center; justify-content: flex-end; }
  .pf-toolbar > .btn, .pf-toolbar > div > .btn { width: auto; min-height: 40px; padding: 0 16px; border-radius: 999px; font-weight: 600; }
  .pf-toolbar .pf-add { width: 40px; height: 40px; padding: 0; }
}
@media (max-width: 640px) {
  /* Chip rows are one swipeable line that fades out where more chips wait. */
  .view .chips { flex-wrap: nowrap; max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; padding: 1px 24px 1px 1px;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .view .chips::-webkit-scrollbar { display: none; }
  .view .chips > * { flex: none; }
  /* Segmented controls: up to four parts share the full width; five or more scroll in one line. */
  .view .seg:not(:has(> :nth-child(5))) { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); width: 100%; box-sizing: border-box; }
  .view .seg:not(:has(> :nth-child(5))) > button { padding-inline: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .view .seg:has(> :nth-child(5)) { display: flex; flex-wrap: nowrap; max-width: 100%; overflow-x: auto; scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .view .seg:has(> :nth-child(5)) > button { flex: none; }
  .view .seg:has(> :nth-child(5))::after { content: ""; flex: none; width: 22px; }
  /* A lone last tile in a two-column grid takes the full width. */
  .view .kpis > :last-child:nth-child(odd) { grid-column: 1 / -1; }
  /* Summary strips swipe sideways instead of stacking: the room at the top of each signal card and the watchlist's
     headlines, and the verdict tiles at the top of a company page. */
  .xf-room, .rd-grid { display: grid; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 84%; overflow-x: auto; overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 2px; }
  .xf-room { margin-inline: -14px; padding-inline: 14px; scroll-padding-inline: 14px; }
  .rd-grid { margin-inline: -12px; padding-inline: 12px; scroll-padding-inline: 12px; }
  .xf-room::-webkit-scrollbar, .rd-grid::-webkit-scrollbar { display: none; }
  .xf-room > *, .rd-grid > * { scroll-snap-align: start; min-width: 0; }
  /* Market: shorter index tiles. */
  .mk-tile { padding: 12px 12px 10px; }
  .mk-tile svg { flex: none; height: 34px; min-height: 34px; }
  /* The watchlist's filings feed: chips on one line, the company picker beside Notable only. */
  .sig-filters .chips { flex: 1 1 100%; }
  .sig-filters .sel { flex: 1 1 auto; }
  /* Radar: the six lenses as a three-by-two grid; the sector column gives way (the sector picker filters by it). */
  .rd-lenses { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; box-sizing: border-box; }
  .rd-lens { text-align: center; padding: 9px 4px; }
  .rd-lens:last-child:nth-child(3n + 1) { grid-column: 1 / -1; }
  .rd-ctl .sel { flex: 1 1 100%; }
  .rd-t:not(.rd-sectors) :is(th, td):nth-child(2) { display: none; }
  /* Watchlist: the title on its own line and the add box under it at full width; the table keeps the company, price,
     the day's move, today's line and remove (the change in dollars and both ranges give way). */
  .pg-h:has(.watch-search) { flex-wrap: wrap; }
  .view[data-page="watchlist"] > .pg-h > .pg-side, .pg-h .watch-search { flex: 1 1 100%; width: 100%; max-width: none; }
  .watch-scroll table :is(th, td):is(:nth-child(2), :nth-child(4), :nth-child(5), :nth-child(6), :nth-child(7), :nth-child(8), :nth-child(9)) { display: none; }
  /* On a phone each row is the company with its call beside the ticker, then the price over the day's move. */
  .watch-scroll .wl { min-width: 0; }
  .watch-scroll .wl-pxm { display: block; margin-bottom: 3px; text-align: right; font-size: 13.5px; font-weight: 600; }
  .watch-scroll .wl-callm { display: inline-flex; }
  .watch-scroll td:first-child .co { max-width: 52vw; white-space: nowrap; }
  /* Portfolio: the chart's tickers swipe, fading at the edge. */
  .pf-chart-legend { scrollbar-width: none; padding-right: 24px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .pf-chart-legend::-webkit-scrollbar { display: none; }
  /* Radio: the channel strip, show covers and continue-listening cards fade at the edge; one-line episode details. */
  .rx-chs, .rx-shelf, .rx-cards { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 32px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 32px), transparent); }
  .rx-chs::after, .rx-shelf::after, .rx-cards::after { content: ""; flex: none; width: 18px; }
  .rx-eps { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  /* Signal cards: the column header wraps cleanly (title and count, then the lean filter at full width). */
  .xf-colh { flex-wrap: wrap; row-gap: 8px; }
  .xf-colh .seg { flex: 1 1 100%; order: 5; }
}
@media (max-width: 640px) { .rd-ctl .seg button { justify-content: center; } }
@media (max-width: 640px) { .mk-p { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; } }
/* ---------- Calls: Buy, Wait, Hold or Sell against an S&P 500 fund (calls.js) ---------- */
:root { --cl-buy-bg: color-mix(in srgb, var(--up) 12%, var(--panel)); --cl-sell-bg: color-mix(in srgb, var(--down) 10%, var(--panel)); }
/* The chip: the word carries the meaning; the tint says whether it asks you to act. */
.cl-chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; font: 600 12.5px/1 var(--sans); white-space: nowrap; background: var(--panel-2); color: var(--fg); }
.cl-chip b { font-weight: 700; letter-spacing: .01em; }
.cl-chip .num { font-weight: 600; opacity: .78; }
.cl-chip.sm { height: 23px; padding: 0 8px; font-size: 12px; gap: 5px; }
.cl-chip.cl-buy { background: var(--cl-buy-bg); color: var(--up); }
.cl-chip.cl-hold { background: var(--panel); color: var(--up); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--up) 45%, transparent); }
.cl-chip.cl-sell { background: var(--cl-sell-bg); color: var(--down); }
.cl-chip.cl-none { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--line); }
.cl-chip.cl-bench { background: var(--accent-soft); color: var(--accent); }
/* Risk: five steps in one hue, filled to the company band. */
.cl-risk { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; white-space: nowrap; color: var(--fg); }
.cl-steps { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.cl-steps i { width: 4px; border-radius: 1.5px; background: var(--line); }
.cl-steps i:nth-child(1) { height: 6px; } .cl-steps i:nth-child(2) { height: 8px; } .cl-steps i:nth-child(3) { height: 10px; } .cl-steps i:nth-child(4) { height: 12px; } .cl-steps i:nth-child(5) { height: 14px; }
.cl-risk.b0 .on, .cl-risk.b1 .on { background: color-mix(in srgb, var(--s2) 45%, var(--panel)); }
.cl-risk.b2 .on { background: color-mix(in srgb, var(--s2) 70%, var(--panel)); }
.cl-risk.b3 .on, .cl-risk.b4 .on { background: var(--s2); }
.wl-call, .wl-risk { white-space: nowrap; }
.wl-pxm, .wl-callm { display: none; }
.wl-symrow { display: flex; align-items: center; gap: 7px; }
.wl-callm .cl-chip.sm { height: 19px; padding: 0 6px; font-size: 11px; gap: 4px; }

/* The call card at the top of a company overview. */
.cl-eye { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.cl-eye > span:first-child { color: var(--fg); font-weight: 700; letter-spacing: .02em; }
.cl-verdict { display: flex; align-items: flex-end; gap: 18px; margin: 12px 0 14px; }
.cl-line { margin: 14px 0 6px; font-size: 15px; font-weight: 600; line-height: 1.4; }
.cl-why { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.5; max-width: 62ch; }
.cl-why a, .cl-foot a { color: var(--accent); font-weight: 600; }
.cl-sub { margin: 0 0 8px; font: 600 12.5px/1.3 var(--sans); color: var(--muted); }
.cl-st { display: inline-block; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 8px; background: var(--panel-2); color: var(--muted); white-space: nowrap; }
.cl-st.champ { background: var(--accent-soft); color: var(--accent); }
.cl-st.pos { background: var(--cl-buy-bg); color: var(--up); }

/* Market: one line about the call of the day. */
.cl-mk { display: flex; align-items: center; gap: 14px; padding: 13px 18px; color: var(--fg); text-decoration: none; }
.cl-mk:hover { background: color-mix(in srgb, var(--panel-2) 60%, var(--panel)); }
.cl-mk-badge { flex: none; font: 700 11px/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 6px 10px; }
.cl-mk-t { flex: 1; min-width: 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.cl-mk-t b { color: var(--fg); }
.cl-mk-mine { flex: none; font-size: 12.5px; font-weight: 600; color: var(--down); background: var(--cl-sell-bg); border-radius: 999px; padding: 4px 10px; white-space: nowrap; }
.cl-mk-go { flex: none; color: var(--muted); font-size: 18px; }

/* The Calls page. */
.cl-hero { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 20px 32px; padding: 22px 24px; }
.cl-hero .cl-eye { font-weight: 600; }
.cl-hero-h { margin: 6px 0 10px; font: 700 34px/1.05 var(--head); letter-spacing: -.025em; }
.cl-hero-t p { margin: 0 0 8px; max-width: 64ch; line-height: 1.55; }
.cl-hero-k { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; align-content: start; }
.cl-k { background: var(--panel-2); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.cl-k b { font: 600 30px/1 var(--sans); letter-spacing: -.01em; }
.cl-k span { font-weight: 600; font-size: 13px; }
.cl-k small { color: var(--muted); font-size: 12px; }
.cl-board td { vertical-align: top; padding-top: 12px; padding-bottom: 12px; }
.cl-board th.num, .cl-board td.num { text-align: right; }
.cl-board td.num b { font-size: 15px; }
.cl-board td.num .cl-st { display: block; width: max-content; margin: 5px 0 0 auto; }
.cl-who b { font-size: 14px; }
.cl-who .cl-st { margin-left: 8px; }
.cl-who small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.45; white-space: normal; max-width: 52ch; }
.cl-champ td { background: color-mix(in srgb, var(--accent) 4%, var(--panel)); }
.cl-said { min-width: 170px; }
.cl-board th:nth-child(2), .cl-board td.cl-said { text-align: left; }
.cl-bar { display: flex; gap: 2px; width: 160px; height: 10px; border-radius: 5px; overflow: hidden; background: var(--panel-2); }
.cl-bar i { min-width: 2px; }
.cl-bar .b { background: var(--up); } .cl-bar .n { background: color-mix(in srgb, var(--muted) 45%, var(--panel)); } .cl-bar .t { background: var(--down); } .cl-bar .x { background: var(--line); }
.cl-said small { display: block; margin-top: 5px; font-size: 11.5px; }
.cl-note { margin: 12px 0 0; font-size: 12px; color: var(--muted); line-height: 1.5; max-width: 110ch; }
.cl-charts .sub { margin: 0 0 10px; font-size: 13px; color: var(--muted); line-height: 1.5; }
.cl-yc { width: 100%; }
.cl-svg { display: block; width: 100%; height: auto; overflow: visible; }
.cl-grid { stroke: var(--line); stroke-width: 1; }
.cl-coin { stroke: var(--muted); stroke-width: 1.25; stroke-dasharray: 4 4; }
.cl-ax { fill: var(--muted); font: 11px var(--sans); }
.cl-coin-t { font-weight: 600; }
.cl-val { fill: var(--fg); font: 600 11px var(--sans); }
.cl-b rect { fill: var(--s1); }
.cl-b.low rect { fill: color-mix(in srgb, var(--s1) 40%, var(--panel)); }
.cl-b:hover rect { filter: brightness(1.12); }
.cl-rk rect { fill: var(--s2); }
.cl-rk.b0 rect, .cl-rk.b1 rect { fill: color-mix(in srgb, var(--s2) 45%, var(--panel)); }
.cl-rk.b2 rect { fill: color-mix(in srgb, var(--s2) 70%, var(--panel)); }
.cl-dl { display: grid; grid-template-columns: minmax(130px, 190px) minmax(0, 1fr); gap: 12px 24px; margin: 0; }
.cl-dl dt { font-weight: 700; font-size: 13.5px; }
.cl-dl dd { margin: 0; font-size: 13.5px; line-height: 1.55; max-width: 82ch; }
.cl-foot { margin: 0; font-size: 13px; color: var(--muted); }
/* Radar Calls lens: a contender view with its detail under it. */
.rd-op .rd-sm { display: block; margin-top: 3px; font-size: 11px; white-space: nowrap; }
@media (max-width: 900px) {
  .cl-hero { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .cl-line { font-size: 14.5px; }
  .cl-mk { flex-wrap: wrap; gap: 8px 10px; padding: 12px 14px; }
  .cl-mk-t { flex-basis: 100%; order: 3; }
  .cl-mk-go { margin-left: auto; }
  .cl-hero { padding: 18px 16px; }
  .cl-hero-h { font-size: 28px; }
  .cl-hero-k { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cl-hero-k .cl-k:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .cl-k b { font-size: 26px; }
  .cl-dl { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  /* The contenders as cards: who, what it says today, then its records side by side. */
  table.wl.cl-board { min-width: 0; }
  .cl-board thead { display: none; }
  .cl-board, .cl-board tbody { display: block; }
  .cl-board tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
  .cl-board tr:last-child { border-bottom: 0; }
  .cl-board td { display: block; padding: 0 !important; border: 0 !important; text-align: left !important; background: none !important; }
  .cl-board td.cl-who, .cl-board td.cl-said, .cl-board td.num:last-child { grid-column: 1 / -1; }
  .cl-board td { white-space: normal; }
  .cl-board td.num::before { content: attr(data-label); display: block; margin-bottom: 3px; font-size: 11px; font-weight: 600; color: var(--muted); }
  .cl-board td.num .cl-st { margin: 5px 0 0; }
  .cl-board tr.cl-champ { padding: 14px 12px; border-radius: 10px; border-bottom: 0; background: color-mix(in srgb, var(--accent) 5%, var(--panel)); }
  .cl-bar { width: 100%; }
  .cl-dl dd { margin-bottom: 10px; }
}
/* ---------- The AI analyst on the overview (ai-card.js) ---------- */
.aa .panel-h { align-items: center; }
.aa-when { font-size: 12px; }
.aa-when span[title] { text-decoration: underline dotted; cursor: help; }
.aa-note { margin: 4px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.aa-input { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 28px; align-items: center; background: var(--panel-2); border-radius: 12px; padding: 16px 18px; }
.aa-in-t { font-size: 15px; }
.aa-reads { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; padding: 0; }
.aa-reads li { font-size: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.aa-go { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; text-align: right; }
.aa-go small { font-size: 12px; }
.aa-run { background: var(--panel-2); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; font-size: 13px; }
.aa-run-h { display: flex; justify-content: space-between; gap: 12px; font-size: 13.5px; flex-wrap: wrap; }
.aa-prog { position: relative; height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.aa-prog i { position: absolute; top: 0; bottom: 0; left: -30%; width: 30%; border-radius: 2px; background: var(--accent); animation: aa-slide 1.6s ease-in-out infinite; }
@keyframes aa-slide { to { left: 100%; } }
@media (prefers-reduced-motion: reduce) { .aa-prog i { animation: none; left: 0; width: 40%; } }
.aa-head { margin: 0 0 14px; font: 600 16px/1.45 var(--sans); max-width: 82ch; }
.aa-verdict { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 20px; }
.aa-v { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; background: var(--panel-2); border-radius: 12px; padding: 12px 14px; min-width: 0; }
.aa-k { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.aa-v b { font: 600 22px/1.1 var(--sans); letter-spacing: -.01em; }
.aa-v small { font-size: 12px; }
.aa-v .ev-pill { font-size: 13px; padding: 3px 10px; margin-top: 2px; }
.aa-dots { display: inline-flex; gap: 4px; margin: 6px 0 2px; }
.aa-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.aa-dots i.on { background: var(--accent); }
.aa-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 18px 32px; }
.aa-sub { margin: 0 0 10px; font: 600 12.5px/1.3 var(--sans); color: var(--muted); }
.aa-sc-bar { display: flex; gap: 2px; height: 10px; border-radius: 5px; overflow: hidden; }
.aa-sc-bar .sc-bear { background: var(--down); } .aa-sc-bar .sc-base { background: color-mix(in srgb, var(--muted) 55%, var(--panel)); } .aa-sc-bar .sc-bull { background: var(--up); }
.aa-sc-row { display: flex; gap: 12px; margin-top: 9px; }
.aa-sc-c { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.aa-sc-c b { font-size: 13px; }
.aa-sc-c > .num { font-size: 12.5px; white-space: nowrap; }
.aa-sc-c small { font-size: 12px; color: var(--muted); line-height: 1.45; }
.aa-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.aa-drv { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.aa-drv li { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 8px; align-items: start; }
.aa-dir { font-size: 11px; line-height: 20px; color: var(--s2); }
.aa-dir.helps { color: var(--up); } .aa-dir.hurts { color: var(--down); }
.aa-drv b { display: flex; align-items: center; gap: 7px; font-size: 13.5px; }
.aa-w { font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); background: var(--panel-2); border-radius: 999px; padding: 2px 7px; }
.aa-drv small { display: block; font-size: 12.5px; line-height: 1.45; color: var(--muted); }
.aa-drv small.aa-clamp, .aa-sc-c small.aa-clamp { display: -webkit-box; }
.aa-folds { margin-top: 18px; border-top: 1px solid var(--line); }
.aa-fold { border-bottom: 1px solid var(--line); }
.aa-fold summary { display: flex; align-items: center; gap: 10px; padding: 11px 2px; cursor: pointer; list-style: none; font-size: 13.5px; font-weight: 600; }
.aa-fold summary::-webkit-details-marker { display: none; }
.aa-fold summary > span:first-child { flex: 1; }
.aa-fold summary::after { content: "+"; width: 14px; text-align: center; color: var(--muted); font-weight: 400; font-size: 17px; line-height: 1; }
.aa-fold[open] summary::after { content: "−"; }
.aa-fold summary:hover > span:first-child { color: var(--accent); }
.aa-fold-b { padding: 0 2px 14px; font-size: 13.5px; line-height: 1.55; }
.aa-fold-b .ai-t { margin: 0; }
/* Two columns of folds (ui.js foldCols): side by side when each can be 380 pixels wide, stacked otherwise. Each column
   carries its own top rule, pulled up a pixel so a stacked pair shows one line between them. */
.aa-folds.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: 0 36px; align-items: start; border-top: 0; }
.aa-folds.two > .aa-col { min-width: 0; border-top: 1px solid var(--line); margin-top: -1px; }
.aa-folds.two > .aa-col:empty { display: none; }
/* In the AI analyst the two columns line up with its three cases and what matters most above them. */
.aa-find > .aa-folds.two { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 0 32px; }
.aa-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; }

/* ---------- What it trades like: the investing styles behind its own moves (stock.js stylesCard) ---------- */
.sty { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.45fr); gap: 20px 36px; align-items: start; }
.sty-lead { margin: 0 0 14px; font-size: 15px; line-height: 1.55; }
.sty-k { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sty-k > div { display: flex; flex-direction: column; gap: 3px; background: var(--panel-2); border-radius: 12px; padding: 12px 14px; }
.sty-k span { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.sty-k b { font: 600 22px/1.1 var(--sans); }
.sty-k small { font-size: 11.5px; color: var(--muted); }
.sty-m { height: 4px; margin: 5px 0 2px; border-radius: 2px; overflow: hidden; background: var(--line); }
.sty-m i { display: block; height: 100%; background: var(--s1); }
.sty-h, .sty-r { display: grid; grid-template-columns: minmax(130px, 1.2fr) 96px minmax(110px, 1.4fr) 62px; gap: 12px; align-items: center; }
.sty-h { padding-bottom: 7px; border-bottom: 1px solid var(--line); font-size: 11px; font-weight: 600; color: var(--muted); }
.sty-h > span:last-child, .sty-r > b.num { text-align: right; }
.sty-ax { display: flex; justify-content: space-between; }
.sty-r { padding: 8px 0; border-bottom: 1px solid var(--line); }
.sty-r:last-child { border-bottom: 0; }
.sty-r.rest { margin-top: 2px; border-top: 1px dashed var(--line); }
.sty-n { display: flex; flex-direction: column; min-width: 0; }
.sty-n b { font-size: 13.5px; }
.sty-n small { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sty-r.faint .sty-n b { font-weight: 500; }
.sty-tag { justify-self: start; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 8px; white-space: nowrap; }
.sty-tag.with { background: color-mix(in srgb, var(--s1) 12%, var(--panel)); color: var(--s1); }
.sty-tag.against { background: color-mix(in srgb, var(--s2) 14%, var(--panel)); color: var(--s2); }
.sty-tag.weak { background: var(--panel-2); color: var(--muted); }
.sty-t { position: relative; height: 12px; background: linear-gradient(var(--line), var(--line)) center / 1px 100% no-repeat; }
.sty-t i { position: absolute; top: 1px; bottom: 1px; border-radius: 3px; }
.sty-t i.pos { background: var(--up); } .sty-t i.neg { background: var(--down); } .sty-t i.weak { opacity: .35; }
.sty-r > b.num { font-size: 13.5px; }
/* Radar Styles lens: a company's link to one style. */
.sty-cell { font-size: 12.5px; white-space: nowrap; }
.sty-cell.with { color: var(--s1); font-weight: 600; } .sty-cell.against { color: var(--s2); font-weight: 600; } .sty-cell.weak { color: var(--muted); }
@media (max-width: 900px) {
  .sty { grid-template-columns: minmax(0, 1fr); }
  .aa-grid, .aa-find > .aa-folds.two { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .aa-input { grid-template-columns: minmax(0, 1fr); padding: 14px; }
  .aa-go { align-items: stretch; text-align: left; }
  .aa-verdict { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aa-verdict .aa-v:first-child { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: space-between; }
  /* The three cases as rows under the bar, each marked with its colour. */
  .aa-sc-row { flex-direction: column; gap: 10px; }
  .aa-sc-c { flex: none !important; padding-left: 10px; border-left: 3px solid var(--line); }
  .aa-sc-c.sc-bear { border-left-color: var(--down); } .aa-sc-c.sc-bull { border-left-color: var(--up); } .aa-sc-c.sc-base { border-left-color: color-mix(in srgb, var(--muted) 55%, var(--panel)); }
  .aa-foot { flex-direction: column; align-items: stretch; }
  .sty-h, .sty-r { grid-template-columns: minmax(0, 1fr) minmax(70px, 1fr) 56px; gap: 10px; }
  .sty-h > span:nth-child(2), .sty-tag { display: none; }
  .sty-lead { font-size: 14.5px; }
}
/* ---------- Dropdowns as app.nvestra.ai builds them (menu.js): a field that opens a panel of choices ---------- */
.vb-f { position: relative; display: inline-flex; flex-direction: column; align-items: flex-start; gap: 1px; min-width: 190px; max-width: 280px; padding: 6px 38px 7px 14px; border: 1px solid var(--line); border-radius: 11px; background: var(--panel); color: var(--fg); text-align: left; cursor: pointer; transition: background .12s, box-shadow .12s, border-color .12s; }
.vb-f:hover { background: color-mix(in srgb, var(--fg) 3%, var(--panel)); }
.vb-f.open, .vb-f:focus-visible { outline: none; border-color: var(--accent); background: var(--accent-soft); box-shadow: inset 0 0 0 .5px var(--accent); }
.vb-l { font: 600 10px/1.2 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.vb-v { max-width: 100%; font: 600 14px/1.35 var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vb-f.muted .vb-v { color: color-mix(in srgb, var(--fg) 80%, var(--muted)); font-weight: 500; }
.vb-chev { position: absolute; right: 12px; top: 50%; width: 17px; height: 17px; color: var(--muted); transform: translateY(-50%); transition: transform .15s; }
.vb-f.open .vb-chev { color: var(--accent); transform: translateY(-50%) rotate(180deg); }
@keyframes vx-in { from { opacity: 0; transform: translateY(-4px); } }
.vx-pop { position: fixed; z-index: 90; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); box-shadow: var(--pop); overflow: hidden; animation: vx-in .12s ease-out; }
@media (prefers-reduced-motion: reduce) { .vx-pop { animation: none; } }
.vx-find { display: flex; align-items: center; gap: 9px; padding: 11px 14px; border-bottom: 1px solid var(--line); cursor: text; }
.vx-find .vx-i { width: 16px; height: 16px; flex: none; color: var(--muted); }
.vx-in { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--fg); font: 500 14px var(--sans); outline: none; }
.vx-in::placeholder { color: var(--muted); }
.vx-list { overflow-y: auto; overscroll-behavior: contain; padding: 6px; }
.vx-sec { padding: 10px 10px 5px; font: 600 10.5px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.vx-sec:first-child { padding-top: 6px; }
.vx-opt { display: grid; grid-template-columns: minmax(0, 1fr) auto 16px; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 9px; cursor: pointer; }
.vx-opt[aria-selected="true"] { background: var(--panel-2); }
.vx-opt.all { margin-bottom: 2px; }
.vx-opt.all + .vx-sec { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 12px; }
.vx-t { display: flex; flex-direction: column; min-width: 0; }
.vx-t b { font: 600 13.5px/1.35 var(--sans); color: var(--fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vx-t small { font-size: 12px; line-height: 1.35; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vx-opt mark { background: color-mix(in srgb, var(--accent) 17%, transparent); color: inherit; border-radius: 3px; }
.vx-opt.cur .vx-t b { color: var(--accent); }
.vx-fig { display: flex; flex-direction: column; align-items: flex-end; font: 600 13px var(--sans); font-variant-numeric: tabular-nums; color: var(--fg); }
.vx-fig small { font-size: 12px; font-weight: 600; }
.vx-tick { width: 16px; height: 16px; color: var(--accent); visibility: hidden; }
.vx-opt.cur .vx-tick { visibility: visible; }
.vx-none { margin: 0; padding: 14px 16px; color: var(--muted); font-size: 13px; }
.vx-none[hidden] { display: none; }

/* ---------- The Radar fills the screen; only its table scrolls ---------- */
.view.fit-screen { flex: none; min-height: 0; overflow: hidden; }
.view.fit-screen > .eng { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
body:has(.view.fit-screen) .foot { display: none; }
.rd-fit { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; gap: 12px; padding-bottom: 10px; }
.rd-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.rd-fit .rd-lenses { flex: none; }
.rd-filters { display: flex; align-items: center; gap: 10px 12px; flex: 1 1 360px; min-width: 0; }
.rd-filters .rd-quick { flex: 1 1 auto; min-width: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 1px 24px 1px 1px;
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
.rd-filters .rd-quick::-webkit-scrollbar { display: none; }
.rd-filters .rd-quick > * { flex: none; }
/* On a wider screen every quick filter shows: they wrap onto a second line rather than hide behind a fade. */
@media (min-width: 641px) { .rd-filters { flex-wrap: wrap; } .rd-filters .rd-quick { flex-wrap: wrap; overflow: visible; padding-right: 1px; -webkit-mask-image: none; mask-image: none; } }
.rd-scroll { flex: 1 1 auto; min-height: 160px; overflow: auto; overscroll-behavior: contain; border-top: 1px solid var(--line); margin: 0 -20px; padding: 0 20px; }
.rd-scroll:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.rd-scroll table.wl { margin: 0; }
/* Headings stay in view as the rows scroll under them. */
.rd-scroll thead th { position: sticky; top: 0; z-index: 2; background: var(--panel); box-shadow: inset 0 -1px 0 var(--line); }
.rd-pager { display: flex; align-items: center; justify-content: space-between; gap: 10px 18px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; }
.rd-pager[hidden] { display: none; }
.rd-per-w { display: inline-flex; align-items: center; gap: 8px; }
.rd-per { display: inline-flex; align-items: center; gap: 4px; height: 34px; padding: 0 8px 0 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--fg); font: 600 13px var(--sans); cursor: pointer; }
.rd-per:hover, .rd-per.open { border-color: var(--accent); background: var(--accent-soft); }
.rd-range { color: var(--muted); margin-right: auto; }
.rd-nav { display: inline-flex; align-items: center; gap: 4px; }
.rd-pb { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--fg); cursor: pointer; }
.rd-pb:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.rd-pb:disabled { opacity: .38; cursor: default; }
.rd-pb:focus-visible, .rd-per:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.rd-pi { width: 17px; height: 17px; }
.rd-pg { min-width: 64px; text-align: center; color: var(--muted); font-weight: 600; }
@media (max-width: 900px) {
  .rd-scroll { margin: 0 -16px; padding: 0 16px; }
}
@media (max-width: 640px) {
  /* On a phone the lenses are one swipeable row, so the table keeps the height. */
  .rd-fit .rd-lenses { display: flex; flex-wrap: nowrap; width: 100%; overflow-x: auto; scrollbar-width: none; padding: 2px 24px 2px 2px;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .rd-fit .rd-lenses::-webkit-scrollbar { display: none; }
  .rd-fit .rd-lens { flex: none; padding: 8px 12px; }
  .rd-filters { flex: 1 1 100%; flex-wrap: wrap; }
  .rd-filters .vb-f { flex: 1 1 100%; max-width: none; }
  .rd-scroll { margin: 0 -14px; padding: 0 14px; }
  .rd-pager { gap: 8px; }
  .rd-per-w .muted, .rd-range { display: none; }
  .rd-nav { margin-left: auto; }
  .rd-pg { min-width: 44px; }
}
@media (max-width: 360px) {
  .rd-pb[aria-label="First page"], .rd-pb[aria-label="Last page"] { display: none; }
}
/* ---------- Radio: every logo fits its plate; streams added from YouTube (listen.js openAdd) ---------- */
/* The plate centres its mark with flexbox, so a tall logo (NBC News NOW's) is scaled to fit instead of spilling out. */
.rx-plate { display: inline-flex; align-items: center; justify-content: center; overflow: hidden; }
.rx-plate img { width: 100%; height: 100%; max-width: none; max-height: none; object-fit: contain; }
.rx-plate.th { padding: 0; background: #111; }
.rx-plate.th img { object-fit: cover; }
/* A channel without a logo fills its plate with a coloured tile and its initials. */
.rx-plate:has(> .rx-mark) { padding: 0; background: transparent; }
.rx-plate > .rx-mark { width: 100%; height: 100%; border-radius: inherit; font-size: 15px; letter-spacing: .02em; }
.lp-logo.th img, .np-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.np-thumb { padding: 0; overflow: hidden; background: #111; }
.rx-addch .rx-plate.add { background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .45); color: #fff; font: 300 26px/1 var(--sans); }
.rx-addch { border-style: dashed; }
.rx-addch:hover .rx-plate.add { background: rgba(255, 255, 255, .2); }
.rx-dlg { width: min(560px, calc(100% - 24px)); max-height: min(680px, calc(100dvh - 32px)); padding: 0; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); color: var(--fg); box-shadow: var(--pop); display: flex; flex-direction: column; overflow: hidden; }
.rx-dlg:not([open]) { display: none; }
.rx-dlg::backdrop { background: rgba(8, 12, 18, .5); }
.rx-dlg-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px 6px; }
.rx-dlg-t { margin: 0; font: 600 18px/1.25 var(--head); letter-spacing: -.01em; }
.rx-x { all: unset; box-sizing: border-box; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; font-size: 22px; line-height: 1; color: var(--muted); cursor: pointer; }
.rx-x:hover { background: var(--panel-2); color: var(--fg); }
.rx-x:focus-visible { outline: 2px solid var(--accent); }
.rx-find { display: flex; align-items: center; gap: 10px; margin: 8px 18px 6px; padding: 0 14px; height: 46px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); cursor: text; }
.rx-find:focus-within { border-color: var(--accent); background: var(--panel); box-shadow: 0 0 0 3px var(--accent-soft); }
.rx-find-i { width: 18px; height: 18px; flex: none; color: var(--muted); }
.rx-find-in { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--fg); font: 500 15px var(--sans); outline: none; }
.rx-find-in::placeholder { color: var(--muted); }
.rx-find-in:focus, .rx-find-in:focus-visible { outline: none; }
.rx-add-note { margin: 4px 18px 0; padding: 8px 12px; border-radius: 10px; background: var(--warn-soft); font-size: 13px; }
.rx-add-note[hidden] { display: none; }
.rx-add-list { flex: 1 1 auto; min-height: 120px; overflow-y: auto; overscroll-behavior: contain; padding: 6px 10px 10px; }
.rx-add-list[aria-busy="true"] { opacity: .6; }
.rx-add-sec { padding: 12px 8px 6px; font: 600 10.5px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.rx-res { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 8px; border-radius: 12px; }
.rx-res:hover { background: var(--panel-2); }
.rx-res .rx-plate { width: 64px; height: 40px; padding: 5px 7px; border-radius: 9px; }
.rx-res .rx-plate.th { padding: 0; }
.rx-res-t { display: flex; flex-direction: column; min-width: 0; }
.rx-res-t b { font: 600 14px/1.3 var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rx-res-t small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rx-livenow { color: var(--down); font-weight: 700; }
.rx-livenow::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 5px; border-radius: 50%; background: var(--down); vertical-align: 1px; }
.rx-res-a { display: flex; gap: 6px; }
.rx-on-btn .rx-no { display: none; }
.rx-on-btn:hover .rx-yes, .rx-on-btn:focus-visible .rx-yes { display: none; }
.rx-on-btn:hover .rx-no, .rx-on-btn:focus-visible .rx-no { display: inline; color: var(--down); }
.rx-on-btn .rx-yes::before { content: "✓ "; color: var(--up); }
.rx-add-empty { margin: 18px 8px; color: var(--muted); font-size: 13.5px; }
.rx-add-foot { display: flex; align-items: center; gap: 6px; margin: 0; padding: 10px 18px 14px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }
@media (max-width: 640px) {
  /* On a phone the dialog is a sheet from the bottom, the full width. */
  .rx-dlg { width: 100%; max-width: none; margin: auto 0 0; max-height: calc(100dvh - 48px); border-radius: 18px 18px 0 0; border-bottom: 0; }
  .rx-res { grid-template-columns: 52px minmax(0, 1fr) auto; gap: 10px; padding: 7px 6px; }
  .rx-res .rx-plate { width: 52px; height: 36px; }
  .rx-res-a .btn.sm { padding: 5px 9px; font-size: 12px; min-height: 32px; }
}
@media (hover: none) { .rx-on-btn .rx-yes { display: none; } .rx-on-btn .rx-no { display: inline; color: var(--down); } }

/* Row 18, phone: comfortable taps and labels that fit. */
@media (pointer: coarse) {
  /* The small "?" keeps its look but answers a press anywhere near it. */
  .help { position: relative; }
  .help::after { content: ""; position: absolute; inset: -10px; }
}
@media (max-width: 640px) {
  .rd-fit .rd-lens { min-height: 34px; }
  .xf-theme { min-height: 32px; }
}
@media (max-width: 420px) {
  /* The results-day strip shows the latest seven, so each date fits under its bar. */
  .rx > .rx-c:nth-child(-n+3) { display: none; }
}

/* The Market's indices and its rates card stack when the page itself is under 1,000 pixels wide (app.js measures it):
   beside the docked Copilot or in a narrow window, whatever the window's width. (A container query on #view would also
   make it the box that positions fixed overlays inside it, so the page is measured instead.) */
.view.narrow .grid2.g64 { grid-template-columns: minmax(0, 1fr); }

/* The call card on a company page (redesigned 2026-12-02): the verdict in its own panel, its track record as 100
   squares, who says what, and the risk. Buy and Hold read green, Sell red, Wait in ink: the words carry the meaning. */
.cc { display: flex; flex-direction: column; gap: 18px; padding: 20px 22px 18px; }
.cc[aria-busy] .cc-top { display: grid; }
.cc { --cc: var(--fg); --cc-bg: color-mix(in srgb, var(--fg) 5%, var(--panel)); }
.cc-h { display: flex; align-items: center; justify-content: space-between; gap: 6px 16px; flex-wrap: wrap; }
.cc-eye { display: flex; align-items: center; gap: 4px 10px; flex-wrap: wrap; min-width: 0; font-size: 13px; color: var(--muted); }
.cc-eye b { font: 700 11px/1 var(--sans); letter-spacing: .09em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 6px 10px; }
.cc-short { display: none; }
.cc-how { font-size: 13px; font-weight: 600; color: var(--accent); white-space: nowrap; }
.cc-how::after { content: ' →'; }
.cc-how:hover { text-decoration: underline; text-underline-offset: 3px; }
.cc-top { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 14px; }
/* The verdict. */
.cc-verdict { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px; border-radius: 14px; background: var(--cc-bg); border: 1px solid color-mix(in srgb, var(--cc) 18%, var(--line)); }
.cc-verdict.cc-buy, .cc-verdict.cc-hold { --cc: var(--up); --cc-bg: color-mix(in srgb, var(--up) 8%, var(--panel)); }
.cc-verdict.cc-sell { --cc: var(--down); --cc-bg: color-mix(in srgb, var(--down) 7%, var(--panel)); }
.cc-verdict.cc-none, .cc-verdict.cc-bench { --cc: var(--muted); }
.cc-vrow { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.cc-word { font: 700 46px/.95 var(--head); letter-spacing: -.03em; color: var(--cc); }
.cc-own { font-size: 12.5px; font-weight: 600; color: var(--cc); padding: 4px 10px; border-radius: 999px; background: var(--panel); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--cc) 30%, var(--line)); }
.cc-say { margin: 2px 0 0; font-size: 15.5px; font-weight: 600; line-height: 1.4; color: var(--fg); max-width: 46ch; }
.cc-by { margin: 0; font-size: 13px; line-height: 1.45; color: var(--muted); max-width: 52ch; }
/* The track record: 100 squares, the edge beyond a coin flip in the call's colour. */
.cc-record { display: flex; align-items: center; gap: 20px; padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line); }
.cc-waffle { width: 132px; height: 132px; flex: none; }
.cc-waffle rect.r { fill: color-mix(in srgb, var(--fg) 62%, var(--panel)); }
.cc-waffle rect.e { fill: var(--cc-edge, var(--fg)); }
.cc-waffle rect.o { fill: var(--panel-2); stroke: var(--line); stroke-width: .6; }
.cc-waffle.cc-buy, .cc-waffle.cc-hold { --cc-edge: var(--up); } .cc-waffle.cc-sell { --cc-edge: var(--down); } .cc-waffle.cc-wait { --cc-edge: var(--accent); }
.cc-flip { stroke: var(--fg); stroke-width: 1.4; stroke-dasharray: 3 3; }
.cc-rtext { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.cc-big { font: 600 34px/1 var(--head); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.cc-rtext > span { font-size: 13px; line-height: 1.4; color: var(--fg); }
.cc-rtext > span.cc-edge { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; }
.cc-rtext > span.cc-edge.muted { color: var(--muted); }
.cc-key { width: 10px; height: 10px; border-radius: 2px; flex: none; }
.cc-key.e { background: var(--cc-edge, var(--fg)); }
.cc-record:has(.cc-buy), .cc-record:has(.cc-hold) { --cc-edge: var(--up); } .cc-record:has(.cc-sell) { --cc-edge: var(--down); } .cc-record:has(.cc-wait) { --cc-edge: var(--accent); }
.cc-key.flip { width: 0; height: 12px; border-left: 1.5px dashed var(--fg); border-radius: 0; margin: 0 4px; }
/* Who says what: one aligned row a contender, the champion first. */
.cc-who { display: flex; flex-direction: column; }
.cc-who-h, .cc-row { display: grid; grid-template-columns: minmax(0, 1.5fr) 96px minmax(170px, 1fr) 120px; gap: 14px; align-items: center; }
.cc-who-h { padding: 0 4px 8px; border-bottom: 1px solid var(--line); }
.cc-cols { display: contents; }
.cc-cols span { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.cc-cols span:last-child { text-align: right; }
.cc-sub { margin: 0; font: 600 12.5px/1.3 var(--sans); color: var(--fg); }
.cc-rows { list-style: none; margin: 0; padding: 0; }
.cc-row { padding: 11px 4px; border-bottom: 1px solid var(--line); }
.cc-row:last-child { border-bottom: 0; }
.cc-row.cc-lead { background: linear-gradient(90deg, var(--accent-soft), transparent 70%); border-radius: 10px; }
.cc-name { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cc-name b { font-size: 14px; }
.cc-name small { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-rec { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.cc-rec .num { font-weight: 600; min-width: 34px; }
.cc-bar { position: relative; flex: 1; max-width: 140px; height: 7px; border-radius: 4px; background: var(--panel-2); }
.cc-bar i { position: absolute; inset: 0 auto 0 0; border-radius: 4px; background: color-mix(in srgb, var(--fg) 40%, var(--panel)); }
.cc-bar.ok i { background: var(--fg); }
.cc-bar u { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--down); }
.cc-st { text-align: right; }
/* The risk. */
.cc-risk { display: flex; align-items: center; gap: 8px 14px; flex-wrap: wrap; padding: 12px 14px; border-radius: 12px; background: var(--panel-2); font-size: 13px; }
/* The card lays itself out by its own width, wherever it sits: the verdict above its record when narrow, then each
   contender on two lines. A container query is safe here: the card holds no fixed overlays. */
.cc { container-type: inline-size; }
.cc-body { display: contents; }
/* A wide card (row 26): the verdict over its record on the left, who says what and the risk on the right, so the
   rows are not stretched across the page and the card is about a third shorter. */
@container (min-width: 1240px) {
  .cc-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); grid-template-rows: auto 1fr; gap: 14px 28px; align-items: start; }
  .cc-body > .cc-top { grid-row: 1 / span 2; grid-template-columns: minmax(0, 1fr); }
  .cc-body > .cc-risk { align-self: end; }
}
@container (max-width: 760px) {
  .cc-top { grid-template-columns: minmax(0, 1fr); }
  .cc-long { display: none; } .cc-short { display: inline; }
  .cc-eye > span { white-space: nowrap; }
}
@container (max-width: 640px) {
  .cc-cols { display: none; }
  .cc-who-h { grid-template-columns: minmax(0, 1fr); }
  .cc-row { grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; }
  .cc-row .cc-rec { grid-column: 1; }
  .cc-row .cc-st { grid-column: 2; grid-row: 2; }
  .cc-word { font-size: 40px; }
  .cc-record { gap: 16px; padding: 14px; }
  .cc-waffle { width: 108px; height: 108px; }
  .cc-big { font-size: 28px; }
}
@media (max-width: 760px) { .cc { padding: 16px; gap: 14px; } }

/* The launch screen (run from index.html, 2026-12-02). It opens as a copy of the phone's own splash (the app icon on
   the installed app's near-black launch color), then the mark turns mint and flies apart. Each moving part is a layer of
   its own so the motion keeps going while the app draws; the hole and the thin rings are drawn in advance, nearly
   invisible. The page gets a layer too, so the zoom it settles from needs no redrawing. */
#launch { display: none; }
html.launch #launch { display: block; position: fixed; inset: 0; z-index: 2147483000; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
#launch .l-bg { position: absolute; inset: 0; background: #0b0e13; }
#launch .l-hole { position: absolute; inset: 0; opacity: .01; will-change: transform; }
#launch .l-in { position: absolute; transform-origin: 50% 50%; }
#launch .l-em { position: absolute; inset: 0; }
#launch .l-em, #launch .l-em > *, #launch .l-r, #launch .l-t { transform-origin: 52% 50%; }
#launch .l-em > *, #launch .l-r, #launch .l-t { position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; }
#launch .l-tile { left: 6.96%; top: 6.96%; width: 86.08%; height: 86.08%; border-radius: 40%; background: #0a5c43; transform-origin: 50% 50%; }
#launch svg { display: block; }
#launch path { fill: none; stroke-linecap: round; }
#launch .l-w path { stroke: #fff; stroke-width: 2; }
#launch .l-r path, #launch .l-t path, #launch .l-rp path { stroke: #4fd29c; }
#launch .l-r path, #launch .l-gl path { stroke-width: 1.7; }
#launch .l-t path { stroke-width: .45; }
#launch .l-rp path { stroke-width: 1; }
#launch .l-gl path { stroke: #d4f7e6; }
#launch .l-r, #launch .l-gl, #launch .l-rp { opacity: 0; }
#launch .l-t { opacity: .01; }
#launch .l-sp { left: 52%; top: 50%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: #d4f7e6; opacity: 0; transform-origin: 50% 50%; }
html.launch #view { will-change: transform; }
