/* NEXIS — UI-kit. Темы: html по умолчанию тёмная область; html[data-theme="light"] = светлая.
   Сайдбар использует --su-sidebar-* (тёмные по умолчанию, светлые в html[data-theme="light"]). Дополняет tailwind.min.css.
   Шрифты: system stack, без внешнего @import — парсинг CSS не ждёт Google Fonts (важно при блокировках CDN). */

/* Единый носитель переменных — html (без дублирования с :root), светлая тема повышает специфичность */
html {
  transition: background-color 0.3s ease, color 0.3s ease;
  --su-border-color: var(--su-border);
  /* Тёмная тема: явный фиолетовый «свечение» (без сильного отрицат. spread — он убивает glow) */
  --su-card-shadow:
    0 1px 0 0 rgba(255, 255, 255, 0.1),
    0 0 0 1px rgba(167, 139, 250, 0.42),
    0 4px 14px rgba(0, 0, 0, 0.52),
    0 20px 44px rgba(0, 0, 0, 0.74),
    0 0 44px rgba(167, 139, 250, 0.48),
    0 0 72px rgba(124, 58, 237, 0.28);
  --su-card-shadow-lg:
    0 1px 0 0 rgba(255, 255, 255, 0.11),
    0 0 0 1px rgba(167, 139, 250, 0.48),
    0 8px 22px rgba(0, 0, 0, 0.58),
    0 32px 58px rgba(0, 0, 0, 0.8),
    0 0 52px rgba(167, 139, 250, 0.55),
    0 0 90px rgba(139, 92, 246, 0.32);
  --su-card-shadow-xl:
    0 1px 0 0 rgba(255, 255, 255, 0.12),
    0 0 0 2px rgba(167, 139, 250, 0.58),
    0 12px 30px rgba(0, 0, 0, 0.64),
    0 42px 84px rgba(0, 0, 0, 0.82),
    0 0 56px rgba(167, 139, 250, 0.62),
    0 0 110px rgba(167, 139, 250, 0.38);
  --su-sidebar-bg: #1e293b;
  --su-sidebar-border: #334155;
  --su-sidebar-text: #f1f5f9;
  --su-sidebar-text-muted: #94a3b8;
  --su-sidebar-hover-bg: rgba(167, 139, 250, 0.12);
  --su-sidebar-active-bg: rgba(167, 139, 250, 0.15);

  --su-accent: #a78bfa;
  --su-success: #34d399;
  --su-error: #f87171;
  --su-warning: #fbbf24;

  --su-radius: 8px;
  --su-tap-min: 44px;

  /* Основная область — тёмная по умолчанию */
  --su-bg-app: #0f172a;
  --su-bg-card: #243044;
  --su-text: #f1f5f9;
  --su-text-muted: #94a3b8;
  --su-border: #334155;
  --su-input-bg: rgba(15, 23, 42, 0.6);
  --su-nested-bg: rgba(15, 23, 42, 0.4);
  --su-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.35), 0 4px 6px -4px rgb(0 0 0 / 0.35);
  --su-icon-btn-bg: rgba(30, 41, 59, 0.8);
  --su-btn-secondary-hover: rgba(51, 65, 85, 0.4);
  --su-table-head-bg: rgba(51, 65, 85, 0.5);
  --su-table-row-hover: rgba(167, 139, 250, 0.08);

  background-color: var(--su-bg-app);
  min-height: 100vh;
}

html[data-theme="light"] {
  /* Премиальная светлая тема: воздух, фиолетовый подтон (Linear / Notion / Stripe) */
  --su-card-shadow:
    0 1px 2px rgba(139, 92, 246, 0.05),
    0 0 0 1px rgba(139, 92, 246, 0.1),
    0 2px 10px rgba(124, 58, 237, 0.06),
    0 10px 36px rgba(139, 92, 246, 0.09);
  --su-card-shadow-lg:
    0 1px 3px rgba(139, 92, 246, 0.06),
    0 0 0 1px rgba(139, 92, 246, 0.12),
    0 4px 18px rgba(124, 58, 237, 0.07),
    0 18px 52px rgba(139, 92, 246, 0.11);
  --su-card-shadow-xl:
    0 2px 8px rgba(124, 58, 237, 0.09),
    0 0 0 1px rgba(124, 58, 237, 0.2),
    0 8px 32px rgba(124, 58, 237, 0.13),
    0 26px 60px rgba(139, 92, 246, 0.14),
    0 0 96px rgba(167, 139, 250, 0.12);
  --su-sidebar-bg: rgba(255, 255, 255, 0.72);
  --su-sidebar-border: rgba(139, 92, 246, 0.12);
  --su-sidebar-text: #172033;
  --su-sidebar-text-muted: #6b6a80;
  --su-sidebar-hover-bg: rgba(139, 92, 246, 0.07);
  --su-sidebar-active-bg: rgba(124, 58, 237, 0.11);

  --su-bg-app: #f5f7fb;
  --su-bg-card: #ffffff;
  --su-text: #172033;
  --su-text-muted: #6b6a80;
  --su-border: rgba(139, 92, 246, 0.14);
  --su-input-bg: #ffffff;
  --su-nested-bg: rgba(139, 92, 246, 0.042);
  --su-accent: #7c3aed;
  --su-shadow-lg:
    0 4px 7px rgba(124, 58, 237, 0.05),
    0 18px 48px rgba(139, 92, 246, 0.1),
    0 0 0 1px rgba(139, 92, 246, 0.08);
  --su-icon-btn-bg: rgba(255, 255, 255, 0.92);
  --su-btn-secondary-hover: rgba(139, 92, 246, 0.07);
  --su-table-head-bg: rgba(245, 247, 251, 0.92);
  --su-table-row-hover: rgba(139, 92, 246, 0.085);
}

.su-app {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  background-color: var(--su-bg-app);
  color: var(--su-text);
  font-size: 15px;
  line-height: 1.5;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.su-app {
  transition: background-color 0.3s ease, color 0.3s ease;
}

@keyframes su-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes su-skeleton-pulse {
  0%,
  100% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.85;
  }
}

@keyframes su-skeleton-shimmer {
  0% {
    background-position: 120% 0;
  }
  100% {
    background-position: -120% 0;
  }
}

.su-content-fade {
  animation: su-fade-in 300ms ease-out forwards;
}

