/* TeYho — дизайн «Обложка в комнате»
   Север: обложка играющего трека — главный герой, цвет интерфейса берётся с неё.
   Нейтрали тёплые и тёмные, акцент один (oklch L .82), подмешивается через --art-h / --art-c. */

@property --art-h { syntax: "<number>"; inherits: true; initial-value: 75; }
@property --art-c { syntax: "<number>"; inherits: true; initial-value: 0.12; }

:root {
  color-scheme: dark;
  --font: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;

  /* нейтрали: один тёплый оттенок (h 70), ступени светлоты по ролям */
  --bg: oklch(0.15 0.006 70);
  --surface: oklch(0.195 0.007 70);
  --raised: oklch(0.235 0.008 70);
  --raised-2: oklch(0.285 0.009 70);
  --text: oklch(0.965 0.004 80);
  --text-2: oklch(0.745 0.01 75);
  --text-3: oklch(0.64 0.01 75);
  --line: oklch(1 0 0 / 0.08);
  --line-2: oklch(1 0 0 / 0.14);
  --shade: oklch(0 0 0 / 0.5);

  /* акцент: цвет с обложки, светлота и насыщенность подобраны под контраст */
  --accent: oklch(0.82 var(--art-c) var(--art-h));
  --accent-soft: oklch(0.82 var(--art-c) var(--art-h) / 0.14);
  --accent-line: oklch(0.82 var(--art-c) var(--art-h) / 0.42);
  --on-accent: oklch(0.2 0.02 var(--art-h));
  --danger: oklch(0.74 0.14 22);

  /* радиусы: внешний = внутренний + отступ */
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;

  --ease: cubic-bezier(0.2, 0, 0, 1);
  --page: 1120px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 72px;
  --player-h: 96px;
}

@supports not (color: oklch(0 0 0)) {
  :root {
    --bg: #0d0b09; --surface: #171412; --raised: #211d1a; --raised-2: #302b27;
    --text: #f5f3f0; --text-2: #b0aca6; --text-3: #968f89;
    --line: rgba(255, 255, 255, 0.08); --line-2: rgba(255, 255, 255, 0.14); --shade: rgba(0, 0, 0, 0.5);
    --accent: #f2b966; --accent-soft: rgba(242, 185, 102, 0.14); --accent-line: rgba(242, 185, 102, 0.42);
    --on-accent: #1e1a14; --danger: #f08a82;
  }
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 400 0.9375rem/1.5 var(--font);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scrollbar-color: var(--raised-2) transparent;
}
::selection { background: var(--accent-soft); color: var(--text); }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: default; }
svg { display: block; flex: none; }
img { max-width: 100%; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
a { color: inherit; }

/* Свет комнаты: пятно цвета обложки за страницей */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto 0;
  height: 62vh;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(70% 90% at 50% 0%, oklch(0.5 var(--art-c) var(--art-h) / 0.2), transparent 72%);
}

/* ---------- Шапка: бренд, разделы, поиск ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto auto minmax(180px, 360px);
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: var(--header-h);
  padding: 12px max(var(--gutter), calc((100vw - var(--page)) / 2 + var(--gutter)));
  background: oklch(0.15 0.006 70 / 0.78);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  text-decoration: none;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.brand-mark { width: 26px; height: 26px; color: var(--accent); }
.source { display: none; }

/* Разделы: сегментный переключатель с ползунком, который переезжает к выбранному */
.tabs {
  position: relative;
  display: flex;
  gap: 2px;
  justify-self: start;
  max-width: 100%;
  padding: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--line);
  width: max-content;
}
.tabs::-webkit-scrollbar { display: none; }
.tab-thumb {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: var(--tw, 0);
  transform: translateX(var(--tx, 0));
  border-radius: 999px;
  background: var(--raised-2);
  box-shadow: 0 0 0 1px var(--line-2);
  opacity: 0;
  pointer-events: none;
}
.tabs[data-ready] .tab-thumb { opacity: 1; transition: transform 300ms var(--ease), width 300ms var(--ease), opacity 150ms; }
.tabs[data-none] .tab-thumb { opacity: 0; }
.tabs button {
  position: relative;
  min-height: 36px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-2);
  font-weight: 500;
  white-space: nowrap;
  transition: color 150ms;
}
.tabs button[aria-current="page"] { color: var(--text); }
@media (hover: hover) { .tabs button:hover { color: var(--text); } }

.search {
  position: relative;
  display: flex;
  align-items: center;
  height: 44px;
  padding-inline: 14px 5px;
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--line);
  transition: box-shadow 150ms, background-color 150ms;
}
.search:focus-within { background: var(--raised); box-shadow: 0 0 0 1.5px var(--accent); }
.search > svg { width: 18px; height: 18px; margin-inline-end: 10px; color: var(--text-3); }
.search input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 1rem; /* 16px: iOS не приближает страницу при фокусе */
}
.search input::placeholder { color: var(--text-3); }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; }
.search button[type="submit"] {
  height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: var(--raised-2);
  font-weight: 500;
  transition: background-color 150ms, scale 150ms var(--ease);
}
@media (hover: hover) { .search button[type="submit"]:hover { background: oklch(0.33 0.01 70); } }
.search button[type="submit"]:active { scale: 0.96; }

