/* Спільні компоненти застосунку й планшета (public/kiosk.html). Вигляд застосунку — поверх цього, public/v8.css; нічну тему планшет тримає в public/kiosk.css. */
:root {
  --bg: #f3f5f8;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --ink: #0f1822;
  --ink-2: #485564;
  --ink-3: #616e7d;
  --line: #dfe5ec;
  --axis: #c3ccd7;
  --accent: #2a78d6;
  --accent-wash: rgba(42, 120, 214, .10);
  --accent-strong: #1f66c1;
  --band: rgba(42, 120, 214, .17);
  --track: #cde2fb;
  --plan: #5d6875;
  --gold: #8c640c;
  --good: #0ca30c;
  --bad: #d03b3b;
  --warn: #fab219;
  --alert: #e8710a;
  --alert-ink: #2b1500;
  --focus: #2a78d6;
  --shadow: 0 1px 2px rgba(15, 24, 34, .05);
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: var(--font);              /* один шрифт для всього (рішення 18.10.2026) */
  --on-accent: #fff;                   /* текст на акцентному тлі */
  --on-status: #fff;                   /* значки на зеленому/червоному тлі */
}

* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.45; }
.wrap { max-width: 1180px; margin: 0 auto; padding-inline: clamp(16px, 3vw, 28px); padding-block: 20px 48px; display: flex; flex-direction: column; gap: 16px; }
.wrap[hidden] { display: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
h1, h2 { margin: 0; text-wrap: balance; }
button, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 6px; }

/* header */
.top { position: relative; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.brand { display: grid; grid-template-columns: auto auto minmax(0, 1fr); grid-template-areas: "logo logo logo" "title tools ."; align-items: center; gap: 10px 6px; min-width: 0; }
.logo { grid-area: logo; display: block; height: 20px; width: 90px; color: var(--ink); }
.hdr-tools { grid-area: tools; display: inline-flex; align-items: center; gap: 2px; }
/* «i» — стан даних; «new» — сповіщення з лічильником, як непрочитані в месенджері */
.info-btn, .new-btn { background: none; border: 0; padding: 0; margin: 0; min-width: 36px; height: 36px; display: inline-grid; place-items: center; cursor: pointer; color: inherit; font: inherit; border-radius: 999px; }
.info-btn .ib { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--axis); color: var(--ink-2); display: grid; place-items: center; font-size: 13px; font-weight: 800; line-height: 1; transition: border-color .15s, color .15s; }
.info-btn:hover .ib, .info-btn[aria-expanded="true"] .ib { border-color: var(--ink-2); color: var(--ink); }
.info-btn.is-busy .ib { border-color: var(--accent); color: var(--accent); animation: ib-pulse 1.2s ease-in-out infinite; }
@keyframes ib-pulse { 50% { box-shadow: 0 0 0 4px var(--accent-wash); } }
.new-btn[hidden] { display: none; }
.new-btn .nb { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 3px 0 10px; border-radius: 999px; font-size: 12px; font-weight: 800; letter-spacing: .02em; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2); transition: background-color .15s, color .15s; }
.new-btn .nb-cnt { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; display: grid; place-items: center; font-size: 11px; font-variant-numeric: tabular-nums; background: var(--axis); color: var(--ink); }
.new-btn.unseen .nb { background: var(--accent-strong); border-color: var(--accent-strong); color: var(--on-accent); }
.new-btn.unseen .nb-cnt { background: var(--on-accent); color: var(--accent-strong); }
.new-btn.unseen.lvl-warn .nb-cnt { background: var(--alert); color: var(--alert-ink); }
.new-btn.unseen.lvl-error .nb-cnt { background: var(--bad); color: var(--on-status); }
.pop, .nt-panel { position: absolute; z-index: 20; background: var(--surface); border: 1px solid var(--axis); box-shadow: 0 10px 28px rgba(8, 14, 22, .18); animation: pop-in .14s ease-out; }
.pop[hidden], .nt-panel[hidden] { display: none; }
@keyframes pop-in { from { opacity: 0; transform: translateY(-4px); } }
.pop { border-radius: 10px; padding: 9px 12px; width: max-content; max-width: min(340px, 100%); }
.pop .status { color: var(--ink); }
.nt-panel { border-radius: 12px; width: min(460px, 100%); max-height: min(72vh, 560px); overflow-y: auto; overscroll-behavior: contain; }
.nt-head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 6px 4px 16px; background: var(--surface); border-bottom: 1px solid var(--line); }
.nt-head h2 { font-size: 15px; }
.nt-x { width: 36px; height: 36px; border: 0; background: none; border-radius: 50%; cursor: pointer; color: var(--ink-2); font-size: 18px; line-height: 1; }
.nt-x:hover { background: var(--surface-2); color: var(--ink); }
.nt-list { display: flex; flex-direction: column; padding: 4px 8px 8px; }
.nt-item { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 10px; padding: 10px 8px; border-radius: 8px; font-size: 14px; }
.nt-item + .nt-item { margin-top: 2px; }
.nt-item.fresh { background: var(--accent-wash); }
/* закрите хрестиком — сіреньким і внизу (Микола, 26.10.2026) */
.nt-item.read { color: var(--ink-3); }
.nt-item.read .nt-ico { opacity: .55; }
.nt-ico { width: 18px; height: 18px; margin-top: 1px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 800; line-height: 1; color: var(--on-status); }
.nt-ico.info { background: var(--accent-strong); }
.nt-ico.error { background: var(--bad); }
.nt-body { min-width: 0; }
.nt-body p { margin: 0; }
.nt-body p + p, .nt-body p + .btn { margin-top: 6px; }
.nt-body ul { margin: 6px 0; padding-left: 18px; }
.nt-body li { margin-bottom: 3px; }
.nt-body b { font-weight: 700; }
.sr-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
h1 { font-size: clamp(22px, 3.2vw, 28px); font-weight: 800; letter-spacing: -.01em; }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.month { display: flex; align-items: center; gap: 4px; }
.btn, .icon-btn, select { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; min-height: 38px; }
.btn { padding: 0 14px; font-weight: 600; cursor: pointer; }
.icon-btn { width: 38px; font-size: 20px; line-height: 1; cursor: pointer; }
.btn:hover, .icon-btn:hover { border-color: var(--axis); background: var(--surface-2); }
.btn[disabled], .icon-btn[disabled] { opacity: .45; cursor: default; }
select { padding: 0 10px; font-weight: 600; }
.status { margin: 0; color: var(--ink-2); font-size: 13px; }

/* banners */
#banners { display: flex; flex-direction: column; gap: 8px; }
#banners:empty { display: none; }
.banner { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--warn); border-radius: 8px; padding: 10px 14px; display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; font-size: 14px; }
.banner.err { border-left-color: var(--bad); }
.banner b { font-weight: 700; }
.banner p { margin: 0; flex: 1 1 280px; min-width: 0; }
.banner.miss { border-left-color: var(--alert); flex-wrap: nowrap; align-items: flex-start; gap: 12px; }
.banner .body { flex: 1 1 auto; min-width: 0; }
.banner .body p { flex: none; }
.banner ul { margin: 6px 0; padding-left: 18px; }
.banner li { margin-bottom: 3px; }
.tri { flex: none; display: inline-block; }
.banner .tri { margin-top: 1px; }

/* summary */
.hero, .tile, .card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.hero { padding: 18px 20px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.label { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.meter { position: relative; height: 10px; border-radius: 5px; background: var(--track); margin-top: 4px; }
.meter-fill { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: 5px; background: var(--accent); transition: width .4s ease; }
.chip { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; padding: 5px 12px 5px 8px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface-2); font-weight: 700; font-size: 14px; }
.chip:empty { display: none; }
.chip .ico { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; color: var(--on-status); font-size: 11px; line-height: 1; }
.chip.good .ico { background: var(--good); }
.chip.bad .ico { background: var(--bad); }
.asof { font-size: 13px; color: var(--ink-2); }
.asof > span { display: block; }
.asof > span + span { margin-top: 6px; }
.asof > .attn { display: flex; gap: 7px; align-items: flex-start; color: var(--ink); font-weight: 600; }
.sub { font-size: 13px; color: var(--ink-2); }
/* OTIF місяця поруч із відсотком виконання */
.hero-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.hero-main { display: flex; flex-direction: column; gap: 8px; min-width: 0; flex: none; }
.hero-otif { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; text-align: right; background: none; border: 0; padding: 2px 0 0; margin: 0; color: inherit; font: inherit; cursor: pointer; border-radius: 8px; flex: 0 1 auto; min-width: 0; max-width: 220px; }
.hero-otif[hidden] { display: none; }
.ho-num { font-size: clamp(30px, 4.4vw, 40px); font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.hero-otif:hover .ho-num { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; }
/* темп: факт / треба і графік по днях */
.pace { display: flex; flex-direction: column; gap: 10px; }
.pace-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 8px 16px; }
.pace-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pace-num { font-size: clamp(30px, 4.4vw, 40px); font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.pace-num .of { color: var(--ink-2); font-weight: 700; }
.pace-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--ink-2); }
.pace-legend[hidden] { display: none; }
.pace-legend span { display: inline-flex; align-items: center; gap: 6px; }
.pace-box { position: relative; }
.pace-chart { width: 100%; min-height: 150px; }
.pace-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.pace .note { margin: 0; }
.sw.good, .key.good { background: var(--good); }
.sw.bad, .key.bad { background: var(--bad); }
.sw.muted, .key.muted { background: var(--axis); }
.sw.today, .key.today { background: var(--track); }
.key.good, .key.bad, .key.muted, .key.today { border-top: 0; height: 3px; }
.key.need { border-top-color: var(--ink); }
.key.need.ahead { border-top-color: var(--ink-3); }
/* доплати: що можна здати сьогодні й завтра, від найбільшої доплати */
.dlv[hidden] { display: none; }
.dlv-sum { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 6px; }
.dlv-sum .pipe-fact { padding: 2px 18px; border-left: 1px solid var(--line); }
.dlv-sum .pipe-fact:first-child { border-left: 0; padding-left: 0; }
.dlv-tabs { margin: 8px 0 4px; }
.dlv-list { list-style: none; margin: 0; padding: 0; }
.dlv-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 14px; align-items: baseline; padding: 9px 2px; border-top: 1px solid var(--line); }
.dlv-row:first-child { border-top: 0; }
.dlv-no { font-weight: 800; font-variant-numeric: tabular-nums; }
.dlv-amt { font-weight: 800; font-size: 16px; text-align: right; white-space: nowrap; }
.dlv-meta, .dlv-paid { font-size: 12px; color: var(--ink-2); }
.dlv-paid { text-align: right; white-space: nowrap; }
.dlv-tag { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 999px; font-size: 11px; font-weight: 700; line-height: 18px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2); vertical-align: 1px; }
.dlv-late { color: var(--bad); font-weight: 600; }
.dlv-grp { font-size: 13px; font-weight: 700; color: var(--ink-2); padding: 14px 2px 4px; }
.dlv-grp + .dlv-row { border-top: 0; }
/* замовлення в роботі: три цифри над виконанням плану */
.orders[hidden] { display: none; }
.orders-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.orders-facts[hidden] { display: none; }
.orders-facts .pipe-fact { padding: 2px 18px; border-left: 1px solid var(--line); }
.orders-facts .pipe-fact:first-child { border-left: 0; padding-left: 0; }

