/* ДОБЫЧА — рабочий инструмент: тёплая бумага, графитовая панель, один сигнальный цвет.
   Плотные таблицы, моноширинные цифры, никакого «нейронского» глянца. */
:root {
  --bg: #f3f0e8;
  --bg-2: #ebe7dc;
  --panel: #fbfaf6;
  --ink: #16150f;
  --ink-2: #4b483e;
  --ink-3: #8b8778;
  --line: #ddd8ca;
  --line-2: #cbc5b4;
  --side: #17160f;
  --side-2: #22211a;
  --side-ink: #e9e4d4;
  --side-dim: #8f8a78;
  --acc: #ff4b12;
  --acc-ink: #ffffff;
  --acc-soft: #ffe3d7;
  --go: #12805a;
  --go-soft: #d9f0e5;
  --warn: #b26b00;
  --warn-soft: #f8ead0;
  --bad: #c23a22;
  --info: #2f5bd3;
  --info-soft: #e1e8fb;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --sans: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 6px;
  --shadow: 0 1px 0 rgba(22, 21, 15, .04), 0 8px 24px -12px rgba(22, 21, 15, .18);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12110d; --bg-2: #191812; --panel: #1d1c16; --ink: #eee9da; --ink-2: #bcb6a4; --ink-3: #7f7a69;
    --line: #2e2c24; --line-2: #3b392f; --side: #0c0b08; --side-2: #18170f; --acc-soft: #3a1c10; --go-soft: #12301f;
    --warn-soft: #36290f; --info-soft: #182444; --shadow: 0 8px 24px -12px rgba(0, 0, 0, .6);
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 14.5px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--acc); color: #fff; }
.mono, .num { font-family: var(--mono); font-feature-settings: "tnum"; }

