/* ==========================================================================
   AISync — MCP-хаб. Дизайн-система кабинета (2026).
   Премиальный SaaS: глубокий тёмный сайдбар, светлый плотный контент,
   индиго-фиолетовый акцент, семантические цвета KPI/статусов.
   Без внешних шрифтов, CDN и JS-библиотек. Только CSS + inline SVG.
   ==========================================================================
   СОДЕРЖАНИЕ
   01. Токены
   02. База и типографика
   03. Каркас: сайдбар, топбар, контент
   04. Карточки и заголовки блоков
   05. Hero (дашборд)
   06. KPI + спарклайны
   07. Графики (.bars) и легенды
   08. Прогресс, чек-лист, метры
   09. Таблицы
   10. Кнопки
   11. Бейджи и теги
   12. Формы
   13. Flash-сообщения
   14. Заголовок страницы
   15. Сетки и утилиты
   16. Дашборд: топ инструментов, события, быстрые действия
   17. Карточка плана, компании
   18. Коннекторы
   19. Биллинг (страницы тарифов в кабинете)
   20. Админ-панель
   21. Auth: сплит-экран входа
   22. Прочее (OAuth, пустые состояния, код)
   23. Адаптив
   ========================================================================== */

/* ============================== 01. ТОКЕНЫ ============================== */
:root {
  /* Бренд */
  --brand-50: #f2f0ff;
  --brand-100: #e8e4ff;
  --brand-200: #d3ccff;
  --brand-300: #b4a8ff;
  --brand-500: #6d5cff;
  --brand-600: #5a47f0;
  --brand-700: #4a37d6;
  --violet-500: #a855f7;
  --violet-600: #9333ea;
  --grad: linear-gradient(135deg, #6d5cff 0%, #a855f7 100%);
  --grad-soft: linear-gradient(135deg, rgba(109, 92, 255, 0.13), rgba(168, 85, 247, 0.13));
  --grad-line: linear-gradient(90deg, #6d5cff, #a855f7);

  /* Семантика */
  --ok: #0f9d67;
  --ok-soft: #e7f8f0;
  --err: #dc2643;
  --err-soft: #fdecef;
  --warn: #b7791f;
  --warn-soft: #fdf5e3;
  --info: #0891b2;
  --info-soft: #e5f7fb;

  /* Поверхности */
  --bg: #f4f5fa;
  --bg-2: #eef0f7;
  --card: #ffffff;
  --surface-2: #f8f9fd;
  --surface-3: #f1f3fa;
  --line: #e7e9f2;
  --line-2: #d9ddea;
  --ink: #141827;
  --ink-2: #2b3145;
  --muted: #667085;
  --muted-2: #949cb1;

  /* Сайдбар */
  --sidebar-w: 266px;
  --sidebar-1: #0e1020;
  --sidebar-2: #171a33;

  /* Тени и радиусы */
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow-sm: 0 2px 8px rgba(16, 24, 40, 0.05);
  --shadow-md: 0 14px 34px -16px rgba(19, 23, 53, 0.28);
  --shadow-lg: 0 34px 90px -40px rgba(64, 48, 158, 0.55);
  --r-xs: 6px;
  --r-sm: 9px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 20px;
  --r-full: 999px;
  --ring: 0 0 0 3px rgba(109, 92, 255, 0.18);

  /* Шрифты */
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial,
    "Noto Sans", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}

/* ========================= 02. БАЗА И ТИПОГРАФИКА ======================= */
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection {
  background: rgba(109, 92, 255, 0.22);
}
h1, h2, h3, h4 {
  color: var(--ink);
  line-height: 1.25;
  letter-spacing: -0.2px;
}
p {
  margin: 0 0 10px;
}
p:last-child {
  margin-bottom: 0;
}
a {
  color: var(--brand-600);
  text-decoration: none;
  transition: color 0.14s ease;
}
a:hover {
  color: var(--brand-700);
  text-decoration: underline;
  text-underline-offset: 2px;
}
strong, b {
  font-weight: 700;
}
small {
  font-size: 11.5px;
}
hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 18px 0;
}
code, pre, kbd, samp {
  font-family: var(--mono);
  font-size: 12.5px;
}
code {
  background: var(--surface-3);
  color: #443a8f;
  border: 1px solid rgba(109, 92, 255, 0.12);
  border-radius: 6px;
  padding: 1px 6px;
  word-break: break-word;
}
pre {
  background: #12142a;
  color: #e7e9ff;
  border: 1px solid #23264a;
  border-radius: var(--r-md);
  padding: 14px 16px;
  overflow-x: auto;
  line-height: 1.6;
  margin: 8px 0 12px;
}
pre code {
  background: none;
  border: 0;
  color: inherit;
  padding: 0;
}
img {
  max-width: 100%;
}
svg {
  flex: 0 0 auto;
}
:focus-visible {
  outline: 2px solid var(--brand-500);
  outline-offset: 2px;
}

/* Иконка-контейнер: универсальный размер inline-SVG */
.icon {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--sm {
  width: 15px;
  height: 15px;
}
.icon--lg {
  width: 22px;
  height: 22px;
}

/* ============================ 03. КАРКАС =============================== */
.app-shell {
  display: flex;
  min-height: 100vh;
  min-height: 100dvh;
}

/* ------------------------------- сайдбар -------------------------------- */
.app-sidebar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  flex: 0 0 var(--sidebar-w);
  width: var(--sidebar-w);
  height: 100vh;
  height: 100dvh;
  padding: 18px 14px 14px;
  overflow-y: auto;
  overflow-x: hidden;
  color: #c3c8e4;
  background:
    radial-gradient(520px 320px at -30% -10%, rgba(109, 92, 255, 0.45), transparent 62%),
    radial-gradient(440px 320px at 120% 108%, rgba(168, 85, 247, 0.3), transparent 62%),
    linear-gradient(180deg, var(--sidebar-1) 0%, #121529 55%, var(--sidebar-2) 100%);
  border-right: 1px solid rgba(255, 255, 255, 0.04);
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.16) transparent;
}
.app-sidebar::-webkit-scrollbar {
  width: 6px;
}
.app-sidebar::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 99px;
}

.app-sidebar__brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 4px 8px 16px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.2px;
}
.brand-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 12px;
  color: #fff;
  background: var(--grad);
  box-shadow: 0 10px 24px -10px rgba(124, 92, 255, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
.brand-logo svg {
  width: 21px;
  height: 21px;
}
.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.2;
}
.brand-name {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.1px;
}
.brand-sub {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.9px;
  text-transform: uppercase;
  color: #8a91b8;
  margin-top: 2px;
}
.app-sidebar__brand .admin-mark {
  margin-left: auto;
}

.app-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 18px;
  flex: 1;
  padding-bottom: 14px;
}
.nav-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.nav-group__label {
  padding: 0 10px;
  margin-bottom: 3px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: #6c7399;
}
.app-sidebar__nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border-radius: 10px;
  color: #b4bada;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.app-sidebar__nav a svg,
