/* ─────────────────────────────────────────────────────────────
   Панель диспетчера. Mobile-first.
   По образцу админки YouGile: токены → база → компоненты.
   ───────────────────────────────────────────────────────────── */
:root {
  --canvas: #f5f6f8;
  --surface: #ffffff;
  --surface-2: #eff1f5;
  --ink: #191b22;
  --muted: #575b68;
  --faint: #696d7a;            /* ≥ 4.5:1 даже на --surface-2 (замер аудита 16.10) */
  --border: #e4e6ec;
  --field-border: #858a97;     /* рамка полей ввода ≥ 3:1 (WCAG 1.4.11) */
  --hairline: #eceef2;

  --accent: #4549c9;
  --accent-soft: #eef0ff;

  --ok: #12754a;      --ok-soft: #e9f7ef;
  --danger: #b8302f;  --danger-soft: #fdeeee;
  --warn: #8a5f00;    --warn-soft: #fff6e0;
  --info: #2a60c4;    --info-soft: #edf3fe;
  --risk: #a34a00;    --risk-soft: #fff0e3;   /* решения с риском: прод, SSH, деньги, удаление */

  --shadow-card: 0 1px 2px rgba(25, 27, 34, .05), 0 4px 16px rgba(25, 27, 34, .05);
  --r-lg: 16px; --r-md: 12px; --r-sm: 8px;
  --tap: 44px;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #121318;
    --surface: #1b1c23;
    --surface-2: #25262f;
    --ink: #eceef4;
    --muted: #a6a9b6;
    --faint: #8f93a1;
    --field-border: #6c7080;
    --border: #2c2e38;
    --hairline: #24262f;

    --accent: #9296ff;
    --accent-soft: #23243d;

    --ok: #4cc385;      --ok-soft: #17301f;
    --danger: #ef7070;  --danger-soft: #341b1b;
    --warn: #d9a53e;    --warn-soft: #322a14;
    --info: #7aa5ec;    --info-soft: #1b2436;
    --risk: #f0a35c;    --risk-soft: #35230f;

    --shadow-card: none;
  }
}

