:root {
  --bg: #0b0e15;
  --panel: #11151f;
  --panel-2: #171c29;
  --line: #232a3b;
  --text: #e6e9f2;
  --muted: #8a93a8;
  --accent: #22d3a6;
  --accent-2: #7c6cff;
  --up: #22d3a6;
  --down: #ff5c7a;
  --warn: #ffb547;
  --new: #7c6cff;
  --mono: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
/* Always reserve the vertical scrollbar's width. Without this, changing the row
   count (e.g. re-sorting the pool table) toggles the scrollbar, which shifts the
   page width by ~15px; when that crosses a @container breakpoint the pool table
   hides/shows a column and the remaining columns jump wider — reads as a sudden
   "zoom" / format change. */
html { scrollbar-gutter: stable; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.45 Inter, system-ui, -apple-system, Segoe UI, sans-serif;
  min-height: 100vh;
}
button { font: inherit; color: inherit; cursor: pointer; }
input { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.pad { padding: 18px; }
.r { text-align: right; }
.num, td.r { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 13px; }

.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 16px;
  padding: 10px 20px;
  background: rgba(11, 14, 21, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; white-space: nowrap; }
.brand b { color: var(--accent); }
.chips { display: flex; gap: 8px; flex: 1; min-width: 0; flex-wrap: wrap; }
.chip {
  display: flex; align-items: center; gap: 7px; min-width: 0; max-width: 100%;
  padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--panel); font-family: var(--mono); font-size: 12.5px; white-space: nowrap;
}
.chip span { overflow: hidden; text-overflow: ellipsis; }
.chip img { width: 16px; height: 16px; border-radius: 50%; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); display: inline-block; flex: none; }
.dot.ok, .dot.live { background: var(--accent); box-shadow: 0 0 0 0 rgba(34, 211, 166, .6); animation: pulse 2s infinite; }
.dot.bad { background: var(--down); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(34, 211, 166, .55); } 70% { box-shadow: 0 0 0 7px rgba(34, 211, 166, 0); } 100% { box-shadow: 0 0 0 0 rgba(34, 211, 166, 0); } }
.actions { display: flex; gap: 8px; }