/* ============ каркас ============ */
.shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; background: linear-gradient(to right, var(--side) 232px, transparent 232px); }
.side { background: var(--side); color: var(--side-ink); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.logo { display: flex; align-items: center; gap: 10px; padding: 20px 20px 18px; font: 700 15px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; }
.logo-mark { width: 22px; height: 22px; background: var(--acc); position: relative; flex: none; }
.logo-mark::after { content: ""; position: absolute; inset: 6px; border: 2px solid var(--side); border-radius: 50%; }
.nav { padding: 6px 10px; display: flex; flex-direction: column; gap: 1px; }
.nav-sec { font: 600 10px/1 var(--mono); color: var(--side-dim); letter-spacing: .14em; text-transform: uppercase; padding: 16px 10px 6px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r); text-decoration: none; color: #cfc9b6; font-weight: 500; }
.nav a:hover { background: var(--side-2); color: #fff; }
.nav a.on { background: var(--side-2); color: #fff; box-shadow: inset 2px 0 0 var(--acc); }
.nav svg { width: 17px; height: 17px; flex: none; opacity: .85; }
.nav .badge { margin-left: auto; font: 600 11px/1 var(--mono); background: var(--acc); color: #fff; padding: 3px 6px; border-radius: 99px; }
.nav .badge.dim { background: #3a382e; color: #d6d0bd; }
.side-foot { margin-top: auto; padding: 14px 16px; border-top: 1px solid #2a2920; font-size: 13px; }
.side-foot .who { font-weight: 600; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-foot .mail { color: var(--side-dim); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-foot a { color: var(--side-dim); font-size: 12px; text-decoration: none; }
.side-foot a:hover { color: #fff; }
.pulse { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #3bd17f; margin-right: 6px; box-shadow: 0 0 0 0 rgba(59, 209, 127, .6); animation: pulse 2.2s infinite; }
.pulse.off { background: #6b675a; animation: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 7px rgba(59, 209, 127, 0); } 100% { box-shadow: 0 0 0 0 rgba(59, 209, 127, 0); } }

.main { min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 16px; padding: 14px 28px; border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 20; }
.top h1 { font: 700 20px/1.2 var(--sans); margin: 0; letter-spacing: -.01em; }
.top .crumbs { font: 500 12px var(--mono); color: var(--ink-3); }
.top .grow { flex: 1; }
.kbd-search { display: flex; align-items: center; gap: 10px; width: 300px; padding: 7px 10px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--panel); color: var(--ink-3); cursor: pointer; font-size: 13px; }
.kbd-search kbd { margin-left: auto; font: 500 11px var(--mono); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 5px; }
.content { padding: 24px 28px 60px; max-width: 1440px; width: 100%; }
.content.wide { max-width: none; }

/* ============ элементы ============ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid var(--line-2); background: var(--panel); padding: 7px 12px; border-radius: var(--r); cursor: pointer; font-weight: 600; font-size: 13px; text-decoration: none; white-space: nowrap; transition: background .12s, border-color .12s; }
.btn:hover { border-color: var(--ink); }
.btn.pri { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.pri:hover { background: #000; }
.btn.acc { background: var(--acc); color: var(--acc-ink); border-color: var(--acc); }
.btn.acc:hover { filter: brightness(.94); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
.btn.ghost:hover { background: var(--bg-2); }
.btn.sm { padding: 4px 9px; font-size: 12px; }
.btn.danger { color: var(--bad); }
.btn[disabled], .btn.busy { opacity: .55; pointer-events: none; }
.btn svg { width: 15px; height: 15px; }
.btns { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }

.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; }
.field > label, .lbl { font: 600 11px/1.2 var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); }
.field .hint { font-size: 12px; color: var(--ink-3); }
.inp, input[type=text], input[type=email], input[type=password], input[type=number], input[type=url], select, textarea {
  width: 100%; border: 1px solid var(--line-2); background: var(--panel); border-radius: var(--r); padding: 8px 10px; outline: none; transition: border-color .12s, box-shadow .12s;
}
.inp:focus, input:focus, select:focus, textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(255, 75, 18, .15); }
textarea { resize: vertical; line-height: 1.5; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.row3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.check { display: flex; align-items: center; gap: 8px; cursor: pointer; user-select: none; }
.check input { width: 16px; height: 16px; accent-color: var(--acc); }
.switch { position: relative; width: 34px; height: 20px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: var(--line-2); border-radius: 99px; cursor: pointer; transition: .15s; }
.switch span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 14px; height: 14px; background: #fff; border-radius: 50%; transition: .15s; }
.switch input:checked + span { background: var(--acc); }
.switch input:checked + span::after { transform: translateX(14px); }

.card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; }
.card-h { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.card-h h3 { margin: 0; font: 600 12px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.card-h .more { margin-left: auto; font-size: 12.5px; color: var(--ink-3); text-decoration: none; }
.card-h .more:hover { color: var(--ink); }
.card-b { padding: 16px; }
.empty { padding: 26px 16px; text-align: center; color: var(--ink-3); font-size: 13px; }
.empty b { display: block; color: var(--ink-2); font-size: 14px; margin-bottom: 4px; }

.pill { display: inline-flex; align-items: center; gap: 5px; font: 600 11px/1 var(--mono); padding: 4px 7px; border-radius: 99px; background: var(--bg-2); color: var(--ink-2); white-space: nowrap; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .7; }
.pill.plain::before { display: none; }
.pill.acc { background: var(--acc-soft); color: var(--acc); }
.pill.go { background: var(--go-soft); color: var(--go); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.info { background: var(--info-soft); color: var(--info); }
.pill.bad { background: var(--acc-soft); color: var(--bad); }
.tag { font: 500 11px/1 var(--mono); border: 1px solid var(--line-2); padding: 3px 6px; border-radius: 4px; color: var(--ink-2); white-space: nowrap; }

.score { display: inline-grid; place-items: center; width: 38px; height: 26px; border-radius: 5px; font: 700 13px var(--mono); background: var(--bg-2); color: var(--ink-2); flex: none; }
.score.s85 { background: var(--acc); color: #fff; }
.score.s70 { background: var(--ink); color: var(--bg); }
.score.s50 { background: var(--line-2); color: var(--ink); }

/* ============ KPI ============ */
.kpis { display: grid; grid-template-columns: repeat(6, 1fr); border: 1px solid var(--line); border-radius: 8px; background: var(--panel); overflow: hidden; }
.kpi { padding: 14px 16px; border-right: 1px solid var(--line); text-decoration: none; display: block; }
.kpi:last-child { border-right: 0; }
.kpi:hover { background: var(--bg-2); }
.kpi .v { font: 600 26px/1.1 var(--mono); letter-spacing: -.02em; }
.kpi .l { font: 500 11px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .07em; color: var(--ink-3); margin-top: 4px; }
.kpi.hot .v { color: var(--acc); }

.grid-2 { display: grid; grid-template-columns: 1.35fr 1fr; gap: 18px; margin-top: 18px; }
.grid-eq { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.stack { display: flex; flex-direction: column; gap: 18px; }

/* ============ списки ============ */
.list { display: flex; flex-direction: column; }
.li { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; border-bottom: 1px solid var(--line); text-decoration: none; }
.li:last-child { border-bottom: 0; }
.li:hover { background: var(--bg); }
.li .t { font-weight: 600; line-height: 1.3; }
.li .s { color: var(--ink-2); font-size: 13px; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.li .m { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 6px; font-size: 12px; color: var(--ink-3); }
.li .grow { flex: 1; min-width: 0; }
.li .side-acts { display: flex; gap: 6px; align-items: center; flex: none; }

/* ============ таблица ============ */
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font: 600 10.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); padding: 10px 12px; border-bottom: 1px solid var(--line-2); background: var(--panel); position: sticky; top: 0; z-index: 1; white-space: nowrap; }
.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:hover td { background: var(--bg); }
.tbl td.n { font-family: var(--mono); text-align: right; white-space: nowrap; }
.tbl th.n { text-align: right; }
.tbl .t { font-weight: 600; }
.tbl .s { color: var(--ink-3); font-size: 12px; }
.tbl tr.on td { background: var(--acc-soft); }
.tbl input[type=checkbox] { accent-color: var(--acc); width: 15px; height: 15px; }

/* ============ вкладки и фильтры ============ */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; scrollbar-width: none; }
.tabs a { white-space: nowrap; }
.tabs a { padding: 9px 14px; text-decoration: none; color: var(--ink-3); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; display: flex; gap: 7px; align-items: center; }
.tabs a:hover { color: var(--ink); }
.tabs a.on { color: var(--ink); border-color: var(--acc); }
.tabs a .c { font: 600 11px var(--mono); color: var(--ink-3); background: var(--bg-2); padding: 2px 6px; border-radius: 99px; }
.filters { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.filters select, .filters input { width: auto; padding: 6px 9px; font-size: 13px; }
.filters input[type=search] { width: 240px; }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--r); overflow: hidden; background: var(--panel); }
.seg a { padding: 6px 11px; text-decoration: none; font-size: 13px; font-weight: 600; color: var(--ink-3); border-right: 1px solid var(--line); }
.seg a:last-child { border-right: 0; }
.seg a.on { background: var(--ink); color: var(--bg); }

/* ============ Радар: список + панель ============ */
.split { display: grid; grid-template-columns: minmax(380px, 1fr) minmax(460px, 1.15fr); gap: 0; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); overflow: hidden; height: calc(100vh - 210px); min-height: 520px; }
.split .pane { overflow-y: auto; }
.split .pane + .pane { border-left: 1px solid var(--line); }
.rrow { display: grid; grid-template-columns: 38px 1fr; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); cursor: pointer; text-decoration: none; }
.rrow:hover { background: var(--bg); }
.rrow.on { background: var(--acc-soft); box-shadow: inset 3px 0 0 var(--acc); }
.rrow .t { font-weight: 600; line-height: 1.3; }
.rrow .s { color: var(--ink-2); font-size: 13px; margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rrow .m { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 7px; font-size: 12px; color: var(--ink-3); }
.panel-in { padding: 22px 24px 40px; }
.panel-in h2 { font: 700 22px/1.2 var(--sans); margin: 8px 0 8px; letter-spacing: -.01em; }
.facts { display: grid; grid-template-columns: 120px 1fr; border-top: 1px solid var(--line); margin: 16px 0; }
.facts dt, .facts dd { margin: 0; padding: 8px 0; border-bottom: 1px solid var(--line); }
.facts dt { font: 500 11px/1.7 var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); }
.why { margin: 0; padding: 0; list-style: none; }
.why li { padding: 3px 0 3px 18px; position: relative; }
.why li::before { content: "→"; position: absolute; left: 0; color: var(--ink-3); font-family: var(--mono); }
.flag { color: var(--bad); }
.quote { white-space: pre-wrap; font-size: 13.5px; border-left: 3px solid var(--line-2); padding: 4px 0 4px 14px; color: var(--ink-2); overflow-wrap: anywhere; }
.sec-t { font: 600 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--ink-3); margin: 22px 0 8px; display: flex; align-items: center; gap: 8px; }
.sec-t::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.stage-bar { display: flex; gap: 4px; flex-wrap: wrap; }
.stage-bar button { border: 1px solid var(--line-2); background: var(--panel); border-radius: 99px; padding: 5px 11px; font-size: 12.5px; cursor: pointer; font-weight: 500; }
.stage-bar button:hover { border-color: var(--ink); }
.stage-bar button.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.timeline { list-style: none; margin: 0; padding: 0; font-size: 12.5px; }
.timeline li { display: flex; gap: 10px; padding: 5px 0; border-bottom: 1px dashed var(--line); }
.timeline time { font-family: var(--mono); color: var(--ink-3); width: 54px; flex: none; }

/* ============ Канбан ============ */
.board { display: grid; grid-template-columns: repeat(6, minmax(230px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.col { background: var(--bg-2); border-radius: 8px; display: flex; flex-direction: column; min-height: 60vh; }
.col-h { padding: 12px 12px 8px; display: flex; align-items: baseline; gap: 8px; }
.col-h b { font: 600 12px var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.col-h .n { font: 500 12px var(--mono); color: var(--ink-3); }
.col-h .sum { margin-left: auto; font: 600 12px var(--mono); color: var(--ink-2); }
.col-b { padding: 4px 8px 10px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.col.drop { outline: 2px dashed var(--acc); outline-offset: -4px; }
.kcard { background: var(--panel); border: 1px solid var(--line); border-radius: 7px; padding: 10px 11px; cursor: grab; text-decoration: none; display: block; box-shadow: var(--shadow); }
.kcard:hover { border-color: var(--ink-3); }
.kcard.dragging { opacity: .4; }
.kcard .t { font-weight: 600; font-size: 13.5px; line-height: 1.3; overflow-wrap: anywhere; }
.kcard .s { color: var(--ink-3); font-size: 12px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kcard .f { display: flex; gap: 6px; align-items: center; margin-top: 8px; font-size: 11.5px; }
.kcard .f .amt { margin-left: auto; font: 600 12px var(--mono); }

/* ============ Продукты ============ */
.offers { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 14px; }
.offer { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.offer h3 { margin: 0; font-size: 17px; }
.offer .sum { color: var(--ink-2); font-size: 13.5px; }
.offer .stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); padding-top: 10px; margin-top: auto; }
.offer .stats div { text-align: center; }
.offer .stats b { font: 600 18px var(--mono); display: block; }
.offer .stats span { font: 500 10px var(--mono); text-transform: uppercase; color: var(--ink-3); letter-spacing: .06em; }
.offer.add { border-style: dashed; align-items: center; justify-content: center; min-height: 180px; cursor: pointer; color: var(--ink-3); font-weight: 600; }
.offer.add:hover { color: var(--ink); border-color: var(--ink-3); }

/* ============ модалка, тост, палитра ============ */
.modal-bg { position: fixed; inset: 0; background: rgba(15, 14, 10, .45); z-index: 60; display: none; align-items: flex-start; justify-content: center; padding: 6vh 16px; overflow-y: auto; }
.modal-bg.on { display: flex; }
.modal { background: var(--panel); border-radius: 10px; width: min(720px, 100%); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .5); }
.modal-h { display: flex; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-h h3 { margin: 0; font-size: 17px; }
.modal-h .x { margin-left: auto; }
.modal-b { padding: 18px 20px; }
.modal-f { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%) translateY(20px); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 8px; font-size: 13.5px; opacity: 0; transition: .2s; z-index: 90; pointer-events: none; max-width: 90vw; }
.toast.on { opacity: 1; transform: translateX(-50%); }
.toast.err { background: var(--bad); color: #fff; }
.palette { width: min(620px, 100%); }
.palette input { border: 0; border-bottom: 1px solid var(--line); border-radius: 10px 10px 0 0; padding: 16px 18px; font-size: 16px; box-shadow: none !important; }
.palette .res a { display: block; padding: 10px 18px; text-decoration: none; border-bottom: 1px solid var(--line); }
.palette .res a:hover, .palette .res a.on { background: var(--acc-soft); }
.palette .res small { display: block; color: var(--ink-3); font-size: 12px; }

/* ============ разное ============ */
.setup { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-bottom: 18px; }
.setup a { border: 1px dashed var(--line-2); border-radius: 8px; padding: 10px 12px; text-decoration: none; font-size: 13px; display: flex; gap: 8px; align-items: center; }
.setup a.done { border-style: solid; color: var(--ink-3); }
.setup a.done::before { content: "✓"; color: var(--go); font-weight: 700; }
.setup a:not(.done)::before { content: "○"; color: var(--acc); font-weight: 700; }
.chart { display: flex; align-items: flex-end; gap: 5px; height: 150px; border-bottom: 1px solid var(--line-2); padding-top: 10px; }
.chart .d { flex: 1; display: flex; gap: 2px; align-items: flex-end; height: 100%; }
.chart .d i { flex: 1; display: block; min-height: 1px; border-radius: 2px 2px 0 0; background: var(--line-2); }
.chart .d i.c { background: var(--ink); }
.chart .d i.r { background: var(--acc); }
.chart-x { display: flex; gap: 5px; font: 10px var(--mono); color: var(--ink-3); margin-top: 5px; }
.chart-x span { flex: 1; text-align: center; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--ink-2); margin-top: 10px; }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.msg { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; background: var(--panel); }
.msg.in { background: var(--info-soft); border-color: transparent; }
.msg .h { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--ink-3); margin-bottom: 6px; }
.msg .subj { font-weight: 600; margin-bottom: 4px; }
.msg .body { white-space: pre-wrap; font-size: 13.5px; }
.note-box { background: var(--warn-soft); color: var(--ink); border-radius: 8px; padding: 12px 14px; font-size: 13.5px; }
.note-box.info { background: var(--info-soft); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); border-radius: 99px; padding: 4px 10px; font-size: 12.5px; background: var(--panel); }
.chip button { border: 0; background: none; cursor: pointer; color: var(--ink-3); padding: 0; }
.muted { color: var(--ink-3); }
.small { font-size: 12.5px; }
.hide { display: none !important; }
.right { margin-left: auto; }
.mt { margin-top: 18px; }
.gap { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ============ вход / онбординг ============ */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.auth-l { background: var(--side); color: var(--side-ink); padding: 48px; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.auth-l .logo { padding: 0; color: #fff; }
.auth-l h2 { font: 700 44px/1.05 var(--sans); letter-spacing: -.03em; margin: auto 0 18px; max-width: 520px; color: #fff; }
.auth-l h2 em { font-style: normal; color: var(--acc); }
.auth-l p { color: #b8b29f; max-width: 460px; font-size: 15.5px; }
.auth-l .feed { position: absolute; right: -40px; top: 120px; width: 300px; display: flex; flex-direction: column; gap: 10px; opacity: .55; transform: rotate(-4deg); }
.auth-l .feed div { background: var(--side-2); border: 1px solid #2f2d24; border-radius: 8px; padding: 10px 12px; font-size: 12.5px; color: #d9d3c1; }
.auth-l .feed b { color: var(--acc); font-family: var(--mono); margin-right: 6px; }
.auth-l ul { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 8px; color: #d6d0bd; font-size: 14px; }
.auth-l li::before { content: "■ "; color: var(--acc); }
.auth-r { display: grid; place-items: center; padding: 40px 24px; }
.auth-form { width: min(380px, 100%); }
.auth-form h1 { font: 700 26px/1.2 var(--sans); margin: 0 0 6px; letter-spacing: -.01em; }
.auth-form .sub { color: var(--ink-3); margin-bottom: 24px; }
.err { color: var(--bad); font-size: 13px; min-height: 18px; margin: -4px 0 10px; }
.wizard { max-width: 860px; margin: 0 auto; padding: 36px 24px 80px; }
.steps { display: flex; gap: 6px; margin-bottom: 28px; }
.steps div { flex: 1; height: 4px; border-radius: 2px; background: var(--line); }
.steps div.on { background: var(--acc); }
.step h2 { font: 700 28px/1.15 var(--sans); letter-spacing: -.02em; margin: 0 0 6px; }
.step .lead { color: var(--ink-2); font-size: 15.5px; margin: 0 0 22px; }
.offer-edit { border: 1px solid var(--line); border-radius: 8px; padding: 14px; background: var(--panel); margin-bottom: 10px; }

@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(3, 1fr); }
  .kpi:nth-child(3) { border-right: 0; }
  .grid-2, .grid-eq { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; height: auto; }
  .split .pane + .pane { border-left: 0; border-top: 1px solid var(--line); }
  .setup { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .shell { grid-template-columns: 1fr; background: none; }
  .filters input[type=search] { width: 100%; }
  .filters select { max-width: 100%; }
  .board { grid-template-columns: repeat(6, 82vw); }
  .grid-2 { grid-template-columns: 1fr !important; }
  .side { position: static; height: auto; }
  .nav { flex-direction: row; flex-wrap: wrap; }
  .nav-sec, .side-foot { display: none; }
  .content { padding: 18px 14px 50px; }
  .top { padding: 12px 14px; }
  .kbd-search { display: none; }
  .auth { grid-template-columns: 1fr; }
  .auth-l { padding: 28px; min-height: 260px; }
  .auth-l h2 { font-size: 30px; margin-top: 30px; }
  .auth-l .feed { display: none; }
  .row2, .row3 { grid-template-columns: 1fr; }
}

/* Радар: разделы, справка, карточки */
.gtabs { display: flex; gap: 8px; overflow-x: auto; margin: 0 0 14px; padding-bottom: 2px; }
.gtabs a { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--panel); text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: 14px; white-space: nowrap; }
.gtabs a b { font: 600 12px var(--mono); background: var(--bg); border-radius: 5px; padding: 2px 7px; color: var(--ink-3); }
.gtabs a.on { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.gtabs a.on b { background: var(--acc); color: #fff; }
.gtabs a.zero { opacity: .5; }
.help { display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 18px; align-items: start; padding: 14px 16px; margin-bottom: 14px; border: 1px solid var(--line); border-left: 3px solid var(--acc); border-radius: 8px; background: var(--panel); }
.help b { display: block; font-size: 13.5px; margin-bottom: 3px; }
.help span { color: var(--ink-3); font-size: 13px; line-height: 1.45; }
.deck { max-width: 920px; margin: 0 auto; }
.deck-bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; padding: 10px 12px; margin-bottom: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow); }
.deck-bar .btns { display: flex; gap: 8px; margin-left: auto; }
.deck-card { border: 1px solid var(--line); border-radius: 8px; background: var(--panel); min-height: 300px; }
@media (max-width: 760px) {
  .help { grid-template-columns: 1fr; }
  .deck-bar { flex-wrap: wrap; }
  .deck-bar .btns { width: 100%; margin-left: 0; }
  .deck-bar .btns .btn { flex: 1; }
}
.rtool { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.rtool .lbl { font: 600 11px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.rtool .seg a { white-space: nowrap; }
.flcats { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.flsec + .flsec { border-top: 1px solid var(--line); }
.flsec summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 12px; cursor: pointer; list-style: none; }
.flsec summary::-webkit-details-marker { display: none; }
.flsec summary:hover { background: var(--bg-2); }
.flsec[open] summary { background: var(--bg-2); }
.flsubs { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 6px 14px; padding: 10px 14px 14px 34px; }
.flsubs .check { font-size: 13px; }
