/* Riding Hood terminal — dark-first, light via [data-theme=light]. */
:root {
  --bg: #0a0b10; --bg2: #12141c; --bg3: #1a1d28; --line: #23273400;
  --line2: #232734; --ink: #eef0f6; --muted: #9aa0b4; --dim: #6b7183;
  --accent: #6b8afd; --green: #16a34a; --red: #ef4444;
  --up: #21c95e; --down: #ff622e;
}
:root[data-theme="light"] {
  --bg: #f7f8fb; --bg2: #ffffff; --bg3: #eef1f6; --line2: #e4e8f0;
  --ink: #14151b; --muted: #5b6178; --dim: #8b90a3;
}
* { box-sizing: border-box; }
/* The `hidden` attribute must always win over class rules that set `display` (e.g. .tok-picker is
   display:flex, which otherwise overrides [hidden] and leaves the token picker permanently open). */
[hidden] { display: none !important; }
/* Thin, theme-colored scrollbars everywhere. */
* { scrollbar-width: thin; scrollbar-color: var(--line2) transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: var(--line2); border-radius: 8px; }
*::-webkit-scrollbar-thumb:hover { background: var(--muted); }
html, body { height: 100%; margin: 0; }
body.terminal {
  background: var(--bg); color: var(--ink);
  font: 12.5px/1.35 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  display: flex; flex-direction: column; overflow: hidden;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; }
.num { font-variant-numeric: tabular-nums; text-align: right; }
.mono-link { font-variant-numeric: tabular-nums; color: var(--muted); }
.mono-link:hover { color: var(--ink); }
.dim { color: var(--dim); }
.empty { color: var(--dim); display: grid; place-items: center; height: 100%; padding: 20px; text-align: center; }
.empty.small { font-size: 13px; }