.suggest {
  position: absolute;
  top: calc(100% + 8px);
  inset-inline: 0;
  z-index: 30;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--raised);
  box-shadow: 0 0 0 1px var(--line-2), 0 18px 48px var(--shade);
}
.sg { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 8px 0 16px; cursor: pointer; }
.sg:hover, .sg.on { background: oklch(1 0 0 / 0.06); }
.sg-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sg-x { display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 999px; background: transparent; color: var(--text-3); }
.sg-x svg { width: 14px; height: 14px; }
@media (hover: hover) { .sg-x:hover { color: var(--text); background: oklch(1 0 0 / 0.08); } }
.sg-clear { display: block; width: 100%; min-height: 44px; padding: 0 16px; border: 0; border-top: 1px solid var(--line); background: transparent; color: var(--text-2); text-align: start; }

/* ---------- Каркас страницы ---------- */
.app {
  max-width: var(--page);
  margin-inline: auto;
  padding: 28px var(--gutter) calc(var(--player-h) + 56px);
}
#view { min-height: 40vh; }

/* Короткие сообщения: всплывают над плеером и сами исчезают */
.status {
  position: fixed;
  z-index: 25;
  inset-inline: 0;
  bottom: calc(var(--player-h) + 28px);
  width: max-content;
  max-width: min(520px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--raised-2);
  box-shadow: 0 0 0 1px var(--line-2), 0 12px 32px var(--shade);
  font-size: 0.875rem;
  text-align: center;
  pointer-events: none;
}
.status:empty { display: none; }
.status.error { color: var(--danger); box-shadow: 0 0 0 1px oklch(0.74 0.14 22 / 0.5), 0 12px 32px var(--shade); }

/* ---------- Заголовки, текст ---------- */
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.section-head h1, .profile h1, .hero h1 {
  margin: 0;
  font-size: clamp(1.75rem, 1.25rem + 2vw, 2.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  text-wrap: balance;
  overflow-wrap: anywhere;
}
.section-head span { color: var(--text-2); font-size: 0.875rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sec { margin-top: 44px; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.sec-head h2 { margin: 0; font-size: 1.25rem; font-weight: 650; line-height: 1.3; letter-spacing: -0.015em; }
.sec-head .note { font-size: 0.8125rem; }
.sec-head button { padding: 6px 4px; border: 0; background: none; color: var(--text-2); font-size: 0.875rem; }
@media (hover: hover) { .sec-head button:hover { color: var(--text); } }
.note { margin: 0; color: var(--text-2); text-wrap: pretty; }
.note.error { color: var(--danger); }
.link { cursor: pointer; }
@media (hover: hover) { .link:hover, .track-info [data-nav]:hover, .now-text [data-nav]:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; } }
[data-nav] { cursor: pointer; }
.eyebrow { color: var(--text-3); font-size: 0.8125rem; font-weight: 500; }

/* ---------- Кнопки и чипы ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 16px; }
.btn, .big-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px 0 16px;
  border: 0;
  border-radius: 999px;
  background: var(--raised);
  box-shadow: 0 0 0 1px var(--line-2);
  font-weight: 550;
  transition: background-color 150ms, scale 150ms var(--ease);
}
.btn svg { width: 16px; height: 16px; }
@media (hover: hover) { .btn:hover { background: var(--raised-2); } }
.btn:active, .big-btn:active, .chip:active { scale: 0.96; }
.big-btn { min-height: 52px; padding: 0 24px 0 20px; background: var(--accent); color: var(--on-accent); box-shadow: none; font-size: 1rem; font-weight: 650; }
.big-btn svg { width: 20px; height: 20px; }
@media (hover: hover) { .big-btn:hover { background: oklch(0.87 var(--art-c) var(--art-h)); } }
.back { margin-bottom: 20px; padding-inline: 12px 16px; }
.back svg { width: 18px; height: 18px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  background: var(--raised);
  box-shadow: 0 0 0 1px var(--line);
  color: var(--text-2);
  font-weight: 500;
  transition: background-color 150ms, color 150ms, box-shadow 150ms, scale 150ms var(--ease);
}
@media (hover: hover) { .chip:hover { background: var(--raised-2); color: var(--text); } }
.chip.on { background: var(--accent-soft); color: var(--accent); box-shadow: 0 0 0 1px var(--accent-line); }
.tag { display: inline-flex; align-items: center; min-height: 32px; padding: 0 12px; border-radius: 999px; background: var(--raised); box-shadow: 0 0 0 1px var(--line); font-size: 0.875rem; }

.icon-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-2);
  transition: color 150ms, background-color 150ms, opacity 150ms, scale 150ms var(--ease);
}
.icon-btn svg { width: 20px; height: 20px; }
@media (hover: hover) { .icon-btn:hover:not(:disabled) { color: var(--text); background: oklch(1 0 0 / 0.07); } }
.icon-btn:active:not(:disabled) { scale: 0.96; }
.icon-btn:disabled { opacity: 0.35; }
.heart svg { transition: fill 200ms; }
.heart.on { color: var(--accent); }
.heart.on svg { fill: currentColor; }

/* ---------- Обложки, карточки ---------- */
.cover {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  overflow: hidden;
  border-radius: var(--r-sm);
  background: var(--raised);
  color: var(--text-3);
}
.cover img { display: block; width: 100%; height: 100%; object-fit: cover; outline: 1px solid oklch(1 0 0 / 0.1); outline-offset: -1px; border-radius: inherit; }
.cover svg { width: 40%; height: 40%; }
.cover.big { width: 100%; height: auto; aspect-ratio: 1; border-radius: 12px; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(156px, 1fr)); gap: 8px; }
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  padding: 8px 8px 12px;
  border-radius: var(--r-lg); /* 12 (обложка) + 8 (отступ) */
  cursor: pointer;
  transition: background-color 200ms, scale 150ms var(--ease);
}
@media (hover: hover) { .card:hover { background: var(--surface); } }
.card:active { scale: 0.98; }
.card.active { background: var(--accent-soft); }
.card strong { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; margin-top: 10px; padding-inline: 4px; overflow: hidden; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.card > span:not(.card-art) { padding-inline: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); font-size: 0.8125rem; }
.card.active strong { color: var(--accent); }
.card-art { position: relative; display: block; }
.card-play {
  position: absolute;
  inset: auto 8px 8px auto;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: 0 8px 20px var(--shade);
  opacity: 0;
  translate: 0 8px;
  transition: opacity 200ms var(--ease), translate 200ms var(--ease);
}
.card-play svg { width: 18px; height: 18px; translate: 1px 0; }
@media (hover: hover) { .card:hover .card-play, .card:focus-visible .card-play { opacity: 1; translate: 0 0; } }