.nav-icon {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.92;
}
.app-sidebar__nav a:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
  text-decoration: none;
}
.app-sidebar__nav a.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(109, 92, 255, 0.95), rgba(168, 85, 247, 0.85));
  box-shadow: 0 12px 26px -14px rgba(109, 92, 255, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.app-sidebar__nav a.active::after {
  content: "";
  position: absolute;
  right: 11px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.16);
}
.app-sidebar__nav .nav-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-sidebar__footer {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
  padding: 14px 6px 2px;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  font-size: 11.5px;
  color: #7c83a8;
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.sidebar-user .avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  text-transform: uppercase;
  background: var(--grad);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.sidebar-user__meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.3;
}
.sidebar-user__meta b {
  color: #edefff;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user__meta span {
  color: #7d84a8;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-logout form,
.sidebar-logout {
  margin: 0;
}
.btn-sidebar {
  width: 100%;
  justify-content: flex-start;
  gap: 9px;
  padding: 8px 11px;
  font-size: 12.5px;
  font-weight: 600;
  color: #c3c8e4;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
}
.btn-sidebar:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(255, 255, 255, 0.16);
  filter: none;
}
.btn-sidebar svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.sidebar-brandfoot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
  color: #6e7599;
  font-size: 10.5px;
  letter-spacing: 0.2px;
}
.sidebar-brandfoot .xstorm-badge {
  height: 17px;
  opacity: 0.9;
}
.xstorm-badge {
  display: block;
  height: 24px;
  flex: 0 0 auto;
}

.admin-mark {
  display: inline-flex;
  align-items: center;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #d6c9ff;
  background: rgba(139, 92, 246, 0.22);
  border: 1px solid rgba(168, 85, 247, 0.45);
  padding: 2px 6px;
  border-radius: 6px;
  line-height: 1.4;
}

/* ------------------------------ главная часть --------------------------- */
.app-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.app-topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 10px 28px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.app-burger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink-2);
  cursor: pointer;
}
.app-burger:hover {
  border-color: var(--brand-300);
  color: var(--brand-600);
}
.app-burger svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
}
.app-topbar__title {
  display: flex;
  flex-direction: column;
  margin-right: auto;
  min-width: 0;
  line-height: 1.2;
}
.app-topbar__eyebrow {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--muted-2);
}
.app-topbar__page {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.2px;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.app-topbar__right {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}
.app-topbar__right form {
  margin: 0;
}
.topbar-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 9px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
}
.topbar-link:hover {
  color: var(--brand-600);
  background: var(--brand-50);
  text-decoration: none;
}
.topbar-user {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 4px 8px 4px 4px;
  border-radius: var(--r-full);
  border: 1px solid transparent;
  color: var(--ink);
}
.topbar-user:hover {
  background: var(--surface-3);
  border-color: var(--line);
  text-decoration: none;
}
.topbar-user .avatar {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 11.5px;
  font-weight: 800;
  text-transform: uppercase;
  color: #fff;
  background: var(--grad);
}
.topbar-user__name {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink-2);
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-divider {
  width: 1px;
  height: 24px;
  background: var(--line);
  margin: 0 2px;
}

.app-content {
  flex: 1;
  width: 100%;
  max-width: 1340px;
  margin: 0 auto;
  padding: 26px 28px 56px;
}

.app-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 45;
  background: rgba(10, 12, 26, 0.5);
  backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity 0.25s ease;
}
body.sidebar-open .app-overlay {
  display: block;
  opacity: 1;
}

