/* СОБРАНО АВТОМАТИЧЕСКИ из miniapp/src/styles/**. Пересборка: python tools/build_miniapp.py */

/* --- tokens.css --- */
/*
 * Тёмный минимализм по референсам VK Music (disigner/): почти чёрный фон,
 * нейтральные серые карточки, цвет — только в акцентах (сине-розовый градиент
 * hero, синяя карточка подписки, синий акцент интерактива).
 * Тема одна — тёмная (решение владельца). Имена токенов сохранены со времён
 * «аметиста», чтобы не трогать компонентные стили.
 */

:root {
  color-scheme: dark;

  /* --- Палитра --- */
  --raw-black: #0f0f10;
  --raw-card: #202022;
  --raw-card-elevated: #2a2a2d;
  --raw-blue: #3b7bfe;
  --raw-blue-deep: #2e55f2;
  --raw-blue-light: #4a7bfb;
  --raw-magenta: #ee3fc8;
  --raw-violet: #7b46e8;
  --raw-white: #ffffff;
  --raw-white-soft: #e8e8ea;
  /* Контраст на #0f0f10 (WCAG): text ≈ 6.2:1, muted ≈ 4.6:1 — мелкий текст читается */
  --raw-grey-text: #a3a3ab;
  --raw-grey-muted: #8b8b93;

  /* --- Фон приложения --- */
  --bg-base: var(--raw-black);
  --bg-glow: none;

  /* --- Поверхности / карточки --- */
  --surface-card: var(--raw-card);
  --surface-card-translucent: rgba(32, 32, 34, 0.88);
  --surface-elevated: var(--raw-card-elevated);

  /* --- Стекло (роль сохранена, вид — нейтральный) --- */
  --glass-bg: rgba(28, 28, 30, 0.86);
  --glass-bg-card: rgba(32, 32, 34, 0.82);
  --glass-blur: 20px;
  --glass-border: rgba(255, 255, 255, 0.05);
  --glass-border-amethyst: rgba(255, 255, 255, 0.09);
  --glass-border-card: rgba(255, 255, 255, 0.06);
  --glass-inset: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  --glass-shadow: 0 14px 40px rgba(0, 0, 0, 0.4);

  /* --- Акцент (интерактив) --- */
  --accent: var(--raw-blue);
  --accent-hover: #5a8ffe;
  --accent-pressed: #2f63d6;
  --accent-soft: rgba(59, 123, 254, 0.14);
  --accent-glow: 0 0 24px rgba(59, 123, 254, 0.22);

  /* --- Градиенты --- */
  --gradient-brand: linear-gradient(135deg, #2e6ff2 0%, #7b46e8 50%, #ee3fc8 100%);
  --gradient-dark: linear-gradient(185deg, #2e6ff2 0%, #b93be2 55%, #f02fc2 100%);
  --gradient-premium-card: linear-gradient(100deg, #2e55f2 0%, #4a7bfb 100%);

  /* --- Типографика --- */
  --text-primary: var(--raw-white);
  --text-soft: var(--raw-white-soft);
  --text-secondary: var(--raw-grey-text);
  --text-muted: var(--raw-grey-muted);
  --text-accent: #7ea4ff;

  /* --- Нижняя навигация --- */
  --nav-bg: rgba(15, 15, 16, 0.94);
  --nav-border: rgba(255, 255, 255, 0.05);
  --nav-icon-active: #ffffff;
  --nav-text-active: #ffffff;
  --nav-icon-inactive: #85858d;
  --nav-text-inactive: #85858d;
  --nav-active-bg: rgba(255, 255, 255, 0.08);

  /* --- Плеер --- */
  --player-bg: linear-gradient(160deg, #1c1c1f 0%, #232327 100%);
  --progress-track: #333338;
  --progress-active: linear-gradient(90deg, #3b7bfe, #ee3fc8);
  --progress-thumb: #ffffff;
  --play-border: rgba(255, 255, 255, 0.16);
  --play-glow: 0 8px 24px rgba(0, 0, 0, 0.35);

  /* --- Иконки --- */
  --icon-primary: var(--raw-white-soft);
  --icon-inactive: #6e6e75;
  --icon-active: var(--raw-blue);
  --icon-premium: #9db9ff;

  /* --- Прочее --- */
  --shadow-elevated: 0 14px 40px rgba(0, 0, 0, 0.4);
  --divider: rgba(255, 255, 255, 0.06);
  --overlay-scrim: rgba(0, 0, 0, 0.66);

  /* --- Унифицированные радиусы --- */
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 20px;
  --radius-xl: 26px;
  --radius-pill: 999px;

  /* --- Унифицированные отступы --- */
  --space-1: 6px;
  --space-2: 10px;
  --space-3: 14px;
  --space-4: 18px;
  --space-5: 24px;
  --space-6: 32px;

  /* --- Единая высота интерактивных элементов --- */
  --control-h: 46px;
  --tap-min: 44px;

  /* --- Типографическая шкала (ui-ux-pro-max: единый ритм вместо разнобоя) --- */
  --font-display: 27px; /* hero-заголовки */
  --font-title: 21px; /* заголовки экранов/плеера */
  --font-heading: 16.5px; /* секции, page-head */
  --font-body: 14px; /* названия треков, кнопки */
  --font-caption: 12.5px; /* подписи, исполнители */
  --font-micro: 11px; /* метки, счётчики */

  /* --- Движение: конкретные кривые вместо generic ease --- */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-normal: 280ms;
}

/* --- Акцентный цвет интерфейса (настройки → Интерфейс, скрин VK photo_19).
   Переопределяем только интерактивный акцент; градиенты hero/premium не трогаем. --- */

:root[data-accent="gold"] {
  --accent: #f5a623;
  --accent-hover: #ffb84d;
  --accent-pressed: #d48c14;
  --accent-soft: rgba(245, 166, 35, 0.14);
  --accent-glow: 0 0 24px rgba(245, 166, 35, 0.22);
  --text-accent: #ffca6b;
  --icon-active: #f5a623;
  --progress-active: linear-gradient(90deg, #f5a623, #ee3fc8);
}

:root[data-accent="pink"] {
  --accent: #ef3f7f;
  --accent-hover: #ff6299;
  --accent-pressed: #cc2f68;
  --accent-soft: rgba(239, 63, 127, 0.14);
  --accent-glow: 0 0 24px rgba(239, 63, 127, 0.22);
  --text-accent: #ff8ab4;
  --icon-active: #ef3f7f;
  --progress-active: linear-gradient(90deg, #ef3f7f, #7b46e8);
}

:root[data-accent="green"] {
  --accent: #32d74b;
  --accent-hover: #55e56a;
  --accent-pressed: #26b13c;
  --accent-soft: rgba(50, 215, 75, 0.14);
  --accent-glow: 0 0 24px rgba(50, 215, 75, 0.22);
  --text-accent: #74e987;
  --icon-active: #32d74b;
  --progress-active: linear-gradient(90deg, #32d74b, #3b7bfe);
}

:root[data-accent="azure"] {
  --accent: #32ade6;
  --accent-hover: #56c1f2;
  --accent-pressed: #2790c2;
  --accent-soft: rgba(50, 173, 230, 0.14);
  --accent-glow: 0 0 24px rgba(50, 173, 230, 0.22);
  --text-accent: #7fd0f5;
  --icon-active: #32ade6;
  --progress-active: linear-gradient(90deg, #32ade6, #ee3fc8);
}

/* --- base.css --- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  background: var(--bg-glow), var(--bg-base);
  background-attachment: fixed;
  color: var(--text-primary);
  /* Нет доступа к сети у окружения сборки — веб-шрифт исключён осознанно,
     чтобы не ловить бесконечный pending-запрос. Премиальность держится на
     весах/трекинге/ритме, а не на экзотическом шрифте. */
  font-family: -apple-system, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Roboto, sans-serif;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color 0.35s ease, color 0.35s ease;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

button {
  font-family: inherit;
  border: none;
  background: none;
  color: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

input {
  font-family: inherit;
  color: inherit;
}

::selection {
  background: var(--accent-soft);
}

a {
  color: inherit;
  text-decoration: none;
}

/* --- Каркас приложения (мобильный вьюпорт Mini App) --- */

#app {
  position: relative;
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-top: env(safe-area-inset-top);
  display: flex;
  flex-direction: column;
}

/* Планшеты — колонка чуть шире, но не растянута на весь экран */
@media (min-width: 700px) {
  #app {
    max-width: 560px;
  }
}

/* Отступ снизу = высота дока (мини-плеер + навигация), чтобы контент никогда
   не уходил под нижнюю панель (ТЗ §2). Высоты задаются классами на #app. */
.screen {
  flex: 1;
  padding: 20px 20px calc(24px + env(safe-area-inset-bottom));
  animation: screen-in 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

#app.has-nav .screen {
  padding-bottom: calc(104px + env(safe-area-inset-bottom));
}

#app.is-playing .screen {
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

#app.has-nav.is-playing .screen {
  padding-bottom: calc(178px + env(safe-area-inset-bottom));
}

/* Горизонтальные ленты (hero-карусель, быстрый доступ, блоки библиотеки):
   скролл строго внутри контейнера, страница по горизонтали не едет. */
.h-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  padding-bottom: 2px;
}

.h-scroll::-webkit-scrollbar {
  display: none;
}

.h-scroll > * {
  scroll-snap-align: start;
  flex: 0 0 auto;
}

@keyframes screen-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-title {
  font-size: var(--font-heading);
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 28px 0 14px;
}

.link-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-accent);
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

/* ---------- Полировка: доступность, focus, motion (ui-ux-pro-max) ---------- */

/* Видимый фокус только для клавиатуры — тач/мышь не рисуют рамку */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

button:focus:not(:focus-visible) {
  outline: none;
}

/* Единый отклик на нажатие интерактивных строк-кнопок (cause→effect) */
.settings-row,
.pl-row,
.artist-row,
.vk-tile,
.plan-card,
.seg,
.sheet-item {
  transition: background-color var(--duration-fast, 150ms) ease, transform var(--duration-fast, 150ms) ease;
}

.settings-row:active,
.pl-row:active,
.plan-card:active {
  transform: scale(0.99);
}

/* Инерционный вертикальный скролл на мобильных */
html {
  -webkit-overflow-scrolling: touch;
}

/* Расширяем hit-область мелких иконок списка до 44px без визуальной перерисовки */
.track-actions .icon-btn::after {
  content: "";
  position: absolute;
  inset: -6px;
}

.track-actions .icon-btn {
  position: relative;
}

/* Пользователь просил меньше движения — убираем все переходы и анимации входа */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* --- components.css --- */
/* ============ Header ============ */

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 0 6px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: 0.14em;
}

.brand__tg {
  color: var(--text-accent);
}

.brand__music {
  color: var(--text-primary);
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--icon-primary);
  flex-shrink: 0;
}

.icon-btn {
  transition: transform 0.14s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease, color 0.2s ease;
}

.icon-btn:active {
  transform: scale(0.94);
  border-color: var(--glass-border-amethyst);
}

.icon-btn svg {
  width: 19px;
  height: 19px;
}

.avatar {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  color: #fff;
  background: var(--gradient-brand);
  position: relative;
  flex-shrink: 0;
}

.avatar--premium::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 15px;
  border: 1.5px solid var(--accent);
  opacity: 0.7;
}

.avatar--lg {
  width: 88px;
  height: 88px;
  border-radius: 26px;
  font-size: 30px;
}

/* ============ Нижний док: мини-плеер + навигация одной колонкой ============ */
/* Один fixed-контейнер исключает наложения панелей друг на друга (ТЗ §2). */

.bottom-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0 16px calc(14px + env(safe-area-inset-bottom));
  pointer-events: none;
}

/* ============ Bottom navigation ============ */

.bottom-nav {
  display: flex;
  justify-content: center;
  width: 100%;
  pointer-events: none;
}

.bottom-nav__inner {
  pointer-events: auto;
  width: 100%;
  max-width: 448px;
  display: flex;
  gap: 4px;
  padding: 8px;
  border-radius: 22px;
  background: var(--nav-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--nav-border);
  box-shadow: var(--glass-shadow);
}

.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 8px 4px 7px;
  border-radius: 15px;
  color: var(--nav-icon-inactive);
}

