/* Master Manager — оформление. Светлая рабочая область, тёмное меню, один акцент (лайм). */

@font-face { font-family: 'Manrope'; font-style: normal; font-display: swap; font-weight: 200 800;
  src: url(/fonts/manrope-cyrillic-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Manrope'; font-style: normal; font-display: swap; font-weight: 200 800;
  src: url(/fonts/manrope-latin-ext-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Manrope'; font-style: normal; font-display: swap; font-weight: 200 800;
  src: url(/fonts/manrope-latin-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --page: #f3f2ed;
  --surface: #fcfcfb;
  --surface-2: #f5f4ef;
  --ink: #0b0b0b;
  --ink-2: #52514e;
  --muted: #898781;
  --line: #e1e0d9;
  --axis: #c3c2b7;
  --side: #111110;
  --side-2: #1f1f1d;
  --side-ink: #f0efec;
  --side-muted: #9a9992;
  --accent: #d6f551;
  --accent-ink: #1b2400;
  --good: #006300;
  --good-bg: #e6f3e2;
  --bad: #b3261e;
  --bad-bg: #fbe9e7;
  --warn: #8a5a00;
  --warn-bg: #fdf1d3;
  /* Цвета рядов на графиках — фиксированный порядок, не менять местами */
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100;
  --s5: #e87ba4; --s6: #008300; --s7: #6250d6; --s8: #e34948;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(11, 11, 11, .04), 0 8px 24px -16px rgba(11, 11, 11, .18);
  --side-w: 252px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font: 500 14px/1.5 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .55; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 6px; }
.side :focus-visible, .login-pitch :focus-visible { outline-color: var(--accent); }
.icon { flex: none; }
.muted { color: var(--ink-2); }
.small { font-size: 12.5px; }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
code { font: 500 12.5px/1.4 ui-monospace, 'Cascadia Code', Consolas, monospace; background: var(--surface-2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; }

/* ---------- каркас ---------- */
.shell { min-height: 100vh; }
.side {
  position: fixed; inset: 0 auto 0 0; width: var(--side-w); background: var(--side); color: var(--side-ink);
  display: flex; flex-direction: column; padding: 18px 12px 12px; overflow-y: auto;
}
.view { margin-left: var(--side-w); padding: 30px 36px 72px; max-width: calc(1240px + var(--side-w)); }
.narrow { max-width: 760px; }

.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 15.5px; letter-spacing: -.01em; text-decoration: none; padding: 4px 8px 18px; }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 800; font-size: 17px; }

.nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.nav-title { font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--side-muted); padding: 20px 10px 6px; }
.nav-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px; border: 0; background: none; width: 100%;
  color: #d5d4ce; text-decoration: none; font-weight: 600; text-align: left; position: relative;
}
.nav-item span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-item:hover { background: var(--side-2); color: #fff; }
.nav-item.on { background: var(--side-2); color: #fff; }
.nav-item.on::before { content: ''; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: var(--accent); }
.nav-emoji { width: 18px; text-align: center; font-size: 15px; line-height: 1; }
.nav-add { color: var(--side-muted); margin-top: 4px; }
.side-foot { border-top: 1px solid #2a2a27; padding-top: 10px; margin-top: 16px; display: flex; flex-direction: column; gap: 6px; }
.me { display: flex; align-items: center; gap: 10px; padding: 6px 4px 2px 8px; }
.me-pic { width: 28px; height: 28px; border-radius: 50%; background: #33332f; display: grid; place-items: center; font-weight: 700; font-size: 13px; object-fit: cover; flex: none; }
.me-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: #d5d4ce; }

/* ---------- шапка страницы ---------- */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; margin-bottom: 22px; }
.page-title h1 { font-size: 27px; font-weight: 750; letter-spacing: -.025em; line-height: 1.15; }
.page-sub { color: var(--ink-2); margin-top: 4px; }
.page-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 14px;
  border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-weight: 650; text-decoration: none; white-space: nowrap;
  transition: background .12s, border-color .12s;
}
.btn:hover:not(:disabled) { border-color: var(--axis); background: #fff; }
.btn-primary { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-primary:hover:not(:disabled) { background: #2b2b28; border-color: #2b2b28; }
.btn-danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn-danger:hover:not(:disabled) { background: #8f1d17; border-color: #8f1d17; }
.btn-quiet { border-color: transparent; background: none; color: var(--ink-2); }
.btn-quiet:hover:not(:disabled) { background: var(--surface-2); border-color: transparent; color: var(--ink); }
.btn-danger-quiet:hover:not(:disabled) { background: var(--bad-bg); color: var(--bad); }
.btn-big { height: 46px; width: 100%; font-size: 15px; border-radius: 12px; }
.btn-icon { width: 32px; height: 32px; border-radius: 8px; border: 0; background: none; display: inline-grid; place-items: center; color: var(--ink-2); }
.btn-icon:hover { background: var(--surface-2); color: var(--ink); }
.btn-icon-dark { color: var(--side-muted); }
.btn-icon-dark:hover { background: var(--side-2); color: #fff; }

.seg { display: inline-flex; padding: 3px; background: #e7e6df; border-radius: 10px; gap: 2px; }
.seg button { border: 0; background: none; height: 30px; padding: 0 12px; border-radius: 8px; font-weight: 650; color: var(--ink-2); white-space: nowrap; }
.seg button:hover { color: var(--ink); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(11, 11, 11, .12); }

/* ---------- плашки и метки ---------- */
.note { display: flex; gap: 10px; align-items: flex-start; background: #ecf6c4; color: #2a3600; border-radius: 12px; padding: 11px 14px; margin-bottom: 20px; font-size: 13.5px; }
.note .icon { margin-top: 1px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px; border-radius: 7px; background: var(--surface-2); border: 1px solid var(--line); font-size: 12.5px; font-weight: 650; white-space: nowrap; }
.tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 6px; background: #e7e6df; color: var(--ink-2); font-size: 12px; font-weight: 700; white-space: nowrap; text-decoration: none; }
a.tag:hover { color: var(--ink); background: #dddcd4; }
.tag-accent { background: var(--accent); color: var(--accent-ink); }
.swatch { width: 10px; height: 10px; border-radius: 3px; flex: none; display: inline-block; }
.link { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-2); text-decoration: none; font-weight: 600; }
.link:hover { color: var(--ink); text-decoration: underline; }
.link-quiet { font-weight: 500; font-size: 12.5px; color: var(--muted); }

.delta { display: inline-flex; align-items: center; gap: 3px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.delta-up { color: var(--good); }
.delta-down { color: var(--bad); }
.delta-flat { color: var(--muted); font-weight: 600; }

/* ---------- карточки ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.pad { padding: 18px 20px; }
.pad-x { padding: 0 20px 20px; }
.block { margin-top: 32px; }
.block-head { margin-bottom: 12px; }
.block-head h2 { font-size: 17px; font-weight: 750; letter-spacing: -.015em; }
.block-head p { color: var(--ink-2); font-size: 13px; margin-top: 2px; max-width: 78ch; }
.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 20px; }
.two-col > .block { margin-top: 12px; }

.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px 14px; box-shadow: var(--shadow); min-width: 0; }
.tile-label { color: var(--ink-2); font-size: 13px; font-weight: 600; }
.tile-value { font-size: 30px; font-weight: 750; letter-spacing: -.03em; line-height: 1.2; margin: 4px 0 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tile-foot { min-height: 19px; }

/* ---------- графики ---------- */
.chart-card { padding: 18px 20px 14px; min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 10px; }
.card-head h3 { font-size: 15.5px; font-weight: 750; letter-spacing: -.01em; }
.card-note { color: var(--ink-2); font-size: 12.5px; }
.card-tools { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 8px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.legend-item { display: inline-flex; align-items: center; gap: 6px; }
.chart { position: relative; width: 100%; min-height: 230px; }
.chart svg { display: block; touch-action: pan-y; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .axis, .spark .axis { stroke: var(--axis); stroke-width: 1; }
.chart .tick { fill: var(--muted); font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
.chart .cross { stroke: var(--axis); stroke-width: 1; }
.chart .ring { stroke: var(--surface); stroke-width: 2; }
.chart-tip {
  position: absolute; top: 0; left: 0; pointer-events: none; z-index: 2; min-width: 150px; max-width: 260px;
  background: var(--ink); color: #fff; border-radius: 10px; padding: 9px 11px; font-size: 12.5px; box-shadow: 0 8px 24px -8px rgba(0, 0, 0, .4);
}
.chart-tip[hidden] { display: none; }
.tip-date { color: #b9b8b1; font-weight: 600; margin-bottom: 5px; }
.tip-row { display: flex; align-items: center; gap: 7px; line-height: 1.7; }
.tip-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tip-row b { font-variant-numeric: tabular-nums; }
.chart-table { max-height: 230px; overflow: auto; }

/* ---------- таблицы ---------- */
.table-scroll { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.table th { text-align: left; font-size: 12px; font-weight: 700; color: var(--ink-2); padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface); position: sticky; top: 0; }
.table th.r { text-align: right; }
.table td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: #f8f7f3; }
.table th:first-child, .table td:first-child { padding-left: 20px; }
.table th:last-child, .table td:last-child { padding-right: 20px; }
.th-sort { border: 0; background: none; padding: 0; font-weight: 700; color: var(--ink-2); display: inline-flex; align-items: center; gap: 3px; }
.th-sort:hover, .th-sort.on { color: var(--ink); }
.post-title { max-width: 340px; font-weight: 600; }
.post-title a { text-decoration: none; }
.post-title a:hover { text-decoration: underline; }
.chan { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; color: var(--ink-2); }
.chan-cell { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cell-stack { display: inline-flex; flex-direction: column; align-items: flex-end; line-height: 1.35; }
.ratio { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink-2); }
.ratio-bar { width: 44px; height: 6px; border-radius: 3px; background: #e7e6df; overflow: hidden; }
.ratio-bar i { display: block; height: 100%; border-radius: 3px; background: var(--axis); }
.ratio.hot { color: var(--ink); }
.ratio.hot .ratio-bar i { background: var(--ink); }
.ratio.cold { color: var(--muted); }
.block > .btn-quiet { margin-top: 8px; }

/* ---------- продукты ---------- */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.product-card { display: flex; flex-direction: column; gap: 14px; padding: 16px 18px 14px; text-decoration: none; transition: border-color .12s, transform .12s; }
.product-card:hover { border-color: var(--ink); transform: translateY(-1px); }
.pc-head { display: flex; align-items: center; gap: 12px; }
.pc-name { flex: 1; min-width: 0; }
.pc-name h3 { font-size: 15.5px; font-weight: 750; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-name span { color: var(--ink-2); font-size: 12.5px; }
.avatar { width: 40px; height: 40px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); display: grid; place-items: center; font-size: 20px; flex: none; object-fit: cover; font-weight: 750; }
.avatar-lg { width: 52px; height: 52px; border-radius: 15px; font-size: 26px; }
.spark { display: block; width: 100%; }
.pc-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pc-stat { display: flex; flex-direction: column; min-width: 0; }
.pc-label { color: var(--ink-2); font-size: 12.5px; }
.pc-stat b { font-size: 21px; font-weight: 750; letter-spacing: -.02em; line-height: 1.3; }
.pc-empty { color: var(--ink-2); font-size: 13px; flex: 1; }
.pc-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); padding-top: 11px; margin-top: auto; min-height: 34px; }
.pc-platforms { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 12.5px; }

.product-title { display: flex; align-items: center; gap: 14px; }
.product-meta { display: flex; align-items: center; gap: 12px; margin-top: 6px; flex-wrap: wrap; }
.about { margin-bottom: 20px; max-width: 78ch; color: var(--ink-2); display: grid; gap: 6px; }
.goal { color: var(--ink); font-weight: 600; }
.goal span { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; background: var(--accent); color: var(--accent-ink); border-radius: 5px; padding: 1px 6px; margin-right: 8px; vertical-align: 1px; }

/* ---------- задачи ---------- */
.actions { padding: 6px 0; }
.actions-flat { padding: 0; }
.action { display: flex; align-items: flex-start; gap: 12px; padding: 11px 20px; }
.actions-flat .action { padding: 9px 0; }
.action + .action { border-top: 1px solid var(--line); }
.check { width: 20px; height: 20px; margin-top: 1px; border-radius: 6px; border: 1.6px solid var(--axis); background: var(--surface); display: grid; place-items: center; flex: none; padding: 0; }
.check:hover { border-color: var(--ink); }
.check.on { background: var(--accent); border-color: #a9c92b; color: var(--accent-ink); }
.action-body { flex: 1; min-width: 0; }
.action-text { font-weight: 650; }
.action-why { color: var(--ink-2); font-size: 13px; }
.action.is-done .action-text { text-decoration: line-through; color: var(--muted); }
.action.is-done .action-why { display: none; }

.top-posts { padding: 6px 0; }
.top-posts li { display: flex; align-items: center; gap: 12px; padding: 10px 20px; }
.top-posts li + li { border-top: 1px solid var(--line); }
.rank { width: 22px; height: 22px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); display: grid; place-items: center; font-size: 12px; font-weight: 750; flex: none; }
.top-body { flex: 1; min-width: 0; }
.top-title { font-weight: 650; text-decoration: none; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-title:hover { text-decoration: underline; }
.top-meta { display: flex; align-items: center; gap: 5px; color: var(--ink-2); font-size: 12.5px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.top-views { font-size: 15px; font-variant-numeric: tabular-nums; }

/* ---------- наблюдения и разбор ---------- */
.obs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.obs { display: flex; gap: 12px; padding: 15px 18px; }
.obs h3 { font-size: 14.5px; font-weight: 750; letter-spacing: -.005em; }
.obs p { color: var(--ink-2); font-size: 13.5px; margin-top: 3px; }
.obs-icon { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; flex: none; background: var(--surface-2); color: var(--ink-2); }
.obs-good .obs-icon { background: var(--good-bg); color: var(--good); }
.obs-warn .obs-icon { background: var(--warn-bg); color: var(--warn); }

.insight { padding: 20px 22px; }
.insight-meta { display: flex; align-items: center; gap: 10px; color: var(--ink-2); font-size: 12.5px; margin-bottom: 12px; }
.insight-summary { font-size: 19px; font-weight: 700; letter-spacing: -.015em; line-height: 1.35; max-width: 62ch; }
.verdicts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 18px 0; }
.verdict { border-radius: 12px; padding: 13px 16px; background: var(--surface-2); }
.verdict h4 { display: flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 750; margin-bottom: 6px; }
.verdict-good h4 { color: var(--good); }
.verdict-warn h4 { color: var(--warn); }
.verdict li { position: relative; padding-left: 14px; margin-top: 4px; font-size: 13.5px; }
.verdict li::before { content: ''; position: absolute; left: 2px; top: .62em; width: 4px; height: 4px; border-radius: 50%; background: var(--axis); }
.insight-next { font-size: 13.5px; font-weight: 750; margin-bottom: 2px; }
.own-actions { margin-top: 14px; padding: 12px 20px; }
.add-action { display: flex; gap: 8px; }
.own-actions .actions-flat + .add-action { margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.older { margin-top: 14px; }
.older summary { cursor: pointer; font-weight: 650; color: var(--ink-2); padding: 6px 0; }
.older .insight { margin-top: 10px; }

.ingest p + .code, .code + p { margin-top: 12px; }
.code { display: flex; align-items: flex-start; gap: 10px; background: var(--side); color: #e9e8e2; border-radius: 12px; padding: 14px 10px 14px 16px; }
.code pre { margin: 0; flex: 1; overflow-x: auto; font: 500 12.5px/1.6 ui-monospace, 'Cascadia Code', Consolas, monospace; white-space: pre; }
.code .btn-quiet { color: #c9c8c1; flex: none; }
.code .btn-quiet:hover:not(:disabled) { background: var(--side-2); color: #fff; }
.danger-row { margin-top: 36px; padding-top: 16px; border-top: 1px solid var(--line); }

.empty { text-align: center; padding: 56px 24px; border: 1.5px dashed var(--axis); border-radius: var(--radius); display: grid; gap: 8px; justify-items: center; margin: 12px 0 8px; }
.empty h3 { font-size: 18px; font-weight: 750; letter-spacing: -.015em; }
.empty p { color: var(--ink-2); max-width: 56ch; }
.empty .btn { margin-top: 10px; }

/* ---------- окна и формы ---------- */
.modal { border: 0; border-radius: 18px; padding: 0; width: min(520px, calc(100vw - 32px)); background: var(--surface); color: var(--ink); box-shadow: 0 24px 80px -20px rgba(0, 0, 0, .5); }
.modal::backdrop { background: rgba(17, 17, 16, .5); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 16px 4px 22px; }
.modal-head h2 { font-size: 18px; font-weight: 750; letter-spacing: -.015em; }
.modal-body { padding: 12px 22px 20px; display: grid; gap: 14px; }
.field { display: grid; gap: 5px; min-width: 0; }
.field-label { font-size: 13px; font-weight: 700; }
.field-hint { font-size: 12.5px; color: var(--ink-2); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.input { width: 100%; min-height: 38px; padding: 8px 11px; border-radius: 10px; border: 1px solid var(--axis); background: #fff; }
.input::placeholder { color: var(--muted); }
.input:focus-visible { outline: 2px solid var(--ink); outline-offset: 0; border-color: var(--ink); border-radius: 10px; }
textarea.input { resize: vertical; }
.emoji-pick { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.input-emoji { width: 52px; text-align: center; font-size: 18px; padding: 4px; }
.emoji-btn { width: 30px; height: 30px; border: 0; background: none; border-radius: 8px; font-size: 16px; padding: 0; }
.emoji-btn:hover { background: var(--surface-2); }
.form-error { color: var(--bad); font-weight: 650; font-size: 13.5px; }
.form-error:empty { display: none; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }

.toasts { position: fixed; right: 20px; bottom: 20px; display: grid; gap: 8px; z-index: 50; }
.toast { background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 11px; font-weight: 650; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .5); animation: rise .18s ease-out; max-width: 340px; }
.toast-err { background: var(--bad); }
@keyframes rise { from { transform: translateY(8px); opacity: 0; } }

/* ---------- настройки ---------- */
.account { display: flex; align-items: center; gap: 14px; }
.account > div { flex: 1; min-width: 0; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.token-box { display: grid; gap: 12px; margin-bottom: 12px; }
.steps ol { list-style: decimal; padding-left: 18px; display: grid; gap: 8px; color: var(--ink-2); }
.steps b { color: var(--ink); }

/* ---------- вход ---------- */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
.login-pitch { background: var(--side); color: var(--side-ink); padding: 32px 48px; display: flex; flex-direction: column; }
.login-pitch .logo { padding: 0; }
.pitch-body { margin: auto 0; max-width: 520px; padding: 40px 0; }
.pitch-body h1 { font-size: clamp(30px, 3.4vw, 44px); font-weight: 780; letter-spacing: -.035em; line-height: 1.08; }
.pitch-body > p { color: #b9b8b1; font-size: 16px; margin-top: 16px; max-width: 46ch; }
.points { margin-top: 32px; display: grid; gap: 16px; }
.points li { display: flex; gap: 12px; }
.points b { display: block; font-weight: 700; }
.points div span { color: #a3a29b; font-size: 13.5px; }
.pt-mark { width: 24px; height: 24px; border-radius: 7px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: none; margin-top: 1px; }
.pitch-foot { color: var(--side-muted); font-size: 12.5px; }
.login-form { display: grid; place-items: center; padding: 32px 24px; }
.login-box { width: min(360px, 100%); display: grid; gap: 12px; }
.login-box h2 { font-size: 26px; font-weight: 760; letter-spacing: -.025em; }
.ways { display: grid; gap: 10px; margin-top: 8px; }
.g-mark { width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.tg-slot { display: grid; place-items: center; min-height: 46px; }

/* ---------- загрузка ---------- */
.sk { background: linear-gradient(90deg, #e9e8e1 25%, #f1f0ea 50%, #e9e8e1 75%); background-size: 200% 100%; border-radius: var(--radius); animation: shimmer 1.2s linear infinite; height: 96px; }
.sk-title { height: 34px; width: 220px; border-radius: 9px; margin-bottom: 24px; }
.sk-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 20px; }
.sk-chart { height: 300px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- узкие экраны ---------- */
@media (max-width: 1080px) {
  .tiles, .sk-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .two-col { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .side { position: sticky; top: 0; z-index: 10; inset: auto; width: auto; flex-direction: row; align-items: center; padding: 8px 10px; gap: 6px; overflow-x: auto; }
  .side .logo { padding: 0 6px 0 2px; }
  .logo-text, .nav-title, .me-name, .me-pic { display: none; }
  .nav { flex-direction: row; flex: 1; gap: 4px; }
  .nav-item { width: auto; white-space: nowrap; padding: 7px 10px; }
  .nav-item.on::before { left: 10px; right: 10px; top: auto; bottom: 2px; width: auto; height: 2px; border-radius: 2px; }
  .side-foot { flex-direction: row; border: 0; padding: 0; margin: 0; align-items: center; }
  .side-foot .nav-item span, .nav-add span { display: none; }
  .me { padding: 0; }
  .view { margin-left: 0; padding: 20px 16px 56px; }
  .verdicts, .field-row { grid-template-columns: minmax(0, 1fr); }
  .login { grid-template-columns: minmax(0, 1fr); }
  .login-pitch { padding: 24px 22px; }
  .pitch-body { padding: 28px 0 20px; }
  .points { display: none; }
  .add-action { flex-direction: column; }
}
@media (max-width: 520px) {
  .tile-value { font-size: 25px; }
  .page-title h1 { font-size: 23px; }
  .page-tools { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