/* ==================== 04. КАРТОЧКИ И ЗАГОЛОВКИ БЛОКОВ ================== */
.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 18px 20px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-xs);
}
.card h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
  margin: 0 0 14px;
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: -0.2px;
  color: var(--ink);
}
.card h2::before {
  content: "";
  width: 3px;
  height: 15px;
  flex: 0 0 3px;
  border-radius: 99px;
  background: var(--grad);
}
.card h2 .cnt {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted-2);
}
.card h3 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 800;
}
.card > p.muted,
.card > p {
  font-size: 13px;
}
.card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.card-head h2 {
  margin: 0;
}
.card-head__titles {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.card-head__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.card-head__text h2 {
  margin: 0;
}
.card-head__text h2::before {
  display: none;
}
.card-head__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 12px;
  color: var(--brand-600);
  background: var(--grad-soft);
  border: 1px solid rgba(109, 92, 255, 0.14);
}
.card-head__icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.card-head__icon--emerald {
  color: var(--ok);
  background: var(--ok-soft);
  border-color: rgba(15, 157, 103, 0.18);
}
.card-head__icon--amber {
  color: var(--warn);
  background: var(--warn-soft);
  border-color: rgba(183, 121, 31, 0.2);
}
.card-head__icon--cyan {
  color: var(--info);
  background: var(--info-soft);
  border-color: rgba(8, 145, 178, 0.18);
}
.card-head__icon--rose {
  color: var(--err);
  background: var(--err-soft);
  border-color: rgba(220, 38, 67, 0.16);
}
.card-sub {
  font-size: 12px;
  color: var(--muted-2);
  line-height: 1.45;
}
.card-mini {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 13px 15px;
  margin-bottom: 12px;
}
.card-mini summary {
  cursor: pointer;
  font-weight: 700;
}
.card-mini summary:hover {
  color: var(--brand-600);
}
.card-mini h2 {
  font-size: 14.5px;
}
.card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--brand-600);
}
.card-link svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ================================ 05. HERO ============================== */
.hero {
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  padding: 28px 30px;
  border-radius: var(--r-xl);
  color: #fff;
  background:
    radial-gradient(620px 320px at 104% -30%, rgba(168, 85, 247, 0.62), transparent 62%),
    radial-gradient(560px 360px at -12% 130%, rgba(109, 92, 255, 0.55), transparent 62%),
    linear-gradient(118deg, #101226 0%, #161930 52%, #1e1740 100%);
  box-shadow: var(--shadow-lg);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(70% 100% at 100% 0%, #000 0%, transparent 72%);
  -webkit-mask-image: radial-gradient(70% 100% at 100% 0%, #000 0%, transparent 72%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  right: -110px;
  top: -130px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 0 60px rgba(255, 255, 255, 0.03), 0 0 0 120px rgba(255, 255, 255, 0.02);
  pointer-events: none;
}
.hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 28px;
  align-items: center;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #b2b7db;
}
.hero__eyebrow .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.16);
}
.hero__title {
  margin: 10px 0 9px;
  font-size: 29px;
  line-height: 1.14;
  font-weight: 800;
  letter-spacing: -0.7px;
  color: #fff;
}
.hero__sub {
  max-width: 580px;
  margin: 0;
  font-size: 13.5px;
  line-height: 1.62;
  color: #b3b9d8;
}
.hero__sub b {
  color: #fff;
}
.hero__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border-radius: var(--r-full);
  font-size: 11.5px;
  font-weight: 700;
  color: #d9dcf3;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.13);
}
.hero-chip svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hero-chip--ok {
  color: #b9f5d7;
  background: rgba(16, 185, 129, 0.14);
  border-color: rgba(52, 211, 153, 0.32);
}
.hero-chip a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.hero__stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.hero-stat {
  position: relative;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.hero-stat__label {
  display: block;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.9px;
  text-transform: uppercase;
  color: #9ba2c6;
}
.hero-stat__value {
  display: block;
  margin-top: 3px;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: #fff;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
}
.hero-stat__value--text {
  font-size: 15px;
  letter-spacing: 0;
  padding-top: 4px;
}
.hero-stat__hint {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: #8f96bb;
}
.btn-hero {
  color: #241a63;
  background: #fff;
  border-color: transparent;
  box-shadow: 0 12px 26px -12px rgba(0, 0, 0, 0.55);
}
.btn-hero:hover {
  background: #f3f1ff;
  filter: none;
}
.btn-hero-ghost {
  color: #e4e6fb;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}
.btn-hero-ghost:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  filter: none;
}

/* ============================ 06. KPI + СПАРК =========================== */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.kpi-grid--lg {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.kpi-grid--auto {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}
.kpi {
  --kpi-color: #6d5cff;
  --kpi-soft: #eeebff;
  position: relative;
  overflow: hidden;
  padding: 16px 18px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xs);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.kpi:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--line-2);
}
.kpi::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--kpi-color);
  opacity: 0.9;
}
.kpi__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.kpi__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  color: var(--kpi-color);
  background: var(--kpi-soft);
}
.kpi__icon svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.kpi__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.1px;
}
.kpi__value {
  margin-top: 2px;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.8px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.kpi__hint {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--muted-2);
}
.kpi__trend {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: var(--r-full);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.2px;
  white-space: nowrap;
  color: var(--ok);
  background: var(--ok-soft);
}
.kpi__trend svg {
  width: 11px;
  height: 11px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.kpi__trend--down {
  color: var(--err);
  background: var(--err-soft);
}
.kpi__trend--flat,
.kpi__trend--neutral {
  color: var(--muted);
  background: var(--surface-3);
}
.kpi--indigo {
  --kpi-color: #6d5cff;
  --kpi-soft: #eeebff;
}
.kpi--emerald {
  --kpi-color: #0f9d67;
  --kpi-soft: #e7f8f0;
}
.kpi--amber {
  --kpi-color: #d08a1c;
  --kpi-soft: #fdf5e3;
}
.kpi--cyan {
  --kpi-color: #0891b2;
  --kpi-soft: #e5f7fb;
}
.kpi--rose {
  --kpi-color: #dc2643;
  --kpi-soft: #fdecef;
}
.kpi--violet {
  --kpi-color: #a855f7;
  --kpi-soft: #f6ecff;
}
.spark {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 30px;
  margin-top: 12px;
}
.spark span {
  flex: 1;
  min-height: 3px;
  border-radius: 2.5px 2.5px 1px 1px;
  background: linear-gradient(180deg, #9b8cff, #6d5cff);
  opacity: 0.9;
}
.kpi--emerald .spark span {
  background: linear-gradient(180deg, #34d399, #0f9d67);
}
.kpi--amber .spark span {
  background: linear-gradient(180deg, #fbbf24, #d08a1c);
}
.kpi--cyan .spark span {
  background: linear-gradient(180deg, #22d3ee, #0891b2);
}
.kpi--rose .spark span {
  background: linear-gradient(180deg, #fb7185, #dc2643);
}
.kpi--violet .spark span {
  background: linear-gradient(180deg, #c084fc, #a855f7);
}

/* ========================== 07. ГРАФИКИ .BARS ========================== */
.chart {
  position: relative;
  margin-top: 4px;
}
.chart::before {
  content: "";
  position: absolute;
  inset: 0 0 26px 0;
  border-radius: var(--r-sm);
  background-image: linear-gradient(to top, #eef0f8 1px, transparent 1px);
  background-size: 100% 33.333%;
  pointer-events: none;
}
.chart--sm::before {
  inset: 0 0 22px 0;
}
.bars {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 152px;
  padding: 10px 2px 0;
}
.bars__col {
  flex: 1;
  display: flex;
  align-items: flex-end;
  height: 100%;
  min-width: 0;
  cursor: default;
}
.bars__bar {
  width: 100%;
  min-height: 3px;
  border-radius: 6px 6px 3px 3px;
  background: linear-gradient(180deg, #9d90ff 0%, #6d5cff 55%, #5a47f0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition: filter 0.15s ease, opacity 0.15s ease;
}
.bars__col:hover .bars__bar {
  filter: brightness(1.12) saturate(1.15);
}
.bars--green .bars__bar {
  background: linear-gradient(180deg, #6ee7b7 0%, #10b981 55%, #0b8f5e 100%);
}
.bars--blue .bars__bar {
  background: linear-gradient(180deg, #7dd3fc 0%, #0ea5e9 55%, #0369a1 100%);
}
.bars-labels {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-top: 8px;
  font-size: 10.5px;
  color: var(--muted-2);
  font-variant-numeric: tabular-nums;
}
.bars-labels span {
  white-space: nowrap;
}
.chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.chart-head__left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.chart-head__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.chart-head__title {
  font-size: 14.5px;
  font-weight: 800;
  letter-spacing: -0.2px;
  color: var(--ink);
}
.card .chart-head__title {
  display: block;
  margin: 0;
  font-size: 14.5px;
}
.card .chart-head__title::before {
  display: none;
}
.chart-head__sub {
  font-size: 11.5px;
  color: var(--muted-2);
}
.chart-head__right {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}
.chart-total {
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.7px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.chart-delta {
  font-size: 10.5px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--r-full);
  color: var(--ok);
  background: var(--ok-soft);
}
.chart-delta--down {
  color: var(--err);
  background: var(--err-soft);
}
.chart-delta--flat {
  color: var(--muted);
  background: var(--surface-3);
}
.chart-empty {
  margin: 10px 0 0;
  padding: 9px 12px;
  border-radius: var(--r-sm);
  background: var(--surface-2);
  border: 1px dashed var(--line-2);
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.5;
}
.chart--empty::before {
  opacity: 0.45;
}
.chart--empty .bars {
  height: 130px;
  opacity: 0.32;
}
.chart-empty-state {
  position: absolute;
  inset: 0 0 26px 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 18px;
  text-align: center;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
  pointer-events: none;
}
.chart-empty-state svg {
  width: 22px;
  height: 22px;
  stroke: var(--muted-2);
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 11.5px;
  color: var(--muted);
}
.legend__item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.legend__dot {
  width: 8px;
  height: 8px;
  border-radius: 3px;
  background: var(--brand-500);
}
.legend__dot--green {
  background: #10b981;
}
.legend__dot--blue {
  background: #0ea5e9;
}

/* ==================== 08. ПРОГРЕСС, ЧЕК-ЛИСТ, МЕТРЫ ==================== */
.progress {
  height: 10px;
  border-radius: var(--r-full);
  background: var(--surface-3);
  overflow: hidden;
  margin: 10px 0 14px;
  box-shadow: inset 0 1px 2px rgba(16, 24, 40, 0.05);
}
.progress__bar {
  height: 100%;
  border-radius: var(--r-full);
  background: var(--grad);
  box-shadow: 0 0 12px rgba(109, 92, 255, 0.45);
  transition: width 0.35s ease;
}
.progress--ok .progress__bar {
  background: linear-gradient(135deg, #34d399, #0f9d67);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.35);
}
.checklist {
  display: grid;
  gap: 8px;
}
.checklist__item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: #fff;
  color: var(--ink-2);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.35;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.12s ease;
}
.checklist__item:hover {
  text-decoration: none;
  border-color: var(--brand-300);
  background: var(--brand-50);
  transform: translateX(2px);
}
.checklist__item.is-done {
  background: #f6fcf9;
  border-color: #cde9db;
  color: #2c5f3d;
}
.checklist__item.is-done:hover {
  border-color: #9fd8bb;
  background: #f0faf5;
}
.checklist__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  background: var(--surface-3);
}
.checklist__icon svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.checklist__item.is-done .checklist__icon {
  color: #0f9d67;
  background: #d9f3e6;
}
.checklist__label {
  flex: 1;
  min-width: 0;
}
.checklist__cta {
  margin-left: auto;
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 800;
  color: var(--brand-600);
  white-space: nowrap;
}
.checklist__cta svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.checklist-progress {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 11.5px;
  color: var(--muted);
}
.checklist-progress b {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.checklist-done {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 12px;
  border-radius: var(--r-md);
  background: #f1fbf6;
  border: 1px solid #cde9db;
  color: #23603f;
  font-size: 12.5px;
  line-height: 1.45;
}
.checklist-done svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin-top: 1px;
  stroke: #0f9d67;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.meter {
  display: grid;
  gap: 5px;
  margin-top: 12px;
}
.meter__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 11.5px;
  color: var(--muted);
}
.meter__value {
  font-weight: 800;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.meter__track {
  height: 7px;
  border-radius: var(--r-full);
  background: var(--surface-3);
  overflow: hidden;
}
.meter__fill {
  height: 100%;
  border-radius: var(--r-full);
  background: var(--grad);
}
.meter--emerald .meter__fill {
  background: linear-gradient(135deg, #34d399, #0f9d67);
}
.meter--amber .meter__fill {
  background: linear-gradient(135deg, #fbbf24, #d08a1c);
}
.meter--rose .meter__fill {
  background: linear-gradient(135deg, #fb7185, #dc2643);
}

/* ============================== 09. ТАБЛИЦЫ ============================ */
.table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}
.table th,
.table td {
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
.table th {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--muted-2);
  white-space: nowrap;
  background: var(--surface-2);
}
.table th:first-child {
  border-top-left-radius: var(--r-sm);
}
.table th:last-child {
  border-top-right-radius: var(--r-sm);
}
.table tbody tr {
  transition: background 0.12s ease;
}
.table tbody tr:nth-child(even) {
  background: #fbfbfe;
}
.table tbody tr:hover {
  background: var(--brand-50);
}
.table tbody tr:last-child td {
  border-bottom: none;
}
.table td {
  color: var(--ink-2);
}
.table code {
  font-size: 11.5px;
}
.table .tag {
  margin-right: 3px;
}
.table--compact th,
.table--compact td {
  padding: 7px 9px;
  font-size: 12px;
}
.table--sticky tbody tr:hover {
  background: var(--brand-50);
}
.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: #fff;
  max-height: 460px;
  scrollbar-width: thin;
}
.table-wrap .table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--surface-2);
  box-shadow: 0 1px 0 var(--line);
}
.table--flush th:first-child,
.table--flush th:last-child {
  border-radius: 0;
}
.table-empty {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 26px 20px;
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.5;
}
.table-empty svg {
  width: 26px;
  height: 26px;
  stroke: var(--muted-2);
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.table-actions {
  white-space: nowrap;
}
.table-actions form {
  display: inline-block;
  margin-right: 6px;
}
.table-actions form:last-child {
  margin-right: 0;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}
.actions form {
  display: inline-block;
  margin: 0;
}
.actions details {
  margin: 0;
}

/* ============================== 10. КНОПКИ ============================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: #fff;
  color: var(--ink-2);
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.35;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease,
    box-shadow 0.14s ease, transform 0.12s ease;
}
.btn:hover {
  background: var(--surface-2);
  border-color: var(--brand-300);
  color: var(--brand-700);
  text-decoration: none;
}
.btn:active {
  transform: translateY(1px);
}
.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}
.btn svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn-primary {
  color: #fff;
  border-color: transparent;
  background: var(--grad);
  box-shadow: 0 10px 22px -12px rgba(109, 92, 255, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.btn-primary:hover {
  color: #fff;
  background: linear-gradient(135deg, #7a68ff 0%, #b268f9 100%);
  border-color: transparent;
  box-shadow: 0 14px 28px -12px rgba(109, 92, 255, 0.9);
}
.btn-danger {
  color: var(--err);
  background: #fff;
  border-color: #f3c6cd;
}
.btn-danger:hover {
  color: #b41c35;
  background: var(--err-soft);
  border-color: #eba9b5;
}
.btn-ghost {
  color: var(--muted);
  background: transparent;
  border-color: transparent;
}
.btn-ghost:hover {
  color: var(--brand-700);
  background: var(--brand-50);
  border-color: transparent;
}
.btn-soft {
  color: var(--brand-700);
  background: var(--brand-50);
  border-color: var(--brand-100);
}
.btn-soft:hover {
  color: var(--brand-700);
  background: var(--brand-100);
  border-color: var(--brand-200);
}
.btn-light {
  background: #fff;
  color: var(--ink-2);
  border-color: var(--line-2);
}
.btn-sm {
  padding: 5px 10px;
  font-size: 11.5px;
  border-radius: 8px;
  gap: 5px;
}
.btn-sm svg {
  width: 13px;
  height: 13px;
}
.btn-block {
  width: 100%;
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

/* ========================= 11. БЕЙДЖИ И ТЕГИ =========================== */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 9px;
  border-radius: var(--r-full);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.7;
  white-space: nowrap;
  color: #4b5568;
  background: var(--surface-3);
}
.tag-trial {
  color: #4a5060;
  background: #eef0f5;
}
.tag-basic {
  color: #15568f;
  background: #e3f0fb;
}
.tag-pro {
  color: #4b2a8f;
  background: #f3edff;
}
.tag-unlimited {
  color: #0f6b47;
  background: #e6f6ec;
}
.tag-ok {
  color: #0b7a4f;
  background: var(--ok-soft);
}
.tag-off {
  color: #b3261e;
  background: var(--err-soft);
}
.tag-err {
  color: #b3261e;
  background: var(--err-soft);
}
.tag-warn {
  color: #8a5a00;
  background: var(--warn-soft);
}
.tag-muted {
  color: #4a5060;
  background: #eef0f5;
}
.tag-primary {
  color: #fff;
  background: var(--grad);
  box-shadow: 0 6px 14px -8px rgba(109, 92, 255, 0.9);
}
.tag-info {
  color: #0b6e88;
  background: var(--info-soft);
}
.tag-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 6px;
}
.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px 3px 8px;
  border-radius: var(--r-full);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.2px;
  white-space: nowrap;
  color: var(--muted);
  background: var(--surface-3);
}
.status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 7px;
}
.status--ok {
  color: #0b7a4f;
  background: var(--ok-soft);
}
.status--err {
  color: #b3261e;
  background: var(--err-soft);
}
.status--warn {
  color: var(--warn);
  background: var(--warn-soft);
}
.status--off {
  color: #6b7280;
  background: #eef0f5;
}
.badge-xstorm {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--r-full);
  color: #fff;
  background: var(--grad);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-decoration: none;
}
a.badge-xstorm:hover {
  filter: brightness(1.06);
  text-decoration: none;
}

/* =============================== 12. ФОРМЫ ============================= */
.field {
  display: block;
  margin-bottom: 13px;
}
.field__label {
  display: block;
  margin-bottom: 5px;
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-2);
}
.field__error {
  display: block;
  margin-top: 5px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--err);
}
.field__hint,
.field .hint {
  display: block;
  margin-top: 5px;
  font-size: 11.5px;
  color: var(--muted-2);
  line-height: 1.45;
}
.field input,
.field select,
.field textarea {
  width: 100%;
}
.field-check {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 10px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
}
.field-check input[type="checkbox"],
.field-check input[type="radio"] {
  accent-color: var(--brand-600);
  width: 15px;
  height: 15px;
}
input,
select,
textarea {
  font: inherit;
  font-size: 13px;
  padding: 8px 11px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-2);
  border-radius: var(--r-sm);
  transition: border-color 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}
input::placeholder,
textarea::placeholder {
  color: #a7aebe;
}
input:hover,
select:hover,
textarea:hover {
  border-color: #c3c7da;
}
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: var(--ring);
}
input[readonly] {
  background: var(--surface-2);
  color: var(--ink-2);
  font-family: var(--mono);
  font-size: 12px;
}
input[type="checkbox"],
input[type="radio"] {
  width: auto;
  padding: 0;
}
select {
  appearance: none;
  padding-right: 30px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23667085' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.input-sm {
  width: auto !important;
  padding: 5px 8px !important;
  font-size: 12px !important;
  border-radius: 7px !important;
}
.input-days {
  width: 118px !important;
}
.inline-form {
  display: inline-flex;
  gap: 9px;
  align-items: flex-end;
  flex-wrap: wrap;
  margin: 0 10px 10px 0;
}
.inline-form .field {
  margin-bottom: 0;
}
.form-field label {
  display: block;
  margin: 10px 0 4px;
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-2);
}
.form-field input,
.form-field select {
  width: 100%;
}
.form-field .hint {
  margin-top: 4px;
  font-size: 11.5px;
  color: var(--muted-2);
}
.form-section + .form-section {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.form-section__title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--muted-2);
}
.form-section__title svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 16px;
}
.form-hint {
  font-size: 11.5px;
  color: var(--muted-2);
  line-height: 1.5;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 14px;
}