.nav-item svg {
  width: 21px;
  height: 21px;
  color: var(--nav-icon-inactive);
}

.nav-item span {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--nav-text-inactive);
  letter-spacing: 0.01em;
}

.nav-item.is-active {
  background: var(--nav-active-bg);
}

.nav-item.is-active svg {
  color: var(--nav-icon-active);
}

.nav-item.is-active span {
  color: var(--nav-text-active);
}

/* ============ Cards & surfaces ============ */

/* Карточек на экране десятки (списки треков) — backdrop-filter на каждой
   стоил кадров на мобильных GPU. Непрозрачный фон визуально тот же, blur
   остался только на одиночных фиксированных панелях (док, шиты). */
.card {
  background: var(--surface-card-translucent);
  border: 1px solid var(--glass-border-card);
  border-radius: 20px;
  box-shadow: var(--glass-inset), var(--glass-shadow);
}

.card--flat {
  background: var(--surface-card);
  box-shadow: none;
}

/* ============ Quick stat tiles ============ */

.tile-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 18px;
}

.tile {
  padding: 16px 14px;
  border-radius: 18px;
}

.tile__icon {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
  margin-bottom: 10px;
}

.tile__icon svg {
  width: 17px;
  height: 17px;
}

.tile__value {
  font-size: 13.5px;
  font-weight: 700;
}

.tile__label {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 1px;
}

/* ============ Track row ============ */

.track-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 10px;
  border-radius: 16px;
}

.track-row + .track-row {
  margin-top: 3px;
}

.track-row:active {
  background: var(--accent-soft);
}

.track-cover {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-dark);
  color: var(--icon-active);
  position: relative;
  overflow: hidden;
}

.track-info {
  flex: 1;
  min-width: 0;
}

.track-title {
  font-size: var(--font-body);
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-artist {
  font-size: var(--font-caption);
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.track-actions {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.track-actions .icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: transparent;
  border: none;
}

.track-actions .icon-btn svg {
  width: 16px;
  height: 16px;
}

.track-actions .icon-btn.is-added {
  color: var(--icon-active);
}

/* ============ Buttons ============ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 46px;
  padding: 0 22px;
  border-radius: 15px;
  font-size: 14px;
  font-weight: 700;
}

.btn {
  transition: transform 0.14s cubic-bezier(0.16, 1, 0.3, 1), filter 0.18s ease, background-color 0.18s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: var(--accent-glow);
}

.btn--primary:active {
  filter: brightness(0.92);
}

.btn--ghost {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border-amethyst);
  color: var(--text-primary);
}

.btn--block {
  width: 100%;
}

/* ============ Search ============ */

.search-input {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 16px;
  border-radius: 16px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
}

.search-input svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-input input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-size: 14.5px;
  color: var(--text-primary);
}

.search-input input::placeholder {
  color: var(--text-muted);
}

.empty-state {
  margin-top: 60px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}

/* ============ Settings rows ============ */

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 16px;
}

.settings-row + .settings-row {
  border-top: 1px solid var(--divider);
}

.settings-row__label {
  font-size: 13.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Пояснение под названием языка: «перевод ещё готовится» */
.settings-row__hint {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 2px;
}

.lang-flag {
  font-size: 18px;
  line-height: 1;
}

.settings-row__label svg {
  width: 17px;
  height: 17px;
  color: var(--icon-active);
  flex-shrink: 0;
}

.settings-row > svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.card--rows {
  margin-top: 12px;
  padding: 2px 16px;
}

/* Theme toggle switch */

.switch {
  width: 44px;
  height: 26px;
  border-radius: 999px;
  background: var(--progress-track);
  border: 1px solid var(--glass-border);
  position: relative;
  flex-shrink: 0;
}

.switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--text-secondary);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), background 0.25s ease;
}

