*{margin:0;padding:0;box-sizing:border-box}
:root{--bg:#0f0a1a;--surface:#1a1230;--surface2:#241b3d;--border:#2d2250;--text:#e8e0f0;--text2:#a094b8;--accent:#6C5CE7;--accent2:#8b7cf7;--gold:#FFB800;--green:#00C9A7;--red:#ff6b6b;--sidebar-w:240px;--player-h:90px}
body{font-family:'Space Grotesk',sans-serif;background:var(--bg);color:var(--text);min-height:100vh;overflow-x:hidden}

/* Sidebar */
.sidebar{position:fixed;top:0;left:0;width:var(--sidebar-w);height:100vh;background:var(--surface);border-right:1px solid var(--border);display:flex;flex-direction:column;z-index:50;padding:20px 0}
.sidebar-top{padding:0 20px 20px}
.sidebar-logo{display:flex;align-items:center;gap:10px}
.logo-img{width:36px;height:36px;border-radius:8px;mix-blend-mode:lighten}
.logo-text{font-size:1.2rem;font-weight:700}
.sidebar-nav{flex:1;padding:0 10px}
.nav-item{display:flex;align-items:center;gap:12px;padding:10px 14px;border-radius:8px;color:var(--text2);text-decoration:none;font-size:.9rem;font-weight:500;transition:background .15s,color .15s;margin-bottom:2px}
.nav-item:hover{background:var(--surface2);color:var(--text)}
.nav-item.active{background:var(--accent);color:#fff}
.nav-item svg{flex-shrink:0}
.sidebar-bottom{padding:10px 14px}
.btn-pro-sidebar{width:100%;padding:10px;border:none;border-radius:8px;background:linear-gradient(135deg,var(--gold),#e6a600);color:#1a1230;font-weight:700;font-size:.85rem;cursor:pointer;font-family:inherit;transition:transform .15s}
.btn-pro-sidebar:hover{transform:translateY(-1px)}
.btn-download-app{display:flex;align-items:center;gap:10px;width:100%;padding:12px 14px;border:1px solid var(--border);border-radius:10px;background:var(--surface2);color:var(--text);font-family:inherit;font-size:.85rem;font-weight:600;cursor:pointer;text-decoration:none;transition:border-color .15s,background .15s,transform .15s}
.btn-download-app:hover{border-color:var(--accent);background:rgba(108,92,231,.1);transform:translateY(-1px)}
.btn-download-app svg{color:var(--accent);flex-shrink:0}

/* Main Content */
.main-content{margin-left:var(--sidebar-w);padding:24px 32px;padding-bottom:calc(var(--player-h) + 24px);min-height:100vh}
.page{display:none}
.page.active{display:block}
.page-header{margin-bottom:24px}
.page-header h1{font-size:1.8rem;margin-bottom:4px}
.page-header p{color:var(--text2);font-size:.95rem}

/* Search */
.search-bar-hero,.search-bar-page{display:flex;align-items:center;gap:12px;background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:14px 18px;margin-bottom:24px}
.search-bar-hero input,.search-bar-page input{flex:1;background:none;border:none;color:var(--text);font-family:inherit;font-size:1rem;outline:none}
.search-bar-hero input::placeholder,.search-bar-page input::placeholder{color:var(--text2)}
.search-bar-hero svg,.search-bar-page svg{color:var(--text2);flex-shrink:0}

/* Quick Actions */
.quick-actions{display:flex;gap:12px;margin-bottom:24px}
.quick-action{display:flex;align-items:center;gap:10px;padding:16px 24px;background:var(--surface);border:1px solid var(--border);border-radius:12px;color:var(--text);font-family:inherit;font-size:.9rem;font-weight:600;cursor:pointer;transition:border-color .15s}
.quick-action:hover{border-color:var(--accent)}
.quick-action svg{color:var(--accent)}

/* Source Tabs */
.source-tabs{display:flex;gap:4px;background:var(--surface);border:1px solid var(--border);border-radius:10px;padding:4px;margin-bottom:20px}
.source-tab{flex:1;padding:8px 12px;border:none;background:transparent;color:var(--text2);font-family:inherit;font-size:.85rem;font-weight:600;border-radius:7px;cursor:pointer;transition:background .15s,color .15s}
.source-tab:hover{color:var(--text)}
.source-tab.active{background:var(--accent);color:#fff}

.source-tab[data-source="foryou"]{position:relative}
.source-tab[data-source="foryou"]::after{content:'';display:inline-block;width:6px;height:6px;border-radius:50%;background:var(--gold);margin-left:6px;vertical-align:middle}

/* Track List */
.track-list{display:flex;flex-direction:column;gap:2px}
.track-item{display:flex;align-items:center;gap:12px;padding:10px 14px;border-radius:8px;cursor:pointer;transition:background .15s}
.track-item:hover{background:var(--surface)}
.track-item.playing{background:var(--surface2)}
.track-thumb{width:44px;height:44px;border-radius:6px;object-fit:cover;background:var(--surface2);flex-shrink:0}
.track-info{flex:1;min-width:0}
.track-title{font-size:.9rem;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.track-artist{font-size:.8rem;color:var(--text2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.track-source{font-size:.65rem;padding:2px 6px;border-radius:4px;font-weight:600;text-transform:uppercase;flex-shrink:0}
.track-source.youtube{background:#ff000020;color:#ff4444}
.track-source.soundcloud{background:#ff550020;color:#ff7700}
.track-source.spotify{background:#1db95420;color:#1db954}
.track-source.local{background:#6C5CE720;color:var(--accent2)}
.track-duration{font-size:.8rem;color:var(--text2);flex-shrink:0;min-width:40px;text-align:right}
.track-actions{display:flex;gap:4px;flex-shrink:0}
.track-action-btn{background:none;border:none;color:var(--text2);cursor:pointer;padding:4px;border-radius:4px;transition:color .15s}
.track-action-btn:hover{color:var(--accent)}

/* Search Results */
.search-results{min-height:200px}
.search-placeholder{text-align:center;color:var(--text2);padding:60px 0;font-size:.95rem}
.search-loading{text-align:center;padding:40px 0;color:var(--text2)}

/* Library */
.library-section{margin-bottom:32px}
.library-section h2{font-size:1.1rem;margin-bottom:12px;color:var(--text2)}
.playlist-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:14px}
.playlist-card{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:16px;cursor:pointer;transition:border-color .15s}
.playlist-card:hover{border-color:var(--accent)}
.playlist-card-name{font-weight:600;font-size:.95rem;margin-bottom:4px}
.playlist-card-meta{font-size:.8rem;color:var(--text2)}
.btn-new-playlist{display:flex;align-items:center;gap:6px;background:var(--accent);color:#fff;border:none;padding:8px 16px;border-radius:8px;font-family:inherit;font-size:.85rem;font-weight:600;cursor:pointer;transition:background .15s}
.btn-new-playlist:hover{background:var(--accent2)}

/* Playlist View */
.playlist-header{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:24px;margin-bottom:20px;display:flex;align-items:center;gap:20px}
.playlist-header-info{flex:1}
.playlist-header-name{font-size:1.5rem;font-weight:700;margin-bottom:4px}
.playlist-header-meta{color:var(--text2);font-size:.85rem}
.playlist-header-actions{display:flex;gap:8px}

/* Settings */
.settings-section{margin-bottom:28px}
.settings-section h2{font-size:1.1rem;margin-bottom:12px;color:var(--text2)}
.settings-card{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:20px}
.settings-card input[type=email],.settings-card input[type=password],.settings-card input[type=text]{width:100%;padding:10px 12px;border-radius:8px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-family:inherit;font-size:.9rem;margin-bottom:10px}
.settings-card input:focus{outline:none;border-color:var(--accent)}
.settings-card .btn{display:inline-flex;align-items:center;gap:6px;padding:10px 18px;border:none;border-radius:8px;font-family:inherit;font-size:.85rem;font-weight:600;cursor:pointer;transition:background .15s}
.btn-primary{background:var(--accent);color:#fff}
.btn-primary:hover{background:var(--accent2)}
.btn-gold{background:linear-gradient(135deg,var(--gold),#e6a600);color:#1a1230}
.btn-secondary{background:var(--surface2);color:var(--text);border:1px solid var(--border)!important}
.settings-card p{color:var(--text2);font-size:.85rem;margin-bottom:10px}
.settings-card .pro-badge-large{display:inline-block;background:var(--gold);color:#1a1230;padding:3px 10px;border-radius:6px;font-weight:700;font-size:.8rem;margin-bottom:8px}

/* Bottom Player */
.bottom-player{position:fixed;bottom:0;left:0;right:0;height:var(--player-h);background:var(--surface);border-top:1px solid var(--border);display:grid;grid-template-columns:240px 1fr 200px;align-items:center;padding:12px 16px 0;z-index:100;gap:4px 16px}
.player-track-info{display:flex;align-items:center;gap:12px;min-width:0}
.player-thumb{width:48px;height:48px;border-radius:6px;object-fit:cover;background:var(--surface2);mix-blend-mode:lighten}
.player-meta{min-width:0}
.player-title{font-size:.85rem;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:260px}
.player-artist{font-size:.75rem;color:var(--text2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer;transition:color .15s}
.player-artist:hover{color:var(--accent);text-decoration:underline}
.player-controls{display:flex;align-items:center;justify-content:center;gap:12px}
.player-btn{background:none;border:none;color:var(--text2);cursor:pointer;padding:6px;border-radius:50%;transition:color .15s}
.player-btn:hover{color:var(--text)}
.player-btn.active{color:var(--accent)}
.player-btn-main{background:var(--accent);color:#fff!important;width:40px;height:40px;display:flex;align-items:center;justify-content:center;border-radius:50%}
.player-btn-main:hover{background:var(--accent2)}
.player-progress-area{display:flex;align-items:center;gap:8px;grid-column:1/-1;order:3;padding:0 4px}
.player-progress-bar{flex:1;height:4px;background:var(--border);border-radius:2px;cursor:pointer;position:relative}
.player-progress-fill{height:100%;background:var(--accent);border-radius:2px;width:0%;transition:width .3s}
.player-time{font-size:.7rem;color:var(--text2);min-width:36px}
.player-time:last-child{text-align:right}
.player-volume{display:flex;align-items:center;gap:8px;justify-content:flex-end}
.player-volume svg{color:var(--text2);flex-shrink:0}
.player-volume input[type=range]{width:100px;-webkit-appearance:none;appearance:none;height:4px;border-radius:2px;background:var(--border);outline:none}
.player-volume input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:14px;height:14px;border-radius:50%;background:var(--accent);cursor:pointer}

/* Mobile Tabs */
.mobile-tabs{display:none;position:fixed;bottom:0;left:0;right:0;background:var(--surface);border-top:1px solid var(--border);z-index:101;padding:6px 0 env(safe-area-inset-bottom)}
.mob-tab{display:flex;flex-direction:column;align-items:center;gap:2px;padding:6px 0;color:var(--text2);text-decoration:none;font-size:.65rem;font-weight:600;flex:1}
.mob-tab.active{color:var(--accent)}

.hidden{display:none!important}

/* Auth Gate */
.auth-gate{position:fixed;inset:0;background:var(--bg);z-index:10000;display:flex;align-items:center;justify-content:center;padding:24px}
.auth-gate.hidden{display:none!important}
.auth-card{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:40px;max-width:440px;width:100%;text-align:center;animation:slideUp .3s ease}
.auth-logo{width:64px;height:64px;border-radius:16px;margin-bottom:16px;mix-blend-mode:lighten}
.auth-title{font-size:1.8rem;font-weight:700;margin-bottom:4px}
.auth-sub{color:var(--text2);font-size:.95rem;margin-bottom:24px}
.auth-tabs{display:flex;gap:4px;background:var(--surface2);border-radius:10px;padding:4px;margin-bottom:20px}
.auth-tab{flex:1;padding:10px;border:none;background:transparent;color:var(--text2);font-family:inherit;font-size:.85rem;font-weight:600;border-radius:7px;cursor:pointer;transition:background .15s,color .15s}
.auth-tab.active{background:var(--accent);color:#fff}
.auth-panel{display:none}
.auth-panel.active{display:block}
.auth-panel input{width:100%;padding:14px 16px;border-radius:12px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-family:'Courier New',monospace;font-size:.9rem;margin-bottom:12px;outline:none;transition:border-color .15s}
.auth-panel input:focus{border-color:var(--accent)}
.auth-panel input::placeholder{color:var(--text2);font-family:'Space Grotesk',sans-serif}
.auth-btn{width:100%;padding:14px;border:none;border-radius:12px;background:var(--accent);color:#fff;font-family:inherit;font-size:.95rem;font-weight:700;cursor:pointer;transition:background .15s,transform .1s}
.auth-btn:hover{background:var(--accent2)}
.auth-btn:active{transform:scale(.98)}
.auth-btn-gold{background:linear-gradient(135deg,var(--gold),#e6a600);color:#1a1230}
.auth-btn-gold:hover{background:linear-gradient(135deg,#e6a600,var(--gold))}
.auth-error{color:var(--red);font-size:.85rem;margin-top:8px;text-align:center}
.auth-price{margin-bottom:16px}
.auth-amount{font-size:2.4rem;font-weight:700;color:var(--gold)}
.auth-period{font-size:1rem;color:var(--text2);margin-left:2px}
.auth-perks{list-style:none;text-align:left;margin-bottom:20px}
.auth-perks li{padding:8px 0;color:var(--text);font-size:.9rem;display:flex;align-items:center;gap:10px}
.auth-perks li::before{content:'';display:block;width:20px;height:20px;border-radius:50%;background:rgba(0,201,167,.15);flex-shrink:0;background-image:url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2300C9A7' stroke-width='3' xmlns='http://www.w3.org/2000/svg'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:center;background-size:12px}
.auth-footer{color:var(--text2);font-size:.8rem;margin-top:14px}
.auth-plans{display:flex;gap:10px;margin-bottom:20px}
.auth-plan{flex:1;background:var(--surface2);border:2px solid var(--border);border-radius:14px;padding:16px 12px;cursor:pointer;transition:border-color .15s,background .15s;text-align:center;position:relative}
.auth-plan:hover{border-color:var(--accent)}
.auth-plan.active{border-color:var(--accent);background:rgba(108,92,231,.1)}
.auth-plan-name{font-size:.8rem;color:var(--text2);font-weight:600;margin-bottom:6px;text-transform:uppercase;letter-spacing:.5px}
.auth-plan-price .auth-amount{font-size:1.8rem;font-weight:700;color:var(--text)}
.auth-plan-price .auth-period{font-size:.85rem;color:var(--text2)}
.auth-plan.active .auth-plan-price .auth-amount{color:var(--accent2)}
.auth-plan-badge{position:absolute;top:-10px;right:-6px;background:var(--gold);color:#1a1230;font-size:.65rem;font-weight:700;padding:3px 8px;border-radius:20px;text-transform:uppercase}

/* Crypto Payment */
.crypto-wallets{display:flex;flex-direction:column;gap:6px;margin-bottom:14px}
.crypto-wallet{display:flex;align-items:center;gap:8px;background:var(--surface2);border:1px solid var(--border);border-radius:10px;padding:10px 12px;transition:border-color .15s}
.crypto-wallet-btn{cursor:pointer;justify-content:space-between}
.crypto-wallet-btn:hover{border-color:var(--accent);background:rgba(108,92,231,.08)}
.crypto-label{font-size:.8rem;font-weight:700;display:flex;align-items:center;gap:6px}
.crypto-icon{font-size:1.1rem}
.crypto-addr{flex:1;font-family:'Courier New',monospace;font-size:.65rem;color:var(--text2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:left}
.crypto-copy{background:var(--accent);color:#fff;border:none;padding:4px 10px;border-radius:6px;font-size:.7rem;font-weight:600;cursor:pointer;font-family:inherit;flex-shrink:0;transition:background .15s}
.crypto-copy:hover{background:var(--accent2)}
.crypto-instructions{text-align:left;margin-bottom:14px}
.crypto-instructions p{color:var(--text2);font-size:.8rem;padding:3px 0;line-height:1.4}
.crypto-verify-form{display:flex;flex-direction:column;gap:10px}
.crypto-select{width:100%;padding:12px 14px;border-radius:12px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-family:inherit;font-size:.9rem;outline:none;appearance:none;-webkit-appearance:none;cursor:pointer;transition:border-color .15s}
.crypto-select:focus{border-color:var(--accent)}
.crypto-verify-form input{width:100%;padding:12px 14px;border-radius:12px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-family:'Courier New',monospace;font-size:.85rem;outline:none;transition:border-color .15s}
.crypto-verify-form input[type=email]{font-family:inherit}
.crypto-verify-form input:focus{border-color:var(--accent)}
.crypto-verify-form input::placeholder{color:var(--text2);font-family:'Space Grotesk',sans-serif}
.crypto-success{background:rgba(0,201,167,.1);border:1px solid var(--green);border-radius:12px;padding:14px;text-align:center}
.crypto-success .crypto-key{font-family:'Courier New',monospace;font-size:.85rem;color:var(--green);word-break:break-all;margin:8px 0;user-select:all}

/* Crypto Payment Modal */
.crypto-pay-overlay{position:fixed;inset:0;background:rgba(0,0,0,.7);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);z-index:10001;display:flex;align-items:center;justify-content:center;padding:20px;animation:fadeIn .15s ease}
.crypto-pay-modal{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:32px;max-width:440px;width:100%;animation:slideUp .2s ease;box-shadow:0 24px 64px rgba(0,0,0,.5)}
.crypto-pay-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:24px}
.crypto-pay-header h2{font-size:1.2rem;font-weight:700;display:flex;align-items:center;gap:8px}
.crypto-pay-close{background:none;border:none;color:var(--text2);font-size:1.4rem;cursor:pointer;width:32px;height:32px;border-radius:8px;display:flex;align-items:center;justify-content:center;transition:background .15s}
.crypto-pay-close:hover{background:var(--surface2);color:var(--text)}
.crypto-pay-amount{text-align:center;background:var(--surface2);border:1px solid var(--border);border-radius:14px;padding:20px;margin-bottom:20px}
.crypto-pay-amount .crypto-coin-amount{font-size:1.8rem;font-weight:700;color:var(--text);margin-bottom:4px;user-select:all}
.crypto-pay-amount .crypto-usd-amount{font-size:.9rem;color:var(--text2)}
.crypto-pay-amount .crypto-copy-amount{margin-top:10px;display:inline-flex;align-items:center;gap:6px;background:var(--accent);color:#fff;border:none;padding:8px 16px;border-radius:8px;font-size:.8rem;font-weight:600;cursor:pointer;font-family:inherit;transition:background .15s}
.crypto-pay-amount .crypto-copy-amount:hover{background:var(--accent2)}
.crypto-pay-address{background:var(--surface2);border:1px solid var(--border);border-radius:12px;padding:14px;margin-bottom:20px}
.crypto-pay-address-label{font-size:.75rem;color:var(--text2);margin-bottom:6px;text-transform:uppercase;font-weight:600;letter-spacing:.5px}
.crypto-pay-address-row{display:flex;align-items:center;gap:8px}
.crypto-pay-address-text{flex:1;font-family:'Courier New',monospace;font-size:.75rem;color:var(--text);word-break:break-all;user-select:all}
.crypto-pay-address-copy{background:var(--accent);color:#fff;border:none;padding:6px 12px;border-radius:6px;font-size:.75rem;font-weight:600;cursor:pointer;font-family:inherit;flex-shrink:0;transition:background .15s}
.crypto-pay-address-copy:hover{background:var(--accent2)}
.crypto-pay-sent{width:100%;padding:14px;border:none;border-radius:12px;background:var(--green);color:#fff;font-family:inherit;font-size:.95rem;font-weight:700;cursor:pointer;transition:background .15s,transform .1s;margin-bottom:12px}
.crypto-pay-sent:hover{background:#00b396}
.crypto-pay-sent:active{transform:scale(.98)}
.crypto-pay-verify{display:none;flex-direction:column;gap:10px;animation:slideUp .2s ease}
.crypto-pay-verify.show{display:flex}
.crypto-pay-verify input{width:100%;padding:12px 14px;border-radius:12px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-size:.85rem;outline:none;transition:border-color .15s}
.crypto-pay-verify input::placeholder{color:var(--text2)}
.crypto-pay-verify input:focus{border-color:var(--accent)}
.crypto-pay-verify input.tx-hash{font-family:'Courier New',monospace;font-size:.8rem}
.crypto-pay-verify-btn{width:100%;padding:14px;border:none;border-radius:12px;background:var(--accent);color:#fff;font-family:inherit;font-size:.95rem;font-weight:700;cursor:pointer;transition:background .15s}
.crypto-pay-verify-btn:hover{background:var(--accent2)}
.crypto-pay-error{color:var(--red);font-size:.85rem;text-align:center}
.crypto-pay-success{background:rgba(0,201,167,.1);border:1px solid var(--green);border-radius:12px;padding:16px;text-align:center}

/* Responsive */
@media(max-width:768px){
  .sidebar{display:none}
  .main-content{margin-left:0;padding:16px;padding-bottom:calc(var(--player-h) + 70px)}
  .mobile-tabs{display:flex}
  .bottom-player{grid-template-columns:1fr auto 1fr;height:auto;padding:8px 12px;gap:8px}
  .player-track-info{order:1}
  .player-controls{order:2;gap:8px}
  .player-progress-area{order:3;padding:0}
  .player-volume{display:none}
  .quick-actions{flex-direction:column}
}

/* Modal */
.modal-overlay{position:fixed;inset:0;background:rgba(0,0,0,.6);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);z-index:200;display:flex;align-items:center;justify-content:center;padding:20px;animation:fadeIn .15s ease}
@keyframes fadeIn{from{opacity:0}to{opacity:1}}
@keyframes slideUp{from{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}
.modal{background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:28px;max-width:420px;width:100%;max-height:80vh;overflow-y:auto;animation:slideUp .2s ease;box-shadow:0 24px 64px rgba(0,0,0,.4)}
.modal h2{font-size:1.15rem;margin-bottom:16px;font-weight:700}
.modal-close{float:right;background:none;border:none;color:var(--text2);font-size:1.3rem;cursor:pointer;width:32px;height:32px;border-radius:8px;display:flex;align-items:center;justify-content:center;transition:background .15s,color .15s}
.modal-close:hover{background:var(--surface2);color:var(--text)}
.modal-list{display:flex;flex-direction:column;gap:6px}
.modal-list-item{display:flex;align-items:center;gap:12px;padding:12px 14px;background:var(--surface2);border:1px solid var(--border);border-radius:10px;cursor:pointer;transition:border-color .15s,background .15s;font-size:.9rem;font-weight:500}
.modal-list-item:hover{border-color:var(--accent);background:rgba(108,92,231,.1)}
.modal-list-item .pl-icon{width:36px;height:36px;border-radius:8px;background:var(--accent);display:flex;align-items:center;justify-content:center;flex-shrink:0;color:#fff}
.modal-list-item .pl-details{flex:1;min-width:0}
.modal-list-item .pl-name{font-weight:600;font-size:.9rem}
.modal-list-item .pl-count{font-size:.75rem;color:var(--text2)}
.modal-divider{height:1px;background:var(--border);margin:14px 0}
.modal-input-row{display:flex;gap:8px}
.modal-input-row input{flex:1;padding:10px 14px;border-radius:10px;border:1px solid var(--border);background:var(--surface2);color:var(--text);font-family:inherit;font-size:.9rem;outline:none;transition:border-color .15s}
.modal-input-row input:focus{border-color:var(--accent)}
.modal-input-row input::placeholder{color:var(--text2)}
.modal-input-row button{padding:10px 18px;border-radius:10px;border:none;background:var(--accent);color:#fff;font-family:inherit;font-weight:600;font-size:.85rem;cursor:pointer;white-space:nowrap;transition:background .15s}
.modal-input-row button:hover{background:var(--accent2)}
.modal-toast{position:fixed;bottom:120px;left:50%;transform:translateX(-50%);background:var(--green);color:#fff;padding:10px 24px;border-radius:10px;font-size:.85rem;font-weight:600;z-index:300;animation:slideUp .2s ease;pointer-events:none}

/* Library Upload */
.library-actions{display:flex;gap:10px;margin-bottom:20px;flex-wrap:wrap}
.btn-upload-lib{display:flex;align-items:center;gap:8px;background:var(--surface);border:1px solid var(--border);color:var(--text);padding:10px 18px;border-radius:10px;font-family:inherit;font-size:.85rem;font-weight:600;cursor:pointer;transition:border-color .15s,background .15s}
.btn-upload-lib:hover{border-color:var(--accent);background:rgba(108,92,231,.08)}
.btn-upload-lib svg{color:var(--accent)}

/* Playlist Header Modern */
.playlist-header{background:linear-gradient(135deg,var(--surface) 0%,var(--surface2) 100%);border:1px solid var(--border);border-radius:16px;padding:28px;margin-bottom:20px;display:flex;align-items:center;gap:20px}
.playlist-header-icon{width:64px;height:64px;border-radius:14px;background:var(--accent);display:flex;align-items:center;justify-content:center;flex-shrink:0}
.playlist-header-icon svg{color:#fff}
.playlist-header-name{font-size:1.6rem;font-weight:700;margin-bottom:4px}
.playlist-header-meta{color:var(--text2);font-size:.85rem}
.playlist-header-actions{display:flex;gap:8px}
.playlist-header-actions .btn{padding:10px 20px;border-radius:10px;font-size:.85rem;font-weight:600;border:none;cursor:pointer;font-family:inherit;display:flex;align-items:center;gap:6px;transition:background .15s,transform .1s}
.playlist-header-actions .btn:active{transform:scale(.97)}
.playlist-header-actions .btn-play-all{background:var(--accent);color:#fff}
.playlist-header-actions .btn-play-all:hover{background:var(--accent2)}
.playlist-header-actions .btn-delete{background:var(--surface);color:var(--red);border:1px solid var(--border)}
.playlist-header-actions .btn-delete:hover{background:rgba(255,107,107,.1)}

/* Playlist Card Modern */
.playlist-card{background:var(--surface);border:1px solid var(--border);border-radius:14px;padding:20px;cursor:pointer;transition:border-color .15s,transform .15s,box-shadow .15s}
.playlist-card:hover{border-color:var(--accent);transform:translateY(-2px);box-shadow:0 8px 24px rgba(108,92,231,.15)}
.playlist-card-icon{width:48px;height:48px;border-radius:10px;background:linear-gradient(135deg,var(--accent),var(--accent2));display:flex;align-items:center;justify-content:center;margin-bottom:12px}
.playlist-card-icon svg{color:#fff}
.playlist-card-name{font-weight:700;font-size:1rem;margin-bottom:4px}
.playlist-card-meta{font-size:.8rem;color:var(--text2)}

/* Playlist Cover Edit */
/* Stats Page */
.stats-grid{display:flex;flex-direction:column;gap:24px}
.stats-section{background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:24px}
.stats-section-title{display:flex;align-items:center;gap:8px;font-size:1rem;font-weight:700;margin-bottom:16px;color:var(--text)}
.stats-section-title svg{color:var(--accent)}
.stats-empty{color:var(--text2);font-size:.9rem;text-align:center;padding:20px 0}
.stats-rank-list{display:flex;flex-direction:column;gap:8px}
.stats-rank-item{display:flex;align-items:center;gap:12px;padding:10px 14px;background:var(--surface2);border:1px solid var(--border);border-radius:10px;transition:border-color .15s}
.stats-rank-item:hover{border-color:var(--accent)}
.stats-rank-num{width:28px;height:28px;border-radius:8px;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:.85rem;background:var(--surface);border:1px solid var(--border);flex-shrink:0}
.stats-rank-num.gold{background:linear-gradient(135deg,#FFD700,#FFA500);color:#1a1230;border-color:#FFD700}
.stats-rank-num.silver{background:linear-gradient(135deg,#C0C0C0,#A0A0A0);color:#1a1230;border-color:#C0C0C0}
.stats-rank-num.bronze{background:linear-gradient(135deg,#CD7F32,#B8691A);color:#1a1230;border-color:#CD7F32}
.stats-rank-info{flex:1;min-width:0}
.stats-rank-name{font-weight:600;font-size:.9rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.stats-rank-detail{font-size:.75rem;color:var(--text2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.stats-rank-bar-wrap{width:80px;height:6px;background:var(--surface);border-radius:3px;overflow:hidden;flex-shrink:0}
.stats-rank-bar{height:100%;background:linear-gradient(90deg,var(--accent),var(--accent2));border-radius:3px;transition:width .3s}
.stats-rank-count{font-size:.8rem;color:var(--text2);text-align:right;min-width:60px;flex-shrink:0}
.stats-chart{display:flex;align-items:flex-end;gap:3px;height:120px;padding:8px 0}
.stats-bar-col{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;height:100%;position:relative}
.stats-bar{background:linear-gradient(180deg,var(--accent),var(--accent2));border-radius:3px 3px 0 0;min-width:6px;width:100%;max-width:16px;transition:height .3s;position:relative;cursor:pointer}
.stats-bar:hover{opacity:.85}
.stats-bar-tooltip{display:none;position:absolute;bottom:calc(100% + 6px);left:50%;transform:translateX(-50%);background:var(--surface);border:1px solid var(--border);border-radius:6px;padding:4px 8px;font-size:.7rem;white-space:nowrap;z-index:10;color:var(--text)}
.stats-bar:hover .stats-bar-tooltip{display:block}
.stats-chart-labels{display:flex;gap:3px;font-size:.6rem;color:var(--text2)}
.stats-chart-labels span{flex:1;text-align:center}

/* Profile Page */
.profile-card{background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:32px;display:flex;align-items:center;gap:24px}
.profile-avatar-wrap{position:relative;cursor:pointer;flex-shrink:0}
.profile-avatar{width:96px;height:96px;border-radius:50%;object-fit:cover;border:3px solid var(--accent);display:block}
.profile-avatar-edit{position:absolute;bottom:0;right:0;width:28px;height:28px;border-radius:50%;background:var(--accent);border:2px solid var(--surface);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0}
.profile-info{flex:1;min-width:0}
.profile-username{font-size:1.4rem;font-weight:700;cursor:pointer;display:flex;align-items:center;gap:8px;margin-bottom:4px}
.profile-username:hover{color:var(--accent2)}
.profile-username-edit{color:var(--text2)}
.profile-meta{color:var(--text2);font-size:.85rem;margin-bottom:16px}
.profile-stats-row{display:flex;gap:20px;flex-wrap:wrap}
.profile-stat{text-align:center}
.profile-stat-value{font-size:1.1rem;font-weight:700;color:var(--accent)}
.profile-stat-label{font-size:.75rem;color:var(--text2);margin-top:2px}

/* Leaderboard Page */
.lb-loading,.lb-empty{text-align:center;padding:40px 20px;color:var(--text2)}
.lb-empty{display:flex;flex-direction:column;align-items:center}
.lb-list{display:flex;flex-direction:column;gap:8px}
.lb-item{display:flex;align-items:center;gap:12px;padding:14px 18px;background:var(--surface);border:1px solid var(--border);border-radius:12px;transition:border-color .15s,transform .15s}
.lb-item:hover{border-color:var(--accent);transform:translateX(2px)}
.lb-gold{background:linear-gradient(135deg,rgba(255,215,0,.12),rgba(255,165,0,.06))!important;border-color:rgba(255,215,0,.4)!important;box-shadow:0 0 20px rgba(255,215,0,.1)}
.lb-silver{background:linear-gradient(135deg,rgba(192,192,192,.12),rgba(160,160,160,.06))!important;border-color:rgba(192,192,192,.4)!important;box-shadow:0 0 20px rgba(192,192,192,.08)}
.lb-bronze{background:linear-gradient(135deg,rgba(205,127,50,.12),rgba(184,105,26,.06))!important;border-color:rgba(205,127,50,.4)!important;box-shadow:0 0 20px rgba(205,127,50,.08)}
.lb-you{border-color:var(--accent)!important}
.lb-crown{font-size:1.4rem;width:32px;text-align:center;flex-shrink:0}
.lb-rank{width:32px;text-align:center;font-weight:700;font-size:.9rem;color:var(--text2);flex-shrink:0}
.lb-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;flex-shrink:0;border:2px solid var(--border)}
.lb-gold .lb-avatar{border-color:rgba(255,215,0,.5)}
.lb-silver .lb-avatar{border-color:rgba(192,192,192,.5)}
.lb-bronze .lb-avatar{border-color:rgba(205,127,50,.5)}
.lb-info{flex:1;min-width:0}
.lb-name{font-weight:600;font-size:.95rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.lb-time{font-size:.8rem;color:var(--text2)}
.lb-bar-wrap{width:100px;height:6px;background:var(--surface2);border-radius:3px;overflow:hidden;flex-shrink:0}
.lb-bar{height:100%;background:linear-gradient(90deg,var(--accent),var(--accent2));border-radius:3px;transition:width .3s}
.lb-gold .lb-bar{background:linear-gradient(90deg,#FFD700,#FFA500)}
.lb-silver .lb-bar{background:linear-gradient(90deg,#C0C0C0,#A0A0A0)}
.lb-bronze .lb-bar{background:linear-gradient(90deg,#CD7F32,#B8691A)}

@media(max-width:768px){
  .profile-card{flex-direction:column;text-align:center}
  .profile-stats-row{justify-content:center}
  .lb-bar-wrap{display:none}
  .stats-rank-bar-wrap{display:none}
}

.pl-cover-edit{position:absolute;bottom:-4px;right:-4px;width:26px;height:26px;border-radius:50%;background:var(--accent);border:2px solid var(--surface);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0;transition:background .15s,transform .15s;z-index:2}
.pl-cover-edit:hover{background:var(--accent2);transform:scale(1.1)}