/* =========================== 13. FLASH-СООБЩЕНИЯ ======================= */
.flash {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 14px;
  margin-bottom: 16px;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  box-shadow: var(--shadow-xs);
}
.flash-ok {
  color: #0b6b47;
  background: #eafaf2;
  border-color: #c4ead8;
}
.flash-err {
  color: #a91d33;
  background: var(--err-soft);
  border-color: #f3c6cd;
}
.flash-token {
  color: #3f2f86;
  background: var(--brand-50);
  border-color: var(--brand-200);
  font-family: var(--mono);
  word-break: break-all;
}
.flash a {
  color: inherit;
  font-weight: 800;
  text-decoration: underline;
}
.api-key-row {
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 420px;
}
.api-key-row input {
  flex: 1;
  min-width: 0;
}
.api-key-row button {
  flex: 0 0 auto;
}
.flash.api-key-row {
  max-width: none;
  display: flex;
}

/* ========================= 14. ЗАГОЛОВОК СТРАНИЦЫ ====================== */
.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.page-head__main {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.page-head__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 14px;
  color: #fff;
  background: var(--grad);
  box-shadow: 0 12px 26px -14px rgba(109, 92, 255, 0.9);
}
.page-head__icon svg {
  width: 23px;
  height: 23px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.page-title {
  margin: 0 0 3px;
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--ink);
}
.page-sub {
  margin: 0;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
}
.page-sub a {
  font-weight: 700;
}
.page-actions {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

/* ========================== 15. СЕТКИ И УТИЛИТЫ ======================== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.cols-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.cols-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.dash-grid {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
}
.dash-grid--2-1 {
  grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr);
}
.dash-grid--1-2 {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.9fr);
}
.dash-grid--1-1 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.dash-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.dash-grid > .card,
.cols-2 > .card,
.cols-3 > .card {
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.cols-2,
.cols-3,
.dash-grid {
  margin-bottom: 18px;
}
.muted {
  color: var(--muted);
}
.muted-2 {
  color: var(--muted-2);
}
.tiny {
  font-size: 11px;
}
.spacer {
  height: 8px;
}
.nowrap {
  white-space: nowrap;
}
.mono {
  font-family: var(--mono);
}
.tabular {
  font-variant-numeric: tabular-nums;
}
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.toolbar h1 {
  margin: 0;
  font-size: 20px;
}
.toolbar h2 {
  margin: 0;
}
.toolbar h3 {
  margin: 0;
}
.empty {
  padding: 30px 22px;
  border-radius: var(--r-md);
  border: 1px dashed var(--line-2);
  background: var(--surface-2);
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}
.stat {
  font-size: 12.5px;
  color: var(--muted);
}
.stat b {
  display: block;
  font-size: 18px;
  color: var(--ink);
}
.stat__value {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.15;
}
.stat__label {
  font-size: 12px;
  color: var(--muted);
}
.divider {
  height: 1px;
  background: var(--line);
  margin: 14px 0;
}
.divider--dashed {
  height: 0;
  border-top: 1px dashed var(--line-2);
  background: none;
}
.list-clean {
  list-style: none;
  margin: 0;
  padding: 0;
}
.list-check {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  font-size: 12.5px;
  color: var(--muted);
}
.list-check li {
  position: relative;
  padding-left: 20px;
  line-height: 1.45;
}
.list-check li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  width: auto;
  height: auto;
  border: 0;
  background: none;
  color: #0f9d67;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}
.list-check li b {
  color: var(--ink-2);
}

/* ================= 16. ТОП ИНСТРУМЕНТОВ, СОБЫТИЯ, ДЕЙСТВИЯ ============ */
.tool-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 2px;
}
.tool-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 10px;
  align-items: baseline;
}
.tool-row__name {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--ink-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tool-row__count {
  font-size: 12px;
  font-weight: 800;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.tool-row__track {
  grid-column: 1 / -1;
  height: 6px;
  border-radius: var(--r-full);
  background: var(--surface-3);
  overflow: hidden;
}
.tool-row__fill {
  height: 100%;
  border-radius: var(--r-full);
  background: var(--grad);
}
.tool-row:nth-child(2n) .tool-row__fill {
  background: linear-gradient(90deg, #a855f7, #6d5cff);
}

.event-type {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--ink-2);
}
.event-type__dot {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--brand-500);
}
.event-type__dot--ok {
  background: #10b981;
}
.event-type__dot--warn {
  background: #f59e0b;
}
.event-type__dot--err {
  background: #f43f5e;
}
.event-type__dot--info {
  background: #0ea5e9;
}
.event-time {
  font-size: 11.5px;
  color: var(--muted-2);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.event-payload {
  display: block;
  max-width: 380px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.events-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.quick {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease,
    background 0.15s ease;
}
.quick:hover {
  text-decoration: none;
  border-color: var(--brand-300);
  background: linear-gradient(180deg, #fff, var(--brand-50));
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.quick__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 10px;
  color: var(--brand-600);
  background: var(--grad-soft);
  border: 1px solid rgba(109, 92, 255, 0.12);
}
.quick__icon svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.quick__body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
  line-height: 1.35;
}
.quick b {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
}
.quick__body span {
  font-size: 11px;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.quick__arrow {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  stroke: var(--muted-2);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.15s ease, stroke 0.15s ease;
}
.quick:hover .quick__arrow {
  stroke: var(--brand-600);
  transform: translateX(2px);
}
.quick-actions--list {
  grid-template-columns: 1fr;
}

/* ==================== 17. КАРТОЧКА ПЛАНА И КОМПАНИИ =================== */
.plan-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-xs);
}
.plan-card__top {
  position: relative;
  padding: 18px 20px 16px;
  color: #fff;
  background:
    radial-gradient(320px 200px at 110% -40%, rgba(168, 85, 247, 0.55), transparent 62%),
    linear-gradient(128deg, #1b1745 0%, #2b1d63 60%, #3a1f6f 100%);
}
.plan-card__top::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -60px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 0 0 34px rgba(255, 255, 255, 0.035);
}
.plan-card__eyebrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: #b6b9e2;
}
.plan-card__name {
  margin: 8px 0 2px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: #fff;
}
.plan-card__price {
  font-size: 12.5px;
  color: #c8cbe8;
}
.plan-card__price b {
  font-size: 17px;
  color: #fff;
}
.plan-card__body {
  padding: 16px 20px 18px;
}
.plan-card__period {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 11.5px;
  color: var(--muted);
}
.plan-card__period b {
  color: var(--ink-2);
}
.plan-card__actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.plan-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: var(--r-full);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.3px;
  color: #e6e2ff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
}
.plan-chip--ok {
  color: #baf5d8;
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(52, 211, 153, 0.3);
}