/* ---------- Списки треков ---------- */
.list-head, .track { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto 56px; align-items: center; gap: 12px; }
.list-head { padding: 0 12px 10px; border-bottom: 1px solid var(--line); color: var(--text-3); font-size: 0.8125rem; }
.list-head span:last-child { text-align: end; }
.results { display: flex; flex-direction: column; margin-top: 8px; }
.track {
  width: 100%;
  min-width: 0;
  padding: 6px 12px;
  border-radius: var(--r-md);
  cursor: pointer;
  text-align: start;
  transition: background-color 150ms;
}
@media (hover: hover) { .track:hover { background: oklch(1 0 0 / 0.065); } }
.track.active { background: var(--accent-soft); }
.track.active .track-info strong, .track.active .n { color: var(--accent); }
.idx { display: grid; place-items: center; height: 24px; color: var(--text-3); font-size: 0.875rem; font-variant-numeric: tabular-nums; }
.idx svg { width: 14px; height: 14px; color: var(--text); translate: 1px 0; }
.track .ic-play, .track .eq { display: none; }
@media (hover: hover) { .track:hover .n { display: none; } .track:hover .ic-play { display: block; } }
.track.playing .n, .track.playing .ic-play { display: none; }
.track.playing .eq { display: flex; }
.eq { align-items: flex-end; gap: 2px; height: 14px; }
.eq i { width: 3px; height: 100%; border-radius: 1px; background: var(--accent); transform-origin: bottom; animation: eq 1s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: -0.35s; }
.eq i:nth-child(3) { animation-delay: -0.7s; }
@keyframes eq { 0%, 100% { transform: scaleY(0.3); } 50% { transform: scaleY(1); } }
.t-main { display: flex; align-items: center; gap: 14px; min-width: 0; }
.track-info { display: flex; flex-direction: column; min-width: 0; }
.track-info strong, .track-info span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.track-info strong { font-weight: 600; }
.track-info span, .track-duration { color: var(--text-2); font-size: 0.8125rem; }
.track-duration { text-align: end; font-variant-numeric: tabular-nums; }
.row-actions { display: flex; gap: 0; }
.track .heart:not(.on), .track .add { opacity: 0; }
.track:hover .heart, .track:hover .add, .track:focus-within .heart, .track:focus-within .add { opacity: 1; }
@media (hover: none) { .track .heart, .track .add { opacity: 1; } }

.empty { padding: 24px; border-radius: var(--r-lg); background: var(--surface); box-shadow: 0 0 0 1px var(--line); }
.empty p { margin: 0 0 16px; color: var(--text-2); }

/* ---------- Главная ---------- */
.hero { max-width: 720px; padding: 28px 0 8px; }
.hero h1 { font-size: clamp(2.25rem, 1.4rem + 3.6vw, 3.75rem); }
.hero p { margin: 14px 0 28px; color: var(--text-2); font-size: 1.0625rem; line-height: 1.55; text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Исполнитель и альбом ---------- */
.profile { display: flex; align-items: flex-end; gap: clamp(16px, 3vw, 28px); margin-bottom: 28px; }
.profile .cover.big { width: clamp(112px, 22vw, 200px); flex: none; border-radius: var(--r-md); box-shadow: 0 18px 48px var(--shade); }
.profile > div { min-width: 0; }
.profile .note { margin-top: 10px; max-width: 60ch; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Моя волна ---------- */
.wave-console {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 8px clamp(20px, 4vw, 48px);
  align-items: center;
  margin-top: 4px;
  padding: clamp(18px, 3vw, 32px);
  overflow: hidden;
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--line);
}
.wave-console::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(60% 90% at 25% 50%, oklch(0.5 var(--art-c) var(--art-h) / 0.18), transparent 70%);
}
.wave-console-top { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wave-live, .wave-settings-label { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 0.8125rem; font-weight: 500; }
.wave-live i { width: 8px; height: 8px; border-radius: 999px; background: var(--text-3); }
.is-playing .wave-live { color: var(--accent); }
.is-playing .wave-live i { background: var(--accent); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; scale: 1; } 50% { opacity: 0.45; scale: 0.7; } }
.wave-profile-name { padding: 4px 12px; border-radius: 999px; background: var(--raised); box-shadow: 0 0 0 1px var(--line); font-size: 0.8125rem; font-weight: 500; }
.wave-visual { position: relative; grid-column: 1; grid-row: 2 / 5; min-height: 280px; display: grid; place-items: center; overflow: hidden; border-radius: var(--r-lg); }
.wave-oil-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.oil-halo { display: none; }
.wave-core { position: relative; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 999px; background: oklch(0.15 0.006 70 / 0.5); backdrop-filter: blur(10px); box-shadow: 0 0 0 1px var(--line-2); color: var(--text); }
.wave-core svg { width: 26px; height: 26px; }
.wave-console-copy { grid-column: 2; align-self: end; }
.wave-console-copy h2 { margin: 0 0 8px; font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2rem); font-weight: 700; line-height: 1.15; letter-spacing: -0.025em; text-wrap: balance; }
.wave-console-copy p { margin: 0; color: var(--text-2); text-wrap: pretty; }
.wave-active-settings { grid-column: 2; }
.wave-settings-label { margin-bottom: 10px; }
.wave-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.wave-pill { display: inline-flex; align-items: center; min-height: 30px; padding: 0 12px; border-radius: 999px; background: oklch(0.8 0.1 var(--h) / 0.14); color: oklch(0.86 0.09 var(--h)); box-shadow: inset 0 0 0 1px oklch(0.8 0.1 var(--h) / 0.3); font-size: 0.8125rem; font-weight: 550; }
.genre-pill { --h: 165; }
.mood-pill { --h: 355; }
.lang-pill { --h: 85; }
.novelty-pill { --h: 235; }
.wave-start { grid-column: 2; justify-self: start; margin-top: 8px; }