.switch.is-on {
  background: var(--accent-soft);
  border-color: var(--glass-border-amethyst);
}

.switch.is-on::after {
  transform: translateX(18px);
  background: var(--accent);
}

/* ============ Premium card ============ */

.premium-card {
  margin-top: 16px;
  padding: 20px;
  border-radius: 22px;
  background: var(--gradient-premium-card);
  border: 1px solid var(--glass-border-amethyst);
  box-shadow: var(--glass-shadow);
  display: flex;
  align-items: center;
  gap: 14px;
}

.premium-card__icon {
  width: 46px;
  height: 46px;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-premium);
  flex-shrink: 0;
}

.premium-card__icon svg {
  width: 21px;
  height: 21px;
}

.premium-card__title {
  font-size: 14px;
  font-weight: 800;
}

.premium-card__subtitle {
  font-size: 12px;
  color: var(--text-accent);
  margin-top: 2px;
}

/* ============ Mini player (persistent bar) ============ */

.mini-player {
  display: flex;
  justify-content: center;
  width: 100%;
  pointer-events: none;
}

.mini-player__inner {
  pointer-events: auto;
  position: relative;
  width: 100%;
  max-width: 448px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 10px 11px 9px;
  border-radius: 18px;
  background: var(--player-bg);
  border: 1px solid var(--glass-border-amethyst);
  box-shadow: var(--glass-shadow);
  overflow: hidden;
}

.mini-player__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2.5px;
  background: var(--progress-track);
}

.mini-player__progress-fill {
  height: 100%;
  width: 0%;
  background: var(--progress-active);
}

.mini-player__cover {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mini-player__info {
  flex: 1;
  min-width: 0;
}

.mini-player__title {
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mini-player__artist {
  font-size: 11px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mini-player__play {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--play-border);
  box-shadow: var(--play-glow);
  color: var(--text-primary);
  flex-shrink: 0;
}

.mini-player__play svg {
  width: 14px;
  height: 14px;
}

/* ============ Full player screen ============ */

.player-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  justify-content: center;
  background: var(--bg-base);
}

.player-overlay__inner {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  padding: env(safe-area-inset-top) 24px calc(28px + env(safe-area-inset-bottom));
  /* Не влезло на низком экране — прокрутка, а не сплющенная обложка (19.09) */
  overflow-y: auto;
  animation: player-in 0.36s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes player-in {
  from {
    transform: translateY(28px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.player-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0 6px;
}

.player-topbar__label {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
}

.player-art {
  /* Размер обложки ограничен высотой экрана — контролы не выталкиваются вниз */
  margin: 10px auto 20px;
  width: min(100%, 40dvh);
  aspect-ratio: 1;
  /* Колонка плеера ужимала обложку по высоте, когда под ней есть кнопки
     «Скачать / Микс по треку»: рамка оставалась шире картинки (скрин 19.09) */
  flex-shrink: 0;
  border-radius: 28px;
  background: var(--gradient-dark);
  border: 1px solid var(--glass-border-amethyst);
  box-shadow: var(--glass-shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--icon-active);
  position: relative;
  overflow: hidden;
}

.player-art::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.1), transparent 55%);
}

/* Метаданные по VK: текст слева, «+» и «…» справа (ТЗ §7) */
.player-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.player-meta__text {
  flex: 1;
  min-width: 0;
  text-align: left;
}

.player-meta__title {
  font-size: var(--font-title);
  font-weight: 800;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-meta__artist {
  margin-top: 3px;
  font-size: 13.5px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-meta__actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.player-meta__actions .icon-btn {
  border-radius: 50%;
}

.player-meta__actions .icon-btn.is-added {
  color: var(--icon-active);
}

/* Чипы действий: Скачать / Текст / Поделиться */
.player-chips {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
  overflow-x: auto;
  scrollbar-width: none;
}

.player-chips::-webkit-scrollbar {
  display: none;
}

.player-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding: 0 16px;
  border-radius: var(--radius-pill);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.player-chip svg {
  width: 16px;
  height: 16px;
  color: var(--icon-active);
}

.player-chip:active {
  background: var(--accent-soft);
}

.player-topbar__spacer {
  width: 40px;
  flex-shrink: 0;
}

.player-progress {
  padding: 0 2px;
}

.progress-track {
  height: 4px;
  border-radius: 999px;
  background: var(--progress-track);
  position: relative;
  cursor: pointer;
  /* Жест перемотки не должен превращаться в скролл страницы */
  touch-action: none;
}

/* Невидимая зона касания 34px поверх тонкой полоски — палец попадает легко */
.progress-track::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 34px;
  transform: translateY(-50%);
}

.progress-track__fill {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: 999px;
  background: var(--progress-active);
  width: 0%;
}

.progress-track__thumb {
  position: absolute;
  top: 50%;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--progress-thumb);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.16);
  transform: translate(-50%, -50%);
  left: 0%;
  transition: width 0.12s, height 0.12s;
}

/* Кружок вырастает, пока палец ведёт перемотку */
.progress-track.is-seeking .progress-track__thumb {
  width: 18px;
  height: 18px;
}

.progress-times {
  display: flex;
  justify-content: space-between;
  margin-top: 9px;
  font-size: 11.5px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.player-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 26px;
  margin-top: 22px;
}

.player-controls__side {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--icon-primary);
}

.player-controls__side svg {
  width: 24px;
  height: 24px;
}

.player-controls__side.is-active {
  color: var(--icon-active);
}

/* Play разумного размера — не «огромная кнопка» (ТЗ §7) */
.player-controls__play {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: #111;
  box-shadow: var(--play-glow);
  flex-shrink: 0;
  transition: transform var(--duration-fast) var(--ease-spring);
}

.player-controls__play:active {
  transform: scale(0.9);
}

.mini-player__play {
  transition: transform var(--duration-fast) var(--ease-spring);
}

.mini-player__play:active {
  transform: scale(0.88);
}

.player-controls__play svg {
  width: 22px;
  height: 22px;
}

.player-tabs {
  display: flex;
  gap: 20px;
  margin-top: 34px;
  border-bottom: 1px solid var(--divider);
}

.player-tab {
  padding: 0 2px 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  position: relative;
}

.player-tab.is-active {
  color: var(--text-primary);
}

.player-tab.is-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: var(--gradient-brand);
}

.player-tab-content {
  padding: 18px 2px 0;
  font-size: 13px;
  line-height: 1.75;
  color: var(--text-secondary);
  min-height: 80px;
}

/* ============ Bottom sheet: настройки трека ============ */

.sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: var(--overlay-scrim);
  animation: fade-in 0.25s ease;
}

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

.sheet {
  width: 100%;
  max-width: 480px;
  padding: 10px 18px calc(24px + env(safe-area-inset-bottom));
  border-radius: 26px 26px 0 0;
  background: var(--surface-elevated);
  border: 1px solid var(--glass-border-amethyst);
  border-bottom: none;
  box-shadow: 0 -18px 60px rgba(0, 0, 0, 0.35);
  animation: sheet-in 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes sheet-in {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.sheet__handle {
  width: 36px;
  height: 4px;
  border-radius: 999px;
  background: var(--divider);
  margin: 6px auto 14px;
}

.sheet__track {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 14px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--divider);
}

.sheet-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 4px;
  font-size: 14px;
  font-weight: 600;
}

.sheet-item svg {
  width: 19px;
  height: 19px;
  color: var(--icon-active);
}

.sheet-item.is-danger svg,
.sheet-item.is-danger {
  color: var(--text-secondary);
}

.sheet-item.is-danger svg {
  color: var(--text-secondary);
}

/* ============ Boot / toast / covers ============ */

.boot-screen {
  min-height: 70dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  color: var(--text-secondary);
  font-size: 14px;
  padding: 0 32px;
  text-align: center;
}

.boot-spinner {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 3px solid var(--progress-track);
  border-top-color: var(--accent);
  animation: boot-spin 0.9s linear infinite;
}

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