/* дільниці за день: пройшло з плану, смужка (риска — 100%), люди й години; натиснули — які замовлення пройшли */
.secs[hidden] { display: none; }
.day-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.day-lbl { min-width: 160px; text-align: center; font-size: 14px; font-weight: 700; }
@media (max-width: 560px) {
  .day-nav { width: 100%; margin-left: 0; }
  .day-lbl { flex: 1 1 auto; min-width: 0; }
}
.sec-msg { font-size: 13px; color: var(--ink-2); }
.sec-msg:empty { display: none; }
.sec-msg p { margin: 0 0 6px; }
.sec-msg .attn { display: flex; gap: 7px; align-items: flex-start; color: var(--ink); font-weight: 600; }
.sec-list, .sec-rows { list-style: none; margin: 0; padding: 0; }
.sec-group + .sec-group, .sec-row + .sec-row { border-top: 1px solid var(--line); }
/* столярка — заголовок з людьми й годинами, під ним чотири операції */
.sec-ghead { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 10px 4px 0; }
.sec-gname { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.sec-gmeta { font-size: 13px; color: var(--ink-2); }
.sec-gmeta.attn { display: flex; gap: 6px; align-items: flex-start; color: var(--ink); font-weight: 600; }
.sec-gmeta .tri { margin-top: 2px; }
.sec-group.multi .sec-row + .sec-row { border-top-style: dashed; }
.sec-btn { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(46px, auto); grid-template-areas: "name val pct" "bar bar bar" "meta meta meta"; align-items: baseline; gap: 5px 12px;
  width: 100%; padding: 10px 4px; margin: 0; background: none; border: 0; border-radius: 8px; text-align: left; color: inherit; font: inherit; cursor: pointer; }
.sec-btn:hover { background: var(--surface-2); }
.sec-name { grid-area: name; display: inline-flex; align-items: baseline; gap: 6px; min-width: 0; font-size: 15px; font-weight: 700; }
.sec-name::after { content: "›"; color: var(--ink-3); font-weight: 800; transition: transform .15s; }
.sec-btn[aria-expanded="true"] .sec-name::after { transform: rotate(90deg); }
.sec-val { grid-area: val; font-size: 14px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sec-val b { font-size: 22px; font-weight: 800; letter-spacing: -.01em; color: var(--ink); }
.sec-pct { grid-area: pct; text-align: right; font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.sec-pct.good { color: var(--good); }
.sec-pct.bad { color: var(--bad); }
.sec-bar { grid-area: bar; position: relative; height: 6px; margin: 1px 0 2px; border-radius: 3px; background: var(--track); }
.sec-bar i { position: absolute; inset: 0 auto 0 0; border-radius: 3px; background: var(--accent); }
.sec-bar::after { content: ""; position: absolute; top: -3px; bottom: -3px; left: 80%; width: 2px; border-radius: 1px; background: var(--ink); }
.sec-meta { grid-area: meta; font-size: 13px; color: var(--ink-2); }
.sec-meta.attn { display: flex; gap: 6px; align-items: flex-start; color: var(--ink); font-weight: 600; }
.sec-meta .tri { margin-top: 2px; }
.sec-orders { list-style: none; margin: 0 0 8px; padding: 0 4px; font-size: 13px; color: var(--ink-2); }
.sec-orders li { padding: 5px 0; border-top: 1px dashed var(--line); overflow-wrap: anywhere; }
.sec-orders b { margin-right: 8px; color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }
/* на широкому екрані — дві колонки: столярка з операціями ліворуч, шліфовка, покраска й збірка праворуч */
@media (min-width: 900px) {
  .sec-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; align-items: start; }
  .sec-group.multi { grid-row: span 3; }
  .sec-group.multi + .sec-group { border-top: 0; }
}

/* cards */
.card { padding: 16px 18px 18px; min-width: 0; }
.card-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; margin-bottom: 10px; }
h2 { font-size: 16px; font-weight: 700; }
.count { font-size: 13px; color: var(--ink-2); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.seg button { background: var(--surface); border: 0; padding: 6px 12px; font-size: 13px; font-weight: 600; cursor: pointer; color: var(--ink-2); min-height: 32px; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--surface); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--ink-2); margin-bottom: 4px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.tip .row.note { white-space: normal; max-width: 230px; align-items: flex-start; gap: 6px; margin-top: 4px; }
.tip .row.note .tri { margin-top: 1px; }
.key { width: 18px; height: 0; border-top: 2px solid var(--accent); border-radius: 1px; }
.key.plan { border-top-color: var(--plan); }
.chart-box { position: relative; }
.chart { width: 100%; min-height: 240px; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart .empty { display: grid; place-items: center; min-height: 240px; color: var(--ink-2); text-align: center; padding: 24px; }
.tip { position: absolute; z-index: 2; pointer-events: none; background: var(--surface); border: 1px solid var(--axis); border-radius: 8px; padding: 8px 10px; font-size: 13px; box-shadow: 0 6px 18px rgba(8, 14, 22, .18); min-width: 150px; }
.tip h3 { margin: 0 0 4px; font-size: 12px; font-weight: 700; color: var(--ink-2); }
.tip .row { display: flex; align-items: baseline; gap: 8px; white-space: nowrap; }
.tip .row b { font-weight: 800; font-variant-numeric: tabular-nums; min-width: 40px; }
.tip .row i { font-style: normal; color: var(--ink-2); }
.tip .row .key { align-self: center; flex: none; }

.cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 16px; align-items: start; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); padding: 6px 12px 6px 0; border-bottom: 1px solid var(--axis); white-space: nowrap; }
td { padding: 8px 12px 8px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
th:last-child, td:last-child { padding-right: 0; }
th.r, td.r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td .minor { display: block; font-size: 12px; color: var(--ink-2); margin-top: 1px; }
td.strong { font-weight: 700; }
td.date { white-space: nowrap; font-variant-numeric: tabular-nums; color: var(--ink-2); }
td.muted { color: var(--ink-2); white-space: nowrap; }
td .skip { display: flex; align-items: flex-start; gap: 5px; font-size: 12px; font-weight: 600; color: var(--ink); margin-top: 3px; }
td .skip.soft { font-weight: 400; color: var(--ink-2); }
tr.gaprow td { color: var(--ink-2); }
tr.gaprow td .skip { margin-top: 0; font-size: 13px; }
@media (max-width: 560px) { .hide-sm { display: none; } }
tr.grp td { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); background: var(--surface-2); padding: 5px 8px; border-bottom: 1px solid var(--line); }
.flag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; color: var(--ink); }
.flag::before { content: "!"; flex: none; width: 15px; height: 15px; border-radius: 50%; background: var(--warn); color: #1a1300; display: grid; place-items: center; font-size: 11px; font-weight: 800; }
.flag.new { align-items: flex-start; }
.flag.new::before { content: "+"; background: var(--accent); color: var(--on-accent); font-size: 13px; margin-top: 1px; }
.banner.info { border-left-color: var(--accent); }
/* інформаційна плашка з хрестиком: закрили — текст у сповіщеннях «new» (Микола, 26.10.2026) */
.banner.closable { position: relative; padding-right: 44px; }
.banner-x { position: absolute; top: 4px; right: 4px; width: 36px; height: 36px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 8px; background: none; color: var(--ink-2); font: inherit; font-size: 16px; cursor: pointer; }
.banner-x:hover { background: var(--surface-2); color: var(--ink); }
.note { margin: 10px 0 0; font-size: 13px; color: var(--ink-2); }
.note:empty { display: none; }
.link-btn { background: none; border: 0; padding: 8px 0 0; color: var(--accent); font-weight: 700; cursor: pointer; font-size: 14px; }
.link-btn:hover { text-decoration: underline; }

/* rules */
details.card > summary { cursor: pointer; font-weight: 700; font-size: 16px; list-style-position: inside; }
details.card[open] > summary { margin-bottom: 12px; }
.how { font-size: 14px; color: var(--ink); max-width: 78ch; }
.how p { margin: 0 0 10px; }
.how ul { margin: 0 0 12px; padding-left: 20px; }
.how li { margin-bottom: 4px; }
.how a { color: var(--accent); }
.how code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; }
.busy .orders, .busy .hero, .busy .pace, .busy .dlv, .busy .chart-card, .busy .fc, .busy .pipe, .busy .otif { opacity: .6; transition: opacity .2s; }