.company-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.company-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: #fff;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.company-row:hover {
  text-decoration: none;
  border-color: var(--brand-300);
  background: var(--brand-50);
}
.company-row__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  color: var(--brand-700);
  background: var(--grad-soft);
  border: 1px solid rgba(109, 92, 255, 0.14);
  text-transform: uppercase;
}
.company-row__info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
  line-height: 1.35;
}
.company-row__name {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.company-row__id {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--muted-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.company-row .tag {
  flex: 0 0 auto;
}
.company-row__arrow {
  width: 14px;
  height: 14px;
  stroke: var(--muted-2);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ============================ 18. КОННЕКТОРЫ ========================== */
.connector-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 18px;
  align-items: stretch;
}
.connector-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 0;
  padding: 18px 20px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}
.connector-card:hover {
  border-color: var(--line-2);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.connector-card.is-connected {
  border-color: rgba(109, 92, 255, 0.28);
  box-shadow: 0 10px 30px -22px rgba(109, 92, 255, 0.8);
}
.connector-card.is-connected::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  background: var(--grad);
}
.connector-card__head {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}
.connector-card__icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  border-radius: 14px;
  font-size: 25px;
  line-height: 1;
  background: linear-gradient(135deg, rgba(109, 92, 255, 0.14), rgba(168, 85, 247, 0.16));
  border: 1px solid rgba(109, 92, 255, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.connector-card__titles {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  flex: 1;
}
.connector-card__titles h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.2px;
}
.connector-card__titles h2::before {
  display: none;
}
.connector-card__chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.connector-card__desc {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--muted);
}
.connector-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  font-size: 11.5px;
  color: var(--muted-2);
  padding: 9px 12px;
  border-radius: var(--r-sm);
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.connector-card__meta b {
  color: var(--ink-2);
}
.connector-card__tools {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  max-height: 92px;
  overflow: auto;
  scrollbar-width: thin;
}
.connector-card__tools code {
  font-size: 10.5px;
  color: #4b2a8f;
  background: #f5f2ff;
  border: 1px solid rgba(109, 92, 255, 0.14);
  border-radius: 6px;
  padding: 2px 6px;
  white-space: nowrap;
}
.connector-card__more {
  display: inline-flex;
  align-items: center;
  font-size: 10.5px;
  font-weight: 800;
  color: var(--brand-600);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  border-radius: 6px;
  padding: 2px 7px;
}
.connector-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.connector-card__actions form {
  margin: 0;
}
.connector-form {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.connector-form .field {
  margin-bottom: 9px;
}
.connector-form .field__label {
  font-size: 11.5px;
}
.connector-form .field__error {
  color: var(--muted-2);
  font-weight: 500;
}
.connector-form__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.connector-hub {
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  border-radius: var(--r-lg);
  border: 1px solid #2a2455;
  background:
    radial-gradient(520px 260px at 108% -40%, rgba(168, 85, 247, 0.45), transparent 60%),
    linear-gradient(120deg, #14162c 0%, #1c1b3d 60%, #261a4c 100%);
  color: #fff;
  padding: 20px 22px;
  box-shadow: var(--shadow-md);
}
.connector-hub__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.connector-hub__title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 800;
  color: #fff;
}
.connector-hub__title svg {
  width: 19px;
  height: 19px;
  stroke: #b9a8ff;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.connector-hub__desc {
  max-width: 720px;
  margin: 0 0 14px;
  font-size: 12.5px;
  line-height: 1.6;
  color: #aeb3d6;
}
.connector-hub__desc b {
  color: #fff;
}
.connector-hub__desc code {
  color: #ded3ff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
}
.connector-hub .api-key-row {
  max-width: none;
}
.connector-hub input[readonly] {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.16);
  color: #f0eeff;
}
.connector-hub__hint {
  margin: 10px 0 0;
  font-size: 11.5px;
  color: #8f95bb;
  line-height: 1.6;
}
.connector-hub__hint code {
  color: #d5ccff;
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.12);
}
.soon-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.soon-item {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 13px;
  border: 1px dashed var(--line-2);
  border-radius: var(--r-md);
  background: var(--surface-2);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.soon-item:hover {
  border-color: var(--brand-300);
  background: var(--brand-50);
}
.soon-item__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 10px;
  font-size: 18px;
  background: #fff;
  border: 1px solid var(--line);
  filter: grayscale(0.15);
}
.soon-item__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.soon-item__body b {
  font-size: 12.5px;
  color: var(--ink);
}
.soon-item__body span {
  font-size: 11.5px;
  color: var(--muted-2);
  line-height: 1.45;
}
.soon-item .tag {
  margin-left: auto;
  flex: 0 0 auto;
}

