/* =====================================================================
   TT2S — фирменный стиль (brand.css)
   Основа для всех страниц сайта. Лендинг (index.html) — эталон: новые и
   переделываемые страницы берут токены и компоненты отсюда, а не
   переопределяют цвета и шрифты у себя.

   Шрифты: Unbounded (заголовки и «крупные» подписи) и
   Golos Text (текст). Подключаются на странице через Google Fonts.
   ===================================================================== */

:root {
  /* цвета */
  --tt-bg: #0c0c0e;
  --tt-bg-2: #111114;
  --tt-surface: #16161a;
  --tt-surface-2: #1c1c21;
  --tt-line: rgba(255, 255, 255, 0.09);
  --tt-line-strong: rgba(255, 255, 255, 0.18);
  --tt-ink: #f4f2f6;
  --tt-ink-soft: #cfc9d6;
  --tt-ink-muted: #a29cac;
  --tt-ink-faint: #958f9f;
  --tt-accent: #ff7ab8;          /* фирменный розовый */
  --tt-accent-deep: #e2559a;
  --tt-accent-ink: #0c0c0e;      /* текст на розовом */
  --tt-violet: #8b6cff;          /* второй акцент — фокус, редкие акценты */
  --tt-mint: #7be0ae;
  --tt-sky: #7ab8ff;
  --tt-sun: #e0c97a;

  /* шрифты */
  --tt-font-display: 'Unbounded', system-ui, sans-serif;
  --tt-font-text: 'Golos Text', system-ui, sans-serif;
  --tt-font-mono: 'TT2S Mono', ui-monospace, Consolas, monospace;

  /* скругления и отступы */
  --tt-r-sm: 12px;
  --tt-r-md: 18px;
  --tt-r-lg: 28px;
  --tt-r-xl: 40px;
  --tt-gutter: clamp(20px, 4vw, 48px);
  --tt-max: 1240px;

  /* тени */
  --tt-shadow-card: 0 24px 60px rgba(0, 0, 0, 0.35);
  --tt-shadow-accent: 0 20px 60px color-mix(in srgb, var(--tt-accent) 35%, transparent);
  /* одна тень для окон и выпадающих панелей (окно подтверждения, тосты,
     каталог, меню «⋯», панели акцента и громкости в кабинете) */
  --tt-shadow-pop: 0 24px 60px rgba(0, 0, 0, 0.4);

  /* служебные оттенки, которые различаются в светлой и тёмной темах */
  --tt-accent-text: var(--tt-accent);          /* акцент, которым пишут текст */
  --tt-dot: rgba(255, 255, 255, 0.07);         /* точки фоновой сетки */
  --tt-glass: rgba(12, 12, 14, 0.72);          /* полупрозрачная шапка */
  --tt-fill: rgba(255, 255, 255, 0.05);        /* лёгкая подложка (чипы) */
  --tt-fill-strong: rgba(255, 255, 255, 0.16); /* выключенный переключатель */
  --tt-line-input: var(--tt-line-strong);      /* рамка кнопки и поля: в светлой теме темнее, контраст ≥ 3:1 */
  --tt-line-field: rgba(255, 255, 255, 0.36);  /* рамка поля ввода и select: ≥ 3:1 к фону и поверхностям (задача 23) */
  --tt-ok: #7be0ae; --tt-warn: #e0c97a; --tt-bad: #ff9a9a;

  /* --- токены v2 (план 2809): инструмент — кабинет, доки, /youtube, админка ---
     Значения обеих тем живут только здесь; кабинет (dashboard.css) держит
     на них алиасы со своими старыми именами. */
  --tt-surface-3: #27272e;                     /* третья ступень поверхности (наведение) */
  --tt-field: #0e0e11;                         /* фон поля ввода */
  --tt-glass-chip: rgba(22, 22, 26, 0.94);     /* плавающие чипы и плашки поверх контента */
  --tt-line-faint: rgba(255, 255, 255, 0.06);
  --tt-line-bold: rgba(255, 255, 255, 0.42);   /* наведение, выбранное, чекбоксы; ≥ 3:1 (задача 23) */
  --tt-line-dash: rgba(255, 255, 255, 0.16);   /* пунктир пустых мест */
  --tt-scrim: rgba(6, 6, 8, 0.74);             /* затемнение под окном */
  --tt-code-bg: rgba(255, 255, 255, 0.08);
  --tt-ok-bg: #12261c; --tt-warn-bg: #2a2414; --tt-bad-bg: #2a1418;
  --tt-live: #ff4d5e;                          /* только индикатор «в эфире» */
  --tt-live-bg: #2e1519;
  --tt-focus: var(--tt-violet);
  /* стекло плиток пульта (план 2909): заливка, обводка, блик, кромка, тень;
     -off — выключенная плитка (темнее, без блика и тени). --tt-glass выше —
     другое, это шапка. --tt-glow-* — яркость мотива функции под стеклом */
  --tt-pane: rgba(255, 255, 255, 0.055);
  --tt-pane-hover: rgba(255, 255, 255, 0.085);
  --tt-pane-off: rgba(0, 0, 0, 0.28);
  --tt-pane-edge: rgba(255, 255, 255, 0.14);
  --tt-pane-edge-off: rgba(255, 255, 255, 0.10);
  --tt-pane-sheen: linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0) 55%);
  --tt-pane-hi: inset 0 1px 0 rgba(255, 255, 255, 0.10);
  --tt-pane-drop: 0 10px 32px rgba(0, 0, 0, 0.30);
  --tt-glow-on: 0.42; --tt-glow-off: 0.08;
  --tt-off-opacity: 0.72;
  --tt-pane-cap: rgba(255, 255, 255, 0.12);    /* подложка значка на стекле */
  --tt-pane-inset: rgba(255, 255, 255, 0.045); /* ряд или вложенный блок на стекле (план 3009) */
  --tt-screen: rgba(0, 0, 0, 0.30);            /* тёмная вставка «монитор», текст в ней всегда светлый */
  --tt-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a29cac' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");

  /* отступы */
  --tt-sp-1: 4px; --tt-sp-2: 8px; --tt-sp-3: 12px; --tt-sp-4: 16px; --tt-sp-5: 20px;
  --tt-sp-6: 24px; --tt-sp-7: 32px; --tt-sp-8: 40px; --tt-sp-9: 56px; --tt-sp-10: 80px;
  /* кегль: инструмент */
  --tt-fs-xs: 12px; --tt-fs-sm: 13.5px; --tt-fs-base: 15px; --tt-fs-md: 17px; --tt-fs-lg: 20px; --tt-fs-xl: 28px;
  /* кегль: витрина (display — как h1 лендинга; h1/h2/h3 — как .tt-h1/.tt-h2/.tt-h3) */
  --tt-fs-display: clamp(40px, 7.4vw, 104px);
  --tt-fs-h1: clamp(32px, 4.6vw, 60px);
  --tt-fs-h2: clamp(34px, 5vw, 64px);
  --tt-fs-h3: clamp(19px, 2vw, 23px);
  /* скругления инструмента (--tt-r-sm/md/lg/xl — витрина) */
  --tt-r-ctl: 10px; --tt-r-box: 14px; --tt-r-panel: 20px;
  /* высоты кнопок и полей */
  --tt-h-sm: 32px; --tt-h-md: 40px; --tt-h-lg: 48px;
  /* движение */
  --tt-dur-1: 120ms; --tt-dur-2: 180ms; --tt-dur-3: 320ms;
  --tt-ease: cubic-bezier(.2, .7, .2, 1);
  /* слои */
  --tt-z-topbar: 50; --tt-z-drawer: 60; --tt-z-scrim: 70; --tt-z-toast: 1100;

  color-scheme: dark;

  --accent: var(--tt-accent); /* совместимость со старыми страницами */
}

