/* ===== Reset & Variables ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #121212;
    --bg-card: #181818;
    --bg-card-hover: #252525;
    --bg-elevated: #1a1a2e;
    --bg-highlight: #1f1f1f;
    --text-primary: #ffffff;
    --text-secondary: #a7a7a7;
    --text-muted: #6a6a6a;
    --accent: #ff6b35;
    --accent-hover: #ff8255;
    --accent-dark: #d45a2a;
    --gradient-1: linear-gradient(135deg, #ff6b35, #f7c948);
    --gradient-2: linear-gradient(135deg, #e91e63, #9c27b0);
    --gradient-3: linear-gradient(135deg, #ff6b35, #f7c948);
    --gradient-4: linear-gradient(135deg, #667eea, #764ba2);
    --gradient-5: linear-gradient(135deg, #f093fb, #f5576c);
    --shadow-lg: 0 8px 32px rgba(0,0,0,.6);
    --shadow-md: 0 4px 16px rgba(0,0,0,.4);
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --sidebar-width: 260px;
    --player-height: 90px;
    --transition: .2s ease;
}

html {
    font-size: 14px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
}

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

button {
    border: none;
    background: none;
    cursor: pointer;
    color: inherit;
    font-family: inherit;
}

input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

::-webkit-scrollbar {
    width: 8px;
}

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

::-webkit-scrollbar-thumb {
    background: #ffffff20;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #ffffff40;
}

.hidden { display: none !important; }

/* ===== App Layout ===== */
.app {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    grid-template-rows: 1fr var(--player-height);
    height: 100vh;
}

/* ===== Sidebar ===== */
.sidebar {
    background: var(--bg-primary);
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    grid-row: 1;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    margin-bottom: 20px;
}

.logo-text {
    font-size: 1.4rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ff6b35, #f7c948);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 24px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    transition: all var(--transition);
    font-weight: 500;
}

.nav-item:hover {
    color: var(--text-primary);
}

.nav-item.active {
    color: var(--text-primary);
    background: var(--bg-highlight);
}

.sidebar-playlists {
    flex: 1;
    overflow-y: auto;
}

.playlist-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    color: var(--text-secondary);
    font-size: .85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}

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

.playlist-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition);
}

.playlist-item:hover {
    background: var(--bg-highlight);
}

