/* Tessera: временное оформление (вариант 3).
   Вся "одежда" биржи лежит в переменных ниже. Чтобы переодеть биржу,
   меняются только они. Раскладка: шапка с меню, под ней одна рабочая колонка. */
:root {
  --bg: #f2f2f6;
  --surface: #ffffff;
  --raise: #e9e9f0;
  --border: #d5d6e0;
  --text: #17181c;
  --muted: #555866;
  --accent: #5340d8;
  --on-accent: #ffffff;
  --up: #087a47;
  --down: #b4232a;
  --warn-bg: #fff3d6;
  --warn-text: #5c4300;
  --on-trade: #ffffff;
  --font-display: 'Unbounded', 'Commissioner', system-ui, sans-serif;
  --font-body: 'Commissioner', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --radius: 10px;
  --radius-s: 8px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #17181c;
    --surface: #212329;
    --raise: #2b2d36;
    --border: #383b46;
    --text: #ededf0;
    --muted: #b4b6c2;
    --accent: #9c8cff;
    --on-accent: #17181c;
    --up: #3dd68c;
    --down: #ff7b7b;
    --warn-bg: #3a3116;
    --warn-text: #ffe2a0;
    --on-trade: #17181c;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #17181c;
  --surface: #212329;
  --raise: #2b2d36;
  --border: #383b46;
  --text: #ededf0;
  --muted: #b4b6c2;
  --accent: #9c8cff;
  --on-accent: #17181c;
  --up: #3dd68c;
  --down: #ff7b7b;
  --warn-bg: #3a3116;
  --warn-text: #ffe2a0;
  --on-trade: #17181c;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
}
h1, h2 { font-family: var(--font-display); font-weight: 500; text-wrap: balance; margin: 0; }
h1 { font-size: 24px; line-height: 1.25; }
h2 { font-size: 17px; line-height: 1.3; }
p { margin: 0; }
a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.demo-bar {
  background: var(--warn-bg);
  color: var(--warn-text);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  padding: 6px 16px;
}
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 8px 24px;
  padding: 10px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand span { font-family: var(--font-display); font-weight: 700; font-size: 19px; }
.brand-tag { font-style: normal; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--accent); color: var(--on-accent); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav-right { margin-left: auto; }
.nav > a, .menu > summary {
  display: inline-flex; align-items: center; min-height: 40px;
  padding: 0 14px; border-radius: var(--radius-s);
  color: var(--muted); text-decoration: none; font-weight: 500; cursor: pointer; white-space: nowrap;
}
.nav > a:hover, .menu > summary:hover { color: var(--text); background: var(--raise); }
.nav > a[aria-current="page"], .menu.active > summary { color: var(--text); background: var(--raise); }
.menu { position: relative; }
.menu > summary { list-style: none; gap: 6px; }
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); }
.menu-list {
  position: absolute; top: calc(100% + 6px); left: 0; z-index: 30; min-width: 270px;
  display: flex; flex-direction: column; gap: 2px; padding: 6px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(10, 10, 30, 0.18);
}
.menu-list a { display: flex; flex-direction: column; padding: 10px 12px; border-radius: var(--radius-s); color: var(--text); text-decoration: none; }
.menu-list a:hover, .menu-list a[aria-current="page"] { background: var(--raise); }
.menu-list small { color: var(--muted); font-size: 13px; }

.more-btn { display: none; margin-left: auto; width: 44px; height: 44px; align-items: center; justify-content: center;
  border: 0; border-radius: var(--radius-s); background: transparent; color: var(--text); cursor: pointer; }
.tabbar { display: none; }
.sheet { width: 100%; max-width: none; margin: auto 0 0; padding: 16px 16px 24px; border: 0;
  border-radius: 18px 18px 0 0; background: var(--surface); color: var(--text); }
.sheet::backdrop { background: rgba(10, 10, 20, 0.5); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; font-family: var(--font-display); }
.sheet-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sheet-list a { display: flex; align-items: center; min-height: 52px; padding: 0 14px; border-radius: var(--radius-s);
  background: var(--bg); color: var(--text); text-decoration: none; font-weight: 500; }
.sheet-list a[aria-current="page"] { outline: 2px solid var(--accent); }

@media (max-width: 1080px) {
  .top { padding: 8px 12px 8px 16px; }
  .top .nav { display: none; }
  .more-btn { display: inline-flex; }
  .tabbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
    display: grid; grid-template-columns: repeat(5, 1fr);
    background: var(--surface); border-top: 1px solid var(--border);
  }
  .tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    min-height: 58px; color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 600; }
  .tabbar a[aria-current="page"] { color: var(--accent); }
  body { padding-bottom: 58px; }
}

.page { max-width: 1040px; margin: 0 auto; padding: 24px 20px 48px; display: flex; flex-direction: column; gap: 20px; }
.head { display: flex; flex-direction: column; gap: 6px; }
.lead { color: var(--muted); max-width: 65ch; }
.panel { background: var(--surface); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.hint { color: var(--muted); font-size: 14px; max-width: 65ch; }
.notice { background: var(--warn-bg); color: var(--warn-text); border-radius: var(--radius-s); padding: 12px 14px; }
.msg { min-height: 24px; font-weight: 500; }
.msg.ok { color: var(--up); }
.msg.err { color: var(--down); }

.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--border); white-space: nowrap; }
th { color: var(--muted); font-weight: 500; font-size: 14px; }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; }
.coin { display: flex; flex-direction: column; }
.coin b { font-weight: 600; }
.coin small { color: var(--muted); font-size: 13px; }
.coin.has-ico { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: center; }
.coin.has-ico .ico { grid-row: 1 / span 2; }
.coin.has-ico b { align-self: end; line-height: 1.2; }
.coin.has-ico small { align-self: start; line-height: 1.2; }
.ico { width: 32px; height: 32px; border-radius: 9px; display: inline-grid; place-items: center; color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 11px; letter-spacing: 0; flex: none; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); }
.ico.ico-3 { font-size: 9.5px; }
img.ico-img { background: none; box-shadow: none; object-fit: contain; border-radius: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
label.btn { cursor: pointer; }
.visually-hidden:focus-visible + label.btn { outline: 2px solid var(--accent); outline-offset: 2px; }
.up { color: var(--up); }
.down { color: var(--down); }
.spark { display: block; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--radius-s);
  font: inherit; font-weight: 600; cursor: pointer;
  background: var(--accent); color: var(--on-accent); text-decoration: none;
}
.btn.quiet { background: var(--raise); color: var(--text); }
.btn.small { min-height: 36px; padding: 0 10px; font-size: 14px; white-space: nowrap; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.form { display: grid; gap: 16px; max-width: 460px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 500; }
.row { display: flex; gap: 8px; }
input[type="text"], input[type="password"], input[type="datetime-local"], input[type="date"], input[type="search"], select {
  min-height: 44px; width: 100%; padding: 0 12px; font: inherit;
  color: var(--text); background: var(--bg);
  border: 1px solid var(--border); border-radius: var(--radius-s);
}
input.narrow { max-width: 140px; }
.check { display: flex; gap: 10px; align-items: flex-start; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); }

.quote { display: grid; gap: 8px; padding: 14px; background: var(--bg); border-radius: var(--radius-s); font-variant-numeric: tabular-nums; }
.quote div { display: flex; justify-content: space-between; gap: 16px; }
.quote span:first-child { color: var(--muted); }
.quote span:last-child { text-align: right; }
.quote .big { font-weight: 600; font-size: 18px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.tile { background: var(--bg); border-radius: var(--radius-s); padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.tile span { color: var(--muted); font-size: 14px; }
.tile b { font-family: var(--font-display); font-weight: 500; font-size: 20px; font-variant-numeric: tabular-nums; }
.total { font-family: var(--font-display); font-weight: 500; font-size: 30px; font-variant-numeric: tabular-nums; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; background: var(--raise); }
.pill.bad { background: var(--down); color: var(--surface); }
.foot { color: var(--muted); font-size: 14px; text-align: center; padding: 0 20px 32px; display: flex; flex-direction: column; gap: 10px; }
.foot-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 20px; }
.foot-nav a { display: inline-flex; align-items: center; min-height: 40px; color: var(--text); }

/* ---------- публичная часть ---------- */
.page.mid { max-width: 1160px; }
.hero { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; align-items: center; padding: 16px 0 8px; }
.hero-text { display: flex; flex-direction: column; gap: 16px; }
.display { font-size: clamp(26px, 3.6vw, 40px); line-height: 1.18; }
.row.wrap { flex-wrap: wrap; }
.board { display: flex; flex-direction: column; }
.board-row { display: grid; grid-template-columns: 1fr auto 96px; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border);
  color: var(--text); text-decoration: none; font-variant-numeric: tabular-nums; }
.board-row:last-child { border-bottom: 0; }
.board-row span:last-child { text-align: right; font-weight: 600; font-size: 14px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.card { background: var(--surface); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.card a { margin-top: auto; font-weight: 600; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.steps li { display: flex; gap: 12px; align-items: flex-start; }
.step-n { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--raise); font-weight: 600; }
.list { margin: 0; padding-left: 20px; display: grid; gap: 8px; max-width: 70ch; }
.faq { display: flex; flex-direction: column; }
.faq details { border-bottom: 1px solid var(--border); }
.faq details:last-child { border-bottom: 0; }
.faq summary { cursor: pointer; padding: 14px 0; font-weight: 600; }
.faq p { padding: 0 0 16px; color: var(--muted); max-width: 65ch; }
td.wrap { white-space: normal; min-width: 220px; }
@media (max-width: 760px) { .hero { grid-template-columns: minmax(0, 1fr); gap: 20px; } }


/* ---------- торговый экран ---------- */
.page.wide { max-width: 1320px; }
.trade-top { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.trade-top .pair select { min-width: 150px; font-weight: 600; background: var(--surface); }
.pxbox { display: flex; flex-direction: column; margin-right: auto; font-variant-numeric: tabular-nums; }
.pxbox .px { font-family: var(--font-display); font-weight: 500; font-size: 22px; }
.pxbox span:last-child { font-size: 14px; font-weight: 600; }

.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--raise); border-radius: var(--radius-s); align-self: flex-start; }
.seg button {
  min-height: 36px; padding: 0 14px; border: 0; border-radius: 6px; font: inherit; font-weight: 600;
  color: var(--muted); background: transparent; cursor: pointer;
}
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); }
.seg button.buy[aria-pressed="true"] { background: var(--up); color: var(--on-trade); }
.seg button.sell[aria-pressed="true"] { background: var(--down); color: var(--on-trade); }
.form .seg { display: flex; }
.form .seg button { flex: 1; }
.btn.buy { background: var(--up); color: var(--on-trade); width: 100%; }
.btn.sell { background: var(--down); color: var(--on-trade); width: 100%; }

.chart { display: block; width: 100%; height: 340px; }
.grid-simple { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 20px; align-items: start; }
.grid-pro {
  display: grid; gap: 16px; align-items: start;
  grid-template-columns: minmax(0, 1fr) 300px 320px;
  grid-template-areas: "chart book form" "orders tape form";
}
.area-chart { grid-area: chart; }
.area-book { grid-area: book; }
.area-form { grid-area: form; }
.area-orders { grid-area: orders; }
.area-tape { grid-area: tape; }
.grid-simple .area-chart, .grid-simple .area-form { grid-area: auto; }
.grid-pro .panel { padding: 16px; gap: 12px; }
.grid-pro .form, .grid-simple .form { max-width: none; }

.book { display: flex; flex-direction: column; font-variant-numeric: tabular-nums; font-size: 14px; }
.book-head, .lvl { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 8px; padding: 0 6px; }
.book-head { color: var(--muted); font-size: 13px; }
.book-head span:not(:first-child), .lvl span:not(:first-child) { text-align: right; }
.lvl {
  min-height: 26px; align-items: center; border: 0; border-radius: 4px; font: inherit; color: var(--text); cursor: pointer;
  background: linear-gradient(to left, var(--tint) var(--fill, 0%), transparent var(--fill, 0%));
}
.lvl.ask { --tint: color-mix(in srgb, var(--down) 16%, transparent); }
.lvl.bid { --tint: color-mix(in srgb, var(--up) 16%, transparent); }
.lvl:hover { outline: 1px solid var(--border); }
.book .mid { padding: 8px 6px; font-weight: 600; font-size: 16px; }
table.dense th, table.dense td { padding: 7px 8px; font-size: 14px; }

@media (max-width: 1100px) {
  .grid-pro { grid-template-columns: minmax(0, 1fr) 320px; grid-template-areas: "chart form" "book form" "orders orders" "tape tape"; }
}
@media (max-width: 760px) {
  .grid-simple { grid-template-columns: minmax(0, 1fr); }
  .grid-pro { grid-template-columns: minmax(0, 1fr); grid-template-areas: "chart" "form" "book" "orders" "tape"; }
  .chart { height: 240px; }
  .pxbox { margin-right: 0; }
}