.boot-error {
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.5;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 160px;
  transform: translateX(-50%);
  z-index: 90;
  padding: 11px 20px;
  border-radius: 14px;
  background: var(--surface-elevated);
  border: 1px solid var(--glass-border-amethyst);
  box-shadow: var(--glass-shadow);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  animation: toast-in 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Абстрактная «кристалл аметиста» обложка: слой блика + приглушённая нота */
.cover-art {
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.cover-facet {
  position: absolute;
  inset: -40% -10%;
  background: linear-gradient(
    115deg,
    transparent 40%,
    rgba(255, 255, 255, 0.14) 48%,
    transparent 56%
  );
  pointer-events: none;
}

.cover-note-icon {
  position: relative;
  display: flex;
  color: rgba(255, 255, 255, 0.32);
}

.cover-note-icon svg {
  width: 34%;
  height: 34%;
  margin: auto;
}

.track-cover .cover-note-icon svg {
  width: 18px;
  height: 18px;
}

.mini-player__cover .cover-note-icon svg {
  width: 16px;
  height: 16px;
}

.player-art .cover-note-icon svg {
  width: 30%;
  height: 30%;
}

.track-row.is-playing .track-title {
  color: var(--text-accent);
}

/* ============ Hero-карусель (свайп между миксами, VK-стиль) ============ */

.hero {
  position: relative;
  margin-top: 12px;
}

.hero__track {
  border-radius: var(--radius-xl);
}

.hero-slide {
  flex: 0 0 100%;
  width: 100%;
  min-height: 340px;
  padding: 34px 22px 64px;
  border-radius: var(--radius-xl);
  text-align: center;
  /* VK Микс: синий верх → маджента низ (скрины владельца в копи/) */
  background: linear-gradient(180deg, #0e63ee 0%, #2f86ff 30%, #ef1fd4 62%, #ff2ad9 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Волновая граница между синим и маджентой + вертикальные штрихи-эквалайзер */
.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(18% 7% at 8% 44%, rgba(255, 255, 255, 0.9), transparent 70%),
    radial-gradient(22% 9% at 26% 47%, rgba(255, 255, 255, 0.8), transparent 70%),
    radial-gradient(16% 6% at 43% 43%, rgba(255, 255, 255, 0.9), transparent 70%),
    radial-gradient(24% 10% at 61% 46%, rgba(255, 255, 255, 0.75), transparent 70%),
    radial-gradient(18% 7% at 78% 42%, rgba(255, 255, 255, 0.85), transparent 70%),
    radial-gradient(20% 8% at 94% 45%, rgba(255, 255, 255, 0.8), transparent 70%),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.07) 0 2px,
      transparent 2px 9px
    );
  filter: blur(5px);
  pointer-events: none;
}

.hero-slide:active {
  filter: brightness(0.96);
}

/* Фон под Infinity Mix (первый слайд): фото владельца + затемняющий слой сверху,
   чтобы белый заголовок/кнопка Play читались на любой картинке.
   Файла нет → остаётся исходный градиент, ничего не ломается. */
.hero-slide:first-child {
  background-image: linear-gradient(180deg, rgba(8, 10, 20, 0.35) 0%, rgba(8, 10, 20, 0.68) 100%),
    url("/assets/mix-bg.jpg");
  background-size: cover;
  background-position: center;
}

/* Белые штрихи-эквалайзер поверх фото приглушаем, иначе спорят с картинкой */
.hero-slide:first-child::before {
  opacity: 0.22;
}

.hero-slide__play {
  position: relative;
  width: 84px;
  height: 84px;
  margin-bottom: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  box-shadow: var(--play-glow);
  transition: transform var(--duration-fast) var(--ease-spring);
}

.hero-slide:active .hero-slide__play {
  transform: scale(0.93);
}

/* Дышащее кольцо вокруг Play — приглашение к действию, не декорация */
.hero-slide__play::after {
  content: "";
  position: absolute;
  inset: -9px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  animation: play-breathe 2.6s var(--ease-out-expo) infinite;
  pointer-events: none;
}

@keyframes play-breathe {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.55;
  }
  50% {
    transform: scale(1.12);
    opacity: 0.15;
  }
}

.hero-slide__play svg {
  width: 30px;
  height: 30px;
  color: #111;
  margin-left: 4px;
}

.hero-slide__title {
  position: relative;
  font-size: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.25);
}

.hero-slide__subtitle {
  position: relative;
  margin-top: 7px;
  font-size: var(--font-body);
  color: rgba(255, 255, 255, 0.85);
}

.hero-slide__setup {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 18px;
  height: 42px;
  padding: 0 20px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

.hero-slide__setup svg {
  width: 16px;
  height: 16px;
}

/* Подсказка свайпа — внутри слайда (текст меняется от слайда к слайду, как в VK) */
.hero-slide__hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 13.5px;
  font-weight: 600;
}

/* Стрелки кликабельны: на ПК свайпа нет — навигация мышью */
.hero-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.92);
}

.hero-arrow svg {
  width: 17px;
  height: 17px;
}

.hero-arrow:active {
  background: rgba(255, 255, 255, 0.18);
}

/* ============ Плитки быстрого доступа (VK-стиль, 2×2) ============ */

.vk-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 18px;
}

/* Плитка как строка главной VK: цветная иконка-квадрат слева, текст справа */
.vk-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  text-align: left;
}

.vk-tile:active {
  background: var(--surface-elevated);
}

.vk-tile__text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.vk-tile__title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.25;
}

.vk-tile__sub {
  font-size: 13px;
  color: var(--text-muted);
}

.vk-tile__icon {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}

.vk-tile__icon--magenta {
  background: linear-gradient(160deg, #e935d1, #a01fee);
}

.vk-tile__icon--teal {
  background: linear-gradient(160deg, #14b8c4, #0e8f9e);
}

.vk-tile__icon--violet {
  background: linear-gradient(160deg, #7a5cff, #b04df0);
}

.vk-tile__icon svg {
  width: 24px;
  height: 24px;
}

/* ============ Карточка подписки (только не-Premium) ============ */

.sub-card {
  position: relative;
  margin-top: 14px;
  padding: 20px 20px 18px;
  border-radius: var(--radius-lg);
  background: var(--gradient-premium-card);
  overflow: hidden;
}

.sub-card__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.75);
  background: rgba(0, 0, 0, 0.16);
}

.sub-card__close svg {
  width: 15px;
  height: 15px;
}

.sub-card__title {
  font-size: 19px;
  font-weight: 800;
  padding-right: 32px;
  color: #fff;
}

.sub-card__subtitle {
  margin-top: 4px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.78);
}

.sub-card__cta {
  display: inline-flex;
  align-items: center;
  height: 40px;
  margin-top: 15px;
  padding: 0 22px;
  border-radius: var(--radius-md);
  background: #fff;
  color: #14141a;
  font-size: 13.5px;
  font-weight: 800;
}

/* ============ Быстрый доступ ============ */

.quick-access {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quick-tile {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  text-align: left;
}

.quick-tile:active {
  background: var(--accent-soft);
}

.quick-tile__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
  flex-shrink: 0;
}

.quick-tile__icon svg {
  width: 19px;
  height: 19px;
}

.quick-tile__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.quick-tile__title {
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.quick-tile__sub {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 1px;
}

/* ============ Шапка вложенной страницы ============ */

.page-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 0 14px;
}

.page-head span {
  font-size: var(--font-heading);
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

/* ============ Настройки рекомендаций ============ */

.rec-section-label {
  margin: 22px 2px 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mood-grid {
  padding: 2px;
}

.mood-tile {
  width: 88px;
  padding: 14px 8px 12px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
}

.mood-tile__icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
}

.mood-tile__icon svg {
  width: 24px;
  height: 24px;
}

.mood-tile__label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.mood-tile.is-active {
  border-color: var(--accent);
  box-shadow: var(--accent-glow);
}

.mood-tile.is-active .mood-tile__label {
  color: var(--text-primary);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.pill {
  height: 40px;
  padding: 0 18px;
  border-radius: var(--radius-pill);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
}

.pill.is-active {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--text-primary);
}

.rec-actions {
  display: flex;
  gap: 10px;
  margin-top: 30px;
}

.rec-actions .btn {
  flex: 1;
}

.empty-state--sm {
  margin-top: 14px;
  padding: 8px 12px;
}

/* ============ Поиск: чипы запросов ============ */

.section-head--between {
  justify-content: space-between;
}

.chip-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.search-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 100%;
  height: 38px;
  padding: 0 14px;
  border-radius: var(--radius-pill);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 600;
}

