/* Склад (02.10.2026). Только токены темы — захардкоженные цвета светятся в тёмной теме. */
.wh-toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.wh-search { flex: 0 1 280px; width: auto; }

/* панель счётчиков над доской (как в amoCRM: без задач / просрочено / на сегодня) */
.wh-stats { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.wh-stat { border: 1px solid var(--border); background: var(--surface); color: var(--text-2); border-radius: var(--r-pill);
  padding: 5px 12px; font: 600 12px var(--font-body); cursor: pointer; transition: .12s; }
.wh-stat b { font-family: var(--font-mono); color: var(--text); }
.wh-stat:hover { border-color: var(--border-strong); }
.wh-stat.on { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.wh-stat.late b { color: var(--danger-text); }
.wh-stat.today b { color: var(--success-text); }

/* доска: три колонки на всю ширину, на узком экране — горизонтальная прокрутка */
.wh-board { display: grid; grid-template-columns: repeat(3, minmax(260px, 1fr)); gap: 16px; align-items: start; overflow-x: auto; padding-bottom: 12px; }
.wh-col { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-lg); min-width: 0; }
.wh-col-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.wh-col-body { padding: 10px; display: flex; flex-direction: column; gap: 10px; min-height: 80px; border-radius: var(--r-md); }
.wh-col-body.drag-over { background: var(--accent-soft); outline: 2px dashed var(--accent-soft-border); outline-offset: -6px; }
.wh-col-body .empty { padding: 18px 8px; }

.wh-card { margin-bottom: 0; }
.wh-card.dragging { opacity: .4; }
.wh-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.wh-task { margin-top: 4px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.wh-meta { display: inline-flex; align-items: center; gap: 4px; font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); }
.wh-meta svg { width: 12px; height: 12px; }
.wh-next { margin-top: 10px; width: 100%; justify-content: center; }

/* индикатор срока */
.wh-due { display: inline-flex; align-items: center; font-size: 11px; font-weight: 600; font-family: var(--font-mono);
  padding: 2px 8px; border-radius: var(--r-pill); color: var(--text-muted); white-space: nowrap; }
.wh-due.muted { padding-left: 0; }
.wh-due.late { background: var(--danger-soft); color: var(--danger-text); border: 1px solid var(--danger-border); }
.wh-due.today { background: var(--success-soft); color: var(--success-text); border: 1px solid var(--success-border); }

.wh-tcell { font-size: 12px; max-width: 520px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* карточка заказа */
.wh-task-full { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.55; color: var(--text); margin-top: 8px; }
.wh-lbl { font-size: 10px; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; }
.wh-status-sel { width: auto; flex: 0 1 190px; }
.wh-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.wh-item:last-of-type { border-bottom: none; }
.wh-item-name { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 13.5px; }
.wh-item.done .wh-item-name { color: var(--text-muted); text-decoration: line-through; }
.wh-item-by { font-size: 11px; white-space: nowrap; }
.wh-chk { width: 22px; height: 22px; flex: none; border: 1.5px solid var(--border-strong); border-radius: 6px; background: var(--surface);
  color: var(--on-accent); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.wh-chk svg { width: 14px; height: 14px; }
.wh-chk.on { background: var(--accent); border-color: var(--accent); }
.wh-chk:disabled { cursor: default; opacity: .6; }
.wh-item .btn-xs svg { width: 13px; height: 13px; }

/* переписка: строка о смене статуса и вложения */
.wh-sys { text-align: center; font-size: 11.5px; color: var(--text-muted); margin: 4px 0 12px; }
.wh-sys b { font-weight: 600; color: var(--text-2); }
.wh-img { display: block; max-width: 220px; max-height: 180px; border-radius: var(--r-sm); border: 1px solid var(--border); margin-top: 6px; }
.wh-clip { width: 13px; height: 13px; }
.deal-chat-input .btn:first-of-type { width: 38px; padding: 0; }
#wh-text { flex: 1; min-width: 0; }

/* диалог создания/правки */
.wh-dialog { max-width: 560px; }
.wh-form { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.wh-form .field label { font-size: 12px; font-weight: 600; color: var(--text-2); }
.wh-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.wh-form textarea.inp { min-height: 0; }

@media (max-width: 900px) {
  .wh-board { grid-template-columns: repeat(3, 280px); }
  .wh-form-row { grid-template-columns: 1fr; }
}