.profile-panel, .setting-panel, .learning-panel { padding: clamp(16px, 2.4vw, 24px); border-radius: var(--r-lg); background: var(--surface); box-shadow: 0 0 0 1px var(--line); }
.profile-panel { display: grid; grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.3fr); gap: 20px; align-items: center; --cat: 295; margin-bottom: 12px; }
.profile-panel h3, .setting-intro h3 { margin: 2px 0 4px; font-size: 1.0625rem; font-weight: 650; letter-spacing: -0.01em; }
.profile-panel p, .setting-intro p { margin: 0; color: var(--text-2); font-size: 0.875rem; text-wrap: pretty; }
.setting-panel { display: grid; gap: 18px; }
.setting-intro { display: flex; align-items: center; gap: 14px; }
.setting-icon { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: var(--r-md); background: oklch(0.8 0.1 var(--cat) / 0.16); color: oklch(0.86 0.1 var(--cat)); font-size: 1.125rem; }
.mood-panel { --cat: 355; }
.genre-panel { --cat: 165; }
.lang-panel { --cat: 85; }
.novelty-panel { --cat: 235; }
.profile-panel, .setting-panel { border-inline-start: 0; }
.sec:has(.setting-panel), .sec:has(.profile-panel) { margin-top: 28px; }
.setting-panel .chip.on, .profile-panel .chip.on { background: oklch(0.8 0.1 var(--cat) / 0.16); color: oklch(0.88 0.1 var(--cat)); box-shadow: 0 0 0 1px oklch(0.8 0.1 var(--cat) / 0.45); }
.learning-panel { display: grid; gap: 14px; }

/* ---------- Плеер: плавающий остров ---------- */
.player {
  position: fixed;
  z-index: 15;
  inset: auto max(12px, calc((100vw - var(--page)) / 2)) 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 1.5fr) minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  min-height: var(--player-h);
  padding: 10px 16px 10px 10px; /* 14 (обложка) + 10 = 24 */
  border: 1px solid transparent;
  border-radius: 24px;
  background: oklch(0.2 0.007 70 / 0.82);
  backdrop-filter: blur(28px) saturate(1.5);
  -webkit-backdrop-filter: blur(28px) saturate(1.5);
  box-shadow: 0 0 0 1px var(--line-2), 0 20px 56px var(--shade);
}
.now { display: flex; align-items: center; gap: 12px; min-width: 0; }
.now-cover { width: 60px; height: 60px; border-radius: 14px; }
.now-cover img:not([src]) { visibility: hidden; }
.now-cover.empty::after { content: ""; position: absolute; width: 24px; height: 24px; background: currentColor; -webkit-mask: var(--note) center / contain no-repeat; mask: var(--note) center / contain no-repeat; }
:root { --note: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18V5.5l10-2V16'/%3E%3Ccircle cx='6.5' cy='18' r='2.5'/%3E%3Ccircle cx='16.5' cy='16' r='2.5'/%3E%3C/svg%3E"); }
.now-text { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.now-text strong, .now-text span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.now-text strong { font-weight: 600; }
.now-text span { color: var(--text-2); font-size: 0.8125rem; }
#now-album:empty, .player:not(.fs) #now-album { display: none; }
.now-actions { display: flex; flex: none; }

.center { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.controls { display: flex; align-items: center; gap: 4px; }
.ctrl { position: relative; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--text); transition: color 150ms, background-color 150ms, scale 150ms var(--ease), opacity 150ms; }
.ctrl svg { width: 20px; height: 20px; }
@media (hover: hover) { .ctrl:hover:not(:disabled) { background: oklch(1 0 0 / 0.07); } }
.ctrl:active:not(:disabled) { scale: 0.96; }
.ctrl:disabled { opacity: 0.35; }
.mode { color: var(--text-2); }
.mode.on { color: var(--accent); }
.mode.on::after { content: ""; position: absolute; bottom: 5px; left: 50%; width: 4px; height: 4px; margin-left: -2px; border-radius: 999px; background: currentColor; }
#repeat[data-mode="one"]::before { content: "1"; position: absolute; top: 6px; right: 7px; font-size: 0.625rem; font-weight: 700; line-height: 1; color: var(--accent); }

.play { position: relative; display: grid; place-items: center; width: 52px; height: 52px; padding: 0; border: 0; border-radius: 999px; background: var(--text); color: var(--bg); transition: background-color 150ms, scale 150ms var(--ease), opacity 150ms; }
.play .ic { position: absolute; inset: 0; display: grid; place-items: center; transition: opacity 300ms var(--ease), scale 300ms var(--ease), filter 300ms var(--ease); }
.play .ic svg { width: 22px; height: 22px; }
.play .ic-play svg { translate: 1.5px 0; } /* оптический центр треугольника */
.play:not(.is-playing) .ic-pause, .play.is-playing .ic-play { opacity: 0; scale: 0.25; filter: blur(4px); }
@media (hover: hover) { .play:hover:not(:disabled) { background: var(--accent); color: var(--on-accent); } }
.play:active:not(:disabled) { scale: 0.96; }
.play:disabled { opacity: 0.35; }

.progress-row { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; align-items: center; gap: 8px; width: 100%; color: var(--text-2); font-size: 0.75rem; font-variant-numeric: tabular-nums; }
.progress-row span:last-child { text-align: end; }
.volume { display: flex; align-items: center; justify-content: flex-end; gap: 8px; color: var(--text-2); }
.volume > svg { width: 20px; height: 20px; }
.volume input { width: 112px; }
.player-error { grid-column: 1 / -1; padding-inline: 8px; color: var(--danger); font-size: 0.8125rem; }
.player-error:empty { display: none; }
audio { display: none; }

/* Ползунки */
input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 20px; margin: 0; background: transparent; cursor: pointer; }
input[type="range"]:disabled { opacity: 0.4; cursor: default; }
input[type="range"]::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--accent) var(--p, 0%), oklch(1 0 0 / 0.16) var(--p, 0%)); }
input[type="range"]::-moz-range-track { height: 4px; border-radius: 2px; background: oklch(1 0 0 / 0.16); }
input[type="range"]::-moz-range-progress { height: 4px; border-radius: 2px; background: var(--accent); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; margin-top: -4px; border: 0; border-radius: 999px; background: var(--text); box-shadow: 0 2px 6px var(--shade); transform: scale(0); transition: transform 150ms var(--ease); }
input[type="range"]::-moz-range-thumb { width: 12px; height: 12px; border: 0; border-radius: 999px; background: var(--text); box-shadow: 0 2px 6px var(--shade); transform: scale(0); transition: transform 150ms var(--ease); }
@media (hover: hover) { input[type="range"]:hover::-webkit-slider-thumb { transform: scale(1); } input[type="range"]:hover::-moz-range-thumb { transform: scale(1); } }
input[type="range"]:focus-visible::-webkit-slider-thumb { transform: scale(1); }
input[type="range"]:focus-visible::-moz-range-thumb { transform: scale(1); }
@media (pointer: coarse) { input[type="range"]::-webkit-slider-thumb { transform: scale(1); } input[type="range"]::-moz-range-thumb { transform: scale(1); } }