/* Светлая тема. Включается атрибутом <html data-theme="light">, который
   ставит /theme-site.js (в кабинете — theme-early.js): выбор кнопкой
   «солнце/луна» в шапке, без выбора — тема системы. */
html[data-theme="light"] {
  color-scheme: light;
  --tt-bg: #f3f1f6;
  --tt-bg-2: #ebe8f0;
  --tt-surface: #ffffff;
  --tt-surface-2: #efedf2;
  --tt-line: rgba(22, 18, 30, 0.10);
  --tt-line-strong: rgba(22, 18, 30, 0.20);
  --tt-ink: #1c1a20;
  --tt-ink-soft: #3f3a47;
  --tt-ink-muted: #57525f;
  --tt-ink-faint: #5f5a68;
  --tt-accent-text: color-mix(in oklab, var(--tt-accent) 42%, #1b0f18);
  --tt-sky: #2f6fbf; --tt-mint: #197a4a; --tt-sun: #8a6a12;
  --tt-dot: rgba(22, 18, 30, 0.07);
  --tt-glass: rgba(243, 241, 246, 0.78);
  --tt-fill: rgba(22, 18, 30, 0.04);
  --tt-fill-strong: rgba(22, 18, 30, 0.16);
  --tt-ok: #156636; --tt-warn: #6b5312; --tt-bad: #a02828;
  --tt-shadow-card: 0 18px 44px rgba(40, 28, 60, 0.10);
  --tt-shadow-pop: 0 16px 44px rgba(40, 28, 60, 0.18);
  --tt-line-input: rgba(22, 18, 30, 0.5);
  --tt-line-field: var(--tt-line-input);
  /* токены v2 */
  --tt-surface-3: #e7e4ec;
  --tt-field: #faf9fc;
  --tt-glass-chip: rgba(255, 255, 255, 0.96);
  --tt-line-faint: rgba(22, 18, 30, 0.07);
  --tt-line-bold: rgba(22, 18, 30, 0.62);
  --tt-line-dash: rgba(22, 18, 30, 0.18);
  --tt-scrim: rgba(20, 18, 24, 0.45);
  --tt-code-bg: rgba(22, 18, 30, 0.06);
  --tt-ok-bg: #d9f5e4; --tt-warn-bg: #fbeecb; --tt-bad-bg: #ffe3e3;
  --tt-live: #d0283a;
  --tt-live-bg: #ffeef0;
  --tt-pane: rgba(255, 255, 255, 0.55);
  --tt-pane-hover: rgba(255, 255, 255, 0.72);
  --tt-pane-off: rgba(255, 255, 255, 0.22);
  --tt-pane-edge: rgba(255, 255, 255, 0.85);
  --tt-pane-edge-off: rgba(255, 255, 255, 0.70);
  --tt-pane-sheen: linear-gradient(135deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 50%);
  --tt-pane-hi: inset 0 1px 0 rgba(255, 255, 255, 1);
  --tt-pane-drop: 0 10px 30px rgba(60, 40, 90, 0.12);
  --tt-glow-on: 0.36; --tt-glow-off: 0.08;
  --tt-off-opacity: 0.66;
  --tt-pane-cap: rgba(255, 255, 255, 0.70);
  --tt-pane-inset: rgba(60, 40, 90, 0.05);
  --tt-screen: rgba(28, 24, 40, 0.78);
  --tt-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2357525f' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
}

/* --- база --- */
/* Атрибут hidden прячет всегда: иначе display у класса (.action, flex-строки)
   перебивает его и «скрытая» кнопка остаётся на экране */
[hidden] { display: none !important; }
.tt-page, .tt-page *, .tt-page *::before, .tt-page *::after { box-sizing: border-box; }
.tt-page {
  margin: 0;
  background-color: var(--tt-bg);
  background-image: radial-gradient(var(--tt-dot) 1.1px, transparent 1.4px);
  background-size: 24px 24px;
  color: var(--tt-ink);
  font-family: var(--tt-font-text);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
:where(.tt-page) a { color: inherit; text-decoration: none; }
.tt-wrap { max-width: calc(var(--tt-max) + var(--tt-gutter) * 2); margin: 0 auto; padding: 0 var(--tt-gutter); position: relative; }

/* --- типографика --- */
.tt-display { font-family: var(--tt-font-display); font-weight: 900; text-transform: uppercase; letter-spacing: -0.02em; line-height: 0.98; text-wrap: balance; }
.tt-h2 { font-family: var(--tt-font-display); font-weight: 800; text-transform: uppercase; letter-spacing: -0.015em; line-height: 1.02; font-size: clamp(34px, 5vw, 64px); margin: 0; text-wrap: balance; }
.tt-h3 { font-family: var(--tt-font-display); font-weight: 700; font-size: clamp(19px, 2vw, 23px); letter-spacing: -0.005em; line-height: 1.2; margin: 0; }
.tt-eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 12px; font-weight: 800; letter-spacing: 0.24em; text-transform: uppercase; color: var(--tt-accent-text); }
.tt-eyebrow::before { content: ''; width: 22px; height: 2px; background: currentColor; border-radius: 2px; }
.tt-lead { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.55; color: var(--tt-ink-soft); margin: 0; }
.tt-text { font-size: 15.5px; line-height: 1.6; color: var(--tt-ink-muted); margin: 0; }

/* Розовая «плашка» внутри заголовка — главный фирменный приём */
.tt-mark {
  display: inline-block; background: var(--tt-accent); color: var(--tt-accent-ink);
  padding: 0 0.16em 0.04em; border-radius: 0.18em; transform: rotate(-2deg); white-space: nowrap;
  box-shadow: var(--tt-shadow-accent);
}
/* Акцентное слово в заголовке без плашки — там, где .tt-mark уже есть на экране или неуместна */
.tt-hl { color: var(--tt-accent-text); }
/* Контурный текст (водяные знаки, крупные цифры) */
.tt-outline { color: transparent; -webkit-text-stroke: 1.5px var(--tt-line-strong); }

/* --- логотип --- */
.tt-logo { display: inline-block; line-height: 0; }
.tt-logo img { display: block; height: 30px; width: auto; }
/* Файлы логотипа (/img): logo.svg — для тёмного фона, logo-dark.svg — для
   светлого, logo-black.svg / logo-white.svg — одноцветные (на розовом и т. п.).
   Иконка — favicon.svg / icon-512.png. Буквы логотипа — отрисованные контуры
   шрифта Titan One, текстом его не набирать. */
/* Логотип под тему — две картинки рядом, показывается одна: подмена src
   скриптом давала мигание при загрузке. Так же в кабинете (dashboard.css). */
.logo-on-light { display: none !important; }
html[data-theme="light"] .logo-on-dark { display: none !important; }
html[data-theme="light"] img.logo-on-light { display: block !important; }

/* Кнопка «солнце/луна» в шапке — её добавляет /theme-site.js */
.tt-theme-btn {
  width: 40px; height: 40px; flex-shrink: 0; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  background: var(--tt-fill); border: 1px solid var(--tt-line-strong); border-radius: 50%; color: var(--tt-ink-soft); cursor: pointer;
  transition: border-color var(--tt-dur-1) var(--tt-ease), color var(--tt-dur-1) var(--tt-ease);
}
.tt-theme-btn:hover { border-color: var(--tt-ink-faint); color: var(--tt-ink); }
.tt-theme-btn svg { display: block; }

/* --- иконки ---
   Эмодзи и символы-картинки (✕ ▶ ⚙ ★ и т. п.) на сайте не используем: они
   по-разному выглядят на разных системах и плохо центрируются. Вместо них —
   inline SVG со stroke="currentColor", 16–20px, внутри .tt-ico. */
.tt-ico { display: inline-block; flex-shrink: 0; width: 1.1em; height: 1.1em; vertical-align: -0.18em; }
.tt-ico svg, svg.tt-ico { display: block; width: 100%; height: 100%; }

/* --- кнопки --- */
.tt-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--tt-font-text); font-weight: 800; font-size: 16px; letter-spacing: 0.01em;
  padding: 17px 28px; border-radius: 999px; border: 2px solid transparent; cursor: pointer;
  white-space: nowrap; transition: transform var(--tt-dur-2) var(--tt-ease), box-shadow var(--tt-dur-2) var(--tt-ease), background-color var(--tt-dur-2) var(--tt-ease), border-color var(--tt-dur-2) var(--tt-ease);
}
.tt-btn svg { display: block; flex-shrink: 0; transition: transform var(--tt-dur-2) var(--tt-ease); }
.tt-btn { line-height: 1.1; }
.tt-btn:hover { transform: translateY(-3px); }
.tt-btn:hover svg.tt-arrow { transform: translateX(4px); }
.tt-btn:active { transform: translateY(-1px); }
.tt-btn--primary { background: var(--tt-accent); color: var(--tt-accent-ink); box-shadow: var(--tt-shadow-accent); }
.tt-btn--primary:hover { box-shadow: 0 26px 70px color-mix(in srgb, var(--tt-accent) 50%, transparent); }
.tt-btn--light { background: var(--tt-ink); color: var(--tt-bg); }
.tt-btn--ghost { background: transparent; color: var(--tt-ink); border-color: var(--tt-line-strong); }
.tt-btn--ghost:hover { border-color: var(--tt-ink-soft); }
.tt-btn--sm { font-size: 13px; padding: 11px 18px; letter-spacing: 0.06em; text-transform: uppercase; }