/* ── база ─────────────────────────────────────────────────── */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--canvas); color: var(--ink);
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(66px + env(safe-area-inset-bottom));
}
a { color: var(--info); text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
::selection { background: color-mix(in srgb, var(--accent) 24%, transparent); }
input, textarea { caret-color: var(--accent); }
a:active { opacity: .7; }
code, .mono { font-family: var(--mono); font-size: 12.5px; overflow-wrap: anywhere; }

/* ── шапка ────────────────────────────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(12px + env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left));
  background: var(--canvas);
  border-bottom: 1px solid var(--hairline);
}
.topbar h1 {
  margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -.2px;
  display: flex; align-items: center; gap: 8px; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.topbar h1::before {
  content: ""; width: 10px; height: 10px; border-radius: 3px;
  background: var(--accent); transform: rotate(45deg); flex: 0 0 auto;
}

main { max-width: 680px; margin: 0 auto; padding: 16px 16px 28px; }
.section-title {
  font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .8px;
  color: var(--faint); margin: 26px 4px 10px;
}
.section-title:first-child { margin-top: 4px; }
.note { font-size: 13px; color: var(--muted); margin: 0 4px 12px; }

/* ── бейджи и теги ────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 600;
  white-space: nowrap;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-gray  { background: var(--surface-2); color: var(--muted); }
.badge-green { background: var(--ok-soft); color: var(--ok); }
.badge-red   { background: var(--danger-soft); color: var(--danger); }
.badge-blue  { background: var(--info-soft); color: var(--info); }
.badge-amber { background: var(--warn-soft); color: var(--warn); }
.badge-violet { background: var(--accent-soft); color: var(--accent); }
.badge.live::before { display: none; }
.spin { display: inline-block; width: 10px; height: 10px; border: 2px solid currentColor;
  border-top-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } }

.chiprow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tag {
  padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 650;
  letter-spacing: .2px; background: var(--surface-2); color: var(--muted); white-space: nowrap;
}
.tag-critical { background: var(--danger-soft); color: var(--danger); }
.tag-high     { background: var(--warn-soft); color: var(--warn); }
.tag-low      { color: var(--faint); }
.tag-id { font-family: var(--mono); font-weight: 600; background: transparent; padding-left: 0; color: var(--faint); }

/* ── фильтры ──────────────────────────────────────────────── */
.controls { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px; margin: 0 -2px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; min-height: 44px; padding: 10px 16px; border-radius: 999px; display: inline-flex; align-items: center;
  border: 1px solid var(--border); background: var(--surface); color: var(--muted);
  font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer;
}
.chip .n { color: var(--faint); font-weight: 600; margin-left: 4px; font-variant-numeric: tabular-nums; }
.chip.active { background: var(--ink); color: var(--canvas); border-color: var(--ink); }
.chip.active .n { color: inherit; opacity: .7; }
.selects { display: flex; gap: 8px; }
.select {
  flex: 1; min-width: 0; min-height: var(--tap);
  padding: 10px 36px 10px 12px; font: inherit; font-size: 16px; font-weight: 500;
  color: var(--ink); background-color: var(--surface);
  border: 1px solid var(--field-border); border-radius: var(--r-md); text-overflow: ellipsis;
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4' fill='none' stroke='%236b6f7c' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.search {
  width: 100%; min-height: var(--tap); padding: 10px 14px; font: inherit; font-size: 16px;
  border: 1px solid var(--field-border); border-radius: var(--r-md);
  background: var(--surface); color: var(--ink);
}
.search:focus-visible, .select:focus-visible, .chip:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ── карточки ─────────────────────────────────────────────── */
.cards { display: flex; flex-direction: column; gap: 10px; }
.card {
  display: block; position: relative; color: inherit;
  background: var(--surface); border: 1px solid var(--hairline);
  border-radius: var(--r-lg); padding: 14px 16px;
  box-shadow: var(--shadow-card);
}
a.card:active { opacity: .75; }
.card h3 { margin: 6px 0 2px; font-size: 15px; font-weight: 650; line-height: 1.35; overflow-wrap: anywhere; }
.card .meta { color: var(--muted); font-size: 13px; margin-top: 4px; overflow-wrap: anywhere; }
.card .desc { color: var(--muted); font-size: 13.5px; margin-top: 4px; overflow-wrap: anywhere; }
.card.accent-ok { border-color: color-mix(in srgb, var(--ok) 32%, var(--hairline)); }
.card.accent-err { border-color: color-mix(in srgb, var(--danger) 38%, var(--hairline)); }
.card.accent-run { border-color: color-mix(in srgb, var(--info) 38%, var(--hairline)); }
.card.accent-wait { border-color: color-mix(in srgb, var(--warn) 32%, var(--hairline)); }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* ── обзор ────────────────────────────────────────────────── */
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 560px) { .stat-grid { grid-template-columns: repeat(3, 1fr); } }
.stat {
  display: block; color: inherit;
  background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--r-lg);
  padding: 12px 14px; box-shadow: var(--shadow-card);
}
.stat .num { font-size: 26px; font-weight: 750; letter-spacing: -.5px; font-variant-numeric: tabular-nums; line-height: 1.2; }
.stat .lbl { font-size: 12px; font-weight: 600; color: var(--muted); margin-top: 2px; }
.stat.hot .num { color: var(--accent); }
.stat.bad .num { color: var(--danger); }
.meter { background: var(--surface-2); border-radius: 5px; height: 8px; margin-top: 10px; overflow: hidden; }
.meter > i { display: block; height: 100%; border-radius: 5px; background: var(--accent); }
.meter.over > i { background: var(--danger); }