.su-skeleton {
  border-radius: var(--su-radius);
  --su-sk-mid: rgba(167, 139, 250, 0.24);
  background: linear-gradient(
    100deg,
    var(--su-nested-bg) 0%,
    var(--su-nested-bg) 32%,
    var(--su-sk-mid) 50%,
    var(--su-nested-bg) 68%,
    var(--su-nested-bg) 100%
  );
  background-size: 220% 100%;
  animation: su-skeleton-shimmer 2s ease-in-out infinite;
  will-change: background-position;
}

.su-skeleton-line {
  height: 14px;
  margin-bottom: 10px;
}

.su-skeleton-line:last-child {
  margin-bottom: 0;
  width: 72%;
}

.su-skeleton-metric {
  height: 88px;
  width: 100%;
}

.su-skeleton-table-row td {
  padding: 12px 16px;
}

.su-skeleton-cell {
  height: 16px;
  border-radius: 4px;
}

/* Фон body: класс выставляет theme.js (в выражениях Alpine window.SalonTheme недоступен без window.)
   Токены сайдбара дублируем здесь: часть прокси/клиентов отдаёт старый salon-ui.css без блока html[data-theme]. */
body.su-app.su-theme-light {
  --su-sidebar-bg: rgba(255, 255, 255, 0.72);
  --su-sidebar-border: rgba(139, 92, 246, 0.12);
  --su-sidebar-text: #172033;
  --su-sidebar-text-muted: #6b6a80;
  --su-sidebar-hover-bg: rgba(139, 92, 246, 0.07);
  --su-sidebar-active-bg: rgba(124, 58, 237, 0.11);

  background-color: #f5f7fb;
  color: #172033;
}

/* Премиальная светлая тема: стекло, таблицы, кнопки, пустые состояния, скелетоны */
html[data-theme="light"] .su-sidebar-inner,
body.su-app.su-theme-light .su-sidebar-inner {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-right: 1px solid rgba(139, 92, 246, 0.12);
}

html[data-theme="light"] .su-topbar,
body.su-app.su-theme-light .su-topbar {
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(139, 92, 246, 0.12);
}

html[data-theme="light"] .su-sidebar-link-active,
body.su-app.su-theme-light .su-sidebar-link-active {
  font-weight: 600;
  color: #7c3aed;
  background: rgba(124, 58, 237, 0.12);
  box-shadow: inset 0 0 0 1px rgba(124, 58, 237, 0.12);
}

html[data-theme="light"] .su-table thead th,
body.su-app.su-theme-light .su-table thead th {
  font-weight: 500;
  font-size: 0.75rem;
  color: #8b879c;
}

html[data-theme="light"] .su-btn,
body.su-app.su-theme-light .su-btn {
  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease,
    filter 0.2s ease,
    opacity 0.2s ease,
    box-shadow 0.2s ease;
}

html[data-theme="light"] .su-btn-primary,
body.su-app.su-theme-light .su-btn-primary {
  box-shadow:
    0 1px 2px rgba(124, 58, 237, 0.14),
    0 4px 16px rgba(124, 58, 237, 0.24);
}

html[data-theme="light"] .su-btn-primary:hover:not(:disabled),
body.su-app.su-theme-light .su-btn-primary:hover:not(:disabled) {
  filter: brightness(1.05);
  box-shadow:
    0 2px 6px rgba(124, 58, 237, 0.16),
    0 10px 32px rgba(124, 58, 237, 0.32);
}

html[data-theme="light"] .su-btn-secondary:hover:not(:disabled),
body.su-app.su-theme-light .su-btn-secondary:hover:not(:disabled) {
  background-color: rgba(139, 92, 246, 0.07);
  border-color: rgba(124, 58, 237, 0.28);
}

html[data-theme="light"] .su-icon-btn:hover,
body.su-app.su-theme-light .su-icon-btn:hover {
  background: rgba(139, 92, 246, 0.06);
  border-color: rgba(124, 58, 237, 0.22);
}

html[data-theme="light"] .su-page-btn:hover:not(:disabled),
body.su-app.su-theme-light .su-page-btn:hover:not(:disabled) {
  background: rgba(139, 92, 246, 0.06);
  border-color: rgba(124, 58, 237, 0.18);
}

html[data-theme="light"] .su-page-btn--active,
body.su-app.su-theme-light .su-page-btn--active {
  background: rgba(124, 58, 237, 0.1);
  box-shadow: 0 0 0 1px rgba(124, 58, 237, 0.15);
}

html[data-theme="light"] .su-page-btn,
body.su-app.su-theme-light .su-page-btn {
  transition:
    color 0.15s ease,
    background-color 0.15s ease,
    border-color 0.15s ease;
}

html[data-theme="light"] .su-skeleton,
body.su-app.su-theme-light .su-skeleton {
  --su-sk-mid: rgba(124, 58, 237, 0.2);
}

html[data-theme="light"] .su-table-wrap > .su-empty-block,
body.su-app.su-theme-light .su-table-wrap > .su-empty-block {
  background: rgba(139, 92, 246, 0.04);
}

html[data-theme="light"] .su-empty-block svg,
body.su-app.su-theme-light .su-empty-block svg {
  color: #7c3aed;
  opacity: 0.32;
}

html[data-theme="light"] .su-ai-placeholder,
body.su-app.su-theme-light .su-ai-placeholder {
  border-color: rgba(139, 92, 246, 0.22);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(249, 247, 255, 0.92) 100%);
  box-shadow:
    0 1px 2px rgba(139, 92, 246, 0.05),
    0 0 0 1px rgba(139, 92, 246, 0.1),
    0 2px 10px rgba(124, 58, 237, 0.06),
    0 10px 36px rgba(139, 92, 246, 0.09);
  box-shadow: var(--su-card-shadow);
}

.su-text-muted {
  color: var(--su-text-muted);
}

.su-text-small {
  font-size: 12px;
  color: var(--su-text-muted);
}

.su-heading-page {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--su-text);
}

@media (min-width: 768px) {
  .su-heading-page {
    font-size: 1.25rem;
  }
}