.search-chip svg {
  width: 14px;
  height: 14px;
  color: var(--icon-active);
  flex-shrink: 0;
}

.search-chip span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-chip:active {
  background: var(--accent-soft);
  border-color: var(--glass-border-amethyst);
}

/* ============ Библиотека: блоки «Мои треки» по 3 ============ */

.lib-cols {
  margin-top: 4px;
}

.lib-col {
  flex: 0 0 86%;
  padding: 6px;
  border-radius: var(--radius-lg);
  background: var(--glass-bg-card);
  border: 1px solid var(--glass-border-card);
  box-shadow: var(--glass-inset);
}

/* Одна колонка целиком (треков ≤ 3) — на всю ширину, без «подглядывания» */
.lib-cols > .lib-col:only-child {
  flex-basis: 100%;
}

.lib-mix-row {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

.lib-mix-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 15px 6px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-soft);
}

.lib-mix-btn:active {
  background: var(--accent-soft);
}

.lib-mix-btn__icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: var(--accent-glow);
}

.lib-mix-btn__icon svg {
  width: 19px;
  height: 19px;
}

/* ============ Раздел «Ещё» ============ */

.more-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 12px;
}

.more-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  text-align: left;
  min-height: 60px;
}

.more-tile:active {
  background: var(--accent-soft);
}

.more-tile__icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
  flex-shrink: 0;
}

.more-tile__icon svg {
  width: 18px;
  height: 18px;
}

.more-tile__label {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

/* ============ Любимые исполнители ============ */

.page-hint {
  margin: -6px 2px 16px;
  font-size: 12.5px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.artist-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.artist-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  text-align: left;
}

.artist-row__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  color: #fff;
  background: var(--gradient-brand);
  flex-shrink: 0;
}

.artist-row__info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.artist-row__name {
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.artist-row__count {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 1px;
}

.artist-row__heart {
  display: flex;
  color: var(--icon-inactive);
  flex-shrink: 0;
}

.artist-row__heart svg {
  width: 20px;
  height: 20px;
}

.artist-row.is-fav .artist-row__heart {
  color: var(--accent);
}

.artist-row.is-fav .artist-row__heart svg {
  fill: var(--accent);
}

/* ============ Документы (FAQ / политика / лицензия / о приложении) ============ */

.doc-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.doc-block__heading {
  font-size: 14.5px;
  font-weight: 800;
  margin-bottom: 6px;
}

.doc-block__text {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* ============ Профиль: ранг, прогресс, статистика, достижения ============ */

.rank-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-left: 6px;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  border: 1px solid var(--glass-border-amethyst);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-accent);
  vertical-align: middle;
}

.rank-progress {
  margin-top: 18px;
  padding: 16px 18px;
}

.rank-progress__text {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
}

.rank-progress__bar {
  margin-top: 10px;
  height: 8px;
  border-radius: var(--radius-pill);
  background: var(--progress-track);
  overflow: hidden;
}

.rank-progress__bar span {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: var(--gradient-brand);
}

.pstat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.pstat {
  padding: 14px 6px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  text-align: center;
}

.pstat__value {
  font-size: 19px;
  font-weight: 800;
  color: var(--text-accent);
}

.pstat__label {
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--text-muted);
}

.ach-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ach-badge {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  filter: grayscale(1);
  opacity: 0.45;
}

.ach-badge.is-unlocked {
  filter: none;
  opacity: 1;
  border-color: var(--glass-border-amethyst);
  background: var(--accent-soft);
}

/* ============ Экран достижений ============ */

.ach-summary {
  margin: 2px 2px 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-accent);
}

.ach-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ach-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
}

.ach-card__emoji {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  background: var(--bg-base);
  filter: grayscale(1);
  opacity: 0.5;
  flex-shrink: 0;
}

.ach-card.is-unlocked {
  border-color: var(--glass-border-amethyst);
}

.ach-card.is-unlocked .ach-card__emoji {
  filter: none;
  opacity: 1;
  background: var(--accent-soft);
}

.ach-card__body {
  flex: 1;
  min-width: 0;
}

.ach-card__title {
  font-size: 13.5px;
  font-weight: 700;
}

.ach-card__done {
  margin-top: 3px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-accent);
}

.ach-card__bar {
  margin-top: 8px;
  height: 6px;
  border-radius: var(--radius-pill);
  background: var(--progress-track);
  overflow: hidden;
}

.ach-card__bar span {
  display: block;
  height: 100%;
  background: var(--gradient-brand);
}

.ach-card__progress {
  margin-top: 5px;
  font-size: 11px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

/* ============ Текст песни ============ */

.lyrics-track {
  margin: -8px 2px 16px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-accent);
}

.lyrics-text {
  margin: 0;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  font-family: inherit;
  font-size: 14.5px;
  line-height: 1.85;
  color: var(--text-soft);
  white-space: pre-wrap;
  word-wrap: break-word;
}

.lyrics-meta {
  margin: 10px 2px 0;
  font-size: 11.5px;
  color: var(--text-muted);
}

.lyrics-input {
  width: 100%;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.7;
  resize: vertical;
  outline: none;
}

.lyrics-input:focus {
  border-color: var(--glass-border-amethyst);
}

/* Переключатель «Треки / Минусы» в поиске */
.search-mode {
  margin-bottom: 12px;
}

/* ============ Аватар-фото из Telegram (ТЗ §22) ============ */

.avatar {
  overflow: hidden;
}

.avatar__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ============ Сегменты-вкладки: Все / Скачанные (ТЗ §5) ============ */

.seg-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.seg {
  flex: 1;
  height: 42px;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-secondary);
  font-size: 13.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.seg.is-active {
  background: var(--surface-card);
  color: var(--text-primary);
}

.seg__count {
  font-weight: 600;
  color: var(--text-muted);
  font-size: 12.5px;
}

/* ============ Мои треки: тулбар Shuffle / Sort ============ */

.search-input--compact {
  height: 44px;
  margin-bottom: 4px;
}

.mt-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 12px 2px 10px;
}

.mt-shuffle {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-accent);
}

.mt-shuffle svg {
  width: 19px;
  height: 19px;
}

.mt-sort {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-accent);
}

.mt-sort svg {
  width: 15px;
  height: 15px;
}

.mt-remove {
  color: #ff5d73;
}

.page-head__action {
  margin-left: auto;
}

.page-head__action.is-active {
  color: var(--accent);
  border-color: var(--accent);
}

.sheet__title {
  text-align: center;
  font-size: 15px;
  font-weight: 800;
  padding: 2px 0 10px;
  border-bottom: 1px solid var(--divider);
  margin-bottom: 6px;
}

/* ============ Плейлисты: строки с обложкой (ТЗ §6) ============ */

.pl-row {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  padding: 9px 10px;
  margin-top: 6px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  text-align: left;
}

.pl-row:active {
  background: var(--accent-soft);
}

.pl-row > svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.pl-cover {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  background: var(--gradient-dark);
  flex-shrink: 0;
}

.pl-cover--create {
  background: var(--surface-elevated);
  color: var(--text-accent);
}

.pl-cover--create svg,
.pl-cover--icon svg {
  width: 22px;
  height: 22px;
}

.pl-cover--icon {
  background: var(--accent-soft);
  color: var(--icon-active);
}

.pl-row__text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.pl-row__title {
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pl-row__sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 1px;
}