/* forecast */
.fc { display: grid; grid-template-columns: minmax(250px, 1fr) minmax(0, 1.7fr); gap: 14px 28px; align-items: center; }
.fc[hidden] { display: none; }
.fc-main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.fc-num { font-size: clamp(40px, 6vw, 54px); font-weight: 800; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.fc-range { font-size: 13px; color: var(--ink-2); }
.fc-range:empty { display: none; }
.fc-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 18px; }
.fc-units { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.fc-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fc-stat { display: flex; flex-direction: column; gap: 3px; min-width: 0; padding: 2px 18px; border-left: 1px solid var(--line); }
.fc-val { font-size: clamp(22px, 3vw, 28px); font-weight: 800; line-height: 1.1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.fc-note { grid-column: 1 / -1; margin: 0; font-size: 13px; color: var(--ink-2); }
.fc-note:empty { display: none; }
/* пунктирний ключ малюємо градієнтом: рамка такої ширини виходить суцільною */
.key.dash { border-top: 0; height: 2px; background: repeating-linear-gradient(90deg, var(--accent) 0 5px, transparent 5px 9px); }
.key.plan.dash { background: repeating-linear-gradient(90deg, var(--plan) 0 5px, transparent 5px 9px); }
.key.neutral.dash { background: repeating-linear-gradient(90deg, var(--ink-3) 0 5px, transparent 5px 9px); }
.swatch { flex: none; width: 18px; height: 10px; border-radius: 3px; background: var(--band); }
tr.fcrow td { border-top: 1px solid var(--axis); font-weight: 700; }
.how table { margin: 4px 0 12px; max-width: 560px; }

/* orders in work */
.pipe[hidden] { display: none; }
#pipeChart { max-width: 860px; }
.pipe-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--ink-2); margin: 0 0 8px; }
.pipe-legend span { display: inline-flex; align-items: center; gap: 7px; }
.sw { flex: none; width: 12px; height: 12px; border-radius: 3px; }
.sw.late, .st-bar .late { background: var(--bad); }
.sw.ok, .st-bar .ok { background: var(--accent); }
.stages { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.st-grp { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); padding: 8px 4px 2px; }
.st-grp:first-child { padding-top: 0; }
.stage { display: grid; grid-template-columns: minmax(110px, 200px) minmax(0, 1fr) minmax(64px, auto); align-items: center; gap: 2px 12px; padding: 4px; border-radius: 6px; }
.stage:hover, .stage:focus-visible { background: var(--surface-2); }
.st-name { font-size: 13px; color: var(--ink); overflow-wrap: anywhere; }
.st-bar { display: flex; gap: 2px; height: 12px; min-width: 0; }
.st-bar i { display: block; height: 100%; min-width: 3px; }
.st-bar i:last-child { border-radius: 0 4px 4px 0; }
.st-val { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
.st-val small { font-size: 12px; font-weight: 500; color: var(--ink-2); }
.pipe-fact { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pipe-msg { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 0 0 10px; padding: 10px 12px; border-radius: 8px; border-left: 4px solid var(--bad); background: var(--surface-2); font-size: 14px; }
.pipe-msg p { margin: 0; flex: 1 1 260px; min-width: 0; }

/* OTIF */
.otif[hidden] { display: none; }
.otif-body { display: grid; grid-template-columns: minmax(160px, 190px) minmax(0, 1fr) minmax(220px, 270px); gap: 16px 28px; align-items: start; }
.otif-main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.otif-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.otif-stats .fc-stat:first-child { border-left: 0; padding-left: 0; }
.trend-wrap .label { margin-bottom: 6px; }
.trend { display: flex; align-items: stretch; gap: 6px; height: 128px; }
.trend button { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; background: none; border: 0; border-radius: 6px; padding: 2px 0; cursor: pointer; color: inherit; font: inherit; }
.trend button:hover { background: var(--surface-2); }
.trend .col { width: min(24px, 80%); min-height: 2px; background: var(--accent); border-radius: 4px 4px 0 0; }
.trend .col.part { background: var(--track); }
.trend .val { font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.trend .mon { font-size: 12px; color: var(--ink-2); }
.trend button[aria-pressed="true"] .mon { color: var(--ink); font-weight: 800; }
.trend button[aria-pressed="true"] { background: var(--surface-2); }
.otif-late { margin-top: 16px; }
.otif-late h3 { margin: 0 0 6px; font-size: 14px; font-weight: 700; }
.otif-late table { max-width: 780px; }

@media (max-width: 900px) {
  .cols { grid-template-columns: 1fr; }
  .fc { grid-template-columns: 1fr; }
  .fc-stat:first-child { border-left: 0; padding-left: 0; }
  .otif-body { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .dlv-sum { grid-template-columns: 1fr; }
  .dlv-sum .pipe-fact, .dlv-sum .pipe-fact:first-child { border-left: 0; padding: 8px 0; border-top: 1px solid var(--line); }
  .dlv-sum .pipe-fact:first-child { border-top: 0; padding-top: 0; }
  .brand { width: 100%; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "logo tools" "title title"; row-gap: 6px; }
  .logo { height: 18px; width: 81px; }
  .nt-panel { left: 0 !important; right: 0; width: auto; }
  .orders-facts { grid-template-columns: 1fr; }
  .orders-facts .pipe-fact, .orders-facts .pipe-fact:first-child { border-left: 0; padding: 10px 0; border-top: 1px solid var(--line); }
  .orders-facts .pipe-fact:first-child { border-top: 0; padding-top: 0; }
  .controls { width: 100%; }
  .month { flex: 1; }
  .month select { flex: 1; min-width: 0; }
  .fc-stats { grid-template-columns: 1fr; }
  .stage { grid-template-columns: minmax(0, 1fr) minmax(64px, auto); }
  .st-name { grid-column: 1 / -1; }
  .otif-stats { grid-template-columns: 1fr 1fr; gap: 12px 0; }
  .otif-stats .fc-stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .fc-stat, .fc-stat:first-child { border-left: 0; padding: 10px 0; border-top: 1px solid var(--line); }
}
@media (prefers-reduced-motion: reduce) { .pop, .nt-panel { animation: none; } .info-btn.is-busy .ib { animation: none; } .meter-fill { transition: none; } .busy .orders, .busy .hero, .busy .pace, .busy .dlv, .busy .chart-card, .busy .fc, .busy .pipe, .busy .otif { transition: none; } }

/* вхід і стан доступу — поки сервер не віддав дані */
.gate { max-width: 420px; margin: max(16px, 14vh) auto 0; padding: 28px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; text-align: center; }
.gate .logo { margin: 0 auto 18px; }
.gate h1 { font-size: 22px; margin: 0 0 8px; }
.gate p { color: var(--ink-2); margin: 0 0 14px; }
.gate .gate-widget { min-height: 44px; display: flex; justify-content: center; }
@media (max-width: 560px) { .gate { margin-left: 16px; margin-right: 16px; } }

/* перемикач для власника «Я / Працівник» (тестовий): у режимі працівника смуга помітна, щоб не забути повернутись */
.viewbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; padding: 8px 16px; background: var(--surface-2); border-bottom: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.viewbar[hidden] { display: none; }
.viewbar .seg button { min-height: 36px; padding: 0 14px; }
body.as-worker .viewbar { background: var(--alert); color: var(--alert-ink); font-weight: 700; }

/* вкладки «Цех / Прохідна» — лише для тих, кому відкрито «Прохідну» */
/* без position: sticky — у Telegram на iPhone «липкий» шар не перемальовувався, коли з'являлись інші вкладки
   (лишалась темна кнопка на всю ширину без підписів; скріншоти Миколи 19.10.2026) */
/* розділ «Цех» зверху (Микола, 19.10.2026: згодом поруч з'являться Каталог та інші розділи) і вкладки всередині нього */
.section-bar { position: relative; display: flex; align-items: center; gap: 8px; padding: 12px 16px 2px; background: var(--bg); color: var(--ink); }
/* сповіщення «new» — у правому верхньому куті смуги розділу, на всіх вкладках (Микола, 26.10.2026) */
.section-bar .new-btn { margin-left: auto; }
.section-bar[hidden] { display: none; }
.section-bar .logo { height: 13px; width: auto; flex: none; }
.section-name { font-size: 15px; font-weight: 800; }
.section-name::before { content: "·"; margin-right: 8px; color: var(--ink-3); }
/* п’ять вкладок (з «Кар’єрою», 20.10.2026): на широкому екрані — порівну, на вузькому телефоні смуга прокручується вбік, як папки в Telegram */
.tabs { position: relative; display: flex; gap: 6px; padding: 8px 16px; background: var(--bg); border-bottom: 1px solid var(--line); overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: 1 0 auto; min-height: 40px; padding: 0 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); border-radius: 10px; font: inherit; font-size: 14px; font-weight: 700; white-space: nowrap; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 5px; }
.tabs button[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.tabs button[hidden] { display: none; }
@media (max-width: 370px) { .tabs { gap: 4px; padding: 8px 12px; } .tabs button { font-size: 13px; padding: 0 10px; } }
.tab-badge { min-width: 18px; height: 18px; padding: 0 5px; box-sizing: border-box; border-radius: 999px; background: var(--bad); color: var(--on-status); font-size: 11px; line-height: 18px; text-align: center; }
.tab-badge[hidden] { display: none; }
/* логотип — у назві розділу зверху; у шапці План-факту його не повторюємо */
body.has-section #app .brand > .logo { display: none; }
body.has-section #app .brand { grid-template-areas: "title tools ."; }
@media (max-width: 560px) { body.has-section #app .brand { grid-template-areas: "title tools"; } }
#ideas, #prokh, #pay, #career, #planning, #catalog { display: none; }
body.tab-ideas #ideas, body.tab-prokh #prokh, body.tab-pay #pay, body.tab-career #career, body.tab-planning #planning, body.tab-catalog #catalog { display: block; }
body.tab-ideas #app, body.tab-prokh #app, body.tab-pay #app, body.tab-career #app, body.tab-planning #app, body.tab-catalog #app { display: none !important; }

/* «Прохідна» */
.att-card { margin-top: 12px; }
.att-status { font-size: 18px; font-weight: 700; margin: 8px 0; }
.att-btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.att-big { flex: 1 1 140px; min-height: 52px; padding: 0 14px; border-radius: 12px; border: 1px solid transparent; font: inherit; font-size: 17px; font-weight: 800; cursor: pointer; }
.att-big.in { background: var(--accent); color: var(--on-accent); }
.att-big.out { background: var(--ink); color: var(--surface); }
.att-big.return { background: var(--good); color: var(--on-status); }
.att-big.leave { background: var(--alert); color: var(--alert-ink); }
.att-big.bad { background: var(--bad); color: var(--on-status); }
.att-big.ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.att-big[disabled], .att-mini[disabled] { opacity: .5; cursor: default; }
.att-chip { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.att-chip.pending, .att-chip.none { color: var(--alert); border-color: var(--alert); background: transparent; }
.att-chip.working { color: var(--accent-strong); border-color: var(--accent); background: transparent; }
.att-chip.confirmed { color: var(--good); border-color: var(--good); background: transparent; }
.att-chip.edited { color: var(--accent-strong); border-color: var(--accent-strong); background: transparent; }
.att-chip.absent { background: var(--bad); border-color: var(--bad); color: var(--on-status); }
.att-chip.vacation, .att-chip.sick, .att-chip.unpaid { color: var(--ink-2); }
.att-week, .att-team, .att-links { list-style: none; margin: 0; padding: 0; }
.att-week li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.att-week .att-meta { flex-basis: 100%; }
.att-d { font-weight: 700; }
.att-meta { font-size: 13px; color: var(--ink-2); }
.att-grp { margin-top: 14px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); }
.att-person { padding: 6px 0; border-top: 1px solid var(--line); }
.att-person.absent .att-n { color: var(--bad); }
.att-pname { width: 100%; min-height: 44px; display: flex; justify-content: space-between; align-items: center; gap: 8px; background: none; border: 0; padding: 4px 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.att-n { font-weight: 700; }
.att-tools { margin: 6px 0 4px; padding: 10px; background: var(--surface-2); border-radius: 12px; }
.att-mini { min-height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.att-mini[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.att-mini.good { background: var(--good); color: var(--on-status); border-color: transparent; }
.att-mini.bad { color: var(--bad); }
.att-form { display: grid; gap: 8px; margin-top: 8px; }
.att-form textarea, .att-form input[type=time], .att-form input[type=date], .att-form input[type=text], .att-form select, .att-links select { font: inherit; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); width: 100%; box-sizing: border-box; }
.att-row2 { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.att-row2 input[type=time], .att-row2 select, .att-row2 input[type=text] { width: auto; flex: 1 1 120px; }
.att-week li > .att-form, .att-week li > .att-btns { flex-basis: 100%; margin: 4px 0 0; }     /* «Відпрошування»: кнопки й форма — під рядком */
.att-span { display: grid; grid-template-columns: auto minmax(0, 1fr) auto minmax(0, 1fr); gap: 8px; align-items: center; }   /* «з … по …» — в один рядок */
.att-reasons { display: flex; flex-wrap: wrap; gap: 6px; }
.att-reason { min-height: 40px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; }
.att-reason[aria-checked="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.att-check { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; }
.att-sum { color: var(--ink-2); font-size: 14px; }
.att-dayname { font-weight: 700; padding: 0 6px; white-space: nowrap; }
.att-links li { display: grid; gap: 6px; padding: 8px 0; border-top: 1px solid var(--line); }
#ideas h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); margin: 14px 0 0; }
#prokh h3, #pay h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); margin: 14px 0 0; }
#prokh .card-head, #pay .card-head { flex-wrap: wrap; gap: 8px; }
#prokh .icon-btn { min-height: 44px; min-width: 44px; }
/* порушення дисципліни */
.att-chips { display: inline-flex; flex-shrink: 0; flex-wrap: wrap; max-width: 100%; align-items: center; gap: 6px; }
.att-chip.warn { color: var(--alert); border-color: var(--alert); background: transparent; }
.att-mini.warn { color: var(--alert); }

/* «Зарплата» */
.pay-card { margin-top: 12px; }
#pay .seg button { min-height: 40px; padding: 0 14px; }
.pay-share { margin: -2px 0 10px; }
.pay-share p { margin: 0; }
.pay-share-main { font-size: 15px; }
.pay-share-main b { font-weight: 800; font-variant-numeric: tabular-nums; }
.pay-share .att-meta { margin-top: 2px; }
.pay-facts li.pay-due span { color: var(--ink); font-weight: 800; }
.pay-months { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.pay-archive { min-height: 40px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; }
.pay-closed { margin: 0 0 10px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.bal-pay { margin-top: 10px; }
.pay-facts { list-style: none; margin: 0; padding: 0; font-size: 14px; }
.pay-facts li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line); }
.pay-facts li span:first-child { color: var(--ink-2); flex-shrink: 0; }
.pay-facts li span:last-child { text-align: right; font-weight: 600; }
.pay-warn { color: var(--alert); }
.pay-list { list-style: none; margin: 0; padding: 0; }
.pay-row { border-top: 1px solid var(--line); }
.pay-head { width: 100%; min-height: 56px; display: flex; justify-content: space-between; align-items: center; gap: 10px; background: none; border: 0; padding: 8px 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.pay-head[disabled] { cursor: default; opacity: 1; }
.pay-name { display: grid; gap: 2px; min-width: 0; }
.pay-sum { font-weight: 800; font-size: 17px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pay-sum.warn { color: var(--alert); }
.pay-break { margin: 0 0 10px; padding: 10px 12px; background: var(--surface-2); border-radius: 12px; }
.pay-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.pay-table { table-layout: fixed; }
.pay-table th { text-align: left; font-size: 14px; font-weight: 600; letter-spacing: normal; text-transform: none; color: var(--ink); white-space: normal; overflow-wrap: anywhere; border-bottom: 0; padding: 8px 10px 8px 0; vertical-align: top; }
.pay-table td { width: 96px; border-bottom: 0; }
.pay-table th .att-meta { display: block; font-weight: 400; margin-top: 2px; }
.pay-table td { text-align: right; white-space: nowrap; padding: 8px 0; vertical-align: top; font-variant-numeric: tabular-nums; }
.pay-table tr + tr th, .pay-table tr + tr td { border-top: 1px solid var(--line); }
.pay-table .pay-total th, .pay-table .pay-total td { font-weight: 800; font-size: 16px; }
.pay-prem .att-week li { flex-wrap: nowrap; }
/* свій баланс: гривні «наживо» з прокруткою цифр і жолуді */
.pay-balance .label { margin-top: 4px; }
.bal-money { display: flex; flex-wrap: wrap; align-items: baseline; margin: 2px 0 6px; font-size: 40px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.bal-kop { font-size: 24px; color: var(--ink-2); }
.bal-cur { font-size: 20px; font-weight: 700; color: var(--ink-2); margin-left: 6px; }
.bal-d { display: inline-block; }
.bal-d.roll { animation: balRoll .45s cubic-bezier(.2, .8, .2, 1); }
@keyframes balRoll { from { transform: translateY(55%); opacity: 0; } to { transform: none; opacity: 1; } }
.bal-acorns { margin: 0 0 8px; font-size: 16px; font-weight: 600; color: var(--ink-2); }
.bal-acorn-n { font-size: 24px; font-weight: 800; color: var(--ink); }
.bal-full { margin: 0 0 6px; font-size: 14px; color: var(--ink-2); }
.bal-full.ok { color: var(--good); font-weight: 600; }
.bal-status { display: flex; align-items: center; gap: 8px; margin: 8px 0 0; padding-top: 10px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.bal-status.on { color: var(--ink); }
.bal-status.on::before { content: ''; flex-shrink: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--good); animation: balPulse 1.6s infinite; }
@keyframes balPulse { 0% { box-shadow: 0 0 0 0 rgba(12, 163, 12, .45); } 70% { box-shadow: 0 0 0 8px rgba(12, 163, 12, 0); } 100% { box-shadow: 0 0 0 0 rgba(12, 163, 12, 0); } }
@media (prefers-reduced-motion: reduce) { .bal-d.roll, .bal-status.on::before { animation: none; } }
.pay-acorns { display: flex; justify-content: space-between; gap: 10px; margin: 8px 0 0; padding-top: 8px; border-top: 1px dashed var(--line); font-size: 14px; }
/* «Ідеї» */
.idea-head, .idea-block { margin-top: 12px; }
.idea-balance { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.idea-acorns { font-size: 30px; font-weight: 800; font-variant-numeric: tabular-nums; }
.idea-rulesbox { margin-top: 10px; }
.idea-rulesbox summary, .idea-block > summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; font-weight: 700; }
.idea-block > summary { font-size: 17px; }
.idea-rulesbox summary, .idea-block > summary { list-style: none; }
.idea-rulesbox summary::-webkit-details-marker, .idea-block > summary::-webkit-details-marker { display: none; }
.idea-rulesbox summary::after, .idea-block > summary::after { content: '▾'; margin-left: auto; padding-left: 10px; color: var(--ink-2); }
.idea-rulesbox[open] summary::after, .idea-block[open] > summary::after { content: '▴'; }
.idea-rules { list-style: none; margin: 4px 0; padding: 0; font-size: 14px; }
.idea-rules li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); }
.idea-rules b { white-space: nowrap; }
.idea-list, .shop-list { list-style: none; margin: 0; padding: 0; }
/* ідеї за статусом — згорнуті групи всередині «Мої ідеї» та «Ідеї інших» */
.idea-group { border-top: 1px solid var(--line); }
.idea-group > summary { min-height: 44px; display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 600; list-style: none; }
.idea-group > summary::-webkit-details-marker { display: none; }
.idea-group > summary::after { content: '▾'; margin-left: auto; padding-left: 10px; color: var(--ink-2); }
.idea-group[open] > summary::after { content: '▴'; }
.idea-dot { flex: none; width: 10px; height: 10px; box-sizing: border-box; border-radius: 50%; border: 2px solid var(--line); }
.idea-dot.new { border-color: var(--accent); }
.idea-dot.rework { border-color: var(--alert); border-style: dashed; }
.idea-dot.accepted { border-color: var(--alert); }
.idea-dot.claimed { background: var(--alert); border-color: var(--alert); }
.idea-dot.done { background: var(--good); border-color: var(--good); }
.idea-dot.rejected { background: var(--ink-3); border-color: var(--ink-3); }
/* статистика по працівниках (власнику й керівнику) */
.idea-stats { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.idea-stats th, .idea-stats td { padding: 8px 0 8px 10px; border-bottom: 1px solid var(--line); text-align: right; vertical-align: top; white-space: nowrap; }
.idea-stats th:first-child { padding-left: 0; text-align: left; white-space: normal; }
.idea-stats tbody th { font-size: 14px; font-weight: 600; letter-spacing: normal; text-transform: none; color: var(--ink); }
.idea-stats thead th { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); }
.idea-rank { display: inline-block; min-width: 24px; color: var(--ink-3); font-weight: 700; }
.idea { border-top: 1px solid var(--line); }
.idea-row { width: 100%; min-height: 52px; display: flex; justify-content: space-between; align-items: center; gap: 10px; background: none; border: 0; padding: 8px 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.idea-row.static { cursor: default; }
.idea-title { display: grid; gap: 2px; min-width: 0; }
.idea-title .att-n { overflow-wrap: anywhere; }
.idea-chip { flex-shrink: 0; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; border: 1px solid var(--line); color: var(--ink-2); }
.idea-chip.new, .idea-chip.requested { color: var(--accent-strong); border-color: var(--accent); }
.idea-chip.rework { color: var(--alert); border-color: var(--alert); border-style: dashed; }
.idea-chip.accepted, .idea-chip.bought { color: var(--alert); border-color: var(--alert); }
.idea-chip.claimed { background: var(--alert); border-color: var(--alert); color: var(--alert-ink); }
.idea-chip.done, .idea-chip.issued { background: var(--good); border-color: var(--good); color: var(--on-status); }
.idea-chip.rejected, .idea-chip.cancelled { color: var(--ink-2); text-decoration: line-through; }
.idea-more { margin: 0 0 10px; padding: 10px 12px; background: var(--surface-2); border-radius: 12px; font-size: 14px; }
.idea-more p { margin: 6px 0; }
.idea-photo { display: block; max-width: 100%; max-height: 360px; border-radius: 10px; margin: 8px 0; }
.idea-photorow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.idea-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; }
.idea-criteria { display: grid; gap: 6px; }
.idea-criteria .att-reason { border-radius: 10px; text-align: left; padding: 8px 12px; }
/* доопрацювання й учасники (Микола, 04.11.2026) */
.idea-todo { padding: 8px 10px; border-radius: 10px; border: 1px dashed var(--alert); }
.idea-past { list-style: none; margin: 4px 0 8px; padding: 0; display: grid; gap: 6px; }
.idea-past li { display: grid; gap: 2px; }
.idea-tasks { margin: 8px 0; }
.idea-steps { list-style: none; margin: 6px 0 8px; padding: 0; counter-reset: step; }
.idea-steps > li { counter-increment: step; display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; align-items: start; gap: 2px 6px; padding: 6px 0; border-top: 1px solid var(--line); }
.idea-steps > li::before { content: counter(step); width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line); font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; color: var(--ink-2); }
.idea-steps > li.turn::before { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.idea-steps > li.done::before { content: '✓'; background: var(--good); border-color: var(--good); color: var(--on-status); }
.idea-step { display: grid; gap: 1px; min-width: 0; overflow-wrap: anywhere; }
.idea-steps .att-mini { min-height: 34px; }
.idea-helpers { display: grid; gap: 8px; justify-items: start; }
.idea-helper { display: grid; grid-template-columns: minmax(0, 1fr) 44px; gap: 6px; width: 100%; }
.idea-helper select { grid-column: 1 / -1; }
.idea-helper .att-mini { padding: 0; }
.idea-helpers select, .idea-helpers input[type=text] { width: 100%; box-sizing: border-box; }
.shop-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 6px 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.shop-item > .att-mini, .shop-confirm { grid-column: 1 / -1; justify-self: start; }
.shop-confirm { margin: 0; }
.shop-price { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pay-daysbox { margin: 8px 0; }
.pay-daysbox summary { min-height: 40px; display: flex; align-items: center; cursor: pointer; font-weight: 600; }
.pay-days { list-style: none; margin: 4px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 14px; font-size: 14px; }
.pay-days li { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-top: 1px solid var(--line); }
.pay-days li.miss { color: var(--alert); }
/* «Виправити час» у «Прохідній» */
.att-away { display: grid; gap: 8px; }
.att-times { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; align-items: end; }
.att-times.away { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 44px; }
.att-times .att-mini { min-height: 44px; padding: 0; }
.att-field { display: grid; gap: 4px; min-width: 0; }
.att-away:empty { display: none; }
.att-preview { font-weight: 700; margin: 2px 0; }
.att-preview.bad { color: var(--bad); font-weight: 600; }
.pay-prem .att-week .att-meta { flex: 1 1 auto; flex-basis: auto; min-width: 0; }

/* табель у «Прохідній»: календар місяця з годинами з Excel-табеля */
.tb-month { min-width: 112px; text-align: center; font-weight: 700; }
.tb-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin: 2px 0 10px; }
.tb-wd { padding-bottom: 2px; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; text-align: center; color: var(--ink-3); }
.tb-wd.we { opacity: .7; }
.tb-day { position: relative; min-height: 48px; padding: 16px 2px 4px; box-sizing: border-box; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--line); display: flex; flex-direction: column; align-items: center; font-variant-numeric: tabular-nums; }
.tb-n { position: absolute; top: 3px; left: 5px; font-size: 10px; line-height: 1; color: var(--ink-3); }
.tb-h { font-size: 15px; font-weight: 800; line-height: 1.2; }
.tb-s { margin-top: 1px; font-size: 9px; font-weight: 700; line-height: 1.1; color: var(--ink-2); }
.tb-day.we { background: transparent; }
.tb-day.later { opacity: .45; }
.tb-day.today { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.tb-day.miss .tb-h { color: var(--alert); }
.tb-day.miss::after { content: ""; position: absolute; top: 4px; right: 4px; width: 6px; height: 6px; border-radius: 50%; background: var(--alert); }
.tb-day.vacation, .tb-sw.vacation { background: var(--accent-wash); border-color: transparent; }
.tb-day.sick, .tb-sw.sick { background: rgba(97, 110, 125, .18); border-color: transparent; }
.tb-day.unpaid, .tb-sw.unpaid, .tb-day.dayoff, .tb-sw.dayoff { background: rgba(176, 132, 52, .16); border-color: transparent; }
.tb-day.trainee, .tb-sw.trainee { background: rgba(250, 178, 25, .26); border-color: transparent; }
.tb-day.probation, .tb-sw.probation { background: rgba(250, 178, 25, .1); border-color: rgba(250, 178, 25, .55); }
.tb-day.absent, .tb-sw.absent { background: rgba(208, 59, 59, .15); border-color: transparent; }
.tb-day.absent .tb-s { color: var(--bad); }
.tb-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0 0 10px; font-size: 12px; color: var(--ink-2); }
.tb-sw { display: inline-block; width: 12px; height: 12px; margin-right: 5px; box-sizing: border-box; border-radius: 3px; border: 1px solid var(--line); vertical-align: -2px; }
.tb-sw.miss { width: 8px; height: 8px; border: 0; border-radius: 50%; background: var(--alert); vertical-align: 0; }
.tb-facts { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 0 0 8px; }
.tb-fact { display: flex; flex-direction: column; gap: 2px; }
.tb-fact b { font-size: 17px; font-variant-numeric: tabular-nums; }
.tb-fact.good b { color: var(--good); }
.tb-fact.bad b { color: var(--bad); }
.att-unlinked { border-color: var(--alert); }

/* «Кар’єра» */
.car-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 4px 0; }
.car-grade { font-size: 26px; font-weight: 800; letter-spacing: -.01em; }
.car-next { margin: 10px 0; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); }
.car-next b { font-weight: 800; }
.car-steps { list-style: none; margin: 0; padding: 0; }
.car-step { border-top: 1px solid var(--line); padding: 6px 0; }
.car-step summary { cursor: pointer; display: flex; justify-content: space-between; gap: 10px; font-weight: 700; min-height: 36px; align-items: center; }
.car-step.cur summary { color: var(--accent-strong); }
.car-step.done summary { color: var(--ink-3); }
.car-lines { margin: 4px 0 6px; padding-left: 18px; }
.car-lines li { margin: 3px 0; }
.car-lines li.ok { color: var(--good); }
.car-lines li.no { color: var(--bad); }
.car-check { display: grid; gap: 6px; }
.car-check .att-reason { text-align: left; border-radius: 10px; white-space: normal; padding: 8px 12px; min-height: 40px; }
.car-team { list-style: none; margin: 0; padding: 0; }
.car-team li { border-top: 1px solid var(--line); }
.car-file { border-left: 3px solid var(--accent); margin: 0 0 12px; padding: 4px 0 8px 12px; }
.car-file .card-head { margin-bottom: 4px; }
.car-trow { width: 100%; min-height: 56px; display: flex; justify-content: space-between; align-items: center; gap: 10px; background: none; border: 0; padding: 8px 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.car-trow[aria-expanded="true"] .att-n { color: var(--accent-strong); }
.car-trow .att-chips { flex-wrap: wrap; justify-content: flex-end; }
.car-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.car-table th, .car-table td { padding: 8px 6px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
.car-table th { font-weight: 600; color: var(--ink-2); font-size: 13px; }
.car-table tr.sel td { background: var(--surface-2); }
.car-table td.r, .car-table th.r { text-align: right; white-space: nowrap; }
.car-tl { list-style: none; margin: 0; padding: 0; }
.car-tl li { display: grid; grid-template-columns: 92px 1fr; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); align-items: start; }
.car-tl .d { color: var(--ink-2); font-size: 13px; padding-top: 2px; }
.car-tl .black { color: var(--bad); }
.car-tl .void { opacity: .55; text-decoration: line-through; }
.car-tl .att-mini { margin-top: 6px; }
.car-acts { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.car-board { list-style: none; margin: 0; padding: 0; }
.car-board li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); }
.car-board li.h { font-weight: 800; border-top: 0; margin-top: 6px; }
/* екран «Моє навчання»: заголовок з «Назад», меню розділів, стрілка › */
.car-screen-head { display: flex; align-items: center; gap: 12px; margin: 12px 0 0; }
.car-screen-head h2 { margin: 0; font-size: 20px; }
.car-chev { color: var(--ink-3); font-size: 24px; line-height: 1; padding-left: 8px; }
.att-card h4 { margin: 10px 0 4px; font-size: 14px; color: var(--ink-2); }
/* «Моє навчання» — ігровий шлях (public/learning.js) */
.ln-summary { display: grid; gap: 8px; margin: 4px 0 10px; }
.ln-badges { font-size: 20px; letter-spacing: 2px; }
.ln-badgelist { display: flex; flex-wrap: wrap; gap: 8px; }
.ln-badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-weight: 700; font-size: 14px; }
.ln-icon { font-size: 18px; }
.ln-state { width: 22px; flex: 0 0 22px; text-align: center; font-weight: 800; color: var(--ink-3); }
.ln-passed .ln-state { color: var(--good); }
.ln-open .ln-state { color: var(--accent-strong); }
.car-trow.ln-locked { opacity: .55; cursor: default; }
.ln-card h3 { font-size: 19px; margin: 10px 0 6px; }
.ln-text { font-size: 17px; line-height: 1.5; }
.ln-dots { display: flex; gap: 6px; }
.ln-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.ln-dot.done { background: var(--accent); opacity: .45; }
.ln-dot.on { background: var(--accent); }
.ln-q { border-top: 1px solid var(--line); padding: 10px 0; }
.ln-q p { margin: 4px 0; }
.ln-ok { color: var(--good); }
.ln-no { color: var(--bad); }
.ln-result { text-align: center; }
.ln-score { font-size: 40px; font-weight: 800; }
.ln-result.ok .ln-score { color: var(--good); }
.ln-result.no .ln-score { color: var(--alert); }
.ln-award { margin-top: 10px; padding: 12px; border-radius: 12px; background: var(--surface-2); }
.ln-award-icon { font-size: 44px; line-height: 1.1; }
.car-screen-head .att-mini { white-space: nowrap; flex: 0 0 auto; }
.car-screen-head h2 { min-width: 0; }
.car-trow > .pay-name { flex: 1 1 auto; text-align: left; }

/* «План» (public/planning.js): план дня, терміни, журнал; картка «План дня» в План-факті */
.pl-sub { margin: -4px 0 10px; }
.pl-line { margin: 4px 0; font-size: 14px; }
.pl-line b { font-weight: 800; }
.pl-attn { margin: 8px 0 0; font-size: 13px; font-weight: 600; color: var(--ink); }
.pl-stations, .pl-group-list, .pl-orders, .pl-plain, .pl-journal, .pl-ystations, .pm-list { list-style: none; margin: 0; padding: 0; }
.pl-stations { margin-top: 10px; }
.pl-group + .pl-group { border-top: 1px solid var(--line); }
.pl-gname { padding: 10px 2px 0; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.pl-st { padding: 2px 0 8px; }
.pl-st + .pl-st { border-top: 1px dashed var(--line); }
.pl-st-btn { width: 100%; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 10px 2px 2px; background: none; border: 0; text-align: left; cursor: pointer; }
.pl-st-name { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; min-width: 0; font-size: 15px; font-weight: 700; }
.pl-st-name::after { content: "›"; color: var(--ink-3); font-weight: 800; transition: transform .15s; }
.pl-st-btn[aria-expanded="true"] .pl-st-name::after { transform: rotate(90deg); }
.pl-st-val { font-size: 14px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.pl-st-val b { font-size: 20px; font-weight: 800; color: var(--ink); }
.pl-st-meta { padding: 0 2px; font-size: 12px; color: var(--ink-2); }
.pl-drum { padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; letter-spacing: .02em; color: var(--alert); border: 1px solid var(--alert); }
.pl-st.drum .pl-st-val b { color: var(--alert); }
.pl-orders { margin-top: 4px; }
.pl-row { padding: 7px 2px; border-top: 1px solid var(--line); font-size: 13px; overflow-wrap: anywhere; }
.pl-orders > .pl-row:first-child { border-top: 0; }
.pl-row-btn { width: 100%; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 0; background: none; border: 0; text-align: left; cursor: pointer; }
.pl-no { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ink); }
.pl-tick { display: inline-block; width: 20px; margin-right: 6px; text-align: center; color: var(--good); }
/* кружечок перед номером (Микола, 04.11.2026): сірий — під’їхало сьогодні; цифра — днів на етапі, від легкого жовтого до червоного;
   після 3 днів миготить, і що більше днів, то сильніше */
.pl-dot { display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; min-width: 20px; height: 20px; margin-right: 6px; padding: 0 4px; border-radius: 10px; vertical-align: 1px; font-size: 11px; font-weight: 800; line-height: 1; color: #3a2a00; }
.pl-dot.none { visibility: hidden; padding: 0; }
.pl-dot.new { min-width: 0; width: 10px; height: 10px; margin: 0 11px 0 5px; padding: 0; background: var(--ink-3); opacity: .45; }
.pl-dot.d1 { background: #fbf3a7; }
.pl-dot.d2 { background: #fae695; }
.pl-dot.d3 { background: #f8d683; }
.pl-dot.d4 { background: #f5c371; --pl-dim: .72; animation: pl-dot-blink 2.6s ease-in-out infinite; }
.pl-dot.d5 { background: #f3ad60; --pl-dim: .64; animation: pl-dot-blink 2.3s ease-in-out infinite; }
.pl-dot.d6 { background: #f0944f; --pl-dim: .56; animation: pl-dot-blink 2s ease-in-out infinite; }
.pl-dot.d7 { background: #ed793e; --pl-dim: .48; animation: pl-dot-blink 1.7s ease-in-out infinite; }
.pl-dot.d8 { background: #e95b2e; --pl-dim: .4; animation: pl-dot-blink 1.4s ease-in-out infinite; }
.pl-dot.d9 { background: #e53b1e; color: #fff; --pl-dim: .32; animation: pl-dot-blink 1.15s ease-in-out infinite; }
.pl-dot.d10 { background: #d5241a; color: #fff; --pl-dim: .24; animation: pl-dot-blink .9s ease-in-out infinite; }
.pl-dot.still { animation: none; }
@keyframes pl-dot-blink { 50% { opacity: var(--pl-dim); } }
@media (prefers-reduced-motion: reduce) { .pl-dot { animation: none; } }
/* пріоритет замовлення в плані: 1 — рекламація, 2 — експрес/впритик, 3 — перенесене (Микола, 30.10.2026) */
.pl-tag { display: inline-block; margin-left: 8px; padding: 1px 7px; border-radius: 6px; vertical-align: 2px; font-size: 11px; font-weight: 800; letter-spacing: .02em; background: var(--surface-2); color: var(--ink-2); }
.pl-tag.c1 { background: var(--bad); color: var(--on-status); }
.pl-tag.c2 { background: var(--alert); color: var(--alert-ink); }
.pl-tag.c3 { background: var(--accent-wash); color: var(--accent-strong); }
.pl-tag.c0 { background: var(--surface-2); color: var(--ink-2); font-weight: 600; }   /* пройшло поза планом (03.11.2026) */
/* «Перенести зараз»: до якого дня й реальна дата (Микола, 30.10.2026) */
.pl-resch { margin-top: 3px; font-size: 13px; color: var(--ink-2); }
.pl-resch b { color: var(--ink); font-weight: 700; }
.pl-resch.bad { color: var(--bad); font-weight: 600; }
.pl-row.done .pl-no { color: var(--ink-2); }
.pl-due { color: var(--ink-2); }
.pl-due .bad { color: var(--bad); font-weight: 600; }
.pl-res { margin-left: auto; font-size: 12px; font-weight: 800; }
.pl-res.good { color: var(--good); }
.pl-res.bad { color: var(--bad); }
.pl-meta { margin-top: 2px; color: var(--ink-2); }
.pl-held { margin-top: 3px; color: var(--alert); font-weight: 600; }
.pl-row.held .pl-no { text-decoration: line-through; color: var(--ink-3); }
.pl-why { margin-top: 3px; color: var(--ink); font-weight: 600; }
.pl-more { margin-top: 6px; padding: 8px 10px; border-radius: 8px; background: var(--surface-2); }
.pl-more p { margin: 0 0 6px; }
.pl-empty { padding: 6px 2px; font-size: 13px; color: var(--ink-2); }
.pl-next { margin: 6px 2px 0; font-size: 12px; color: var(--ink-2); }
.pl-next-h { padding: 10px 2px 2px; border-top: 1px solid var(--line); font-size: 12px; color: var(--ink-2); }
.pl-more-btn { display: block; margin: 6px 0 0; padding: 4px 2px; background: none; border: 0; font: inherit; font-size: 12px; color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.pl-hold { display: grid; gap: 8px; margin-top: 4px; }
.pl-hold-q { margin: 0; font-weight: 700; }
.pl-reasons { display: flex; flex-wrap: wrap; gap: 6px; }
.pl-reason { min-height: 36px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; cursor: pointer; }
.pl-reason[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.pl-hold textarea { width: 100%; box-sizing: border-box; font: inherit; font-size: 14px; color: inherit; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.pl-hold-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.pl-primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.pl-primary:hover { background: var(--accent-strong); }
.pl-dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 12px; margin: 8px 0 0; font-size: 14px; }
.pl-dl dt { color: var(--ink-2); }
.pl-dl dd { margin: 0; font-weight: 600; }
.pl-new { margin-top: 10px; }
.pl-ystations li { padding: 6px 0; border-top: 1px solid var(--line); font-size: 13px; }
.pl-ystations li:first-child { border-top: 0; }
.pl-ys { display: block; font-weight: 700; }
.pl-ys.bad { color: var(--bad); }
.pl-ymiss { display: block; margin-top: 2px; color: var(--ink-2); }
.pl-sub-btn { display: block; width: 100%; margin-top: 8px; padding: 10px 2px; background: none; border: 0; border-top: 1px solid var(--line); text-align: left; font-weight: 700; cursor: pointer; }
.pl-sub-btn::after { content: " ›"; color: var(--ink-3); }
.pl-sub-btn[aria-expanded="true"]::after { content: " ⌄"; }
.pl-h3 { margin: 12px 0 4px; font-size: 14px; font-weight: 700; }
.pl-plain li { padding: 4px 0; font-size: 13px; overflow-wrap: anywhere; }
.pl-journal li + li { border-top: 1px solid var(--line); }
.pl-jbtn { width: 100%; display: flex; justify-content: space-between; gap: 10px; padding: 9px 2px; background: none; border: 0; text-align: left; cursor: pointer; font-size: 14px; }
.pl-jday { font-weight: 700; white-space: nowrap; }
.pl-jval { color: var(--ink-2); text-align: right; }
.pl-how { margin: 0; padding-left: 18px; font-size: 14px; line-height: 1.5; }
.pl-how li { margin-bottom: 6px; }
.pl-back { align-self: flex-start; }
.pl-block > summary { font-size: 16px; }
.pm-sub { margin: -4px 0 8px; }
.pm-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0 18px; }
.pm-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 7px 2px; border-top: 1px solid var(--line); font-size: 14px; }
.pm-name { font-weight: 700; }
.pm-val { color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pm-val b { font-size: 17px; font-weight: 800; color: var(--ink); }
.pm-row.drum .pm-name::after { content: " · вузьке місце"; font-weight: 600; font-size: 12px; color: var(--alert); }
.pl-batch { padding: 8px 2px 2px; border-top: 1px solid var(--line); font-size: 12px; font-weight: 800; letter-spacing: .02em; color: var(--accent-strong); }
.pl-orders > .pl-batch:first-child { border-top: 0; }
.pl-st .pl-attn { margin: 4px 2px 0; font-size: 12px; color: var(--alert); }
.pl-note { margin-top: 3px; font-size: 12px; font-weight: 600; color: var(--accent-strong); }

/* «Продажі» (public/sales.js): перемикач розділів «Цех · Продажі», дашборд продажів і підказки менеджерам (Микола, 23.10.2026) */
.section-switch { margin-left: 2px; border-radius: 999px; }
.section-switch button { min-height: 32px; padding: 0 14px; font-size: 14px; font-weight: 800; }
.section-switch button[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); }
#sectionSwitch[hidden], #sectionName[hidden], #tabsSales[hidden] { display: none; }
#salesDash, #salesHints, #salesDealers, #salesSamples, #salesCatalog { display: none; }
body.sec-sales #app, body.sec-sales #tabs, body.sec-sales #ideas, body.sec-sales #prokh, body.sec-sales #pay, body.sec-sales #career, body.sec-sales #planning, body.sec-sales #catalog { display: none !important; }
body.sec-sales.stab-dash #salesDash, body.sec-sales.stab-hints #salesHints, body.sec-sales.stab-dealers #salesDealers, body.sec-sales.stab-samples #salesSamples, body.sec-sales.stab-catalog #salesCatalog { display: flex; }
.sl-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.sl-head h1 { font-size: 24px; }
.sl-head .month select { min-width: 150px; }
@media (max-width: 560px) { .sl-head .month { flex: 1 1 100%; } .sl-head .month select { flex: 1; min-width: 0; } }
.sl-err { margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--bad); color: var(--bad); font-weight: 600; }
.sl-notes { display: grid; gap: 8px; }
.sl-notice { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); font-size: 14px; }
.sl-tri { flex: none; margin-top: 1px; fill: var(--alert); }
.sl-tri .sl-tri-mark { stroke: var(--alert-ink); stroke-width: 2.3; stroke-linecap: round; fill: none; }
.sl-tri .sl-tri-dot { fill: var(--alert-ink); }
.sl-lede { margin: 0; font-size: 16px; line-height: 1.5; }
.sl-lede b { font-weight: 800; }
.sl-up { color: var(--good); font-weight: 700; }
.sl-down { color: var(--bad); font-weight: 700; }
.sl-miss { color: var(--bad) !important; }
.sl-summary { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 16px; }
@media (max-width: 760px) { .sl-summary { grid-template-columns: minmax(0, 1fr); } }
.sl-hero { padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.sl-big { font-size: 34px; font-weight: 800; letter-spacing: -.01em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.sl-sub { font-size: 14px; color: var(--ink-2); }
.sl-sub b { color: var(--ink); font-weight: 800; }
.sl-forecast { padding-top: 4px; border-top: 1px dashed var(--line); margin-top: 2px; }
.sl-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.sl-tile { padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.sl-val { font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.15; overflow-wrap: anywhere; }
.sl-tile .sl-sub { font-size: 12px; }
.sl-note-top { margin: -6px 0 8px; }
.sl-key-dash { border-top-style: dashed; }
.sl-key-muted { border-top-color: var(--ink-3); }
.sl-chart { min-height: 220px; }
.sl-chart svg text { font-family: var(--font); font-size: 11px; }
.sl-grid { stroke: var(--line); stroke-width: 1; }
.sl-axis { fill: var(--ink-3); }
.sl-axis-on { fill: var(--ink); font-weight: 800; }
.sl-line-fact, .sl-line-fc, .sl-line-plan, .sl-line-prev { fill: none; stroke-linejoin: round; }
.sl-line-fact { stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; }
.sl-line-fc { stroke: var(--accent); stroke-width: 2; stroke-dasharray: 5 4; }
.sl-line-plan { stroke: var(--plan); stroke-width: 1.6; stroke-dasharray: 5 4; }
.sl-line-prev { stroke: var(--ink-3); stroke-width: 1.6; opacity: .75; }
.sl-dot { fill: var(--accent); }
.sl-end { font-weight: 700; }
.sl-end-fact { fill: var(--accent-strong); }
.sl-end-plan { fill: var(--plan); }
.sl-end-prev { fill: var(--ink-3); }
.sl-rule { stroke: var(--axis); stroke-width: 1; }
.sl-plan-tick { stroke: var(--plan); stroke-width: 2; stroke-dasharray: 4 3; }
.sl-pt { fill: var(--ink-3); stroke: var(--ink-3); stroke-width: 1.5; }
.sl-pt-open { fill: var(--surface); }
.sl-c0 { background: var(--axis); fill: var(--axis); }
.sl-c1 { background: var(--accent); fill: var(--accent); }
.sl-c2 { background: var(--gold); fill: var(--gold); }
.sl-open { opacity: .5; }
.sl-sw { display: inline-block; width: 12px; height: 12px; border-radius: 3px; flex: none; }
.sl-table td, .sl-table th { white-space: nowrap; }
.sl-table td:first-child { white-space: normal; min-width: 90px; }
.sl-table tr.sl-total td { font-weight: 800; background: var(--surface-2); }
.sl-sec-title { font-size: 18px; margin: 4px 0 -4px; }
.sl-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: start; }
@media (max-width: 900px) { .sl-cols { grid-template-columns: minmax(0, 1fr); } }
.sl-h3 { margin: 0; font-size: 16px; }
.sl-bar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 14px; }
.sl-bar-nm { min-width: 0; overflow-wrap: anywhere; }
.sl-bar-vl { color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sl-bar-vl b { color: var(--ink); }
.sl-bar-tr { grid-column: 1 / -1; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.sl-bar-fl { height: 100%; border-radius: 999px; }
.sl-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px 16px; margin: 4px 0 8px; }
.sl-kpi { display: flex; flex-direction: column; gap: 3px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); min-width: 0; }
.sl-kpi .sl-sub { font-size: 12px; }
.sl-more { margin-top: 10px; }
.sl-more > summary { cursor: pointer; font-weight: 700; color: var(--accent); }

/* підказки */
.sl-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.sl-chips::-webkit-scrollbar { display: none; }
.sl-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.sl-chip span { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); font-size: 12px; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums; }
.sl-chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.sl-chip[aria-pressed="true"] span { background: var(--surface); color: var(--ink); }
.sl-sec { display: flex; flex-direction: column; gap: 10px; }
.sl-sec-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.sl-sec-head h2 { font-size: 18px; }
.sl-n { min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-size: 12px; font-weight: 800; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.sl-asof { font-size: 13px; color: var(--ink-2); }
.sl-card { padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.sl-card.is-late { border-left: 3px solid var(--bad); }
.sl-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.sl-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.sl-name { font-size: 16px; font-weight: 800; overflow-wrap: anywhere; }
.sl-meta { font-size: 12px; color: var(--ink-2); overflow-wrap: anywhere; }
.sl-amount { flex: none; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sl-amount s { color: var(--ink-3); font-weight: 600; margin-right: 2px; }
.sl-lag { font-size: 13px; padding: 5px 10px; border-radius: 8px; align-self: flex-start; }
.sl-lag b { font-weight: 800; }
.sl-lag.is-late { background: rgba(208, 59, 59, .10); color: var(--bad); }
.sl-lag.is-ok { background: var(--accent-wash); color: var(--accent-strong); }
.sl-lag.is-wait { background: var(--surface-2); color: var(--ink-2); }
.sl-lag-why { font-weight: 500; opacity: .9; }
.sl-what { font-size: 14px; font-weight: 600; }
.sl-state { font-size: 13px; color: var(--ink-2); line-height: 1.45; }
.sl-tags { font-size: 12px; color: var(--ink-3); }
.sl-line { font-size: 14px; display: grid; grid-template-columns: 82px minmax(0, 1fr); gap: 8px; }
.sl-line-k { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); padding-top: 2px; }
.sl-bubble { background: var(--accent-wash); border-radius: 12px 12px 12px 4px; padding: 10px 12px; font-size: 14px; }
.sl-bubble.is-call { background: var(--surface-2); border: 1px dashed var(--line); }
.sl-bubble-label { font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-2); margin-bottom: 4px; }
.sl-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.sl-fill { background: rgba(250, 178, 25, .32); color: inherit; border-radius: 4px; padding: 0 2px; }
.sl-bubble-hint { margin-top: 6px; font-size: 12px; color: var(--ink-2); }
.sl-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.sl-actions .btn { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; color: var(--ink); }
.sl-actions .btn.sm { min-height: 36px; padding: 0 12px; font-size: 13px; }
.sl-copy { background: var(--accent); border-color: var(--accent); color: var(--on-accent) !important; }
.sl-copy.is-done { background: var(--good); border-color: var(--good); }
.sl-group { padding: 12px 14px; }
.sl-group > summary { cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-weight: 800; list-style: none; }
.sl-group > summary::-webkit-details-marker { display: none; }
.sl-group > summary::after { content: "›"; color: var(--ink-3); font-weight: 800; transition: transform .15s; }
.sl-group[open] > summary::after { transform: rotate(90deg); }
.sl-group-t { flex: 1; }
/* «Перенести дату» — рядок-кнопка серед пропозицій, натиснули — окремий екран (Микола, 31.10.2026) */
.sl-entry { display: flex; align-items: center; gap: 10px; width: 100%; padding: 12px 14px; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.sl-entry::after { content: "›"; color: var(--ink-3); font-weight: 800; }
.sl-entry .sl-dot-t { align-self: flex-start; margin-top: 6px; }
.sl-entry-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.sl-entry-t b { font-weight: 800; }
.sl-entry-sub { font-size: 13px; color: var(--ink-2); }
.sl-entry-sub.is-today { color: var(--bad); font-weight: 700; }
.sl-back { align-self: flex-start; }
.sl-group[open] > summary { margin-bottom: 10px; }
.sl-row { border-top: 1px solid var(--line); }
.sl-group .sl-row:first-of-type { border-top: 0; }
.sl-row > summary { cursor: pointer; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; padding: 10px 0; list-style: none; font-size: 14px; }
.sl-row > summary::-webkit-details-marker { display: none; }
.sl-row-who b { font-weight: 800; }
.sl-row-what { flex: 1 1 100%; color: var(--ink-2); font-size: 13px; }
.sl-row-late { font-size: 12px; font-weight: 700; color: var(--bad); }
.sl-row-body { display: flex; flex-direction: column; gap: 8px; padding: 0 0 12px; }
.sl-args { display: grid; gap: 10px; }
.sl-arg { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.sl-rules ol { margin: 6px 0 0; padding-left: 20px; display: grid; gap: 8px; }
.sl-rules li p { margin: 2px 0 0; font-size: 14px; color: var(--ink-2); }
.sl-people .sl-person { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 170px); gap: 4px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.sl-people select { width: 100%; padding: 8px; }
.sl-people .sl-meta { grid-column: 1 / -1; }
.sl-person-n { font-weight: 700; overflow-wrap: anywhere; }
.sl-toast { position: fixed; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 30; display: flex; align-items: center; gap: 14px; max-width: calc(100% - 32px); padding: 10px 16px; border-radius: 12px; background: var(--ink); color: var(--surface); font-size: 14px; box-shadow: 0 10px 28px rgba(8, 14, 22, .25); }
.sl-toast .link-btn { padding: 0; color: var(--surface); text-decoration: underline; }
.sl-offscreen { position: fixed; left: -9999px; top: 0; opacity: 0; }
#salesDashBody, #salesHintsBody, #salesDealersBody { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
/* «Продажі» → «Дилери» (public/dealers.js) */
#salesDealersBody { width: 100%; }
.dm-lead { margin: 0; }
.dm-msg { margin: 0; padding: 10px 14px; border-radius: 10px; background: var(--accent-wash); color: var(--ink); font-size: 14px; }
.dm-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dm-row input[type="text"], .dm-block input[type="search"] { min-height: 38px; border: 1px solid var(--line); border-radius: 8px; padding: 0 12px; background: var(--surface); color: var(--ink); font: inherit; min-width: 0; flex: 1 1 180px; }
.dm-block input[type="search"] { width: 100%; margin-top: 8px; }
.dm-a { display: inline-flex; align-items: center; text-decoration: none; color: var(--ink); }
.dm-link { width: 100%; min-height: 40px; border: 1px solid var(--line); border-radius: 8px; padding: 0 12px; background: var(--surface-2); color: var(--ink); font: 600 13px/1 var(--font); margin: 10px 0; }
.dm-invite { border: 2px solid var(--accent); }
.dm-invite h2, .dm-new h2 { margin: 0; font-size: 17px; }
.dm-dealer > summary { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; cursor: pointer; list-style: none; font-size: 16px; }
.dm-dealer > summary::-webkit-details-marker { display: none; }
.dm-dealer > summary::before { content: "›"; display: inline-block; transition: transform .15s; color: var(--ink-3); font-weight: 700; }
.dm-dealer[open] > summary::before { transform: rotate(90deg); }
.dm-dealer[open] > summary { margin-bottom: 12px; }
.dm-chip { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); background: var(--surface-2); }
.dm-chip.ok { color: var(--good); border-color: currentColor; }
.dm-chip.bad { color: var(--bad); border-color: currentColor; }
.dm-meta { font-size: 12px; color: var(--ink-3); }
.dm-block { border-top: 1px solid var(--line); margin-top: 14px; padding-top: 12px; }
.dm-block h3 { margin: 0 0 6px; font-size: 14px; }
.dm-block h4 { margin: 12px 0 4px; font-size: 13px; color: var(--ink-2); }
.dm-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.dm-line:last-child { border-bottom: 0; }
.dm-line > span:first-child { flex: 1 1 200px; min-width: 0; }
.dm-line .link-btn { padding: 0; font-size: 13px; }
.dm-line select { min-height: 32px; font-size: 13px; }
.dm-line.off > span:first-child { color: var(--ink-3); text-decoration: line-through; }
.dm-found { margin-top: 4px; }
.dm-reqs { border: 2px solid var(--accent); }
.dm-reqs h2 { margin: 0; font-size: 17px; }
.dm-req { border-top: 1px solid var(--line); padding: 12px 0 4px; display: flex; flex-direction: column; gap: 6px; }
.dm-req-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dm-req-items { margin: 0; padding-left: 20px; font-size: 14px; }
.dm-req-m { margin: 0; font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.dm-req .dm-row { margin-top: 4px; }
.dm-req .dm-row input[type="text"] { min-height: 38px; border: 1px solid var(--line); border-radius: 8px; padding: 0 12px; background: var(--surface); color: var(--ink); font: inherit; flex: 1 1 200px; min-width: 0; }
.sl-mob-minor .minor { display: none; }
@media (max-width: 560px) { .sl-mob-minor .minor { display: block; } }
.sl-kpi .sl-val { font-size: clamp(17px, 4.6vw, 22px); }
@media (max-width: 560px) { .sl-table th, .sl-table td { padding-right: 8px; font-size: 13px; } .sl-table td:first-child { min-width: 0; } }
/* «Пропозиції для менеджерів» — як у claude.ai (Микола, 23.10.2026) */
p.sl-asof { margin: -8px 0 0; }
.sl-dot-t { width: 10px; height: 10px; border-radius: 50%; flex: none; align-self: center; background: var(--ink-3); }
.t-hot .sl-dot-t { background: var(--bad); }
.t-client .sl-dot-t { background: var(--accent); }
.t-warm .sl-dot-t { background: var(--warn); }
.t-resched .sl-dot-t { background: var(--alert); }   /* «Перенести дату» — цех не встигає (Микола, 30.10.2026) */
.sl-state { color: var(--gold); }
.sl-fold > summary { cursor: pointer; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.sl-fold > summary::-webkit-details-marker { display: none; }
.sl-open { align-self: flex-start; font-size: 13px; font-weight: 700; color: var(--accent); }
.sl-open::after { content: " ›"; }
.sl-fold[open] .sl-open { display: none; }
.sl-row-side { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; }
.sl-row > summary { align-items: center; }
.sl-foot > summary { cursor: pointer; font-weight: 700; }
.sl-foot p { margin: 8px 0 0; }

/* звільнення в особистій справі (Микола, 25.10.2026): чекліст керівника — кожен крок кнопкою-галочкою */
.car-leaving { margin-top: 12px; padding: 12px; border-radius: 12px; background: var(--surface-2); }
.car-leaving h3 { margin-top: 0; }
.car-steps { list-style: none; margin: 8px 0 0; padding: 0; }
.car-steps li + li { border-top: 1px solid var(--line); }
.car-stepbtn { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 2px; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.car-stepbtn:disabled { opacity: .6; cursor: default; }
.car-stepmark { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--ink-3); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; }
.car-stepbtn[aria-checked="true"] .car-stepmark { background: var(--good); border-color: var(--good); color: #fff; }
.car-stepbtn[aria-checked="true"] .att-n { text-decoration: line-through; opacity: .7; }
/* звільнені в команді — згорнута група внизу (Микола, 25.10.2026) */
.car-gone { margin-top: 10px; border-top: 1px solid var(--line); }
.car-gone > summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; list-style: none; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-2); }
.car-gone > summary::-webkit-details-marker { display: none; }
.car-gone > summary::after { content: '▾'; margin-left: auto; padding-left: 10px; }
.car-gone[open] > summary::after { content: '▴'; }
/* відпустка з «Кар’єри» (Микола, 26.10.2026): список в особистій справі й рядок у моїй картці */
.car-vac { margin-top: 12px; }
.car-vac .att-week li { flex-wrap: wrap; }
.car-vacnote { margin: 4px 0 10px; padding: 10px 12px; border-radius: 12px; background: var(--accent-wash); color: var(--ink); font-weight: 600; }
/* рядок людини в команді: плашки не стискаються й не налазять на ім’я — коли поруч не вміщаються, переходять
   на новий рядок праворуч (Микола, 26.10.2026: «одне на інше наклалось») */
.car-trow { flex-wrap: wrap; }
.car-trow > .pay-name { flex: 1 1 180px; min-width: 0; }
.car-trow .att-chips { flex: 0 0 auto; margin-left: auto; }

/* «Планшет-прохідна» в «Прохідній» (public/prokhidna.js): звідки відмітка, фото, картка «Планшети біля входу» */
.att-src { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 6px; margin-top: 6px; }
.att-src .att-mini { min-height: 34px; font-size: 13px; text-align: left; }
.att-src-i { padding: 6px 2px; font-size: 13px; color: var(--ink-2); }
.att-src .lost { color: var(--alert); }
.att-photo { flex-basis: 100%; }
.att-photo img { display: block; max-width: min(100%, 320px); border-radius: 10px; margin: 4px 0; }
.att-photo .note { margin: 4px 0; }
.att-dayphotos { margin: 8px 0 4px; }
.att-pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin-top: 8px; }
.att-pgrid figure { margin: 0; }
.att-pgrid .att-photo img { max-width: 100%; margin: 0; }
.att-pgrid figcaption { font-size: 12px; color: var(--ink-2); margin-top: 4px; }
.att-code { margin: 8px 0; padding: 12px; border: 1px solid var(--accent); border-radius: 12px; background: var(--accent-wash); }
.att-code-n { font-size: 34px; font-weight: 800; letter-spacing: .12em; font-variant-numeric: tabular-nums; }

/* «Налаштування» (public/settings.js, src/settings/; Микола, 03.11.2026): третій розділ лише власнику — «Цех · Продажі · Налаштування»;
   картки «Заступник на час відпустки» у «Прохідній» і «Немає матеріалу» у «Плані» */
#settings { display: none; }
body.sec-settings #app, body.sec-settings #tabs, body.sec-settings #ideas, body.sec-settings #prokh, body.sec-settings #pay, body.sec-settings #career, body.sec-settings #planning, body.sec-settings #catalog, body.sec-settings #salesCatalog, body.sec-settings #salesSamples, body.sec-settings #salesDash, body.sec-settings #salesHints, body.sec-settings #salesDealers, body.sec-settings #tabsSales { display: none !important; }
body.sec-settings #settings { display: flex; }
#secSettings[hidden], #tabsSettings[hidden], #secSales[hidden] { display: none; }
@media (max-width: 430px) { body.has-settings .section-bar > .logo { display: none; } body.has-settings .section-switch button { padding: 0 9px; font-size: 13px; } }
.st-lead { margin: 0 0 10px; }
.st-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.st-table th, .st-table td { padding: 8px 6px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
.st-table thead th { border-top: 0; font-size: 12px; color: var(--ink-2); font-weight: 700; }
.st-table tbody th { font-size: 13px; font-weight: 700; letter-spacing: normal; text-transform: none; color: var(--ink); white-space: normal; width: 1%; min-width: 92px; }
.st-table tbody th .st-cell-note { display: block; font-weight: 500; }
.st-table td .st-check { min-width: 84px; align-items: flex-start; }
.st-cell-note { display: block; font-size: 11px; font-weight: 500; color: var(--ink-3); line-height: 1.3; }
.st-fixed { color: var(--good); font-weight: 700; white-space: nowrap; }
.st-hints { margin: 10px 0 0; padding-left: 18px; font-size: 13px; color: var(--ink-2); }
.st-hints li { margin-bottom: 3px; }
.st-pending { margin: 8px 0 0; font-size: 13px; font-weight: 600; color: var(--accent-strong); }
.st-check { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.st-check input { width: 20px; height: 20px; margin: 0; flex: none; accent-color: var(--accent); }
.st-people { display: grid; gap: 8px; margin: 6px 0 0; }
.st-person { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; font-size: 14px; }
.st-person .st-role { font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.st-save { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 12px; }
.st-save .st-n { font-weight: 700; flex: 1 1 100%; }
.st-field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--ink-2); min-width: 0; }
.st-grow { flex: 1 1 200px; }
.st-form { display: grid; gap: 10px; margin-top: 10px; }
.st-row { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: flex-end; }
.st-form input[type="text"], .st-form input[type="date"], .st-form select, .st-save input[type="text"], .st-save input[type="date"] { font: inherit; font-weight: 500; color: var(--ink); min-height: 40px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); min-width: 0; box-sizing: border-box; }
.st-form input[type="text"] { width: 100%; }
.st-mode { display: inline-flex; gap: 6px; }
.st-mode button { min-height: 36px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.st-mode button[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.st-list { list-style: none; margin: 8px 0 0; padding: 0; }
.st-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; overflow-wrap: anywhere; }
.st-list li:first-child { border-top: 0; }
.st-list .st-who { font-weight: 700; }
.st-list .st-meta { flex-basis: 100%; font-size: 12px; color: var(--ink-3); }
.st-list .link-btn { padding: 0; margin-left: auto; font-size: 13px; }
.st-state-now { color: var(--good); font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.st-state-future { color: var(--accent-strong); font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.st-state-past { color: var(--ink-3); font-size: 12px; }
.st-journal li { display: block; }
.st-jhead { font-size: 12px; color: var(--ink-3); }
.st-jtext { margin-top: 2px; }
.st-arrow { color: var(--ink-3); }
.st-msg { margin: 0; padding: 10px 14px; border-radius: 10px; background: var(--accent-wash); color: var(--ink); font-size: 14px; }
.st-preview { border: 2px solid var(--accent); }
.st-who-list { flex-basis: 100%; margin: 2px 0 0; padding-left: 18px; font-size: 13px; }
.st-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.st-primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.st-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.st-danger { color: var(--bad); }
.st-past summary { cursor: pointer; font-weight: 600; margin-top: 8px; }

/* «Підбір зразків» (public/samples.js, src/samples/; Микола, 04.11.2026): вигляд варіанта 8 — кольори з docs/design/v8-src/v8.css. Кольори сталі: нічної теми в новому дизайні немає */
.pl-switch { display: flex; margin-bottom: 12px; }
body.pl-samples #planningBody { display: none; }
#samplesBody, #salesSamplesBody, #catalogBody, #salesCatalogBody { --sm-ink: #1E2A4A; --sm-ink2: #586B82; --sm-mute: #8A9BB3; --sm-well: #E4E8EE; --sm-blue: #1B6FD6; --sm-coral: #F26B52; --sm-shadow: 0 8px 24px rgba(30, 42, 74, .08); color: var(--sm-ink); width: 100%; min-width: 0; }
#salesSamplesBody { display: flex; flex-direction: column; gap: 16px; }
#samplesBody:not([hidden]) { display: flex; flex-direction: column; gap: 16px; }
.sm-head { display: flex; flex-direction: column; gap: 8px; }
.sm-title { margin: 0; font-size: clamp(24px, 4vw, 32px); font-weight: 700; line-height: 1.12; letter-spacing: -.01em; color: var(--ink); }
.sm-sub { margin: 0; font-size: 13px; line-height: 1.5; color: var(--ink-2); }
.sm-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.sm-c { background: #fff; border-radius: 18px; padding: 18px; display: flex; flex-direction: column; gap: 8px; box-shadow: var(--sm-shadow); min-width: 0; font-size: 13px; color: var(--sm-ink); }
.sm-c.center { align-items: center; text-align: center; }
.sm-c.peach { background: #F6DCD6; box-shadow: none; }
.sm-c.peach b { color: #D8311C; }
.sm-c h2 { margin: 0; font-size: 18px; color: var(--sm-ink); }
.sm-ring { display: block; }
.sm-cap { font-size: 12px; color: var(--sm-ink2); line-height: 1.45; }
.sm-cap.warn { color: #D8311C; font-weight: 600; }
.sm-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; padding: 10px 14px; border-radius: 14px; background: var(--sm-well); font-size: 12px; color: var(--sm-ink2); }
.sm-strip span { display: inline-flex; align-items: center; gap: 6px; }
.sm-dot { width: 10px; height: 10px; border-radius: 5px; display: inline-block; flex: none; }
.sm-dot.green { background: #0CC78A; } .sm-dot.yellow { background: #F2C400; } .sm-dot.orange { background: #F2A33A; } .sm-dot.red { background: #E0392B; }
.sm-kan { display: grid; gap: 16px; align-items: start; }
.sm-kan.k4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sm-kan.k2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sm-col { background: var(--sm-well); border-radius: 18px; padding: 12px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.sm-col h3 { margin: 0 0 2px; padding: 2px 4px; font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; color: var(--sm-ink); }
.sm-cnt { min-width: 22px; height: 22px; border-radius: 11px; background: var(--sm-ink); color: #fff; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.sm-empty { margin: 0; padding: 6px 4px; font-size: 12px; color: var(--sm-mute); }
.sm-card { background: #fff; border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--sm-shadow); min-width: 0; color: var(--sm-ink); }
.sm-no { font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sm-tone { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--sm-ink2); }
.sm-wood { width: 14px; height: 14px; border-radius: 7px; border: 1px solid rgba(30, 42, 74, .15); display: inline-block; flex: none; }
.sm-what { font-size: 13px; line-height: 1.35; overflow-wrap: anywhere; }
.sm-meta { font-size: 12px; color: var(--sm-ink2); line-height: 1.4; overflow-wrap: anywhere; }
.sm-note { font-size: 12px; color: var(--sm-ink2); line-height: 1.4; }
.sm-note.bad { color: #C8392A; font-weight: 600; }
.sm-pill { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 13px; font-size: 11px; font-weight: 600; white-space: nowrap; flex: none; background: #fff; color: var(--sm-ink); }
.sm-pill.xs { height: 20px; padding: 0 8px; font-size: 10px; border-radius: 10px; }
.sm-no .sm-pill { margin-left: auto; }
.sm-pill.green { background: #D9F5EB; color: #0A8F62; } .sm-pill.yellow { background: #FFF1B3; color: #7A5E00; } .sm-pill.orange { background: #FFE3C4; color: #9A4B00; } .sm-pill.red { background: #FBDAD3; color: #C8392A; } .sm-pill.coral { background: var(--sm-coral); color: #fff; align-self: flex-start; }
.sm-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.sm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 18px; border: 0; border-radius: 12px; background: var(--sm-coral); color: #fff; font: inherit; font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; }
.sm-btn.sm { height: 34px; padding: 0 12px; border-radius: 17px; font-size: 12px; }
.sm-btn.ghost { background: #fff; color: var(--sm-ink); box-shadow: inset 0 0 0 1px rgba(30, 42, 74, .14); }
.sm-btn.ok { background: #0CC78A; }
.sm-btn.link { background: none; color: var(--sm-ink2); padding: 0 6px; text-decoration: underline; }
.sm-btn[disabled] { opacity: .55; cursor: default; }
.sm-input { width: 100%; min-width: 0; height: 40px; padding: 0 12px; border: 1px solid rgba(30, 42, 74, .16); border-radius: 12px; background: #fff; color: var(--sm-ink); font: inherit; font-size: 14px; box-sizing: border-box; }
textarea.sm-input { height: auto; padding: 8px 12px; resize: vertical; }
.sm-input.num { width: 72px; flex: none; }
.sm-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.sm-row.between { justify-content: space-between; }
.sm-form { display: flex; flex-direction: column; gap: 6px; }
.sm-arrived form { margin-top: 2px; }
.sm-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.sm-chip { height: 32px; padding: 0 12px; border: 0; border-radius: 16px; background: var(--sm-well); color: var(--sm-ink); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.sm-chip.on { background: var(--sm-ink); color: #fff; }
.sm-recipe summary { cursor: pointer; font-size: 12px; font-weight: 600; color: var(--sm-blue); }
.sm-layer { font-size: 12px; line-height: 1.45; padding-top: 4px; overflow-wrap: anywhere; }
.sm-edit { gap: 10px; }
.sm-lay { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: 14px; background: #F4F6F9; }
@media (max-width: 899px) {
  .sm-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .sm-cards.has-bonus .sm-c.peach { grid-column: 1 / -1; }
  .sm-kan.k4, .sm-kan.k2 { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .sm-c { padding: 14px; border-radius: 16px; }
}

/* «План покраски» (public/paint.js, src/paint/; Микола, 04.11.2026): картки тягнуть пальцем чи мишею */
#paintBody:not([hidden]) { display: flex; flex-direction: column; gap: 16px; }
#paintBody { --sm-ink: #1E2A4A; --sm-ink2: #586B82; --sm-mute: #8A9BB3; --sm-well: #E4E8EE; --sm-blue: #1B6FD6; --sm-coral: #F26B52; --sm-shadow: 0 8px 24px rgba(30, 42, 74, .08); color: var(--sm-ink); width: 100%; min-width: 0; }
.sm-kan.k3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
/* усі три стовпці — на висоту найдовшого: картку знизу можна тягнути просто вбік (Микола, 05.11.2026). На телефоні стовпці одне під одним, там висота не вирівнюється */
.pt-board { align-items: stretch; }
.pt-col { transition: box-shadow .12s; min-height: 120px; }
.pt-col.over { box-shadow: inset 0 0 0 2px #2F8FEF; }
.pt-hint { margin-left: auto; font-size: 11px; font-weight: 400; color: var(--sm-mute); }
.pt-card.can { cursor: grab; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: manipulation; }
.pt-card.dim { opacity: .55; }
.pt-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 12px; color: var(--sm-ink2); line-height: 1.4; }
.pt-late { color: var(--sm-coral); font-weight: 600; }
.pt-line .sm-pill { margin-left: auto; }
.sm-pill.blue { background: #DCEBFC; color: #1B6FD6; }
.pt-done { align-self: flex-start; margin-top: 2px; }
.pt-open { align-self: flex-start; margin-top: auto; }
.pt-src { opacity: .35; }
.pt-ghost { position: fixed; left: 0; top: 0; z-index: 1000; pointer-events: none; box-shadow: 0 14px 34px rgba(30, 42, 74, .28); will-change: transform; }
body.pt-dragging { cursor: grabbing; -webkit-user-select: none; user-select: none; }
@media (max-width: 899px) { .sm-kan.k3 { grid-template-columns: minmax(0, 1fr); gap: 12px; } }

/* стани статистики (public/stat.js; правило Миколи, 04.11.2026): кільце, стовпчики, блимання, зірочки; картка приходу */
.st-ring { position: relative; display: inline-block; flex: none; }
.st-ring svg { display: block; }
.st-blink { animation: st-blink var(--st-hz, 1s) steps(2, jump-none) infinite; }
@keyframes st-blink { 0% { opacity: 1; } 100% { opacity: .3; } }
.st-stars { position: absolute; inset: 0; pointer-events: none; }
.st-star { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; font-size: 10px; line-height: 10px; font-style: normal; color: #F2C400; opacity: 0; animation: st-star 2.6s ease-in-out infinite; }
@keyframes st-star { 0%, 100% { opacity: 0; transform: scale(.4); } 40% { opacity: 1; transform: scale(1.15) rotate(20deg); } 70% { opacity: .6; transform: scale(.8); } }
@media (prefers-reduced-motion: reduce) { .st-blink, .st-star { animation: none; } .st-star { opacity: 1; } }
.st-bars { display: flex; gap: 8px; align-items: stretch; height: 150px; }
.st-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.st-col.off { opacity: .5; }
.st-track { position: relative; flex: 1 1 auto; width: min(22px, 100%); border-radius: 11px; background: #E9EEF4; overflow: hidden; }
.st-fill { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 11px; background: #2F8FEF; }
.st-fill.live { opacity: .55; }
.st-lab { font-size: 11px; color: var(--ink-3); }
.st-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 10px 0; }
.st-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; font-size: 13px; }
.st-card.center { align-items: center; text-align: center; }
.st-big { font-size: 32px; font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
.st-big.muted { color: var(--ink-3); }
.st-late .st-big, .st-late b { color: #7A5E00; }
.st-cap { font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.st-week { margin-top: 14px; }
.st-week h3 { margin: 0; }
.att-chip.late { background: #FFF1B3; color: #7A5E00; border-color: transparent; }
.att-big.in { background: #F26B52; color: #fff; }
.att-big.out { background: var(--surface); color: var(--ink); border-color: var(--line); }
.pay-stat { display: flex; align-items: center; gap: 14px; margin: 10px 0; min-width: 0; }
.pay-stat-t { display: flex; flex-direction: column; gap: 4px; min-width: 0; font-size: 12px; color: var(--ink-2); line-height: 1.45; }
.pay-stat-t b { font-size: 20px; font-weight: 800; letter-spacing: -.01em; }
.pay-pill { display: inline-block; margin-left: 8px; padding: 2px 8px; border-radius: 10px; font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; }
.pace-legend .sw.st-blue { background: #2F8FEF; } .pace-legend .sw.st-green { background: #0CC78A; } .pace-legend .sw.st-yellow { background: #F2C400; } .pace-legend .sw.st-orange { background: #F2A33A; } .pace-legend .sw.st-red { background: #E0392B; }
.att-week .att-chips { flex-wrap: wrap; flex-shrink: 1; min-width: 0; }
.att-week .att-chip { white-space: normal; }
/* фото й відео зразка (public/samples.js, src/samples/files.js) */
.sm-files { display: flex; flex-direction: column; gap: 6px; }
.sm-tiles { display: flex; flex-wrap: wrap; gap: 6px; }
.sm-tile-w { position: relative; display: inline-flex; }
.sm-tile { position: relative; width: 68px; height: 68px; border: 0; border-radius: 12px; padding: 0; overflow: hidden; display: inline-flex; flex-direction: column; align-items: center; justify-content: flex-end; font: inherit; font-size: 10px; font-weight: 600; cursor: pointer; background: #E4E8EE; color: #586B82; }
.sm-tile.video { background: #2C3C4D; color: #fff; }
.sm-tile.add { background: #DCEBFC; color: #1B6FD6; justify-content: center; gap: 2px; line-height: 1.15; padding: 0 4px; }
.sm-tile.add[disabled] { opacity: .5; cursor: default; }
.sm-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sm-tile-cap { position: relative; align-self: stretch; padding: 2px 6px 4px; text-align: left; }
.sm-tile.photo img + .sm-tile-cap { color: #fff; background: linear-gradient(transparent, rgba(30, 42, 74, .65)); }
.sm-tile-plus { font-size: 20px; font-weight: 500; line-height: 1; }
.sm-tile-x { position: absolute; top: -5px; right: -5px; width: 24px; height: 24px; border: 2px solid #fff; border-radius: 12px; padding: 0; background: #1E2A4A; color: #fff; font-size: 10px; line-height: 1; cursor: pointer; }
.sm-viewer { --sm-ink: #1E2A4A; --sm-ink2: #586B82; --sm-coral: #F26B52; position: fixed; inset: 0; z-index: 1000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); background: rgba(15, 22, 31, .94); }
.sm-view-media { max-width: 100%; max-height: calc(100vh - 110px); max-height: calc(100dvh - 110px); border-radius: 12px; background: #000; }
.sm-view-bar { display: flex; gap: 10px; }
/* панель на телефоні в «Налаштуваннях» */
.st-navrow { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.st-navsel { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.st-navsel select { width: 100%; min-width: 0; font-size: 13px; }
@media (max-width: 560px) { .st-navsel { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* лише для варіанта 8 (public/v8.css); у звичайному вигляді сховано */

/* ---------- зразки, етап 2 (05.11.2026): замовлення підбору, еталон, каталог ---------- */
.sm-serial { font-size: 15px; font-weight: 700; letter-spacing: .01em; }
.sm-sign { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 10px; background: #FFF1B3; color: #7A5E00; font-size: 12px; font-weight: 600; }
.sm-orders { display: flex; flex-wrap: wrap; gap: 4px; }
.sm-order { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 8px; border-radius: 12px; background: var(--sm-well); color: var(--sm-ink); font-size: 11px; font-weight: 600; }
.sm-order.bad { background: #FBE3DF; color: #D8311C; }
.sm-order.ok { background: #D9F5EB; color: #0A8F62; }
.sm-order.wait { background: #FFF1B3; color: #7A5E00; }
.sm-order .sm-x { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; padding: 0 0 0 2px; line-height: 1; }
.sm-ref { font-size: 12px; color: var(--sm-ink2); }
.sm-ref b { color: var(--sm-ink); font-weight: 600; }
.sm-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.sm-select { width: 100%; min-width: 0; font: inherit; font-size: 13px; padding: 8px 10px; border: 1px solid #D5DCE5; border-radius: 10px; background: #fff; color: var(--sm-ink); }
.sm-gate { display: flex; flex-direction: column; gap: 6px; }
.sm-gate-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 8px 10px; border-radius: 10px; background: #fff; font-size: 12px; }
.sm-gate-row b { font-size: 13px; }
/* каталог: плитки еталонів — підібрано (фото) чи ще ні (сіра, як закрита ачівка) */
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.ct-tile { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 150px; border: 0; border-radius: 16px; padding: 0; overflow: hidden; background: #fff; box-shadow: var(--sm-shadow); color: var(--sm-ink); font: inherit; text-align: left; cursor: pointer; }
.ct-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ct-tile .ct-cap { position: relative; padding: 10px 12px; font-size: 12px; line-height: 1.3; }
.ct-tile.done .ct-cap { background: linear-gradient(transparent, rgba(30, 42, 74, .8)); color: #fff; padding-top: 28px; }
.ct-tile.done .ct-cap b, .ct-tile .ct-cap b { display: block; font-size: 13px; font-weight: 700; }
.ct-tile.done.nophoto { background: #DCEBFC; }
.ct-tile.done.nophoto .ct-cap { background: none; color: var(--sm-ink); padding-top: 10px; }
.ct-tile.locked { background: #E4E8EE; color: var(--sm-mute); box-shadow: none; }
.ct-tile.locked .ct-cap { color: var(--sm-mute); }
.ct-tile.locked .ct-lock { position: absolute; top: 10px; right: 12px; font-size: 18px; opacity: .6; }
.ct-tile .ct-n { position: absolute; top: 8px; left: 10px; height: 20px; padding: 0 7px; border-radius: 10px; background: rgba(255, 255, 255, .85); color: var(--sm-ink); font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; }
.ct-card { background: #fff; border-radius: 18px; padding: 16px; box-shadow: var(--sm-shadow); display: flex; flex-direction: column; gap: 10px; }
.ct-card h3 { margin: 0; font-size: 16px; }
.ct-sample { border-top: 1px solid #EEF0F3; padding-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.ct-count { font-size: 12px; color: var(--sm-ink2); }
@media (max-width: 560px) { .ct-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sm-grid2 { grid-template-columns: 1fr; } }
.st-tones { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px 16px; margin-top: 10px; }
.st-tone { display: flex; align-items: center; gap: 6px; font-size: 13px; min-width: 0; }
.st-tone .sm-wood { width: 36px; height: 36px; border-radius: 18px; }
.pt-card .sm-tone .sm-wood { width: 20px; height: 20px; border-radius: 10px; }
.st-tone span { margin-left: 3px; overflow-wrap: anywhere; }
.st-tone small { display: block; font-size: 11px; color: var(--ink-3); }

/* ---------- зразки, етап 3: «Створити підбір», чекаємо зразок, посилки (public/samples.js; макет — секція 2д робочої копії у Figma) ---------- */
.sm-step { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.sm-step-n { width: 28px; height: 28px; border-radius: 14px; background: var(--sm-soft, #DCEBFC); color: var(--sm-soft-ink, #1B6FD6); font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.sm-step b { display: block; font-size: 15px; }
.sm-opts { display: flex; flex-direction: column; gap: 6px; }
.sm-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; padding: 9px 12px; border-radius: 12px; border: 1.5px solid transparent; background: var(--well, #E4E8EE); color: inherit; font: inherit; cursor: pointer; }
.sm-opt.on { background: var(--sm-soft, #DCEBFC); border-color: var(--sm-soft-ink, #1B6FD6); }
.sm-opt.dim { opacity: .55; cursor: default; }
.sm-opt b { font-size: 13px; }
.sm-found { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 12px; background: var(--well, #E4E8EE); }
.sm-found .sm-opt { background: var(--card, #fff); }
.sm-check { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.sm-stage3 { display: flex; flex-direction: column; gap: 6px; }
.sm-cap.warn { color: #9A4B00; }
.sm-kan.k5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.sm-kan.k6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 1179px) { .sm-kan.k5, .sm-kan.k6 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 899px) { .sm-kan.k5, .sm-kan.k6 { grid-template-columns: minmax(0, 1fr); gap: 12px; } }
/* вузькі стовпчики на ПК (5–6 на дошці): довгий текст кнопок і позначок переноситься, а не вилазить за картку */
@media (min-width: 1180px) and (max-width: 1399px) { .sm-kan.k6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.sm-col .sm-row { flex-wrap: wrap; }
.sm-col .sm-btn { max-width: 100%; height: auto; min-height: 40px; padding-block: 6px; white-space: normal; line-height: 1.25; }
.sm-col .sm-btn.sm { min-height: 34px; }
.sm-col .sm-btn.link { justify-content: flex-start; text-align: left; }
.sm-col .sm-pill { max-width: 100%; height: auto; min-height: 20px; padding-block: 2px; white-space: normal; flex: 0 1 auto; line-height: 1.2; }