.su-card {
  /* Тени снаружи блока: не вешайте overflow-x-auto на <main> — обрезает box-shadow.
     Две декларации box-shadow: литеральная «страховка», затем var(...). Если var по какой-то причине
     невалиден, браузер игнорирует вторую строку и остаётся заметная глубина (см. скриншоты «плоский» UI). */
  background-color: var(--su-bg-card);
  border-radius: var(--su-radius);
  padding: 24px;
  border: 1px solid var(--su-border);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  box-shadow:
    0 1px 0 0 rgb(255 255 255 / 0.1),
    0 0 0 1px rgb(167 139 250 / 0.42),
    0 4px 14px rgb(0 0 0 / 0.52),
    0 20px 44px rgb(0 0 0 / 0.74),
    0 0 44px rgb(167 139 250 / 0.48),
    0 0 72px rgb(124 58 237 / 0.28);
  box-shadow: var(--su-card-shadow);
}

html[data-theme="light"] .su-card,
body.su-app.su-theme-light .su-card {
  box-shadow:
    0 1px 2px rgba(139, 92, 246, 0.05),
    0 0 0 1px rgba(139, 92, 246, 0.1),
    0 2px 10px rgba(124, 58, 237, 0.06),
    0 10px 36px rgba(139, 92, 246, 0.09);
  box-shadow: var(--su-card-shadow);
}

@media (min-width: 768px) {
  .su-card {
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.11),
      0 0 0 1px rgb(167 139 250 / 0.48),
      0 8px 22px rgb(0 0 0 / 0.58),
      0 32px 58px rgb(0 0 0 / 0.8),
      0 0 52px rgb(167 139 250 / 0.55),
      0 0 90px rgb(139 92 246 / 0.32);
    box-shadow: var(--su-card-shadow-lg);
  }

  html[data-theme="light"] .su-card,
  body.su-app.su-theme-light .su-card {
    box-shadow:
      0 1px 3px rgba(139, 92, 246, 0.06),
      0 0 0 1px rgba(139, 92, 246, 0.12),
      0 4px 18px rgba(124, 58, 237, 0.07),
      0 18px 52px rgba(139, 92, 246, 0.11);
    box-shadow: var(--su-card-shadow-lg);
  }

  .su-card--hover:hover {
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.12),
      0 0 0 2px rgb(167 139 250 / 0.58),
      0 12px 30px rgb(0 0 0 / 0.64),
      0 42px 84px rgb(0 0 0 / 0.82),
      0 0 56px rgb(167 139 250 / 0.62),
      0 0 110px rgb(167 139 250 / 0.38);
    box-shadow: var(--su-card-shadow-xl);
    transform: translateY(-2px);
  }

  html[data-theme="light"] .su-card--hover:hover,
  body.su-app.su-theme-light .su-card--hover:hover {
    box-shadow:
      0 2px 8px rgba(124, 58, 237, 0.09),
      0 0 0 1px rgba(124, 58, 237, 0.2),
      0 8px 32px rgba(124, 58, 237, 0.13),
      0 26px 60px rgba(139, 92, 246, 0.14),
      0 0 96px rgba(167, 139, 250, 0.12);
    box-shadow: var(--su-card-shadow-xl);
    transform: translateY(-2px);
  }
}

@media (max-width: 767px) {
  /* Страховка для блоков таблицы на узкой ширине */
  .su-card:not(.su-modal-panel) {
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.1),
      0 0 0 1px rgb(167 139 250 / 0.42),
      0 4px 14px rgb(0 0 0 / 0.52),
      0 20px 44px rgb(0 0 0 / 0.74),
      0 0 44px rgb(167 139 250 / 0.48),
      0 0 72px rgb(124 58 237 / 0.28);
    box-shadow: var(--su-card-shadow);
  }

  html[data-theme="light"] .su-card:not(.su-modal-panel),
  body.su-app.su-theme-light .su-card:not(.su-modal-panel) {
    box-shadow:
      0 1px 2px rgba(139, 92, 246, 0.05),
      0 0 0 1px rgba(139, 92, 246, 0.1),
      0 2px 10px rgba(124, 58, 237, 0.06),
      0 10px 36px rgba(139, 92, 246, 0.09);
    box-shadow: var(--su-card-shadow);
  }
}

.su-card-metric {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: start;
}

.su-card-metric .su-count-pill {
  min-width: 1.85rem;
  height: 1.85rem;
  font-size: 0.78rem;
  font-weight: 700;
}

.su-metric-trend-slot {
  min-width: 3rem;
  min-height: 1.25rem;
}

/* Внешняя оболочка таблицы: тень здесь, а не на .su-table-wrap — у overflow-x:auto тень обрезается. */
.su-table-elevated {
  border-radius: var(--su-radius);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  box-shadow:
    0 1px 0 0 rgb(255 255 255 / 0.1),
    0 0 0 1px rgb(167 139 250 / 0.42),
    0 4px 14px rgb(0 0 0 / 0.52),
    0 20px 44px rgb(0 0 0 / 0.74),
    0 0 44px rgb(167 139 250 / 0.48),
    0 0 72px rgb(124 58 237 / 0.28);
  box-shadow: var(--su-card-shadow);
}

html[data-theme="light"] .su-table-elevated,
body.su-app.su-theme-light .su-table-elevated {
  box-shadow:
    0 1px 2px rgba(139, 92, 246, 0.05),
    0 0 0 1px rgba(139, 92, 246, 0.1),
    0 2px 10px rgba(124, 58, 237, 0.06),
    0 10px 36px rgba(139, 92, 246, 0.09);
  box-shadow: var(--su-card-shadow);
}

