:root {
  --bg: #f7f9fc; --card: #fff; --text: #141a22; --muted: #6b7684; --line: #e1e8ef; --soft: #eef3f8;
  --accent: #3a9de0; --accent-dark: #1f74b4; --accent-soft: #e8f4fd; --accent-text: #fff;
  --ok: #17803d; --ok-bg: #e5f5ea; --warn: #9a5b00; --warn-bg: #fff2dc; --bad: #b42318; --bad-bg: #fdecea;
  --info: #1d5fbf; --info-bg: #e7effb; --side: 236px; --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font: 15px/1.45 -apple-system, "Segoe UI", Roboto, Arial, sans-serif; background: var(--bg); color: var(--text); }
a { color: var(--accent-dark); }
svg.i { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.demo { background: #ffe08a; color: #4a3500; text-align: center; padding: 6px 16px; font-weight: 600; font-size: 14px; }

/* каркас */
.shell { display: flex; min-height: 100vh; }
.side { width: var(--side); background: var(--card); border-right: 1px solid var(--line); padding: 14px 10px; position: sticky; top: 0; height: 100vh; overflow-y: auto; flex: none; }
.brand { font-weight: 700; font-size: 17px; padding: 4px 10px 12px; display: flex; align-items: center; gap: 8px; }
.brand b { color: var(--accent); }
.scope { margin: 0 6px 12px; }
.scope select { width: 100%; }
.nav-group { margin-top: 12px; }
.nav-group > summary { list-style: none; cursor: pointer; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 4px 10px; }
.nav-group > summary::-webkit-details-marker { display: none; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.nav a:hover { background: var(--soft); }
.nav a.on { background: var(--accent-soft); color: var(--accent-dark); font-weight: 600; }
.nav a .soon { margin-left: auto; font-size: 11px; color: var(--muted); white-space: nowrap; padding-left: 6px; }
.mainwrap { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 12px; padding: 10px 20px; background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.top form.search { flex: 1; max-width: 460px; display: flex; align-items: center; gap: 6px; background: var(--soft); border-radius: 8px; padding: 0 10px; }
.top form.search input { border: 0; background: transparent; flex: 1; padding: 9px 0; font-size: 15px; outline: none; }
.top .bell { position: relative; color: var(--text); display: flex; padding: 6px; border-radius: 8px; }
.top .bell:hover { background: var(--soft); }
.top .bell .n { position: absolute; top: -2px; right: -4px; background: var(--bad); color: #fff; border-radius: 999px; font-size: 11px; padding: 0 5px; min-width: 18px; text-align: center; }
.top .who { color: var(--muted); font-size: 14px; margin-left: auto; white-space: nowrap; }
.menu-toggle { display: none; }
main { padding: 20px; max-width: 1240px; width: 100%; }
h1 { font-size: 23px; margin: 2px 0 14px; }
h2 { font-size: 18px; margin: 22px 0 10px; }
h3 { font-size: 16px; margin: 0 0 8px; }

/* элементы */
.flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 12px; border: 1px solid transparent; }
.flash.ok { background: var(--ok-bg); border-color: #bfe3cb; } .flash.err { background: var(--bad-bg); border-color: #f3c2bd; }
.flash.warn { background: var(--warn-bg); border-color: #f1d6a8; } .flash.info { background: var(--info-bg); border-color: #c7d9f3; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px; }
.muted { color: var(--muted); } .small { font-size: 13px; } .nowrap { white-space: nowrap; }
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid transparent; border-radius: 8px; padding: 9px 15px; font-size: 15px; cursor: pointer; background: var(--accent); color: var(--accent-text); text-decoration: none; min-height: 40px; }
.btn:hover { background: var(--accent-dark); }
.btn.big { padding: 12px 20px; font-size: 17px; min-height: 48px; }
.btn.light { background: var(--card); color: var(--text); border-color: var(--line); }
.btn.light:hover { background: var(--soft); }
.btn.bad { background: var(--bad); }
.btn.small { padding: 5px 10px; min-height: 32px; font-size: 14px; }
.btn:disabled { opacity: .5; cursor: default; }
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 12.5px; background: var(--soft); color: var(--text); white-space: nowrap; }
.badge.ok { background: var(--ok-bg); color: var(--ok); } .badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.bad { background: var(--bad-bg); color: var(--bad); } .badge.info { background: var(--info-bg); color: var(--info); }
.badge.ok::before { content: "✓"; } .badge.bad::before { content: "!"; font-weight: 700; } .badge.warn::before { content: "•"; }
.metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin-bottom: 14px; }
.metric { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.metric .v { font-size: 26px; font-weight: 700; line-height: 1.2; }
.metric .l { color: var(--muted); font-size: 13px; }
.metric.na .v { font-size: 15px; font-weight: 600; color: var(--muted); padding: 6px 0; }
.tasks { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.task { display: flex; flex-direction: column; gap: 6px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px; text-decoration: none; color: var(--text); min-height: 130px; }
.task:hover { border-color: var(--accent); }
.task b { font-size: 17px; display: flex; align-items: center; gap: 8px; }
.task.off { opacity: .75; } .task.off:hover { border-color: var(--line); }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 14px; overflow-x: auto; }
.tabs a { padding: 9px 14px; text-decoration: none; color: var(--muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs a.on { color: var(--accent-dark); border-color: var(--accent); font-weight: 600; }
.filters { display: flex; gap: 14px; flex-wrap: wrap; align-items: flex-end; }
.filters label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.checks { display: flex; gap: 10px; flex-wrap: wrap; }
.checks label { flex-direction: row; align-items: center; gap: 6px; color: var(--text); font-size: 15px; }
input[type=number], input[type=text], input[type=password], input[type=date], input[type=url], input[type=search], select, textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; min-height: 40px; }
input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--accent); }
.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 12px; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
th { font-size: 12.5px; color: var(--muted); font-weight: 600; background: #fafbfa; position: sticky; top: 0; }
td.num, th.num { text-align: right; }
tr.urgent td { background: #fffaf0; }
.pin { position: sticky; left: 0; background: inherit; }
.photo { width: 44px; height: 44px; border-radius: 6px; object-fit: cover; background: var(--soft); display: inline-flex; align-items: center; justify-content: center; color: #9aa59f; flex: none; }
.prod { display: flex; gap: 10px; align-items: center; min-width: 220px; }
.prod b { display: block; }
details.drawer > summary { cursor: pointer; color: var(--accent-dark); font-size: 13px; list-style: none; }
details.drawer > summary::-webkit-details-marker { display: none; }
details.drawer[open] > summary { margin-bottom: 6px; }
.toolbar { position: sticky; bottom: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; box-shadow: 0 -4px 14px rgba(0,0,0,.06); z-index: 4; }
.toolbar .count { font-weight: 600; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
form.inline { display: inline; }
.empty { text-align: center; padding: 28px 16px; color: var(--muted); }
.steps { display: flex; gap: 6px; flex-wrap: wrap; margin: 8px 0 14px; }
.steps span { padding: 4px 10px; border-radius: 999px; background: var(--soft); color: var(--muted); font-size: 13px; }
.steps span.done { background: var(--ok-bg); color: var(--ok); } .steps span.now { background: var(--accent); color: #fff; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

@media (max-width: 1024px) { .grid2 { grid-template-columns: 1fr; } }
@media (max-width: 860px) {
  .side { position: fixed; left: 0; top: 0; z-index: 20; transform: translateX(-100%); transition: transform .2s; }
  #menu:checked ~ .shell .side { transform: none; box-shadow: 4px 0 20px rgba(0,0,0,.12); }
  .menu-toggle { display: inline-flex; padding: 6px; border-radius: 8px; cursor: pointer; }
  .top { padding: 8px 12px; gap: 8px; }
  .top .who { display: none; }
  main { padding: 14px 12px; }
}
@media print { .side, .top, .noprint, .demo, .toolbar { display: none !important; } body { background: #fff; } .card, .table-wrap { border: 0; } main { padding: 0; } }
.pagehead { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.pagehead h1 { margin: 0; }

/* FBS: границы выборки и три разных счета */
.scopebar { display: flex; gap: 12px 20px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.scope-items { display: flex; gap: 6px 18px; flex-wrap: wrap; font-size: 14px; }
.scope-items .muted { font-size: 12.5px; margin-right: 4px; }
.countgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.countcol { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px 0; }
.countcol.plan { border-style: dashed; background: #fbfcfb; }
.countcol .metrics { grid-template-columns: repeat(3, 1fr); }
.countcol .metric { border-color: var(--soft); }
.equation { margin: 8px 2px 14px; }
@media (max-width: 1100px) { .countgrid { grid-template-columns: 1fr; } }

/* FBO: мастер поставки */
.wizard { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 6px 0 4px; }
.wstep { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); background: var(--card); border-radius: var(--radius); font: inherit; color: var(--muted); cursor: pointer; text-align: left; }
.wstep .n { width: 26px; height: 26px; border-radius: 50%; background: var(--soft); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex: none; }
.wstep.done .n { background: var(--ok-bg); color: var(--ok); }
.wstep.now { border-color: var(--accent); color: var(--text); font-weight: 600; box-shadow: 0 0 0 2px var(--accent-soft); }
.wstep.now .n { background: var(--accent); color: #fff; }
.ozon-steps { margin: 6px 2px 12px; }
.problems summary { cursor: pointer; }
.problems ul { margin: 8px 0 0; }
.grow { flex: 1; min-width: 200px; }
.filters label.grow input, .filters label.grow select { width: 100%; }
.filters label.inline { flex-direction: row; align-items: center; gap: 6px; color: var(--text); font-size: 14px; }
label.block { display: block; margin-top: 10px; } label.block input { width: 100%; }
.pick { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.scanrow { display: flex; align-items: center; gap: 8px; border: 2px solid var(--accent); border-radius: 10px; padding: 0 12px; background: #fff; }
.scanrow input { border: 0; flex: 1; font-size: 17px; padding: 11px 0; outline: none; min-height: 46px; }
.results { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; margin: 10px 0; max-height: 470px; overflow-y: auto; }
.rcard { display: flex; gap: 10px; align-items: center; text-align: left; font: inherit; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px; cursor: pointer; color: var(--text); }
.rcard:hover { border-color: var(--accent); }
.rcard.in { background: var(--accent-soft); border-color: #b5d9f2; }
.rtext { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.rtext b, .rtext .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rtext .small { color: var(--muted); }
.radd { font-size: 12.5px; color: var(--accent-dark); white-space: nowrap; }
.photo.ph { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.catalog-line { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
details.manual { margin-top: 10px; } details.manual summary { cursor: pointer; color: var(--accent-dark); font-size: 14px; margin-bottom: 8px; }
.srow, .prow, .bline { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.srow:last-child, .prow:last-child, .bline:last-child { border-bottom: 0; }
.stepper { display: inline-flex; align-items: center; gap: 4px; }
.stepper .btn { min-width: 34px; justify-content: center; }
input.qty { width: 74px; text-align: right; }
.boxes-layout { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 12px; align-items: start; }
.boxes-title { margin: 4px 0 8px; }
.prow { flex-wrap: wrap; }
.prow .fill { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; width: 100%; padding-left: 54px; }
.prow .fill label { flex-direction: row; display: flex; align-items: center; gap: 4px; }
.prow.done .rtext b:first-child { color: var(--muted); }
.left { color: var(--warn); } .overtext { color: var(--bad); } .oktext { color: var(--ok); }
#add-mixed { margin-top: 10px; }
.boxcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; margin-bottom: 10px; }
.boxcard.mixed { border-left: 4px solid var(--info); }
.bhead { display: flex; gap: 8px 10px; align-items: center; flex-wrap: wrap; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.bhead .copies { margin-left: auto; }
.badd { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding-top: 8px; }
.badd select { flex: 1; min-width: 180px; }
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choice label { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 10px; padding: 12px; cursor: pointer; }
.choice label span { display: flex; flex-direction: column; gap: 2px; }
.choice label:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.save-profile { margin-top: 10px; }
ul.docs { list-style: none; padding: 0; margin: 0; }
ul.docs li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
ul.docs li:last-child { border-bottom: 0; }
ul.docs li > span:first-child { display: flex; flex-direction: column; }
ul.docs li.off { opacity: .7; }
.wbar { justify-content: space-between; margin-top: 12px; }
.totals { display: flex; gap: 6px 16px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.totals b { color: var(--text); font-size: 16px; }
.totals .left b { color: var(--warn); } .totals .over b { color: var(--bad); }
.cancel-form { margin-top: 16px; }
@media (max-width: 1100px) { .pick, .boxes-layout { grid-template-columns: 1fr; } }
@media (max-width: 700px) { .wizard { grid-template-columns: 1fr 1fr; } .choice { grid-template-columns: 1fr; } }

[hidden] { display: none !important; }

/* FBO: маршрут */
.choice.three { grid-template-columns: repeat(3, 1fr); }
.choice label.off { opacity: .65; }
.choice label .btn { margin-top: 6px; align-self: flex-start; }
.picked { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; background: var(--accent-soft); border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; }
.points { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; margin-top: 8px; }
.pcard { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; text-align: left; font: inherit; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px; cursor: pointer; }
.pcard:hover { border-color: var(--accent); } .pcard.on { border-color: var(--accent); background: var(--accent-soft); }
.slotday { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px solid var(--line); }
.slotday b { min-width: 96px; }
.routesum { border-left: 4px solid var(--accent); }
.routesum p { margin: 4px 0; }
@media (max-width: 1100px) { .choice.three { grid-template-columns: 1fr; } }

/* FBS: очередь дня */
.metrics.four, .countcol .metrics.four { grid-template-columns: repeat(4, 1fr); }
table.queue tr.deliver td { background: #f7fafe; }
.plist { display: flex; flex-direction: column; gap: 6px; min-width: 320px; }
.prow2 { display: flex; gap: 8px; align-items: flex-start; }
.prow2.off { opacity: .6; }
.qbar .defer { display: inline-flex; gap: 6px; align-items: center; margin-left: auto; }
@media (max-width: 1280px) { .metrics.four, .countcol .metrics.four { grid-template-columns: repeat(2, 1fr); } }

/* Закупки */
.buyrow { display: flex; flex-direction: column; gap: 8px; }
.bstat { display: flex; gap: 6px 14px; flex-wrap: wrap; align-items: center; }
table.mini { width: 100%; border-collapse: collapse; } table.mini td { padding: 6px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.pthumb { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; margin-right: 4px; }
input.comment { width: 180px; }

/* Данные Ozon */
table.datagrid td.cell, table.datagrid th { text-align: center; padding: 6px 4px; }
table.datagrid .badge { font-size: 11.5px; padding: 1px 6px; }

/* FBO: что дальше */
.nextbox { border-left: 4px solid var(--accent); }
.nexthead { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.nexthead b { font-size: 17px; }
.nextlists { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 10px; }
ol.todo { margin: 4px 0 0; padding-left: 20px; font-size: 14px; }
ol.todo li { margin: 3px 0; } ol.todo li.ok { color: var(--muted); } ol.todo li.ok::marker { content: "✓  "; color: var(--ok); }
.permission { margin: 10px 0 0; padding: 8px 10px; background: var(--warn-bg); border-radius: 8px; }
.flashfocus { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; transition: outline-color .6s; }
@media (max-width: 900px) { .nextlists { grid-template-columns: 1fr; } }

/* Мой бизнес */
.bizgrid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 12px; align-items: start; }
.bignum { font-size: 38px; font-weight: 700; color: var(--accent-dark); line-height: 1.15; margin: 4px 0 8px; }
.bignum.neg, .dv.neg { color: var(--bad); }
table.breakdown td { padding: 4px 0; border-bottom: 1px dashed var(--line); } table.breakdown tr.total td { border-bottom: 0; padding-top: 8px; }
.side3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 6px; } .side3 .v { font-size: 20px; font-weight: 700; }
svg.trend { width: 100%; height: 130px; } svg.trend .bpos { fill: var(--accent); } svg.trend .bneg { fill: var(--bad); }
svg.trend .bpre { opacity: .45; } svg.trend text { font-size: 10px; fill: var(--muted); } svg.trend .zero { stroke: var(--line); }
.calhead { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; } .calhead a { text-decoration: none; font-weight: 700; }
table.cal { table-layout: fixed; } table.cal td { height: 74px; vertical-align: top; padding: 4px; border: 1px solid var(--line); }
table.cal td.out { background: var(--soft); } table.cal td.sel { outline: 2px solid var(--accent); outline-offset: -2px; }
table.cal a { display: flex; flex-direction: column; gap: 2px; color: var(--text); text-decoration: none; height: 100%; }
.dn { font-size: 12px; color: var(--muted); } .dv { font-weight: 700; font-size: 14px; } .ds { font-size: 11px; color: var(--muted); }
.prob { display: flex; gap: 10px; justify-content: space-between; align-items: center; padding: 8px 0 8px 10px; border-bottom: 1px solid var(--line); border-left: 3px solid var(--line); font-size: 14px; }
.prob.bad { border-left-color: var(--bad); } .prob.warn { border-left-color: var(--warn); } .prob.info { border-left-color: var(--info); }
.trace { padding: 4px 0; border-bottom: 1px dashed var(--line); }
@media (max-width: 1100px) { .bizgrid { grid-template-columns: 1fr; } .side3 { grid-template-columns: 1fr 1fr 1fr; } }


/* ---------- стиль в духе Yoolip, основной цвет — светло-голубой ---------- */
body { font-family: Inter, -apple-system, "SF Pro Text", "Segoe UI", Roboto, Arial, sans-serif; }
.side { padding: 16px 12px; }
.brand { font-size: 19px; letter-spacing: -.01em; }
.brand b { display: inline-flex; width: 26px; height: 26px; border-radius: 8px; background: var(--accent); color: #fff; align-items: center; justify-content: center; font-size: 14px; }
.nav-group > summary { font-size: 11px; font-weight: 600; letter-spacing: .08em; padding: 10px 10px 4px; }
.nav a { padding: 7px 10px; font-size: 14.5px; }
.nav a.on { background: var(--accent-soft); color: var(--accent-dark); }
.nav a.on svg.i { color: var(--accent); }
.top { border-bottom-color: transparent; background: var(--bg); }
main { padding: 18px 24px; }
h1 { font-size: 25px; letter-spacing: -.015em; }
.card, .table-wrap, .metric { border-color: #e6ebf1; }
.btn { border-radius: 10px; }
.btn.light { border-color: #dfe6ee; }
th { background: #fafcfe; font-weight: 500; text-transform: uppercase; font-size: 11.5px; letter-spacing: .03em; }

/* Чипы периода и фильтров */
.chips { display: inline-flex; gap: 4px; flex-wrap: wrap; align-items: center; }
.chips a, .chips button { padding: 6px 12px; border-radius: 9px; font-size: 13.5px; color: var(--text); text-decoration: none; border: 1px solid transparent; background: transparent; cursor: pointer; font: inherit; }
.chips a:hover, .chips button:hover { background: var(--soft); }
.chips a.on, .chips button.on { background: var(--accent-soft); color: var(--accent-dark); font-weight: 600; }
.chips .cnt { color: var(--muted); font-weight: 400; margin-left: 2px; }
.seg { display: inline-flex; background: var(--soft); border-radius: 10px; padding: 3px; gap: 2px; }
.seg a { padding: 6px 12px; border-radius: 8px; text-decoration: none; color: var(--muted); font-size: 13.5px; }
.seg a.on { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgba(20,30,50,.08); }
.datebox { display: inline-flex; align-items: center; gap: 6px; border: 1px solid #dfe6ee; border-radius: 10px; padding: 6px 10px; font-size: 13.5px; background: #fff; }

/* KPI-карточки */
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; margin-bottom: 14px; }
.kpi { background: #fff; border: 1px solid #e6ebf1; border-radius: var(--radius); padding: 14px 16px 10px; display: flex; flex-direction: column; gap: 4px; min-height: 128px; position: relative; text-decoration: none; color: inherit; }
.kpi .lbl { color: var(--muted); font-size: 13px; display: flex; gap: 6px; align-items: center; }
.kpi .val { font-size: 26px; font-weight: 700; letter-spacing: -.01em; line-height: 1.2; }
.kpi .val.neg { color: var(--bad); }
.kpi .sub { color: var(--muted); font-size: 12.5px; }
.kpi .spark { width: 100%; height: 34px; margin-top: auto; }
.kpi .spark path.area { fill: var(--accent-soft); } .kpi .spark path.line { fill: none; stroke: var(--accent); stroke-width: 1.6; }
.delta { font-size: 12.5px; font-weight: 600; } .delta.up { color: var(--ok); } .delta.down { color: var(--bad); } .delta.flat { color: var(--muted); }
.kpi.hl { border-left: 4px solid var(--accent); }

/* Цветные «таблетки» в таблицах */
.pill { display: inline-block; padding: 2px 9px; border-radius: 8px; font-weight: 600; font-size: 13px; white-space: nowrap; background: var(--soft); }
.pill.ok { background: #e6f6ec; color: #14803c; } .pill.warn { background: #fff4de; color: #9a5b00; } .pill.bad { background: #fde9e7; color: #b42318; }
.pill.info { background: var(--accent-soft); color: var(--accent-dark); } .pill.big { font-size: 22px; padding: 4px 12px; }

/* «Куда уходит каждый рубль» */
.bar100 { display: flex; height: 12px; border-radius: 8px; overflow: hidden; background: var(--soft); margin: 8px 0; }
.bar100 span { display: block; height: 100%; }
.legend { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 4px 16px; font-size: 13px; }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; vertical-align: middle; }
.c1 { background: #8fb9da; } .c2 { background: #3a9de0; } .c3 { background: #7fd1c4; } .c4 { background: #f2b866; } .c5 { background: #c9a3e8; } .c6 { background: #4cbf7a; } .c7 { background: #f08a7e; }

/* Рекомендации «в первую очередь» */
.firstrow { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.firstcard { display: flex; gap: 10px; align-items: center; border: 1px solid #e6ebf1; border-radius: 12px; padding: 10px; background: #fff; }
.firstcard .rt { flex: 1; min-width: 0; } .firstcard .rt b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Карточка товара */
.prodhead { display: flex; gap: 16px; align-items: center; }
.prodhead h1 { margin: 0 0 4px; font-size: 21px; }
.bigphoto { width: 84px; height: 84px; border-radius: 12px; object-fit: cover; flex: none; }
.pulse td, .pulse th { padding: 6px 8px; font-size: 13.5px; } .pulse td:first-child { white-space: nowrap; color: var(--muted); }
.pulse tr.grp td { background: #fafcfe; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; }
.note { background: var(--accent-soft); border-radius: 6px; padding: 2px 6px; margin: 2px 0; font-size: 12px; }

.entry2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.entry2 .val { font-size: 20px; }
@media (max-width: 900px) { .entry2 { grid-template-columns: 1fr; } }
.watch { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.watch h4 { margin: 0 0 6px; font-size: 15px; }
.bad { color: var(--bad); }

/* ---------- каркас как в Yoolip: магазин, группы, пользователь внизу ---------- */
:root { --side: 248px; }
.side { display: flex; flex-direction: column; gap: 2px; padding: 16px 12px 12px; border-right-color: #eaeef3; }
.brand { text-decoration: none; color: var(--text); padding: 2px 6px 14px; gap: 10px; font-size: 20px; font-weight: 700; }
.brand b { width: 32px; height: 32px; border-radius: 9px; }
.brand b svg.i { width: 18px; height: 18px; color: #fff; }
.shopcard { position: relative; display: flex; align-items: center; gap: 10px; border: 1px solid #e6ebf1; border-radius: 14px; padding: 10px 12px; margin: 0 0 10px; background: #fff; box-shadow: 0 1px 2px rgba(20,30,50,.04); }
.shopcard .dot { width: 18px; height: 18px; border-radius: 50%; border: 4px solid var(--accent); flex: none; }
.shopcard .sc-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.shopcard .sc-txt b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 15px; }
.shopcard .sc-txt span { color: var(--muted); font-size: 12.5px; }
.shopcard svg.i { color: var(--muted); }
.shopcard .sc-pick { position: absolute; inset: 0; margin: 0; }
.shopcard .sc-pick select { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.sidesearch { display: flex; align-items: center; gap: 6px; background: var(--soft); border-radius: 10px; padding: 0 10px; margin-bottom: 6px; color: var(--muted); }
.sidesearch input { border: 0; background: transparent; flex: 1; padding: 8px 0; min-height: 34px; font-size: 13.5px; outline: none; min-width: 0; }
.nav-group { margin-top: 6px; }
.nav-group > summary { display: flex; justify-content: space-between; align-items: center; color: #8a95a3; }
.nav-group > summary .chev { width: 7px; height: 7px; border-right: 1.5px solid #a3adb9; border-bottom: 1.5px solid #a3adb9; transform: rotate(45deg); margin-right: 4px; }
.nav-group:not([open]) > summary .chev { transform: rotate(-45deg); }
.nav a { color: #2b3440; border-radius: 10px; }
.nav a svg.i { color: #6b7684; }
.sidefoot { margin-top: auto; display: flex; align-items: center; gap: 8px; padding: 12px 6px 2px; border-top: 1px solid #eef1f5; }
.sidefoot .ava { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; flex: none; }
.sidefoot .who { display: flex; flex-direction: column; flex: 1; min-width: 0; font-size: 13.5px; }
.sidefoot .who span { color: var(--muted); font-size: 12px; }
.sidefoot .bell, .top .bell { position: relative; color: #6b7684; display: inline-flex; padding: 6px; border-radius: 8px; }
.sidefoot .bell:hover { background: var(--soft); }
.sidefoot .bell .n, .top .bell .n { position: absolute; top: -2px; right: -4px; background: var(--bad); color: #fff; border-radius: 999px; font-size: 11px; padding: 0 5px; min-width: 18px; text-align: center; }
.top.mobile-only { display: none; }
main { padding: 22px 28px; max-width: 1320px; }
.pagehead { margin-bottom: 14px; }
.pagehead h1 { font-size: 26px; }
.btn { font-weight: 500; }
.btn svg.i { width: 17px; height: 17px; }
.fresh.ok svg.i { color: var(--accent); }
.fresh.old { color: var(--warn); }
.btn.outline { background: #fff; color: var(--accent-dark); border-color: var(--accent); }
.btn.outline:hover { background: var(--accent-soft); }
@media (max-width: 860px) {
  .top.mobile-only { display: flex; position: sticky; top: 0; background: var(--card); border-bottom: 1px solid var(--line); }
  .top.mobile-only .bell { margin-left: auto; }
  main { padding: 14px 12px; }
}

/* Панель: вкладки слева, горизонт/страховой справа */
.toolrow { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.segb { display: inline-flex; border: 1px solid #dfe6ee; border-radius: 10px; overflow: hidden; background: #fff; }
.segb a, .segb label { padding: 7px 13px; font-size: 13.5px; color: var(--text); text-decoration: none; cursor: pointer; border-right: 1px solid #eef1f5; margin: 0; }
.segb a:last-child, .segb label:last-child { border-right: 0; }
.segb a.on, .segb label.on { background: var(--accent); color: #fff; font-weight: 600; }
.ytable td { padding: 10px; }
.pname { color: var(--text); text-decoration: none; font-weight: 500; display: block; max-width: 420px; }
.pname:hover { color: var(--accent-dark); }
.prod .small { display: block; }

/* Лента событий и задач (История / Поимка слота) */
.feed { padding: 4px 16px; }
.feedrow { display: flex; gap: 12px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid #eef1f5; }
.feedrow:last-child { border-bottom: 0; }
.ficon { width: 30px; height: 30px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: var(--soft); color: #6b7684; flex: none; }
.ficon.ok, .ficon.info { background: var(--accent-soft); color: var(--accent-dark); } .ficon.bad { background: var(--bad-bg); color: var(--bad); }
.ficon svg.i { width: 16px; height: 16px; }
.fbody { flex: 1; min-width: 0; }
.ftitle { font-size: 15px; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 18px; background: #f6f8fb; border-radius: 10px; padding: 8px 12px; margin-top: 8px; font-size: 13px; color: var(--muted); }
.meta span { display: inline-flex; gap: 5px; align-items: center; } .meta b { color: var(--text); font-weight: 600; }
.meta svg.i { width: 14px; height: 14px; }
.fside { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.okmark { color: var(--accent); font-weight: 700; }

/* Модальное окно «Организация поставки» */
.modal-back { position: fixed; inset: 0; background: rgba(15, 25, 40, .45); z-index: 50; display: flex; align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; }
.modal { background: #fff; border-radius: 18px; width: 100%; max-width: 1040px; box-shadow: 0 20px 60px rgba(0,0,0,.25); display: flex; flex-direction: column; max-height: calc(100vh - 80px); }
.modal-head { display: flex; justify-content: space-between; align-items: flex-start; padding: 18px 22px 10px; }
.modal-head h2 { margin: 0 0 2px; font-size: 19px; }
.modal-head .close { color: var(--text); text-decoration: none; font-size: 14px; }
.stepper { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 12px 22px 16px; border-bottom: 1px solid #eef1f5; }
.stepper .st { display: inline-flex; gap: 8px; align-items: center; font-weight: 600; color: var(--muted); }
.stepper .st i { font-style: normal; width: 28px; height: 28px; border-radius: 50%; border: 2px solid #cfd8e2; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }
.stepper .st.now { color: var(--text); } .stepper .st.now i { border-color: var(--accent); color: var(--accent-dark); }
.stepper .st.done { color: var(--text); } .stepper .st.done i { background: var(--accent); border-color: var(--accent); color: #fff; }
.stepper .line { width: 60px; height: 2px; background: #dfe6ee; }
.modal-body { padding: 16px 22px; overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 22px; border-top: 1px solid #eef1f5; }
.clcard { border: 1px solid #e6ebf1; border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.clcard.warnc { border-color: #f1d6a8; background: #fffbf3; }
.clhead { display: flex; justify-content: space-between; gap: 10px; align-items: center; margin-bottom: 8px; }
.chiplist { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 4px; background: #f3f6f9; border-radius: 8px; padding: 4px 8px; font-size: 13px; color: #3b4652; }
.chip input[type=number] { width: 56px; min-height: 26px; padding: 2px 6px; font-size: 13px; }
.chip select { min-height: 26px; padding: 2px 6px; font-size: 13px; }
.pointlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; margin: 8px 0; }
.pointlist .pcard { text-align: left; border: 1px solid #e6ebf1; background: #fff; border-radius: 10px; padding: 8px 10px; cursor: pointer; display: flex; flex-direction: column; font: inherit; }
.pointlist .pcard.on { border-color: var(--accent); background: var(--accent-soft); }
.barrow { position: relative; display: flex; justify-content: space-between; gap: 10px; padding: 7px 8px; font-size: 13.5px; border-radius: 8px; overflow: hidden; }
.barrow span, .barrow b { position: relative; z-index: 1; }
.barrow i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent-soft); border-radius: 8px; }
.ytable td.num, .ytable th.num { white-space: nowrap; }
.ytable td { font-size: 14px; }

/* План продаж, Рука на пульсе, P&L */
.chart { width: 100%; height: auto; display: block; }
.chart text { font-size: 10px; fill: var(--muted); }
.chart line.g { stroke: var(--line); stroke-width: 1; }
.chart path.fact { fill: none; stroke: var(--accent); stroke-width: 2.4; }
.chart path.plan { fill: none; stroke: #9db7d3; stroke-width: 1.6; stroke-dasharray: 5 4; }
.lg { display: inline-block; width: 18px; height: 3px; vertical-align: middle; border-radius: 2px; }
.lg.fact { background: var(--accent); } .lg.plan { background: #9db7d3; }
.ring { width: 92px; height: 92px; }
.ring circle { fill: none; stroke-width: 12; }
.ring .bg { stroke: var(--soft); } .ring .fg { stroke: var(--accent); stroke-linecap: round; }
.ring.ok .fg { stroke: #2b9a57; } .ring.warn .fg { stroke: #e0a020; } .ring.bad .fg { stroke: #d24b3e; }
.ring text { font-size: 22px; font-weight: 700; fill: var(--text); }
.planring { flex-direction: column; }
tr.grp td { background: var(--accent-soft); color: var(--accent-dark); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
tr.strong td { font-weight: 700; }
.up { color: var(--ok); } .down { color: var(--bad); }
.pulse td.stick, .pulse th.stick { position: sticky; left: 0; background: #fff; z-index: 1; min-width: 170px; }
.pulse tr.grp td.stick { background: var(--accent-soft); }
table.pnl td { vertical-align: top; }
a.card.promo { display: block; text-decoration: none; color: inherit; }
a.card.promo:hover { border-color: var(--accent); }
mark { background: #cfe6fb; color: inherit; border-radius: 3px; padding: 0 2px; }
tr.focus td { background: var(--accent-soft); }

/* Простые всплывающие окна (ui.js) */
.modal-back[hidden] { display: none; }
body.modal-open { overflow: hidden; }
.modal.sm { max-width: 440px; margin-top: 12vh; }
.modal.md { max-width: 620px; margin-top: 6vh; }
.btn.danger { background: #d64545; border-color: #d64545; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 8px 6px 12px; border-radius: 999px; background: #eaf3fc; color: #1d5b94; font-weight: 600; font-size: 14px; }
.chip button { border: 0; background: transparent; cursor: pointer; font-size: 16px; line-height: 1; color: inherit; padding: 0 4px; }
.picklist { list-style: none; margin: 8px 0 0; padding: 0; max-height: 46vh; overflow: auto; border: 1px solid #e6ebf1; border-radius: 12px; }
.picklist li { padding: 10px 14px; cursor: pointer; display: flex; justify-content: space-between; border-bottom: 1px solid #f0f3f7; }
.picklist li:last-child { border-bottom: 0; }
.picklist li:hover { background: #f5f9fd; }
.picklist li.on { background: #eaf3fc; font-weight: 600; }
.picklist li.on::after { content: "✓"; color: var(--accent-dark); }
.stepcard { background: #fff; border: 1px solid #e6ebf1; border-radius: 16px; padding: 16px 18px; margin-bottom: 14px; }
.stepcard h3 { margin: 0 0 10px; display: flex; gap: 10px; align-items: center; }
.stepcard h3 i { font-style: normal; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice label { border: 2px solid #e1e8f0; border-radius: 14px; padding: 12px 14px; cursor: pointer; display: block; }
.choice label.on { border-color: var(--accent); background: #f1f8ff; }
.choice b { display: block; margin-bottom: 4px; }
@media (max-width: 700px) { .choice { grid-template-columns: 1fr; } }

/* Выбор слота: календарь и плитки времени */
.modal.slot { max-width: 780px; margin-top: 6vh; }
.slotpick { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; padding: 8px 26px 18px; }
@media (max-width: 720px) { .slotpick { grid-template-columns: 1fr; gap: 16px; } }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; font-size: 20px; }
.cal-head b span { color: var(--muted); font-weight: 500; }
.cal-head button { border: 0; background: transparent; font-size: 26px; line-height: 1; cursor: pointer; color: var(--muted); padding: 2px 10px; border-radius: 8px; }
.cal-head button:hover:not([disabled]) { background: #f0f4f8; color: var(--text); }
.cal-head button[disabled] { opacity: .3; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px 0; text-align: center; }
.cal-grid .wd { color: var(--muted); font-size: 13px; padding: 6px 0 10px; }
.cal-grid .day { border: 0; background: transparent; height: 42px; font-size: 16px; cursor: pointer; color: var(--text); border-radius: 12px; position: relative; font-family: inherit; }
.cal-grid .day.we { color: #e0698f; }
.cal-grid .day[disabled] { color: #c4cbd4; cursor: default; }
.cal-grid .day:hover:not([disabled]) { background: #eef3f9; }
.cal-grid .day.today { box-shadow: inset 0 0 0 2px #cfd8e2; }
.cal-grid .day.in { background: #e3f0fd; border-radius: 0; color: #145a9c; }
.cal-grid .day.in.a { border-radius: 12px 0 0 12px; }
.cal-grid .day.in.b { border-radius: 0 12px 12px 0; }
.cal-grid .day.in.a.b { border-radius: 12px; }
.cal-grid .day.a, .cal-grid .day.b { background: #0b1220; color: #fff; border-radius: 12px; }
.cal-grid .day.a:not(.b) { border-radius: 12px 0 0 12px; }
.cal-grid .day.b:not(.a) { border-radius: 0 12px 12px 0; }
.times-title { margin: 0 0 12px; font-size: 20px; }
.timegroup { margin-bottom: 14px; }
.tg-title { color: var(--text); margin-bottom: 8px; }
.tchips { display: flex; flex-wrap: wrap; gap: 8px; }
.tchip { border: 1px solid #dde4ec; background: #fff; border-radius: 12px; padding: 9px 12px; font-size: 15px; color: #4c5b6b; cursor: pointer; font-family: inherit; }
.tchip:hover { border-color: #9bb6d3; }
.tchip.on { background: #0b1220; border-color: #0b1220; color: #fff; }
.tchip.any { padding: 9px 16px; }
.slotbtn { display: flex; align-items: center; gap: 14px; border: 1px solid #dde4ec; background: #fff; border-radius: 12px; padding: 8px 14px; cursor: pointer; font-family: inherit; font-size: 15px; }
.slotbtn:hover { border-color: #9bb6d3; background: #f7fafd; }
.slotbtn b { font-weight: 600; }
.slotbtn span { color: #4c5b6b; background: #eef3f9; border-radius: 8px; padding: 2px 8px; }
.slotbtn i { font-style: normal; color: var(--accent-dark); font-size: 13px; margin-left: 4px; }

/* Отправка по кластерам: карточка на каждую поставку */
.kidlist { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
.kidcard { display: grid; grid-template-columns: 1.1fr 1.5fr auto; gap: 20px; align-items: center; background: #fff; border: 1px solid #e6ebf1; border-left: 5px solid #cfd8e2; border-radius: 16px; padding: 16px 20px; }
.kidcard.booked { border-left-color: #2fb36d; }
.kidcard.hunting { border-left-color: #3b97e6; }
.kidcard.found { border-left-color: #f0a73a; }
.kidcard.error { border-left-color: #d64545; }
.kid-title { font-size: 19px; font-weight: 700; margin-bottom: 2px; }
.kid-state > * + * { margin-top: 4px; }
.pill.big { font-size: 15px; padding: 5px 12px; }
.kid-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.kid-actions form { margin: 0; }
@media (max-width: 900px) { .kidcard { grid-template-columns: 1fr; gap: 10px; } .kid-actions { justify-content: flex-start; } }

/* Лоток слотов под карточкой кластера */
.kidcard { grid-template-columns: 1.1fr 1.5fr auto; }
.kidcard .tray { grid-column: 1 / -1; border-top: 1px solid #eef1f5; padding-top: 10px; }
.tray > summary { cursor: pointer; list-style: none; padding: 2px 0; }
.tray > summary::-webkit-details-marker { display: none; }
.tray > summary::before { content: "▸"; margin-right: 8px; color: var(--muted); display: inline-block; transition: transform .15s; }
.tray[open] > summary::before { transform: rotate(90deg); }
.tray-body { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; padding: 10px 0 4px; }
@media (max-width: 800px) { .tray-body { grid-template-columns: 1fr; gap: 14px; } }
.tray-title { font-weight: 600; margin-bottom: 8px; }
.tray-day { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 8px; }
.tray-date { min-width: 52px; font-weight: 600; }
.tchip.inside { border-color: #2fb36d; background: #effaf4; color: #1c7a47; }
.tchip.inside:hover { background: #dff5e9; }

.photo.sm { width: 32px; height: 32px; border-radius: 5px; }
.period-label { margin-left: 12px; color: var(--muted); font-size: 14px; }
.period-label b { color: var(--text); }

/* Задачи */
.sub-head { color: var(--muted); margin-top: 2px; } .bad-text { color: var(--bad); font-weight: 600; }
.tasks-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 4px 0 18px; }
.seg .cnt, .tgroup .cnt { margin-left: 6px; font-size: 12px; background: #e6ecf3; color: #51606f; border-radius: 999px; padding: 1px 7px; }
.seg a.on .cnt { background: var(--accent-soft); color: var(--accent-dark); }
.task-search { margin-left: auto; min-width: 240px; border-radius: 10px; }
.tgroup { margin-bottom: 14px; }
.tgroup > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; padding: 6px 4px; font-size: 16px; }
.tgroup > summary::-webkit-details-marker { display: none; }
.tgroup > summary::after { content: "▾"; margin-left: auto; color: var(--muted); transition: transform .15s; }
.tgroup:not([open]) > summary::after { transform: rotate(-90deg); }
.tdot { width: 10px; height: 10px; border-radius: 50%; background: #b8c4d0; display: inline-block; }
.tdot.bad { background: #e5484d; } .tdot.warn { background: #f0a73a; } .tdot.info { background: #3b97e6; }
.tlist { background: #fff; border: 1px solid #e6ebf1; border-radius: 16px; overflow: hidden; box-shadow: 0 1px 2px rgba(20,30,50,.04); }
.trow { display: grid; grid-template-columns: 22px 1fr auto auto; gap: 14px; align-items: center; padding: 12px 16px; border-bottom: 1px solid #f0f3f7; border-left: 4px solid transparent; transition: background .12s; }
.trow:last-child { border-bottom: 0; } .trow:hover { background: #f8fbfe; } .trow.picked { background: #eef6fe; }
.trow.bad { border-left-color: #e5484d; } .trow.warn { border-left-color: #f0a73a; } .trow.info { border-left-color: #3b97e6; }
.tmain { cursor: pointer; min-width: 0; }
.ttitle { font-weight: 600; } .tdetail { color: var(--muted); font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tresult { font-size: 13.5px; color: var(--ok); margin-top: 2px; }
.tmeta { display: flex; gap: 8px; align-items: center; }
.chip-due { font-size: 13px; padding: 3px 10px; border-radius: 999px; background: #eef3f8; color: #51606f; white-space: nowrap; }
.chip-due.late { background: var(--bad-bg); color: var(--bad); font-weight: 600; }
.avatar { width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-dark); font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; justify-content: center; }
.tact { display: flex; gap: 6px; align-items: center; } .icon-btn { padding: 4px 10px; font-size: 16px; line-height: 1; }
.tsel { width: 18px; height: 18px; cursor: pointer; }
@media (max-width: 860px) { .trow { grid-template-columns: 22px 1fr; } .tmeta, .tact { grid-column: 2; } }
.bulkbar { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); background: #0b1220; color: #fff; display: flex; gap: 10px; align-items: center; padding: 10px 16px; border-radius: 16px; box-shadow: 0 12px 40px rgba(0,0,0,.28); z-index: 40; }
.bulkbar[hidden] { display: none; } .bulkbar .btn.light { background: rgba(255,255,255,.12); color: #fff; border-color: transparent; }
.empty-state { text-align: center; padding: 56px 16px; background: #fff; border: 1px dashed #d5dde7; border-radius: 18px; }
.empty-state .big { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; background: var(--ok-bg); color: var(--ok); font-size: 30px; display: flex; align-items: center; justify-content: center; }
.empty-state h3 { margin: 0 0 6px; } .empty-state p { max-width: 460px; margin: 0 auto; }
.field { margin-bottom: 14px; } .field > .flabel { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.field textarea, .field input[type=text], .field input[type=date], .field select { width: 100%; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; } @media (max-width: 600px) { .two { grid-template-columns: 1fr; } }
.quick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; } .quick button { border: 1px solid #dde4ec; background: #fff; border-radius: 999px; padding: 3px 10px; font-size: 12.5px; cursor: pointer; color: #4c5b6b; font-family: inherit; }
.quick button:hover { border-color: #9bb6d3; background: #f7fafd; }
.seg.wide { display: flex; } .seg.wide label { flex: 1; } .seg.wide label span { display: block; text-align: center; padding: 7px 8px; border-radius: 8px; cursor: pointer; color: var(--muted); font-size: 13.5px; }
.seg.wide label.on span { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgba(20,30,50,.08); }

/* Общая полировка: уведомления, отклик кнопок, таблицы, фокус */
.toasts { position: fixed; top: 18px; right: 18px; z-index: 80; display: flex; flex-direction: column; gap: 10px; max-width: min(520px, calc(100vw - 36px)); }
.toast { display: flex; gap: 12px; align-items: flex-start; margin: 0; padding: 12px 14px; border-radius: 14px; box-shadow: 0 10px 32px rgba(20,30,50,.18); background: #fff; animation: toast-in .22s ease; border-width: 1px; }
.toast.ok { background: #effaf4; border-color: #bfe3cb; } .toast.err { background: #fff1f0; border-color: #f3c2bd; }
.toast span { flex: 1; word-break: break-word; } .toast-x { border: 0; background: transparent; font-size: 20px; line-height: 1; cursor: pointer; color: #6b7684; padding: 0 2px; }
.toast.out { opacity: 0; transform: translateY(-8px); transition: all .22s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.btn { transition: background .12s, box-shadow .12s, transform .06s; } .btn:hover { box-shadow: 0 2px 8px rgba(31,116,180,.22); } .btn:active { transform: translateY(1px); }
.btn.light:hover { box-shadow: 0 2px 8px rgba(20,30,50,.10); }
.ytable tr:hover td, .table-wrap table tr:hover td { background: #f8fbfe; }
.card { box-shadow: 0 1px 2px rgba(20,30,50,.04); }
:focus-visible { outline: 3px solid rgba(58,157,224,.45); outline-offset: 2px; border-radius: 8px; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(58,157,224,.18); outline: none; }
textarea { font: inherit; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; background: #fff; }
.pagehead h1 { letter-spacing: -.01em; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* Дашборд */
.dash-hero { display: grid; grid-template-columns: minmax(300px, 1fr) 2fr; gap: 16px; margin-bottom: 16px; }
@media (max-width: 960px) { .dash-hero { grid-template-columns: 1fr; } }
.hero-card { background: linear-gradient(135deg, #0b1220 0%, #16324f 100%); color: #fff; border-radius: 20px; padding: 22px 24px; box-shadow: 0 10px 30px rgba(11,18,32,.22); }
.hero-card.neg { background: linear-gradient(135deg, #3b0d12 0%, #7a1c24 100%); }
.hero-card .lbl { color: rgba(255,255,255,.75); display: flex; gap: 8px; align-items: center; }
.hero-num { font-size: 44px; font-weight: 700; letter-spacing: -.02em; margin: 8px 0 4px; line-height: 1.1; }
.hero-sub { display: flex; gap: 10px; align-items: center; color: rgba(255,255,255,.75); font-size: 14px; }
.hero-card .delta { background: rgba(255,255,255,.14); padding: 2px 9px; border-radius: 999px; font-weight: 600; } .hero-card .delta.up { color: #7cf0b0; } .hero-card .delta.down { color: #ff9a9a; }
.hero-pills { display: flex; gap: 22px; margin-top: 18px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.14); }
.hero-pills div { display: flex; flex-direction: column; gap: 4px; } .hero-pills .small { color: rgba(255,255,255,.6); } .hero-pills b { font-size: 18px; }
.hero-note { margin-top: 14px; font-size: 12.5px; color: #ffd28a; line-height: 1.35; }
.chart-card { background: #fff; border: 1px solid #e6ebf1; border-radius: 20px; padding: 18px 20px; box-shadow: 0 1px 2px rgba(20,30,50,.04); }
.netchart { display: flex; align-items: flex-end; gap: 4px; height: 190px; margin-top: 14px; }
.nc-col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; cursor: pointer; min-width: 0; }
.nc-bar { width: 100%; max-width: 38px; border-radius: 8px 8px 3px 3px; transition: filter .12s, transform .12s; }
.nc-bar.pos { background: linear-gradient(180deg, #3bc57c, #1f9d5c); } .nc-bar.neg { background: linear-gradient(180deg, #ee6a6e, #d64045); }
.nc-bar.pre { opacity: .5; } .nc-col:hover .nc-bar { filter: brightness(1.08); transform: scaleY(1.03); transform-origin: bottom; }
.nc-d { font-size: 11px; color: var(--muted); margin-top: 6px; }
.kpi-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi2 { background: #fff; border: 1px solid #e6ebf1; border-radius: 16px; padding: 14px 16px; box-shadow: 0 1px 2px rgba(20,30,50,.04); display: flex; flex-direction: column; gap: 4px; transition: box-shadow .15s, transform .15s; }
.kpi2:hover { box-shadow: 0 8px 24px rgba(20,30,50,.10); transform: translateY(-1px); }
.kpi2 .lbl { color: var(--muted); font-size: 13px; } .kpi2 .v { font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
.kpi2 .s { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; } .kpi2 svg.spark { height: 30px; width: 100%; margin-top: 4px; }
.bar100.tall { height: 18px; border-radius: 9px; overflow: hidden; }
.cnt { margin-left: 6px; font-size: 12px; background: #e6ecf3; color: #51606f; border-radius: 999px; padding: 1px 8px; vertical-align: middle; }
.aitem { display: grid; grid-template-columns: 12px 1fr auto; gap: 12px; align-items: center; padding: 11px 0; border-bottom: 1px solid #f0f3f7; } .aitem:last-of-type { border-bottom: 0; }
.adot { width: 10px; height: 10px; border-radius: 50%; background: #b8c4d0; } .aitem.bad .adot { background: #e5484d; } .aitem.warn .adot { background: #f0a73a; } .aitem.info .adot { background: #3b97e6; }
.atext { min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 14px; } .atext span { color: var(--muted); }
.allgood { display: flex; gap: 10px; align-items: center; padding: 18px 0; color: var(--ok); font-weight: 600; } .allgood span { width: 28px; height: 28px; border-radius: 50%; background: var(--ok-bg); display: inline-flex; align-items: center; justify-content: center; }
.topitem { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 8px 6px; border-radius: 12px; text-decoration: none; color: inherit; transition: background .12s; } .topitem:hover { background: #f4f8fc; }
.tname { display: flex; flex-direction: column; min-width: 0; } .tname .small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tbar { height: 5px; background: #eef3f8; border-radius: 3px; margin-top: 5px; overflow: hidden; } .tbar i { display: block; height: 100%; background: linear-gradient(90deg, #3a9de0, #5ab4f0); border-radius: 3px; }
.tnum { display: flex; flex-direction: column; text-align: right; white-space: nowrap; }
.calnav { font-size: 24px; text-decoration: none; padding: 0 10px; color: var(--muted); border-radius: 8px; } .calnav:hover { background: #f0f4f8; }
table.cal.heat td { padding: 3px; border-radius: 10px; } table.cal.heat td.today { box-shadow: inset 0 0 0 2px #0b1220; }
table.cal.heat .daybtn { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; min-height: 62px; background: transparent; border: 0; border-radius: 8px; padding: 6px 8px; cursor: pointer; text-align: left; font-family: inherit; color: inherit; transition: background .12s; }
table.cal.heat .daybtn:hover { background: rgba(255,255,255,.55); }
.kpi2 .spark path.area { fill: var(--accent-soft); } .kpi2 .spark path.line { fill: none; stroke: var(--accent); stroke-width: 1.6; }

/* Экономика и реклама */
.kpi-strip.tight { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin: 0; align-content: stretch; }
.custom-period { position: relative; } .custom-period > summary { list-style: none; cursor: pointer; display: inline-block; } .custom-period > summary::-webkit-details-marker { display: none; }
.custom-period[open] form { position: absolute; z-index: 20; top: 38px; left: 0; background: #fff; border: 1px solid #e6ebf1; border-radius: 14px; padding: 14px; box-shadow: 0 12px 32px rgba(20,30,50,.16); min-width: 300px; }
.pill.abc-a { background: #e3f6ea; color: #17803d; } .pill.abc-b { background: #e7effb; color: #1d5fbf; } .pill.abc-c { background: #eef1f4; color: #6b7684; }
.mbar { display: inline-block; width: 54px; height: 6px; background: #eef3f8; border-radius: 3px; margin-right: 8px; vertical-align: middle; overflow: hidden; } .mbar i { display: block; height: 100%; background: #2fb36d; border-radius: 3px; } .mbar.neg i { background: #e5484d; }
table.sticky th { position: sticky; top: 0; background: #f7f9fc; z-index: 2; } th[data-sort] { cursor: pointer; user-select: none; white-space: nowrap; } th[data-sort]:hover { color: var(--text); } th[data-sort].asc::after { content: " ↑"; } th[data-sort].desc::after { content: " ↓"; }
.nirow { display: grid; grid-template-columns: minmax(180px, 1.2fr) 2fr auto; gap: 14px; align-items: center; padding: 8px 0; border-bottom: 1px solid #f0f3f7; } .nirow:last-child { border-bottom: 0; } .nirow .tbar { margin: 0; }
.adscamp td { vertical-align: middle; } .share { display: block; height: 4px; background: #eef3f8; border-radius: 2px; margin-top: 5px; width: 120px; overflow: hidden; } .share i { display: block; height: 100%; background: linear-gradient(90deg, #3a9de0, #5ab4f0); }
.drrbadge { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.nc-bar.ad { background: linear-gradient(180deg, #5ab4f0, #2f86d4); }
.tlist .table-wrap { overflow-x: auto; margin: 0; } .tlist table { min-width: 860px; width: 100%; }

/* Склад: плитки «Сегодня», список поставок */
.today-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; margin-bottom: 8px; }
.ttile { display: flex; flex-direction: column; gap: 10px; background: #fff; border: 1px solid #e6ebf1; border-radius: 20px; padding: 18px 20px; text-decoration: none; color: var(--text); box-shadow: 0 1px 2px rgba(20,30,50,.04); transition: box-shadow .15s, transform .15s, border-color .15s; min-height: 150px; }
.ttile:hover { box-shadow: 0 10px 28px rgba(20,30,50,.12); transform: translateY(-2px); border-color: #cfe0f1; }
.ttile.main { background: linear-gradient(135deg, #0b1220 0%, #16324f 100%); color: #fff; border-color: transparent; }
.ttile.main .tt-sub { color: rgba(255,255,255,.7); } .ttile.main .tt-ic { background: rgba(255,255,255,.14); color: #fff; }
.tt-head { display: flex; align-items: center; gap: 12px; font-size: 18px; }
.tt-ic { width: 40px; height: 40px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-dark); display: inline-flex; align-items: center; justify-content: center; flex: none; } .tt-ic svg.i { width: 20px; height: 20px; }
.tt-sub { color: var(--muted); font-size: 14px; } .tt-pills { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }
.sec-title { margin: 26px 0 10px; font-size: 18px; }
.todo-row { display: grid; grid-template-columns: 12px 1fr auto; gap: 14px; align-items: center; padding: 14px 18px; border-bottom: 1px solid #f0f3f7; text-decoration: none; color: inherit; transition: background .12s; } .todo-row:last-child { border-bottom: 0; } a.todo-row:hover { background: #f8fbfe; }
.entry2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; margin-bottom: 18px; }
.entry-card { display: flex; gap: 14px; align-items: flex-start; background: #fff; border: 1px solid #e6ebf1; border-radius: 18px; padding: 16px 18px; text-decoration: none; color: var(--text); transition: box-shadow .15s, transform .15s; } .entry-card:hover { box-shadow: 0 8px 24px rgba(20,30,50,.10); transform: translateY(-1px); }
.kidcard.cancelled { opacity: .6; } .kidcard.split { border-left-color: #8b95a1; }

/* FBS: вкладки, показатели, панели, таблицы, пачки */
.tabs { display: inline-flex; gap: 2px; background: var(--soft); border-radius: 12px; padding: 4px; border-bottom: 0; margin-bottom: 16px; max-width: 100%; overflow-x: auto; }
.tabs a { padding: 8px 16px; border-radius: 9px; border-bottom: 0; color: var(--muted); font-size: 14px; transition: background .12s, color .12s; }
.tabs a:hover { color: var(--text); } .tabs a.on { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(20,30,50,.10); border-color: transparent; }
.metric { border-radius: 16px; padding: 14px 16px; box-shadow: 0 1px 2px rgba(20,30,50,.04); border-color: #e6ebf1; transition: box-shadow .15s; } a.metric:hover { box-shadow: 0 8px 22px rgba(20,30,50,.10); }
.metric .v { font-size: 28px; letter-spacing: -.01em; }
.countcol { border-radius: 20px; padding: 16px 18px 4px; box-shadow: 0 1px 2px rgba(20,30,50,.04); border-color: #e6ebf1; } .countcol.plan { background: #f9fbfd; border-style: dashed; }
.countcol h3 { margin: 0 0 12px; } .countcol .metric { background: #fff; border-color: #edf1f5; }
.scopebar { border-radius: 16px; background: #fff; border-color: #e6ebf1; }
.card.filters, form.card.filters { border-radius: 16px; border-color: #e6ebf1; }
.table-wrap { border-radius: 18px; border-color: #e6ebf1; box-shadow: 0 1px 2px rgba(20,30,50,.04); }
.table-wrap table th { background: #f7f9fc; color: #5a6877; font-weight: 600; font-size: 13px; letter-spacing: .01em; }
.table-wrap table tr:hover td { background: #f8fbfe; }
.qbar, .toolbar { position: sticky; bottom: 14px; z-index: 30; background: #0b1220; color: #fff; border: 0; border-radius: 16px; padding: 12px 18px; box-shadow: 0 12px 36px rgba(0,0,0,.28); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.qbar .muted, .toolbar .muted, .qbar label, .toolbar label { color: rgba(255,255,255,.75); } .qbar select, .toolbar select { background: #fff; color: var(--text); }
.qbar .btn.light, .toolbar .btn.light { background: rgba(255,255,255,.12); color: #fff; border-color: transparent; }
.brow { display: grid; grid-template-columns: 1.2fr .8fr auto 1fr auto; gap: 16px; align-items: center; padding: 14px 18px; border-bottom: 1px solid #f0f3f7; border-left: 4px solid transparent; transition: background .12s; }
.brow:last-child { border-bottom: 0; } .brow:hover { background: #f8fbfe; } .brow.bad { border-left-color: #e5484d; } .brow.warn { border-left-color: #f0a73a; } .brow.info { border-left-color: #3b97e6; } .brow.ok { border-left-color: #2fb36d; }
.b-title { font-weight: 700; font-size: 16px; text-decoration: none; } .b-who { display: flex; gap: 8px; align-items: center; }
@media (max-width: 860px) { .brow { grid-template-columns: 1fr; gap: 6px; } }

/* P&L, ДДС, товары, цены */
table.first-sticky td:first-child, table.first-sticky th:first-child { position: sticky; left: 0; background: #fff; z-index: 3; box-shadow: 1px 0 0 #eef1f5; min-width: 180px; }
table.first-sticky th:first-child { background: #f7f9fc; z-index: 4; }
table.pnl tr.grp td { background: #f3f6fa; font-weight: 700; color: #51606f; font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; }
table.pnl tr.strong td { background: #fafcfe; font-weight: 700; } td.neg-cell { color: var(--bad); }
.amount-in { color: #1c8a4e; font-weight: 600; } .amount-out { color: #c0392b; font-weight: 600; } .amount-tr { color: #51606f; font-weight: 600; }
.acc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-bottom: 18px; }
.acc-card { background: #fff; border: 1px solid #e6ebf1; border-radius: 18px; padding: 16px 18px; box-shadow: 0 1px 2px rgba(20,30,50,.04); display: flex; flex-direction: column; gap: 4px; }
.acc-card .an { font-weight: 600; } .acc-card .ab { font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
.chips-listing { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; } .chip-l { display: inline-flex; gap: 6px; align-items: center; background: #f1f5f9; border-radius: 10px; padding: 3px 10px; font-size: 13px; }
.chip-l b { font-weight: 600; } .chip-l .muted { font-size: 12px; }
.pairrow { display: grid; grid-template-columns: 1fr auto 1fr auto; gap: 16px; align-items: center; padding: 14px 18px; border-bottom: 1px solid #f0f3f7; } .pairrow:last-child { border-bottom: 0; }
.prow { display: grid; grid-template-columns: minmax(220px, 1fr) 2fr; gap: 18px; align-items: center; padding: 12px 18px; border-bottom: 1px solid #f0f3f7; } .prow:last-child { border-bottom: 0; } .prow:hover { background: #f8fbfe; }
@media (max-width: 900px) { .pairrow, .prow { grid-template-columns: 1fr; gap: 8px; } }
.wf { display: grid; grid-template-columns: minmax(180px, 1.3fr) 2fr auto; gap: 14px; align-items: center; padding: 8px 0; border-bottom: 1px solid #f0f3f7; } .wf:last-child { border-bottom: 0; } .wf.total { font-weight: 700; border-top: 2px solid #e1e8ef; padding-top: 12px; }
.wfbar { height: 8px; border-radius: 4px; background: #eef3f8; overflow: hidden; } .wfbar i { display: block; height: 100%; background: #3a9de0; border-radius: 4px; } .wfbar.neg i { background: #e5484d; } .wfbar.pos i { background: #2fb36d; }
.oprow { display: grid; grid-template-columns: 64px 1fr auto auto; gap: 16px; align-items: center; padding: 12px 18px; border-bottom: 1px solid #f0f3f7; transition: background .12s; } .oprow:last-child { border-bottom: 0; } .oprow:hover { background: #f8fbfe; }
.opdate { display: flex; flex-direction: column; font-weight: 700; line-height: 1.1; } .opdate i { font-style: normal; font-weight: 400; font-size: 11.5px; color: var(--muted); }
.oprow form { margin: 0; } .ozonline { margin-top: 14px; padding-top: 12px; border-top: 1px solid #eef1f5; font-size: 13.5px; }
.waterfall .wf { grid-template-columns: minmax(200px, 1.6fr) 1.2fr auto; }
/* тот же вид карточки для больших таблиц аналитики */
.table-wrap:has(> table.ytable) { background: #fff; border: 1px solid #e6ebf1; border-radius: 16px; box-shadow: 0 1px 2px rgba(20,30,50,.04); overflow-x: auto; }
.table-wrap:has(> table.ytable) .ytable th { background: #f6f8fb; }
.chart-card details.card, details.card { border-radius: 16px; }
a.card.promo { border-radius: 16px; display: block; text-decoration: none; color: inherit; transition: box-shadow .15s, transform .15s; }
a.card.promo:hover { box-shadow: 0 8px 24px rgba(20,30,50,.10); transform: translateY(-1px); }
/* Рука на пульсе: цветные полосы блоков, стрелки и подсветка относительно вчера */
.pulse2 .obj { position: sticky; left: 0; z-index: 2; background: #fff; min-width: 190px; max-width: 220px; vertical-align: top; white-space: normal; padding: 10px 12px; color: var(--text); border-right: 1px solid #e6ebf1; }
.pulse2 th.obj { background: #f6f8fb; }
.pulse2 .stick { left: 190px; z-index: 1; } .pulse2 th.stick { z-index: 3; }
.pulse2 .sigma { position: sticky; left: 370px; background: #fff; z-index: 1; border-right: 2px solid #1f2a37; }
.pulse2 th.sigma { background: #1f2a37; color: #fff; }
.pulse2 tr.grp td.mt { font-weight: 700; letter-spacing: .04em; font-size: 11.5px; text-transform: uppercase; }
.pulse2 tr.g-rev td:not(.obj), .pulse2 tr.g-rev-r td.stick { background: #e9f7ef; } .pulse2 tr.g-rev td.mt { color: #1d7a45; }
.pulse2 tr.g-ads td:not(.obj) { background: #e8f0fd; } .pulse2 tr.g-ads td.mt { color: #1f5fbf; }
.pulse2 tr.g-mar td:not(.obj) { background: #fdf3d6; } .pulse2 tr.g-mar td.mt { color: #9a6a00; }
.pulse2 tr.g-fun td:not(.obj) { background: #f1eafc; } .pulse2 tr.g-fun td.mt { color: #6b3fb5; }
.pulse2 tr.g-stk td:not(.obj) { background: #e6f3fb; } .pulse2 tr.g-stk td.mt { color: #1b6c99; }
.pulse2 td.t-up { background: #e4f6ea !important; } .pulse2 td.t-dn { background: #fde8e8 !important; }
.pulse2 .ar { font-size: 11px; margin-right: 3px; color: var(--muted); } .pulse2 .ar.up { color: #1d9a57; } .pulse2 .ar.down { color: #d64545; }
.pulse2 tbody.pblock { border-top: 3px solid #cfd8e2; }
.pulse2 .sigma b { font-weight: 700; }
.pulse2 td.obj { white-space: normal !important; overflow-wrap: anywhere; width: 190px; min-width: 190px; max-width: 190px; }
.pulse2 table.ytable th.sigma { background: #1f2a37; color: #fff; }
.pulse2 td.obj a { text-transform: none; letter-spacing: 0; }
/* Экономика товаров: строка итогов, группы колонок как у Dropzon */
.sumline { display: flex; flex-wrap: wrap; gap: 8px 22px; background: #fff; border: 1px solid #e6ebf1; border-radius: 14px; padding: 12px 18px; font-size: 14px; color: var(--muted); }
.sumline b { color: var(--text); font-weight: 700; margin-left: 4px; }
.grp-chips .chip { border: 1px solid #d8e0ea; background: #fff; border-radius: 999px; padding: 3px 12px; font-size: 12.5px; cursor: pointer; margin-left: 4px; color: var(--muted); }
.grp-chips .chip.on { background: var(--accent-soft); color: var(--accent-dark); border-color: transparent; font-weight: 600; }
table.goods tr.gh th { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; text-align: center; }
table.goods .g-ord { background-color: rgba(59,151,230,.06); } table.goods .g-sold { background-color: rgba(47,179,109,.06); }
table.goods .g-ads { background-color: rgba(240,167,58,.07); } table.goods .g-fee { background-color: rgba(214,69,69,.05); } table.goods .g-res { background-color: rgba(107,63,181,.06); }
table.goods tr.gh th.g-ord { color: #1f5fbf; } table.goods tr.gh th.g-sold { color: #1d7a45; } table.goods tr.gh th.g-ads { color: #9a6a00; } table.goods tr.gh th.g-fee { color: #b13030; } table.goods tr.gh th.g-res { color: #6b3fb5; }

/* Параметры расчёта */
.pgroup { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 18px 0 8px; }
.pgroup:first-of-type { margin-top: 4px; }
.pgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.pfield { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--muted); }
.pfield input, .pfield select { height: 40px; padding: 0 12px; border: 1px solid var(--line, #e3e8ef); border-radius: 10px; background: #fff; font-size: 15px; color: var(--text, #111); width: 100%; box-sizing: border-box; }
.pfield input:focus, .pfield select:focus { outline: 2px solid #bcd9ff; border-color: #6aa9f5; }
.pfield small { font-size: 12px; color: var(--muted); }
.pauto { background: #eef6ff; border-radius: 12px; padding: 10px 14px; font-size: 13px; display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
@media (max-width: 640px) { .pgrid { grid-template-columns: 1fr; } }
/* Позиции и карточки */
svg.spark { color: #2f7be5; display: block; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; }
@media (max-width: 900px) { .grid3 { grid-template-columns: 1fr; } }
.neg { color: #c0392b; } .pos { color: #1c8c4e; }

tr.colhide { display: none; }
tr.colfilter th { padding: 3px 6px; background: transparent; } tr.colfilter input { width: 100%; min-width: 52px; box-sizing: border-box; font-size: 12px; padding: 4px 8px; border: 1px solid #d9e1ec; border-radius: 8px; background: #fff; font-weight: 400; }
th.asc::after { content: " ▲"; font-size: 10px; } th.desc::after { content: " ▼"; font-size: 10px; }
.colcount { padding: 6px 4px; }
