:root {
    color-scheme: dark;
    --bg: #080a0e;
    --bg-soft: #0d1016;
    --panel: #11151d;
    --panel-2: #151b24;
    --panel-3: #1b222d;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.14);
    --text: #f4f7f4;
    --muted: #8e99a8;
    --muted-2: #626d7b;
    --accent: #c9ff4a;
    --accent-strong: #b6ee36;
    --accent-ink: #0a0d08;
    --danger: #ff6b7a;
    --warning: #ffc857;
    --radius-xl: 26px;
    --radius-lg: 18px;
    --radius-md: 13px;
    --sidebar: 250px;
    --topbar: 72px;
    --player: 94px;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

html {
    min-height: 100%;
    background: var(--bg);
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 84% -10%, rgba(201, 255, 74, 0.08), transparent 33rem),
        radial-gradient(circle at 10% 110%, rgba(72, 118, 255, 0.07), transparent 30rem),
        var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

body.queue-open {
    overflow: hidden;
}

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

button,
input,
select,
textarea {
    font: inherit;
}

button {
    color: inherit;
}

svg {
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
}

img {
    display: block;
    max-width: 100%;
}

::selection {
    color: var(--accent-ink);
    background: var(--accent);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #2a333f;
    border: 2px solid var(--bg);
    border-radius: 999px;
}

.icon-sprite {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

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

.eyebrow {
    display: block;
    color: var(--accent);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.16em;
    line-height: 1.3;
    text-transform: uppercase;
}

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

h1 {
    font-size: clamp(38px, 5vw, 64px);
    font-weight: 700;
    letter-spacing: -0.045em;
    line-height: 0.98;
}

h2 {
    font-size: clamp(22px, 2.3vw, 30px);
    font-weight: 680;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.app {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    z-index: 60;
    inset: 0 auto 0 0;
    display: flex;
    flex-direction: column;
    width: var(--sidebar);
    padding: 24px 16px 18px;
    background: rgba(10, 13, 18, 0.94);
    border-right: 1px solid var(--line);
    backdrop-filter: blur(22px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 3px 10px;
    margin-bottom: 28px;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: var(--accent-ink);
    background: var(--accent);
    border-radius: 13px;
    box-shadow: 0 8px 28px rgba(201, 255, 74, 0.18);
}

.brand-mark svg {
    width: 26px;
    height: 26px;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-copy strong {
    font-size: 22px;
    letter-spacing: -0.045em;
}

.brand-copy small {
    margin-top: 4px;
    color: var(--muted);
    font-size: 10px;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.brand-large .brand-mark {
    width: 52px;
    height: 52px;
    border-radius: 16px;
}

.brand-large .brand-copy strong {
    font-size: 30px;
}

.main-nav {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 3px;
}

.nav-label {
    padding: 0 12px 9px;
    color: var(--muted-2);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.nav-label-spaced {
    margin-top: 24px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 0 12px;
    color: #b6c0cc;
    border: 1px solid transparent;
    border-radius: 12px;
    font-weight: 520;
    transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.nav-link svg {
    width: 19px;
    height: 19px;
    color: #778391;
}

.nav-link:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.045);
}

.nav-link.is-active {
    color: var(--text);
    background: linear-gradient(90deg, rgba(201, 255, 74, 0.13), rgba(201, 255, 74, 0.035));
    border-color: rgba(201, 255, 74, 0.16);
}

.nav-link.is-active svg {
    color: var(--accent);
}

.nav-badge {
    min-width: 23px;
    margin-left: auto;
    padding: 2px 6px;
    color: var(--accent-ink);
    background: var(--accent);
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    text-align: center;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 14px 8px 2px;
    border-top: 1px solid var(--line);
}

.avatar {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    color: var(--accent);
    background: #1a221c;
    border: 1px solid rgba(201, 255, 74, 0.22);
    border-radius: 50%;
    font-size: 14px;
    font-weight: 800;
}

.sidebar-user-copy {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
}

.sidebar-user-copy strong {
    overflow: hidden;
    font-size: 13px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-user-copy small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
    font-size: 11px;
}

.status-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: var(--danger);
    border-radius: 50%;
}

.status-dot.online {
    background: var(--accent);
    box-shadow: 0 0 9px rgba(201, 255, 74, 0.65);
}

.sidebar-scrim {
    display: none;
}

.workspace {
    min-height: 100vh;
    margin-left: var(--sidebar);
}

.topbar {
    position: sticky;
    z-index: 40;
    top: 0;
    display: flex;
    align-items: center;
    gap: 18px;
    height: var(--topbar);
    padding: 0 32px;
    background: rgba(8, 10, 14, 0.78);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(20px);
}

.menu-button {
    display: none;
}

.global-search {
    display: flex;
    align-items: center;
    gap: 10px;
    width: min(520px, 48vw);
    height: 42px;
    padding: 0 14px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.042);
    border: 1px solid var(--line);
    border-radius: 12px;
    transition: border-color 160ms ease, background 160ms ease;
}

.global-search:focus-within {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(201, 255, 74, 0.4);
}

.global-search svg {
    width: 18px;
    height: 18px;
}

.global-search input {
    flex: 1;
    min-width: 0;
    color: var(--text);
    background: transparent;
    border: 0;
    outline: 0;
}

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

.global-search kbd {
    padding: 1px 6px;
    color: var(--muted-2);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--line);
    border-radius: 5px;
    font-family: inherit;
    font-size: 11px;
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-left: auto;
}

.user-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
}

.content {
    width: min(1500px, 100%);
    padding: 32px;
    margin: 0 auto;
    animation: content-in 380ms ease both;
}

.content-spacer {
    height: calc(var(--player) + 28px);
}

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

.flash-stack {
    display: grid;
    gap: 8px;
    padding: 14px 32px 0;
}

.flash {
    padding: 12px 15px;
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--line-strong);
    border-radius: 12px;
    font-size: 13px;
}

.flash-success {
    color: #dfffb0;
    background: rgba(142, 196, 46, 0.12);
    border-color: rgba(201, 255, 74, 0.22);
}

.flash-error {
    color: #ffd3d8;
    background: rgba(255, 107, 122, 0.11);
    border-color: rgba(255, 107, 122, 0.24);
}

.flash-warning {
    color: #ffe9b3;
    background: rgba(255, 200, 87, 0.1);
    border-color: rgba(255, 200, 87, 0.22);
}

.connection-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 32px 0;
    padding: 12px 15px;
    color: #ffe9b3;
    background: rgba(255, 200, 87, 0.08);
    border: 1px solid rgba(255, 200, 87, 0.23);
    border-radius: 12px;
    font-size: 13px;
}

.connection-banner svg {
    width: 18px;
    height: 18px;
}