@media (min-width: 768px) {
  .su-table-elevated {
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.11),
      0 0 0 1px rgb(167 139 250 / 0.48),
      0 8px 22px rgb(0 0 0 / 0.58),
      0 32px 58px rgb(0 0 0 / 0.8),
      0 0 52px rgb(167 139 250 / 0.55),
      0 0 90px rgb(139 92 246 / 0.32);
    box-shadow: var(--su-card-shadow-lg);
  }

  html[data-theme="light"] .su-table-elevated,
  body.su-app.su-theme-light .su-table-elevated {
    box-shadow:
      0 1px 3px rgba(139, 92, 246, 0.06),
      0 0 0 1px rgba(139, 92, 246, 0.12),
      0 4px 18px rgba(124, 58, 237, 0.07),
      0 18px 52px rgba(139, 92, 246, 0.11);
    box-shadow: var(--su-card-shadow-lg);
  }

  .su-table-elevated--hover:hover {
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.12),
      0 0 0 2px rgb(167 139 250 / 0.58),
      0 12px 30px rgb(0 0 0 / 0.64),
      0 42px 84px rgb(0 0 0 / 0.82),
      0 0 56px rgb(167 139 250 / 0.62),
      0 0 110px rgb(167 139 250 / 0.38);
    box-shadow: var(--su-card-shadow-xl);
    transform: translateY(-2px);
  }

  html[data-theme="light"] .su-table-elevated--hover:hover,
  body.su-app.su-theme-light .su-table-elevated--hover:hover {
    box-shadow:
      0 2px 8px rgba(124, 58, 237, 0.09),
      0 0 0 1px rgba(124, 58, 237, 0.2),
      0 8px 32px rgba(124, 58, 237, 0.13),
      0 26px 60px rgba(139, 92, 246, 0.14),
      0 0 96px rgba(167, 139, 250, 0.12);
    box-shadow: var(--su-card-shadow-xl);
    transform: translateY(-2px);
  }
}

.su-table-wrap {
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  background-color: var(--su-bg-card);
  border: 1px solid var(--su-border);
  border-radius: var(--su-radius);
  box-shadow: none;
}

/* Мультивыбор в форме (чекбоксы в раскрывающемся блоке) */
.su-spec-multiselect summary {
  list-style: none;
}
.su-spec-multiselect summary::-webkit-details-marker {
  display: none;
}
.su-spec-multiselect[open] .su-spec-multiselect-summary .opacity-80 {
  transform: rotate(180deg);
}
.su-spec-multiselect-summary .opacity-80 {
  display: inline-block;
  transition: transform 0.15s ease;
}

.su-table {
  width: 100%;
  min-width: 640px;
  font-size: 14px;
  border-collapse: collapse;
}

.su-table thead {
  background-color: var(--su-table-head-bg);
  color: var(--su-text-muted);
  text-align: left;
}

.su-table th,
.su-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--su-border);
}

.su-table tbody tr:hover {
  background-color: var(--su-table-row-hover);
}

.su-pagination {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--su-border);
  font-size: 12px;
  color: var(--su-text-muted);
}

.su-pagination--bar {
  justify-content: space-between;
}

.su-pagination-nums {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.su-page-btn {
  min-width: 2.25rem;
  min-height: 44px;
  padding: 0 10px;
  border-radius: var(--su-radius);
  border: 1px solid var(--su-border);
  background: var(--su-bg-app);
  color: var(--su-text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition:
    color 0.15s ease,
    background-color 0.15s ease;
}

.su-page-btn:hover:not(:disabled) {
  background: var(--su-btn-secondary-hover);
}

.su-page-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.su-page-btn--active {
  border-color: var(--su-accent);
  background: rgba(167, 139, 250, 0.15);
  color: var(--su-accent);
}

.su-label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--su-text-muted);
  margin-bottom: 6px;
}

.su-input,
.su-select,
.su-textarea {
  width: 100%;
  background-color: var(--su-input-bg);
  border: 1px solid var(--su-border);
  border-radius: var(--su-radius);
  color: var(--su-text);
  padding: 10px 12px;
  font-size: 14px;
  min-height: var(--su-tap-min);
}

.su-input:focus,
.su-select:focus,
.su-textarea:focus {
  outline: 2px solid var(--su-accent);
  outline-offset: 1px;
}

.su-field-error {
  font-size: 12px;
  color: var(--su-error);
  margin-top: 4px;
}

.su-btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 500;
  border-radius: var(--su-radius);
  cursor: pointer;
  border: none;
  border-color: transparent;
  min-height: var(--su-tap-min);
  padding: 0 16px;
  font-size: 14px;
  transition:
    color 0.15s ease,
    background-color 0.15s ease,
    border-color 0.15s ease,
    filter 0.15s ease,
    opacity 0.15s ease;
}

.su-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* Tooltip ::after уходит вверх — иначе overflow:hidden на .su-btn обрезает подсказку */
.su-btn.su-has-hint {
  overflow: visible;
}

.su-btn-primary {
  background-color: var(--su-accent);
  color: #fff;
}

.su-btn-primary:hover:not(:disabled) {
  filter: brightness(1.08);
}

.su-btn-secondary {
  background: transparent;
  color: var(--su-text);
  border: 1px solid var(--su-border);
}

.su-btn-secondary:hover:not(:disabled) {
  background-color: var(--su-btn-secondary-hover);
}

.su-btn-ghost {
  background: transparent;
  color: var(--su-text-muted);
  border: none;
  min-height: var(--su-tap-min);
  padding: 0 12px;
}

.su-btn-ghost:hover {
  color: var(--su-error);
}

.su-icon-btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--su-radius);
  border: 1px solid var(--su-border);
  background: var(--su-icon-btn-bg);
  color: var(--su-text);
  cursor: pointer;
}

.su-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  /* Без backdrop-filter — немного плотнее, чтобы фон читался */
  background: rgba(0, 0, 0, 0.52);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
}

@supports (-webkit-backdrop-filter: blur(8px)) or (backdrop-filter: blur(8px)) {
  .su-modal-backdrop {
    background: rgba(0, 0, 0, 0.4);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
}

@media (min-width: 640px) {
  .su-modal-backdrop {
    align-items: center;
  }
}

.su-modal-panel {
  background: var(--su-bg-card);
  border: 1px solid var(--su-border);
  border-radius: var(--su-radius);
  box-shadow: var(--su-shadow-lg);
  width: 100%;
  max-width: 32rem;
  padding: 24px;
  max-height: 90vh;
  overflow-y: auto;
}

@media (max-width: 767px) {
  .su-modal-backdrop {
    padding: 0;
    align-items: stretch;
  }

  .su-modal-panel {
    max-width: none;
    width: 100%;
    min-height: 100%;
    max-height: none;
    border-radius: 0;
    padding: 16px;
    margin: 0;
    align-self: stretch;
  }
}

.su-toast {
  pointer-events: none;
  position: fixed;
  top: 1.25rem;
  left: 50%;
  bottom: auto;
  max-width: min(90vw, 22rem);
  padding: 0.65rem 1rem;
  border-radius: var(--su-radius);
  border: 1px solid var(--su-border);
  background: rgba(15, 15, 24, 0.88);
  color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
  font-size: 0.8125rem;
  line-height: 1.35;
  z-index: 9999;
  opacity: 0;
  transform: translateX(-50%) translateY(-20px);
  transition:
    transform 0.25s ease,
    opacity 0.25s ease;
}

.su-toast--visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.su-toast--leaving {
  transform: translateX(-50%) translateY(-12px);
  opacity: 0;
}

.su-toast--error {
  border-color: rgba(248, 113, 113, 0.35);
  color: #fecaca;
}

@media (prefers-reduced-motion: reduce) {
  .su-toast {
    transition: none;
    transform: translateX(-50%) translateY(0);
    opacity: 1;
  }

  .su-toast--leaving {
    transition: none;
    opacity: 0;
  }
}

.su-search-wrap {
  position: relative;
}

.su-search-wrap .su-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--su-text-muted);
  pointer-events: none;
}