/* --- кнопки инструмента (план 2809, задача 3) ---
   Одна система для кабинета (.action), док-панелей и /youtube (.btn —
   часть разметки генерирует JS, класс остаётся). Витрина — .tt-btn выше.
   Три высоты: .action--sm (и старые .small, .t-act, .cat-btn), обычная,
   .action--lg. Варианты: .primary, .danger, .ghost, .is-icon (квадрат).
   Списки селекторов, а не :is(): старый Chromium в OBS его не знает и
   выбросил бы правило целиком. */
.action, .btn {
  --btn-h: var(--tt-h-md);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--btn-h); padding: 0 16px; border-radius: var(--tt-r-ctl);
  background: var(--tt-surface-2); border: 1px solid var(--tt-line-input); color: var(--tt-ink);
  font-family: var(--tt-font-text); font-size: 14px; font-weight: 700; line-height: 1.2; letter-spacing: 0;
  cursor: pointer; white-space: nowrap; text-decoration: none;
  transition: background-color var(--tt-dur-1) var(--tt-ease), border-color var(--tt-dur-1) var(--tt-ease), color var(--tt-dur-1) var(--tt-ease), transform var(--tt-dur-1) var(--tt-ease);
}
.action svg, .btn svg { display: block; flex-shrink: 0; pointer-events: none; }
.action:hover, .btn:hover { background: var(--tt-surface-3); border-color: var(--tt-line-bold); }
.action:active, .btn:active { transform: scale(.98); }
.action:focus-visible, .btn:focus-visible { outline: 2px solid var(--tt-focus); outline-offset: 2px; }