/* ---------- фьючерсы ---------- */
.grid-fut { display: grid; gap: 16px; align-items: start; grid-template-columns: minmax(0, 1fr) 400px;
  grid-template-areas: "chart form" "orders form" "tape tape"; }
.grid-fut .form { max-width: none; }
.trade-top .hint { max-width: none; }
input[type="range"] { width: 100%; min-height: 32px; accent-color: var(--accent); }
.levout { font-family: var(--font-display); font-weight: 500; margin-left: 6px; }
.pill.good { background: var(--up); color: var(--on-trade); }
.pill.bad { background: var(--down); color: var(--on-trade); }
.pos-list { display: flex; flex-direction: column; gap: 14px; }
.pos { display: flex; flex-direction: column; gap: 14px; padding: 16px; background: var(--bg); border-radius: var(--radius-s); }
.pos-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.pos-head .btn { margin-left: auto; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; font-variant-numeric: tabular-nums; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat span { color: var(--muted); font-size: 13px; }
.stat b { font-weight: 600; }
.levels { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.levels input { background: var(--surface); }
.earn-form { display: grid; grid-template-columns: minmax(140px, 1fr) auto auto auto; gap: 10px; align-items: end; }
.earn-form input { background: var(--surface); }
.form.wide-form { max-width: 620px; }
/* ---------- поддержка и объявления ---------- */
.thread { display: flex; flex-direction: column; gap: 10px; }
.bubble { align-self: flex-start; max-width: min(640px, 88%); padding: 10px 14px; border-radius: 14px 14px 14px 4px; background: var(--bg); }
.bubble.mine { align-self: flex-end; border-radius: 14px 14px 4px 14px; background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
.bubble span { display: block; margin-bottom: 2px; color: var(--muted); font-size: 13px; }
.bubble p { white-space: pre-wrap; overflow-wrap: anywhere; }
.news-list { display: flex; flex-direction: column; }
.news { display: flex; flex-direction: column; gap: 6px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.news:first-child { padding-top: 0; }
.news:last-child { border-bottom: 0; padding-bottom: 0; }
.news p { white-space: pre-wrap; overflow-wrap: anywhere; max-width: 70ch; }
.banner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 10px 14px;
  border-radius: var(--radius-s); background: var(--warn-bg); color: var(--warn-text); }
.banner a { color: inherit; }
.card.current { outline: 2px solid var(--accent); }
input.reason { max-width: 240px; min-height: 36px; }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.chartbox { display: flex; flex-direction: column; gap: 8px; padding: 14px; background: var(--bg); border-radius: var(--radius-s); }
.bars { display: block; width: 100%; height: auto; font-family: var(--font-body); }
.btn.sell.auto { width: auto; }
.loan-actions { display: grid; grid-template-columns: minmax(140px, 1fr) auto minmax(140px, 1fr) auto; gap: 10px; align-items: end; }
.loan-actions input { background: var(--surface); }
@media (max-width: 700px) { .loan-actions { grid-template-columns: 1fr auto; } }
.sub-actions { display: grid; grid-template-columns: minmax(120px, 200px) minmax(140px, 1fr) auto; gap: 10px; align-items: start; }
.sub-actions > .row { margin-top: 30px; }
.sub-actions input, .sub-actions select { background: var(--surface); }
@media (max-width: 700px) { .sub-actions { grid-template-columns: 1fr; } .sub-actions > .row { margin-top: 0; } }
a.tile { text-decoration: none; color: inherit; }
a.tile:hover { border-color: var(--accent); }
.spark { display: block; width: 100%; height: 110px; }
.sparkbox { margin-top: 14px; }
.tabs-scroll { margin-bottom: 16px; }
.tabs-scroll .seg { white-space: nowrap; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px 24px; margin: 6px 0 14px; align-items: start; }
.check-group { display: flex; flex-direction: column; gap: 8px; }
.check-group > .check:first-child span { font-weight: 600; }
.check.sub { margin-left: 30px; }
.check.sub span { font-weight: 400; color: var(--muted); }
.decide { display: flex; flex-direction: column; gap: 10px; min-width: 260px; }
.decide .notice, .decide .hint { margin: 0; }
.card-tabs { margin-bottom: 16px; }
.wallet-top .total { font-size: 38px; line-height: 1.15; }
.wallet-top .hint { margin: 2px 0 0; }
.wallet-top .row { margin-top: 14px; }
.places { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.place { background: var(--bg); border-radius: var(--radius-s); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.place-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.place-top small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.place-num { text-align: right; white-space: nowrap; display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.place a { font-size: 14px; font-weight: 600; }
.wallet-filters { align-items: end; }
.wallet-filters .check { align-self: center; margin-top: 18px; }
table.assets tr.asset-row { cursor: pointer; }
table.assets tr.asset-row:hover td, table.assets tr.asset-row.open td { background: var(--bg); }
table.assets td.chev { width: 28px; color: var(--muted); font-size: 11px; }
table.assets tr.asset-more td { background: var(--bg); padding: 4px 16px 18px; white-space: normal; }
table.assets tr.asset-more .stats { margin-bottom: 10px; }
.show-s { display: none; }
@media (max-width: 700px) {
  .wallet-top .total { font-size: 30px; } .wallet-filters .check { margin-top: 0; }
  .wallet-top .row { display: grid; grid-template-columns: 1fr 1fr; }
  .wallet-top .row .btn { text-align: center; padding-left: 8px; padding-right: 8px; }
  .show-s { display: block; color: var(--muted); font-size: 13px; font-weight: 400; }
  table.assets { width: 100%; }
  table.assets tr.asset-more td { padding: 4px 10px 16px; }
}
.dep { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; margin-top: 16px; }
.dep-pic { display: flex; flex-direction: column; gap: 8px; align-items: center; text-align: center; }
.dep-img { width: 220px; height: 220px; border-radius: var(--radius-s); border: 1px solid var(--border); background: #fff; padding: 10px; object-fit: contain; }
.dep-side { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.dep-addr { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 18px; font-weight: 600; padding: 14px 16px; background: var(--bg); border-radius: var(--radius-s); overflow-wrap: anywhere; user-select: all; }
@media (max-width: 700px) { .dep { grid-template-columns: 1fr; } }
.fiat-title { margin: 4px 0 10px; font-size: 17px; }
.fiat-text { white-space: pre-line; background: var(--bg); border-radius: var(--radius-s); padding: 14px 16px; margin: 0 0 10px; }
.ind-bar { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 10px 0 4px; }
.ind { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); cursor: pointer; }
.ind input { width: 16px; height: 16px; margin: 0; }
.ind-sw { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }
.cond-sum { min-height: 1.2em; }
.chart.chart-sub { height: 110px; margin-top: 8px; }
.levels.partial { margin-top: 10px; grid-template-columns: 1fr auto; }
.levels.partial input[type="range"] { width: 100%; }
.mg-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.mg-col { display: flex; flex-direction: column; gap: 20px; }
@media (max-width: 900px) { .mg-grid { grid-template-columns: 1fr; } }
.area-chart .tabs-scroll { margin-bottom: 0; }
.area-chart .tabs-scroll .seg { flex-wrap: nowrap; width: max-content; }
.area-chart .tabs-scroll .seg button { white-space: nowrap; }
.ind-wrap { margin: 8px 0 6px; }
.ind-wrap summary { cursor: pointer; font-size: 14px; font-weight: 600; color: var(--muted); padding: 4px 0; }
.ind-wrap .ind-bar { margin-top: 6px; }
.chart-tools { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; margin: 0 0 6px; }
.chart-group { display: flex; flex-wrap: wrap; gap: 2px; background: var(--bg); border-radius: 9px; padding: 2px; }
.ic-btn { position: relative; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 7px; background: transparent; color: var(--muted); display: inline-grid; place-items: center; cursor: pointer; font: inherit; }
.ic-btn svg { width: 16px; height: 16px; display: block; }
.ic-btn.ic-text { width: auto; min-width: 28px; padding: 0 6px; font-size: 12.5px; font-weight: 600; }
.ic-btn:hover { background: var(--surface); color: var(--text); }
.ic-btn[aria-pressed="true"] { background: var(--surface); color: var(--accent); box-shadow: 0 0 0 1px var(--border); }
.ic-btn[data-tip]:hover::after, .ic-btn[data-tip]:focus-visible::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 0; z-index: 70; background: var(--text); color: var(--surface); font-size: 12px; font-weight: 500; line-height: 1.3; padding: 5px 8px; border-radius: 6px; white-space: nowrap; pointer-events: none; }
.ic-btn.tip-r[data-tip]:hover::after, .ic-btn.tip-r[data-tip]:focus-visible::after { left: auto; right: 0; }
@media (max-width: 700px) { .ic-btn[data-tip]:hover::after, .ic-btn[data-tip]:focus-visible::after { white-space: normal; width: max-content; max-width: 220px; } }
.chart-tools .seg { margin: 0; }
.chart-tools .btn.on { background: var(--accent); color: var(--on-accent); }
canvas.chart { cursor: crosshair; touch-action: pan-y; }
canvas.chart.adding { cursor: copy; }
.panel.chart-full { position: fixed; inset: 0; z-index: 60; border-radius: 0; overflow: auto; margin: 0; }
.panel.chart-full canvas.chart:not(.chart-sub) { height: calc(100vh - 330px); min-height: 260px; }
.p2p-steps { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 6px 0 14px; padding: 0 0 0 20px; color: var(--muted); font-size: 14px; }
.p2p-steps li.done { color: var(--text); font-weight: 600; }
.p2p-steps li.done::marker { color: var(--up); }
.bubble small { display: block; margin-bottom: 2px; color: var(--muted); font-size: 13px; }
.bubble p { margin: 0; }
.bubble.sys { background: transparent; border: 1px dashed var(--border); align-self: center; max-width: 100%; }
.p2p-coins { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.chip { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 6px 14px; font: inherit; font-weight: 600; font-size: 14px; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.p2p-list { display: flex; flex-direction: column; }
.p2p-ad { border-top: 1px solid var(--border); padding: 16px 0; }
.p2p-ad.open { background: var(--bg); border-radius: var(--radius-s); padding: 16px; border-top-color: transparent; margin: 6px 0; }
.p2p-row { display: grid; grid-template-columns: minmax(180px, 1.4fr) minmax(110px, 0.8fr) minmax(150px, 1fr) minmax(160px, 1.3fr) auto; gap: 16px; align-items: center; }
.p2p-who { display: flex; gap: 12px; align-items: center; min-width: 0; }
.p2p-who small, .p2p-cell small { display: block; color: var(--muted); font-size: 13px; }
.p2p-ava { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 16%, var(--surface)); color: var(--accent); font-weight: 700; }
.p2p-ok { color: var(--up); }
.p2p-price { font-family: var(--font-display); font-size: 20px; }
.p2p-pay .pill { margin: 2px 4px 2px 0; }
.p2p-go .btn { white-space: nowrap; }
.p2p-open { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); }
.p2p-open input, .p2p-open select { background: var(--surface); }
.p2p-deal { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.p2p-methods { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px 16px; }
@media (max-width: 900px) {
  .p2p-row { grid-template-columns: 1fr 1fr; }
  .p2p-who, .p2p-pay, .p2p-go { grid-column: 1 / -1; }
  .p2p-go .btn { width: 100%; }
  .p2p-open, .p2p-deal { grid-template-columns: 1fr; }
}
.p2p-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.p2p-top h1 { margin: 0; }
.p2p-tools { display: flex; gap: 4px; }
.p2p-ib { width: 36px; height: 36px; }
.p2p-ib svg { width: 20px; height: 20px; }
.p2p-ib .adm-count { position: absolute; top: -2px; right: -4px; }
.p2p-bar { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 14px; }
.p2p-bar .p2p-coins { margin: 0; gap: 2px; }
.p2p-bar .chip { border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; color: var(--muted); padding: 6px 10px; }
.p2p-bar .chip[aria-pressed="true"] { background: none; color: var(--text); border-bottom-color: var(--accent); }
.p2p-filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.p2p-filters select, .p2p-filters input { height: 40px; }
.p2p-amount { display: flex; border: 1px solid var(--border); border-radius: var(--radius-s); overflow: hidden; background: var(--surface); }
.p2p-amount input { border: 0; width: 170px; background: none; }
.p2p-amount select { border: 0; border-left: 1px solid var(--border); border-radius: 0; background: none; width: auto; font-weight: 600; }
.p2p-filters > select { width: auto; min-width: 200px; }
.p2p-filters .p2p-ib { margin-left: auto; }
.p2p-headrow { padding: 10px 0 8px; color: var(--muted); font-size: 13px; }
.p2p-headrow .p2p-go { text-align: right; }
.p2p-name { display: inline-flex; align-items: center; gap: 4px; }
.p2p-ok { display: inline-grid; color: var(--accent); }
.p2p-ok svg, .p2p-meta svg { width: 14px; height: 14px; }
.p2p-meta { display: flex !important; gap: 12px; margin-top: 2px; }
.p2p-meta span { display: inline-flex; align-items: center; gap: 4px; }
.p2p-cur { font-size: 13px; color: var(--muted); }
.pay-tag { display: flex; align-items: center; gap: 6px; font-size: 14px; line-height: 1.5; }
.pay-bar { flex: none; width: 3px; height: 12px; border-radius: 2px; }
.p2p-empty { padding: 28px 0; text-align: center; }
.p2p-row .p2p-cell small { display: none; }
@media (max-width: 900px) {
  .p2p-headrow { display: none; }
  .p2p-row .p2p-cell small { display: block; }
  .p2p-amount { flex: 1 1 100%; } .p2p-amount input { flex: 1; width: auto; min-width: 0; }
  .p2p-filters > select { flex: 1; min-width: 0; }
  .p2p-pay > div { display: flex; flex-wrap: wrap; gap: 2px 14px; }
}
/* ---------- служебная система ---------- */
.adm { display: grid; grid-template-columns: 248px minmax(0, 1fr); gap: 24px; align-items: start; }
.adm-side { position: sticky; top: 76px; max-height: calc(100vh - 92px); overflow-y: auto; background: var(--surface); border-radius: var(--radius); padding: 10px; display: flex; flex-direction: column; gap: 2px; }
.adm-side h3 { margin: 10px 10px 2px; font-size: 13px; font-weight: 600; color: var(--muted); }
.adm-side button { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 34px; padding: 5px 10px; border: 0; border-radius: 8px; background: transparent; font: inherit; font-size: 15px; color: var(--text); text-align: left; cursor: pointer; }
.adm-side button:hover { background: var(--bg); }
.adm-side button[aria-selected="true"] { background: var(--raise); font-weight: 600; box-shadow: inset 3px 0 0 var(--accent); }
.adm-count { flex: none; min-width: 22px; padding: 1px 7px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 600; text-align: center; }
.adm-main { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.adm-title h2 { margin: 0 0 4px; font-size: 22px; }
.adm-title .hint { margin: 0; }
.todo { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.todo-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-s); background: var(--bg); font: inherit; color: var(--text); text-align: left; cursor: pointer; }
.todo-item:hover { border-color: var(--accent); }
.todo-item b { font-family: var(--font-display); font-size: 22px; color: var(--accent); }
.adm-head { flex-direction: row; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.adm-head .field { min-width: 200px; }
.adm-tabs { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--raise); border-radius: var(--radius-s); }
.adm-tabs button { flex: none; min-height: 40px; padding: 0 14px; border: 0; border-radius: 6px; font: inherit; font-weight: 600; color: var(--muted); background: transparent; cursor: pointer; white-space: nowrap; }
.adm-tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); }
.filters { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: flex-end; }
.filters .field { flex: 1; min-width: 180px; max-width: 320px; }
.linklike { padding: 0; border: 0; background: none; font: inherit; font-weight: 600; color: var(--accent); cursor: pointer; text-align: left; }
.linklike:hover { text-decoration: underline; }
textarea { width: 100%; padding: 10px 12px; font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-s); resize: vertical; }
.earn-form.finance-form { grid-template-columns: minmax(160px, 1.4fr) minmax(110px, 1fr) minmax(110px, 1fr) auto auto; }
@media (max-width: 700px) { .earn-form.finance-form { grid-template-columns: 1fr 1fr; } }
.earn-form.launch-form { grid-template-columns: minmax(140px, 260px) auto auto; justify-content: start; }
.faq details p + p { padding-top: 0; }
.bar { height: 10px; border-radius: 999px; background: var(--raise); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.code { font-family: var(--font-display); font-weight: 500; font-size: 18px; letter-spacing: 0.04em; user-select: all; }
tr.me td { background: var(--bg); }
tr.me .pill { margin-left: 8px; }
.badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 6px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 600; }
.more-btn { position: relative; }
.more-btn.has-new::after { content: ""; position: absolute; top: 9px; right: 8px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); border: 2px solid var(--surface); }
.coinrow { display: flex; align-items: center; gap: 6px; }
.star { width: 36px; height: 36px; border: 0; border-radius: var(--radius-s); background: transparent; color: var(--muted); font-size: 20px; line-height: 1; cursor: pointer; }
.star.on { color: var(--accent); }
.star:hover { background: var(--raise); }
.notes { display: flex; flex-direction: column; }
.note { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.note:last-child { border-bottom: 0; }
.note span { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.note.new p { font-weight: 600; }
.earn-form.alert-form { grid-template-columns: minmax(140px, 1fr) minmax(120px, 1fr) auto; }
@media (max-width: 560px) { .note { grid-template-columns: 1fr; gap: 2px; } }
.copy-row { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: center; }
.copy-row .stats { flex: 1; min-width: 240px; }
.earn-form.copy-form { grid-template-columns: minmax(140px, 260px) auto; justify-content: start; }
.pos-head .pill { font-weight: 500; }
.form .row .field { flex: 1; min-width: 0; }
.form .row:has(.field) { align-items: flex-end; }
@media (max-width: 700px) { .earn-form { grid-template-columns: 1fr 1fr; } .earn-form .field { grid-column: 1 / -1; } .earn-form .btn:last-child { grid-column: 1 / -1; } }
@media (max-width: 900px) {
  .grid-fut { grid-template-columns: minmax(0, 1fr); grid-template-areas: "chart" "form" "orders" "tape"; }
}
@media (max-width: 560px) { .levels { grid-template-columns: 1fr 1fr; } .levels .btn { grid-column: 1 / -1; } }

@media (max-width: 560px) {
  .page { padding: 16px 16px 40px; }
  .panel { padding: 16px; }
  .hide-s { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* ---------- верхнее меню: значки справа ---------- */
.nav-right { gap: 2px; }
.top-ic, .nav > a.top-ic, .menu > summary.top-ic { position: relative; display: inline-grid; place-items: center; width: 40px; height: 40px; padding: 0; border-radius: 10px; color: var(--muted); cursor: pointer; }
.top-ic:hover, .nav > a.top-ic[aria-current="page"], .menu-ic[open] > summary { color: var(--text); background: var(--raise); }
.menu > summary.top-ic::after { display: none; }
.top-ic .badge { position: absolute; top: 2px; right: 0; }
.top-ic[data-tip]:hover::before { content: attr(data-tip); position: absolute; top: calc(100% + 6px); right: 0; z-index: 40; white-space: nowrap; background: var(--text); color: var(--surface); font-size: 12.5px; font-weight: 500; padding: 4px 8px; border-radius: 6px; pointer-events: none; }
.menu-ic[open] > summary[data-tip]::before { display: none; }
.nav > a.top-dep { display: inline-flex; gap: 6px; align-items: center; background: var(--accent); color: var(--on-accent); margin-right: 8px; padding: 0 14px; height: 36px; border-radius: 10px; }
.nav > a.top-dep:hover { background: var(--accent); color: var(--on-accent); filter: brightness(1.08); }
.menu-right { left: auto; right: 0; min-width: 240px; }
.menu-list a.menu-row { flex-direction: row; align-items: center; gap: 12px; }
.menu-row svg { color: var(--muted); flex: none; }
.menu-row .badge { margin-left: auto; }
.menu-who { display: flex; flex-direction: column; padding: 10px 12px 12px; margin-bottom: 6px; border-bottom: 1px solid var(--border); }
.menu-who small { color: var(--muted); font-size: 13px; }
/* ---------- личный кабинет ---------- */
.cab { display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 28px; align-items: start; }
.cab-side { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 2px; }
.cab-main { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.cab-item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 10px; color: var(--text); text-decoration: none; font-weight: 500; }
.cab-item svg { color: var(--muted); flex: none; }
.cab-item:hover { background: var(--raise); }
.cab-item.on { background: var(--surface); box-shadow: inset 3px 0 0 var(--accent); font-weight: 600; }
.cab-item.on svg { color: var(--accent); }
.cab-item .badge { margin-left: auto; }
.cab-sub { padding: 8px 14px 8px 46px; border-radius: 10px; color: var(--muted); text-decoration: none; font-size: 15px; }
.cab-sub:hover, .cab-sub[aria-current="page"] { color: var(--text); }
.cab-sub[aria-current="page"] { font-weight: 600; }
.cab .cab-hide { display: none; }
.dash-user { display: grid; grid-template-columns: auto auto 1fr; gap: 16px 20px; align-items: center; }
.dash-ava { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 16%, var(--surface)); color: var(--accent); font-family: var(--font-display); font-size: 22px; }
.dash-name { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.dash-name b { font-family: var(--font-display); font-size: 20px; }
.dash-facts { display: flex; flex-wrap: wrap; gap: 8px 32px; justify-content: flex-end; }
.dash-fact { display: flex; flex-direction: column; }
.dash-fact small { color: var(--muted); font-size: 13px; }
.dash-fact b, .dash-fact a { font-weight: 600; font-size: 15px; }
.dash-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.dash-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.dash-cap { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.dash-cap h2 { margin: 0; }
.dash-bal .dash-cap { justify-content: flex-start; }
.dash-sum { display: flex; align-items: baseline; gap: 8px; }
.dash-total { font-family: var(--font-display); font-size: 34px; line-height: 1.15; }
.dash-unit { color: var(--muted); font-weight: 600; }
.dash-acts { margin-top: 16px; }
.dash-news { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.dash-news li { display: flex; flex-direction: column; padding: 10px 0; border-top: 1px solid var(--border); }
.dash-news li:first-child { border-top: 0; padding-top: 0; }
.dash-news small { color: var(--muted); font-size: 13px; }
@media (max-width: 900px) {
  .cab { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .cab-side { position: static; flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 4px; scrollbar-width: none; }
  .cab-item { flex: none; padding: 8px 12px; border: 1px solid var(--border); background: var(--surface); }
  .cab-item.on { box-shadow: none; border-color: var(--accent); }
  .cab-sub { flex: none; padding: 8px 10px; }
  .dash-user { grid-template-columns: auto 1fr; }
  .dash-facts { grid-column: 1 / -1; justify-content: flex-start; }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-total { font-size: 28px; }
}

/* ---------- профиль и безопасность: компактный вид ---------- */
.cab-main .head h1 { font-size: 24px; }
.cab-main .head .lead { font-size: 15px; margin-top: 2px; }
.me-card { max-width: 760px; }
.me-head { display: flex; align-items: center; gap: 16px; padding-bottom: 16px; margin-bottom: 4px; border-bottom: 1px solid var(--border); }
.me-head .pill { margin-left: auto; }
.me-head .dash-ava { width: 48px; height: 48px; font-size: 19px; }
.me-head .dash-name b { font-size: 18px; }
.kv { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
.kv-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: 15px; }
.kv-row:nth-last-child(-n+2) { border-bottom: 0; }
.kv-row > span { color: var(--muted); }
.kv-row b, .kv-row a { font-weight: 600; text-align: right; }
.sec-bar { margin: 2px 0 6px; max-width: 760px; }
.sec-list { display: flex; flex-direction: column; max-width: 760px; }
.sec-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 14px; align-items: center; padding: 14px 0; border-top: 1px solid var(--border); }
.sec-row:first-child { border-top: 0; }
.sec-ic { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--raise); color: var(--muted); }
.sec-ic.on { background: color-mix(in srgb, var(--up) 14%, var(--surface)); color: var(--up); }
.sec-text { display: flex; flex-direction: column; min-width: 0; }
.sec-text b { font-weight: 600; }
.sec-text small { color: var(--muted); font-size: 13.5px; }
.sec-state { font-size: 13.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.sec-state::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--border); }
.sec-state.on { color: var(--up); } .sec-state.on::before { background: var(--up); }
.sec-body { padding: 4px 0 18px 52px; max-width: 620px; display: flex; flex-direction: column; gap: 12px; }
.sec-body .hint { margin: 0; }
@media (max-width: 700px) {
  .kv { grid-template-columns: 1fr; } .kv-row:nth-last-child(2) { border-bottom: 1px solid var(--border); }
  .sec-row { grid-template-columns: auto minmax(0, 1fr) auto; } .sec-state { grid-column: 2; grid-row: 2; } .sec-row .btn { grid-row: 1 / span 2; grid-column: 3; }
  .sec-body { padding-left: 0; }
}
.cab-main .panel:has(.sec-list), .cab-main .panel:has(.sec-list) + .panel { max-width: 800px; }

/* ---------- торговля: раскладка как на больших биржах ---------- */
.ticker { display: flex; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 10px 36px; padding: 12px 18px; }
.ticker .pair { display: flex; flex-direction: column; }
.ticker .pair select { min-width: 150px; font-weight: 700; font-size: 18px; border: 0; background: none; padding-left: 0; height: 32px; }
.ticker .pxbox { margin-right: 0; }
.ticker .pxbox .px { font-size: 22px; }
.ticker .pxbox small { font-size: 13px; font-weight: 400; }
.tk-stat { display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.tk-stat small { color: var(--muted); font-size: 12.5px; }
.tk-stat b { font-weight: 600; font-size: 14.5px; }
.page.wide .grid-pro { grid-template-columns: 290px minmax(0, 1fr) 290px; grid-template-areas: "book chart pairs" "book form tape" "orders orders orders"; gap: 12px; }
.area-pairs { grid-area: pairs; }
.grid-pro .panel h2 { font-size: 15px; margin: 0; }
.grid-pro .area-form { grid-area: form; }
.form-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.form-pair .form { gap: 10px; }
.form-pair .form > .hint { margin: 0; }
.form-pair .btn[type="submit"] { width: 100%; }
.only-s { display: none; }
.pairs { display: flex; flex-direction: column; max-height: 300px; overflow-y: auto; margin: 0 -6px; }
.pairs-head, .pair-row { display: grid; grid-template-columns: 1.1fr 1fr 0.9fr; gap: 6px; padding: 0 6px; }
.pair-row { border: 0; background: none; font: inherit; font-size: 13.5px; color: var(--text); padding: 6px; border-radius: 6px; cursor: pointer; text-align: left; font-variant-numeric: tabular-nums; }
.pair-row span:not(:first-child) { text-align: right; }
.pair-row small { color: var(--muted); }
.pair-row:hover, .pair-row.on { background: var(--raise); }
.area-pairs input { height: 36px; }
.area-tape .scroll { max-height: 330px; overflow-y: auto; }
.book .lvl { padding-top: 1px; padding-bottom: 1px; font-size: 13.5px; }
@media (max-width: 1100px) {
  .page.wide .grid-pro { grid-template-columns: minmax(0, 1fr) 290px; grid-template-areas: "chart pairs" "form book" "orders orders" "tape tape"; }
}
@media (max-width: 760px) {
  .page.wide .grid-pro { grid-template-columns: minmax(0, 1fr); grid-template-areas: "chart" "form" "book" "orders" "tape" "pairs"; }
  .only-s { display: block; }
  .form-pair { grid-template-columns: 1fr; }
  .form-pair.pick-buy .side-sell, .form-pair.pick-sell .side-buy { display: none; }
  .ticker { gap: 8px 20px; }
}

.grid-pro .area-chart > .hint { display: none; }
.area-tape .scroll { overflow-x: hidden; }
.area-tape table.dense { width: 100%; font-size: 13.5px; }
.area-tape table.dense td, .area-tape table.dense th { padding: 5px 4px; }
.form-pair .quote { padding: 10px 12px; font-size: 14px; }
.form-pair .btn.small { padding: 0 8px; flex: 1; }

/* фьючерсы: график, стакан, форма; позиции во всю ширину */
.page.wide .grid-fut { grid-template-columns: minmax(0, 1fr) 280px 340px; grid-template-areas: "chart book form" "orders orders form" "tape tape tape"; gap: 12px; }
.grid-fut .panel { padding: 16px; gap: 12px; }
.grid-fut .panel h2 { font-size: 15px; margin: 0; }
.grid-fut .area-chart > .hint { display: none; }
@media (max-width: 1100px) { .page.wide .grid-fut { grid-template-columns: minmax(0, 1fr) 340px; grid-template-areas: "chart form" "book form" "orders orders" "tape tape"; } }
@media (max-width: 760px) { .page.wide .grid-fut { grid-template-columns: minmax(0, 1fr); grid-template-areas: "chart" "form" "orders" "book" "tape"; } }

/* ---------- плотный вид: всё компактнее (на телефоне кнопки остаются крупными для пальца) ---------- */
@media (min-width: 761px) {
  body { font-size: 14px; }
  h1 { font-size: 20px; } h2 { font-size: 15px; }
  .cab-main .head h1 { font-size: 20px; } .cab-main .head .lead, .lead { font-size: 14px; }
  .hint { font-size: 13px; }
  .top { padding: 6px 20px; gap: 6px 18px; }
  .brand span { font-size: 17px; } .brand svg { width: 28px; height: 25px; }
  .nav > a, .menu > summary { min-height: 34px; padding: 0 11px; }
  .top-ic, .nav > a.top-ic, .menu > summary.top-ic { width: 34px; height: 34px; min-height: 34px; }
  .top-ic svg { width: 19px; height: 19px; }
  .nav > a.top-dep { height: 30px; min-height: 30px; padding: 0 12px; font-size: 13px; }
  .menu-list { min-width: 240px; } .menu-list a { padding: 7px 10px; } .menu-list small { font-size: 12px; }
  .page { padding: 16px 20px 40px; gap: 14px; }
  .panel { padding: 16px; gap: 12px; }
  .btn { min-height: 34px; padding: 0 14px; font-size: 14px; }
  .btn.small { min-height: 28px; padding: 0 9px; font-size: 13px; }
  input[type="text"], input[type="password"], input[type="datetime-local"], input[type="date"], select { min-height: 34px; padding: 0 10px; }
  textarea { padding: 8px 10px; }
  .form { gap: 12px; } .field { gap: 4px; } .field label { font-size: 13px; }
  .seg { padding: 3px; gap: 2px; } .seg button { min-height: 28px; padding: 0 11px; font-size: 13px; }
  th, td { padding: 8px 8px; } th { font-size: 12.5px; }
  table.dense th, table.dense td { padding: 5px 8px; font-size: 13px; }
  .tiles { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
  .tile { padding: 10px 12px; gap: 2px; } .tile span { font-size: 12.5px; } .tile b { font-size: 16px; }
  .total { font-size: 24px; } .dash-total { font-size: 26px; }
  .pill { font-size: 12px; padding: 1px 8px; }
  .quote { padding: 10px 12px; gap: 6px; } .quote .big { font-size: 15px; }
  .notice { padding: 9px 12px; }
  .check input { width: 16px; height: 16px; }
  .cab { grid-template-columns: 200px minmax(0, 1fr); gap: 22px; }
  .cab-item { padding: 8px 12px; gap: 10px; } .cab-item svg { width: 18px; height: 18px; }
  .cab-sub { padding: 6px 12px 6px 40px; font-size: 13.5px; }
  .cab-main { gap: 14px; }
  .dash-ava { width: 44px; height: 44px; font-size: 18px; } .dash-name b { font-size: 17px; }
  .dash-fact small { font-size: 12px; } .dash-fact b, .dash-fact a { font-size: 13.5px; }
  .dash-grid, .dash-col { gap: 14px; }
  .kv-row { padding: 8px 0; font-size: 13.5px; }
  .sec-row { padding: 10px 0; } .sec-ic { width: 32px; height: 32px; } .sec-text small, .sec-state { font-size: 12.5px; }
  .ticker { padding: 8px 16px; gap: 6px 28px; } .ticker .pair select { font-size: 16px; height: 28px; min-height: 28px; } .ticker .pxbox .px { font-size: 19px; }
  .tk-stat small { font-size: 11.5px; } .tk-stat b { font-size: 13px; }
  .book, .book .lvl { font-size: 12.5px; } .book .mid { font-size: 14px; padding: 5px 6px; } .book-head { font-size: 12px; }
  .pair-row { font-size: 12.5px; padding: 4px 6px; }
  .area-tape table.dense { font-size: 12.5px; }
  .form-pair { gap: 18px; } .form-pair .quote { font-size: 13px; padding: 8px 10px; }
  .p2p-row { gap: 12px; } .p2p-ad { padding: 12px 0; } .p2p-price { font-size: 17px; } .p2p-ava { width: 30px; height: 30px; }
  .p2p-who small, .p2p-cell small { font-size: 12px; } .pay-tag { font-size: 13px; }
  .p2p-filters select, .p2p-filters input { height: 34px; } .p2p-ib { width: 32px; height: 32px; } .p2p-ib svg { width: 18px; height: 18px; }
  .adm-side button { padding-top: 6px; padding-bottom: 6px; }
  .foot { font-size: 13px; }
}

/* ---------- выпадающие списки ---------- */
.sel { position: relative; display: block; width: 100%; min-width: 0; }
.sel.narrow { max-width: 140px; }
.sel-native { position: absolute !important; inset: 0; width: 100% !important; height: 100% !important; min-height: 0 !important; opacity: 0; pointer-events: none; margin: 0; }
.sel-btn { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 44px; padding: 0 10px 0 12px; font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--border); border-radius: var(--radius-s); cursor: pointer; text-align: left; }
.sel-btn:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.sel.open .sel-btn, .sel-btn:focus-visible { border-color: var(--accent); outline: 2px solid color-mix(in srgb, var(--accent) 25%, transparent); outline-offset: 0; }
.sel-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.sel-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.sel-chev { flex: none; width: 14px; height: 14px; color: var(--muted); transition: transform 0.15s; }
.sel.open .sel-chev { transform: rotate(180deg); }
.sel-pop { position: fixed; z-index: 200; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 14px 36px rgba(10, 10, 30, 0.2); padding: 6px; overflow: hidden; }
.sel-list { overflow-y: auto; display: flex; flex-direction: column; gap: 1px; min-height: 0; }
.sel-find { min-height: 34px !important; margin-bottom: 6px; flex: none; }
.sel-opt { display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 0; background: none; font: inherit; color: var(--text); text-align: left; padding: 8px 10px; border-radius: 6px; cursor: pointer; white-space: nowrap; flex: none; }
.sel-opt.hover, .sel-opt:hover { background: var(--raise); }
.sel-opt.on { color: var(--accent); font-weight: 600; }
.sel-opt.on::after { content: ""; width: 5px; height: 10px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg) translateY(-2px); flex: none; }
.sel-opt:disabled { opacity: 0.45; cursor: not-allowed; }
.sel-empty { margin: 0; padding: 10px; color: var(--muted); font-size: 13px; }
.filters .sel, .earn-form .sel { min-width: 150px; }
.p2p-amount .sel { width: auto; } .p2p-amount .sel-btn { border: 0; border-left: 1px solid var(--border); border-radius: 0; background: none; font-weight: 600; outline-offset: -2px; }
.p2p-filters > .sel { width: auto; min-width: 200px; }
.ticker .pair .sel { width: auto; min-width: 140px; } .ticker .pair .sel-btn { border-color: transparent; background: none; padding-left: 0; font-weight: 700; font-size: 18px; min-height: 32px; justify-content: flex-start; }
.ticker .pair .sel-btn:hover { border-color: transparent; color: var(--accent); }
@media (min-width: 761px) {
  .sel-btn { min-height: 34px; padding: 0 8px 0 10px; }
  .sel-opt { padding: 6px 9px; font-size: 13.5px; }
  .ticker .pair .sel-btn { font-size: 16px; min-height: 28px; }
  .p2p-filters .sel-btn { min-height: 34px; }
}
@media (max-width: 760px) { .p2p-filters > .sel { flex: 1; min-width: 0; } .sel-pop { max-width: calc(100vw - 16px); } }
.sel-list { scrollbar-width: thin; } .ticker .pair .sel.open .sel-btn, .ticker .pair .sel-btn:focus-visible { outline: 0; color: var(--accent); }

/* ---------- активы и ордера ---------- */
.cab .places { grid-template-columns: 1fr; gap: 0; }
.cab .place { background: none; border-radius: 0; border-top: 1px solid var(--border); padding: 10px 0; flex-direction: row; align-items: center; gap: 18px; }
.cab .place:first-child { border-top: 0; padding-top: 0; }
.cab .place-top { flex: 1; min-width: 0; align-items: center; }
.cab .place .bar { width: 110px; flex: none; }
.cab .place > a { white-space: nowrap; font-size: 13px; }
.cab .place small { display: block; color: var(--muted); font-size: 12.5px; }
.wallet-top .total { line-height: 1.15; }
.wallet-filters { align-items: center; }
.wallet-filters .field label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.wallet-filters .field { max-width: 240px; }
.ord-find { max-width: 280px; }
.cab table.dense td .ic-btn { width: 24px; height: 24px; }
@media (max-width: 700px) { .cab .place { flex-wrap: wrap; gap: 8px; } .cab .place .bar { width: 100%; order: 3; } }

/* ---------- рынки ---------- */
.page:has(.mk-cards) { max-width: 1160px; }
.mk-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.mk-card { gap: 4px; padding: 12px 14px; }
.mk-card h2 { font-size: 13px; color: var(--muted); font-family: var(--font-body); font-weight: 500; margin-bottom: 4px; }
.mk-line { display: grid; grid-template-columns: 1fr auto 76px; gap: 10px; padding: 4px 6px; margin: 0 -6px; border-radius: 6px; color: var(--text); text-decoration: none; font-variant-numeric: tabular-nums; font-size: 13.5px; }
.mk-line:hover { background: var(--raise); }
.mk-line span:last-child { text-align: right; font-weight: 600; }
.mk-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mk-bar .tabs-scroll { margin: 0; }
.mk-table td { padding-top: 6px; padding-bottom: 6px; }
.mk-table .coinrow { gap: 6px; }
.spark { width: 96px; height: 28px; display: block; } .spark.up { color: var(--up); } .spark.down { color: var(--down); }
.mk-star { color: var(--border); } .mk-star.on { color: #e0a100; } .mk-star.on svg path { fill: currentColor; }
.mk-acts { justify-content: flex-end; gap: 2px; }
a.ic-btn { text-decoration: none; }
@media (max-width: 760px) { .mk-cards { grid-template-columns: 1fr; } .mk-cards .mk-card:nth-child(n+2) { display: none; } }
/* ---------- верх страницы на телефоне: значки аккаунта и уведомлений ---------- */
@media (max-width: 1080px) {
  .top .nav.nav-right { display: flex; margin-left: auto; }
  .top .nav-right .top-dep, .top .nav-right .m-wallet, .top .nav-right .ic-support, .top .nav-right .ic-admin { display: none; }
  .top .more-btn { margin-left: 0; }
  .top .nav-right .top-ic { width: 40px; height: 40px; }
  .top-ic[data-tip]:hover::before { display: none; }
}

/* ---------- кабинет: ширина и списки ---------- */
.msg:empty { display: none; }
.cab-main { max-width: 940px; }
.cab .pos { background: none; border-radius: 0; border-top: 1px solid var(--border); padding: 10px 0; gap: 2px; }
.cab .pos:first-of-type { border-top: 0; }
.cab .pos .pos-head { gap: 10px; }
.cab .pos .pos-head > :last-child:not(:first-child) { margin-left: auto; }
.cab .pos .hint { margin: 0; }
@media (min-width: 761px) { .pos { padding: 10px 12px; gap: 6px; } .head { gap: 2px; } .head .lead { max-width: 80ch; } }

/* ---------- формы и списки продуктов ---------- */
.split { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 14px; align-items: start; }
.split-form, .split-rest { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.split .form { max-width: none; }
.page:has(.cv-card) { max-width: 500px; }
.cv-card .form { max-width: none; }
.cv-flip { display: flex; justify-content: center; margin: -6px 0; }
.cv-flip .ic-btn { background: var(--raise); border-radius: 50%; width: 32px; height: 32px; }
.pos:has(> .earn-form) { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 8px 20px; align-items: center; }
.pos:has(> .earn-form) > .earn-form, .pos:has(> .earn-form) > .msg { grid-column: 1 / -1; }
.pos:has(> .earn-form) > .hint { display: none; }
.pos:has(> .earn-form) > .earn-form:not(.finance-form) { grid-template-columns: minmax(140px, 240px) auto auto auto; justify-content: start; }
.pos:has(> .earn-form) .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pos-list { gap: 8px; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } .pos:has(> .earn-form) { grid-template-columns: 1fr; } }
.cv-card .form .btn[type="submit"] { width: 100%; }

/* копитрейдинг: карточки стратегий сеткой */
.pos-list:has(> .pos > .copy-form) { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 10px; }
.pos:has(> .copy-form) { display: flex; flex-direction: column; gap: 8px; align-items: stretch; }
.pos:has(> .copy-form) > .hint { display: block; margin: 0; font-size: 12.5px; }
.pos:has(> .copy-form) .copy-row { display: flex; flex-direction: column; gap: 8px; }
.pos:has(> .copy-form) .copy-row svg, .pos:has(> .copy-form) .copy-row canvas { width: 100%; height: 44px; }
.pos:has(> .copy-form) .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pos:has(> .copy-form) .stat span { font-size: 11.5px; } .pos:has(> .copy-form) .stat b { font-size: 13px; }
.pos:has(> .copy-form) > .earn-form.copy-form { grid-template-columns: minmax(0, 1fr) auto; margin-top: auto; }
.split-form textarea { min-height: 110px; }

/* ---------- админка: компактнее ---------- */
#view:has(.adm) > .head { display: none; }
@media (min-width: 761px) {
  .adm { grid-template-columns: 208px minmax(0, 1fr); gap: 16px; }
  .adm-side { top: 60px; max-height: calc(100vh - 72px); padding: 6px; gap: 0; }
  .adm-side h3 { margin: 8px 8px 2px; font-size: 11.5px; }
  .adm-side button { min-height: 28px; padding: 3px 8px; font-size: 13px; }
  .adm-count { min-width: 18px; padding: 0 6px; font-size: 11px; }
  .adm-main { gap: 12px; }
  .adm-title h2 { font-size: 18px; margin-bottom: 0; }
  .adm-tabs { padding: 3px; gap: 2px; } .adm-tabs button { min-height: 28px; padding: 0 10px; font-size: 13px; }
  .adm-head .field { min-width: 160px; }
  .adm-main .tiles { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
  .adm-main td.wrap { min-width: 180px; }
  .adm-main .decide { gap: 6px; }
  .adm-main input.reason { min-height: 28px; }
}
@media (min-width: 761px) {
  .adm-main .tiles { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 6px; }
  .adm-main .tile { padding: 7px 10px; }
  .adm-main .tile b { font-size: 14px; font-family: var(--font-body); font-weight: 600; }
  .adm-main .tile span { font-size: 12px; }
}

/* ---------- главная ---------- */
.hero { gap: 28px; padding: 18px 0 4px; align-items: start; }
.hero-text { padding-top: 22px; }
.hm-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.hm-market { gap: 2px; } .hm-market .dash-cap { margin-bottom: 6px; }
.hm-line { grid-template-columns: 1fr auto 78px; align-items: center; padding: 6px; }
.hm-bal { display: flex; flex-direction: column; }
.hm-quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.hm-tile { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--surface); border-radius: var(--radius); color: var(--text); text-decoration: none; }
.hm-tile:hover { box-shadow: inset 0 0 0 1px var(--accent); }
.hm-tile .sec-ic { color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); }
.hm-tile b { display: block; font-weight: 600; } .hm-tile small { color: var(--muted); font-size: 12.5px; }
.hm-fees { display: flex; flex-wrap: wrap; gap: 6px 28px; align-items: baseline; padding: 10px 14px; background: var(--surface); border-radius: var(--radius); font-size: 13.5px; }
.hm-fees small { color: var(--muted); } .hm-fees a { margin-left: auto; }
@media (min-width: 761px) { h1.display { font-size: 34px; line-height: 1.15; } }
@media (max-width: 760px) { .hero-text { padding-top: 0; } .hm-quick { grid-template-columns: 1fr 1fr; } .hm-fees a { margin-left: 0; } }
.hm-market .seg { flex-wrap: nowrap; } .hm-market .seg button { white-space: nowrap; padding: 0 10px; } .hm-market .dash-cap a { white-space: nowrap; }

/* ---------- главная: виджеты ---------- */
.tape { overflow: hidden; background: var(--surface); border-radius: var(--radius); mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }
.tape-run { display: flex; width: max-content; animation: tape 140s linear infinite; }
.tape:hover .tape-run, .tape:focus-within .tape-run { animation-play-state: paused; }
.tape-item { display: inline-flex; gap: 8px; align-items: baseline; padding: 7px 18px; color: var(--text); text-decoration: none; font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tape-item:hover { background: var(--raise); }
@keyframes tape { to { transform: translateX(-50%); } }
.hm-points { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 22px; color: var(--muted); font-size: 13.5px; }
.hm-points li::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-right: 8px; vertical-align: middle; }
.hm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; align-items: stretch; }
.hm-w { gap: 8px; }
.hm-w h2 { margin: 0; }
.hm-chips { margin: 0; gap: 4px; } .hm-chips .chip { padding: 3px 10px; font-size: 12.5px; }
.hm-px { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; font-weight: 600; font-size: 13.5px; }
.hm-big { font-family: var(--font-display); font-weight: 500; font-size: 20px; font-variant-numeric: tabular-nums; }
.hm-chart { width: 100%; height: 90px; display: block; margin-top: auto; } .hm-chart.up { color: var(--up); } .hm-chart.down { color: var(--down); }
.hm-mood { height: 8px; border-radius: 999px; background: var(--down); overflow: hidden; } .hm-mood i { display: block; height: 100%; background: var(--up); }
.hm-legend { display: flex; justify-content: space-between; font-size: 12.5px; font-weight: 600; }
a.kv-row { color: var(--text); text-decoration: none; } a.kv-row:hover b { color: var(--accent); }
.hm-w .kv-row:nth-last-child(2) { border-bottom: 1px solid var(--border); }
.hm-calc { display: grid; grid-template-columns: minmax(0, 1fr) 104px; gap: 8px; align-items: center; }
.hm-got { display: flex; flex-direction: column; min-width: 0; } .hm-got .hm-big { overflow: hidden; text-overflow: ellipsis; }
.hm-lessons { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 7px; }
.hero-text { padding-top: 10px; }
.tape .tape-run { animation: tape 140s linear infinite !important; } .tape:hover .tape-run, .tape:focus-within .tape-run { animation-play-state: paused !important; } .tape { overflow: hidden !important; }

/* бегущая строка: плавное движение без рывков */
@keyframes tape { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }
.tape .tape-run { will-change: transform; backface-visibility: hidden; }
.tape-item { font-variant-numeric: tabular-nums; }
.tape-px { display: inline-block; min-width: 68px; text-align: right; }
.tape-ch { display: inline-block; min-width: 62px; }

/* бегущая строка: без мерцания (затемнение краёв сделано накладками, а не маской) */
.tape { position: relative; mask-image: none !important; -webkit-mask-image: none !important; contain: paint; }
.tape::before, .tape::after { content: ""; position: absolute; top: 0; bottom: 0; width: 48px; z-index: 1; pointer-events: none; }
.tape::before { left: 0; background: linear-gradient(90deg, var(--surface), transparent); }
.tape::after { right: 0; background: linear-gradient(270deg, var(--surface), transparent); }
.tape .tape-run { backface-visibility: visible; will-change: transform; }
.tape-item, .tape-item:hover { background: none; transition: none; }
.tape-item:hover b { color: var(--accent); }
.tape-item * { text-rendering: optimizeSpeed; }

/* бегущую строку двигает скрипт, шагами в целый пиксель */
.tape .tape-run { animation: none !important; will-change: transform; }
.tape-item * { text-rendering: auto; }

/* ---------- пополнение и вывод ---------- */
.fund-bar { display: flex; align-items: center; gap: 12px 18px; flex-wrap: wrap; }
.fund-bar h1 { margin-right: 6px; } .fund-bar .tabs-scroll { margin: 0; }
.fund-level { position: relative; margin-left: auto; display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--surface); color: var(--text); text-decoration: none; font-size: 12.5px; font-weight: 600; }
.fund-level svg { color: var(--accent); }
.fund-level[data-tip]:hover::after { content: attr(data-tip); position: absolute; top: calc(100% + 6px); right: 0; z-index: 30; white-space: nowrap; background: var(--text); color: var(--surface); font-size: 12px; font-weight: 500; padding: 4px 8px; border-radius: 6px; }
.fund { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; align-items: start; }
.fund-side { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.fund-tips .list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; color: var(--muted); font-size: 13px; }
.fund-card { counter-reset: fstep; }
.fund-card .form { max-width: 460px; }
.fund-card .field > label::before, .fund-card .dep-side > .hint:first-child::before { counter-increment: fstep; content: counter(fstep); display: inline-grid; place-items: center; width: 20px; height: 20px; margin-right: 8px; border-radius: 50%;
  background: var(--accent); color: var(--on-accent); font-size: 11.5px; font-weight: 700; }
.fund-card .field > label, .fund-card .dep-side > .hint:first-child { display: flex; align-items: center; font-weight: 600; color: var(--text); font-size: 13.5px; max-width: none; }
.fund-card .field { padding-left: 0; }
.fund-card .field > :not(label) { margin-left: 28px; }
.fund-card .field > .row { margin-left: 28px; }
.fund-card .dep { grid-template-columns: minmax(0, 1fr) 150px; gap: 18px; margin-top: 4px; max-width: 640px; }
.fund-card .dep-side { order: 1; } .fund-card .dep-pic { order: 2; }
.fund-card .dep-side > :not(.hint:first-child) { margin-left: 28px; }
.fund-card .dep-img, .fund-card .dep-pic canvas, .fund-card .dep-pic svg, .fund-card .dep-pic img { width: 140px; height: 140px; padding: 6px; }
.fund-card .dep-pic .hint { font-size: 11.5px; }
.addr-row { display: flex; align-items: center; gap: 6px; background: var(--bg); border-radius: var(--radius-s); padding: 4px 6px 4px 12px; }
.addr-row .dep-addr { flex: 1; min-width: 0; background: none; padding: 6px 0; font-size: 14.5px; }
.addr-copy { flex: none; color: var(--accent); }
.fund-card .quote { max-width: 432px; margin-left: 28px; }
.fund-card .form > div:not(.field):not(.quote), .fund-card .form > .btn { margin-left: 28px; }
.fund-side .panel h2 { font-size: 14px; }
@media (max-width: 900px) { .fund { grid-template-columns: 1fr; } .fund-level { margin-left: 0; } .fund-card .dep { grid-template-columns: 1fr; } .fund-card .dep-pic { order: 0; } }
.fund-side table td.wrap, .fund-side table td:nth-child(4) { white-space: normal; min-width: 120px; overflow-wrap: anywhere; font-size: 12.5px; }

/* ---------- пополнение и вывод: шаги линией, плитки сетей, окно подтверждения ---------- */
.fund-card .form, .fund-card .dep { position: relative; }
.fund-card .field { position: relative; }
.fund-card .field::before { content: ""; position: absolute; left: 9.5px; top: 24px; bottom: -14px; width: 1px; background: var(--border); }
.fund-card .form > .field:last-of-type::before { display: none; }
.fund-chips { margin: 0 0 6px 28px !important; }
.net-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; margin-left: 28px; }
.net-opt { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 12px; border: 1px solid var(--border); border-radius: var(--radius-s); background: var(--surface); color: var(--text); font: inherit; font-size: 13.5px; cursor: pointer; text-align: left; }
.net-opt b { font-weight: 600; }
.net-opt:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.net-opt[aria-checked="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 7%, var(--surface)); box-shadow: inset 0 0 0 1px var(--accent); }
.net-opt[aria-checked="true"]::after { content: ""; width: 5px; height: 10px; border: solid var(--accent); border-width: 0 2px 2px 0; transform: rotate(45deg) translateY(-2px); flex: none; }
.fund-card .field .hm-chips { margin-top: 6px; }
.fund-card .quote .big { font-size: 16px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
dialog.confirm { width: min(440px, calc(100vw - 24px)); border: 0; border-radius: 14px; padding: 18px; background: var(--surface); color: var(--text); box-shadow: 0 24px 70px rgba(10, 10, 30, 0.35); }
dialog.confirm::backdrop { background: rgba(10, 10, 20, 0.55); }
.confirm-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.confirm-head h2 { margin: 0; font-size: 17px; }
.confirm-rows { grid-template-columns: 1fr; margin-bottom: 12px; }
.confirm-rows .kv-row:nth-last-child(2) { border-bottom: 1px solid var(--border); }
.confirm-rows .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; overflow-wrap: anywhere; max-width: 260px; }
.confirm-rows .big { font-family: var(--font-display); font-size: 17px; }
.confirm-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
dialog.confirm .notice { font-size: 13px; margin: 0; }

/* ---------- пополнение и вывод: крупные переключатели и уровень проверки ---------- */
.fund-top { display: flex; flex-direction: column; gap: 10px; }
.fund-top .fund-bar { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; align-items: stretch; }
.fund-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.fund-tab { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid transparent; border-radius: var(--radius); background: var(--surface); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.fund-tab:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.fund-tab.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.fund-tab .sec-ic.on { background: var(--accent); color: var(--on-accent); }
.fund-tab-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.fund-tab-text b { font-size: 15px; font-weight: 600; }
.fund-tab-text small { color: var(--muted); font-size: 12.5px; }
.fund-top .fund-level { position: static; margin: 0; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--radius); font-size: inherit; font-weight: 400;
  background: color-mix(in srgb, var(--up) 9%, var(--surface)); border: 1px solid color-mix(in srgb, var(--up) 40%, var(--border)); }
.fund-top .fund-level .sec-ic { background: var(--surface); color: var(--up); }
.fund-top .fund-level.lv0 { background: var(--warn-bg); border-color: color-mix(in srgb, var(--warn-text) 30%, var(--warn-bg)); color: var(--warn-text); }
.fund-top .fund-level.lv0 .sec-ic, .fund-top .fund-level.lv0 small { color: var(--warn-text); }
.fund-top .fund-level:hover::after { display: none; }
.fund-up { margin-left: auto; flex: none; padding: 5px 12px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12.5px; font-weight: 600; }
@media (max-width: 900px) { .fund-top .fund-bar { grid-template-columns: 1fr; } .fund-tab { flex-direction: column; align-items: flex-start; gap: 6px; padding: 10px; } .fund-tab-text small { display: none; } .fund-top .fund-level .fund-tab-text small { display: block; } }
.fund-card .field > .sel, .fund-card .field > input, .fund-card .field > .row { width: calc(100% - 28px); } .fund-card .quote { max-width: calc(100% - 28px); }

/* ---------- правка данных клиента: поля прямо в таблице ---------- */
.ed-table td { padding: 3px 5px; vertical-align: middle; }
.ed-in { min-height: 26px !important; height: 26px; padding: 0 6px !important; font-size: 12.5px; width: 92px !important; background: var(--bg); border: 1px solid var(--border); border-radius: 6px; font: inherit; font-size: 12.5px; color: var(--text); }
.ed-in.ed-s { width: 54px !important; } .ed-in.ed-dt { width: 158px !important; } .ed-in.ed-wide { width: 100% !important; }
.ed-table .sel, .ed-form .sel { width: auto; min-width: 96px; display: inline-block; }
.ed-table .sel-btn, .ed-form .sel-btn, .ed-news .sel-btn { min-height: 26px; height: 26px; padding: 0 6px 0 8px; font-size: 12.5px; border-radius: 6px; }
.ed-acts { justify-content: flex-end; gap: 0; flex-wrap: nowrap; }
.ed-ok { color: var(--up); }
.ed-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 12px; }
.ed-form label { display: flex; flex-direction: column; gap: 2px; font-size: 12px; color: var(--muted); }
.ed-add { padding-top: 10px; border-top: 1px solid var(--border); }
.ed-add b { align-self: center; font-size: 13px; }
.ed-group td { font-weight: 600; font-size: 12px; color: var(--muted); padding-top: 10px; border-bottom: 0; }
.ed-own td:first-child { font-weight: 600; } .ed-own .ed-in { border-color: var(--accent); }
.ed-own-table { max-width: 620px; } .ed-own-table .ed-in { width: 120px !important; }
.ed-news { display: flex; flex-direction: column; gap: 6px; max-width: 620px; }
.ed-news textarea { font-size: 13px; padding: 6px 8px; }

/* ---------- обучение ---------- */
.page:has(.ln) { max-width: 1160px; }
.ln { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 16px; align-items: start; }
.ln-side { position: sticky; top: 60px; max-height: calc(100vh - 76px); overflow-y: auto; background: var(--surface); border-radius: var(--radius); padding: 8px; display: flex; flex-direction: column; gap: 1px; }
.ln-side h3 { margin: 10px 8px 3px; font-size: 11.5px; font-weight: 600; color: var(--muted); }
.ln-side h3:first-child { margin-top: 4px; }
.ln-item { display: flex; align-items: center; gap: 9px; padding: 6px 8px; border: 0; border-radius: 8px; background: none; color: var(--text); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.ln-item:hover { background: var(--bg); }
.ln-item.on { background: var(--raise); font-weight: 600; }
.ln-n { flex: none; display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 4px; border-radius: 6px; background: var(--raise); color: var(--muted); font-size: 11.5px; font-weight: 700; }
.ln-item.on .ln-n { background: var(--accent); color: var(--on-accent); }
.ln-main { gap: 10px; padding: 22px 26px; }
.ln-main h2 { font-size: 22px; margin: 0 0 4px; }
.ln-main p { margin: 0; max-width: 68ch; font-size: 15px; line-height: 1.6; }
.ln-main p.hint { font-size: 13px; }
.ln-tip { background: color-mix(in srgb, var(--accent) 8%, var(--surface)); border-left: 3px solid var(--accent); padding: 10px 14px; border-radius: 0 var(--radius-s) var(--radius-s) 0; }
.ln-nav { margin-top: 8px; }
.ln-words { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 0; margin: 0; }
.ln-words dt, .ln-words dd { margin: 0; padding: 8px 0; border-top: 1px solid var(--border); }
.ln-words dt { font-weight: 600; } .ln-words dd { color: var(--muted); }
.faq p + p { margin-top: 6px; }
@media (max-width: 800px) { .ln { grid-template-columns: 1fr; } .ln-side { position: static; max-height: 220px; } .ln-main { padding: 16px; } .ln-words { grid-template-columns: 1fr; } .ln-words dd { border-top: 0; padding-top: 0; } }
/* ---------- админка: вопросы и ответы ---------- */
.fq-list { display: flex; flex-direction: column; }
.fq-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; align-items: start; padding: 6px 0; border-top: 1px solid var(--border); }
.fq-list .fq-row:first-child { border-top: 0; }
.fq-text { display: flex; flex-direction: column; gap: 4px; }
.fq-text input.ed-in { font-weight: 600; }
.fq-text textarea { font-size: 12.5px; padding: 5px 8px; min-height: 44px; }
.fq-acts { display: flex; }
.fq-new { border-top: 2px solid var(--border); padding-top: 10px; }

/* ---------- карточка клиента: вкладки по группам ---------- */
.ct-bar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; background: none; }
.ct-group { background: var(--surface); border-radius: var(--radius); padding: 8px 8px 8px; border: 1px solid transparent; display: flex; flex-direction: column; gap: 4px; }
.ct-group.on { border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); }
.ct-head { display: flex; align-items: center; gap: 6px; padding: 0 6px 2px; font-size: 11.5px; font-weight: 600; color: var(--muted); }
.ct-group.on .ct-head { color: var(--accent); }
.ct-list { display: flex; flex-direction: column; gap: 1px; }
.ct-tab { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-height: 28px; padding: 3px 8px; border: 0; border-radius: 7px; background: none; color: var(--text); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.ct-tab:hover { background: var(--bg); }
.ct-tab.on { background: var(--accent); color: var(--on-accent); font-weight: 600; }
.ct-tab.on .adm-count { background: var(--on-accent); color: var(--accent); }
.ct-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); flex: none; }
.ct-tab.on .ct-dot { background: var(--on-accent); }
@media (max-width: 1100px) { .ct-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- админка: меню блоками ---------- */
.adm-side { background: none !important; padding: 0 !important; gap: 8px !important; }
.adm-group { background: var(--surface); border-radius: var(--radius); padding: 6px; display: flex; flex-direction: column; gap: 1px; border: 1px solid transparent; }
.adm-group.on { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.adm-side .adm-group h3 { display: flex; align-items: center; gap: 7px; margin: 0 0 4px; padding: 6px 8px; border-radius: 7px; background: var(--raise); color: var(--text); font-family: var(--font-display); font-size: 12px; font-weight: 500; }
.adm-group.on h3 { background: color-mix(in srgb, var(--accent) 12%, var(--surface)); color: var(--accent); }
.adm-group h3 .adm-count { margin-left: auto; }
.adm-side button { justify-content: flex-start !important; gap: 8px !important; text-align: left; }
.adm-side button svg { flex: none; color: var(--muted); }
.adm-side button .adm-name { flex: 1; min-width: 0; }
.adm-side button[aria-selected="true"] { background: var(--accent) !important; color: var(--on-accent); box-shadow: none !important; }
.adm-side button[aria-selected="true"] svg { color: var(--on-accent); }
.adm-side button[aria-selected="true"] .adm-count { background: var(--on-accent); color: var(--accent); }

/* ---------- правила сигналов ---------- */
.fr-table td { vertical-align: middle; padding: 6px 6px; white-space: normal; }
.fr-about { display: block; font-size: 12px; max-width: 300px; }
.fr-pars { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.fr-par { display: flex; flex-direction: column; gap: 1px; font-size: 11.5px; color: var(--muted); }
.ed-in.ed-s2 { width: 84px !important; }
.fr-off td:nth-child(n+2) { opacity: 0.5; }
.fr-pick { min-width: 220px; }
.ef-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 14px; margin: 4px 0 8px; }

/* ---------- админка: инструкция ---------- */
.adm-side .adm-guide { min-height: 38px !important; padding: 0 12px !important; border-radius: var(--radius) !important; background: var(--surface) !important; border: 1px dashed color-mix(in srgb, var(--accent) 50%, var(--border)) !important; color: var(--accent); font-weight: 600; }
.adm-side .adm-guide svg { color: var(--accent); }
.adm-side .adm-guide[aria-selected="true"] { background: var(--accent) !important; color: var(--on-accent); border-style: solid !important; }
.gd-block { gap: 6px; }
.gd-head { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--accent); }
.gd-list { display: grid; grid-template-columns: 210px minmax(0, 1fr); margin: 0; }
.gd-list dt, .gd-list dd { margin: 0; padding: 8px 0; border-top: 1px solid var(--border); }
.gd-list dt:first-of-type, .gd-list dt:first-of-type + dd { border-top: 0; }
.gd-list dt { font-weight: 600; padding-right: 12px; }
.gd-list dd { color: var(--muted); font-size: 13px; line-height: 1.5; max-width: 76ch; }
.linklike { border: 0; background: none; padding: 0; font: inherit; font-weight: 600; color: var(--accent); cursor: pointer; text-align: left; text-decoration: underline; text-underline-offset: 2px; }

.ed-in.ed-mid { width: 230px !important; } .ed-in.ed-long { width: 420px !important; max-width: 100%; }

/* Источник цен (админка) */
.fd-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 8px 0 10px; }
.fd-state { display: flex; align-items: center; gap: 8px; margin: 6px 0; font-size: 13px; }
.fd-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted, #888); flex: none; }
.fd-dot.ok { background: var(--up, #1fa37a); } .fd-dot.bad { background: var(--down, #d6455d); } .fd-dot.wait { background: #d9a62b; }
.fd-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 4px 12px; margin: 8px 0 10px; max-height: 300px; overflow: auto; }
.fd-coin { display: flex; align-items: center; gap: 7px; font-size: 13px; padding: 3px 0; cursor: pointer; }
.fd-coin span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; opacity: .8; }
.fd-coin small { opacity: .7; }

.fd-fx { display: inline-flex; align-items: center; gap: 10px; margin-left: 10px; }

/* Длинные списки в админке: поиск и «показать ещё» */
.cap-bar { display: flex; align-items: center; gap: 10px; margin: 2px 0 8px; }
.cap-find { width: 220px; max-width: 100%; height: 30px; padding: 0 10px; font-size: 13px; }
.cap-info { font-size: 12px; opacity: .7; }
.cap-foot { display: flex; gap: 8px; margin-top: 8px; }
.cap-foot:empty { display: none; }

.fd-sw { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; cursor: pointer; }
.fd-sw input { width: 16px; height: 16px; }
.fd-row .fd-state { margin: 0; }

/* Полосы прокрутки скрыты везде: списки и страница прокручиваются колесом мыши, тачпадом или пальцем */
html, body, * { scrollbar-width: none !important; -ms-overflow-style: none; }
*::-webkit-scrollbar { width: 0 !important; height: 0 !important; display: none !important; }

/* Подсказка «дальше есть ещё»: край прокручиваемого списка растворяется, пока не докрутили до конца */
.fade-b { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 30px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 30px), transparent); }
.fade-r { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 30px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 30px), transparent); }
.fade-b.fade-r { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 30px), transparent), linear-gradient(to right, #000 calc(100% - 30px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 30px), transparent), linear-gradient(to right, #000 calc(100% - 30px), transparent); -webkit-mask-composite: source-in; mask-composite: intersect; }
.page-fade { position: fixed; left: 0; right: 0; bottom: 0; height: 34px; pointer-events: none; z-index: 5; opacity: 0; transition: opacity .25s; background: linear-gradient(to bottom, transparent, var(--bg)); }
.page-fade.on { opacity: 1; }
@media (max-width: 760px) { .page-fade { display: none; } }

/* Начисление и списание: одна форма в карточке клиента и в «Финансах» */
.cr-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 12px; margin: 8px 0 6px; max-width: 980px; }
.cr-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--muted); min-width: 0; }
.cr-grid .cr-w2 { grid-column: span 2; }
.cr-grid .cr-in, .cr-grid input.ed-in { width: 100%; height: 36px; padding: 0 10px; font-size: 14px; border-radius: 8px; }
.cr-grid .sel { width: 100%; display: block; }
.cr-prev { margin: 4px 0 10px; font-size: 13px; color: var(--muted); }
.cr-acts { align-items: center; gap: 10px; }