.su-search-wrap .su-input {
  padding-left: 40px;
}

.su-combo-wrap {
  position: relative;
}

.su-combo-list {
  position: absolute;
  z-index: 90;
  left: 0;
  right: 0;
  top: 100%;
  margin-top: 4px;
  max-height: 240px;
  overflow-y: auto;
  border: 1px solid var(--su-border);
  border-radius: var(--su-radius);
  background: var(--su-bg-card);
  box-shadow: var(--su-card-shadow-lg);
  -webkit-overflow-scrolling: touch;
}

.su-combo-item {
  padding: 10px 12px;
  cursor: pointer;
  font-size: 14px;
  min-height: 44px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--su-border);
}

.su-combo-item:last-child {
  border-bottom: none;
}

.su-combo-item:hover,
.su-combo-item:focus {
  background: var(--su-table-row-hover);
}

.su-status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 9999px;
}

.su-status-ok {
  background-color: var(--su-success);
}

.su-status-neutral {
  background-color: var(--su-text-muted);
}

.su-status-bad {
  background-color: var(--su-error);
}

/* Навигация сайдбара — только токены сайдбара */
.su-sidebar-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--su-radius);
  color: var(--su-sidebar-text-muted);
  text-decoration: none;
  font-size: 14px;
  min-height: var(--su-tap-min);
  transition:
    color 0.15s ease,
    background-color 0.15s ease;
}

.su-sidebar-link:hover {
  color: var(--su-sidebar-text);
  background: var(--su-sidebar-hover-bg);
}

.su-sidebar-link-active {
  color: var(--su-accent);
  background: var(--su-sidebar-active-bg);
}

.su-sidebar-link-active::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(180deg, #a78bfa 0%, #3b82f6 100%);
  animation: su-sidebar-accent-glow 2s ease-in-out infinite alternate;
}

.su-sidebar-logo {
  font-weight: 700;
  font-size: 18px;
  color: var(--su-sidebar-text);
  padding: 16px 12px 12px;
  letter-spacing: -0.02em;
}

.su-sidebar-sep {
  height: 1px;
  background: var(--su-sidebar-border);
  margin: 8px 12px;
}

.su-sidebar-future {
  opacity: 0.45;
  pointer-events: none;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--su-sidebar-text-muted);
  font-size: 13px;
}

.su-topbar {
  background: var(--su-bg-card);
  border-bottom: 1px solid var(--su-border);
}

.su-avatar {
  position: relative;
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: 9999px;
  background: rgba(167, 139, 250, 0.25);
  color: var(--su-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
  transition: transform 0.2s ease;
}

button.su-avatar {
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  margin: 0;
  padding: 0;
  cursor: pointer;
  color: inherit;
  text-align: center;
}

button.su-avatar.su-avatar-interactive:hover:not(:disabled) {
  transform: scale(1.05);
}

.su-avatar-skel {
  position: absolute;
  inset: 0;
  border-radius: 9999px;
  background: var(--su-nested-bg);
  border: none;
  animation: su-avatar-skel-pulse 1.2s ease-in-out infinite;
}

html[data-theme="light"] .su-avatar,
body.su-app.su-theme-light .su-avatar {
  background: rgba(124, 58, 237, 0.12);
  color: #7c3aed;
  border-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 10px rgba(124, 58, 237, 0.18);
}

@keyframes su-sidebar-accent-glow {
  from {
    opacity: 0.78;
  }

  to {
    opacity: 1;
  }
}

@keyframes su-avatar-skel-pulse {
  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 0.95;
  }
}

.su-burger {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}

.su-burger-line {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition:
    transform 0.25s ease,
    opacity 0.2s ease;
  transform-origin: center;
}

@media (max-width: 767px) {
  .su-burger.su-burger--open .su-burger-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .su-burger.su-burger--open .su-burger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
  }

  .su-burger.su-burger--open .su-burger-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }
}

.su-has-hint {
  position: relative;
  z-index: 0;
}

.su-has-hint::after {
  content: attr(data-su-hint);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%);
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(18, 18, 28, 0.82);
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.18s ease,
    visibility 0.18s ease;
  transition-delay: 0s, 0s;
  z-index: 20;
}

.su-has-hint:hover::after {
  opacity: 1;
  visibility: visible;
  transition-delay: 0.5s, 0.5s;
}

.su-ripple {
  position: absolute;
  width: 12px;
  height: 12px;
  margin-left: -6px;
  margin-top: -6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  pointer-events: none;
  transform: scale(0);
  opacity: 0.9;
}

.su-ripple--on {
  animation: su-ripple-fade 0.4s ease-out forwards;
}

@keyframes su-ripple-fade {
  to {
    transform: scale(18);
    opacity: 0;
  }
}

.su-brand-spinner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  color: currentColor;
  border-radius: 6px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  animation: su-brand-spin 1s linear infinite;
}

.su-brand-spinner--sm {
  width: 1.125rem;
  height: 1.125rem;
  font-size: 11px;
  border-radius: 5px;
}

@keyframes su-brand-spin {
  to {
    transform: rotate(360deg);
  }
}

.su-metric-no-data {
  color: var(--su-text-muted);
  font-size: 14px;
}