.action.action--sm, .btn.action--sm, .btn.small, .action.t-act, .action.cat-btn {
  --btn-h: var(--tt-h-sm); padding: 0 12px; font-size: 12.5px; gap: 6px;
}
.action.action--lg, .btn.action--lg { --btn-h: var(--tt-h-lg); padding: 0 20px; font-size: 15px; }
.action.is-icon, .btn.is-icon, .btn.icon { width: var(--btn-h); min-width: var(--btn-h); flex-shrink: 0; padding: 0; }

.action.primary, .btn.primary { background: var(--tt-accent); border-color: var(--tt-accent); color: var(--tt-accent-ink); }
.action.primary:hover:not(:disabled), .btn.primary:hover:not(:disabled) { background: var(--tt-accent); border-color: var(--tt-accent); filter: brightness(1.07); }
.action.danger, .btn.danger { color: var(--tt-bad); border-color: color-mix(in srgb, var(--tt-bad) 40%, transparent); }
.action.danger:hover:not(:disabled), .btn.danger:hover:not(:disabled) { border-color: var(--tt-bad); background: var(--tt-bad-bg); }
.action.ghost, .btn.ghost { background: transparent; border-color: transparent; color: var(--tt-ink-soft); }
.action.ghost:hover:not(:disabled), .btn.ghost:hover:not(:disabled) { background: var(--tt-surface-3); border-color: transparent; color: var(--tt-ink); }

/* Выключенная: без наведения и нажатия; основная — как вторичная, иначе
   приглушённый акцент выглядит нажатым (аудит 2026-09-28, U36) */
.action:disabled, .btn:disabled, .action[aria-disabled="true"], .action.is-disabled {
  opacity: .5; cursor: default; transform: none; filter: none;
  background: var(--tt-surface-2); border-color: var(--tt-line-input); color: var(--tt-ink);
}
.action.danger:disabled, .btn.danger:disabled { color: var(--tt-bad); border-color: color-mix(in srgb, var(--tt-bad) 40%, transparent); }
.action.ghost:disabled, .btn.ghost:disabled { background: transparent; border-color: transparent; }

@media (prefers-reduced-motion: reduce) {
  .action, .btn { transition: none; }
  .action:active, .btn:active { transform: none; }
}

/* --- чипы и бейджи --- */
.tt-chip {
  display: inline-flex; align-items: center; gap: 9px; padding: 11px 16px; border-radius: 14px;
  background: var(--tt-fill); border: 1.5px solid var(--tt-line-strong);
  font-family: var(--tt-font-display); font-weight: 700; font-size: 14px;
}
.tt-chip svg { color: var(--tt-accent-text); flex-shrink: 0; }
.tt-badge {
  display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase;
  border: 1.5px solid currentColor;
}

/* --- карточки --- */
/* Карточки и панели — матовое стекло плиток пульта (план 3009, задача 2):
   заливка --tt-pane с бликом, светлая кромка, тень. Без backdrop-filter —
   фон под ними неподвижный */
.tt-card {
  position: relative; overflow: hidden; background: var(--tt-pane-sheen), var(--tt-pane);
  border: 1.5px solid var(--tt-pane-edge); border-radius: var(--tt-r-lg); box-shadow: var(--tt-pane-hi), var(--tt-pane-drop);
  transition: border-color var(--tt-dur-2) var(--tt-ease), transform var(--tt-dur-2) var(--tt-ease);
}
.tt-card:hover { border-color: var(--tt-line-strong); }

/* --- пузыри чата (иллюстрации) --- */
.tt-bubble {
  display: inline-block; max-width: 100%; background: color-mix(in srgb, var(--tt-surface) 94%, transparent);
  border: 1.5px solid var(--tt-line); border-radius: 20px 20px 20px 6px;
  padding: 12px 16px; font-size: 16px; line-height: 1.4; box-shadow: var(--tt-shadow-card);
}
.tt-bubble b { font-weight: 800; margin-right: 6px; }
.tt-bubble--bot { border-radius: 20px 20px 6px 20px; background: color-mix(in srgb, var(--tt-accent) 13%, var(--tt-surface)); border-color: color-mix(in srgb, var(--tt-accent) 45%, transparent); }

/* --- фокус с клавиатуры (дублирует a11y.css для страниц без него) --- */
.tt-page :focus-visible { outline: 2px solid var(--tt-focus); outline-offset: 3px; }

/* --- появление при скролле --- */
.tt-reveal { opacity: 0; transform: translateY(16px); transition: opacity var(--tt-dur-3) var(--tt-ease), transform var(--tt-dur-3) var(--tt-ease); }
.tt-reveal.in-view { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .tt-reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .tt-btn, .tt-btn svg, .tt-card { transition: none !important; }
  .tt-btn:hover, .tt-btn:active, .tt-btn:hover svg.tt-arrow { transform: none; }
}