/* ====================== 19. БИЛЛИНГ В КАБИНЕТЕ ========================= */
.pricing-card {
  position: relative;
  display: flex;
  flex-direction: column;
  margin-bottom: 16px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--card);
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}
.pricing-card:hover {
  border-color: var(--brand-200);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.pricing-card.featured {
  border: 2px solid var(--brand-500);
  box-shadow: 0 20px 44px -28px rgba(109, 92, 255, 0.65);
}
.pricing-card h3 {
  margin: 0 0 4px;
  font-size: 17px;
  font-weight: 800;
}
.pricing-card .plan-name {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--brand-600);
}
.pricing-card .price {
  margin: 8px 0 2px;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.8px;
}
.pricing-card .price small {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}
.pricing-card .per {
  margin-bottom: 12px;
  font-size: 12.5px;
  color: var(--muted);
}
.pricing-card__price {
  margin: 8px 0 2px;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.8px;
}
.pricing-card__price .muted {
  font-size: 13px;
  font-weight: 600;
}
.pricing-card ul {
  display: grid;
  gap: 7px;
  flex: 1;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
  color: var(--muted);
}
.pricing-card__features {
  display: grid;
  gap: 7px;
  flex: 1;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
}
.pricing-card li::before {
  content: "✓";
  margin-right: 8px;
  font-weight: 800;
  color: var(--brand-600);
}
.pricing-card__features li::before {
  content: "✓";
  margin-right: 8px;
  font-weight: 800;
  color: var(--brand-600);
}
.pricing-card .btn {
  width: 100%;
}