.pl-create-form {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.pl-create-form input {
  flex: 1;
  min-width: 0;
  height: 46px;
  padding: 0 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
}

.pl-create-form .btn {
  padding: 0 14px;
}

/* ============ Страница подборки: hero (ТЗ §6) ============ */

.coll-hero {
  text-align: center;
  margin-bottom: 18px;
}

.coll-hero__cover {
  width: 168px;
  height: 168px;
  margin: 6px auto 14px;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 54px;
  font-weight: 800;
  color: #fff;
  background: var(--gradient-dark);
  box-shadow: var(--glass-shadow);
}

.coll-hero__title {
  font-size: 20px;
  font-weight: 800;
}

.coll-hero__meta {
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-muted);
}

.coll-hero__actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.coll-hero__actions .btn {
  flex: 1;
}

/* ============ Реферальная программа (ТЗ §23) ============ */

.ref-intro {
  text-align: center;
  padding: 6px 8px 2px;
}

.ref-intro__emoji {
  font-size: 44px;
}

.ref-intro__title {
  margin-top: 8px;
  font-size: 18px;
  font-weight: 800;
}

.ref-intro__text {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-secondary);
}

.ref-progress {
  margin-top: 16px;
  padding: 16px 18px;
}

.ref-progress__row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 8px;
}

.ref-progress__count {
  font-size: 28px;
  font-weight: 800;
  color: var(--text-accent);
}

.ref-progress__label {
  font-size: 13px;
  color: var(--text-secondary);
  flex: 1;
}

.ref-steps .ref-step {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 0;
}

.ref-steps .ref-step + .ref-step {
  border-top: 1px solid var(--divider);
}

.ref-step__num {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--text-accent);
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}

.ref-step__text {
  font-size: 13.5px;
  font-weight: 600;
}

.ref-rewards {
  padding: 6px 16px;
}

.ref-reward {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
}

.ref-reward + .ref-reward {
  border-top: 1px solid var(--divider);
}

.ref-reward__check {
  display: flex;
  color: var(--icon-inactive);
  flex-shrink: 0;
}

.ref-reward__check svg {
  width: 18px;
  height: 18px;
}

.ref-reward.is-done .ref-reward__check {
  color: var(--accent);
}

.ref-reward__friends {
  font-size: 13.5px;
  font-weight: 700;
  flex: 1;
}

.ref-reward__prize {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-accent);
}

.ref-reward.is-done .ref-reward__friends {
  color: var(--text-muted);
}

.pstat-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

/* ============ Premium: тарифы (ТЗ §24) ============ */

.premium-hero {
  text-align: center;
  padding: 8px 0 4px;
}

.premium-hero__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-premium-card);
  color: #fff;
}

.premium-hero__icon svg {
  width: 30px;
  height: 30px;
}

.premium-hero__title {
  margin-top: 12px;
  font-size: 19px;
  font-weight: 800;
}

.premium-hero__sub {
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-secondary);
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.plan-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 16px 14px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1.5px solid var(--glass-border);
  text-align: left;
}

.plan-card.is-active {
  border-color: var(--accent);
  box-shadow: var(--accent-glow);
}

.plan-card--best {
  background: var(--gradient-premium-card);
}

.plan-card--best .plan-card__monthly,
.plan-card--best .plan-card__label {
  color: rgba(255, 255, 255, 0.85);
}

.plan-card--best .plan-card__price {
  color: #fff;
}

.plan-card__badge {
  position: absolute;
  top: -9px;
  right: 10px;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: #fff;
  color: #14141a;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.plan-card__label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-secondary);
}

.plan-card__price {
  font-size: 19px;
  font-weight: 800;
}

.plan-card__price s {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
  margin-left: 4px;
}

.plan-card__monthly {
  font-size: 11.5px;
  color: var(--text-muted);
}

/* ============ О приложении (ТЗ §20) ============ */

.about-hero {
  text-align: center;
  padding: 18px 0 16px;
}

.about-hero__logo {
  width: 84px;
  height: 84px;
  margin: 0 auto;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  background: var(--gradient-dark);
  box-shadow: var(--glass-shadow);
}

.about-hero__name {
  margin-top: 12px;
  font-size: 20px;
  font-weight: 800;
}

.about-hero__version {
  margin-top: 3px;
  font-size: 12.5px;
  color: var(--text-muted);
}

/* ============ Текст песни: шапка трека (ТЗ §8) ============ */

.lyrics-track__title {
  font-size: 17px;
  font-weight: 800;
  color: var(--text-primary);
}

