/* Раздел «Агентство»: индекс здоровья аккаунтов, задачи по клиентам, экономика клиентов. */
.ag-table td { vertical-align: top; }
.ag-row { cursor: pointer; }
.ag-row:hover td { background: var(--hover); }
.ag-row:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
.ag-row.dim td { opacity: .65; }

/* health */
.ag-score { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; min-width: 2ch; display: inline-block; text-align: right; }
.ag-score.critical { color: var(--critical); }
.ag-score.warning { color: var(--warning-ink); }
.ag-score.good { color: var(--ok); }
.ag-delta { font-size: 12.5px; font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; }
.ag-delta.up { color: var(--ok); }
.ag-delta.down { color: var(--critical); }
.ag-spark { display: block; overflow: visible; }
.ag-spark path { fill: none; stroke: var(--brand); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.ag-ref { stroke: var(--ink-3); stroke-width: 1; stroke-dasharray: 3 3; opacity: .7; }
.ag-grid { stroke: var(--line); stroke-width: 1; }
.ag-drags { min-width: 260px; max-width: 420px; display: grid; gap: 4px; }
.ag-drag { font-size: 13px; }
.ag-drag .sub { line-height: 1.35; }
.ag-method { margin-top: 16px; }
.ag-method ul { margin: 8px 0 0; padding-left: 18px; display: grid; gap: 4px; max-width: 900px; }
.ag-chart { width: 100%; height: auto; display: block; }
.ag-chart text { font-size: 10.5px; fill: var(--ink-3); font-variant-numeric: tabular-nums; }
.ag-line { fill: none; stroke: var(--brand); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.ag-hit { fill: transparent; }
.ag-hit:hover { fill: color-mix(in oklch, var(--brand) 30%, transparent); }
.ag-pbar { display: inline-block; width: 72px; height: 6px; border-radius: 3px; background: var(--hover); vertical-align: middle; position: relative; overflow: hidden; }
.ag-pbar span { position: absolute; inset: 0 auto 0 0; border-radius: 3px; background: var(--ink-3); }
.ag-pbar span.good { background: var(--ok); }
.ag-pbar span.warning { background: var(--warning); }
.ag-pbar span.critical { background: var(--critical); }
.ag-parts { max-height: none !important; overflow: visible; }
.ag-parts td a { white-space: nowrap; }
.ag-pnum { display: inline-block; min-width: 3ch; margin-left: 8px; font-variant-numeric: tabular-nums; }

/* tasks */
.ag-overdue td:first-child { box-shadow: inset 3px 0 0 var(--critical); }
.ag-text { font-family: var(--font) !important; font-size: 14px !important; }
.ag-pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13.5px; line-height: 1.5; }
.ag-comment { border-left: 2px solid var(--line-2); padding: 2px 0 2px 10px; display: grid; gap: 2px; }
.ag-time-form .input[type="number"] { width: 90px; }
.ag-time-form .input[type="date"] { width: 150px; }
.ag-alert-hook p { margin: 0; }

/* economics */
.ag-loss td:first-child { box-shadow: inset 3px 0 0 var(--critical); }
.ag-cur td { background: var(--brand-soft); }
.ag-hbar { min-width: 150px; }
.ag-rate { width: 120px; }

@media (max-width: 860px) {
  .ag-drags { min-width: 200px; }
  .ag-time-form .input[type="date"], .ag-time-form .input[type="number"] { width: 100%; }
}
