/* ════════════════════════════════════════════════════════════════════
   SESSION TESTS — WHITE FUTURE
   Светлая футуристичная тема: белые «стеклянные» поверхности,
   холодная сетка, мягкие неоновые акценты и ТЁМНЫЙ (почти чёрный)
   текст на всех обычных элементах интерфейса.
   Подключается ПОСЛЕ всех остальных тем.
   ════════════════════════════════════════════════════════════════════ */

[data-theme="white-future"] {
  color-scheme: light;

  --ig-body-bg:
    radial-gradient(circle at 12% 4%, rgba(99, 102, 241, .15), transparent 36%),
    radial-gradient(circle at 88% 18%, rgba(6, 182, 212, .13), transparent 34%),
    radial-gradient(circle at 50% 100%, rgba(139, 92, 246, .09), transparent 45%),
    linear-gradient(165deg, #fcfdff 0%, #f1f5fc 46%, #e8eef9 100%);

  --ig-surface: #ffffff;
  --ig-surface-raised: rgba(255, 255, 255, .88);
  --ig-surface-input: #ffffff;
  --ig-surface-hover: #eef3fb;
  --ig-surface-btn: #ffffff;

  --ig-border: #d8e1ef;
  --ig-border-light: #e8eef7;
  --ig-border-input: #cbd7e8;
  --ig-border-focus: #4f46e5;
  --ig-divider: #e6ecf6;
  --ig-divider-strong: #d7e1ef;

  /* Текст: адаптируется под светлый фон и становится чёрным/тёмно-серым. */
  --ig-text: #0a1020;
  --ig-text-secondary: #293449;
  --ig-text-muted: #475569;
  --ig-text-dim: #5d6b80;
  --ig-text-faint: #8190a5;
  --ig-text-btn: #0f172a;
  --ig-text-btn-muted: #52627a;

  --ig-accent: #4f46e5;
  --ig-accent2: #0891b2;
  --accent: #4f46e5;
  --text-dim: #475569;
  --ig-accent-gradient: linear-gradient(135deg, #4338ca, #0891b2);
  --ig-accent-bg: rgba(79, 70, 229, .08);
  --ig-accent-contrast: #ffffff;

  --ig-focus-ring: 0 0 0 3px rgba(79, 70, 229, .22);
  --ig-shadow: 0 18px 60px rgba(30, 64, 175, .10), 0 2px 8px rgba(15, 23, 42, .05);
  --ig-shadow-sm: 0 2px 14px rgba(15, 23, 42, .07);
  --ig-shadow-lg: 0 24px 80px rgba(30, 64, 175, .16);

  --ig-avatar-border: #d8e1ef;
  --ig-avatar-placeholder: linear-gradient(135deg, #e0e7ff, #cffafe);
  --ig-cover-bg: linear-gradient(135deg, #eef2ff, #ecfeff);
  --ig-badge-bg: #f1f5fb;
  --ig-badge-border: #d8e1ef;

  --ig-success: #047857;
  --ig-success-bg: rgba(4, 120, 87, .10);
  --ig-error: #b91c1c;
  --ig-error-bg: rgba(185, 28, 28, .08);
  --ig-warning: #b45309;
  --ig-warning-bg: rgba(180, 83, 9, .09);
}

/* Сетка и мягкое свечение — «футуристичный» фон без ущерба читаемости. */
body[data-theme="white-future"]::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(79, 70, 229, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79, 70, 229, .055) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, .45) 55%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, .45) 55%, transparent 100%);
}

body[data-theme="white-future"]::after {
  content: '';
  position: fixed;
  left: 50%;
  top: -260px;
  width: 780px;
  height: 520px;
  transform: translateX(-50%);
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(99, 102, 241, .14), transparent 68%);
  filter: blur(12px);
  animation: wfFloat 14s ease-in-out infinite alternate;
}

@keyframes wfFloat {
  from { transform: translateX(-50%) translateY(0) scale(1); }
  to   { transform: translateX(-48%) translateY(26px) scale(1.06); }
}

/* Стеклянные панели. */
body[data-theme="white-future"] .st-header,
body[data-theme="white-future"] .st-tabbar {
  background: rgba(255, 255, 255, .82) !important;
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  backdrop-filter: blur(18px) saturate(1.4);
  border-color: var(--ig-border) !important;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .9) inset, 0 6px 24px rgba(30, 64, 175, .06);
}

body[data-theme="white-future"] .st-header {
  border-bottom: 2px solid transparent !important;
  border-image: linear-gradient(90deg, transparent, rgba(79, 70, 229, .55), rgba(6, 182, 212, .45), transparent) 1;
}

