/* «ИИ-бухгалтер» → «Несданные 091» (ТЗ Жоогазын «Тест кейс по 091 на 27.11.26») — ai-accountant-dn.js (window.ACCN).
   Каркас, плитки, чипы, кнопки — классы раздела (ai-accountant.css, ai-accountant-reports.css, ai-accountant-contracts.css): здесь только
   своё — карточка клиента, строка периода, цитата, подсказка в карточке клиента. Совет ИИ у строки периода и у цитаты — «ровная планка
   внутри» (::before, цвет через --bar), без border-left. Цвета — токены раздела (--acc-*), обе темы. */

.accn { display: flex; flex-direction: column; gap: 14px; }
.accn-top { padding: 12px; }
.accn-list { display: flex; flex-direction: column; gap: 10px; }

/* клиент */
.accn-cl { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border: 1px solid var(--acc-line); border-radius: var(--acc-radius); background: var(--card-bg); min-width: 0; }
.accn-ch { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px 14px; flex-wrap: wrap; }
.accn-who { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1 1 320px; }
.accn-name { align-self: flex-start; border: 0; background: none; padding: 0; color: var(--text-color); font: inherit; font-size: 15px; font-weight: 700; line-height: 1.3; text-align: left; cursor: pointer; }
.accn-name:hover { color: var(--primary-color); text-decoration: underline; }
.accn-sub { display: flex; align-items: center; gap: 4px 12px; flex-wrap: wrap; font-size: 12px; color: var(--text-muted); }
.accn-sub > span { display: inline-flex; align-items: center; gap: 4px; }
.accn-sub > em { font-style: normal; }
.accn-acts { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.accn-acts .acc-btn .acc-wait i, .accn-pa .acc-btn .acc-wait i { width: 13px; height: 13px; }
.accn-sum { margin: 0; font-size: 13px; line-height: 1.5; color: var(--text-color); }
.accn-cf { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-size: 11.5px; line-height: 1.4; color: var(--text-muted); }

/* период: совет ИИ — ровная планка внутри слева */
.accn-pers { display: flex; flex-direction: column; gap: 6px; }
.accn-per { --bar: var(--acc-line); position: relative; display: grid; grid-template-columns: 190px minmax(0, 1fr) auto; gap: 8px 14px; align-items: start;
    padding: 10px 12px 10px 16px; border: 1px solid var(--acc-line); border-radius: 10px; background: var(--acc-soft); }
.accn-per::before { content: ''; position: absolute; left: 0; top: 12px; bottom: 12px; width: 4px; border-radius: 0 4px 4px 0; background: var(--bar); pointer-events: none; }
.accn-per.r-set_dn { --bar: var(--acc-ok); }
.accn-per.r-file { --bar: var(--acc-bad); }
.accn-per.r-ask { --bar: var(--acc-warn); }
.accn-pl { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 12px; color: var(--text-muted); line-height: 1.35; }
.accn-pl b { font-size: 13.5px; color: var(--text-color); }
.accn-bc { color: var(--acc-info); font-weight: 600; }
.accn-pm { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.accn-pm p { margin: 0; font-size: 13px; line-height: 1.5; }
.accn-tags { display: flex; align-items: center; gap: 6px 8px; flex-wrap: wrap; }
.accn-tags em { font-style: normal; font-size: 11.5px; color: var(--text-muted); }
.accn-tags em.accn-auto { display: inline-flex; align-items: center; gap: 4px; color: var(--acc-ai); font-weight: 600; }
.accn-pa { display: flex; align-items: flex-start; }
.accn-pa .acc-btn { height: 30px; padding: 0 10px; font-size: 12.5px; }
.acc-btn.quiet { color: var(--text-muted); }

/* цитата из переписки: ровная планка внутри */
.accn-q { position: relative; margin: 0; padding: 7px 10px 7px 14px; border-radius: 8px; background: var(--card-bg); border: 1px solid var(--acc-line); font-size: 12.5px; line-height: 1.5; color: var(--text-color); }
.accn-q::before { content: ''; position: absolute; left: 0; top: 6px; bottom: 6px; width: 3px; border-radius: 0 3px 3px 0; background: var(--acc-ai); pointer-events: none; }
.accn-q cite { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--text-muted); }
.accn-notes { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 3px; }
.accn-notes li { display: flex; align-items: flex-start; gap: 5px; font-size: 12px; line-height: 1.4; color: var(--text-muted); }
.accn-notes li svg, .accn-rev svg { flex: none; margin-top: 2px; }
.accn-rev { display: flex; align-items: flex-start; gap: 5px; font-size: 12px; line-height: 1.4; color: var(--acc-warn); }

/* подсказка в карточке клиента → «Отчёты», под галочкой «Деятельность не велась» (вне раздела — токены из .acc-scope) */
.accn-hint { --bar: var(--acc-ai); position: relative; display: flex; align-items: flex-start; gap: 8px; margin: 0 0 8px; padding: 8px 10px 8px 14px;
    border: 1px solid var(--acc-ai-line); border-radius: 8px; background: var(--acc-ai-bg); font-size: 12.5px; line-height: 1.45; color: var(--text-color); }
.accn-hint::before { content: ''; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--bar); pointer-events: none; }
.accn-hint.r-set_dn { --bar: var(--acc-ok); }
.accn-hint.r-file { --bar: var(--acc-bad); }
.accn-hint.r-ask { --bar: var(--acc-warn); }
.accn-h-ic { display: inline-flex; flex: none; margin-top: 1px; color: var(--acc-ai); }
.accn-h-b { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.accn-h-who, .accn-h-x { color: var(--text-muted); }
.accn-h-x { font-size: 12px; }
.accn-h-a { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.accn-h-btn { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px; border: 1px solid var(--acc-ok); border-radius: 7px; background: var(--card-bg); color: var(--acc-ok); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.accn-h-btn:hover { background: var(--acc-ok-bg); }
.accn-h-btn:disabled { opacity: .6; cursor: default; }
.accn-h-btn .acc-wait i { width: 12px; height: 12px; }

@media (max-width: 900px) {
    .accn-per { grid-template-columns: minmax(0, 1fr) auto; }
    .accn-pl { grid-column: 1 / 2; flex-direction: row; flex-wrap: wrap; gap: 2px 10px; }
    .accn-pm { grid-column: 1 / -1; grid-row: 2; }
    .accn-pa { grid-column: 2; grid-row: 1; }
}
@media (max-width: 720px) {
    .accn .acc-ctl-hero-main > .acc-scen-ic { display: none; }
    .accn-cl { padding: 12px; }
    .accn-acts { width: 100%; }
    .accn-acts .acc-btn.primary { flex: 1; }
    .accn-pl b { width: 100%; }
}