/* ---------- «Сейчас играет» на весь экран ---------- */
body.fs-lock { overflow: hidden; }
.fs-close { position: absolute; top: max(16px, env(safe-area-inset-top)); inset-inline-end: 16px; z-index: 2; background: oklch(1 0 0 / 0.08); }
.player.fs {
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  min-height: 0;
  padding: max(24px, env(safe-area-inset-top)) 24px max(24px, env(safe-area-inset-bottom));
  overflow: hidden;
  overscroll-behavior: none;
  scrollbar-width: none;
  border-radius: 0;
  background: var(--bg);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  isolation: isolate;
}
.player.fs::before {
  content: "";
  position: fixed;
  inset: -10%;
  z-index: -1;
  background: var(--cover, none) center / cover no-repeat;
  filter: blur(70px) saturate(1.5) brightness(0.55);
  opacity: 0.9;
}
.player.fs::after { content: ""; position: fixed; inset: 0; z-index: -1; background: linear-gradient(oklch(0.15 0.006 70 / 0.35), oklch(0.15 0.006 70 / 0.75)); }
.player.fs .now { flex-direction: column; gap: 22px; width: 100%; max-width: 440px; text-align: center; }
.player.fs .now-cover { width: min(80vw, 46vh, 400px); height: min(80vw, 46vh, 400px); border-radius: var(--r-xl); box-shadow: 0 30px 80px var(--shade); }
.player.fs .now-text { align-items: center; width: 100%; }
.player.fs .now-text strong { font-size: clamp(1.375rem, 1rem + 1.6vw, 1.875rem); font-weight: 700; line-height: 1.2; letter-spacing: -0.02em; white-space: normal; text-wrap: balance; }
.player.fs .now-text span { font-size: 1rem; white-space: normal; }
.player.fs .center, .player.fs .player-error { width: 100%; max-width: 440px; }
.player.fs .center { gap: 10px; }
.player.fs .progress-row { font-size: 0.8125rem; }
.player.fs .play { width: 68px; height: 68px; }
.player.fs .play .ic svg { width: 28px; height: 28px; }
.player.fs .volume { justify-content: center; }
.player.fs #fs-open { display: none; }

/* ---------- Движение ---------- */
@media (prefers-reduced-motion: no-preference) {
  #view.enter > * { animation: enter 300ms var(--ease) both; animation-delay: calc(var(--i, 0) * 80ms); }
  @keyframes enter { from { opacity: 0; translate: 0 12px; filter: blur(4px); } to { opacity: 1; translate: 0 0; filter: blur(0); } }
  .status:not(:empty) { animation: toast 250ms var(--ease) both; }
  @keyframes toast { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }
  .player.fs { animation: fs-in 300ms var(--ease) both; }
  @keyframes fs-in { from { opacity: 0; scale: 0.985; } to { opacity: 1; scale: 1; } }
  :root { transition: --art-h 700ms ease, --art-c 700ms ease; }
}
@media (prefers-reduced-motion: reduce) {
  .eq i { animation: none; transform: scaleY(0.7); }
  .is-playing .wave-live i { animation: none; }
  .tabs[data-ready] .tab-thumb { transition: none; }
}
@media (forced-colors: active) {
  .player, .suggest, .status, .chip, .btn { border: 1px solid CanvasText; }
}