/* Header */
.tbar { display: grid; grid-template-columns: 1fr minmax(0, 440px) 1fr; align-items: center; gap: 16px; padding: 8px 14px; border-bottom: 1px solid var(--line2); background: var(--bg2); flex: none; }
.brand { display: flex; align-items: center; gap: 8px; justify-self: start; }
.mark-img { width: 40px; height: 40px; }
.beta-tag { font-size: 10px; font-weight: 700; color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); padding: 1px 5px; border-radius: 5px; }
.tsearch { position: relative; display: flex; align-items: center; gap: 8px; flex: 1; max-width: 460px; background: var(--bg); border: 1px solid var(--line2); border-radius: 10px; padding: 8px 12px; color: var(--muted); }
.search-dd { position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%); width: min(1000px, 94vw); max-height: min(76vh, 560px); overflow-y: auto; background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; box-shadow: 0 16px 40px rgba(0,0,0,.5); z-index: 80; }
.dd-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.dd-table thead th { position: sticky; top: 0; z-index: 1; background: var(--bg2); text-align: right; color: var(--muted); font-weight: 600; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; padding: 9px 12px; border-bottom: 1px solid var(--line2); cursor: pointer; white-space: nowrap; user-select: none; }
.dd-table thead th.dd-tok { text-align: left; }
.dd-table thead th:hover { color: var(--ink); }
.dd-table thead th.on { color: var(--accent); }
/* Paired-token screener modal */
.scr-overlay { position: fixed; inset: 0; z-index: 200; background: rgba(0,0,0,.5); display: flex; align-items: flex-start; justify-content: center; padding: 48px 16px; }
.scr-overlay[hidden] { display: none; } /* the attribute must beat the display:flex above */
.scr-panel { width: min(1100px, 96vw); max-height: 86vh; display: flex; flex-direction: column; background: var(--bg2); border: 1px solid var(--line2); border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.55); overflow: hidden; }
.scr-head { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line2); }
.scr-head .scr-sub { font-size: 12px; font-weight: 400; }
.scr-head #scr-close { margin-left: auto; }
.scr-body { overflow-y: auto; }
.scr-body .dd-table td.dd-tok { min-width: 180px; }
.dd-row { cursor: pointer; }
.dd-row:hover { background: var(--bg3); }
.dd-wallet td { color: var(--ink); }
.dd-wallet:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.dd-wallet-ic { color: var(--accent); margin-right: 4px; }
.dd-wallet .mono { font-family: ui-monospace, monospace; font-size: 11px; margin-left: 6px; }
.dd-row.sel { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.dd-row td { padding: 7px 12px; border-top: 1px solid var(--line2); white-space: nowrap; vertical-align: middle; }
.dd-tok-in { display: flex; align-items: center; gap: 9px; }
.dd-row .prem.up { color: var(--up); } .dd-row .prem.down { color: var(--down); }
.dd-msg { text-align: center; color: var(--dim); padding: 18px; }
.tsearch input { flex: 1; border: 0; outline: 0; background: transparent; color: var(--ink); font: inherit; }
.tbar-right { justify-self: end; display: flex; align-items: center; gap: 8px; }
.tnav { display: inline-flex; align-items: center; justify-content: center; line-height: 1; text-decoration: none; padding: 0 12px; height: 34px; border-radius: 9px; color: var(--muted); border: 1px solid var(--line2); font-weight: 700; font-size: 12px; background: transparent; cursor: pointer; }
.tnav:hover { color: var(--ink); border-color: var(--accent); }
.tnav-accent { color: #fff; background: var(--accent); border-color: var(--accent); }
.tnav-accent:hover { color: #fff; border-color: var(--accent); filter: brightness(1.08); }
.icon-btn { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: var(--muted); border: 1px solid var(--line2); }
.icon-btn:hover { color: var(--ink); }
.i-sun { display: none; } :root[data-theme="light"] .i-moon { display: none; } :root[data-theme="light"] .i-sun { display: block; }

/* 3-column grid */
.tgrid { flex: 1; min-height: 0; display: grid; grid-template-columns: 300px 1fr 330px; gap: 10px; padding: 10px; overflow: hidden; }
@media (max-width: 1200px) { .tgrid { grid-template-columns: 260px 1fr; } .side { display: none; } }
.rail, .center, .side { min-height: 0; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.rail, .side { overflow: hidden; }

/* Left rail */
.rail { background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; }
.rail-tabs { display: flex; align-items: center; justify-content: space-between; gap: 4px; padding: 2px 6px; border-bottom: 1px solid var(--line2); }
.rtabs-list { display: flex; align-items: center; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.rtabs-list::-webkit-scrollbar { display: none; }
.ctab { padding: 6px 12px; border-radius: 8px; font-weight: 600; font-size: 13px; color: var(--muted); }
.ctab.active { color: var(--ink); background: var(--bg3); }
.rtab { position: relative; flex: none; white-space: nowrap; padding: 9px 11px; font-weight: 600; font-size: 13px; color: var(--muted); }
.rtab:hover { color: var(--ink); }
.rtab.active { color: var(--ink); }
.rail-collapse { display: grid; place-items: center; color: var(--muted); font-size: 15px; width: 26px; height: 26px; border-radius: 7px; flex: none; }
.rail-collapse:hover { color: var(--ink); }
/* Expand bar: hidden while the panel is open; fills the narrowed rail when collapsed. */
.rail-expand { display: none; width: 100%; height: 40px; color: var(--muted); font-size: 16px; }
.rail-expand:hover { color: var(--ink); background: var(--bg3); }
body.rail-collapsed .rail-expand { display: grid; place-items: center; }
body.rail-collapsed .rail-tabs, body.rail-collapsed .rail-filter, body.rail-collapsed .rail-body { display: none; }
/* Collapsed rail is a 40×40 square button pinned to the top of the column. */
body.rail-collapsed .rail { height: 40px; align-self: start; }
body.rail-collapsed .tgrid { grid-template-columns: 40px 1fr 330px; }
@media (max-width: 1200px) { body.rail-collapsed .tgrid { grid-template-columns: 40px 1fr; } }
.rail-filter { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-bottom: 1px solid var(--line2); flex-wrap: wrap; }
.filter-btn { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.filter-btn:hover, .filter-btn[aria-expanded="true"] { color: var(--ink); }
.filter-hint { font-size: 11px; color: var(--dim); }
.filter-chips { display: flex; gap: 4px; }
.filter-chips[hidden] { display: none; }
.filter-chips button { padding: 3px 9px; border-radius: 999px; font-size: 11px; font-weight: 600; color: var(--muted); border: 1px solid var(--line2); }
.filter-chips button:hover { color: var(--ink); }
.filter-chips button.active { color: var(--ink); background: var(--bg3); border-color: transparent; }
.filter-custom, .filter-text { width: 88px; background: var(--bg); border: 1px solid var(--line2); border-radius: 999px; color: var(--ink); font: inherit; font-size: 11px; padding: 3px 9px; outline: none; }
.filter-text { width: 104px; }
.filter-custom:focus, .filter-text:focus { border-color: var(--accent); }
.rail-body { flex: 1; min-height: 0; position: relative; }
.rail-pane { position: absolute; inset: 0; overflow-y: auto; }
.feed-row, .tok-row { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line2); }
.feed-row:hover, .tok-row:hover { background: var(--bg3); }
/* Rows rendered as anchors (leaderboard / paired) should look like the button rows. */
a.feed-row { color: inherit; text-decoration: none; cursor: pointer; }
.board-rank { width: 22px; flex: none; text-align: right; color: var(--dim); font-size: 12px; font-weight: 700; }
/* Token category badge (paired list) */
.badge.cat { text-transform: uppercase; letter-spacing: .03em; font-size: 9px; }
.cat-meme { background: color-mix(in srgb, #a855f7 20%, transparent); color: #c084fc; }
.cat-ai { background: color-mix(in srgb, #06b6d4 20%, transparent); color: #22d3ee; }
.cat-stock { background: color-mix(in srgb, #16a34a 20%, transparent); color: #4ade80; }
.cat-stable { background: color-mix(in srgb, #eab308 20%, transparent); color: #facc15; }
.cat-native { background: color-mix(in srgb, #f97316 20%, transparent); color: #fb923c; }
/* Paired tab: stock rows that expand to their pools */
.pstock-count { margin-left: auto; display: flex; align-items: center; gap: 4px; flex: none; font-weight: 700; font-size: 13px; color: var(--muted); }
.pstock-count .chev { color: var(--dim); font-size: 15px; transition: transform .15s; display: inline-block; }
.pstock-wrap.open .pstock { background: var(--bg3); }
.pstock-pools { background: color-mix(in srgb, var(--bg2) 60%, transparent); border-bottom: 1px solid var(--line2); }
.pstock-pools[hidden] { display: none; }
.pstock-pool { padding-left: 22px !important; }
.pstock-pool .plogo { width: 18px; height: 18px; }
/* Clans (Board → Clans view): clan row expands to its member roster + top tokens. */
.board-toggle .bt-sep { width: 1px; align-self: stretch; margin: 4px; background: var(--line2); flex: none; }
.pstock-caret { margin-left: auto; flex: none; color: var(--dim); font-size: 12px; padding-left: 6px; }
.clan-row { cursor: pointer; }
.clan-wrap.open .clan-row, .clan-row:hover { background: var(--bg3); }
.clan-detail { background: color-mix(in srgb, var(--bg2) 60%, transparent); }
.clan-member { padding-left: 22px !important; }
.clan-member .frow-logo { width: 20px; height: 20px; }
.clan-subhead { padding: 6px 12px 2px 22px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); }
.clan-note { padding: 4px 12px 4px 22px; }

/* Center Pools category filter bar */
.pool-filter { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; min-height: 37px; padding: 6px 10px; border-bottom: 1px solid var(--line2); position: sticky; top: 0; background: var(--bg2); z-index: 3; }
.pool-filter::-webkit-scrollbar { display: none; }
.poolcat { flex: none; }
.pf-note { font-size: 12px; color: var(--dim); white-space: nowrap; }
/* Table header sits BELOW the sticky filter bar (both stick, stacked). Higher specificity than
   `.swap-table th { top: 0 }` so it isn't overridden. */
.pools-table thead th { top: 38px; z-index: 2; }
.poolcat { padding: 4px 11px; border-radius: 999px; font-weight: 600; font-size: 12px; color: var(--dim); background: transparent; }
.poolcat:hover { color: var(--ink); }
.poolcat.active { color: var(--ink); background: var(--bg3); }
.rail-subhead { padding: 8px 12px 4px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); background: var(--bg2); position: sticky; top: 0; }
/* Social sub-nav: Posts / Trades — a secondary toggle (only the active one is filled, so the
   hierarchy is clear), inset from the rail edges. */
.rail-subnav { display: flex; gap: 2px; padding: 8px 12px 2px; }
.rail-subnav[hidden] { display: none; }
.rsub { padding: 5px 12px; border-radius: 8px; font-weight: 600; font-size: 12px; color: var(--dim); background: transparent; transition: background .12s, color .12s; }
.rsub:hover { color: var(--ink); }
.rsub.active { color: var(--ink); background: var(--bg3); }
.tok-row.sel { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.frow-logo, .trow-logo { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; background: var(--bg3); flex: none; }
.feed-row, .tok-row { padding: 8px 12px; }
.frow-logo.mono, .trow-logo.mono { display: grid; place-items: center; font-weight: 700; color: var(--muted); }
.frow-main, .trow-main { min-width: 0; flex: 1; }
.frow-top { display: flex; align-items: center; gap: 6px; }
.frow-sub, .trow-name { color: var(--dim); font-size: 12px; margin-top: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wallet-link { color: var(--muted); }
.wallet-link:hover { color: var(--accent); text-decoration: underline; }
.wallet-copy { color: var(--dim); font-size: 11px; padding: 0 1px; vertical-align: baseline; }
.wallet-copy:hover { color: var(--ink); }
.trow-sym { font-weight: 600; }
.trow-num { text-align: right; font-variant-numeric: tabular-nums; }
.prem.up { color: var(--up); } .prem.down { color: var(--down); } .prem { font-size: 12px; }
.side.b { color: var(--up); } .side.s { color: var(--down); }
.side { font-weight: 700; font-size: 12px; }

/* Center */
.center { min-width: 0; }
.thead { background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; padding: 10px 14px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; flex: none; }
.th-id { display: flex; align-items: center; gap: 10px; flex: none; }
.th-logo { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--bg3); }
.th-logo.mono { display: grid; place-items: center; font-weight: 800; color: var(--muted); }
.th-sym { font-weight: 800; font-size: 20px; letter-spacing: -.02em; line-height: 1.05; }
.th-name { color: var(--dim); font-size: 11px; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.th-hero { display: flex; gap: 14px; padding: 0; flex: none; }
.hero-col .hlbl { font-size: 9px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.hero-col .hval { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.prem-col.up .hval { color: var(--up); } .prem-col.down .hval { color: var(--down); }
.th-chips { display: flex; gap: 5px; margin-left: auto; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.th-chips::-webkit-scrollbar { display: none; }
.chip { background: var(--bg3); border-radius: 7px; padding: 4px 8px; flex: none; }
.chip .clbl { display: block; font-size: 9px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); white-space: nowrap; }
.chip .cval { font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }

.chart-wrap { flex: 1; min-height: 0; background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; display: flex; flex-direction: column; overflow: hidden; }
.chart-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border-bottom: 1px solid var(--line2); }
.tf, .pm { display: inline-flex; gap: 2px; background: var(--bg3); border-radius: 8px; padding: 3px; }
.tf button, .pm button { padding: 4px 10px; border-radius: 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.tf button.active, .pm button.active { background: var(--bg); color: var(--ink); }
.chart-pool { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; min-width: 0; max-width: 220px; overflow: hidden; white-space: nowrap; }
.chart-pool b { color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.chart { flex: 1; min-height: 0; }

.ctabs { display: flex; gap: 4px; padding: 0 2px; flex: none; }
.ctab-body { flex: none; height: 280px; background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; overflow: hidden; }
.ctab-pane { height: 100%; overflow-y: auto; }
.swap-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.swap-table th { position: sticky; top: 0; background: var(--bg2); text-align: left; color: var(--muted); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; padding: 7px 12px; border-bottom: 1px solid var(--line2); }
.swap-table th.num { text-align: right; }
.swap-table td { padding: 6px 12px; border-top: 1px solid var(--line2); white-space: nowrap; }
.pair-cell { display: flex; align-items: center; gap: 8px; }

/* Right */
.side { overflow-y: auto; }
.trade-card, .about-card { background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; padding: 12px; }
.bs-toggle { display: flex; gap: 6px; margin-bottom: 10px; }
.bs { flex: 1; padding: 9px; border-radius: 9px; font-weight: 700; background: var(--bg3); color: var(--muted); }
.bs.buy.active { background: color-mix(in srgb, var(--green) 22%, transparent); color: var(--up); }
.bs.sell.active { background: color-mix(in srgb, var(--red) 22%, transparent); color: var(--down); }
.bs-amount { display: flex; align-items: center; gap: 4px; background: var(--bg3); border-radius: 10px; padding: 11px 13px; font-size: 22px; margin-bottom: 10px; }
.bs-amount .cur { color: var(--dim); }
.bs-amount input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--ink); font: inherit; }
.bs-quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 10px; }
.bs-quick button { padding: 7px; border-radius: 8px; background: var(--bg3); font-weight: 700; font-size: 13px; }
.bs-exec { width: 100%; padding: 11px; border-radius: 10px; background: var(--bg3); color: var(--muted); font-weight: 700; cursor: not-allowed; }
.bs-note { font-size: 11px; color: var(--dim); margin: 8px 2px 0; }

/* ── Uniswap-style swap widget ── */
.trade-card { position: relative; }
.uswap { position: relative; display: flex; flex-direction: column; gap: 4px; }
.uswap-panel { background: var(--bg3); border: 1px solid transparent; border-radius: 16px; padding: 14px 14px 12px; transition: border-color .12s; }
.uswap-panel:focus-within { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.uswap-lbl { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.uswap-mid { display: flex; align-items: center; gap: 8px; }
.uswap-amt { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--ink); font: inherit; font-size: 30px; font-weight: 500; letter-spacing: -.01em; }
.uswap-amt::placeholder { color: var(--dim); }
.uswap-out { color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uswap-tok { display: flex; align-items: center; gap: 6px; background: var(--bg2); border: 1px solid var(--line2); border-radius: 999px; padding: 5px 10px 5px 6px; font-weight: 700; font-size: 15px; color: var(--ink); cursor: pointer; white-space: nowrap; flex: none; box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.uswap-tok:hover { background: var(--bg); }
.uswap-tok.empty { background: var(--accent); color: #fff; border-color: transparent; padding-left: 12px; }
.uswap-tok.empty .uswap-tok-logo { display: none; }
.uswap-tok.empty .uswap-chev { color: rgba(255,255,255,.85); }
.uswap-tok-logo, .uswap-tok-logo img { width: 22px; height: 22px; border-radius: 999px; object-fit: cover; display: block; background: var(--bg3); }
.uswap-tok-logo.mono { display: grid; place-items: center; font-size: 10px; font-weight: 800; color: var(--muted); }
.uswap-chev { color: var(--dim); }
.uswap-sub { display: flex; justify-content: space-between; align-items: center; min-height: 16px; margin-top: 6px; font-size: 12px; color: var(--dim); }
.uswap-bal { display: flex; align-items: center; gap: 6px; }
.uswap-max { background: none; border: 0; color: var(--accent); font-weight: 700; font-size: 11px; cursor: pointer; padding: 0; }
.uswap-max:hover { text-decoration: underline; }
/* Overlapping circular flip button between the two cards */
.uswap-flip { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 34px; height: 34px; border-radius: 11px; background: var(--bg3); border: 4px solid var(--bg2); color: var(--ink); cursor: pointer; display: grid; place-items: center; z-index: 2; }
.uswap-flip:hover { color: var(--accent); }
.uswap-cta { width: 100%; margin-top: 8px; padding: 14px; border-radius: 16px; background: var(--accent); color: #fff; font-weight: 700; font-size: 15px; cursor: pointer; border: 0; }
.uswap-cta:disabled { background: var(--bg3); color: var(--muted); cursor: not-allowed; }
/* Collapsible route details */
.uswap-details { margin-top: 8px; border: 1px solid var(--line2); border-radius: 14px; overflow: hidden; }
.uswap-sumrow { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; background: none; border: 0; color: var(--ink); font: inherit; font-size: 12px; cursor: pointer; }
.uswap-sumrow:hover { background: var(--bg3); }
.uswap-rate { color: var(--muted); }
.uswap-sumright { display: flex; align-items: center; gap: 8px; }
.uswap-sumrow[aria-expanded="true"] .uswap-chev { transform: rotate(180deg); }
.uswap-expand { padding: 4px 12px 12px; border-top: 1px solid var(--line2); }
/* Token picker (modal-style, over the card) */
.tok-picker { position: absolute; inset: 0; background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; z-index: 20; display: flex; flex-direction: column; box-shadow: 0 12px 32px rgba(0,0,0,.5); }
.tok-picker-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 12px 8px; }
.tok-picker-title { font-size: 14px; }
.tok-picker-close { background: none; border: 0; color: var(--dim); cursor: pointer; font-size: 15px; padding: 0 4px; }
.tok-search { margin: 0 12px 8px; background: var(--bg); border: 1px solid var(--line2); border-radius: 10px; color: var(--ink); font: inherit; font-size: 13px; padding: 9px 11px; outline: none; }
.tok-search:focus { border-color: var(--accent); }
.tok-bases { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 12px 8px; }
.tok-base { display: flex; align-items: center; gap: 5px; border: 1px solid var(--line2); border-radius: 999px; padding: 4px 9px 4px 5px; background: var(--bg); color: var(--ink); font-weight: 700; font-size: 12px; cursor: pointer; }
.tok-base:hover { border-color: var(--accent); }
.tok-base img, .tok-base .mono { width: 18px; height: 18px; border-radius: 999px; display: block; }
.tok-base .mono { display: grid; place-items: center; font-size: 9px; font-weight: 800; color: var(--muted); background: var(--bg3); }
.tok-results { overflow-y: auto; padding: 4px 6px 8px; display: flex; flex-direction: column; gap: 1px; border-top: 1px solid var(--line2); }
.tok-res { display: flex; align-items: center; gap: 10px; padding: 9px; border-radius: 10px; background: none; border: 0; cursor: pointer; text-align: left; color: var(--ink); }
.tok-res:hover { background: var(--bg3); }
.tok-res-logo, .tok-res-logo img { width: 30px; height: 30px; border-radius: 999px; object-fit: cover; display: block; background: var(--bg3); flex: none; }
.tok-res-logo.mono { display: grid; place-items: center; font-size: 11px; font-weight: 800; color: var(--muted); }
.tok-res-main { display: flex; flex-direction: column; min-width: 0; }
.tok-res-sym { font-weight: 700; font-size: 14px; }
.tok-res-addr { font-family: ui-monospace, monospace; font-size: 10px; color: var(--dim); }
.tok-res-tvl { margin-left: auto; font-size: 11px; color: var(--muted); }

/* ── DEX quote / route preview ── */
.quote-box { margin-top: 10px; padding: 10px; border: 1px solid var(--line2); border-radius: 10px; background: var(--bg); }
.q-est { font-size: 15px; }
.q-est b { font-weight: 700; }
.q-route { font-size: 11px; color: var(--muted); margin-top: 4px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.q-route .ar { margin: 0 3px; color: var(--dim); }
.warn { color: var(--down); font-weight: 600; }
.q-graph { width: 100%; height: auto; margin-top: 8px; display: block; }
.q-graph .gn { fill: var(--bg3); stroke: var(--line2); stroke-width: 1.5; }
.q-graph .gn-end { stroke: var(--accent); }
.q-graph .gn-lbl { fill: var(--ink); font-size: 10px; font-weight: 700; }
.q-graph .ge-alt { stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 4 3; }
.q-graph .ge-dead { stroke: var(--down); stroke-width: 1.2; stroke-dasharray: 1 4; opacity: .55; }
.q-graph .ge-best { stroke: var(--accent); stroke-width: 2.5; }
.q-graph .ge-lbl { fill: var(--dim); font-size: 8px; text-transform: uppercase; letter-spacing: .03em; }
.q-graph .ge-lbl-best { fill: var(--accent); font-weight: 700; }
.q-graph .ge-lbl-dead { fill: var(--down); opacity: .7; }
.q-legend { display: flex; gap: 12px; font-size: 10px; color: var(--dim); margin: 2px 0 6px; }
.q-legend .lg { position: relative; padding-left: 16px; }
.q-legend .lg::before { content: ""; position: absolute; left: 0; top: 50%; width: 12px; height: 0; border-top: 2px solid currentColor; }
.q-legend .lg-best { color: var(--accent); }
.q-legend .lg-alt { color: var(--muted); }
.q-legend .lg-alt::before { border-top-style: dashed; }
.q-legend .lg-dead { color: var(--down); }
.q-legend .lg-dead::before { border-top-style: dotted; }
.q-alts { margin-top: 8px; }
.q-alts-h { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 3px; }
.q-alt { display: flex; justify-content: space-between; gap: 8px; font-size: 11px; padding: 2px 0; }
.q-alt span:last-child { color: var(--muted); white-space: nowrap; }

/* Latency + price-impact chips */
.q-lat { font-size: 10px; color: var(--muted); background: var(--bg3); border-radius: 5px; padding: 1px 5px; margin-left: 4px; }
/* Split route */
.split-badge { font-size: 9px; font-weight: 800; letter-spacing: .04em; color: #fff; background: var(--accent); border-radius: 4px; padding: 1px 5px; }
.q-split { border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent); background: color-mix(in srgb, var(--accent) 8%, transparent); border-radius: 10px; padding: 8px 10px; margin: 4px 0 8px; }
.q-split-h { font-size: 12px; font-weight: 700; display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.q-split-imp { font-size: 10px; font-weight: 700; color: var(--up); }
.q-split-part { display: flex; align-items: center; gap: 8px; font-size: 11px; padding: 2px 0; }
.q-split-pct { font-weight: 700; min-width: 34px; }
.q-split-part span:last-child { margin-left: auto; color: var(--muted); white-space: nowrap; }
.q-imp { font-size: 10px; font-weight: 600; border-radius: 5px; padding: 1px 5px; margin-right: 4px; }
.q-imp.imp-lo { color: var(--up); background: color-mix(in srgb, var(--up) 14%, transparent); }
.q-imp.imp-mid { color: #d98a00; background: color-mix(in srgb, #d98a00 16%, transparent); }
.q-imp.imp-hi { color: var(--down); background: color-mix(in srgb, var(--down) 16%, transparent); }

/* Pools-tried list (click to copy the address / v4 pool id) */
.q-pools { margin-top: 8px; }
.q-pools-h { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 4px; }
.q-pool { display: flex; align-items: center; gap: 6px; font-size: 11px; padding: 3px 0; flex-wrap: wrap; }
.q-pool.is-dead { opacity: .5; }
.q-pool-pair { display: flex; align-items: center; gap: 3px; }
.q-pool-tvl { margin-left: auto; font-size: 10px; }
.q-addr { font-family: ui-monospace, monospace; font-size: 10px; color: var(--muted); text-decoration: none; }
a.q-addr:hover { color: var(--accent); text-decoration: underline; }
.q-copy { font-size: 11px; color: var(--dim); background: none; border: none; cursor: pointer; padding: 0 2px; }
.q-copy:hover { color: var(--accent); }
.q-tag { font-size: 9px; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line2); border-radius: 4px; padding: 0 4px; }
.q-tag.best { color: var(--accent); border-color: var(--accent); }
.q-tag.dead { color: var(--down); border-color: transparent; }
.about-head { font-weight: 600; margin-bottom: 8px; }
.about-rows { display: flex; flex-direction: column; }
.arow { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line2); font-size: 13px; }
.arow span { color: var(--muted); }
.arow b { font-variant-numeric: tabular-nums; }
.copy { font-variant-numeric: tabular-nums; color: var(--ink); }
.about-links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.about-links a { padding: 6px 10px; border-radius: 8px; background: var(--bg3); font-size: 12px; }

/* Badges */
.vbadge { display: inline-grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; font-size: 10px; font-weight: 700; vertical-align: middle; }
.vbadge.ok { background: color-mix(in srgb, var(--green) 18%, transparent); color: var(--up); }
.vbadge.warn { background: color-mix(in srgb, var(--down) 20%, transparent); color: var(--down); }
.vbadge.unk { background: var(--bg3); color: var(--muted); }
.badge.pool { font-size: 10px; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line2); border-radius: 5px; padding: 1px 5px; letter-spacing: .03em; }
.badge.warn { font-size: 10px; color: #ff5c5c; border: 1px solid rgba(255,92,92,.5); background: rgba(255,92,92,.12); border-radius: 5px; padding: 1px 5px; letter-spacing: .02em; }
.pair-logos { display: inline-flex; align-items: center; }
.plogo { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; background: var(--bg3); border: 2px solid var(--bg2); }
.plogo.mono { display: grid; place-items: center; font-size: 9px; font-weight: 700; color: var(--muted); }
.plogo-b { margin-left: -8px; }
.pool-link { color: var(--accent); font-size: 12px; font-weight: 600; }
.pool-pill { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line2); white-space: nowrap; }
.pool-pill:hover { color: var(--ink); border-color: var(--accent); }
.pool-pill .pair-logos { flex: none; }

/* Toasts */
.toast-wrap { position: fixed; right: 14px; bottom: 14px; display: flex; flex-direction: column; gap: 8px; z-index: 60; }
.toast { display: flex; align-items: center; gap: 10px; background: var(--bg2); border: 1px solid var(--line2); border-radius: 12px; padding: 10px 12px; box-shadow: 0 10px 30px rgba(0,0,0,.4); opacity: 0; transform: translateY(10px); transition: .3s; }
.toast.show { opacity: 1; transform: none; }
.toast .t-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--up); }
.toast .t-sub { color: var(--muted); font-size: 12px; }

/* ── Stats strip: buys/sells + timeframe % ── */
.tstats { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 2px 2px; flex: none; }
.tstats:empty { display: none; }
.stat-tfs { display: flex; gap: 6px; }
.stat-tf { display: flex; flex-direction: column; align-items: center; background: var(--bg2); border: 1px solid var(--line2); border-radius: 8px; padding: 4px 10px; min-width: 54px; }
.stat-tf .stf-l { font-size: 9px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.stat-tf .stf-v { font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-tf.up .stf-v { color: var(--up); } .stat-tf.down .stf-v { color: var(--down); }
.stat-bs { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.stat-bs .bs-counts, .stat-bs .bs-vol { display: flex; gap: 6px; font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat-bs .up { color: var(--up); } .stat-bs .down { color: var(--down); }
.bs-bar { width: 90px; height: 6px; border-radius: 4px; background: var(--down); overflow: hidden; }
.bs-bar .bs-b { display: block; height: 100%; background: var(--up); }

/* ── Trade card: active pool + pool selection ── */
.bs-pool { font-size: 11px; color: var(--muted); background: var(--bg3); border-radius: 8px; padding: 6px 9px; margin-bottom: 8px; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.bs-pool b { color: var(--ink); }
.pool-row { cursor: pointer; }
.pool-row:hover { background: var(--bg3); }
.pool-row.active { background: color-mix(in srgb, var(--accent) 13%, transparent); }
.pool-row .chart-dot { display: none; font-size: 9px; text-transform: uppercase; letter-spacing: .04em; color: var(--accent); border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent); border-radius: 4px; padding: 0 4px; margin-left: 4px; vertical-align: middle; }
.pool-row.active .chart-dot { display: inline; }

/* ── Ops overlay ── */
.ops-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.55); backdrop-filter: blur(3px); display: grid; place-items: center; z-index: 90; padding: 20px; }
.ops-overlay[hidden] { display: none; }
.ops-panel { width: min(940px, 100%); max-height: 88vh; overflow-y: auto; background: var(--bg2); border: 1px solid var(--line2); border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,.5); }
.ops-head { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line2); background: var(--bg2); font-size: 15px; }
.ops-close { color: var(--muted); font-size: 16px; width: 30px; height: 30px; border-radius: 8px; }
.ops-close:hover { color: var(--ink); background: var(--bg3); }
.ops-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 16px; }
.ops-host { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.ops-meter { background: var(--bg3); border-radius: 10px; padding: 10px 12px; }
.ops-meter-h { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 7px; }
.ops-meter-h span { color: var(--muted); } .ops-meter-h b { font-variant-numeric: tabular-nums; }
.ops-bar { height: 6px; border-radius: 4px; background: var(--line2); overflow: hidden; }
.ops-bar span { display: block; height: 100%; background: var(--accent); }
.ops-meter.warn .ops-bar span { background: #eab308; }
.ops-meter.hot .ops-bar span { background: var(--down); }
.ops-kvs { grid-column: 1 / -1; display: flex; gap: 22px; }
.ops-kv { display: flex; flex-direction: column; }
.ops-kv span { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.ops-kv b { font-size: 14px; font-variant-numeric: tabular-nums; }
/* Per-core CPU: a grid of water-tank meters that fill to each core's load. */
.ops-cores-wrap { grid-column: 1 / -1; }
.ops-cores-h { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 8px; }
.ops-cores-h span { color: var(--muted); } .ops-cores-h b { font-variant-numeric: tabular-nums; color: var(--muted); }
.ops-cores { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 6px; }
.ops-core { position: relative; height: 54px; border-radius: 7px; background: var(--bg3); border: 1px solid var(--line2); overflow: hidden; }
.ops-core-water { position: absolute; left: 0; right: 0; bottom: 0; height: 0; transition: height .6s cubic-bezier(.22,.61,.36,1), background .6s ease; }
.ops-core-water::before { content: ""; position: absolute; left: -50%; width: 200%; top: -6px; height: 12px;
  background: radial-gradient(circle at 9px 12px, transparent 9px, rgba(255,255,255,.45) 9.5px) 0 0/18px 12px repeat-x;
  animation: ops-wave 2.6s linear infinite; opacity: .4; }
@keyframes ops-wave { from { transform: translateX(0); } to { transform: translateX(18px); } }
.ops-core-pct { position: absolute; inset: 0; display: grid; place-items: center; font-size: 11px; font-variant-numeric: tabular-nums; z-index: 2; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.ops-svcs { display: flex; flex-direction: column; gap: 10px; }
.ops-svc { border: 1px solid var(--line2); border-radius: 12px; padding: 11px 13px; }
.ops-svc-h { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.ops-dot { width: 9px; height: 9px; border-radius: 50%; }
.ops-dot.ok { background: var(--up); } .ops-dot.down { background: var(--down); }
.ops-det { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.ops-tables { display: flex; flex-wrap: wrap; gap: 6px; width: 100%; margin-top: 2px; }
.ops-tag { font-size: 11px; color: var(--muted); background: var(--bg3); border-radius: 6px; padding: 3px 7px; }
.ops-tag b { color: var(--ink); font-variant-numeric: tabular-nums; }
@media (max-width: 560px) { .ops-host { grid-template-columns: 1fr; } }

/* ── Social feed rows (Pump/Fomo callouts) ── */
.social-row { display: flex; gap: 9px; padding: 9px 12px; border-bottom: 1px solid var(--line2); align-items: flex-start; }
.social-row:hover { background: var(--bg3); }
.srow-av { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; background: var(--bg3); flex: none; }
.srow-av.mono { display: grid; place-items: center; font-weight: 700; color: var(--muted); font-size: 12px; }
.srow-main { min-width: 0; flex: 1; }
.srow-top { display: flex; align-items: center; gap: 5px; }
.srow-name { font-weight: 700; font-size: 12.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 120px; }
a.srow-name:hover { color: var(--accent); }
.srow-src { width: 14px; height: 14px; border-radius: 4px; object-fit: contain; flex: none; }
.srow-time { margin-left: auto; font-size: 11px; white-space: nowrap; }
.srow-tok { display: flex; align-items: center; gap: 6px; font-size: 12px; margin-top: 2px; }
.srow-tok a { font-weight: 700; color: var(--ink); }
.srow-tok a:hover { color: var(--accent); }
.srow-tok .prem.up { color: var(--up); } .srow-tok .prem.down { color: var(--down); }
.srow-text { font-size: 12px; color: var(--muted); margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.srow-eng { font-size: 11px; margin-top: 3px; }

/* Search ⌘K/Ctrl-K hint */
.search-kbd { flex: none; font-size: 10px; font-weight: 600; color: var(--muted); background: var(--bg3); border: 1px solid var(--line2); border-radius: 5px; padding: 1px 5px; letter-spacing: .02em; white-space: nowrap; }
.tsearch:focus-within .search-kbd { display: none; }

/* ── Mobile / narrow screens: stack the 3-column terminal into one scrollable column ── */
@media (max-width: 820px) {
  body.terminal { overflow-y: auto; overflow-x: hidden; }
  /* Header: brand + right on one row, search full-width below. */
  .tbar { grid-template-columns: auto 1fr; grid-template-areas: "brand right" "search search"; gap: 8px 10px; padding: 8px 10px; }
  .brand { grid-area: brand; } .tbar-right { grid-area: right; } .tsearch { grid-area: search; max-width: none; flex: none; width: 100%; }
  .mark-img { width: 32px; height: 32px; }
  /* Stack the columns; let the page scroll instead of each column. */
  .tgrid { display: flex; flex-direction: column; gap: 10px; padding: 10px; overflow: visible; height: auto; }
  .rail, .center, .side { overflow: visible; flex: none; height: auto; }
  .side { display: flex; } /* show the trade/about column (hidden on tablet) */
  /* The active rail-pane is position:absolute (fills a flex-sized body on desktop); on mobile the
     rail is auto-height, so an absolute pane gives the body zero height — the rail collapses to a
     sliver. Let the active pane flow normally here, with its own scroll cap. */
  .rail-body { flex: none; height: auto; min-height: 0; position: static; overflow: visible; }
  .rail-pane { position: static; inset: auto; max-height: 70vh; overflow-y: auto; }
  .chart { height: 300px; min-height: 300px; flex: none; }
  .chart-wrap { flex: none; }
  .ctab-body, #pane-pools, #pane-swaps { max-height: 65vh; }
  .search-dd { width: 94vw; }
  .search-kbd { display: none; }
}

/* ── Profile popover — a compact card pinned beside the clicked username (JS sets left/top) ── */
.pf-pop { position: fixed; z-index: 220; width: 322px; max-width: calc(100vw - 16px); max-height: 78vh; overflow-y: auto; overscroll-behavior: contain; background: var(--bg2); border: 1px solid var(--line2); border-radius: 14px; box-shadow: 0 14px 44px rgba(0,0,0,.5); padding: 14px 14px 12px; }
.pf-pop[hidden] { display: none; }
.pf-close { position: absolute; top: 9px; right: 9px; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 7px; border: none; background: transparent; color: var(--dim); font-size: 13px; line-height: 1; cursor: pointer; z-index: 1; }
.pf-close:hover { color: var(--ink); background: var(--bg3); }
.pf-tabs { display: flex; gap: 6px; margin-bottom: 12px; }
.pf-tab { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line2); background: transparent; color: var(--muted); font-weight: 700; font-size: 11.5px; text-transform: capitalize; cursor: pointer; }
.pf-tab img { width: 15px; height: 15px; border-radius: 4px; }
.pf-tab.active { color: var(--ink); background: var(--bg3); border-color: var(--bg3); }
.pf-head { display: flex; gap: 11px; align-items: center; padding-right: 22px; }
.pf-av { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--bg3); font-size: 18px; color: var(--muted); }
.pf-id { min-width: 0; flex: 1; }
.pf-name { display: flex; align-items: center; gap: 6px; font-weight: 800; font-size: 15px; color: var(--ink); line-height: 1.2; }
.pf-nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-src { width: 15px; height: 15px; border-radius: 4px; flex: none; }
.pf-bio { color: var(--muted); font-size: 12px; margin-top: 2px; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pf-wallet { display: flex; align-items: center; gap: 7px; margin-top: 5px; font-size: 11px; }
.pf-wallet .wallet-copy { padding: 0 2px; background: transparent; border: none; color: var(--dim); cursor: pointer; }
.pf-wallet .wallet-copy:hover { color: var(--ink); }
.pf-venue-link { text-decoration: none; margin-left: auto; white-space: nowrap; }
.pf-venue-link:hover { color: var(--ink); }
.pf-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(62px, 1fr)); gap: 8px; margin: 12px 0; padding: 11px 0; border-top: 1px solid var(--line2); border-bottom: 1px solid var(--line2); }
.pf-stat { text-align: center; min-width: 0; }
.pf-stat-v { font-weight: 800; font-size: 12.5px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-stat-v.up { color: var(--up); } .pf-stat-v.down { color: var(--down); }
.pf-stat-l { font-size: 9.5px; text-transform: uppercase; letter-spacing: .03em; margin-top: 2px; }
.pf-sec-h { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); font-weight: 700; margin: 12px 0 6px; }
/* Theses + holdings: fixed-height scroll panes showing the FULL list (images lazy-load on scroll). */
.pf-theses, .pf-trades { max-height: 188px; overflow-y: auto; overscroll-behavior: contain; padding-right: 4px; }
.pf-theses::-webkit-scrollbar, .pf-trades::-webkit-scrollbar { width: 6px; }
.pf-thesis { padding: 7px 0; border-top: 1px solid var(--line2); }
.pf-thesis:first-of-type { border-top: none; padding-top: 0; }
.pf-th-top { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.pf-th-eng { margin-left: auto; font-size: 10.5px; white-space: nowrap; }
.pf-th-text { color: var(--muted); font-size: 11.5px; margin-top: 3px; line-height: 1.4; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pf-trade { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-top: 1px solid var(--line2); font-size: 12px; }
.pf-trade:first-of-type { border-top: none; }
.pf-trade b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 96px; }
.pf-tk-logo { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--bg3); font-size: 9px; }
.pf-tag { font-size: 9px; font-weight: 800; letter-spacing: .02em; flex: none; }
.pf-tk-usd { margin-left: auto; color: var(--muted); white-space: nowrap; }
.pf-tk-pnl { min-width: 48px; text-align: right; font-weight: 700; white-space: nowrap; }
.pf-open { cursor: pointer; }
.srow-name.pf-open:hover, .frow-sub .pf-open:hover { text-decoration: underline; }
.feed-row.pf-open { cursor: pointer; text-decoration: none; }

/* ── Live-update flash: brief highlight when a cell changes from a WS push (holders / pool / token
   metrics). Theme-agnostic accent that fades to transparent. ── */
.live-flash { animation: liveflash 0.9s ease-out; }
@keyframes liveflash {
  from { background-color: rgba(56, 189, 248, 0.34); }
  to { background-color: transparent; }
}
.live-holders { border-radius: 3px; transition: background-color 0.2s; }

/* ── Wallet holdings (right rail) ── */
.tnav-wallet.connected { color: var(--accent, #6aa3ff); border-color: currentColor; font-family: ui-monospace, Menlo, monospace; }
.holdings-card { border: 1px solid var(--line, #1c202a); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.hold-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 6px; }
.hold-head b { font-size: 13px; }
.hold-sub { font-size: 11px; }
.hold-check { margin-bottom: 8px; }
.hold-check input { width: 100%; box-sizing: border-box; background: var(--bg); border: 1px solid var(--line2); border-radius: 8px; color: var(--ink); font: inherit; font-size: 12px; padding: 6px 9px; outline: none; }
.hold-check input:focus { border-color: var(--accent); }
.hold-body { display: flex; flex-direction: column; gap: 2px; max-height: 260px; overflow-y: auto; }
.hold-row { display: flex; align-items: center; gap: 8px; width: 100%; background: none; border: 0; padding: 6px 4px; border-radius: 7px; cursor: pointer; text-align: left; color: inherit; }
.hold-row:hover { background: var(--hover, rgba(255,255,255,0.05)); }
.hold-logo { width: 22px; height: 22px; border-radius: 50%; flex: 0 0 auto; }
.hold-main { min-width: 0; flex: 1; }
.hold-sym { font-weight: 600; font-size: 13px; }
.hold-name { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hold-bal { font-family: ui-monospace, Menlo, monospace; font-size: 12px; white-space: nowrap; }