.su-ai-placeholder {
  background-color: var(--su-bg-card);
  border: 1px dashed var(--su-border);
  border-radius: var(--su-radius);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--su-text-muted);
  font-size: 14px;
  box-shadow:
    0 1px 0 0 rgb(255 255 255 / 0.1),
    0 0 0 1px rgb(167 139 250 / 0.42),
    0 4px 14px rgb(0 0 0 / 0.52),
    0 20px 44px rgb(0 0 0 / 0.74),
    0 0 44px rgb(167 139 250 / 0.48),
    0 0 72px rgb(124 58 237 / 0.28);
  box-shadow: var(--su-card-shadow);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

@media (min-width: 768px) {
  .su-ai-placeholder {
    padding: 24px;
    box-shadow:
      0 1px 0 0 rgb(255 255 255 / 0.11),
      0 0 0 1px rgb(167 139 250 / 0.48),
      0 8px 22px rgb(0 0 0 / 0.58),
      0 32px 58px rgb(0 0 0 / 0.8),
      0 0 52px rgb(167 139 250 / 0.55),
      0 0 90px rgb(139 92 246 / 0.32);
    box-shadow: var(--su-card-shadow-lg);
  }

  html[data-theme="light"] .su-ai-placeholder,
  body.su-app.su-theme-light .su-ai-placeholder {
    box-shadow:
      0 1px 3px rgba(139, 92, 246, 0.06),
      0 0 0 1px rgba(139, 92, 246, 0.12),
      0 4px 18px rgba(124, 58, 237, 0.07),
      0 18px 52px rgba(139, 92, 246, 0.11);
    box-shadow: var(--su-card-shadow-lg);
  }
}

.su-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  display: inline-block;
}

.su-badge-confirmed {
  background: rgba(52, 211, 153, 0.22);
  color: #6ee7b7;
}

html[data-theme="light"] .su-badge-confirmed {
  color: #047857;
}

.su-badge-cancelled {
  background: rgba(248, 113, 113, 0.22);
  color: #fca5a5;
}

html[data-theme="light"] .su-badge-cancelled {
  color: #b91c1c;
}

.su-badge-completed {
  background: rgba(96, 165, 250, 0.22);
  color: #93c5fd;
}

html[data-theme="light"] .su-badge-completed {
  color: #1d4ed8;
}

.su-badge-scheduled {
  background: rgba(148, 163, 184, 0.22);
  color: #cbd5e1;
}

html[data-theme="light"] .su-badge-scheduled {
  color: #475569;
}

.su-badge-default {
  background: rgba(148, 163, 184, 0.22);
  color: #cbd5e1;
}

html[data-theme="light"] .su-badge-default {
  color: #475569;
}

.su-section-title {
  font-size: 1rem;
  font-weight: 600;
  padding-bottom: 12px;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--su-border-color);
  color: var(--su-text);
}

.su-header-with-count {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.su-header-with-count .su-count-pill {
  min-width: 1.65rem;
  height: 1.65rem;
  font-size: 0.72rem;
  font-weight: 700;
}

.su-count-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  height: 1.5rem;
  padding: 0 6px;
  border-radius: 9999px;
  font-size: 0.7rem;
  font-weight: 600;
  background: rgba(148, 163, 184, 0.25);
  color: var(--su-text-muted);
}

html:not([data-theme="light"]) .su-count-pill {
  background: rgba(167, 139, 250, 0.2);
  color: #ede9fe;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 0 0 1px rgba(167, 139, 250, 0.35);
}

html[data-theme="light"] .su-count-pill {
  background: rgba(124, 58, 237, 0.08);
  color: #7c3aed;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 0 0 1px rgba(139, 92, 246, 0.22);
}

.su-table-wrap > .su-empty-block {
  min-height: 11rem;
  margin: 0.25rem;
  border-radius: calc(var(--su-radius) - 2px);
  background: var(--su-nested-bg);
}

.su-empty-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.25rem;
  gap: 0.5rem;
  color: var(--su-text-muted);
}

.su-empty-block svg {
  width: 2.5rem;
  height: 2.5rem;
  opacity: 0.55;
}

.su-empty-title {
  font-weight: 600;
  color: var(--su-text);
  font-size: 0.95rem;
}

.su-empty-hint {
  font-size: 0.8125rem;
  max-width: 20rem;
  line-height: 1.45;
}

.su-empty-block--compact {
  padding: 1.25rem 0.5rem;
  gap: 0.25rem;
}

/* Главная страница: топ загрузки мастеров */
.su-master-util-stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 0.5rem;
  width: 100%;
}

.su-master-util-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(88px, 34%) auto;
  gap: 0.35rem 0.5rem;
  align-items: center;
  font-size: 0.75rem;
  line-height: 1.25;
}

.su-master-util-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--su-text);
}

.su-master-util-track {
  height: 6px;
  border-radius: 9999px;
  background: var(--su-nested-bg);
  overflow: hidden;
}

.su-master-util-pct {
  font-variant-numeric: tabular-nums;
  color: var(--su-text-muted);
  justify-self: end;
}

.su-master-util-bar {
  height: 100%;
  min-width: 0;
  border-radius: 9999px;
  transition: width 0.65s cubic-bezier(0.33, 1, 0.68, 1);
}

.su-master-util-bar--high {
  background-color: #34d399;
}

.su-master-util-bar--mid {
  background-color: #fbbf24;
}

.su-master-util-bar--low {
  background-color: #f87171;
}

@media (max-width: 639px) {
  .su-master-util-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
  }

  .su-master-util-name {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
  }

  .su-master-util-pct {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
  }

  .su-master-util-track {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

/* Успешное сохранение: галочка на кнопке */
.su-save-flash-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  animation: su-save-flash-pop 0.9s cubic-bezier(0.33, 1, 0.68, 1) forwards;
}

@keyframes su-save-flash-pop {
  0% {
    opacity: 0;
    transform: scale(0.82);
  }
  20% {
    opacity: 1;
    transform: scale(1);
  }
  70% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0.96);
  }
}

.su-save-flash-icon {
  width: 1.25rem;
  height: 1.25rem;
  color: #34d399;
  filter: drop-shadow(0 0 6px rgba(52, 211, 153, 0.35));
}

/* Пустое состояние: мягкий пульс иконки и CTA */
.su-empty-block.su-empty-block--inviting svg {
  color: var(--su-accent);
  opacity: 0.88;
  animation: su-empty-invite-pulse 3.2s ease-in-out infinite;
}