/* ---------- Узкие экраны ---------- */
@media (max-width: 1040px) {
  .top { grid-template-columns: auto minmax(0, 1fr); row-gap: 10px; padding-block: 10px; }
  .search { grid-column: 2; grid-row: 1; }
  .tabs { grid-column: 1 / -1; grid-row: 2; justify-self: stretch; width: auto; }
  .player { grid-template-columns: minmax(0, 1fr) minmax(260px, 1.4fr) auto; }
  .volume input, .volume > svg { display: none; }
  :root { --header-h: 118px; }
  .wave-console { grid-template-columns: 1fr; }
  .wave-visual, .wave-console-copy, .wave-active-settings, .wave-start { grid-column: 1; grid-row: auto; }
  .wave-visual { min-height: 240px; }
  .profile-panel { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  :root { --player-h: 128px; --header-h: 112px; }
  .tabs { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); padding-inline-end: 24px; }
  .top { gap: 8px 12px; }
  .brand span { display: none; }
  .app { padding-top: 20px; }
  .sec { margin-top: 36px; }
  .cards { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); }
  .list-head, .track { grid-template-columns: 28px minmax(0, 1fr) auto 44px; gap: 8px; }
  .track { padding-inline: 8px; }
  .row-actions .add { display: none; }
  .player { inset: auto 8px calc(8px + env(safe-area-inset-bottom)); grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "now ctrl" "prog prog"; gap: 4px 8px; padding: 8px 8px 6px; }
  .now { grid-area: now; }
  .now-cover { width: 48px; height: 48px; border-radius: 12px; }
  .now-actions .icon-btn:not(.heart) { display: none; }
  .center { display: contents; }
  .controls { grid-area: ctrl; }
  .controls .mode, #prev { display: none; }
  .progress-row { grid-area: prog; grid-template-columns: 36px minmax(0, 1fr) 36px; padding-inline: 4px; }
  .volume { display: none; }
  .player-error { grid-area: auto; }
  .status { bottom: calc(var(--player-h) + 20px); }
  /* на весь экран на телефоне показываем все кнопки */
  .player.fs { display: flex; padding-inline: 20px; }
  .player.fs .center { display: flex; }
  .player.fs .controls .mode, .player.fs #prev { display: grid; }
  .player.fs .now-actions .icon-btn:not(.heart) { display: grid; }
  .player.fs .volume { display: flex; }
  .player.fs .volume > svg, .player.fs .volume input { display: block; }
  .player.fs .volume #queue-btn { display: grid; }
  .profile { flex-direction: column; align-items: flex-start; }
  .profile .cover.big { width: 140px; }
}

@media (pointer: coarse) {
  .chip { min-height: 44px; }
  .tabs button { min-height: 40px; }
}

/* ---------- Субтитры-караоке ---------- */
.icon-btn.on:not(.heart) { color: var(--accent); }
.icon-btn.on:not(.heart)::after { content: ""; position: absolute; bottom: 6px; left: 50%; width: 4px; height: 4px; margin-left: -2px; border-radius: 999px; background: currentColor; }

/* Строка-субтитр над плеером */
.caption {
  position: fixed;
  z-index: 14;
  left: 50%;
  bottom: calc(var(--player-h) + 28px);
  translate: -50% 0;
  width: max-content;
  max-width: min(760px, calc(100vw - 24px));
  padding: 12px 22px 14px;
  border-radius: var(--r-lg);
  background: oklch(0.2 0.007 70 / 0.82);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  box-shadow: 0 0 0 1px var(--line-2), 0 14px 40px var(--shade);
  text-align: center;
  pointer-events: none;
}
.cap-cur { margin: 0; font-size: clamp(1.125rem, 1rem + 0.6vw, 1.5rem); font-weight: 700; line-height: 1.3; letter-spacing: -0.015em; text-wrap: balance; }
.cap-next { margin: 4px 0 0; overflow: hidden; color: var(--text-3); font-size: 0.9375rem; text-overflow: ellipsis; white-space: nowrap; }
.cap-next:empty { display: none; }
body.has-caption .status { bottom: calc(var(--player-h) + 128px); }
body.fs-lock .caption { display: none; }