.btn {
  border: 1px solid var(--line); background: var(--panel-2);
  padding: 8px 14px; border-radius: 10px; font-weight: 500; white-space: nowrap;
  transition: background .15s, border-color .15s, opacity .15s;
}
.btn:hover { border-color: #37415a; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #04120d; font-weight: 600; }
.btn.primary:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; }
.btn.sm { padding: 5px 10px; font-size: 12.5px; border-radius: 8px; }
.btn.danger { color: var(--down); }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.search { padding: 18px 20px 6px; max-width: 1480px; margin: 0 auto; }
.search form { display: flex; gap: 10px; }
.search input {
  flex: 1; min-width: 0; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--panel); font-family: var(--mono); font-size: 13.5px; outline: none;
}
.search input:focus { border-color: var(--accent); }
.recent { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.recent button {
  display: flex; align-items: center; gap: 6px;
  border: 1px solid var(--line); background: var(--panel); border-radius: 999px; padding: 3px 10px 3px 4px; font-size: 12.5px;
}
.recent img { width: 18px; height: 18px; border-radius: 50%; }

main { max-width: 1480px; margin: 0 auto; padding: 10px 20px 60px; }
.empty { padding: 60px 0; max-width: 720px; }
.empty h1 { font-size: 26px; line-height: 1.25; margin: 0 0 12px; }
.empty p { color: var(--muted); font-size: 15px; }

.token-card {
  display: grid; grid-template-columns: auto 1fr auto; grid-template-areas: "icon id watch" "stats stats stats";
  gap: 12px 16px; align-items: center;
  padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel);
}
.token-card > img { grid-area: icon; width: 44px; height: 44px; border-radius: 50%; background: var(--panel-2); }
.tok-id { grid-area: id; min-width: 0; }
.tok-name { font-size: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tok-name span { color: var(--muted); font-size: 14px; }
.mint { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; border: 0; background: none; padding: 0; color: var(--muted); font-family: var(--mono); font-size: 12px; }
.mint:hover { color: var(--text); }
.tok-stats { grid-area: stats; display: flex; gap: 28px; flex-wrap: wrap; }
.tok-stats label { display: block; color: var(--muted); font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; }
.tok-stats b { font-family: var(--mono); font-size: 17px; font-weight: 600; }
.watch { grid-area: watch; display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12.5px; }

.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 16px 0 10px; }
.seg { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--panel); }
.seg button { border: 0; background: none; padding: 6px 12px; font-size: 13px; color: var(--muted); }
.seg button.on { background: var(--panel-2); color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); }
.create-btn { margin-left: auto; }
/* Фи/TVL custom-threshold panel ("⚙ фильтр"): free-form numeric inputs. */
.yl-custom { gap: 8px 14px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); margin-top: 0; }
.yl-custom label { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.yl-custom input { width: 72px; padding: 5px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font-family: var(--mono); font-size: 12.5px; outline: none; }
.yl-custom input:focus { border-color: var(--accent); }
.yl-custom .dash { color: var(--muted); opacity: .6; margin: 0 -2px; }
.yl-custom .yl-sep { color: var(--muted); opacity: .7; padding: 0 2px 0 6px; border-left: 1px solid var(--line); margin-left: 4px; }
.yl-custom input::placeholder { color: var(--muted); opacity: .55; }
.yl-custom #cfReset { margin-left: 4px; }
.field select { padding: 9px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font-family: var(--mono); font-size: 13px; outline: none; }
.check { display: inline-flex; gap: 6px; align-items: center; color: var(--muted); font-size: 13px; cursor: pointer; }

.table-wrap { border: 1px solid var(--line); border-radius: 14px; overflow-x: auto; background: var(--panel); }
table.pools { width: 100%; border-collapse: collapse; min-width: 1100px; }
.pools th {
  text-align: left; font-weight: 500; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em;
  padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; background: var(--panel);
}
.pools th.r { text-align: right; }
.pools td { padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; vertical-align: middle; }
.pools tr:last-child td { border-bottom: 0; }
.pools tbody tr:hover td { background: rgba(255, 255, 255, .02); }
.pair { display: flex; align-items: center; gap: 8px; }
.venue-logo { width: 17px; height: 17px; border-radius: 50%; flex: none; opacity: .95; }
.pair .icons { display: flex; }
.pair .icons img { width: 22px; height: 22px; border-radius: 50%; background: var(--panel-2); border: 2px solid var(--panel); }
.pair .icons img + img { margin-left: -8px; }
.pair b { font-weight: 600; }
.sub { display: block; color: var(--muted); font-size: 11.5px; font-family: var(--mono); }
/* Source chip: chain family (SOL/EVM) + venue/chain, shown in every row's name
   cell so it never hides when the "Площадка" column collapses on narrow screens. */
.srcchip { display: inline-flex; align-items: center; gap: 4px; margin-right: 7px; padding: 1px 6px; border-radius: 999px; font-size: 9.5px; font-weight: 700; letter-spacing: .06em; line-height: 1.5; vertical-align: 1px; white-space: nowrap; }
.srcchip i { font-style: normal; font-weight: 600; font-size: 10px; letter-spacing: 0; opacity: .88; }
.srcchip.sol { color: #c3a6ff; background: rgba(177, 140, 255, .13); box-shadow: inset 0 0 0 1px rgba(177, 140, 255, .30); }
.srcchip.evm { color: #9cc0ff; background: rgba(143, 180, 255, .13); box-shadow: inset 0 0 0 1px rgba(143, 180, 255, .30); }
/* Matching colored left edge on each row — the "side" marker for SOL vs EVM. */
table.live tr.row-sol > td:first-child { box-shadow: inset 3px 0 0 rgba(177, 140, 255, .5); }
table.live tr.row-evm > td:first-child { box-shadow: inset 3px 0 0 rgba(143, 180, 255, .5); }
.tag { display: inline-block; padding: 1px 7px; border-radius: 6px; font-size: 11.5px; font-weight: 600; background: var(--panel-2); border: 1px solid var(--line); }
.tag.raydium { color: var(--accent); }
.tag.orca { color: #ffd166; }
.tag.meteora { color: #b18cff; }
.tag.new { background: var(--new); border-color: var(--new); color: #fff; animation: blink 1.2s ease-in-out 6; }
.tag.stock { background: #1f7a4d; border-color: #2fae6e; color: #eafff4; font-size: 10.5px; letter-spacing: .3px; vertical-align: 1px; }
.tag.index { background: #3a2f7a; border-color: #6a5acd; color: #e7e3ff; font-size: 10.5px; letter-spacing: .3px; vertical-align: 1px; }
.tag.index.new { background: #5a3ba8; border-color: #8f6fff; color: #fff; animation: blink 1.2s ease-in-out 6; }
.tag.warn { color: var(--warn); }
@keyframes blink { 50% { opacity: .35; } }
tr.fresh td { background: rgba(124, 108, 255, .10); }
tr.fresh td:first-child { box-shadow: inset 3px 0 0 var(--new); }
.up { color: var(--up); }
.down { color: var(--down); }
.flash-up { animation: fu .9s; }
.flash-down { animation: fd .9s; }
@keyframes fu { from { background: rgba(34, 211, 166, .28); } to { background: transparent; } }
@keyframes fd { from { background: rgba(255, 92, 122, .28); } to { background: transparent; } }
td .btns { display: flex; gap: 6px; justify-content: flex-end; }
.linkbtn { color: var(--muted); font-size: 12px; border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; }
.linkbtn:hover { color: var(--text); }

.positions { margin-top: 22px; }
.pos-head { display: flex; align-items: center; gap: 16px; margin-bottom: 10px; }
.pos-head h2 { font-size: 16px; margin: 0; }
.range-bar { position: relative; height: 6px; border-radius: 3px; background: var(--panel-2); margin-top: 5px; min-width: 120px; }
.range-bar i { position: absolute; top: -3px; width: 2px; height: 12px; background: var(--text); }
.range-bar span { position: absolute; top: 0; bottom: 0; background: rgba(34, 211, 166, .45); border-radius: 3px; }

.modal { position: fixed; inset: 0; z-index: 50; background: rgba(3, 5, 10, .72); display: flex; align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; }
.sheet { position: relative; width: 100%; max-width: 640px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 22px; }
.sheet.narrow { max-width: 480px; }
.sheet h2 { margin: 0 0 14px; font-size: 18px; }
.sheet h3 { margin: 18px 0 8px; font-size: 13px; color: var(--muted); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.x { position: absolute; top: 14px; right: 14px; border: 0; background: var(--panel-2); width: 30px; height: 30px; border-radius: 8px; color: var(--muted); }
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 10px; }
.field span { color: var(--muted); font-size: 12.5px; }
.field input:not([type=checkbox]) { padding: 9px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-family: var(--mono); font-size: 13.5px; outline: none; }
.field input:focus { border-color: var(--accent); }
.field.check { flex-direction: row; align-items: center; margin-top: 22px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.hint { color: var(--muted); font-size: 12.5px; margin: 2px 0 12px; }
.row-end { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
.wallet-list { display: flex; flex-direction: column; gap: 8px; }
.wallet-list button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2); text-align: left; }
.wallet-list img { width: 26px; height: 26px; border-radius: 6px; }

.lp-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; padding-right: 36px; }
.lp-head .pair .icons img { width: 28px; height: 28px; }
.lp-price { display: flex; gap: 20px; flex-wrap: wrap; padding: 12px 14px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; margin-top: 12px; }
.lp-price label { display: block; color: var(--muted); font-size: 11.5px; }
.lp-price b { font-family: var(--mono); font-size: 16px; }
.unit { margin-left: auto; }
.presets { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.presets button { border: 1px solid var(--line); background: var(--panel-2); border-radius: 8px; padding: 4px 9px; font-size: 12.5px; }
.presets button.on { border-color: var(--accent); color: var(--accent); }
.range-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.rbox { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.rbox label { color: var(--muted); font-size: 12px; display: flex; justify-content: space-between; }
.rbox input { width: 100%; border: 0; background: none; outline: none; font-family: var(--mono); font-size: 18px; padding: 4px 0; }
.rbox .conv { color: var(--muted); font-family: var(--mono); font-size: 12px; }
/* the price field with its one-tick nudge buttons beside it */
.withstep { display: flex; align-items: center; gap: 6px; }
.withstep input { flex: 1; min-width: 0; }
.step { display: inline-flex; gap: 4px; flex: none; }
.step button {
  width: 30px; height: 30px; padding: 0; line-height: 1;
  border: 1px solid var(--line); border-radius: 8px;
  background: var(--panel-2); color: var(--text);
  font-size: 17px; font-family: var(--mono); cursor: pointer;
}
.step button:hover { border-color: var(--accent); color: var(--accent); }
.step button:active { transform: translateY(1px); }
.rbox .pct { font-family: var(--mono); font-size: 12px; }
.amt { display: flex; align-items: center; gap: 10px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
.amt img { width: 26px; height: 26px; border-radius: 50%; }
.amt .sym { font-weight: 600; min-width: 56px; }
.amt input { flex: 1; min-width: 0; border: 0; background: none; outline: none; text-align: right; font-family: var(--mono); font-size: 18px; }
.amt .bal { display: block; color: var(--muted); font-size: 11.5px; font-family: var(--mono); text-align: right; }
.amt .bal button { border: 0; background: none; color: var(--accent); padding: 0 0 0 6px; font-size: 11.5px; }
.amt.disabled { opacity: .45; }
.summary { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 13px; }
.summary div { display: flex; justify-content: space-between; padding: 2px 0; }
.summary span:last-child { font-family: var(--mono); }
.inline-fields { display: flex; gap: 12px; align-items: flex-end; margin: 12px 0; flex-wrap: wrap; }
.inline-fields .field { margin: 0; }
.inline-fields .field input { width: 130px; }
.slip-presets { display: flex; gap: 4px; }
.slip-presets button { border: 1px solid var(--line); background: var(--panel-2); border-radius: 8px; padding: 7px 9px; font-size: 12.5px; }
.submit { width: 100%; padding: 13px; font-size: 15px; margin-top: 12px; }
.warnbox { border: 1px solid rgba(255, 181, 71, .35); background: rgba(255, 181, 71, .08); color: var(--warn); border-radius: 10px; padding: 8px 12px; font-size: 13px; margin-top: 10px; }

.gate { position: fixed; inset: 0; z-index: 90; background: var(--bg); display: flex; align-items: center; justify-content: center; padding: 20px; }
.gate-card { display: flex; flex-direction: column; gap: 10px; align-items: stretch; width: 100%; max-width: 320px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 26px 22px; text-align: center; }
.gate-card svg { align-self: center; }
.gate-card h1 { font-size: 18px; margin: 4px 0 0; font-weight: 600; }
.gate-card h1 b { color: var(--accent); }
.gate-card p { margin: 0 0 6px; font-size: 13px; }
.gate-card input[type=password] { padding: 11px 13px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-family: var(--mono); font-size: 14px; outline: none; text-align: center; }
.gate-card input[type=password]:focus { border-color: var(--accent); }
.gate-err { color: var(--down); font-size: 12.5px; }
.paused .dot { background: var(--warn) !important; animation: none !important; }
.pausebar { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid rgba(255, 181, 71, .35); background: rgba(255, 181, 71, .08); color: var(--warn); border-radius: 12px; margin: 12px 0; font-size: 13px; }
.pausebar .btn { margin-left: auto; }

.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 80; display: flex; flex-direction: column; gap: 8px; max-width: min(420px, calc(100vw - 32px)); }
.toast { background: var(--panel-2); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 12px; padding: 10px 14px; font-size: 13px; box-shadow: 0 10px 30px rgba(0, 0, 0, .4); word-break: break-word; }
.toast.err { border-left-color: var(--down); }
.toast.new { border-left-color: var(--new); }
.toast b { display: block; margin-bottom: 2px; }

@media (max-width: 760px) {
  .top { flex-wrap: wrap; padding: 10px 16px; }
  .chips { order: 3; flex-basis: 100%; }
  .actions { margin-left: auto; flex-wrap: wrap; justify-content: flex-end; min-width: 0; }
  .actions .btn { padding: 8px 10px; }
  #walletBtn { max-width: 52vw; overflow: hidden; text-overflow: ellipsis; }
  .search, main { padding-left: 16px; padding-right: 16px; }
  .search form { flex-direction: column; }
  .token-card { grid-template-columns: auto 1fr; grid-template-areas: "icon id" "watch watch" "stats stats"; }
  .tok-stats { gap: 16px; }
  .range-grid, .grid2 { grid-template-columns: 1fr; }
  .modal { padding: 12px; }
  .sheet { padding: 18px 14px; }
}

/* ---------------------------------------------------------- liquidity book */
.book-btn.on { border-color: var(--accent); color: var(--accent); }
.pools tbody tr[data-id] { cursor: pointer; }
.book {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 40;
  width: min(600px, 100vw); display: flex; flex-direction: column;
  background: var(--panel); border-left: 1px solid var(--line);
  box-shadow: -18px 0 40px rgba(0, 0, 0, .45);
}
.book-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 8px; position: relative; padding-right: 54px; }
.book-head .x { top: 14px; right: 14px; }
.book-ctl { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 4px 16px 10px; }
.book-ctl .seg button { padding: 4px 9px; font-size: 12px; }
.book-sum { display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 10px 16px; margin: 0 16px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; }
.book-sum label { display: block; color: var(--muted); font-size: 11px; }
.book-sum b { font-family: var(--mono); font-size: 13.5px; font-weight: 600; }
.warn-inline { color: var(--warn); font-size: 12px; align-self: center; }
.book-scroll { flex: 1; overflow-y: auto; margin-top: 10px; border-top: 1px solid var(--line); }
.book-t { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.book-t th { position: sticky; top: 0; z-index: 1; background: var(--panel); color: var(--muted); font-weight: 500; font-size: 11px; text-transform: uppercase; letter-spacing: .03em; text-align: left; padding: 7px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.book-t th.r { text-align: right; }
.book-t td { padding: 4px 8px; border-bottom: 1px solid rgba(35, 42, 59, .55); white-space: nowrap; font-family: var(--mono); font-variant-numeric: tabular-nums; }
.book-t td.bp { font-weight: 600; position: relative; }
.book-t tr.ask td.bp { color: var(--down); }
.book-t tr.bid td.bp { color: var(--up); }
.book-t tr.cur td { background: rgba(124, 108, 255, .14); }
.book-t tr.cur td:first-child { box-shadow: inset 3px 0 0 var(--new); }
.book-t td.bl { position: relative; min-width: 150px; width: 40%; }
.book-t td.bl .bar { position: absolute; left: 0; top: 3px; bottom: 3px; border-radius: 0 4px 4px 0; opacity: .22; }
.book-t tr.ask .bar { background: var(--down); }
.book-t tr.bid .bar { background: var(--up); }
.book-t tr.cur .bar { background: var(--new); opacity: .35; }
.book-t td.bl > span { position: relative; }
.book-t .sub { font-size: 10.5px; }
.book-t tr.fee-up td { animation: feeflash 1.1s; }
@keyframes feeflash { from { background: rgba(34, 211, 166, .30); } to { background: transparent; } }
.own-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--warn); margin-right: 5px; vertical-align: middle; }
.bk-add { width: 26px; height: 24px; padding: 0; border: 1px solid var(--line); border-radius: 7px; background: var(--panel-2); color: var(--accent); font-weight: 700; font-size: 15px; line-height: 1; }
.bk-add:hover { border-color: var(--accent); background: rgba(34, 211, 166, .12); }
.book-foot { padding: 8px 16px 12px; font-size: 11.5px; border-top: 1px solid var(--line); }
.book-hint { border: 1px solid rgba(124, 108, 255, .4); background: rgba(124, 108, 255, .08); color: var(--text); border-radius: 10px; padding: 8px 12px; }
@media (min-width: 1400px) {
  body.book-open main, body.book-open .search { margin-right: 600px; margin-left: 0; }
}
@media (max-width: 760px) {
  .book-t td.bl { min-width: 110px; }
  .book-t th:nth-child(4), .book-t td:nth-child(4) { display: none; }
}
/* ------------------------------------------------------- admin: screener */
.tabs { display: flex; gap: 2px; border: 1px solid var(--line); border-radius: 10px; padding: 2px; background: var(--panel); }
.tabs button { border: 0; background: none; color: var(--muted); padding: 5px 12px; border-radius: 8px; font-size: 13px; font-weight: 500; }
.tabs button.on { background: var(--panel-2); color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); }
.screen { max-width: 1680px; }
.scr-head { display: flex; gap: 20px; align-items: flex-start; justify-content: space-between; margin: 8px 0 4px; }
.scr-head h1 { font-size: 22px; margin: 0 0 4px; }
.scr-head p { margin: 0; max-width: 820px; font-size: 13.5px; }
.scr-status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12.5px; white-space: nowrap; font-family: var(--mono); }
.scr-q { padding: 7px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); font-family: var(--mono); font-size: 13px; outline: none; min-width: 200px; }
.scr-q:focus { border-color: var(--accent); }
table.scr { min-width: 1250px; }
.spike { font-family: var(--mono); font-weight: 600; }
.spike.warm { color: var(--warn); }
.spike.hot { color: #fff; background: var(--down); padding: 1px 6px; border-radius: 6px; }
tr.hotrow td { background: rgba(255, 92, 122, .07); }
tr.hotrow td:first-child { box-shadow: inset 3px 0 0 var(--down); }
.scr-note { font-size: 12px; margin-top: 10px; }
@media (max-width: 760px) { .scr-head { flex-direction: column; } .tabs { order: 2; } }
/* ------------------------------------------------------- admin: live */
.scr-mode { margin-top: 6px; display: inline-flex; }
.scr-mode button { font-size: 13px; padding: 6px 14px; }
.live-alerts { display: flex; flex-direction: column; gap: 5px; margin: 10px 0 4px; }
.live-alerts:empty { display: none; }
.alert { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; text-align: left; border: 1px solid var(--line); border-left: 3px solid var(--warn); background: var(--panel); border-radius: 10px; padding: 6px 10px; font-size: 12.5px; font-family: var(--mono); }
.alert img { width: 16px; height: 16px; border-radius: 50%; }
.alert.fast { border-left-color: var(--down); }
.alert.main { border-left-color: var(--warn); }
.alert.new { border-left-color: var(--new); }
.alert.yield { border-left-color: var(--accent); }
.alert:hover { border-color: #37415a; }
table.live td { padding: 7px 10px; }
table.live tr.fee-up td { animation: feeflash 1.1s; }
.tag.pump { color: #5fe3a1; }
.solo-tag { color: var(--accent) !important; font-weight: 600; }
.book-sum .warn-inline { flex-basis: 100%; }


/* ------------------------------------------------------- admin: watchlist */
.star { border: 0; background: none; color: var(--muted); font-size: 16px; padding: 0 2px; line-height: 1; }
.star.on { color: #ffd166; }
.star:hover { color: #ffd166; }
.watch-h { font-size: 13px; color: var(--muted); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; margin: 14px 0 8px; }
.watch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); gap: 10px; }
.wcard { border: 1px solid var(--line); background: var(--panel); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.whead { display: flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 13px; }
.whead img { width: 22px; height: 22px; border-radius: 50%; }
.whead .wx { margin-left: auto; border: 0; background: var(--panel-2); color: var(--muted); border-radius: 6px; width: 24px; height: 24px; }
.wnums { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; }
.wnums label { display: block; color: var(--muted); font-size: 10.5px; }
.wnums b { font-family: var(--mono); font-size: 13px; }
.wchart label { display: block; color: var(--muted); font-size: 10.5px; margin-bottom: 2px; }
.bars rect { fill: var(--accent); opacity: .85; }
.bars.sec rect { fill: var(--accent-2); }
.wbest { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; }
.wbest .btn { margin-left: 6px; }
.wticks { font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
.wticks b { color: var(--text); }
/* ============================================================ fit to size ==
   Every table hides its less important columns by the width of its own box
   (container queries), so an open book, a narrow window or a phone never
   push the page sideways. The wrapper keeps overflow-x as the last resort. */
.table-wrap { container-type: inline-size; max-width: 100%; }
table.pools, table.scr { min-width: 0 !important; }
.pools th, .pools td { padding: 8px 9px; }
.pools td .btns { gap: 4px; }
.pools .btn.sm { padding: 4px 8px; }
.pair { min-width: 0; }
.pair b { white-space: nowrap; }
main, .search, .screen { max-width: 100%; min-width: 0; }
.toolbar { min-width: 0; }
.toolbar .seg, .book-ctl .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.toolbar .seg::-webkit-scrollbar, .book-ctl .seg::-webkit-scrollbar { display: none; }
.seg button { white-space: nowrap; }
.scr-q { min-width: 0; flex: 1 1 160px; max-width: 320px; }
.top { flex-wrap: wrap; row-gap: 8px; }
.chips { min-width: 0; }

/* terminal pools: 1 pool 2 venue 3 price 4 price$ 5 tvl 6 in pool 7 vol/fees 8 earned 9 age 10 buttons */
@container (max-width: 1500px) { table.ptbl :is(th, td):nth-child(6) { display: none; } }
@container (max-width: 1300px) { table.ptbl :is(th, td):nth-child(4) { display: none; } }
@container (max-width: 1120px) { table.ptbl :is(th, td):nth-child(9) { display: none; } }
@container (max-width: 960px)  { table.ptbl :is(th, td):nth-child(7) { display: none; } }
@container (max-width: 760px)  { table.ptbl :is(th, td):nth-child(2) { display: none; } }
@container (max-width: 560px)  { table.ptbl :is(th, td):nth-child(5) { display: none; } }

/* live pools: 1 pool 2 venue 3 tvl 4 10s 5 30s 6 1m 7 5m 8 1h 9 24h 10 swaps 11 apr5m 12 apr24h 13 spike 14 solo 15 buttons */
@container (max-width: 1560px) { table.live[data-view=pools] :is(th, td):is(:nth-child(5), :nth-child(12)) { display: none; } }
@container (max-width: 1360px) { table.live[data-view=pools] :is(th, td):is(:nth-child(10), :nth-child(9)) { display: none; } }
@container (max-width: 1160px) { table.live[data-view=pools] :is(th, td):is(:nth-child(4), :nth-child(2)) { display: none; } }
@container (max-width: 940px)  { table.live[data-view=pools] :is(th, td):is(:nth-child(8), :nth-child(3)) { display: none; } }
@container (max-width: 720px)  { table.live[data-view=pools] :is(th, td):is(:nth-child(7), :nth-child(14)) { display: none; } }
@container (max-width: 480px)  { table.live[data-view=pools] :is(th, td):nth-child(13) { display: none; } }

/* live tokens: 1 token 2 pools 3 tvl 4 10s 5 1m 6 5m 7 1h 8 24h 9 spike 10 best 11 buttons */
@container (max-width: 1150px) { table.live[data-view=tokens] :is(th, td):is(:nth-child(2), :nth-child(8)) { display: none; } }
@container (max-width: 920px)  { table.live[data-view=tokens] :is(th, td):is(:nth-child(4), :nth-child(10)) { display: none; } }
@container (max-width: 620px)  { table.live[data-view=tokens] :is(th, td):is(:nth-child(3), :nth-child(7)) { display: none; } }

/* live new pools: 1 pool 2 venue 3 created 4 tvl 5 1m 6 5m 7 1h 8 swaps 9 apr5m 10 solo 11 buttons */
@container (max-width: 1150px) { table.live[data-view=new] :is(th, td):is(:nth-child(8), :nth-child(7)) { display: none; } }
@container (max-width: 920px)  { table.live[data-view=new] :is(th, td):is(:nth-child(2), :nth-child(10)) { display: none; } }
@container (max-width: 620px)  { table.live[data-view=new] :is(th, td):is(:nth-child(4), :nth-child(6)) { display: none; } }

/* venue-API screener: 1 pool 2 venue 3 tvl 4 $/min 5 short 6 1h 7 24h 8 apr now 9 apr24h 10 spike 11 turnover 12 buttons */
@container (max-width: 1250px) { #scrApi table :is(th, td):is(:nth-child(11), :nth-child(6)) { display: none; } }
@container (max-width: 1000px) { #scrApi table :is(th, td):is(:nth-child(2), :nth-child(9)) { display: none; } }
@container (max-width: 700px)  { #scrApi table :is(th, td):is(:nth-child(3), :nth-child(5)) { display: none; } }

/* EVM: 1 pool 2 chain/dex 3 fee 4 price 5 price$ 6 tvl 7 in pool 8 fees 9 last 10 buttons */
@container (max-width: 1250px) { #evm table :is(th, td):nth-child(7) { display: none; } }
@container (max-width: 1020px) { #evm table :is(th, td):is(:nth-child(4), :nth-child(9)) { display: none; } }
@container (max-width: 720px)  { #evm table :is(th, td):is(:nth-child(3), :nth-child(5)) { display: none; } }

/* positions: 1 pool 2 range 3 status 4 amounts 5 fees 6 total 7 buttons */
@container (max-width: 900px)  { #positions table :is(th, td):is(:nth-child(4), :nth-child(3)) { display: none; } }

/* the book: as wide as fits, never wider than its content needs */
.book { width: clamp(340px, 40vw, 620px); }
.book-scroll { container-type: inline-size; overflow-x: auto; }
.book-t th, .book-t td { padding: 4px 6px; }
.book-t td.bl { min-width: 0; width: auto; }
/* 1 price 2 liquidity 3 fees/vol 4 crossings 5 solo 6 share yield 7 + */
@container (max-width: 560px) { .book-t :is(th, td):nth-child(6) { display: none; } }
@container (max-width: 470px) { .book-t :is(th, td):nth-child(4) { display: none; } }
@media (min-width: 1100px) {
  body.book-open main, body.book-open .search { margin-right: clamp(340px, 40vw, 620px); margin-left: 0; }
}
@media (max-width: 1099px) { .book { width: min(620px, 100vw); } }

/* watch cards and alerts never overflow */
.watch-grid { grid-template-columns: repeat(auto-fill, minmax(min(360px, 100%), 1fr)); }
.alert { max-width: 100%; }
.wnums { grid-template-columns: repeat(auto-fit, minmax(54px, 1fr)); }
.evm-form { display: flex; gap: 8px; margin: 12px 0; }
.evm-form input { flex: 1; min-width: 0; padding: 11px 13px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); font-family: var(--mono); font-size: 13.5px; outline: none; }
.tag.evm { color: #8fb4ff; }

/* phone */
@media (max-width: 760px) {
  .top { padding: 8px 12px; gap: 8px; }
  .brand span { display: none; }
  .tabs { order: 2; flex: 1 1 auto; overflow-x: auto; }
  .tabs button { padding: 5px 9px; }
  .chips { order: 4; }
  #solChip { display: none; }
  .actions { order: 3; }
  .actions .btn { padding: 6px 9px; font-size: 13px; }
  #settingsBtn { font-size: 0; }
  #settingsBtn::before { content: '⚙'; font-size: 15px; }
  .scr-head { gap: 8px; }
  .scr-head h1 { font-size: 18px; }
  .scr-status { white-space: normal; }
  .tok-stats { gap: 10px 16px; }
  .evm-form { flex-direction: column; }
}
/* ---- fit, second pass: thresholds measured on the real tables ---- */
.pools th { white-space: normal; line-height: 1.25; vertical-align: bottom; }
td .btns { flex-wrap: wrap; justify-content: flex-end; max-width: 170px; margin-left: auto; }
.scr-status { white-space: normal; flex-wrap: wrap; justify-content: flex-end; }
@container (max-width: 1650px) { table.ptbl :is(th, td):nth-child(6) { display: none; } }
@container (max-width: 1450px) { table.ptbl :is(th, td):nth-child(4) { display: none; } }
@container (max-width: 1250px) { table.ptbl :is(th, td):nth-child(9) { display: none; } }
@container (max-width: 1080px) { table.ptbl :is(th, td):nth-child(7) { display: none; } }
@container (max-width: 880px)  { table.ptbl :is(th, td):nth-child(2) { display: none; } }
@container (max-width: 660px)  { table.ptbl :is(th, td):nth-child(5) { display: none; } }
@container (max-width: 1350px) { #evm table :is(th, td):nth-child(7) { display: none; } }
@container (max-width: 1150px) { #evm table :is(th, td):is(:nth-child(4), :nth-child(9)) { display: none; } }
@container (max-width: 820px)  { #evm table :is(th, td):is(:nth-child(3), :nth-child(5)) { display: none; } }
@container (max-width: 560px)  { #evm table :is(th, td):nth-child(2) { display: none; } }
@container (max-width: 560px)  { table.live[data-view=tokens] :is(th, td):nth-child(6) { display: none; } }
@container (max-width: 880px)  { table.live[data-view=pools] :is(th, td):nth-child(7) { display: none; } }
/* small boxes: the little link buttons go, the main action stays */
@container (max-width: 720px) {
  .pools .linkbtn { display: none; }
  .pools td .btns { max-width: 96px; }
  .pools th, .pools td { padding: 7px 6px; }
  .pair .icons img + img { display: none; }
  .venue-logo { display: none; }
}
@container (max-width: 600px) { .book-t :is(th, td):nth-child(6) { display: none; } }
@container (max-width: 500px) { .book-t :is(th, td):nth-child(4) { display: none; } .book-t td.bp .sub { display: none; } }
@container (max-width: 420px) { .book-t th, .book-t td { padding: 4px 4px; font-size: 11.5px; } .book-t td.bl .sub { display: none; } }
/* ---- phone: rows become cards (no table can fit 390 px) ---- */
@container (max-width: 600px) {
  :is(table.ptbl, table.live, #evm table, #scrApi table) thead { display: none; }
  :is(table.ptbl, table.live, #evm table, #scrApi table) tbody tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
  :is(table.ptbl, table.live, #evm table, #scrApi table) tbody td { display: block; padding: 0; border: 0; text-align: left; white-space: normal; }
  :is(table.ptbl, table.live, #evm table, #scrApi table) tbody td:first-child { grid-column: 1 / -1; }
  :is(table.ptbl, table.live, #evm table, #scrApi table) tbody td:last-child { grid-column: 1 / -1; }
  :is(table.ptbl, table.live, #evm table, #scrApi table) tbody td[colspan] { grid-column: 1 / -1; }
  .pools td .btns { justify-content: flex-start; max-width: none; margin: 4px 0 0; }
  .pools tbody td::before { display: block; color: var(--muted); font-size: 10.5px; font-family: Inter, system-ui, sans-serif; text-transform: uppercase; letter-spacing: .03em; }
  table.ptbl td:nth-child(3)::before { content: 'Цена'; }
  table.ptbl td:nth-child(5)::before { content: 'TVL'; }
  table.ptbl td:nth-child(7)::before { content: 'Объём / фисы 24ч'; }
  table.ptbl td:nth-child(8)::before { content: 'Заработано'; }
  table.live[data-view=pools] td:nth-child(6)::before { content: 'Фисы 1 мин'; }
  table.live[data-view=pools] td:nth-child(11)::before { content: 'APR 5 мин'; }
  table.live[data-view=pools] td:nth-child(13)::before { content: 'Всплеск'; }
  table.live[data-view=pools] td:nth-child(14)::before { content: 'Соло-тик'; }
  table.live[data-view=tokens] td:nth-child(5)::before { content: 'Фисы 1 мин'; }
  table.live[data-view=tokens] td:nth-child(9)::before { content: 'Всплеск'; }
  table.live[data-view=new] td:nth-child(3)::before { content: 'Создан'; }
  table.live[data-view=new] td:nth-child(5)::before { content: 'Фисы 1 мин'; }
  table.live[data-view=new] td:nth-child(9)::before { content: 'APR 5 мин'; }
  #evm table td:nth-child(6)::before { content: 'TVL'; }
  #evm table td:nth-child(8)::before { content: 'Фисы live'; }
  #scrApi table td:nth-child(4)::before { content: '$/мин'; }
  #scrApi table td:nth-child(8)::before { content: 'APR сейчас'; }
  #scrApi table td:nth-child(10)::before { content: 'Всплеск'; }
  /* on a card there is room again for the columns a narrow table had to drop */
  table.live[data-view=pools] :is(th, td):is(:nth-child(13), :nth-child(14)) { display: block; }
}
/* ---- fit, last pass ---- */
.scr-head > div { min-width: 0; }
.scr-mode { max-width: 100%; flex-wrap: wrap; }
.scr-mode button { white-space: normal; flex: 1 1 auto; }
@container (max-width: 560px) { .book-t th, .book-t td { padding: 4px 5px; } }
@container (max-width: 380px) {
  .book-t :is(th, td):nth-child(3) .sub { display: none; }
  .book-t td.bl { max-width: 96px; overflow: hidden; }
  .bk-add { width: 22px; }
}
/* the book table always fits its drawer: fixed layout, long text is cut */
.book-t { table-layout: fixed; width: 100%; }
.book-t td, .book-t th { overflow: hidden; text-overflow: ellipsis; }
.book-t th:first-child { width: 23%; }
.book-t th:last-child { width: 34px; }
/* toasts never bury the page: a few at a time, compact on a phone */
.toasts .toast:nth-child(n+5) { display: none; }
@media (max-width: 760px) {
  .toasts { left: 12px; right: 12px; bottom: 10px; max-width: none; }
  .toasts .toast:nth-child(n+3) { display: none; }
  .toast { padding: 7px 10px; font-size: 12px; }
}
/* token links to OKX DEX; the junk filter line */
a.okx { color: inherit; text-decoration: none; border-bottom: 1px dashed rgba(138, 147, 168, .55); }
a.okx:hover { color: var(--accent); border-bottom-color: var(--accent); }
.junk-info { font-size: 12.5px; color: var(--muted); margin: 8px 0 0; }
.junk-info b { color: var(--text); }
.junk-seg button.on { box-shadow: inset 0 -2px 0 var(--warn); }
/* sound settings */
.snd-box { display: flex; flex-direction: column; gap: 8px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; }
.snd-box .field { margin: 0; }
.snd-box .field.check { margin-top: 0; }
.snd-vol input { width: 100%; accent-color: var(--accent); }
.snd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; }
.snd-cd input { width: 120px; }
#sndTest { align-self: flex-start; }
@media (max-width: 520px) { .snd-grid { grid-template-columns: 1fr; } }
/* minimum LP fees per minute */
.minfee { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12.5px; border: 1px solid var(--line); border-radius: 10px; padding: 3px 4px 3px 10px; background: var(--panel); white-space: nowrap; }
.minfee input { width: 72px; border: 0; background: var(--bg); border-radius: 7px; padding: 4px 7px; font-family: var(--mono); font-size: 13px; color: var(--text); outline: none; }
.minfee input:focus { box-shadow: 0 0 0 1px var(--accent); }
/* sortable column titles */
.pools th.sortable { cursor: pointer; user-select: none; }
.pools th.sortable:hover { color: var(--text); }
.pools th.sorted { color: var(--accent); }
.pools th .arr { font-size: 9px; margin-left: 3px; }
/* anti-shitcoin switch and its panel */
.anti-btn.on { border-color: var(--accent); color: var(--accent); }
#lvAfBtn.on { border-color: var(--accent-2); }
.af-panel { border: 1px solid var(--line); background: var(--panel); border-radius: 14px; padding: 12px 14px; margin: 8px 0 12px; }
.af-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 4px 0 8px; font-size: 13px; }
.af-presets { margin-left: auto; display: flex; gap: 6px; }
.af-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px 14px; margin-bottom: 10px; }
.af-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.af-grid input[type=number] { padding: 6px 9px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); font-family: var(--mono); font-size: 13px; color: var(--text); outline: none; }
.af-grid input:focus { border-color: var(--accent); }
.af-grid .af-check { flex-direction: row; align-items: center; color: var(--text); }
.af-note { font-size: 11.5px; margin: 0; }
.alert.big { border-left-color: var(--accent); }
/* EVM live table columns: 1 pool 2 chain 3 tvl 4 10s 5 1m 6 5m 7 1h 8 24h 9 swaps 10 apr5m 11 apr24h 12 spike 13 link */
@container (max-width: 1350px) { table.evml :is(th, td):is(:nth-child(4), :nth-child(11)) { display: none; } }
@container (max-width: 1100px) { table.evml :is(th, td):is(:nth-child(8), :nth-child(9)) { display: none; } }
@container (max-width: 860px) { table.evml :is(th, td):is(:nth-child(2), :nth-child(7)) { display: none; } }
@container (max-width: 600px) { table.evml :is(th, td):is(:nth-child(3), :nth-child(6), :nth-child(12)) { display: none; } }


/* EVM token in the main tab + one-tick deposit (admin) */
#evmView .toolbar { flex-wrap: wrap; }
#evmView tr.book-on td { background: rgba(34, 211, 166, .06); }
#evmView tbody tr { cursor: pointer; }
.ed-range { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 12px 0 8px; }
.ed-step { display: flex; align-items: center; gap: 8px; }
.ed-step b { min-width: 72px; text-align: center; }
.ed-step input { flex: 1; min-width: 0; width: 100%; text-align: center; padding: 8px 6px; border-radius: 9px; border: 1px solid var(--line); background: var(--bg); font-family: var(--mono); font-size: 14px; font-weight: 600; outline: none; }
.ed-step input:focus { border-color: var(--accent); }
.ed-step .btn.sm { flex: 0 0 auto; }
.ed-band { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 2px 0 8px; flex-wrap: wrap; }
.pctstep { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12.5px; }
.pctstep b { min-width: 34px; text-align: center; color: var(--text); font-family: var(--mono); font-size: 14px; }
.ed-width { font-size: 12.5px; }
#edPct { margin: 0 0 8px; flex-wrap: wrap; }
#edPre { margin: 4px 0 10px; flex-wrap: wrap; }
.ed-need { margin: 10px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); font-size: 13px; display: grid; gap: 4px; }
.ed-need label { color: var(--muted); font-size: 12px; }
.ed-log { min-height: 20px; font-size: 13px; margin: 6px 0; word-break: break-word; }
#lvNet button:first-child { font-weight: 600; }
@media (max-width: 600px) { .ed-range { grid-template-columns: 1fr; } }
.ed-amt { display: grid; grid-template-columns: 1fr auto auto; gap: 6px 10px; align-items: center; padding: 6px 0; }
.ed-amt input { font-size: 18px; font-weight: 600; min-width: 0; }
.ed-amt .muted { grid-column: 1 / -1; font-size: 12px; }
.ed-amt.short .muted, .ed-amt.short input { color: var(--down, #ff6b6b); }

/* watchlist and positions tabs */
.tabs .cnt { display: inline-block; min-width: 16px; padding: 0 5px; margin-left: 4px; border-radius: 8px; background: var(--accent); color: #06231b; font-size: 11px; font-weight: 700; line-height: 16px; }
.tabs .cnt:empty { display: none; }
#tokStar, #evStar { margin-right: 6px; font-size: 18px; }
.star.on { color: #ffcc4d; }
#watchView .evm-form, #posView .pos-head { margin: 10px 0 14px; }
#posView .pos-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
#posView .pos-sol-h { margin-top: 24px; }
#posView .btns { flex-wrap: wrap; }
.empty-note { padding: 24px 0; }
#paShare { margin: 10px 0 6px; }
#paRange { width: 100%; }

/* one look for every pool table: names are links only on hover, letter avatars for EVM tokens, venue pills */
#evmView .pair a.okx { border-bottom: 0; }
.av { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-style: normal; font-size: 11px; font-weight: 700; color: #fff; background: hsl(var(--h) 45% 38%); border: 2px solid var(--panel); }
.icons .av + .av { margin-left: -8px; }
.av-lg { width: 44px; height: 44px; font-size: 18px; flex: none; }
.tag.dex-uni { color: #ff7ad9; background: rgba(255, 122, 217, .12); }
.tag.dex-pcs { color: #4fd1e8; background: rgba(79, 209, 232, .12); }
.tag.dex-aero { color: #6aa3ff; background: rgba(106, 163, 255, .12); }
.tag.dex-sushi { color: #e48bff; background: rgba(228, 139, 255, .12); }
.tag.dex-other { color: var(--muted); background: var(--panel-2); }
#evmView .token-card { display: flex; align-items: center; gap: 14px; }
.blk { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 15px; padding: 0 4px 0 0; opacity: .55; }
.blk:hover { color: var(--down, #ff6b6b); opacity: 1; }
.af-black { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }

/* every row: ☆ ⊘ [token][chain] name — fixed widths so nothing shifts sideways */
.pair .star, .pair .blk { flex: none; width: 18px; text-align: center; padding: 0; }
.pair .icons { flex: none; width: 38px; align-items: center; }
.pair .icons > img, .pair .icons > .av, .pair .icons > .chain-logo { flex: none; width: 22px; height: 22px; box-sizing: border-box; }
.pair .icons > .chain-logo { margin-left: -6px; border-radius: 50%; box-shadow: 0 0 0 2px var(--panel); }
.pair .icons > .av + .chain-logo, .pair .icons > img + .chain-logo { margin-left: -6px; }
@container (max-width: 720px) { .pair .icons { width: 22px; } .pair .icons > .chain-logo { display: none; } }
/* the action buttons keep their room; the pool name gives way */
table.live th:last-child, table.live td:last-child { width: 1%; white-space: nowrap; }
table.live td:last-child .btns { flex-wrap: nowrap; justify-content: flex-end; }
table.live td:first-child { max-width: 340px; }
.pair .icons > .ti { position: relative; flex: none; width: 22px; height: 22px; }
.pair .icons > .ti > .av, .pair .icons > .ti > img { position: absolute; inset: 0; width: 22px; height: 22px; box-sizing: border-box; border-radius: 50%; }
.pair .icons > .ti > img { background: var(--panel-2); border: 2px solid var(--panel); }
.pair .icons > .ti + .chain-logo { margin-left: -6px; }
table.live .pair .sub { white-space: normal; overflow-wrap: anywhere; }
.ti { display: inline-block; position: relative; width: 22px; height: 22px; vertical-align: middle; flex: none; }
.ti > .av, .ti > img { position: absolute; inset: 0; width: 22px; height: 22px; box-sizing: border-box; border-radius: 50%; }
.ti > img { background: var(--panel-2); }
.alert .ti, .live-alerts .ti { width: 18px; height: 18px; } .alert .ti > * { width: 18px; height: 18px; font-size: 9px; }