.su-empty-block.su-empty-block--inviting .su-empty-cta {
  animation: su-empty-invite-pulse 3.2s ease-in-out 0.25s infinite;
}

@keyframes su-empty-invite-pulse {
  0%,
  100% {
    opacity: 0.72;
    filter: brightness(1);
  }

  50% {
    opacity: 1;
    filter: brightness(1.06);
  }
}

@media (prefers-reduced-motion: reduce) {
  html,
  body.su-app,
  .su-app {
    transition: none;
  }

  .su-content-fade {
    animation: none;
    opacity: 1;
  }

  .su-skeleton {
    animation: none;
    opacity: 0.55;
    background: var(--su-nested-bg);
    background-size: auto;
  }

  html[data-theme="light"] .su-skeleton,
  body.su-app.su-theme-light .su-skeleton {
    background: rgba(139, 92, 246, 0.08);
  }

  .su-master-util-bar {
    transition: none;
  }

  .su-save-flash-inner {
    animation: none;
    opacity: 1;
  }

  .su-empty-block.su-empty-block--inviting svg,
  .su-empty-block.su-empty-block--inviting .su-empty-cta {
    animation: none;
    opacity: 0.88;
    filter: none;
  }

  .su-card--hover:hover {
    transform: none;
    box-shadow: var(--su-card-shadow-xl);
  }

  .su-table-elevated--hover:hover {
    transform: none;
    box-shadow: var(--su-card-shadow-xl);
  }

  .su-sidebar-link-active::before {
    animation: none;
    opacity: 1;
  }

  .su-burger-line {
    transition: none;
  }

  .su-brand-spinner {
    animation: none;
  }

  .su-avatar-skel {
    animation: none;
    opacity: 0.72;
  }

  button.su-avatar.su-avatar-interactive:hover:not(:disabled) {
    transform: none;
  }

  .su-has-hint::after {
    display: none;
  }

  .su-ripple--on {
    animation: none;
    opacity: 0;
  }
}

/* Ограничение высоты и прокрутка сайдбара на мобилках (кнопка «Выйти» под системной панелью Safari) */
@media (max-width: 767px) {
  .su-sidebar-mount {
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: 100vh;
    max-height: 100dvh;
    overflow: hidden;
    box-sizing: border-box;
  }

  .su-sidebar-mount .su-sidebar-inner {
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
    max-height: none;
    -webkit-overflow-scrolling: touch;
  }
}

.su-sidebar-inner {
  background: var(--su-sidebar-bg);
  border-right: 1px solid var(--su-sidebar-border);
  height: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  width: 220px;
  overflow-y: auto;
  box-sizing: border-box;
}

.su-sidebar-footer {
  margin-top: auto;
  padding-bottom: max(16px, calc(12px + env(safe-area-inset-bottom, 0px)));
}

@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes gradientText {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 200% 50%;
  }
}

.su-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: var(--su-bg-app);
}