.lyrics-track__artist {
  margin-top: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* ============ «Какой сейчас вайб?» — mood-миксы на главной (скрины VK) ============ */

.vibe-section {
  margin-top: 22px;
}

.vibe-section__label {
  font-size: 13px;
  color: var(--text-muted);
}

.vibe-section__title {
  margin-top: 2px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.vibe-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.vibe-card {
  flex: 0 0 62%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 88px;
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 19px;
  font-weight: 800;
  scroll-snap-align: start;
}

.vibe-card svg {
  width: 18px;
  height: 18px;
}

.vibe-card:active {
  filter: brightness(0.94);
}

.vibe-card--love {
  background: linear-gradient(120deg, #d773b8, #e88ec9 55%, #c95ba4);
}

.vibe-card--happy {
  background: linear-gradient(120deg, #e9a83a, #f0bd63 55%, #dd9426);
}

.vibe-card--sad {
  background: linear-gradient(120deg, #d9575e, #e3767c 55%, #c74850);
}

.vibe-card--active {
  background: linear-gradient(120deg, #e2571f, #ef7a43 55%, #d54a15);
}

.vibe-card--calm {
  background: linear-gradient(120deg, #9fd2e8, #c2e4f2 55%, #8ac4de);
  color: #0f2c3a;
}

/* ============ ПК-адаптация: hover-состояния при точном указателе ============ */

@media (hover: hover) and (pointer: fine) {
  button {
    cursor: pointer;
  }

  .track-row:hover,
  .vk-tile:hover,
  .sheet-item:hover {
    background: var(--surface-elevated);
  }

  .icon-btn:hover,
  .hero-arrow:hover {
    background: rgba(255, 255, 255, 0.14);
  }

  .hero-slide:hover .hero-slide__play {
    transform: scale(1.05);
  }

  .vibe-card:hover,
  .sub-card:hover,
  .hero-slide__setup:hover {
    filter: brightness(1.06);
  }

  .pill:hover,
  .seg:hover,
  .search-chip:hover,
  .btn:hover {
    filter: brightness(1.12);
  }
}

/* ============ Эквалайзер (скрины VK) ============ */

.hint-text {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 3px;
  font-weight: 400;
}

.eq-bands {
  display: flex;
  justify-content: space-between;
  gap: 4px;
  margin: 18px 2px 16px;
}

.eq-bands.is-disabled {
  opacity: 0.45;
}

.eq-band {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}

/* Вертикальный слайдер: горизонтальный input повёрнут на -90° внутри колонки */
.eq-band__slider {
  position: relative;
  width: 30px;
  height: 150px;
}

.eq-band__slider input {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 150px;
  height: 30px;
  transform: translate(-50%, -50%) rotate(-90deg);
  appearance: none;
  background: transparent;
}

.eq-band__slider input::-webkit-slider-runnable-track {
  height: 3px;
  border-radius: 2px;
  background: var(--progress-track);
}

.eq-band__slider input::-webkit-slider-thumb {
  appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -7.5px;
  border-radius: 50%;
  background: #b9b9c0;
  border: none;
}

.eq-band__slider input::-moz-range-track {
  height: 3px;
  border-radius: 2px;
  background: var(--progress-track);
}

.eq-band__slider input::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #b9b9c0;
  border: none;
}

.eq-band__label {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
}

.sheet-item.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

/* ============ Плеер: нижние табы, очередь, чип-иконка (скрины VK доп копи/) ============ */

.player-bottombar {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--divider);
}

.player-bottombar__tab {
  flex: 1;
  height: 44px;
  border-radius: var(--radius-md);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.player-bottombar__tab:active {
  background: var(--surface-elevated);
}

.player-bottombar__count {
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.12);
  font-size: 12px;
}

.player-chip--icon {
  padding: 0 12px;
}

.sheet--tall {
  max-height: 78dvh;
  display: flex;
  flex-direction: column;
}

.queue-list {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -4px;
}

.queue-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 14px;
  text-align: left;
}

.queue-row.is-current {
  background: var(--accent-soft);
}

.queue-row.is-current .track-title {
  color: var(--text-accent);
}

.queue-row svg {
  width: 18px;
  height: 18px;
  color: var(--icon-active);
  flex-shrink: 0;
}

.queue-row:active {
  background: var(--surface-elevated);
}

/* ============ Производительность длинных списков ============ */
/* Строки вне вьюпорта не раскладываются и не красятся браузером: список из
   сотен треков скроллится без рывков. Высота-заглушка = высота строки. */

.track-row,
.queue-row {
  content-visibility: auto;
  contain-intrinsic-size: auto 64px;
}

/* Компоновка строки изолирована — правка одной не пересчитывает соседей */
.track-row {
  contain: layout style;
}

/* ============ Перенос из других сервисов (скрин копи/ photo_16) ============ */

.transfer-hero {
  margin: 12px 0 20px;
}

.transfer-hero__title {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.transfer-hero__sub {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--text-muted);
}

.transfer-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.transfer-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  border: 1.5px solid transparent;
  text-align: left;
}

.transfer-card.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.transfer-card__logo {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 18px;
  color: #fff;
  margin-bottom: 6px;
}

.transfer-card--spotify .transfer-card__logo { background: #1db954; }
.transfer-card--yandex .transfer-card__logo { background: #ffcc00; color: #1a1a1a; }
.transfer-card--vk .transfer-card__logo { background: #0077ff; }
.transfer-card--sc .transfer-card__logo { background: #ff5500; }

.transfer-card__label {
  font-size: 15px;
  font-weight: 700;
}

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

.transfer-input {
  width: 100%;
  margin-top: 8px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  font-size: 14.5px;
  font-family: inherit;
  resize: vertical;
}

.transfer-input:focus {
  outline: none;
  border-color: var(--accent);
}

.transfer-result {
  margin-top: 14px;
  padding: 14px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-secondary);
}

.transfer-steps .settings-row {
  font-size: 13.5px;
}

/* ============ Конверсия: триал, награды, лидерборд ============ */

.trial-banner {
  margin: 14px 0;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: linear-gradient(120deg, #1f8a4c, #2fc46f 55%, #16a34a);
  color: #fff;
}

.trial-banner__title {
  font-size: 19px;
  font-weight: 800;
}

.trial-banner__sub {
  margin-top: 4px;
  font-size: 13.5px;
  opacity: 0.9;
}

.trial-banner .btn--primary {
  background: #fff;
  color: #14663a;
  box-shadow: none;
}

.ref-next {
  margin-top: 12px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: var(--accent-soft);
  border: 1px solid var(--glass-border-amethyst);
}

.ref-next__title {
  font-size: 15.5px;
  font-weight: 700;
}

.ref-next__sub {
  margin-top: 3px;
  font-size: 12.5px;
  color: var(--text-muted);
}

.ref-teaser {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-top: 18px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  text-align: left;
}

.ref-teaser:active {
  background: var(--surface-elevated);
}

.ref-teaser__emoji {
  font-size: 26px;
}

.ref-teaser__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ref-teaser__title {
  font-size: 15px;
  font-weight: 700;
}

.ref-teaser__sub {
  font-size: 12.5px;
  color: var(--text-muted);
}

.ref-teaser svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.leader-list {
  padding: 6px 4px;
}

.leader-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
}

.leader-row__place {
  width: 26px;
  font-size: 15px;
  font-weight: 800;
  color: var(--text-secondary);
}

.leader-row__name {
  flex: 1;
  font-size: 14.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.leader-row__count {
  font-size: 14px;
  font-weight: 800;
  color: var(--text-accent);
}

.ach-bank {
  margin: 10px 0 6px;
  padding: 14px 16px;
  font-size: 14px;
}

.ach-card__reward {
  margin-left: 6px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-accent);
  white-space: nowrap;
}

/* ============ Профиль: широкая градиентная шапка + топы (скрины VK) ============ */

.profile-hero--wide {
  position: relative;
  margin: 0 calc(-1 * var(--space-4)) 16px;
  padding: 28px 20px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: linear-gradient(170deg, #6b2b2b 0%, #3a1f2c 55%, var(--bg-base) 100%);
}

.profile-hero--wide .avatar--lg {
  border-radius: 50%;
  width: 108px;
  height: 108px;
}

.profile-hero--wide .avatar__img {
  border-radius: 50%;
}

.profile-hero__tags {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.72);
  text-align: center;
}

.top-list {
  padding: 4px;
  margin-top: 8px;
}

.top-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 14px;
  text-align: left;
}

.top-row:active {
  background: var(--surface-elevated);
}

.top-row__num {
  width: 20px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
}

.top-row__name {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 14.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-row__artist {
  font-size: 12.5px;
  font-weight: 400;
  color: var(--text-muted);
}

.top-row__count {
  font-size: 13px;
  color: var(--text-muted);
}

/* ============ Загрузка трека из Mini App ============ */

.lib-add-row {
  margin-top: 8px;
}

.upload-drop {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 16px;
  margin-top: 8px;
  border-radius: var(--radius-md);
  background: var(--glass-bg);
  border: 1.5px dashed var(--glass-border-amethyst);
  cursor: pointer;
}

.upload-drop:active {
  background: var(--surface-elevated);
}

.upload-drop__icon {
  display: flex;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
}

.upload-drop__icon svg {
  width: 22px;
  height: 22px;
}

.upload-drop__text {
  flex: 1;
  font-size: 14px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.req-mark {
  font-size: 11px;
  font-weight: 600;
  color: #e35d6a;
  margin-left: 4px;
}

/* ============ Онбординг первого входа ============ */

.onboarding {
  display: flex;
  flex-direction: column;
  min-height: 82dvh;
  padding: 20px 4px 24px;
}

.onb-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.onb-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--surface-elevated);
  transition: width var(--duration-normal) var(--ease-out-expo);
}

.onb-dot.is-active {
  width: 22px;
  border-radius: 4px;
  background: var(--accent);
}

.onb-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Гейт обязательной подписки (блок B) — поверх всего */
.sub-gate {
  min-height: 100dvh;
  padding: 32px 22px calc(32px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  gap: 14px;
}

.sub-gate__icon {
  color: var(--accent);
  display: flex;
  justify-content: center;
}

.sub-gate__icon svg {
  width: 56px;
  height: 56px;
}

.sub-gate__title {
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.sub-gate__text {
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--text-muted);
}

.sub-gate__channels {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 8px 0;
}

.sub-gate__channel {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.sub-gate__channel.is-done {
  opacity: 0.6;
}

.sub-gate__check {
  margin-top: 6px;
}

.onb-hero {
  text-align: center;
  margin-bottom: 28px;
}

.onb-hero__logo {
  font-size: 64px;
  margin-bottom: 14px;
}

.onb-hero__title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.onb-hero__sub {
  margin-top: 10px;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--text-muted);
}

.onb-points {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.onb-point {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14.5px;
}

.onb-point svg {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  padding: 9px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--icon-active);
}

.onb-step-head {
  font-size: 22px;
  font-weight: 800;
  text-align: center;
}

.onb-step-sub {
  margin: 8px 0 20px;
  font-size: 14px;
  color: var(--text-muted);
  text-align: center;
}

.onb-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 28px;
}

.onb-chip {
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  background: var(--surface-card);
  border: 1.5px solid transparent;
  font-size: 14px;
  font-weight: 600;
}

.onb-chip.is-active {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--text-accent);
}

/* ============ Перенос: подсказки на выбранный сервис (photo_13) ============ */

.transfer-prompt {
  margin-top: 18px;
  margin-bottom: 8px;
  font-size: 16px;
  font-weight: 700;
}

.transfer-warn {
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-card);
  font-size: 12.5px;
  color: var(--text-muted);
  text-align: center;
}

/* ============ Premium: плюшки с описанием + тариф «навсегда» ============ */

.perk-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 14px;
}

.perk-row + .perk-row {
  border-top: 1px solid var(--divider);
}

.perk-row__icon {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--icon-active);
}

.perk-row__icon svg {
  width: 18px;
  height: 18px;
}

.perk-row__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.perk-row__title {
  font-size: 14.5px;
  font-weight: 700;
}

.perk-row__desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.35;
}