.playlist-item-cover {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    background: var(--gradient-4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .7rem;
    font-weight: 700;
    flex-shrink: 0;
    overflow: hidden;
}

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

.playlist-item-info {
    overflow: hidden;
}

.playlist-item-name {
    font-size: .9rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.playlist-item-meta {
    font-size: .75rem;
    color: var(--text-muted);
}

.sidebar-artist {
    margin-top: auto;
    padding-top: 12px;
}

.sidebar-artist hr {
    border: none;
    border-top: 1px solid #ffffff15;
    margin-bottom: 8px;
}

/* ===== Main Content ===== */
.main-content {
    background: var(--bg-secondary);
    border-radius: 8px;
    margin: 8px 8px 0 0;
    overflow-y: auto;
    position: relative;
}

.page {
    padding: 0 24px 24px;
    min-height: 100%;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    position: sticky;
    top: 0;
    background: var(--bg-secondary);
    z-index: 10;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #00000080;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Buttons ===== */
/* ===== Google Button ===== */
.btn-google {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 24px;
    background: #ffffff;
    color: #1a1a1a;
    border: none;
    border-radius: 500px;
    font-weight: 600;
    font-size: .95rem;
    cursor: pointer;
    transition: all var(--transition);
}

.btn-google:hover {
    background: #f0f0f0;
    transform: scale(1.02);
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 20px 0;
    color: var(--text-muted);
    font-size: .85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #ffffff15;
}

.auth-error {
    color: #ef4444;
    font-size: .85rem;
    text-align: center;
    margin-top: -4px;
}

/* ===== Role Cards ===== */
.role-cards {
    display: flex;
    gap: 12px;
}

.role-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 24px 16px;
    background: #ffffff08;
    border: 2px solid #ffffff15;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition);
    color: var(--text-secondary);
}

.role-card:hover {
    border-color: var(--accent);
    color: var(--text-primary);
    background: rgba(255, 107, 53, .08);
}

.role-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.role-card-desc {
    font-size: .8rem;
    text-align: center;
}

/* ===== User Photo ===== */
.user-photo {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

.user-avatar {
    position: relative;
}

.dropdown-user-info {
    padding: 12px;
    border-bottom: 1px solid #ffffff10;
    margin-bottom: 4px;
}

.dropdown-name {
    font-weight: 600;
    font-size: .95rem;
    margin-bottom: 2px;
}

.dropdown-email {
    font-size: .8rem;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.dropdown-role {
    display: inline-block;
    font-size: .7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: var(--accent);
    background: rgba(255, 107, 53, .15);
    padding: 2px 8px;
    border-radius: 500px;
}

.btn-primary {
    background: var(--accent);
    color: #000;
    padding: 10px 24px;
    border-radius: 500px;
    font-weight: 700;
    font-size: .9rem;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: scale(1.04);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    padding: 10px 24px;
    border-radius: 500px;
    font-weight: 700;
    font-size: .9rem;
    border: 1px solid #ffffff40;
    transition: all var(--transition);
}

.btn-outline:hover {
    border-color: #fff;
    transform: scale(1.04);
}

.btn-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all var(--transition);
    color: var(--text-secondary);
    flex-shrink: 0;
}

.btn-icon:hover {
    color: var(--text-primary);
    transform: scale(1.1);
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* ===== Greeting ===== */
.greeting-section {
    margin-bottom: 32px;
}

.greeting-section h1 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.quick-picks {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 8px;
}

.quick-pick {
    display: flex;
    align-items: center;
    background: #ffffff10;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
    transition: background var(--transition);
    height: 64px;
}

.quick-pick:hover {
    background: #ffffff20;
}

.quick-pick img {
    width: 64px;
    height: 64px;
    object-fit: cover;
}

.quick-pick-gradient {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quick-pick span {
    padding: 0 16px;
    font-weight: 700;
    font-size: .95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ===== Content Sections ===== */
.content-section {
    margin-bottom: 40px;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
}

.see-all {
    color: var(--text-secondary);
    font-size: .85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.see-all:hover {
    color: var(--text-primary);
}

/* ===== Cards ===== */
.card-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 16px;
    cursor: pointer;
    transition: all .3s ease;
    position: relative;
}

.card:hover {
    background: var(--bg-card-hover);
}

.card:hover .card-play {
    opacity: 1;
    transform: translateY(0);
}

.card-cover {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 12px;
    background: var(--bg-highlight);
}

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

.card-cover-gradient {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.card-play {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--accent);
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(8px);
    transition: all .3s ease;
    box-shadow: 0 8px 16px rgba(0,0,0,.3);
}

.card-play:hover {
    transform: scale(1.06) translateY(0);
    background: var(--accent-hover);
}

.card-title {
    font-weight: 700;
    font-size: .95rem;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-subtitle {
    color: var(--text-secondary);
    font-size: .85rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card.artist-card .card-cover {
    border-radius: 50%;
}

/* ===== Modal ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 32px;
    width: 90%;
    max-width: 420px;
    position: relative;
    box-shadow: var(--shadow-lg);
    max-height: 90vh;
    overflow-y: auto;
}

.modal-lg {
    max-width: 700px;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 1.5rem;
    color: var(--text-secondary);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.modal-close:hover {
    color: var(--text-primary);
    background: #ffffff15;
}

.modal h2 {
    font-size: 1.5rem;
    margin-bottom: 24px;
}

.modal-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 24px;
    background: #ffffff10;
    border-radius: 500px;
    padding: 4px;
}

.modal-tab {
    flex: 1;
    padding: 10px;
    border-radius: 500px;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.modal-tab.active {
    background: var(--accent);
    color: #000;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-form input,
.upload-form input,
.upload-form select,
.upload-form textarea,
#playlistForm input,
#playlistForm textarea {
    padding: 12px 16px;
    background: #ffffff10;
    border: 1px solid #ffffff20;
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: .95rem;
    transition: border-color var(--transition);
}

.auth-form input:focus,
.upload-form input:focus,
.upload-form select:focus,
.upload-form textarea:focus,
#playlistForm input:focus,
#playlistForm textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.role-select {
    display: flex;
    gap: 24px;
    padding: 8px 0;
    color: var(--text-secondary);
}

.role-select label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.role-select input[type="radio"] {
    accent-color: var(--accent);
}

/* ===== User Menu ===== */
.user-menu {
    position: relative;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gradient-4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .85rem;
    cursor: pointer;
}

.dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--bg-card-hover);
    border-radius: var(--radius-md);
    padding: 4px;
    min-width: 160px;
    box-shadow: var(--shadow-lg);
    z-index: 100;
}

.dropdown a {
    display: block;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: .9rem;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.dropdown a:hover {
    background: #ffffff10;
    color: var(--text-primary);
}

/* ===== Genre Grid ===== */
.genre-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.genre-card {
    aspect-ratio: 1.3;
    border-radius: var(--radius-lg);
    padding: 16px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform var(--transition);
}

.genre-card:hover {
    transform: scale(1.02);
}

.genre-card h3 {
    font-size: 1.3rem;
    font-weight: 800;
}

/* ===== Search ===== */
.search-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #ffffff15;
    border-radius: 500px;
    padding: 8px 16px;
    width: 360px;
}

.search-bar input {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: .95rem;
    width: 100%;
    outline: none;
}

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

.search-section {
    margin-bottom: 32px;
}

.search-section h3 {
    font-size: 1.2rem;
    margin-bottom: 16px;
}

/* ===== Library ===== */
.library-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.lib-tab {
    padding: 8px 16px;
    border-radius: 500px;
    font-weight: 600;
    font-size: .85rem;
    color: var(--text-primary);
    background: #ffffff10;
    transition: all var(--transition);
}

.lib-tab.active {
    background: var(--text-primary);
    color: var(--bg-primary);
}

.library-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

/* ===== Upload ===== */
.upload-grid {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.cover-upload {
    cursor: pointer;
}

.cover-preview {
    width: 200px;
    height: 200px;
    border: 2px dashed #ffffff30;
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--text-muted);
    transition: border-color var(--transition);
    overflow: hidden;
}

.cover-preview:hover {
    border-color: var(--accent);
}

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

.cover-preview span {
    font-size: .85rem;
}

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

.track-upload-section {
    margin-bottom: 24px;
}

.track-upload-section h3 {
    margin-bottom: 12px;
    font-size: 1.1rem;
}

.drop-zone {
    border: 2px dashed #ffffff20;
    border-radius: var(--radius-md);
    padding: 32px;
    text-align: center;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition);
}

.drop-zone:hover,
.drop-zone.dragover {
    border-color: var(--accent);
    background: rgba(255, 107, 53, .05);
}

.drop-zone p {
    margin-top: 8px;
}

.drop-zone .link {
    color: var(--accent);
    text-decoration: underline;
}

.drop-zone .hint {
    display: block;
    font-size: .8rem;
    margin-top: 4px;
    color: var(--text-muted);
}

.track-list-upload {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.track-upload-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: #ffffff08;
    border-radius: var(--radius-sm);
}

.track-upload-item .track-num {
    width: 24px;
    color: var(--text-muted);
    font-size: .85rem;
    text-align: center;
}

.track-upload-item input {
    flex: 1;
    padding: 6px 10px;
    background: #ffffff10;
    border: 1px solid transparent;
    border-radius: 4px;
    color: var(--text-primary);
    font-size: .85rem;
}

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

.track-upload-item .track-duration {
    color: var(--text-muted);
    font-size: .8rem;
    min-width: 40px;
}

.track-upload-item .remove-track {
    color: var(--text-muted);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 4px;
}

.track-upload-item .remove-track:hover {
    color: #e74c3c;
}

/* ===== Upload Type Tabs ===== */
.upload-type-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
}

.upload-type-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 16px;
    background: #ffffff08;
    border: 2px solid #ffffff15;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: .9rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
}

.upload-type-tab:hover {
    border-color: #ffffff30;
    color: var(--text-primary);
}

.upload-type-tab.active {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(255, 107, 53, .08);
}

/* ===== Single File Info ===== */
.single-file-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #ffffff08;
    border-radius: var(--radius-md);
    margin-bottom: 12px;
}

.single-file-info .file-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--accent);
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.single-file-info .file-details {
    flex: 1;
    overflow: hidden;
}

.single-file-info .file-name {
    font-weight: 600;
    font-size: .9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.single-file-info .file-meta {
    font-size: .8rem;
    color: var(--text-muted);
}

.single-file-info .file-remove {
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
}

.single-file-info .file-remove:hover {
    color: #ef4444;
}

/* ===== Track Reorder ===== */
.track-upload-item .drag-handle {
    cursor: grab;
    color: var(--text-muted);
    padding: 4px;
    display: flex;
    align-items: center;
}

.track-upload-item .drag-handle:hover {
    color: var(--text-primary);
}

.track-upload-item.dragging {
    opacity: .5;
    background: #ffffff15;
}

.track-upload-item.drag-over {
    border-top: 2px solid var(--accent);
}

/* ===== Edit Actions ===== */
.edit-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.btn-danger {
    background: transparent;
    color: #ef4444;
    border: 1px solid #ef4444;
    padding: 10px 24px;
    border-radius: 500px;
    font-weight: 700;
    font-size: .9rem;
    cursor: pointer;
    transition: all var(--transition);
}

.btn-danger:hover {
    background: #ef4444;
    color: #fff;
}

/* ===== Dashboard Cards with Edit ===== */
.dashboard-section {
    margin-bottom: 32px;
}

.dashboard-section h3 {
    font-size: 1.2rem;
    margin-bottom: 16px;
}

.card-actions {
    display: flex;
    gap: 6px;
    margin-top: 8px;
}

.card-action-btn {
    flex: 1;
    padding: 6px 0;
    border-radius: var(--radius-sm);
    font-size: .75rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition);
}

.card-action-btn.edit {
    background: #ffffff10;
    color: var(--text-secondary);
}

.card-action-btn.edit:hover {
    background: #ffffff20;
    color: var(--text-primary);
}

.card-action-btn.delete {
    background: rgba(239, 68, 68, .1);
    color: #ef4444;
}

.card-action-btn.delete:hover {
    background: rgba(239, 68, 68, .2);
}

.empty-state {
    padding: 40px;
    text-align: center;
    color: var(--text-muted);
    grid-column: 1 / -1;
}

.empty-state svg {
    margin-bottom: 12px;
    opacity: .4;
}

.empty-state p {
    margin-bottom: 16px;
}

/* ===== Dashboard Stats ===== */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.stat-card .stat-value {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 4px;
}

.stat-card .stat-label {
    color: var(--text-secondary);
    font-size: .85rem;
}

/* ===== Context Menu ===== */
.context-menu {
    position: fixed;
    background: var(--bg-card-hover);
    border-radius: var(--radius-md);
    padding: 4px;
    min-width: 180px;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
}

.context-menu button {
    display: block;
    width: 100%;
    text-align: left;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: .9rem;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.context-menu button:hover {
    background: #ffffff10;
    color: var(--text-primary);
}

/* ===== Toast ===== */
.toast {
    position: fixed;
    bottom: calc(var(--player-height) + 16px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: #000;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    z-index: 9999;
    animation: toastIn .3s ease, toastOut .3s ease 2.7s forwards;
}

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

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

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .upload-grid {
        grid-template-columns: 1fr;
    }
    .cover-upload {
        justify-self: center;
    }
}

@media (max-width: 768px) {
    .app {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr auto auto;
    }
    .sidebar {
        display: none;
    }
    .main-content {
        margin: 0;
        border-radius: 0;
        padding-bottom: 60px;
    }
    .quick-picks {
        grid-template-columns: 1fr;
    }
    .card-row {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }
    .search-bar {
        width: 200px;
    }
    .page-header {
        padding: 12px 0;
    }
    .greeting-section h1 {
        font-size: 1.5rem;
    }
    .modal {
        width: 95%;
        padding: 20px;
        max-height: 85vh;
    }
    .modal-lg {
        max-width: 95%;
    }
    .upload-grid {
        grid-template-columns: 1fr;
    }
    .cover-preview {
        width: 150px;
        height: 150px;
        margin: 0 auto;
    }
    .cover-upload {
        justify-self: center;
    }
    .role-cards {
        flex-direction: column;
    }

    /* Mobile Bottom Nav */
    .mobile-nav {
        display: flex !important;
    }
}

/* ===== Mobile Bottom Navigation ===== */
.mobile-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-top: 1px solid #ffffff10;
    z-index: 60;
    justify-content: space-around;
    padding: 6px 0;
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 12px;
    color: var(--text-muted);
    font-size: .65rem;
    font-weight: 600;
    cursor: pointer;
    transition: color var(--transition);
    background: none;
    border: none;
}

.mobile-nav-item.active {
    color: var(--text-primary);
}

.mobile-nav-item svg {
    width: 22px;
    height: 22px;
}
