:root {
    --bg: #080b14;
    --bg2: #10172a;
    --card: rgba(20, 27, 45, .92);
    --card2: rgba(30, 41, 65, .94);
    --text: #f6f7fb;
    --muted: #a9b2c7;
    --line: rgba(255,255,255,.11);
    --primary: #8b5cf6;
    --primary-dark: #7c3aed;
    --secondary: #06b6d4;
    --danger: #f43f5e;
    --success: #22c55e;
    --warning: #f59e0b;
    --shadow: 0 22px 60px rgba(0,0,0,.30);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(139,92,246,.34), transparent 34rem),
        radial-gradient(circle at top right, rgba(6,182,212,.22), transparent 32rem),
        linear-gradient(180deg, #070914 0%, #111827 100%);
    color: var(--text);
    min-height: 100vh;
}
a { color: #c4b5fd; text-decoration: none; }
a:hover { color: #fff; text-decoration: none; }
.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 70px;
    padding: 12px 24px;
    background: rgba(8, 11, 20, .78);
    color: #fff;
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}
.brand a { color: #fff; font-size: 20px; font-weight: 900; letter-spacing: -.03em; display: inline-flex; align-items: center; gap: 10px; }
.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 13px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 12px 35px rgba(139,92,246,.32);
}
.nav { display: flex; gap: 8px; flex: 1; flex-wrap: wrap; }
.nav a { color: #dbe3f4; padding: 8px 12px; border-radius: 999px; font-weight: 700; font-size: 14px; }
.nav a:hover, .nav a.active { background: rgba(255,255,255,.12); color: #fff; }
.userbox { color: var(--muted); font-size: 14px; white-space: nowrap; }
.container { max-width: 1280px; margin: 30px auto; padding: 0 18px; }
.footer { color: var(--muted); text-align: center; padding: 30px; font-size: 13px; }
.card, .track-card, .album-card {
    background: linear-gradient(180deg, rgba(30,41,65,.92), rgba(15,23,42,.92));
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 18px;
    box-shadow: var(--shadow);
}
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.track-list { display: grid; gap: 14px; }
.track-card { display: grid; grid-template-columns: 76px minmax(220px, 1fr) minmax(250px, 420px) auto; gap: 16px; align-items: center; }
.track-card h3 { margin: 0 0 6px; font-size: 18px; letter-spacing: -.02em; }
.track-card audio { width: 100%; filter: saturate(1.25); }
.track-cover, .album-cover {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(139,92,246,.70), rgba(6,182,212,.45));
    border: 1px solid rgba(255,255,255,.13);
}
.track-cover { width: 76px; height: 76px; border-radius: 18px; color: #fff; font-weight: 900; font-size: 22px; }
.track-cover img, .album-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.track-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.inline-form { display: inline-flex; gap: 6px; align-items: center; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.page-title { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; }
h1 { margin: 0 0 16px; font-size: clamp(28px, 4vw, 42px); letter-spacing: -.055em; }
h2 { margin-top: 0; letter-spacing: -.03em; }
h3 { letter-spacing: -.02em; }
.hero {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 24px;
    align-items: center;
    margin-bottom: 20px;
}
.hero .album-cover { width: 180px; height: 180px; border-radius: 30px; box-shadow: 0 25px 70px rgba(0,0,0,.35); }
.hero h1 { margin-bottom: 6px; }
.form-row { margin-bottom: 13px; }
label { display: block; font-weight: 800; margin-bottom: 6px; color: #e6edf9; }
input[type="text"], input[type="password"], input[type="number"], input[type="file"], select, textarea {
    width: 100%;
    padding: 11px 13px;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 13px;
    background: rgba(2,6,23,.55);
    color: var(--text);
    outline: none;
}
input:focus, select:focus, textarea:focus { border-color: rgba(139,92,246,.78); box-shadow: 0 0 0 4px rgba(139,92,246,.15); }
select option { background: #111827; color: #fff; }
textarea { min-height: 120px; }
.btn, button.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 9px 14px;
    border-radius: 13px;
    border: 1px solid rgba(255,255,255,.13);
    background: rgba(255,255,255,.08);
    color: var(--text);
    cursor: pointer;
    font-weight: 800;
    text-decoration: none;
    transition: transform .12s ease, background .12s ease, border-color .12s ease;
}
.btn:hover { transform: translateY(-1px); background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.24); }
.btn-primary { background: linear-gradient(135deg, var(--primary), #ec4899); border-color: transparent; color: #fff; }
.btn-primary:hover { background: linear-gradient(135deg, var(--primary-dark), #db2777); }
.btn-danger { color: #fff; background: var(--danger); border-color: var(--danger); }
.btn-success { color: #fff; background: var(--success); border-color: var(--success); }
.table { width: 100%; border-collapse: collapse; background: rgba(15,23,42,.92); border-radius: 18px; overflow: hidden; border: 1px solid var(--line); }
.table th, .table td { padding: 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table th { background: rgba(255,255,255,.05); font-size: 13px; color: #cbd5e1; }
.table tr:hover td { background: rgba(255,255,255,.03); }
.alert { padding: 12px 14px; border-radius: 14px; margin-bottom: 16px; border: 1px solid var(--line); background: rgba(255,255,255,.08); }
.alert-success { border-color: rgba(34,197,94,.42); background: rgba(34,197,94,.12); color: #86efac; }
.alert-danger { border-color: rgba(244,63,94,.42); background: rgba(244,63,94,.13); color: #fecdd3; }
.alert-warning { border-color: rgba(245,158,11,.42); background: rgba(245,158,11,.13); color: #fde68a; }
.alert-info { border-color: rgba(6,182,212,.42); background: rgba(6,182,212,.12); color: #a5f3fc; }
.empty { padding: 28px; text-align: center; color: var(--muted); background: rgba(255,255,255,.05); border: 1px dashed rgba(255,255,255,.15); border-radius: 20px; }
.login-wrap { max-width: 430px; margin: 80px auto; }
.searchbar { display: flex; gap: 10px; margin-bottom: 18px; }
.searchbar input { flex: 1; }
.badge { display: inline-block; padding: 5px 9px; border-radius: 999px; background: rgba(139,92,246,.18); color: #ddd6fe; font-size: 12px; font-weight: 900; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 18px; }
.album-card { display: block; padding: 14px; color: var(--text); transition: transform .14s ease, border-color .14s ease; }
.album-card:hover { transform: translateY(-3px); border-color: rgba(139,92,246,.55); color: #fff; }
.album-cover { aspect-ratio: 1 / 1; border-radius: 20px; margin-bottom: 13px; }
.album-title { font-weight: 900; letter-spacing: -.03em; line-height: 1.15; margin-bottom: 4px; }
.album-artist, .album-count { color: var(--muted); font-size: 13px; }
.cover-preview { width: 190px; height: 190px; border-radius: 24px; object-fit: cover; border: 1px solid var(--line); box-shadow: var(--shadow); }
pre { white-space: pre-wrap; overflow: auto; padding: 12px; background: rgba(2,6,23,.65); border-radius: 14px; border: 1px solid var(--line); color: #dbeafe; }
hr { border: 0; border-top: 1px solid var(--line); margin: 18px 0; }
@media (max-width: 950px) {
    .topbar { align-items: flex-start; flex-direction: column; }
    .track-card { grid-template-columns: 76px 1fr; }
    .track-card audio, .track-actions { grid-column: 1 / -1; }
    .track-actions { justify-content: flex-start; }
    .searchbar { flex-direction: column; }
    .hero { grid-template-columns: 1fr; }
    .hero .album-cover { width: 160px; height: 160px; }
}