.plan-card--forever {
  border-color: #f0b429;
  background: linear-gradient(150deg, rgba(240,180,41,0.14), transparent);
}

.plan-card--forever .plan-card__badge {
  background: linear-gradient(120deg, #f0b429, #e08a1e);
  color: #1a1200;
}

/* Настоящая обложка поверх градиентной заглушки */
.cover-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/* Карточка артиста (SPEC-КАТАЛОГ §2): баннер-hero, аватар, жанры, альбомы */
.artist-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 28px 16px 20px;
  border-radius: var(--radius-lg, 16px);
  background: var(--surface, #202022);
  background-size: cover;
  background-position: center;
  margin-bottom: 14px;
}

.artist-hero__avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.18);
}

.artist-hero__avatar--letter {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  font-weight: 800;
  background: linear-gradient(135deg, #2e55f2, #4a7bfb);
  color: #fff;
}

.artist-hero__name {
  font-size: 22px;
  font-weight: 800;
  text-align: center;
}

.artist-hero__genres {
  justify-content: center;
}

.artist-card__desc {
  font-size: 13.5px;
  line-height: 1.45;
  color: var(--text-muted);
  margin: 0 4px 14px;
}

.artist-albums {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.artist-album {
  flex: 0 0 128px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.artist-album__cover {
  width: 128px;
  height: 128px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--surface, #202022);
}

.artist-album__cover--letter {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 800;
  color: var(--text-muted);
}

.artist-album__name {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.artist-album__count {
  font-size: 11.5px;
  color: var(--text-muted);
}

/* Карточка артиста: подписка, последний релиз, синглы, похожие */
.artist-hero__follow {
  margin-top: 4px;
}

.btn--outline {
  background: transparent;
  border: 1.5px solid var(--accent, #3b7bfe);
  color: var(--accent, #3b7bfe);
}

.latest-release {
  margin: 4px 0 14px;
}

.latest-release__label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent, #3b7bfe);
  margin-bottom: 8px;
}

.latest-release__body {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 12px;
  background: var(--surface, #202022);
  cursor: pointer;
}

.latest-release__info {
  flex: 1;
  min-width: 0;
}

.latest-release__play {
  flex: 0 0 auto;
}

.similar-artists {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.similar-artist {
  flex: 0 0 88px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  color: inherit;
  cursor: pointer;
}

.similar-artist__avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  object-fit: cover;
}

.similar-artist__avatar--letter {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #2e55f2, #4a7bfb);
  color: #fff;
}

.similar-artist__name {
  font-size: 12px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 84px;
}

.artist-row__avatar-img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 auto;
}

/* ---------- Конкурсы (SPEC-2.0 §28) ---------- */

.contest-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-top: 16px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: linear-gradient(120deg, rgba(59, 123, 254, 0.22), rgba(239, 63, 127, 0.22));
  border: 1px solid var(--accent-soft);
  text-align: left;
}

.contest-banner:active {
  filter: brightness(1.1);
}

.contest-banner__emoji {
  font-size: 26px;
}

.contest-banner__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.contest-banner__title {
  font-size: 15px;
  font-weight: 700;
}

.contest-banner__sub {
  font-size: 12.5px;
  color: var(--text-muted);
}

.contest-banner svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.contest-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contest-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--surface-card);
}

.contest-card__prize {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  align-self: flex-start;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.contest-card__prize svg {
  width: 15px;
  height: 15px;
}

.contest-card__title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
}

.contest-card__meta {
  font-size: 12.5px;
  color: var(--text-muted);
}

.contest-card__text {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  white-space: pre-line;
}

.contest-conds {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contest-cond {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
  color: var(--text-muted);
}

.contest-cond.is-done {
  color: var(--text-primary);
}

.contest-cond__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--surface-elevated);
  flex: 0 0 auto;
}

.contest-cond.is-done .contest-cond__mark {
  background: var(--accent-soft);
  color: var(--accent);
}

.contest-cond__mark svg {
  width: 13px;
  height: 13px;
}

.contest-card__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.contest-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
}

.contest-btn:active {
  background: var(--accent-pressed);
}

.contest-btn--ghost {
  background: var(--surface-elevated);
  color: var(--text-primary);
}

.contest-joined {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  border-radius: var(--radius-md);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 15px;
  font-weight: 700;
}

.contest-joined svg {
  width: 17px;
  height: 17px;
}

.contest-card__note {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-muted);
}

/* Пэйвол Mini App: бот бесплатный, приложение по подписке */
.paywall {
  padding: 24px 18px 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.paywall__hero { text-align: center; }

.paywall__badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: linear-gradient(120deg, #2e55f2, #b04aff);
  color: #fff;
  margin-bottom: 10px;
}

.paywall__title {
  font-size: 28px;
  font-weight: 800;
  margin: 0 0 8px;
}

.paywall__lead {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

.paywall__features {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.paywall-feature {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--surface, #202022);
  border-radius: 14px;
  padding: 12px 14px;
}

.paywall-feature__emoji { font-size: 20px; line-height: 1.2; }

.paywall-feature__body { display: flex; flex-direction: column; gap: 2px; }

.paywall-feature__title { font-size: 14.5px; font-weight: 700; }

.paywall-feature__text {
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--text-muted);
}

.paywall__price {
  text-align: center;
  background: linear-gradient(150deg, rgba(46, 85, 242, 0.18), transparent);
  border: 1px solid rgba(46, 85, 242, 0.35);
  border-radius: 16px;
  padding: 18px 16px;
}

.paywall__price-value { font-size: 34px; font-weight: 800; }

.paywall__price-value span {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-muted);
}

.paywall__price-note {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text-muted);
}

.paywall__cta {
  width: 100%;
  justify-content: center;
  padding: 14px;
  font-size: 15px;
}

.paywall__footer {
  text-align: center;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text-muted);
  margin: 0;
}

/* Обложка живого альбома (16.09): картинка вместо буквы — без растяжения */
img.coll-hero__cover {
  object-fit: cover;
  display: block;
}

/* Третья кнопка «Добавить весь альбом» (16.09) не влезала в ряд на телефоне и
   уезжала за край — переносим её на всю ширину отдельной строкой. */
.coll-hero__actions {
  flex-wrap: wrap;
}

.coll-hero__actions [data-action="album-add-all"] {
  flex-basis: 100%;
}

/* Иконки в кнопках (16.09). У SVG из icons.js нет собственного размера, а общего
   правила не было — внутри .btn иконка растягивалась на всю ширину: огромные
   «▶ Слушать» и «Перемешать» на страницах плейлистов и альбомов, «+» поверх текста. */
.btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* --- screens.css --- */
/* ============ Profile screen ============ */

.profile-head {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 0 8px;
}

.profile-head span {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-secondary);
}

.profile-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 26px 0 8px;
}

.profile-hero__name {
  margin-top: 16px;
  font-size: 19px;
  font-weight: 800;
}

.profile-hero__status {
  margin-top: 5px;
  font-size: 12.5px;
  color: var(--text-secondary);
}

.profile-hero__status.is-premium {
  color: var(--text-accent);
  font-weight: 700;
}

.profile-card {
  margin-top: 22px;
  padding: 4px 4px;
}

/* ============ Library screen ============ */

.lib-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 4px 12px;
}

.lib-row .section-title {
  font-size: 14px;
}

/* ============ Home screen ============ */

.home-track-card {
  margin-top: 20px;
  padding: 8px;
}