/* ── карточка задачи ──────────────────────────────────────── */
.back { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding-right: 12px; font-weight: 600; font-size: 14px; }
.task-head h2 { margin: 8px 0 6px; font-size: 19px; line-height: 1.3; letter-spacing: -.2px; overflow-wrap: anywhere; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; font-size: 13.5px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.prose { font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.prose.muted { color: var(--muted); }
.quote {
  margin: 6px 0 0; padding: 9px 12px; border-radius: var(--r-md);
  background: var(--accent-soft);
  font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere;
}
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 12px 18px; font-size: 13.5px; }
.timeline li::before { content: ""; position: absolute; left: 3px; top: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--faint); }
.timeline li::after { content: ""; position: absolute; left: 6px; top: 16px; bottom: 0; width: 1px; background: var(--border); }
.timeline li:last-child::after { display: none; }
.timeline li.newest::before { background: var(--accent); }
.timeline .when { color: var(--faint); font-size: 12px; font-variant-numeric: tabular-nums; }
.timeline .why { color: var(--muted); overflow-wrap: anywhere; }
.err-text { color: var(--danger); font-size: 13px; margin-top: 6px; overflow-wrap: anywhere; white-space: pre-wrap; }
ul.plain { margin: 4px 0 0; padding-left: 18px; font-size: 13.5px; }
ul.plain li { margin: 2px 0; overflow-wrap: anywhere; }
details.more { margin-top: 8px; font-size: 13.5px; }
details.more summary { cursor: pointer; color: var(--info); font-weight: 600; min-height: 44px; display: flex; align-items: center; }
.field-label { font-size: 12px; font-weight: 600; color: var(--faint); text-transform: uppercase; letter-spacing: .5px; margin: 10px 0 2px; }

/* ── таб-бар ──────────────────────────────────────────────── */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex;
  background: var(--surface);
  border-top: 1px solid var(--hairline);
  padding-bottom: env(safe-area-inset-bottom);
}
/* Safari на iOS 26 рисует страницу и под своей прозрачной нижней панелью: продлеваем фон вкладок
   вниз за край, чтобы между ними и краем экрана не просвечивали карточки. */