.connection-banner span {
    flex: 1;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 44px;
    padding: 0 18px;
    color: var(--text);
    background: var(--panel-3);
    border: 1px solid var(--line);
    border-radius: 12px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 650;
    white-space: nowrap;
    transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.button:hover {
    transform: translateY(-1px);
    background: #242d39;
    border-color: var(--line-strong);
}

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

.button-primary {
    color: var(--accent-ink);
    background: var(--accent);
    border-color: var(--accent);
}

.button-primary:hover {
    background: var(--accent-strong);
    border-color: var(--accent-strong);
}

.button-ghost {
    color: #c9d0d8;
    background: rgba(255, 255, 255, 0.035);
    border-color: var(--line);
}

.button-small {
    min-height: 34px;
    padding: 0 12px;
    font-size: 12px;
}

.button.is-loading {
    opacity: 0.65;
    pointer-events: none;
}

.icon-button {
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    padding: 0;
    color: #c2cbd5;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 50%;
    cursor: pointer;
    transition: color 150ms ease, background 150ms ease, border-color 150ms ease;
}

.icon-button:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.07);
}

.icon-button.subtle {
    color: var(--muted);
}

.icon-button.subtle:hover {
    color: var(--text);
}

.icon-button:disabled {
    opacity: 0.25;
    pointer-events: none;
}

.text-button {
    padding: 4px;
    color: var(--muted);
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
}