/* ========================== 20. АДМИН-ПАНЕЛЬ =========================== */
.admin-sidebar .app-sidebar__brand {
  gap: 10px;
}
.admin-sidebar .brand-logo {
  background: linear-gradient(135deg, #f43f5e 0%, #a855f7 100%);
  box-shadow: 0 10px 24px -10px rgba(244, 63, 94, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
.admin-sidebar .app-sidebar__nav a.active {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.9), rgba(168, 85, 247, 0.85));
  box-shadow: 0 12px 26px -14px rgba(244, 63, 94, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}
.admin-topbar__admin {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--r-full);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, #f43f5e, #a855f7);
  box-shadow: 0 8px 18px -10px rgba(244, 63, 94, 0.8);
}
.admin-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--brand-100);
  background: var(--brand-50);
  font-size: 12.5px;
  color: #4a3d8f;
  line-height: 1.5;
}
.admin-note svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  margin-top: 1px;
  stroke: var(--brand-600);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.admin-note--warn {
  border-color: #f3d9a4;
  background: var(--warn-soft);
  color: #7a5513;
}
.admin-note--warn svg {
  stroke: var(--warn);
}
.kpi-grid--admin {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.kpi-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.admin-kpi {
  padding: 14px 16px 12px;
}
.admin-kpi .kpi__value {
  font-size: 24px;
}
.user-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.user-cell .avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, #6d5cff, #a855f7);
}
.user-cell__meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.35;
}
.user-cell__meta b {
  font-size: 12.5px;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-cell__meta span {
  font-size: 11px;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-cell__meta > span {
  font-size: 11px;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-cell__meta .tag {
  font-size: 9.5px;
  padding: 1px 6px;
  color: #fff;
  background: var(--grad);
}
.user-cell .tag {
  margin-left: 4px;
}
.activity-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 20px;
  padding: 0 7px;
  border-radius: var(--r-full);
  font-size: 10.5px;
  font-weight: 800;
  color: var(--brand-700);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
}

/* ===================== 21. AUTH: СПЛИТ-ЭКРАН ВХОДА ===================== */
.auth-split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  background: var(--bg);
}
.auth-brand {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 26px;
  padding: 36px 44px;
  color: #fff;
  background:
    radial-gradient(640px 420px at 8% -6%, rgba(109, 92, 255, 0.62), transparent 62%),
    radial-gradient(720px 520px at 112% 112%, rgba(168, 85, 247, 0.42), transparent 62%),
    linear-gradient(158deg, #0d0f20 0%, #12152c 52%, #1b1440 100%);
}
.auth-brand::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(90% 70% at 20% 10%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(90% 70% at 20% 10%, #000 0%, transparent 75%);
  pointer-events: none;
}
.auth-brand__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.2px;
}
.auth-brand__top .xstorm-badge {
  height: 22px;
  margin-left: auto;
}
.auth-brand__top .brand-logo {
  width: 40px;
  height: 40px;
  flex-basis: 40px;
  border-radius: 13px;
}
.auth-brand__body {
  position: relative;
  z-index: 1;
  max-width: 520px;
}
.auth-brand__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #b0b5da;
}
.auth-brand__body h1 {
  margin: 0 0 14px;
  font-size: 34px;
  line-height: 1.14;
  font-weight: 800;
  letter-spacing: -0.9px;
  color: #fff;
}
.auth-brand__body p {
  max-width: 450px;
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.65;
  color: #b4bad8;
}
.auth-brand__list {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}
.auth-brand__list li {
  position: relative;
  padding-left: 26px;
  color: #dfe2f6;
  line-height: 1.45;
}
.auth-brand__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgba(74, 222, 128, 0.16);
  border: 1px solid rgba(74, 222, 128, 0.35);
}
.auth-brand__list li::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 6.5px;
  width: 6px;
  height: 3.5px;
  border-left: 1.8px solid #6ee7b7;
  border-bottom: 1.8px solid #6ee7b7;
  transform: rotate(-45deg);
}
.auth-brand__list li b {
  color: #fff;
}
.auth-brand__visual {
  position: relative;
  z-index: 1;
  margin-top: 4px;
  max-width: 520px;
}
.auth-visual {
  position: relative;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.055);
  box-shadow: 0 30px 70px -38px rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
}
.auth-visual__bar {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 9px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.03);
}
.auth-visual__bar span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
}
.auth-visual__bar span:nth-child(1) {
  background: #f87171;
}
.auth-visual__bar span:nth-child(2) {
  background: #fbbf24;
}
.auth-visual__bar span:nth-child(3) {
  background: #34d399;
}
.auth-visual__body {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 12px;
  padding: 13px;
}
.auth-visual__side {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding-right: 10px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}
.auth-visual__side i {
  height: 9px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.11);
}
.auth-visual__side i:first-child {
  background: linear-gradient(90deg, #6d5cff, #a855f7);
  width: 100%;
}
.auth-visual__side i:nth-child(2) {
  width: 82%;
}
.auth-visual__side i:nth-child(3) {
  width: 92%;
}
.auth-visual__side i:nth-child(4) {
  width: 70%;
}
.auth-visual__main {
  min-width: 0;
}
.auth-visual__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  margin-bottom: 10px;
}
.auth-visual__stats div {
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
}
.auth-visual__chart {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 74px;
  padding: 8px 8px 0;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
}
.auth-visual__chart i {
  flex: 1;
  min-height: 4px;
  border-radius: 3px 3px 1px 1px;
  background: linear-gradient(180deg, #a78bfa, #6d5cff);
}
.auth-visual__chart i:nth-child(3n) {
  background: linear-gradient(180deg, #e879f9, #a855f7);
}
.auth-visual__chart i:nth-child(4n) {
  background: linear-gradient(180deg, #67e8f9, #0891b2);
}
.auth-visual__badge {
  position: absolute;
  right: 12px;
  bottom: 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: var(--r-full);
  font-size: 10.5px;
  font-weight: 800;
  color: #dff7ea;
  background: rgba(8, 12, 26, 0.78);
  border: 1px solid rgba(52, 211, 153, 0.42);
  box-shadow: 0 16px 30px -18px rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.auth-visual__badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.18);
}
.auth-brand__foot {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 11.5px;
  color: #7d84a8;
}
.auth-brand__foot a {
  color: #a7aed6;
  font-weight: 600;
}
.auth-brand__foot a:hover {
  color: #fff;
}
.auth-form-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 28px;
  background:
    radial-gradient(620px 420px at 90% -10%, rgba(109, 92, 255, 0.09), transparent 62%),
    radial-gradient(520px 380px at 0% 110%, rgba(168, 85, 247, 0.08), transparent 62%),
    var(--bg);
}
.auth-box {
  width: 100%;
  max-width: 430px;
  padding: 32px 32px 26px;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  background: var(--card);
  box-shadow: 0 30px 80px -46px rgba(28, 20, 56, 0.55);
}
.auth-box__brand {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 20px;
  font-size: 14px;
  font-weight: 800;
  color: var(--ink);
}
.auth-box__brand .xstorm-badge {
  height: 22px;
  margin-left: auto;
}
.auth-box h2 {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
}
.auth-box__sub {
  margin: 0 0 20px;
  font-size: 13px;
  line-height: 1.55;
}
.auth-form .field {
  margin-bottom: 14px;
}
.auth-form .field__label {
  font-size: 11.5px;
  letter-spacing: 0.2px;
}
.auth-form input {
  padding: 10px 12px;
  font-size: 13.5px;
  border-radius: 10px;
}
.auth-form .btn-block {
  margin-top: 4px;
  padding: 11px 16px;
  font-size: 13.5px;
  border-radius: 11px;
}
.auth-box__foot {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
}
.auth-box__foot a {
  font-weight: 700;
}
.auth-alt {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--line-2);
  font-size: 12.5px;
}
.auth-alt summary {
  display: flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  color: var(--muted);
  font-weight: 600;
  list-style: none;
}
.auth-alt summary::-webkit-details-marker {
  display: none;
}
.auth-alt summary::before {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 1.8px solid var(--muted-2);
  border-bottom: 1.8px solid var(--muted-2);
  transform: rotate(-45deg);
  transition: transform 0.15s ease;
}
.auth-alt[open] summary::before {
  transform: rotate(45deg);
}
.auth-alt summary:hover {
  color: var(--brand-600);
}
.auth-alt .auth-form {
  margin-top: 12px;
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 6px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted-2);
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.code-input {
  text-align: center;
  font-size: 30px !important;
  font-weight: 700;
  letter-spacing: 14px;
  text-indent: 14px;
  font-family: var(--mono) !important;
  padding: 12px 8px !important;
  border-radius: 12px !important;
  background: var(--surface-2) !important;
  border: 1px solid var(--line-2) !important;
}
.code-input:focus {
  background: #fff !important;
  box-shadow: var(--ring);
}
.code-note {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 14px;
  font-size: 11.5px;
  color: var(--muted-2);
  line-height: 1.5;
}
.code-note svg {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  margin-top: 1px;
  stroke: var(--muted-2);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ====================== 22. ПРОЧЕЕ (OAuth, пустые, код) ================ */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 28px 20px;
  background:
    radial-gradient(640px 440px at 10% -8%, rgba(109, 92, 255, 0.14), transparent 62%),
    radial-gradient(640px 440px at 108% 110%, rgba(168, 85, 247, 0.12), transparent 62%),
    var(--bg);
}
.auth-card {
  width: 100%;
  max-width: 470px;
  margin: 0;
  padding: 28px 30px;
  border-radius: var(--r-xl);
  box-shadow: 0 30px 80px -50px rgba(28, 20, 56, 0.5);
}
.auth-card h1 {
  margin: 0 0 14px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.4px;
}
.auth-card__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}
.auth-card__brand img {
  height: 24px;
}
.company-picker {
  display: grid;
  gap: 10px;
  margin: 14px 0;
}
.company-picker__item {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 12px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease;
}
.company-picker__item:hover {
  border-color: var(--brand-300);
  background: var(--brand-50);
}
.company-picker__item:has(input:checked) {
  border-color: var(--brand-500);
  background: var(--brand-50);
  box-shadow: var(--ring);
}
.company-picker__item input {
  accent-color: var(--brand-600);
}
.company-picker__title {
  font-size: 13.5px;
  font-weight: 700;
}
.company-picker__id {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted-2);
  word-break: break-all;
}
.progress-note {
  font-size: 11.5px;
  color: var(--muted-2);
}
.avatar-stack {
  display: flex;
  align-items: center;
}
.avatar-stack span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  font-size: 10px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #6d5cff, #a855f7);
  border: 2px solid #fff;
  margin-left: -7px;
}
.avatar-stack span:first-child {
  margin-left: 0;
}