/* «Уменьшить движение» на всех страницах с brand.css (план 2809, задача 22):
   переходы и анимации мгновенно доходят до конца — ленты, пятно, волны,
   «в эфире», маскот, спиннеры и появления стоят, смена состояний остаётся.
   Виджеты OBS brand.css не подключают */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: .01ms !important; transition-delay: 0s !important;
    animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}

/* =====================================================================
   Компоненты внутренних страниц (кабинет, бета, заявки, статистика и т. д.)
   ===================================================================== */

/* --- шапка сайта: логотип слева, ссылки, справа — пользователь/кнопки --- */
.tt-topbar { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); background: var(--tt-glass); border-bottom: 1px solid var(--tt-line); }
.tt-topbar-inner { max-width: calc(var(--tt-max) + var(--tt-gutter) * 2); margin: 0 auto; padding: 0 var(--tt-gutter); min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.tt-topbar .tt-logo img { height: 34px; }
.tt-topbar-links { display: flex; align-items: center; gap: 26px; font-size: 12px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--tt-ink-soft); }
.tt-topbar-links a:hover, .tt-topbar-links a[aria-current="page"] { color: var(--tt-ink); }
.tt-topbar-links a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--tt-accent); padding-bottom: 4px; }
.tt-topbar-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tt-user { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 700; color: var(--tt-ink-soft); }
.tt-user img { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--tt-accent-text); object-fit: cover; }
/* Шапка с несколькими ссылками (служебные /admin*): на телефоне ссылки уходят
   второй строкой в ленту с прокруткой, а логотип и кнопка темы остаются
   в первой. Разметка: <header class="tt-topbar tt-topbar--scroll"> и ссылки
   в <nav class="tt-topbar-scroll"> внутри .tt-topbar-right. */
.tt-topbar-scroll { display: flex; align-items: center; gap: 10px; }
@media (max-width: 560px) {
  .tt-topbar--scroll .tt-topbar-inner { flex-wrap: wrap; min-height: 0; padding-top: 10px; gap: 8px 10px; }
  .tt-topbar--scroll .tt-topbar-right { display: contents; }
  .tt-topbar--scroll .tt-topbar-scroll {
    order: 5; flex: 1 0 100%; min-width: 0; gap: 6px; padding: 0 0 10px;
    overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none;
  }
  .tt-topbar--scroll .tt-topbar-scroll::-webkit-scrollbar { display: none; }
  .tt-topbar--scroll .tt-topbar-scroll > * { flex-shrink: 0; }
}

/* --- заголовок страницы --- */
.tt-pagehead { padding: clamp(40px, 6vw, 72px) 0 clamp(24px, 3vw, 36px); }
.tt-h1 { font-family: var(--tt-font-display); font-weight: 900; text-transform: uppercase; letter-spacing: -0.02em; line-height: 1; font-size: var(--tt-fs-h1); margin: 16px 0 0; text-wrap: balance; }
/* на самых узких экранах длинные слова h1 («ПОДКЛЮЧЕНИЕ», «КОНФИДЕНЦИ-») не влезают в 32px */
@media (max-width: 360px) { :root { --tt-fs-h1: 26px; } }
.tt-pagehead .tt-lead { margin-top: 18px; max-width: 640px; }

/* --- панели --- */
.tt-panel {
  background: var(--tt-pane-sheen), var(--tt-pane); border: 1.5px solid var(--tt-pane-edge); border-radius: var(--tt-r-lg);
  box-shadow: var(--tt-pane-hi), var(--tt-pane-drop); padding: clamp(22px, 3vw, 34px);
}
.tt-panel + .tt-panel { margin-top: 16px; }
.tt-panel-title { font-family: var(--tt-font-display); font-weight: 800; font-size: clamp(18px, 1.8vw, 21px); letter-spacing: -0.005em; margin: 0 0 6px; }
.tt-panel--accent { background: var(--tt-accent); color: var(--tt-accent-ink); border-color: transparent; box-shadow: none; }

/* --- формы --- */
.tt-field { display: block; margin-top: 18px; }
.tt-field:first-child { margin-top: 0; }
.tt-label { display: block; font-size: 13px; font-weight: 700; color: var(--tt-ink-soft); margin-bottom: 8px; }
.tt-input, .tt-select, .tt-textarea {
  width: 100%; min-height: var(--tt-h-md); background: var(--tt-field); color: var(--tt-ink); border: 1px solid var(--tt-line-field);
  border-radius: var(--tt-r-ctl); padding: 8px 12px; font: 500 var(--tt-fs-base)/1.4 var(--tt-font-text);
  transition: border-color var(--tt-dur-2) var(--tt-ease), box-shadow var(--tt-dur-2) var(--tt-ease);
}
.tt-input, .tt-select { height: var(--tt-h-md); padding-top: 0; padding-bottom: 0; }
.tt-textarea { min-height: 110px; resize: vertical; }
.tt-input::placeholder, .tt-textarea::placeholder { color: var(--tt-ink-faint); opacity: 1; }
.tt-input:hover, .tt-select:hover, .tt-textarea:hover { border-color: var(--tt-line-bold); }
.tt-input:focus, .tt-select:focus, .tt-textarea:focus { outline: none; border-color: var(--tt-accent-text); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tt-accent) 18%, transparent); }
.tt-hint { font-size: 13px; line-height: 1.5; color: var(--tt-ink-faint); margin: 8px 0 0; }

/* Переключатель 42×24 — один вид на три разметки:
   <label class="tt-switch"><input type="checkbox"><span></span></label> (сайт),
   <label class="switch"><input type="checkbox"><span class="slider"></span></label> (кабинет),
   <button class="t-sw" role="switch" aria-checked> (плитки пульта).
   Списки селекторов, а не :is() — см. кнопки выше. */