.text-button:hover {
    color: var(--text);
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

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

.text-link svg {
    width: 16px;
    height: 16px;
}

.page-hero {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
    min-height: 250px;
    padding: 38px;
    overflow: hidden;
    background:
        radial-gradient(circle at 90% 0%, rgba(201, 255, 74, 0.16), transparent 22rem),
        linear-gradient(125deg, #151b23, #0e1219 70%);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

.page-hero::after {
    position: absolute;
    top: -55%;
    right: 8%;
    width: 260px;
    height: 260px;
    background: var(--accent);
    border-radius: 50%;
    filter: blur(110px);
    opacity: 0.12;
    content: "";
    pointer-events: none;
}

.page-hero-copy {
    position: relative;
    z-index: 1;
    max-width: 700px;
}

.page-hero-copy h1 {
    margin-top: 12px;
}

.page-hero-copy p {
    max-width: 620px;
    margin-top: 18px;
    color: var(--muted);
    font-size: 15px;
}

.home-hero {
    min-height: 300px;
}

.home-hero .page-hero-copy h1 {
    font-size: clamp(48px, 7vw, 86px);
}

.slim-hero {
    min-height: 180px;
}

.slim-hero .page-hero-copy h1 {
    font-size: clamp(38px, 5vw, 58px);
}

.stat-strip {
    display: flex;
    gap: 8px;
    flex: 0 0 auto;
    align-self: flex-end;
}

.stat {
    display: flex;
    flex-direction: column;
    min-width: 112px;
    padding: 15px 17px;
    background: rgba(8, 10, 14, 0.5);
    border: 1px solid var(--line);
    border-radius: 15px;
    backdrop-filter: blur(10px);
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.15;
}

.stat-label {
    margin-top: 4px;
    color: var(--muted);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.section-block {
    margin-top: 42px;
}

.section-block-tight {
    margin-top: 28px;
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.section-head-compact {
    margin-bottom: 18px;
}

.section-head h2 {
    margin-top: 5px;
}

.album-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
    gap: 24px 18px;
}

.album-grid-roomy {
    margin-top: 8px;
}

.album-card {
    min-width: 0;
}

.album-card-cover {
    position: relative;
    aspect-ratio: 1;
    margin-bottom: 12px;
    overflow: hidden;
    background: linear-gradient(145deg, #202734, #12161e);
    border: 1px solid var(--line);
    border-radius: 16px;
}

.album-card-cover > a {
    display: block;
    width: 100%;
    height: 100%;
}

.album-card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 450ms cubic-bezier(0.2, 0.8, 0.2, 1), filter 300ms ease;
}

.album-card-cover::after {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, rgba(4, 6, 8, 0.56));
    opacity: 0;
    content: "";
    pointer-events: none;
    transition: opacity 200ms ease;
}

.album-card:hover .album-card-cover img {
    transform: scale(1.035);
    filter: brightness(0.8);
}

.album-card:hover .album-card-cover::after {
    opacity: 1;
}

.cover-fallback {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    color: rgba(255, 255, 255, 0.26);
    background:
        radial-gradient(circle at 30% 20%, rgba(201, 255, 74, 0.12), transparent 45%),
        linear-gradient(145deg, #202734, #10141b);
}

.cover-fallback svg {
    width: 34%;
    height: 34%;
    min-width: 28px;
    min-height: 28px;
}

.cover-play,
.cover-add {
    position: absolute;
    z-index: 2;
    display: grid;
    place-items: center;
    padding: 0;
    color: var(--accent-ink);
    background: var(--accent);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 180ms ease, transform 180ms ease, background 160ms ease;
}

.cover-play {
    right: 12px;
    bottom: 12px;
    width: 46px;
    height: 46px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.cover-play svg {
    width: 19px;
    height: 19px;
    margin-left: 2px;
}

.cover-add {
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    color: var(--text);
    background: rgba(11, 14, 19, 0.78);
    border: 1px solid var(--line-strong);
    backdrop-filter: blur(8px);
}

.cover-add svg {
    width: 16px;
    height: 16px;
}

.cover-play:hover,
.cover-add:hover {
    background: var(--accent-strong);
    color: var(--accent-ink);
}

.album-card:hover .cover-play,
.album-card:hover .cover-add,
.album-card:focus-within .cover-play,
.album-card:focus-within .cover-add {
    opacity: 1;
    transform: translateY(0);
}

.album-card-title {
    display: block;
    overflow: hidden;
    font-size: 13px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.album-card-title:hover {
    color: var(--accent);
}

.album-card-meta {
    display: flex;
    gap: 4px;
    margin-top: 3px;
    overflow: hidden;
    color: var(--muted);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.album-card-meta a:hover {
    color: #d3dbe3;
}

.home-lower {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
    gap: 20px;
    margin-top: 42px;
}

.panel {
    padding: 23px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}

.recent-list {
    display: grid;
    gap: 2px;
}

.recent-row {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto 36px;
    align-items: center;
    gap: 12px;
    padding: 8px;
    border-radius: 11px;
    transition: background 150ms ease;
}

.recent-row:hover {
    background: rgba(255, 255, 255, 0.035);
}

.recent-cover {
    width: 42px;
    height: 42px;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: 8px;
}

.recent-cover img,
.history-cover img,
.queue-item-cover img,
.player-cover img,
.top-track-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recent-copy,
.history-copy,
.queue-item-copy,
.top-track-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.recent-title,
.history-title,
.queue-item-title,
.top-track-title {
    overflow: hidden;
    font-size: 13px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.recent-meta,
.history-meta,
.queue-item-artist,
.top-track-artist {
    overflow: hidden;
    color: var(--muted);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.recent-time {
    color: var(--muted-2);
    font-size: 10px;
    white-space: nowrap;
}

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

.genre-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 0 12px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid var(--line);
    border-radius: 10px;
    font-size: 12px;
    transition: background 150ms ease, border-color 150ms ease;
}

.genre-pill:hover {
    background: rgba(201, 255, 74, 0.09);
    border-color: rgba(201, 255, 74, 0.22);
}

.genre-pill small {
    display: grid;
    place-items: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    font-size: 9px;
}

.track-list {
    padding: 8px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}

.track-list-album {
    background: rgba(17, 21, 29, 0.68);
}

.track-row {
    display: grid;
    grid-template-columns: 56px minmax(200px, 1fr) minmax(90px, 180px) 52px 32px 38px 16px;
    align-items: center;
    gap: 10px;
    min-height: 58px;
    padding: 6px 12px 6px 8px;
    border-radius: 10px;
    transition: background 140ms ease;
}

.track-row + .track-row {
    border-top: 1px solid rgba(255, 255, 255, 0.035);
}

.track-row:hover {
    background: rgba(255, 255, 255, 0.04);
}

.track-lead {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
}

.track-number {
    color: var(--muted-2);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}

.track-play {
    display: none;
    place-items: center;
    width: 32px;
    height: 32px;
    padding: 0;
    color: var(--accent-ink);
    background: var(--accent);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
}

.track-play svg {
    width: 14px;
    height: 14px;
    margin-left: 1px;
}

.track-row:hover .track-number,
.track-row:focus-within .track-number {
    display: none;
}

.track-row:hover .track-play,
.track-row:focus-within .track-play {
    display: grid;
}

.track-main {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

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

.track-sub {
    display: flex;
    gap: 4px;
    overflow: hidden;
    color: var(--muted);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.track-sub a:hover {
    color: #d7dee6;
}

.dot {
    color: var(--muted-2);
}

.track-genre {
    overflow: hidden;
    color: var(--muted);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.track-duration {
    color: var(--muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.track-favorite {
    width: 32px;
    height: 32px;
    color: var(--muted-2);
}

.track-favorite svg {
    width: 16px;
    height: 16px;
}

.track-favorite:hover,
.track-favorite.is-favorite {
    color: var(--accent);
}

.track-favorite.is-favorite svg {
    fill: currentColor;
}

.track-add {
    width: 32px;
    height: 32px;
    opacity: 0;
}

.track-row:hover .track-add,
.track-row:focus-within .track-add {
    opacity: 1;
}

.track-add svg {
    width: 16px;
    height: 16px;
}

.playing-bars {
    display: none;
    align-items: flex-end;
    gap: 2px;
    width: 14px;
    height: 14px;
}

.playing-bars i {
    width: 2px;
    height: 40%;
    background: var(--accent);
    border-radius: 2px;
    animation: bars 800ms ease-in-out infinite alternate;
}

.playing-bars i:nth-child(2) {
    height: 80%;
    animation-delay: -300ms;
}

.playing-bars i:nth-child(3) {
    height: 55%;
    animation-delay: -500ms;
}

.track-row.is-playing .track-number,
.track-row.is-playing .track-play {
    display: none;
}

.track-row.is-playing .playing-bars {
    display: flex;
}

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

@keyframes bars {
    to {
        height: 100%;
    }
}

.search-hero {
    display: block;
    min-height: 0;
    padding-bottom: 30px;
}

.search-hero-form {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    width: min(820px, 100%);
    margin-top: 28px;
    padding: 7px 7px 7px 17px;
    background: rgba(4, 7, 10, 0.62);
    border: 1px solid var(--line-strong);
    border-radius: 15px;
}

.search-hero-form > svg {
    color: var(--muted);
}

.search-hero-form input {
    flex: 1;
    min-width: 0;
    height: 44px;
    color: var(--text);
    background: transparent;
    border: 0;
    outline: 0;
    font-size: 17px;
}

.search-hero-form input::placeholder {
    color: var(--muted-2);
}

.result-summary {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin: 24px 2px 0;
    color: #d4dbe2;
    font-size: 13px;
}

.result-summary .muted {
    font-size: 11px;
}

.search-suggestions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 26px;
}

.suggestion-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    transition: border-color 160ms ease, transform 160ms ease;
}

.suggestion-card:hover {
    border-color: rgba(201, 255, 74, 0.24);
    transform: translateY(-2px);
}

.suggestion-card > svg:first-child {
    width: 30px;
    height: 30px;
    color: var(--accent);
}

.suggestion-card > svg:last-child {
    width: 18px;
    height: 18px;
    margin-left: auto;
    color: var(--muted);
}

.suggestion-card > span {
    display: flex;
    flex-direction: column;
}

.suggestion-card strong {
    font-size: 14px;
}

.suggestion-card small {
    color: var(--muted);
    font-size: 11px;
}

.artist-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 24px 18px;
}

.artist-grid-roomy {
    margin-top: 8px;
}

.artist-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    padding: 22px 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid transparent;
    border-radius: var(--radius-lg);
    text-align: center;
    transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.artist-card:hover {
    background: var(--panel);
    border-color: var(--line);
    transform: translateY(-2px);
}

.artist-avatar {
    width: 110px;
    height: 110px;
    margin-bottom: 14px;
    overflow: hidden;
    background: var(--panel-2);
    border: 1px solid var(--line);
    border-radius: 50%;
}

.artist-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.artist-name {
    max-width: 100%;
    overflow: hidden;
    font-size: 14px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.artist-meta {
    margin-top: 3px;
    color: var(--muted);
    font-size: 10px;
}

.artist-hero {
    display: flex;
    align-items: flex-end;
    gap: 30px;
    min-height: 260px;
    padding: 30px;
    background:
        radial-gradient(circle at 15% 10%, rgba(201, 255, 74, 0.11), transparent 25rem),
        var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

.artist-hero-avatar {
    flex: 0 0 190px;
    width: 190px;
    height: 190px;
    overflow: hidden;
    background: var(--panel-2);
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    box-shadow: var(--shadow);
}

.artist-hero-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.genre-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 12px;
    margin-top: 6px;
}

.genre-card {
    display: flex;
    flex-direction: column;
    min-height: 118px;
    padding: 18px;
    background:
        linear-gradient(140deg, rgba(201, 255, 74, 0.07), transparent 65%),
        var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.genre-card:hover {
    background:
        linear-gradient(140deg, rgba(201, 255, 74, 0.12), transparent 65%),
        var(--panel);
    border-color: rgba(201, 255, 74, 0.24);
    transform: translateY(-2px);
}

.genre-card-top {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 18px;
    font-weight: 650;
    letter-spacing: -0.02em;
}

.genre-card-top svg {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    color: var(--accent);
}

.genre-card-stats {
    margin-top: auto;
    color: var(--muted);
    font-size: 10px;
}

.genre-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: 34px;
    background:
        linear-gradient(130deg, rgba(201, 255, 74, 0.1), transparent 55%),
        var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

.genre-hero p {
    margin-top: 14px;
    color: var(--muted);
    font-size: 14px;
}

.genre-hero .page-hero-copy h1 {
    font-size: clamp(40px, 5vw, 62px);
}

.detail-hero {
    display: flex;
    align-items: flex-end;
    gap: 34px;
    padding: 34px;
    background:
        radial-gradient(circle at 0% 100%, rgba(201, 255, 74, 0.1), transparent 30rem),
        linear-gradient(145deg, #151b24, #0e1218);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

.detail-cover {
    flex: 0 0 230px;
    width: 230px;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--panel-2);
    border: 1px solid var(--line-strong);
    border-radius: 20px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
}

.detail-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-copy {
    min-width: 0;
    padding-bottom: 5px;
}

.detail-copy h1 {
    margin: 10px 0 14px;
    hyphens: auto;
    overflow-wrap: anywhere;
}

.detail-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 13px;
    color: var(--muted);
    font-size: 12px;
}

.detail-meta > * + *::before {
    margin-right: 13px;
    color: var(--muted-2);
    content: "·";
}

.detail-artist {
    color: var(--text);
    font-weight: 650;
}

a.detail-artist:hover {
    color: var(--accent);
}

.detail-genre {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 16px;
    padding: 5px 10px;
    color: #c8d1da;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 10px;
}

.detail-genre svg {
    width: 13px;
    height: 13px;
    color: var(--accent);
}

.detail-genre:hover {
    border-color: rgba(201, 255, 74, 0.25);
}

.detail-actions {
    display: flex;
    gap: 9px;
    margin-top: 24px;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 28px;
}

.pagination-page {
    color: var(--muted);
    font-size: 11px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    padding: 40px;
    color: var(--muted);
    text-align: center;
}

.empty-state.compact {
    min-height: 180px;
    padding: 26px;
}

.empty-icon {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    margin-bottom: 14px;
    color: var(--muted-2);
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid var(--line);
    border-radius: 18px;
}

.empty-icon svg {
    width: 25px;
    height: 25px;
}

.empty-state p {
    color: var(--text);
    font-size: 16px;
    font-weight: 600;
}

.empty-state > span:not(.empty-icon) {
    max-width: 400px;
    margin-top: 5px;
    font-size: 12px;
}

.error-state .empty-icon {
    color: var(--warning);
}

.error-state .button {
    margin-top: 20px;
}

.top-track-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 8px;
}

.top-track {
    display: grid;
    grid-template-columns: 24px 46px minmax(0, 1fr) auto 34px;
    align-items: center;
    gap: 11px;
    padding: 10px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
}

.top-track-number {
    color: var(--muted-2);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

.top-track-cover {
    width: 46px;
    height: 46px;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: 8px;
}

.top-track-plays {
    color: var(--accent);
    font-size: 11px;
    font-weight: 700;
}

.history-genres {
    margin-top: 20px;
}

.history-list {
    display: grid;
    gap: 1px;
}

.history-row {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr) 54px 88px 36px;
    align-items: center;
    gap: 14px;
    padding: 10px 12px;
    border-radius: 11px;
    transition: background 150ms ease;
}

.history-row:hover {
    background: rgba(255, 255, 255, 0.035);
}

.history-time {
    display: flex;
    flex-direction: column;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.4;
}

.history-time strong {
    color: #dce3e9;
    font-size: 12px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.history-track {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.history-cover {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: 8px;
}

.history-duration {
    color: var(--muted);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.history-status {
    padding: 3px 7px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.04);
    border-radius: 6px;
    font-size: 9px;
    text-align: center;
}

.history-status.is-complete {
    color: #d9f8a5;
    background: rgba(201, 255, 74, 0.08);
}

.queue-page-hero {
    align-items: flex-end;
}

.queue-page-actions {
    display: flex;
    gap: 8px;
}

.queue-page {
    margin-top: 22px;
    padding: 14px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}

.queue-page-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 8px 14px;
    font-size: 11px;
}

.queue-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.queue-item {
    display: grid;
    grid-template-columns: 44px 44px minmax(0, 1fr) 50px 110px;
    align-items: center;
    gap: 10px;
    min-height: 58px;
    padding: 6px 8px;
    border: 1px solid transparent;
    border-radius: 10px;
    transition: background 150ms ease, border-color 150ms ease;
}

.queue-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.queue-item.is-current {
    background: rgba(201, 255, 74, 0.055);
    border-color: rgba(201, 255, 74, 0.11);
}

.queue-item-index {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    color: var(--muted-2);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
}

.queue-item-play {
    display: none;
    place-items: center;
    width: 30px;
    height: 30px;
    padding: 0;
    color: var(--accent-ink);
    background: var(--accent);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
}

.queue-item-play svg {
    width: 13px;
    height: 13px;
    margin-left: 1px;
}

.queue-item:hover .queue-item-index > span,
.queue-item:focus-within .queue-item-index > span {
    display: none;
}

.queue-item:hover .queue-item-play,
.queue-item:focus-within .queue-item-play {
    display: grid;
}

.queue-item.is-playing .queue-item-index > span,
.queue-item.is-playing .queue-item-play {
    display: none;
}

.queue-item.is-playing .queue-item-index .playing-bars {
    display: flex;
}

.queue-item.is-playing .queue-item-title {
    color: var(--accent);
}

.queue-item-cover {
    width: 40px;
    height: 40px;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: 8px;
}

.queue-item-duration {
    color: var(--muted);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.queue-item-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1px;
    opacity: 0;
    transition: opacity 150ms ease;
}

.queue-item:hover .queue-item-actions,
.queue-item:focus-within .queue-item-actions {
    opacity: 1;
}

.queue-item-actions .icon-button {
    width: 32px;
    height: 32px;
}

.queue-item-actions svg {
    width: 15px;
    height: 15px;
}

.queue-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 240px;
    padding: 30px;
    color: var(--muted);
    text-align: center;
}

.queue-empty .empty-icon {
    margin-bottom: 12px;
}

.queue-empty p {
    color: var(--text);
    font-weight: 600;
}

.queue-empty > span:last-child {
    max-width: 260px;
    margin-top: 4px;
    font-size: 11px;
}

.queue-list-page .queue-item {
    grid-template-columns: 44px 48px minmax(0, 1fr) 54px 118px;
    min-height: 64px;
}

.queue-list-page .queue-item-index > span {
    font-size: 11px;
}

/* Player */
.player {
    position: fixed;
    z-index: 100;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    grid-template-columns: minmax(200px, 1fr) minmax(330px, 2fr) minmax(190px, 1fr);
    align-items: center;
    gap: 28px;
    height: var(--player);
    padding: 11px 26px;
    background: rgba(12, 15, 21, 0.94);
    border-top: 1px solid var(--line-strong);
    box-shadow: 0 -18px 60px rgba(0, 0, 0, 0.32);
    backdrop-filter: blur(26px);
}

.player-track {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.player-cover {
    position: relative;
    flex: 0 0 58px;
    width: 58px;
    height: 58px;
    overflow: hidden;
    background: var(--panel-2);
    border: 1px solid var(--line);
    border-radius: 10px;
}

.player-cover img {
    position: absolute;
    inset: 0;
}

.player-track-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.player-title {
    overflow: hidden;
    font-size: 13px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.player-title:hover {
    color: var(--accent);
}

.player-artist {
    overflow: hidden;
    color: var(--muted);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.player.is-idle .player-title,
.player.is-idle .player-artist {
    color: var(--muted);
}

.player.is-idle .player-cover .cover-fallback {
    opacity: 0.5;
}

.player-favorite {
    margin-left: auto;
}

.player-favorite.is-favorite {
    color: var(--accent);
}

.player-favorite.is-favorite svg {
    fill: currentColor;
}

.player-favorite + .add-current-button {
    margin-left: 0;
}

.add-current-button {
    margin-left: auto;
}

.player-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    min-width: 0;
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 9px;
}

.player-controls .icon-button {
    width: 34px;
    height: 34px;
}

.player-controls .icon-button svg {
    width: 18px;
    height: 18px;
}

.play-button {
    position: relative;
    display: grid;
    place-items: center;
    width: 43px;
    height: 43px;
    padding: 0;
    color: var(--accent-ink);
    background: var(--accent);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 7px 22px rgba(201, 255, 74, 0.16);
    transition: transform 150ms ease, background 150ms ease;
}

.play-button:hover {
    background: var(--accent-strong);
    transform: scale(1.045);
}

.play-button svg {
    width: 18px;
    height: 18px;
}

.play-button .play-icon {
    margin-left: 2px;
}

.play-button .pause-icon {
    display: none;
}

.play-button.is-playing .play-icon {
    display: none;
}

.play-button.is-playing .pause-icon {
    display: block;
}

.player-loader {
    position: absolute;
    inset: 4px;
    border: 2px solid rgba(10, 13, 8, 0.25);
    border-top-color: var(--accent-ink);
    border-radius: 50%;
    animation: spin 700ms linear infinite;
}

.play-button.is-loading > svg {
    opacity: 0;
}

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

.player-progress {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.time {
    min-width: 33px;
    color: var(--muted-2);
    font-size: 9px;
    font-variant-numeric: tabular-nums;
}

.time:first-child {
    text-align: right;
}

.range {
    height: 3px;
    background: transparent;
    border-radius: 99px;
    outline: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.range::-webkit-slider-runnable-track {
    height: 3px;
    background: linear-gradient(90deg, rgba(201, 255, 74, 0.9), rgba(201, 255, 74, 0.9)) 0 / var(--range-progress, 0%) 100% no-repeat, rgba(255, 255, 255, 0.12);
    border-radius: 99px;
}

.range::-moz-range-track {
    height: 3px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 99px;
}

.range::-moz-range-progress {
    height: 3px;
    background: var(--accent);
    border-radius: 99px;
}

.range::-webkit-slider-thumb {
    width: 9px;
    height: 9px;
    margin-top: -3px;
    background: var(--text);
    border: 0;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 150ms ease;
    -webkit-appearance: none;
    appearance: none;
}

.range:hover::-webkit-slider-thumb,
.range:focus-visible::-webkit-slider-thumb {
    opacity: 1;
}

.range::-moz-range-thumb {
    width: 9px;
    height: 9px;
    background: var(--text);
    border: 0;
    border-radius: 50%;
}

.seek-range {
    flex: 1;
}

.player-side {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.player-side .icon-button {
    width: 34px;
    height: 34px;
}

.player-side .icon-button svg {
    width: 17px;
    height: 17px;
}

.volume-range {
    width: 88px;
}

.mute-icon {
    display: none;
}

.player-side .is-muted .volume-icon {
    display: none;
}

.player-side .is-muted .mute-icon {
    display: block;
}

.queue-toggle {
    position: relative;
    border: 1px solid var(--line);
}

.queue-count {
    position: absolute;
    top: -2px;
    right: -2px;
    display: grid;
    place-items: center;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    color: var(--accent-ink);
    background: var(--accent);
    border-radius: 99px;
    font-size: 8px;
    font-weight: 800;
}

.player.is-buffering .player-title {
    opacity: 0.65;
}

/* Queue drawer */
.queue-overlay {
    position: fixed;
    z-index: 110;
    inset: 0;
    background: rgba(0, 0, 0, 0.52);
    backdrop-filter: blur(3px);
    animation: fade-in 180ms ease;
}

.queue-drawer {
    position: fixed;
    z-index: 120;
    top: 0;
    right: 0;
    bottom: var(--player);
    display: flex;
    flex-direction: column;
    width: min(430px, 94vw);
    padding: 22px 18px 14px;
    background: rgba(14, 18, 25, 0.98);
    border-left: 1px solid var(--line-strong);
    box-shadow: -30px 0 80px rgba(0, 0, 0, 0.42);
    transform: translateX(104%);
    visibility: hidden;
    transition: transform 240ms cubic-bezier(0.2, 0.8, 0.2, 1), visibility 240ms;
}

.queue-drawer.is-open {
    transform: translateX(0);
    visibility: visible;
}

.queue-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    padding: 0 6px 18px;
    border-bottom: 1px solid var(--line);
}

.queue-header h2 {
    margin-top: 3px;
    font-size: 26px;
}

.queue-header-actions {
    display: flex;
    align-items: center;
    gap: 3px;
}

.queue-header-actions .text-button {
    color: var(--muted);
}

.queue-header-actions .text-button:hover {
    color: var(--danger);
}

.queue-drawer .queue-list {
    flex: 1;
    padding: 10px 0;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.queue-drawer .queue-item {
    grid-template-columns: 34px 40px minmax(0, 1fr) 84px;
    gap: 8px;
    min-height: 54px;
    padding: 5px 6px;
}

.queue-drawer .queue-item-index {
    width: 32px;
    height: 32px;
}

.queue-drawer .queue-item-cover {
    width: 38px;
    height: 38px;
}

.queue-drawer .queue-item-duration {
    display: none;
}

.queue-drawer .queue-item-actions {
    opacity: 0;
    grid-column: 4;
}

.queue-drawer .queue-item:hover .queue-item-actions {
    opacity: 1;
}

.queue-drawer .queue-item-actions .icon-button {
    width: 27px;
    height: 27px;
}

.queue-drawer .queue-item-actions svg {
    width: 13px;
    height: 13px;
}

.queue-drawer .queue-item-actions [data-queue-move] {
    display: none;
}

.queue-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 13px 6px 0;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 11px;
}

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

/* Login */
.auth-shell {
    position: relative;
    min-height: 100vh;
}

.auth-flashes {
    position: fixed;
    z-index: 10;
    top: 18px;
    left: 50%;
    width: min(480px, calc(100% - 32px));
    padding: 0;
    transform: translateX(-50%);
}

.login-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(420px, 0.85fr);
    min-height: 100vh;
}

.login-art {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
    padding: 42px clamp(30px, 5vw, 76px);
    overflow: hidden;
    background:
        radial-gradient(circle at 74% 20%, rgba(201, 255, 74, 0.16), transparent 22rem),
        radial-gradient(circle at 20% 80%, rgba(66, 111, 255, 0.12), transparent 28rem),
        #0b0f14;
    border-right: 1px solid var(--line);
}

.login-art::after {
    position: absolute;
    inset: auto -20% -45% 30%;
    width: 600px;
    height: 600px;
    background: var(--accent);
    border-radius: 50%;
    filter: blur(160px);
    opacity: 0.045;
    content: "";
}

.login-art-copy {
    position: relative;
    z-index: 1;
    max-width: 630px;
    margin: auto 0;
}

.login-art-copy h1 {
    margin-top: 16px;
    font-size: clamp(48px, 6.2vw, 94px);
    letter-spacing: -0.06em;
    line-height: 0.93;
}

.login-art-copy h1 em {
    color: var(--accent);
    font-style: normal;
}

.login-art-copy p {
    max-width: 470px;
    margin-top: 24px;
    color: var(--muted);
    font-size: 15px;
}

.login-wave {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 5px;
    height: 50px;
    opacity: 0.75;
}

.login-wave i {
    width: 3px;
    height: 25%;
    background: var(--accent);
    border-radius: 2px;
    animation: login-wave 1.4s ease-in-out infinite alternate;
}

.login-wave i:nth-child(3n) { height: 75%; animation-delay: -0.3s; }
.login-wave i:nth-child(4n) { height: 48%; animation-delay: -0.6s; }
.login-wave i:nth-child(5n) { height: 100%; animation-delay: -0.9s; }
.login-wave i:nth-child(7n) { height: 35%; animation-delay: -1.1s; }

@keyframes login-wave {
    from { transform: scaleY(0.45); opacity: 0.45; }
    to { transform: scaleY(1); opacity: 1; }
}

.login-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 28px 24px;
    background:
        radial-gradient(circle at 100% 0%, rgba(201, 255, 74, 0.05), transparent 20rem),
        var(--bg);
}

.login-card {
    width: min(420px, 100%);
    padding: 34px;
    background: rgba(17, 21, 29, 0.86);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.login-card h2 {
    margin-top: 7px;
    font-size: 34px;
}

.login-intro {
    margin-top: 12px;
    color: var(--muted);
    font-size: 12px;
}

.login-form {
    display: grid;
    gap: 15px;
    margin-top: 26px;
}

.field {
    display: grid;
    gap: 7px;
}

.field > span:first-child {
    color: #aeb8c3;
    font-size: 10px;
    font-weight: 650;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.field input {
    width: 100%;
    height: 48px;
    padding: 0 14px;
    color: var(--text);
    background: rgba(4, 7, 10, 0.45);
    border: 1px solid var(--line-strong);
    border-radius: 11px;
    outline: 0;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.field input:focus {
    border-color: rgba(201, 255, 74, 0.5);
    box-shadow: 0 0 0 3px rgba(201, 255, 74, 0.07);
}

.field input::placeholder {
    color: var(--muted-2);
}

.password-wrap {
    position: relative;
    display: block;
}

.password-wrap input {
    padding-right: 48px;
}

.reveal-password {
    position: absolute;
    top: 4px;
    right: 4px;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    padding: 0;
    color: var(--muted);
    background: transparent;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
}

.reveal-password:hover,
.reveal-password.is-active {
    color: var(--accent);
    background: rgba(255, 255, 255, 0.04);
}

.reveal-password svg {
    width: 17px;
    height: 17px;
}

.login-submit {
    width: 100%;
    height: 49px;
    margin-top: 3px;
}

.login-submit svg {
    margin-left: auto;
}

.security-note {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin-top: 20px;
    padding: 12px;
    color: var(--muted);
    background: rgba(201, 255, 74, 0.035);
    border: 1px solid rgba(201, 255, 74, 0.1);
    border-radius: 10px;
    font-size: 10px;
    line-height: 1.5;
}

.security-note svg {
    width: 16px;
    height: 16px;
    margin-top: 1px;
    color: var(--accent);
}

.login-footer {
    margin-top: 20px;
    color: var(--muted-2);
    font-size: 10px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* Toasts */
.toast-stack {
    position: fixed;
    z-index: 200;
    right: 22px;
    bottom: calc(var(--player) + 18px);
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    width: min(340px, calc(100vw - 32px));
    pointer-events: none;
}

.toast {
    max-width: 100%;
    padding: 12px 15px;
    color: var(--text);
    background: rgba(25, 32, 42, 0.96);
    border: 1px solid var(--line-strong);
    border-radius: 11px;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.4);
    font-size: 12px;
    animation: toast-in 180ms ease both;
    backdrop-filter: blur(15px);
}

.toast-error {
    border-color: rgba(255, 107, 122, 0.3);
}

.toast.is-leaving {
    opacity: 0;
    transform: translateY(3px);
    transition: opacity 200ms ease, transform 200ms ease;
}

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

@media (max-width: 1200px) {
    :root {
        --sidebar: 224px;
    }

    .content {
        padding: 26px;
    }

    .page-hero {
        padding: 30px;
    }

    .home-hero {
        min-height: 270px;
    }

    .player {
        gap: 18px;
        padding-right: 20px;
        padding-left: 20px;
    }

    .volume-range {
        width: 62px;
    }
}

@media (max-width: 1020px) {
    .sidebar {
        transform: translateX(-104%);
        transition: transform 220ms ease;
    }

    body.nav-open .sidebar {
        transform: translateX(0);
    }

    .sidebar-scrim {
        position: fixed;
        z-index: 55;
        inset: 0;
        display: block;
        background: rgba(0, 0, 0, 0.55);
        opacity: 0;
        visibility: hidden;
        transition: opacity 220ms ease, visibility 220ms;
    }

    body.nav-open .sidebar-scrim {
        opacity: 1;
        visibility: visible;
    }

    .workspace {
        margin-left: 0;
    }

    .menu-button {
        display: inline-grid;
    }

    .topbar {
        padding: 0 22px;
    }

    .global-search {
        width: min(520px, 60vw);
    }

    .home-lower {
        grid-template-columns: 1fr;
    }

    .login-layout {
        grid-template-columns: 1fr;
    }

    .login-art {
        min-height: 52vh;
        padding: 30px;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .login-art-copy h1 {
        font-size: clamp(42px, 8vw, 74px);
    }

    .login-panel {
        min-height: 48vh;
        padding: 36px 22px;
    }

    .login-footer {
        display: none;
    }
}

@media (max-width: 780px) {
    :root {
        --player: 108px;
    }

    .topbar {
        gap: 10px;
        padding: 0 14px;
    }

    .global-search {
        width: auto;
        flex: 1;
    }

    .global-search kbd,
    .user-chip {
        display: none;
    }

    .topbar-user .button {
        display: none;
    }

    .content {
        padding: 18px 14px;
    }

    .flash-stack,
    .connection-banner {
        margin-right: 14px;
        margin-left: 14px;
        padding-right: 0;
        padding-left: 0;
    }

    .page-hero {
        display: block;
        min-height: 0;
        padding: 24px;
        border-radius: 20px;
    }

    .home-hero {
        min-height: 0;
    }

    .home-hero .page-hero-copy h1 {
        font-size: clamp(43px, 12vw, 66px);
    }

    .stat-strip {
        flex-wrap: wrap;
        margin-top: 22px;
    }

    .stat {
        flex: 1;
        min-width: 88px;
        padding: 12px;
    }

    .stat-value {
        font-size: 20px;
    }

    .stat-label {
        font-size: 8px;
    }

    .album-grid {
        grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
        gap: 19px 12px;
    }

    .cover-play,
    .cover-add {
        opacity: 1;
        transform: none;
    }

    .track-row {
        grid-template-columns: 46px minmax(0, 1fr) 32px 42px 30px;
        gap: 6px;
        min-height: 55px;
        padding-right: 5px;
    }

    .track-genre,
    .track-duration {
        display: none;
    }

    .track-add {
        opacity: 1;
    }

    .top-track-grid {
        grid-template-columns: 1fr;
    }

    .search-suggestions {
        grid-template-columns: 1fr;
    }

    .result-summary {
        flex-direction: column;
        gap: 4px;
    }

    .artist-grid {
        grid-template-columns: repeat(auto-fill, minmax(135px, 1fr));
        gap: 12px;
    }

    .artist-card {
        padding: 15px 9px;
    }

    .artist-avatar {
        width: 90px;
        height: 90px;
    }

    .detail-hero,
    .artist-hero {
        display: block;
        padding: 22px;
        border-radius: 20px;
    }

    .detail-cover {
        width: min(230px, 65vw);
        margin-bottom: 22px;
    }

    .artist-hero-avatar {
        width: 140px;
        height: 140px;
        margin-bottom: 22px;
    }

    .detail-copy h1 {
        font-size: clamp(34px, 10vw, 52px);
    }

    .genre-hero {
        display: block;
        padding: 24px;
        border-radius: 20px;
    }

    .genre-hero .button {
        margin-top: 20px;
    }

    .history-row {
        grid-template-columns: 56px minmax(0, 1fr) 34px;
        gap: 9px;
        padding: 8px 5px;
    }

    .history-time {
        font-size: 9px;
    }

    .history-duration,
    .history-status {
        display: none;
    }

    .history-cover {
        flex-basis: 36px;
        width: 36px;
        height: 36px;
    }

    .panel {
        padding: 18px;
    }

    .recent-row {
        grid-template-columns: 40px minmax(0, 1fr) 34px;
    }

    .recent-time {
        display: none;
    }

    .queue-page {
        padding: 8px;
    }

    .queue-page-head {
        display: none;
    }

    .queue-item,
    .queue-list-page .queue-item {
        grid-template-columns: 36px 36px minmax(0, 1fr) 90px;
        gap: 7px;
        padding: 5px;
    }

    .queue-item-duration {
        display: none !important;
    }

    .queue-item-cover {
        width: 34px;
        height: 34px;
    }

    .queue-item-actions {
        opacity: 1;
    }

    .queue-item-actions [data-queue-move] {
        display: none;
    }

    .queue-item-actions .icon-button {
        width: 27px;
        height: 27px;
    }

    .queue-drawer {
        bottom: var(--player);
        width: 100%;
        border-left: 0;
    }

    .player {
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "track side"
            "center center";
        gap: 4px 10px;
        height: var(--player);
        padding: 8px 13px 9px;
    }

    .player-track {
        grid-area: track;
    }

    .player-cover {
        flex-basis: 46px;
        width: 46px;
        height: 46px;
    }

    .player-title {
        font-size: 12px;
    }

    .player-artist {
        font-size: 10px;
    }

    .player-center {
        grid-area: center;
    }

    .player-controls {
        margin-top: -2px;
    }

    .play-button {
        width: 37px;
        height: 37px;
    }

    .player-progress {
        margin-top: -4px;
    }

    .player-side {
        grid-area: side;
    }

    .volume-range,
    .player-side > button:first-child {
        display: none;
    }

    .player-side .queue-toggle {
        width: 36px;
        height: 36px;
        border: 0;
    }

    .add-current-button {
        display: none !important;
    }

    .toast-stack {
        right: 14px;
        bottom: calc(var(--player) + 12px);
    }

    .login-art {
        min-height: 44vh;
        padding: 24px;
    }

    .login-art .brand {
        margin-bottom: 20px;
    }

    .login-art-copy h1 {
        font-size: clamp(37px, 11vw, 58px);
    }

    .login-art-copy p {
        margin-top: 16px;
        font-size: 12px;
    }

    .login-wave {
        height: 30px;
        margin-top: 26px;
    }

    .login-panel {
        min-height: 56vh;
        padding: 26px 14px;
    }

    .login-card {
        padding: 24px 20px;
        border-radius: 19px;
    }

    .login-card h2 {
        font-size: 29px;
    }
}

@media (max-width: 480px) {
    .global-search input {
        font-size: 13px;
    }

    .page-hero-copy p {
        font-size: 13px;
    }

    .album-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .artist-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .genre-grid {
        grid-template-columns: 1fr;
    }

    .detail-actions {
        flex-direction: column;
    }

    .detail-actions .button {
        width: 100%;
    }

    .recent-row {
        gap: 8px;
    }

    .track-row {
        grid-template-columns: 41px minmax(0, 1fr) 29px 29px;
    }

    .track-lead {
        width: 36px;
    }

    .track-favorite {
        width: 29px;
        height: 29px;
    }

    .track-row .track-add {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Wave */
.wave-hero {
    align-items: flex-end;
}

.wave-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.wave-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    align-items: start;
    gap: 22px;
    margin-top: 22px;
}

.wave-main {
    min-height: 420px;
    padding: 16px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}

.wave-status {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 4px 8px 14px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.wave-status-dot {
    width: 8px;
    height: 8px;
    background: var(--muted-2);
    border-radius: 50%;
}

.wave-status-dot.is-active {
    background: var(--accent);
    box-shadow: 0 0 0 4px rgba(201, 255, 74, 0.1), 0 0 18px rgba(201, 255, 74, 0.5);
}

.wave-status-count {
    margin-left: auto;
    color: var(--muted-2);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}

.wave-queue {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.wave-track {
    display: grid;
    grid-template-columns: 38px 48px minmax(0, 1fr) 50px;
    align-items: center;
    gap: 11px;
    min-height: 64px;
    padding: 6px 8px;
    border: 1px solid transparent;
    border-radius: 10px;
    transition: background 150ms ease, border-color 150ms ease;
}

.wave-track:hover,
.wave-track:focus-within {
    background: rgba(255, 255, 255, 0.04);
}

.wave-track.is-current {
    background: rgba(201, 255, 74, 0.055);
    border-color: rgba(201, 255, 74, 0.12);
}

.wave-track.is-current .wave-track-copy strong {
    color: var(--accent);
}

.wave-track.is-next .wave-track-copy strong::after {
    content: " (далее)";
    color: var(--accent);
    font-weight: 600;
}

.wave-track-play {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    padding: 0;
    color: var(--accent-ink);
    background: var(--accent);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    transition: opacity 150ms ease, transform 150ms ease;
}

.wave-track:hover .wave-track-play,
.wave-track:focus-within .wave-track-play,
.wave-track.is-current .wave-track-play {
    opacity: 1;
}

.wave-track-play:hover {
    transform: scale(1.06);
}

.wave-track-play svg {
    width: 14px;
    height: 14px;
    margin-left: 1px;
}

.wave-track-cover {
    width: 44px;
    height: 44px;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: 9px;
}

.wave-track-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.wave-track-copy strong,
.wave-track-copy span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wave-track-copy strong {
    color: var(--text);
    font-size: 13px;
    font-weight: 650;
}

.wave-track-copy span {
    color: var(--muted);
    font-size: 11px;
}

.wave-track-duration {
    color: var(--muted);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.wave-track-play--ghost {
    visibility: hidden;
}

.wave-panel {
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: sticky;
    top: 92px;
}

.wave-future-card {
    padding: 14px;
}

.wave-future {
    display: flex;
    max-height: calc(100vh - 220px);
    flex-direction: column;
    gap: 5px;
    overflow-y: auto;
    padding-right: 2px;
}

.wave-future-empty {
    padding: 18px 8px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}

.wave-option {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 56px;
    padding: 6px 8px;
    color: var(--text);
    text-align: left;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: background 150ms ease, border-color 150ms ease;
}

.wave-option:hover,
.wave-option:focus-visible {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--line);
}

.wave-option.is-stay {
    background: rgba(201, 255, 74, 0.055);
    border-color: rgba(201, 255, 74, 0.16);
}

.wave-option.is-stay .wave-option-label {
    color: var(--accent);
}

.wave-option.is-loading,
.wave-option:disabled {
    opacity: 0.55;
}

.wave-option:disabled {
    cursor: default;
}

.wave-option:disabled:hover {
    background: transparent;
    border-color: transparent;
}

.wave-option.is-stay:disabled:hover {
    background: rgba(201, 255, 74, 0.055);
    border-color: rgba(201, 255, 74, 0.16);
}

.wave-option .wave-track-cover {
    width: 40px;
    height: 40px;
    border-radius: 8px;
}

.wave-option-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 2px;
}

.wave-option-copy strong,
.wave-option-copy span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wave-option-label {
    color: var(--muted-2);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.wave-option-copy strong {
    color: var(--text);
    font-size: 12px;
    font-weight: 650;
}

.wave-option-copy span:last-child {
    color: var(--muted);
    font-size: 10px;
}

.wave-option-duration {
    color: var(--muted);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
}

.wave-card {
    padding: 18px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}

.wave-card-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.wave-card-head h2 {
    font-size: 15px;
    letter-spacing: -0.01em;
}

.wave-card-hint {
    color: var(--muted-2);
    font-size: 10px;
    text-align: right;
}

.wave-select,
.wave-input {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    color: var(--text);
    background: var(--panel-2);
    border: 1px solid var(--line);
    border-radius: 10px;
    outline: none;
    font-size: 12px;
}

.wave-select:focus,
.wave-input:focus {
    border-color: var(--line-strong);
}

.wave-energy {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
    margin-top: 10px;
    padding: 4px;
    background: var(--panel-2);
    border: 1px solid var(--line);
    border-radius: 11px;
}

.wave-energy button {
    min-height: 34px;
    padding: 0 6px;
    color: var(--muted);
    background: transparent;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 650;
    transition: color 150ms ease, background 150ms ease;
}

.wave-energy button:hover {
    color: var(--text);
}

.wave-energy button.is-active {
    color: var(--accent-ink);
    background: var(--accent);
}

.wave-slider {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-top: 15px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

.wave-slider > span {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.wave-slider b {
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.wave-range {
    width: 100%;
}

.wave-range::-webkit-slider-thumb {
    opacity: 1;
}

.wave-nudge-row {
    display: flex;
    gap: 7px;
}

.wave-nudge-row .wave-input {
    min-width: 0;
    flex: 1;
}

.wave-nudge-row .button {
    flex: 0 0 auto;
}

.wave-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}

.wave-chips button {
    padding: 7px 10px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid var(--line);
    border-radius: 99px;
    cursor: pointer;
    font-size: 10px;
    font-weight: 600;
    transition: color 150ms ease, border-color 150ms ease;
}

.wave-chips button:hover {
    color: var(--text);
    border-color: var(--line-strong);
}

@media (max-width: 1100px) {
    .wave-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .wave-panel {
        position: static;
        display: block;
    }

    .wave-future {
        max-height: none;
    }
}

@media (max-width: 720px) {
    .wave-panel {
        grid-template-columns: minmax(0, 1fr);
    }

    .wave-hero-actions {
        width: 100%;
    }

    .wave-hero-actions .button {
        flex: 1;
    }

    .wave-track {
        grid-template-columns: 32px 42px minmax(0, 1fr) 44px;
        gap: 8px;
    }

    .wave-track-play {
        width: 30px;
        height: 30px;
        opacity: 1;
    }
}