/* ============================== 23. АДАПТИВ ============================ */
@media (max-width: 1280px) {
  .app-content {
    padding: 24px 22px 48px;
  }
  .hero__grid {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 22px;
  }
  .hero__title {
    font-size: 26px;
  }
  .connector-grid {
    gap: 16px;
  }
}
@media (max-width: 1180px) {
  .dash-grid--2-1,
  .dash-grid--1-2 {
    grid-template-columns: 1fr;
  }
  .dash-grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kpi-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .connector-grid {
    grid-template-columns: 1fr;
  }
  .soon-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hero__grid {
    grid-template-columns: 1fr;
  }
  .hero__stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
@media (max-width: 1023px) {
  .app-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 60;
    transform: translateX(-104%);
    transition: transform 0.28s cubic-bezier(0.4, 0.14, 0.3, 1);
    box-shadow: 0 40px 90px -30px rgba(5, 6, 18, 0.85);
  }
  body.sidebar-open .app-sidebar {
    transform: none;
  }
  body.sidebar-open {
    overflow: hidden;
  }
  .app-burger {
    display: inline-flex;
  }
  .app-topbar {
    padding: 10px 18px;
  }
  .app-content {
    padding: 20px 18px 48px;
  }
  .topbar-link {
    display: none;
  }
  .topbar-user__name {
    display: none;
  }
  .topbar-divider {
    display: none;
  }
  .auth-split {
    grid-template-columns: 1fr;
  }
  .auth-brand {
    display: none;
  }
  .auth-form-side {
    min-height: 100vh;
    min-height: 100dvh;
    padding: 28px 18px;
  }
}
@media (max-width: 900px) {
  .cols-2,
  .cols-3 {
    grid-template-columns: 1fr;
  }
  .dash-grid--3,
  .dash-grid--1-1 {
    grid-template-columns: 1fr;
  }
  .page-head {
    flex-direction: column;
  }
  .page-head__main {
    align-items: flex-start;
  }
  .quick-actions {
    grid-template-columns: 1fr;
  }
  .hero {
    padding: 24px 22px;
  }
  .hero__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .auth-box {
    padding: 26px 22px 22px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  /* На узких экранах таблицы внутри карточек прокручиваются, а не ломают вёрстку. */
  .card {
    overflow-x: auto;
  }
  .app-topbar__right .btn-label {
    display: none;
  }
  .app-topbar__right .admin-topbar__admin {
    display: none;
  }
  .app-topbar__right .btn-soft {
    padding: 5px 8px;
  }
  .kpi-grid,
  .kpi-grid--lg,
  .kpi-grid--admin,
  .kpi-grid--3 {
    grid-template-columns: 1fr;
  }
  .grid--2 {
    grid-template-columns: 1fr;
  }
  .soon-grid {
    grid-template-columns: 1fr;
  }
  .app-content {
    padding: 16px 14px 44px;
  }
  .app-topbar {
    min-height: 58px;
    padding: 8px 14px;
    gap: 8px;
  }
  .app-topbar__right {
    gap: 6px;
  }
  .app-topbar__page {
    font-size: 15px;
  }
  .hero__title {
    font-size: 23px;
  }
  .hero {
    border-radius: var(--r-lg);
  }
  .bars {
    height: 118px;
  }
  .card {
    padding: 15px 16px;
  }
  .connector-card {
    padding: 15px 16px;
  }
  .connector-card__icon {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
    font-size: 22px;
  }
  .page-title {
    font-size: 20px;
  }
  .table {
    font-size: 12px;
  }
  .table th,
  .table td {
    padding: 8px 9px;
  }
  .api-key-row {
    flex-wrap: wrap;
  }
  .api-key-row input {
    flex: 1 1 100%;
  }
  .api-key-row button {
    flex: 1 1 auto;
  }
  .auth-box h2 {
    font-size: 21px;
  }
  .code-input {
    font-size: 25px !important;
    letter-spacing: 10px;
    text-indent: 10px;
  }
  .inline-form {
    width: 100%;
    margin-right: 0;
  }
  .inline-form .field {
    flex: 1 1 100%;
  }
  .inline-form input,
  .inline-form select {
    width: 100% !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