.tt-switch, .switch, .t-sw {
  position: relative; display: inline-block; flex: none; align-self: center;
  width: 42px; height: 24px; margin: 0; padding: 0; border: 0; vertical-align: middle;
}
.tt-switch input[type=checkbox] { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
/* [type=checkbox] — чтобы перебить общий вид чекбокса кабинета */
.switch input[type=checkbox], .switch input[type=checkbox]:disabled { position: absolute; opacity: 0; width: 0; height: 0; margin: 0; padding: 0; border: 0; }
.tt-switch span, .switch .slider { position: absolute; inset: 0; cursor: pointer; }
.tt-switch span, .switch .slider, .t-sw {
  border-radius: 999px; background: var(--tt-fill-strong); cursor: pointer;
  transition: background-color var(--tt-dur-2) var(--tt-ease);
}
.tt-switch span::after, .switch .slider::before, .t-sw::after {
  content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--tt-ink-soft); transition: transform var(--tt-dur-2) var(--tt-ease), background-color var(--tt-dur-2) var(--tt-ease);
}
.tt-switch input:checked + span, .switch input:checked + .slider, .t-sw[aria-checked="true"] { background: var(--tt-accent); }
.tt-switch input:checked + span::after, .switch input:checked + .slider::before, .t-sw[aria-checked="true"]::after {
  transform: translateX(18px); background: var(--tt-accent-ink);
}
.tt-switch input:focus-visible + span, .switch input:focus-visible + .slider, .t-sw:focus-visible { outline: 2px solid var(--tt-focus); outline-offset: 2px; }
.tt-switch input:disabled + span, .switch input:disabled + .slider, .t-sw:disabled { opacity: .5; cursor: not-allowed; }

/* --- статусы ---
   .tt-status + --ok / --warn / --bad / --live. Старые классы кабинета и
   /pending — алиасы: .status-pill + .status-on / -connecting / -pending /
   -off / -denied. Фон — сплошные токены (без color-mix: статусы есть и в
   доках OBS). Капс с разрядкой — только у статусов и бейджей. */
.tt-status, .status-pill {
  display: inline-flex; align-items: center; gap: 6px; max-width: 100%;
  padding: 4px 10px; border-radius: 999px; background: var(--tt-surface-3); color: var(--tt-ink-soft);
  font: 700 var(--tt-fs-xs)/1.3 var(--tt-font-text); letter-spacing: .06em; text-transform: uppercase; white-space: nowrap;
}
.tt-status::before, .status-pill::before { content: ''; flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tt-status--ok, .status-pill.status-on { background: var(--tt-ok-bg); color: var(--tt-ok); }
.tt-status--warn, .status-pill.status-connecting, .status-pill.status-pending { background: var(--tt-warn-bg); color: var(--tt-warn); }
.tt-status--bad, .status-pill.status-off, .status-pill.status-denied { background: var(--tt-bad-bg); color: var(--tt-bad); }
.tt-status--live { background: var(--tt-live-bg); color: var(--tt-live); }

@media (prefers-reduced-motion: reduce) {
  .tt-input, .tt-select, .tt-textarea,
  .tt-switch span, .switch .slider, .t-sw,
  .tt-switch span::after, .switch .slider::before, .t-sw::after { transition: none; }
}

/* --- таблицы --- */
.tt-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.tt-table th { text-align: left; font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--tt-ink-faint); padding: 0 12px 12px; border-bottom: 1px solid var(--tt-line); }
.tt-table td { padding: 14px 12px; border-bottom: 1px solid var(--tt-line); vertical-align: middle; }
.tt-table tr:last-child td { border-bottom: 0; }

/* --- рабочие страницы вне кабинета (/youtube, админка): вид инструмента ---
   <body class="tt-page tt-page--tool"> (план 2809, задачи 18–19): без точек
   фона, заголовок страницы размером инструмента, панели и таблицы — как
   секции кабинета (1px, --tt-r-panel), числа одной ширины. */
/* Фон — мягкая подсветка, как под пультом (план 3009, задача 2): акцент
   слева сверху, фиолетовый справа снизу; стоит на месте при прокрутке */
.tt-page--tool {
  background-image:
    radial-gradient(90% 80% at -10% 0%, color-mix(in srgb, var(--tt-accent) 10%, transparent), transparent 75%),
    radial-gradient(90% 90% at 110% 105%, color-mix(in srgb, var(--tt-violet) 11%, transparent), transparent 75%);
  background-size: auto; background-attachment: fixed;
}
.tt-page--tool .tt-pagehead { padding: clamp(24px, 4vw, 40px) 0 clamp(16px, 2vw, 24px); }
.tt-page--tool .tt-pagehead .tt-h1 { font-size: var(--tt-fs-xl); }
.tt-page--tool .tt-panel { border-width: 1px; border-radius: var(--tt-r-panel); padding: var(--tt-sp-5); }
.tt-page--tool .tt-panel-title { font-size: var(--tt-fs-md); }
.tt-page--tool .tt-table { font-size: 14px; font-variant-numeric: tabular-nums; }
.tt-page--tool .tt-table th { font-size: var(--tt-fs-xs); font-weight: 700; letter-spacing: .06em; padding: 0 12px 10px; }
.tt-page--tool .tt-table td { padding: 12px; }

/* --- маленькие страницы с одной карточкой по центру (заявка, поддержка) --- */
.tt-center { min-height: calc(100vh - 73px); display: flex; align-items: center; justify-content: center; padding: 40px var(--tt-gutter) 72px; }
.tt-center > .tt-panel { width: 100%; max-width: 560px; }

/* --- подвал внутренних страниц --- */
.tt-foot { max-width: calc(var(--tt-max) + var(--tt-gutter) * 2); margin: 64px auto 0; padding: 26px var(--tt-gutter) 36px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; border-top: 1px solid var(--tt-line); font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--tt-ink-faint); }
.tt-foot img { height: 22px; width: auto; display: block; }
.tt-foot nav { display: flex; flex-wrap: wrap; gap: 22px; }
.tt-foot a:hover { color: var(--tt-ink); }