/* Подсветка спетой части строки: градиент идёт вдоль текста и переходит на следующую строку переноса */
.cap-cur .t, .ly.on .t {
  background: linear-gradient(90deg, var(--accent) var(--fill, 0%), oklch(1 0 0 / 0.72) var(--fill, 0%));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

/* Панель текста в полноэкранном режиме */
.lyrics { display: none; position: relative; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; text-align: start; -webkit-mask-image: linear-gradient(transparent, #000 14%, #000 86%, transparent); mask-image: linear-gradient(transparent, #000 14%, #000 86%, transparent); }
.lyrics::-webkit-scrollbar { display: none; }
.player.fs.lyrics-on .lyrics { display: block; }
.ly { display: block; width: 100%; padding: 8px 4px; border: 0; background: transparent; color: var(--text-3); font-size: clamp(1.25rem, 1rem + 1.4vw, 1.875rem); font-weight: 700; line-height: 1.25; letter-spacing: -0.02em; text-align: start; text-wrap: balance; cursor: pointer; transition: color 300ms var(--ease); }
.ly .t { display: inline; }
.ly:not(.on):not(.past) { color: var(--text-2); }
@media (hover: hover) { .ly:not(.on):hover { color: var(--text); } }
.ly.gap { font-size: 1rem; letter-spacing: 0.3em; }
.ly-pad { height: 42%; }
.ly-note, .ly-credit { margin: 0; color: var(--text-2); font-size: 0.9375rem; }
.ly-note { padding: 24px 4px; font-size: 1.125rem; }
.ly-credit { padding: 12px 4px 4px; color: var(--text-3); font-size: 0.8125rem; }
.ly-plain { padding: 24px 4px 8px; color: var(--text-2); font-size: 1.125rem; line-height: 1.7; white-space: pre-line; }
.player.fs .volume .icon-btn { display: grid; }
.player.fs .volume input, .player.fs .volume > svg { display: block; }

@media (min-width: 900px) {
  .player.fs.lyrics-on {
    display: grid;
    grid-template-columns: minmax(280px, 400px) minmax(0, 560px);
    grid-template-areas: "now lyrics" "center lyrics" "volume lyrics";
    grid-template-rows: auto auto auto;
    justify-content: center;
    align-content: center;
    column-gap: clamp(32px, 6vw, 96px);
    row-gap: 22px;
  }
  .player.fs.lyrics-on .now { grid-area: now; max-width: none; }
  .player.fs.lyrics-on .now-cover { width: min(26vw, 36vh, 340px); height: min(26vw, 36vh, 340px); }
  .player.fs.lyrics-on .center { grid-area: center; max-width: none; }
  .player.fs.lyrics-on .volume { grid-area: volume; }
  .player.fs.lyrics-on .lyrics { grid-area: lyrics; height: min(74vh, 680px); align-self: center; }
}
@media (max-width: 899px) {
  .player.fs.lyrics-on { justify-content: flex-start; gap: 12px; }
  .player.fs.lyrics-on .now { flex-direction: row; flex-wrap: wrap; gap: 14px; text-align: start; max-width: 520px; padding-inline-end: 52px; }
  .player.fs.lyrics-on .now-cover { width: 76px; height: 76px; border-radius: 16px; }
  .player.fs.lyrics-on .now-text { align-items: flex-start; flex: 1; width: auto; min-width: 0; }
  .player.fs.lyrics-on .now-text strong { font-size: 1.125rem; }
  .player.fs.lyrics-on .now-actions { margin-inline-start: auto; }
  .player.fs.lyrics-on .lyrics { flex: 1 1 0; min-height: 120px; width: 100%; max-width: 520px; }
  .player.fs.lyrics-on .center { gap: 4px; }
  .player.fs.lyrics-on .play { width: 56px; height: 56px; }
}
@media (max-width: 720px) {
  .caption { bottom: calc(var(--player-h) + 20px); padding: 10px 16px 12px; }
  body.has-caption .status { bottom: calc(var(--player-h) + 112px); }
}

.caption.note { padding: 10px 18px; }
.caption.note .cap-cur { font-size: 0.9375rem; font-weight: 550; letter-spacing: 0; }
.caption.note .cap-cur .t { background: none; color: var(--text-2); -webkit-text-fill-color: currentColor; }

@media (max-width: 899px) {
  /* на телефоне текст идёт сразу под обложкой, кнопки управления внизу, ползунок громкости не нужен */
  .player.fs.lyrics-on .now { order: 0; }
  .player.fs.lyrics-on .lyrics { order: 1; }
  .player.fs.lyrics-on .center { order: 2; }
  .player.fs.lyrics-on .volume { order: 3; }
  .player.fs.lyrics-on .player-error { order: 4; }
  .player.fs.lyrics-on .volume input, .player.fs.lyrics-on .volume > svg { display: none; }
}

/* ---------- Аккаунты TeYho ---------- */
.auth-screen[hidden], .account-button[hidden] { display: none !important; }
html.auth-pending body > :not(#auth-screen) { visibility: hidden; }
.auth-screen { position: fixed; inset: 0; z-index: 10000; display: grid; place-items: center; overflow-y: auto; padding: 24px; background: radial-gradient(ellipse at 50% 0%, rgba(156, 91, 44, .18), transparent 55%), #0d0b09; }
.auth-card { width: min(100%, 420px); padding: clamp(24px, 5vw, 42px); border: 1px solid rgba(255,255,255,.09); border-radius: 24px; background: rgba(23,20,17,.96); box-shadow: 0 28px 100px rgba(0,0,0,.42); }
.auth-brand { display: inline-block; color: var(--text, #f5eee7); font-size: 1.8rem; font-weight: 750; letter-spacing: -.07em; text-decoration: none; }
.auth-kicker { margin: 22px 0 8px; color: #c58a55; font-size: .68rem; font-weight: 750; letter-spacing: .16em; }
.auth-card h1 { margin: 0; color: #f7f1eb; font-size: clamp(1.7rem, 5vw, 2.1rem); letter-spacing: -.045em; }
.auth-subtitle { margin: 10px 0 26px; color: #a9a097; line-height: 1.5; font-size: .92rem; }
#auth-form { display: grid; gap: 9px; }
#auth-form label { margin-top: 5px; color: #d9d0c7; font-size: .82rem; font-weight: 600; }
#auth-form input { width: 100%; min-width: 0; padding: 13px 14px; border: 1px solid #39312a; border-radius: 11px; outline: none; color: #f5eee7; background: #100e0c; font: inherit; }
#auth-form input:focus { border-color: #b87943; box-shadow: 0 0 0 3px rgba(184,121,67,.12); }
.auth-submit { margin-top: 9px; padding: 13px 16px; border: 0; border-radius: 11px; color: #1a110a; background: linear-gradient(135deg, #e0ad78, #b87840); font: inherit; font-weight: 750; cursor: pointer; }
.auth-submit:disabled { opacity: .65; cursor: wait; }
.auth-error { min-height: 1.2em; margin: 2px 0 0; color: #ff9a8c; font-size: .82rem; }
.auth-switch { margin: 20px 0 0; color: #aaa097; text-align: center; font-size: .85rem; }
.auth-switch button { padding: 0; border: 0; color: #e1ad79; background: none; font: inherit; font-weight: 700; cursor: pointer; }
.auth-footnote { margin: 18px 0 0; color: #70675e; font-size: .72rem; line-height: 1.45; text-align: center; }
.account-button { position: fixed; z-index: 1001; top: 14px; right: 14px; left: auto; width: 42px; height: 42px; display: grid; place-items: center; padding: 9px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; color: var(--text, #f5eee7); background: #211b16; cursor: pointer; box-shadow: 0 4px 18px rgba(0,0,0,.18); }
.account-button svg { display:block; width:22px; height:22px; }
@media (max-width: 720px) { .auth-screen { padding: 16px; } .auth-card { border-radius: 20px; } .account-button { top: 10px; right: 10px; left: auto; } }


/* Профиль и аналитика аккаунта */
.account-button { transition: opacity .15s ease; }
body.fs-lock .account-button { display: none !important; }
body.fs-lock, body.fs-lock html { overflow: hidden !important; }
body.fs-lock .player.fs { width: 100vw; height: 100dvh; max-height: 100dvh; box-sizing: border-box; }
body.fs-lock .player.fs::-webkit-scrollbar, body.fs-lock *::-webkit-scrollbar { width: 0 !important; height: 0 !important; display: none !important; }
.account-hero { display:flex; align-items:center; gap:18px; padding:22px; margin:18px 0 22px; border:1px solid var(--line,rgba(255,255,255,.1)); border-radius:22px; background:linear-gradient(120deg,rgba(185,119,64,.14),rgba(255,255,255,.025)); }
.account-avatar { flex:0 0 62px; width:62px; height:62px; display:grid; place-items:center; border-radius:20px; background:linear-gradient(135deg,#d6a16d,#80502d); color:#17100a; font-size:1.7rem; font-weight:800; }
.account-identity { min-width:0; flex:1; }
.account-identity h2 { margin:4px 0; font-size:1.55rem; overflow-wrap:anywhere; }
.account-identity p { margin:0; color:var(--text-2); font-size:.85rem; }
.analytics-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin:18px 0 26px; }
.analytics-stat { min-width:0; padding:18px; border:1px solid var(--line,rgba(255,255,255,.09)); border-radius:17px; background:var(--surface,rgba(255,255,255,.025)); }
.analytics-stat span,.analytics-stat small { display:block; color:var(--text-2); font-size:.8rem; }
.analytics-stat strong { display:block; margin:10px 0 5px; font-size:clamp(1.45rem,3vw,2rem); letter-spacing:-.04em; overflow-wrap:anywhere; }
.analytics-stat small { color:var(--text-3); font-size:.72rem; }
.analytics-panel { display:grid; gap:22px; padding:22px; border:1px solid var(--line,rgba(255,255,255,.09)); border-radius:18px; }
.analytics-panel h3 { margin:5px 0; }
.analytics-panel p { margin:4px 0; color:var(--text-2); }
.preference-block > b { display:block; margin-bottom:10px; }
.preference-pairs { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.preference-pairs div { display:grid; gap:7px; padding:13px; border-radius:12px; background:rgba(255,255,255,.035); }
.preference-pairs span { color:var(--text-2); font-size:.78rem; }
.preference-pairs b { font-size:.9rem; }
.analytics-artists { display:grid; gap:8px; }
.analytics-artist { display:flex; align-items:center; gap:12px; padding:12px 14px; border-radius:12px; background:rgba(255,255,255,.03); }
.analytics-artist > span:nth-child(2) { flex:1; min-width:0; overflow-wrap:anywhere; }
.analytics-artist b { color:var(--text-2); font-size:.78rem; font-weight:500; text-align:right; }
.analytics-rank { display:grid; place-items:center; width:28px; height:28px; border-radius:9px; background:rgba(190,130,78,.14); color:#d8a574; font-weight:700; }
.analytics-grid-small { grid-template-columns:repeat(3,minmax(0,1fr)); margin:0; }
.analytics-disclaimer { color:var(--text-3); font-size:.76rem; line-height:1.5; }
@media(max-width:850px) { .analytics-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } .account-hero { flex-wrap:wrap; } .account-hero .btn { margin-left:80px; } }
@media(max-width:520px) { .account-hero { padding:16px; gap:12px; } .account-avatar { width:48px; height:48px; flex-basis:48px; border-radius:15px; } .account-identity h2 { font-size:1.25rem; } .account-hero .btn { margin-left:0; width:100%; } .analytics-stat { padding:14px; } .analytics-stat span { font-size:.75rem; } .preference-pairs { grid-template-columns:1fr; } .analytics-artist { align-items:flex-start; flex-wrap:wrap; } .analytics-artist b { margin-left:40px; text-align:left; } }

.account-actions { display:flex; align-items:center; gap:8px; margin-left:auto; flex-wrap:wrap; }
.account-logout { border-color:rgba(255,120,100,.25); color:#ffb3a7; }
@media(max-width:850px){.account-actions{margin-left:80px}}
@media(max-width:520px){.account-actions{margin-left:0;width:100%}.account-actions .btn{flex:1}}