.su-login-wrap.login-page {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.login-watermark {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.login-watermark img {
  width: min(52vw, 400px);
  max-height: 72vh;
  height: auto;
  object-fit: contain;
  opacity: 0.18;
}

html[data-theme="dark"] .login-watermark img {
  filter: invert(1);
  opacity: 0.22;
}

html[data-theme="light"] .login-watermark img {
  opacity: 0.16;
}

.su-login-wrap.login-page > :not(.login-watermark) {
  position: relative;
  z-index: 1;
}

/* Водяной знак в приложении (страницы с sidebar) */
body.su-app:not(.login-page) {
  isolation: isolate;
}

body.su-app:not(.login-page)::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: url("/frontend/assets/logo.svg") center / min(42vw, 360px) no-repeat;
  opacity: 0.08;
}

html[data-theme="dark"] body.su-app:not(.login-page)::after {
  filter: invert(1);
  opacity: 0.1;
}

html[data-theme="light"] body.su-app:not(.login-page)::after {
  opacity: 0.1;
}

body.su-app:not(.login-page) > * {
  position: relative;
  z-index: 1;
}

html:not([data-theme="light"]) .su-login-wrap.login-page {
  background: linear-gradient(-45deg, #0f172a, #1e1b4b, #064e3b, #10b981, #2e1065, #0f172a);
  background-size: 400% 400%;
  animation: gradientBG 18s ease infinite;
}

html[data-theme="light"] .su-login-wrap.login-page {
  background: linear-gradient(-45deg, #e2e8f0, #cbd5e1, #e2e8f0, #cbd5e1, #e2e8f0);
  background-size: 300% 300%;
  animation: gradientBG 15s ease infinite;
}

html:not([data-theme="light"]) .nexis-gradient {
  background: linear-gradient(90deg, #a78bfa, #10b981, #3b82f6, #a78bfa);
  background-size: 300% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientText 4s linear infinite;
}

html[data-theme="light"] .nexis-gradient {
  background: linear-gradient(90deg, #6b21a5, #0891b2, #6b21a5);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientText 4s linear infinite;
}

html:not([data-theme="light"]) .su-login-wrap.login-page .login-form.su-card {
  background: rgba(15, 23, 42, 0.6);
  background-color: rgba(15, 23, 42, 0.6);
}

html:not([data-theme="light"]) .login-form {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 24px;
  border: 1px solid rgba(16, 185, 129, 0.3);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.2),
    0 0 0 1px rgba(16, 185, 129, 0.1);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

html:not([data-theme="light"]) .login-form:hover {
  border-color: rgba(16, 185, 129, 0.6);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(16, 185, 129, 0.2);
}

html[data-theme="light"] .su-login-wrap.login-page .login-form.su-card,
html[data-theme="light"] .login-form {
  background: rgba(255, 255, 255, 0.8);
  background-color: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(100, 116, 139, 0.2);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
}

html[data-theme="light"] .login-form:hover {
  border-color: rgba(100, 116, 139, 0.35);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
}

html:not([data-theme="light"]) .su-login-wrap.login-page .su-text-small {
  color: rgba(226, 232, 240, 0.85);
}

html:not([data-theme="light"]) .su-login-wrap.login-page .su-label {
  color: rgba(226, 232, 240, 0.9);
}

html:not([data-theme="light"]) .su-login-wrap.login-page .su-input {
  background: rgba(15, 23, 42, 0.5);
  border-color: rgba(16, 185, 129, 0.25);
}

html:not([data-theme="light"]) .su-login-wrap.login-page .su-input:focus {
  border-color: rgba(16, 185, 129, 0.55);
}

html[data-theme="light"] .su-login-wrap.login-page .su-text-small {
  color: rgba(51, 65, 85, 0.85);
}

html[data-theme="light"] .su-login-wrap.login-page .su-label {
  color: rgba(30, 41, 59, 0.9);
}

html[data-theme="light"] .su-login-wrap.login-page .su-input {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(100, 116, 139, 0.3);
  color: var(--su-text);
}

html[data-theme="light"] .su-login-wrap.login-page .su-input:focus {
  border-color: rgba(8, 145, 178, 0.45);
}

@media (prefers-reduced-motion: reduce) {
  html:not([data-theme="light"]) .su-login-wrap.login-page,
  html[data-theme="light"] .su-login-wrap.login-page {
    animation: none;
    background-position: 50% 50%;
  }

  html:not([data-theme="light"]) .nexis-gradient,
  html[data-theme="light"] .nexis-gradient {
    animation: none;
    background-position: 0% 50%;
  }
}

.su-login-card {
  position: relative;
  width: 100%;
  max-width: 28rem;
}

.su-login-theme-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: var(--su-tap-min);
  height: var(--su-tap-min);
  padding: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Row delete (trash): smooth hover without layout thrash */
.su-row-delete {
  transition: color 0.18s ease, border-color 0.18s ease, opacity 0.18s ease, background-color 0.18s ease;
}

/* Appointments calendar: drag / drop */
.su-apt-day-root {
  display: flex;
  align-items: stretch;
}
.su-apt-time-gutter {
  flex: 0 0 44px;
  width: 44px;
}
.su-apt-master-col {
  position: relative;
  flex: 1 1 0;
  min-width: 150px;
  max-width: 240px;
}
.su-apt-grid-layer,
.su-apt-week-col {
  position: relative;
}
.su-apt-slot-line,
.su-apt-slot,
.su-apt-card {
  position: absolute;
}
.su-apt-slot-line,
.su-apt-slot {
  left: 0;
  right: 0;
}
.su-apt-slot--drop {
  background: rgba(167, 139, 250, 0.14);
}
.su-apt-list-card {
  border: 1px solid var(--su-border);
  border-radius: 0.75rem;
  background: var(--su-nested-bg);
  padding: 0.625rem;
  font-size: 0.75rem;
  line-height: 1.25;
  position: relative;
}
.su-apt-list-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}
.su-apt-list-client {
  min-width: 0;
  color: var(--su-text);
  font-weight: 650;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.su-apt-list-status {
  flex: 0 0 auto;
  font-size: 0.625rem;
  line-height: 1;
  padding: 0.25rem 0.4rem;
}
.su-apt-list-time {
  margin-top: 0.25rem;
  color: var(--su-text-muted);
  font-size: 0.6875rem;
}
.su-apt-list-service {
  margin-top: 0.125rem;
  color: var(--su-text-muted);
  font-size: 0.6875rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.su-apt-list-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.375rem;
  margin-top: 0.625rem;
}
.su-apt-action {
  min-height: 1.75rem;
  border-radius: 0.5rem;
  padding: 0 0.55rem;
  border: 1px solid var(--su-border);
  background: transparent;
  font-size: 0.6875rem;
  font-weight: 600;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.su-apt-action-primary {
  color: var(--su-accent);
}
.su-apt-action-primary:hover {
  border-color: var(--su-accent);
  background: rgba(167, 139, 250, 0.1);
}
.su-apt-action-danger {
  color: var(--su-text-muted);
}
.su-apt-action-danger:hover {
  border-color: var(--su-error);
  color: var(--su-error);
}
html[data-theme="dark"] .su-calendar-icon,
html:not([data-theme="light"]) .su-calendar-icon {
  color: #c084fc;
}
html[data-theme="dark"] .su-date-input,
html:not([data-theme="light"]) .su-date-input {
  color-scheme: dark;
}
html[data-theme="dark"] .su-date-input::-webkit-calendar-picker-indicator,
html:not([data-theme="light"]) .su-date-input::-webkit-calendar-picker-indicator {
  cursor: pointer;
  opacity: 1;
  filter: invert(72%) sepia(47%) saturate(1140%) hue-rotate(211deg) brightness(102%) contrast(98%);
}
html[data-theme="dark"] .su-apt-board,
html:not([data-theme="light"]) .su-apt-board {
  padding: 0.25rem;
  border-radius: 1rem;
  background:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    rgba(167, 139, 250, 0.06);
  background-size: 100% 44px;
}
html[data-theme="dark"] .su-apt-master-card,
html:not([data-theme="light"]) .su-apt-master-card {
  border-color: rgba(255, 255, 255, 0.22) !important;
  background: rgba(30, 41, 59, 0.82);
}
html[data-theme="dark"] .su-apt-master-card > p:first-child,
html:not([data-theme="light"]) .su-apt-master-card > p:first-child {
  border-color: rgba(255, 255, 255, 0.2) !important;
  color: rgba(241, 245, 249, 0.9);
}
html[data-theme="dark"] .su-apt-list-card,
html:not([data-theme="light"]) .su-apt-list-card {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(15, 23, 42, 0.52);
}
html[data-theme="dark"] .su-apt-list-card:hover,
html:not([data-theme="light"]) .su-apt-list-card:hover {
  border-color: rgba(167, 139, 250, 0.36);
  background: rgba(167, 139, 250, 0.12);
}
html[data-theme="dark"] .su-apt-list-time,
html[data-theme="dark"] .su-apt-list-service,
html:not([data-theme="light"]) .su-apt-list-time,
html:not([data-theme="light"]) .su-apt-list-service {
  color: rgba(226, 232, 240, 0.78);
}
.su-apt-card--drag {
  opacity: 0.5;
  cursor: grabbing !important;
}
.su-apt-card--conflict {
  animation: su-apt-shake 0.35s ease;
  border-color: var(--su-error) !important;
}
@keyframes su-apt-shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-3px);
  }
  75% {
    transform: translateX(3px);
  }
}
.su-apt-week-col {
  min-height: 12rem;
}