@media (max-width: 760px) {
  .tt-topbar-links { display: none; }
  .tt-topbar .tt-logo img { height: 28px; }
}

/* Телефон: шрифт полей меньше 16px — и iOS увеличивает страницу при фокусе.
   Одно правило на весь сайт, поверх стилей страниц и inline-стилей.
   Только сенсорные экраны: узкие док-панели в OBS остаются компактными */
@media (max-width: 640px) and (pointer: coarse) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="file"]),
  select, textarea { font-size: 16px !important; }
}

/* =====================================================================
   Маскот (public/mascot.js, задача 21 docs/plans/2609.md). SVG вставлен
   разметкой в .tt-mascot-box; цвета и классы частей — docs/mascot.md.
   ===================================================================== */
.tt-mascot-box {
  --m-accent: var(--tt-accent);
  --m-bubble: #f4f2f6; --m-bubble-ink: #0c0c0e; --m-cup-line: none;
  position: relative; display: inline-block; flex: none; vertical-align: middle;
  width: var(--m-size, 64px); height: var(--m-size, 64px);
  animation: m-float 4s ease-in-out infinite;
}
html[data-theme="light"] .tt-mascot-box { --m-bubble: #16161a; --m-bubble-ink: #f4f2f6; --m-cup-line: #16161a; }
.tt-mascot-box > svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; overflow: visible; }

/* смена состояния: старый гаснет поверх нового, облачка нового проявляются */
.tt-mascot-box > svg.m-leaving { animation: m-fade-out var(--tt-dur-3) var(--tt-ease) forwards; }
.tt-mascot-box > svg.m-entering .m-extra { animation: m-fade-in var(--tt-dur-3) var(--tt-ease) both; }

/* моргание — у всех состояний */
.tt-mascot-box .m-eyes { transform-box: view-box; transform-origin: 100px 100px; animation: m-blink 5s ease-in-out infinite; }

/* «объясняет»: рот-эквалайзер, пока показан текст */
.tt-mascot-box .m-eq-bar { transform-box: fill-box; transform-origin: center; }
.tt-mascot-box.m-talking .m-eq-bar { animation: m-eq .42s ease-in-out infinite alternate; }
.tt-mascot-box.m-talking .m-eq-bar:nth-child(2) { animation-duration: .36s; animation-delay: -.1s; }
.tt-mascot-box.m-talking .m-eq-bar:nth-child(3) { animation-duration: .5s; animation-delay: -.25s; }
.tt-mascot-box.m-talking .m-eq-bar:nth-child(4) { animation-duration: .38s; animation-delay: -.05s; }
.tt-mascot-box.m-talking .m-eq-bar:nth-child(5) { animation-duration: .46s; animation-delay: -.3s; }

/* «думает»: пульсирует шарик антенны, точки покачиваются вокруг неё */
.tt-mascot--think .m-antenna-ball { transform-box: fill-box; transform-origin: center; animation: m-pulse 1.4s ease-in-out infinite; }
.tt-mascot--think .m-orbit { transform-box: view-box; transform-origin: 100px 20px; animation: m-sway 2.8s ease-in-out infinite; }
.tt-mascot--think .m-dot, .tt-mascot--wait .m-dot { animation: m-dot 1.4s ease-in-out infinite; }
.tt-mascot--think .m-dot + .m-dot, .tt-mascot--wait .m-dot:nth-of-type(2) { animation-delay: .45s; }
.tt-mascot--wait .m-dot:nth-of-type(3) { animation-delay: .9s; }

/* «радуется»: искры коротко вспыхивают при появлении */
.tt-mascot--happy .m-spark { transform-box: fill-box; transform-origin: center; animation: m-spark .7s cubic-bezier(.2, .8, .3, 1.2) both; }
.tt-mascot--happy .m-sparks > :nth-child(2) .m-spark { animation-delay: .12s; }
.tt-mascot--happy .m-sparks > :nth-child(3) .m-spark { animation-delay: .24s; }
.tt-mascot--happy .m-sparks > :nth-child(4) .m-spark { animation-delay: .36s; }

/* Страницы-инструменты (/youtube, админка) — без бесконечных анимаций, как
   кабинет (dashboard.css): маскот «музыка выключена» стоит (задача 23) */
.tt-page--tool .tt-mascot-box, .tt-page--tool .tt-mascot-box .m-eyes, .tt-page--tool .tt-mascot--wait .m-dot,
.tt-page--tool .tt-mascot--think .m-antenna-ball, .tt-page--tool .tt-mascot--think .m-orbit, .tt-page--tool .tt-mascot--think .m-dot { animation: none; }

@keyframes m-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5%); } }
@keyframes m-blink { 0%, 93%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } }
@keyframes m-eq { from { transform: scaleY(.45); } to { transform: scaleY(1.35); } }
@keyframes m-pulse { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.3); opacity: .55; } }
@keyframes m-sway { 0%, 100% { transform: rotate(-14deg); } 50% { transform: rotate(14deg); } }
@keyframes m-dot { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
@keyframes m-spark { 0% { transform: scale(0) rotate(-45deg); opacity: 0; } 60% { transform: scale(1.4) rotate(0); opacity: 1; } 100% { transform: scale(1); opacity: 1; } }
@keyframes m-fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes m-fade-out { from { opacity: 1; } to { opacity: 0; } }

/* пустой блок: маскот слева от текста */
.tt-empty:not([hidden]) { display: flex; align-items: center; gap: 14px; }
.tt-empty .tt-mascot-box { --m-size: 56px; flex: none; }
/* tt2sEmpty (/common.js): текст и кнопка действия под ним */
.tt-empty-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; min-width: 0; }
.tt-empty-text { margin: 0; color: var(--tt-ink-muted); font-size: 14px; line-height: 1.5; }