.tabbar::after {
  content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 50vh;
  background: var(--surface); pointer-events: none;
}
.tabbtn {
  flex: 1 1 0; min-width: 0; min-height: 58px; color: var(--muted);
  font-size: 11px; font-weight: 600; letter-spacing: -.1px; position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  white-space: nowrap; overflow: hidden;
}
.tabbtn svg { width: 22px; height: 22px; stroke: currentColor; fill: none;
  stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tabbtn.active { color: var(--accent); }
@media (min-width: 420px) { .tabbtn { font-size: 11.5px; } }
.tabbar-inner { display: flex; width: 100%; max-width: 680px; margin: 0 auto; }
.tabbtn .count {
  position: absolute; top: 6px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px; background: var(--danger); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px;
  text-align: center; font-variant-numeric: tabular-nums;
}
@media (prefers-color-scheme: dark) { .tabbtn .count { color: #11121a; } }

/* ── состояния ────────────────────────────────────────────── */
.skeleton { height: 84px; border-radius: var(--r-lg);
  background: linear-gradient(100deg, var(--surface-2) 30%, var(--surface) 50%, var(--surface-2) 70%);
  background-size: 200% 100%; animation: shim 1.3s infinite; border: 1px solid var(--hairline); }
@keyframes shim { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .skeleton { animation: none; } }
.empty { text-align: center; color: var(--muted); padding: 32px 20px; font-size: 14px;
  background: var(--surface); border: 1px dashed var(--border); border-radius: var(--r-lg); }
.plate { padding: 11px 14px; border-radius: var(--r-md); font-size: 13.5px; font-weight: 500; }
.plate-error { background: var(--danger-soft); color: var(--danger); }
.plate-info { background: var(--surface-2); color: var(--muted); }
.btn {
  min-height: var(--tap); padding: 10px 18px; border-radius: var(--r-md); font: inherit;
  font-size: 14.5px; font-weight: 650; border: 0; cursor: pointer;
  background: var(--surface-2); color: var(--ink); margin-top: 10px;
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.hidden { display: none !important; }

/* ── решения владельца ────────────────────────────────────── */
.decide {
  background: var(--surface); border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--hairline));
  border-radius: var(--r-lg); padding: 14px 16px 16px; box-shadow: var(--shadow-card);
}
.decide-review { border-color: color-mix(in srgb, var(--info) 35%, var(--hairline)); }
.decide.risky { border-color: color-mix(in srgb, var(--risk) 60%, var(--hairline)); }
.decide-plain { border-color: var(--hairline); }
.decide-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.decide-open { font-size: 14px; font-weight: 600; min-height: 44px; min-width: 44px; padding: 0 2px 0 12px; display: inline-flex; align-items: center; justify-content: flex-end; flex: 0 0 auto; }
.decide h3 { margin: 8px 0 2px; font-size: 16px; font-weight: 650; line-height: 1.35; overflow-wrap: anywhere; }

.decide .meta { margin-top: 8px; }
.decide-actions { display: flex; gap: 8px; margin-top: 14px; }
.decide-actions .btn { flex: 1 1 0; margin-top: 0; }
.decide-actions[hidden], .decide-form[hidden] { display: none; }
.decide-form { margin-top: 12px; }
.decide-form .field-label { display: block; margin-top: 0; }
.task-actions { margin: 4px 0 18px; }
.clamp { display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }

.btn { transition: background-color .15s ease-out, color .15s ease-out, transform .1s ease-out; }
.btn:active:not(:disabled) { transform: scale(.98); }
.btn:disabled { cursor: default; opacity: .55; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-quiet { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--border); }
.btn-quiet-danger { color: var(--danger); }
.btn.busy { position: relative; color: transparent; transition: none; }
.btn.busy::after {
  content: ""; position: absolute; inset: 0; margin: auto; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid #fff; border-top-color: transparent; animation: spin .8s linear infinite;
}
.btn-quiet.busy::after { border-color: var(--muted); border-top-color: transparent; }
@media (prefers-color-scheme: dark) { .btn-primary, .btn-danger { color: #11121a; } .btn.busy::after { border-color: #11121a; border-top-color: transparent; } }

.input {
  width: 100%; min-height: 88px; padding: 10px 12px; resize: vertical;
  font: inherit; font-size: 16px; line-height: 1.45; color: var(--ink);
  background: var(--surface); border: 1px solid var(--field-border); border-radius: var(--r-md);
}
.input::placeholder { color: var(--faint); }
.input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.input.invalid { border-color: var(--danger); }
.chips.quick { flex-wrap: wrap; overflow: visible; margin-top: 8px; }
.chips.quick .chip { min-height: 44px; font-size: 13.5px; text-align: left; white-space: normal; }
.plate-ok { background: var(--ok-soft); color: var(--ok); }

.toast {
  position: fixed; left: 16px; right: 16px; bottom: calc(70px + env(safe-area-inset-bottom)); z-index: 30;
  max-width: 560px; margin: 0 auto; padding: 12px 16px; border-radius: var(--r-md);
  font-size: 14px; font-weight: 600; line-height: 1.4;
  background: var(--ink); color: var(--canvas);
  box-shadow: 0 6px 24px rgba(25, 27, 34, .22);
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity .2s ease-out, transform .25s cubic-bezier(.16, 1, .3, 1);
}
.toast.show { opacity: 1; transform: none; }
.toast-error { background: var(--danger); color: #fff; }
@media (prefers-reduced-motion: reduce) { .toast, .btn { transition: none; } }

/* ── вход ─────────────────────────────────────────────────── */
body.login-page { padding-bottom: 0; min-height: 100svh; display: grid; place-items: center; }
.login { width: 100%; max-width: 360px; padding: 32px 20px calc(32px + env(safe-area-inset-bottom)); text-align: center; }
.login-mark { border-radius: 18px; box-shadow: 0 4px 14px rgba(25, 27, 34, .16); }
.login h1 { margin: 16px 0 24px; font-size: 22px; font-weight: 700; letter-spacing: -.3px; }
.login form { text-align: left; display: flex; flex-direction: column; gap: 10px; }
.login .field-label { margin: 0; }
.login .note { text-align: center; margin-top: 16px; }
.btn-block { width: 100%; margin-top: 4px; }
.settings .decide-actions:empty { display: none; }
.runner { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; margin: 2px 4px 0; }
.runner .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.runner.ok { color: var(--ok); }
.runner.off { color: var(--warn); }

/* ── обзор: сводка одной строкой ──────────────────────────── */
.summary { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 14px 0 4px; }
.summary a {
  display: inline-flex; align-items: baseline; gap: 5px; min-height: 44px; padding: 10px 14px;
  border-radius: 999px; background: var(--surface); border: 1px solid var(--hairline); color: var(--muted);
  font-size: 13.5px; font-weight: 600;
}
.summary a b { color: var(--ink); font-size: 15px; font-variant-numeric: tabular-nums; }
.summary a.hot b { color: var(--accent); }
.summary a.bad b { color: var(--danger); }

/* ── «всё разобрано» ─────────────────────────────────────── */
.all-clear {
  display: flex; align-items: center; gap: 14px; padding: 18px 16px;
  background: var(--ok-soft); color: var(--ok); border-radius: var(--r-lg);
}
.all-clear svg { width: 28px; height: 28px; flex: 0 0 auto; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.all-clear strong { display: block; font-size: 15px; }
.all-clear span { font-size: 13px; color: var(--ink); opacity: .75; }

/* ── текст действия: обрезка вместо прокрутки внутри ─────── */
.quote.clamped {
  max-height: calc(14px * 1.5 * 6 + 18px); overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent);
  mask-image: linear-gradient(to bottom, #000 60%, transparent);
}
.show-all { background: none; border: 0; padding: 0 2px; min-height: 44px; font: inherit; font-size: 14px; font-weight: 600; color: var(--info); cursor: pointer; }

/* ── риск ─────────────────────────────────────────────────── */
.tag-risk { background: var(--risk-soft); color: var(--risk); }
.risk-note { margin-top: 10px; padding: 10px 12px; border-radius: var(--r-md); background: var(--risk-soft); color: var(--risk); font-size: 13.5px; font-weight: 600; }
.btn-primary.risk { background: var(--risk); }

/* ── подтверждение: «Да, разрешить» и полоса 4 с ───────────── */
.btn.armed { background: var(--ink); color: var(--canvas); position: relative; overflow: hidden; }
.btn.armed::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 3px; width: 100%;
  background: currentColor; opacity: .6; transform-origin: left; animation: arm-countdown 4s linear forwards;
}
@keyframes arm-countdown { from { transform: scaleX(1); } to { transform: scaleX(0); } }
@media (prefers-reduced-motion: reduce) { .btn.armed::after { animation: none; opacity: .35; } }
.arm-hint { margin-top: 8px; font-size: 13px; color: var(--muted); }

/* ── ошибки форм — у поля ─────────────────────────────────── */
.field-error { margin-top: 6px; font-size: 13.5px; font-weight: 600; color: var(--danger); }
.input[aria-invalid="true"] { border-color: var(--danger); }

/* ── шапка: «обновлено» — кнопка ──────────────────────────── */
button.badge { border: 0; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; min-height: 32px; }

/* ── технические детали запуска ───────────────────────────── */
details.tech { margin-top: 6px; font-size: 13px; }
details.tech summary { cursor: pointer; color: var(--muted); min-height: 44px; display: flex; align-items: center; font-weight: 600; }
.more-row { display: flex; justify-content: center; margin-top: 12px; }
.proj-tasks { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; font-size: 14px; }
.show-pw { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 14px; color: var(--muted); cursor: pointer; }
.show-pw input { width: 18px; height: 18px; accent-color: var(--accent); }

/* ── новая задача ─────────────────────────────────────────── */
.new-task { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 6px; }
.new-task svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2.4; stroke-linecap: round; }
.controls + .new-task, .new-task + .controls { margin-top: 0; }
.new-card { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.new-card .field-label { margin-top: 10px; }
.new-card .field-label:first-child { margin-top: 0; }
.new-card .section-title { margin: 0 0 4px; }
.new-card .decide-actions { margin-top: 12px; }
.pw-change { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.pw-change .field-label { margin-top: 6px; }
.pw-change[hidden], #step-login[hidden], #step-change[hidden] { display: none; }
#step-login, #step-change { display: flex; flex-direction: column; gap: 10px; }
#step-change .note { text-align: left; margin: 0 0 4px; }

/* ── диктовка ─────────────────────────────────────────────── */
.dictate { display: inline-flex; align-items: center; justify-content: center; gap: 8px; align-self: flex-start; margin-top: 8px; padding: 10px 16px; }
.dictate svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.dictate.listening { color: var(--danger); box-shadow: inset 0 0 0 1.5px var(--danger); }
.dictate.listening svg { animation: listen 1.2s ease-in-out infinite; }
@keyframes listen { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .dictate.listening svg { animation: none; } }
