/* Онбординг сервиса и согласование пакетов услуг (решения владельца от 22.10.2026): строки черновика
   с ошибками, подсказка «в справочнике есть похожая работа», отметки решения по строке и итог внизу.
   Переменные — из style.css; тёмная тема — через них же. */

/* --- Строка пакета ---------------------------------------------------------- */

tr.line-broken td { background: var(--danger-soft); }
.line-errors { margin: 4px 0 0; padding-left: 18px; color: var(--danger); font-size: .88rem; }
.line-errors li + li { margin-top: 2px; }

.hint-box {
  margin: 6px 0 0; padding: 6px 8px; border-left: 3px solid var(--accent); background: var(--accent-soft);
  border-radius: 0 var(--radius) var(--radius) 0; font-size: .88rem;
}
.hint-title { display: block; font-weight: 600; }
.hint-box ul { margin: 2px 0 0; padding-left: 18px; }
.hint-box li { overflow-wrap: anywhere; }

.plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.plain-list .badge { white-space: normal; }

/* --- Решение по строке ---------------------------------------------------------- */

.decision-cell { display: grid; gap: 6px; min-width: 220px; }
.decision-cell textarea { width: 100%; min-height: 34px; resize: vertical; }
.decision-cell .field { margin: 0; }
.decision-choice { display: flex; flex-wrap: wrap; gap: 2px 14px; margin: 0; padding: 0; border: none; }
.decision-choice .check { margin: 0; }
.choice-approve input:checked + span { color: var(--success); font-weight: 600; }
.choice-reject input:checked + span { color: var(--danger); font-weight: 600; }

.decision-footer {
  position: sticky; bottom: 0; z-index: 2; display: grid; gap: 8px; margin-top: 12px;
  border-top: 2px solid var(--accent);
}
.decision-totals { margin: 0; font-weight: 600; }
.decision-feedback:empty { display: none; }
.decision-feedback .form-error { margin: 0; }
.screen-head h2 { margin: 0; }
.package-facts { margin: 0 0 8px; }

@media (max-width: 640px) {
  /* На телефоне итог не закрепляется внизу: иначе он закрывает четверть экрана. */
  .decision-footer { position: static; }
  .decision-cell { min-width: 0; }
}