/* Заморозка: галочки разрешений */
.fz-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 14px; margin: 4px 0 8px; max-width: 900px; }
.fz-can { font-size: 12.5px; margin-right: 8px; }
.fz-edit { margin-left: 4px; }
.fz-editrow td { background: var(--surface-2, rgba(127,127,127,.08)); padding: 12px; }

/* Закрытый раздел */
.adm-vault { margin-bottom: 8px; }
.vl-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; margin: 8px 0; }
.vl-form .field { margin: 0; min-width: 180px; }
.vl-form .vl-wide { flex: 1 1 380px; }
.vl-form .vl-wide input { width: 100%; }
.vl-pin { width: 180px; letter-spacing: 4px; font-size: 18px; }
.vl-msg { margin: 6px 0; font-size: 13.5px; color: var(--up, #1fa37a); }
.vl-msg.bad { color: var(--down, #d6455d); }
.vl-bar { display: flex; align-items: center; gap: 10px; padding: 8px 12px; margin-bottom: 10px; border-radius: 10px; background: var(--surface); font-size: 13px; }
.vl-bar span { flex: 1; }
.vl-steps { margin: 4px 0 8px 18px; padding: 0; font-size: 13px; color: var(--muted); display: flex; flex-direction: column; gap: 3px; }

.wd-addr { width: 190px !important; }

/* AML-проверка */
.aml-in { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 4px; }
.aml-in input { flex: 1 1 320px; min-width: 0; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px; }
.aml-list { display: flex; flex-direction: column; gap: 6px; }
.aml-item { border: 1px solid var(--line, rgba(127,127,127,.18)); border-radius: 10px; overflow: hidden; }
.aml-item.open { border-color: var(--accent); }
.aml-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; background: none; border: 0; color: inherit; font: inherit; cursor: pointer; text-align: left; }
.aml-row:hover { background: rgba(127,127,127,.07); }
.aml-a { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; flex: 1 1 200px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aml-n, .aml-t, .aml-u { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.aml-rep, .aml-edit { padding: 12px 14px 14px; border-top: 1px solid var(--line, rgba(127,127,127,.18)); }
.aml-item > div:not(.aml-rep):not(.aml-edit) { padding: 12px 14px; border-top: 1px solid var(--line, rgba(127,127,127,.18)); }
.aml-item > div > .aml-rep { padding: 0; border: 0; }
.aml-top { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.aml-score { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 124px; height: 84px; border-radius: 12px; color: #fff; flex: none; }
.aml-score b { font-size: 24px; line-height: 1.1; } .aml-score span { font-size: 12px; }
.aml-score.low, .aml-p.low { background: #1f9d6b; color: #fff; } .aml-score.mid, .aml-p.mid { background: #c98a12; color: #fff; } .aml-score.high, .aml-p.high { background: #cf3f58; color: #fff; }
.aml-meta { flex: 1 1 260px; min-width: 0; }
.aml-scale { position: relative; height: 8px; border-radius: 4px; background: linear-gradient(to right, #1f9d6b, #c98a12, #cf3f58); margin-top: 6px; }
.aml-scale i { position: absolute; top: -4px; width: 4px; height: 16px; margin-left: -2px; border-radius: 2px; background: var(--text); box-shadow: 0 0 0 2px var(--surface); }
.aml-legend { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); margin: 4px 0; }
.aml-line { margin: 10px 0 4px; font-size: 14px; }
.aml-srcs h3 { margin: 12px 0 6px; font-size: 13.5px; }
.aml-src { display: grid; grid-template-columns: 190px 1fr 58px; gap: 10px; align-items: center; font-size: 13px; padding: 2px 0; }
.aml-src b { text-align: right; font-weight: 600; }
.aml-bar { height: 7px; border-radius: 4px; background: rgba(127,127,127,.16); overflow: hidden; }
.aml-bar i { display: block; height: 100%; border-radius: 4px; background: #1f9d6b; }
.aml-src.mid .aml-bar i { background: #c98a12; } .aml-src.high .aml-bar i { background: #cf3f58; }
.aml-full { margin: 0 0 8px; font-size: 13px; word-break: break-all; } .aml-full b { font-family: ui-monospace, Menlo, Consolas, monospace; }
.aml-facts { margin: 0 0 10px 18px; padding: 0; font-size: 13px; color: var(--muted); }
.aml-fields { display: flex; gap: 12px; flex-wrap: wrap; margin: 10px 0; } .aml-fields label, .aml-cat { display: flex; flex-direction: column; gap: 3px; font-size: 12.5px; color: var(--muted); }
.aml-wide { flex: 1 1 280px; } .aml-wide input { width: 100%; }
.aml-catsbox { margin: 6px 0 10px; } .aml-catshead { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.aml-sum.bad { color: #cf3f58; }
.aml-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px 12px; }
.aml-cat input { width: 100%; } .aml-cat.high span { color: #cf3f58; } .aml-cat.mid span { color: #c98a12; }
.aml-edit textarea { width: 100%; }
@media (max-width: 760px) { .aml-src { grid-template-columns: 120px 1fr 52px; } .aml-row { flex-wrap: wrap; gap: 6px 10px; } .aml-score { width: 100%; flex-direction: row; gap: 10px; height: 54px; } }

/* Комплаенс */
.cp-f { display: flex; flex-direction: column; gap: 3px; font-size: 12.5px; color: var(--muted); min-width: 0; }
.cp-f.cp-grow { flex: 1 1 240px; } .cp-f.cp-grow input { width: 100%; }
.cp-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px 12px; margin: 8px 0; max-width: 1000px; }
.cp-grid .cp-w2 { grid-column: span 2; } .cp-grid input, .cp-grid .sel { width: 100%; }
.cp-form { margin: 8px 0; } .cp-form textarea { width: 100%; }
.cp-bar { align-items: flex-end; gap: 10px; margin: 4px 0 10px; }
.cp-tabs { margin-bottom: 10px; }
.cp-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; } .cp-head h2 { margin: 0; }
.cp-text { font-size: 14.5px; margin: 8px 0 4px; white-space: pre-wrap; } .cp-ans { margin: 8px 0; font-size: 14px; white-space: pre-wrap; }
.cp-sof { border: 1px solid var(--accent); }
.cp-thumbs { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 10px; }
.cp-thumb { width: 84px; height: 84px; padding: 0; border: 1px solid var(--line, rgba(127,127,127,.25)); border-radius: 8px; overflow: hidden; background: none; cursor: pointer; display: block; }
.cp-thumbs.big .cp-thumb { width: 150px; height: 150px; } .cp-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cp-weights { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 6px 18px; margin: 8px 0 12px; }
.cp-w { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13px; } .cp-w input { width: 64px; flex: none; text-align: right; } .cp-wsel .sel, .cp-wsel select { width: 210px; flex: none; }
.cp-kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 2px 22px; margin: 6px 0 12px; }
.cp-kv > div { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; border-bottom: 1px solid var(--line, rgba(127,127,127,.14)); font-size: 13px; } .cp-kv span { color: var(--muted); }
.cp-plain { font-family: inherit !important; }
.cp-tm { display: contents; }
@media (max-width: 760px) { .cp-grid { grid-template-columns: 1fr 1fr; } }

.row:has(> .cp-f), .row:has(> .check) { align-items: flex-end; }
.row:has(> .cp-f) > .btn { align-self: flex-end; }
.row:has(> .cp-f) > .check { padding-bottom: 8px; }

/* Развёрнутая проверка личности */
.kx-group { border: 1px solid var(--line, rgba(127,127,127,.18)); border-radius: 12px; padding: 10px 14px 14px; margin: 12px 0; min-width: 0; }
.kx-group legend { padding: 0 6px; font-weight: 600; font-size: 14px; }
.kx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px 14px; }
.kx-f { margin: 0; min-width: 0; } .kx-f input, .kx-f .sel, .kx-f select { width: 100%; } .kx-f label small { color: var(--muted); font-weight: 400; }
.kx-f input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.kx-bad > input, .kx-bad .sel-btn, .kx-bad .kx-photo { border-color: #cf3f58 !important; box-shadow: 0 0 0 1px #cf3f58; } label.kx-bad span { color: #cf3f58; }
.kx-err { margin: 3px 0 0; font-size: 12px; color: #cf3f58; }
.kx-fix > label span:first-child::after { content: ' · исправьте'; color: #c98a12; font-weight: 600; }
.kx-photo { display: flex; align-items: center; gap: 12px; border: 1px dashed var(--line, rgba(127,127,127,.35)); border-radius: 10px; padding: 8px; min-height: 76px; }
.kx-photo img { width: 96px; height: 64px; object-fit: cover; border-radius: 6px; flex: none; } .kx-ph { color: var(--muted); font-size: 12.5px; flex: 1; } .kx-pbtn { display: flex; gap: 6px; flex-wrap: wrap; margin-left: auto; }
.kx-decl { display: flex; flex-direction: column; gap: 6px; margin: 10px 0 14px; }
.kx-card { gap: 10px; } .kx-cols { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(240px, 1fr); gap: 16px; }
.kx-sec h4, .kx-side h4 { margin: 10px 0 6px; font-size: 13px; color: var(--muted); font-weight: 600; } .kx-sec:first-child h4, .kx-side h4:first-child { margin-top: 0; }
.kx-kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 2px 18px; }
.kx-kv > div { display: flex; flex-direction: column; padding: 3px 0; font-size: 13.5px; min-width: 0; } .kx-kv span { font-size: 11.5px; color: var(--muted); } .kx-kv b { font-weight: 600; overflow-wrap: anywhere; }
.kx-shots { display: flex; gap: 10px; flex-wrap: wrap; }
.kx-shot { width: 150px; border: 1px solid var(--line, rgba(127,127,127,.22)); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; color: inherit; text-decoration: none; font-size: 11.5px; }
.kx-shot img { width: 100%; height: 100px; object-fit: cover; display: block; } .kx-shot span { padding: 4px 6px; color: var(--muted); } .kx-shot.none { justify-content: center; min-height: 60px; border-style: dashed; }
.kx-auto { list-style: none; margin: 0 0 6px; padding: 0; font-size: 13px; display: flex; flex-direction: column; gap: 3px; }
.kx-auto li { padding-left: 18px; position: relative; } .kx-auto li::before { content: ''; position: absolute; left: 2px; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: #c98a12; }
.kx-auto li.ok::before { background: #1f9d6b; } .kx-auto li.bad::before { background: #cf3f58; } .kx-auto li.bad { color: #cf3f58; }
.kx-side .check { display: flex; margin: 3px 0; font-size: 13px; } .kx-fixes { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; max-height: 190px; overflow: auto; }
.kx-card textarea, .kx-card .field > input { width: 100%; }
@media (max-width: 900px) { .kx-cols { grid-template-columns: 1fr; } }

/* Виды уведомлений */
.nt-tabs { margin: 0 0 8px; flex-wrap: wrap; }
.notes .note { grid-template-columns: 30px 1fr; gap: 10px; padding: 9px 10px; border-left: 3px solid transparent; border-radius: 6px; margin-bottom: 2px; }
.nt-ic { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: rgba(127,127,127,.14); color: var(--muted) !important; }
.nt-body { min-width: 0; } .nt-meta { display: flex; gap: 10px; align-items: baseline; font-size: 12px; } .nt-meta b { font-weight: 600; } .nt-meta span { font-size: 12px; }
.nt-body p { margin: 2px 0 0; overflow-wrap: anywhere; }
.nt-official { border-left-color: #cf3f58 !important; background: rgba(207,63,88,.07); } .nt-official .nt-ic { background: #cf3f58; color: #fff !important; } .nt-official .nt-meta b { color: #cf3f58; }
.nt-support { border-left-color: var(--accent) !important; } .nt-support .nt-ic { background: var(--accent); color: var(--on-accent, #fff) !important; } .nt-support .nt-meta b { color: var(--accent); }
.nt-security { border-left-color: #c98a12 !important; } .nt-security .nt-ic { background: #c98a12; color: #fff !important; } .nt-security .nt-meta b { color: #c98a12; }
.nt-info .nt-meta b { color: var(--muted); }
.badge.hot { background: #cf3f58 !important; color: #fff !important; }
/* Риск счёта и важные сообщения у клиента */
.rk-strip { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.rk-strip .aml-score { width: 96px; height: 58px; border-radius: 10px; } .rk-strip .aml-score b { font-size: 19px; } .rk-strip .aml-score span { font-size: 11px; }
.rk-strip .aml-meta { flex: 1 1 240px; } .rk-tips { margin: 6px 0 0 16px; padding: 0; font-size: 12.5px; color: var(--muted); }
.alert-hard { border: 1px solid #cf3f58; background: rgba(207,63,88,.09); border-radius: 12px; padding: 12px 14px; margin: 0 0 12px; display: flex; gap: 12px; align-items: flex-start; }
.alert-hard svg { color: #cf3f58; flex: none; margin-top: 2px; } .alert-hard b { display: block; color: #cf3f58; margin-bottom: 2px; } .alert-hard p { margin: 0; font-size: 13.5px; }

.cp-sub { margin: 8px 0 2px; font-size: 12.5px; color: var(--muted); }
.cp-inqreq { border-top: 1px solid var(--line, rgba(127,127,127,.18)); margin-top: 10px; padding-top: 6px; }

/* Что ограничено и почему */
.rs-panel { border-left: 3px solid #c98a12; }
.rs-list { display: flex; flex-direction: column; }
.rs-row { display: grid; grid-template-columns: minmax(140px, 220px) 1fr auto; gap: 6px 14px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line, rgba(127,127,127,.14)); font-size: 13.5px; }
.rs-row:last-child { border-bottom: 0; } .rs-row b { font-weight: 600; } .rs-row span { color: var(--muted); } .rs-row i { display: none; }
@media (max-width: 700px) { .rs-row { grid-template-columns: 1fr; } }

/* Сворачиваемые блоки настроек */
.fold-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; cursor: pointer; margin-bottom: 0; }
.panel:not(.folded) > .fold-head { margin-bottom: 10px; }
.fold-btn { border: 0; background: rgba(127,127,127,.12); color: inherit; width: 26px; height: 26px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex: none; }
.fold-btn svg { transition: transform .15s; } .fold-btn[aria-expanded="false"] svg { transform: rotate(-90deg); }
.panel.folded { padding-top: 12px; padding-bottom: 12px; }
.foot-credits { font-size: 12px; opacity: .75; } .foot-credits a { color: inherit; }

/* Заметные плашки вверху страниц клиента */
.top-alerts { display: flex; flex-direction: column; gap: 8px; margin: 0 0 14px; }
.top-alert, .top-alerts .alert-hard { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-radius: 12px; margin: 0; border: 1px solid transparent; border-left-width: 6px; box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.ta-ic { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex: none; color: #fff; }
.ta-body { flex: 1; min-width: 0; } .ta-body b { display: block; font-size: 15px; } .ta-body p { margin: 2px 0 0; font-size: 13.5px; overflow-wrap: anywhere; }
.ta-cats { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin-top: 6px; font-size: 12px; } .ta-cats span { opacity: .8; }
.ta-cats i { font-style: normal; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: rgba(0,0,0,.12); }
.ta-btn { flex: none; white-space: nowrap; }
.ta-reg { background: #b3243f; border-color: #8e1a31; color: #fff; } .ta-reg .ta-ic { background: rgba(255,255,255,.2); } .ta-reg .ta-cats i { background: rgba(255,255,255,.22); } .ta-reg .ta-btn { background: #fff !important; color: #b3243f !important; }
.ta-ex { background: rgba(224,134,20,.14); border-color: #e08614; } .ta-ex .ta-ic { background: #e08614; } .ta-ex b { color: #b86a08; } .ta-ex .ta-btn { background: #e08614 !important; color: #fff !important; }
.ta-lock { background: rgba(127,127,127,.12); border-color: #8a8fa3; } .ta-lock .ta-ic { background: #6b7085; }
.top-alerts .alert-hard { background: #7d1227; border-color: #5c0c1b; color: #fff; } .top-alerts .alert-hard b, .top-alerts .alert-hard svg { color: #fff; } .top-alerts .alert-hard a { color: #fff; text-decoration: underline; }
@media (max-width: 700px) { .top-alert { flex-wrap: wrap; } .ta-btn { width: 100%; text-align: center; } }
/* Запросы на странице «Идентификация»: чем важнее, тем заметнее */
.cp-sof.cp-k-reg { border: 2px solid #b3243f; } .cp-sof.cp-k-reg .cp-head h2 { color: #b3243f; } .cp-sof.cp-k-reg.cp-need { box-shadow: 0 0 0 4px rgba(179,36,63,.14); }
.cp-sof.cp-k-ex { border: 2px solid #e08614; } .cp-sof.cp-k-ex .cp-head h2 { color: #b86a08; }
/* Уведомления: запрос регулятора самый заметный, требование биржи оранжевое */
.nt-regulator { border-left: 5px solid #b3243f !important; background: #b3243f; color: #fff; } .nt-regulator .nt-ic { background: rgba(255,255,255,.22); color: #fff !important; } .nt-regulator .nt-meta b, .nt-regulator .nt-meta span { color: #fff !important; }
.nt-official { border-left-color: #e08614 !important; background: rgba(224,134,20,.10); } .nt-official .nt-ic { background: #e08614; } .nt-official .nt-meta b { color: #b86a08; }
.nt-security { border-left-color: #2a86c8 !important; } .nt-security .nt-ic { background: #2a86c8; } .nt-security .nt-meta b { color: #2a86c8; }
.rs-panel { border-left: 6px solid #e08614; } .rs-panel h2 { color: #b86a08; } .rs-row b { font-size: 14px; }

/* Короткие плашки (нажимаются) и окно с подробностями */
.top-alerts { gap: 6px; margin-bottom: 12px; }
button.top-alert { width: 100%; text-align: left; font: inherit; cursor: pointer; padding: 8px 14px; gap: 10px; min-height: 0; border-radius: 10px; border-left-width: 5px; box-shadow: none; }
button.top-alert:hover { filter: brightness(1.06); } button.top-alert:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
button.top-alert .ta-ic { width: 26px; height: 26px; } button.top-alert b { font-size: 14px; white-space: nowrap; color: inherit; }
.ta-short { flex: 1; min-width: 0; font-size: 13px; opacity: .92; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ta-n { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: rgba(0,0,0,.12); white-space: nowrap; } .ta-reg .ta-n, .ta-sanc .ta-n { background: rgba(255,255,255,.22); }
.ta-more { font-size: 12.5px; font-weight: 600; text-decoration: underline; white-space: nowrap; opacity: .9; }
.ta-ex b { color: #b86a08; } .ta-sanc { background: #7d1227; border-color: #5c0c1b; color: #fff; } .ta-sanc .ta-ic { background: rgba(255,255,255,.2); }
dialog.ta-dialog { width: min(560px, calc(100vw - 24px)); border-top: 6px solid #8a8fa3; }
dialog.ta-dialog.ta-reg { border-top-color: #b3243f; background: var(--surface); color: var(--text); } dialog.ta-dialog.ta-sanc { border-top-color: #7d1227; background: var(--surface); color: var(--text); } dialog.ta-dialog.ta-ex { border-top-color: #e08614; background: var(--surface); }
dialog.ta-dialog .confirm-head h2 { display: flex; align-items: center; gap: 10px; } dialog.ta-dialog .ta-ic { width: 32px; height: 32px; background: #6b7085; }
dialog.ta-dialog.ta-reg .ta-ic { background: #b3243f; } dialog.ta-dialog.ta-sanc .ta-ic { background: #7d1227; } dialog.ta-dialog.ta-ex .ta-ic { background: #e08614; }
dialog.ta-dialog.ta-reg h2 { color: #b3243f; } dialog.ta-dialog.ta-ex h2 { color: #b86a08; }
.ta-full { font-size: 15px; margin: 4px 0 12px; padding: 10px 12px; border-radius: 10px; background: rgba(127,127,127,.10); white-space: pre-wrap; overflow-wrap: anywhere; }
dialog.ta-dialog .kv-row { align-items: flex-start; gap: 14px; } dialog.ta-dialog .kv-row span { flex: 0 0 150px; } dialog.ta-dialog .kv-row b { text-align: left; font-weight: 500; flex: 1; overflow-wrap: anywhere; }
.ta-cats-d { margin: 12px 0; } dialog.ta-dialog .ta-cats i { background: rgba(127,127,127,.18); }
dialog.ta-dialog .confirm-acts a.btn { text-decoration: none; }
@media (max-width: 700px) { button.top-alert { flex-wrap: nowrap; } .ta-more { display: none; } dialog.ta-dialog .kv-row { flex-direction: column; gap: 2px; } dialog.ta-dialog .kv-row span { flex: none; } }

.cp-inqline { font-weight: 600; margin: 6px 0 0; }