body[data-theme="white-future"] .card,
body[data-theme="white-future"] .st-answers-card,
body[data-theme="white-future"] .st-settings-drawer,
body[data-theme="white-future"] .modal-content,
body[data-theme="white-future"] .st-section,
body[data-theme="white-future"] .st-hero-card {
  background: var(--ig-surface-raised) !important;
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  backdrop-filter: blur(16px) saturate(1.3);
  border: 1px solid var(--ig-border) !important;
  box-shadow: var(--ig-shadow) !important;
  color: var(--ig-text);
}

body[data-theme="white-future"] .card::before,
body[data-theme="white-future"] .card::after {
  display: none;
}

/* Кнопки: светлый «хай-тек» с чёрным текстом. Кнопки с акцентным
   фоном оставляем с белым текстом — на тёмном индиго он читается лучше. */
body[data-theme="white-future"] button,
body[data-theme="white-future"] .st-btn,
body[data-theme="white-future"] .st-answers-tab {
  color: var(--ig-text-btn);
  border-color: var(--ig-border-input);
  background: var(--ig-surface-btn);
}

body[data-theme="white-future"] button:hover,
body[data-theme="white-future"] .st-btn:hover {
  background: var(--ig-surface-hover);
  border-color: var(--ig-accent);
}

body[data-theme="white-future"] .answers button.is-selected {
  border-color: var(--ig-accent);
  background: var(--ig-accent-bg);
  color: #0a1020 !important;
}

/* Поля ввода. */
body[data-theme="white-future"] input,
body[data-theme="white-future"] textarea,
body[data-theme="white-future"] select {
  color: #0a1020;
  background: #ffffff;
  border-color: var(--ig-border-input);
}

body[data-theme="white-future"] input::placeholder,
body[data-theme="white-future"] textarea::placeholder { color: #7b8aa1; }

/* Заголовки и акцентный градиент — тёмные оттенки, чтобы не «выгорали». */
body[data-theme="white-future"] .st-hero-title {
  color: #0a1020;
  text-shadow: none;
}

body[data-theme="white-future"] .st-hero-title .st-glow,
body[data-theme="white-future"] .st-section-title,
body[data-theme="white-future"] .st-hero-kicker {
  background: linear-gradient(120deg, #3730a3, #0e7490);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

body[data-theme="white-future"] .st-answer-a { color: #047857; }
body[data-theme="white-future"] .st-answer-num { color: #64748b; }

/* Плеер и мини-плеер: там много жёстко заданного белого текста —
   принудительно переводим его в тёмный и убираем тени. */
body[data-theme="white-future"] .st-player,
body[data-theme="white-future"] .stnp-panel,
body[data-theme="white-future"] .stnp-panel *,
body[data-theme="white-future"] .st-player * {
  color: #101828 !important;
  text-shadow: none !important;
}

body[data-theme="white-future"] .st-player,
body[data-theme="white-future"] .stnp-panel {
  background: rgba(255, 255, 255, .94) !important;
  border-color: var(--ig-border) !important;
  box-shadow: var(--ig-shadow-lg) !important;
}

body[data-theme="white-future"] .st-player-sdk-tip {
  background: rgba(255, 255, 255, .96) !important;
  color: #101828 !important;
  box-shadow: var(--ig-shadow-sm) !important;
}

/* Модалки и фильтры: там цвет текста и фон раньше были «жёстко» белыми. */
body[data-theme="white-future"] .modal-content button,
body[data-theme="white-future"] .modal button {
  color: #0f172a !important;
  background: #ffffff !important;
  border: 1px solid var(--ig-border-input) !important;
}

body[data-theme="white-future"] .modal-content button:hover,
body[data-theme="white-future"] .modal button:hover {
  background: var(--ig-surface-hover) !important;
}

body[data-theme="white-future"] .tc-chip,
body[data-theme="white-future"] button.tc-chip {
  color: #0f172a !important;
  background: #ffffff !important;
  border-color: var(--ig-border-input) !important;
}

/* Прочее: ползунки, разделители, скроллбары, выделение. */
body[data-theme="white-future"] ::selection {
  background: rgba(79, 70, 229, .20);
  color: #0a1020;
}

body[data-theme="white-future"] hr,
body[data-theme="white-future"] .ig-divider { border-color: var(--ig-divider) !important; }

body[data-theme="white-future"] ::-webkit-scrollbar-thumb {
  background: #c9d4e6;
  border-radius: 999px;
}

body[data-theme="white-future"] #matrix-bg,
body[data-theme="white-future"] #abstract-canvas { display: none !important; }

body[data-theme="white-future"] .error-cta a {
  color: #ffffff !important;
}

@media (prefers-reduced-motion: reduce) {
  body[data-theme="white-future"]::after { animation: none; }
}

body[data-theme="white-future"].performance-mode::after {
  animation: none;
}