@media (prefers-reduced-motion: reduce) {
  .tt-mascot-box, .tt-mascot-box * { animation: none !important; }
}

/* --- тост (window.tt2sToast в /a11y.js) ---
   Сверху по центру: внизу слева — индикатор сохранения кабинета, справа —
   плавающие кнопки поддержки */
.tt-toasts {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 1100;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: min(460px, calc(100vw - 32px)); pointer-events: none;
}
.tt-toast {
  pointer-events: auto; display: flex; align-items: center; gap: 10px; width: 100%; box-sizing: border-box;
  background: var(--tt-surface); color: var(--tt-ink); border: 1.5px solid var(--tt-line-strong);
  border-radius: 18px; padding: 10px 10px 10px 16px; box-shadow: var(--tt-shadow-pop);
  font: 600 14px/1.45 var(--tt-font-text); animation: tt-toast-in var(--tt-dur-2) var(--tt-ease);
}
.tt-toast::before { content: ''; flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--tt-ok); }
.tt-toast--error { border-color: var(--tt-bad); border-color: color-mix(in srgb, var(--tt-bad) 55%, transparent); }
.tt-toast--error::before { background: var(--tt-bad); }
.tt-toast--info::before { background: var(--tt-accent); }
.tt-toast.is-leaving { opacity: 0; transform: translateY(-6px); transition: opacity var(--tt-dur-1) var(--tt-ease), transform var(--tt-dur-1) var(--tt-ease); }
.tt-toast-text { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.tt-toast-action {
  flex-shrink: 0; background: none; border: 1.5px solid currentColor; color: var(--tt-accent-text); border-radius: 999px;
  font: 800 13px/1 var(--tt-font-text); padding: 8px 12px; cursor: pointer;
}
.tt-toast-close {
  flex-shrink: 0; width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: var(--tt-ink-muted);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.tt-toast-close:hover { background: var(--tt-fill); color: var(--tt-ink); }
@keyframes tt-toast-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* --- окно подтверждения и поле ввода (tt2sConfirm / tt2sPrompt) --- */
.tt-ask-overlay {
  position: fixed; inset: 0; z-index: 1050; display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(6, 6, 8, 0.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.tt-ask-overlay[hidden] { display: none; }
.tt-ask {
  width: 100%; max-width: 420px; box-sizing: border-box; margin: 0;
  background: var(--tt-surface); color: var(--tt-ink); border: 1.5px solid var(--tt-line-strong); border-radius: 24px;
  padding: 24px; box-shadow: var(--tt-shadow-pop); font-family: var(--tt-font-text);
  /* на телефоне — не под адресной строкой: dvh, запасное vh строкой выше */
  max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain;
}
.tt-ask-title { margin: 0 0 8px; font: 800 19px/1.25 var(--tt-font-text); }
.tt-ask-title[hidden] { display: none; }
.tt-ask-text { margin: 0; font-size: 15px; line-height: 1.55; color: var(--tt-ink-soft); white-space: pre-line; }
.tt-ask-input {
  display: block; width: 100%; box-sizing: border-box; margin-top: 14px;
  background: var(--tt-fill); border: 1.5px solid var(--tt-line-field); color: var(--tt-ink);
  border-radius: 14px; padding: 11px 14px; font: 500 16px/1.4 var(--tt-font-text);
}
.tt-ask-input[hidden] { display: none; }
.tt-ask-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; margin-top: 20px; }
.tt-ask-actions button {
  min-height: 44px; padding: 0 20px; border-radius: 999px; font: 800 14.5px/1 var(--tt-font-text); cursor: pointer;
}
.tt-ask-cancel { background: none; border: 1.5px solid var(--tt-line-strong); color: var(--tt-ink); }
.tt-ask-cancel:hover { border-color: var(--tt-ink-muted); }
.tt-ask-ok { background: var(--tt-accent); border: 1.5px solid var(--tt-accent); color: var(--tt-accent-ink); }
.tt-ask-ok.is-danger { background: var(--tt-bad); border-color: var(--tt-bad); color: var(--tt-bg); }
.tt-ask-ok:disabled { opacity: .5; cursor: not-allowed; }
@media (max-width: 420px) {
  .tt-ask-actions button { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  .tt-toast, .tt-toast.is-leaving { animation: none; transition: none; }
}

/* --- браузеры без color-mix() (старый Chromium в OBS и т. п.) ---
   Запасной цвет строкой выше тут не помогает: в строке с color-mix() есть
   var(), такая строка считается верной при разборе и перебивает запасную,
   а без поддержки color-mix свойство сбрасывается. Поэтому — отдельный блок,
   который применяется только там, где color-mix() не понимают. */
@supports not (color: color-mix(in srgb, red, red)) {
  .tt-toast--error { border-color: var(--tt-bad); }
  .tt-input:focus, .tt-select:focus, .tt-textarea:focus { box-shadow: 0 0 0 3px var(--tt-line-dash); }
  html[data-theme="light"] { --tt-accent-text: var(--tt-ink); }
  .tt-page--tool { background-image: none; }
  /* рамка «опасной» кнопки — --tt-bad на 40% (доки в OBS всегда тёмные) */
  .action.danger, .btn.danger, .action.danger:disabled, .btn.danger:disabled { border-color: rgba(255, 154, 154, 0.4); }
  html[data-theme="light"] .action.danger, html[data-theme="light"] .btn.danger,
  html[data-theme="light"] .action.danger:disabled, html[data-theme="light"] .btn.danger:disabled { border-color: rgba(160, 40, 40, 0.4); }
}

/* Без прозрачности (настройка системы): карточки и панели — сплошные,
   фон служебных страниц — ровный (план 3009, задача 2) */
@media (prefers-reduced-transparency: reduce) {
  .tt-card, .tt-panel { background: var(--tt-surface); border-color: var(--tt-line); box-shadow: none; }
  .tt-panel--accent { background: var(--tt-accent); border-color: transparent; }
  .tt-page--tool { background-image: none; }
}
