:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #13131a;
    --bg-tertiary: #1a1a24;
    --accent-primary: #ff3366;
    --accent-secondary: #00d9ff;
    --text-primary: #ffffff;
    --text-secondary: #b4b4c8;
    --text-tertiary: #6e6e8f;
    --border-color: rgba(255, 255, 255, 0.08);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.6);
    --shadow-glow: 0 0 30px rgba(255, 51, 102, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

header {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(20px);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -1px;
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    font-size: 15px;
}

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

.install-btn {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    border-radius: 12px;
    padding: 10px 20px;
    color: white;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
    box-shadow: var(--shadow-glow);
}

.install-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 40px rgba(255, 51, 102, 0.5);
}

.install-btn:active {
    transform: translateY(0);
}

.install-btn.hidden {
    display: none;
}

.hero {
    padding: 80px 0 60px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.hero h1 {
    font-size: 64px;
    font-weight: 900;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -2px;
}

.hero p {
    font-size: 20px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
}

.live-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 51, 102, 0.1);
    border: 1px solid var(--accent-primary);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    color: var(--accent-primary);
}

.live-dot {
    width: 8px;
    height: 8px;
    background: var(--accent-primary);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

.player-section {
    padding: 60px 0;
}

.player-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 48px;
    box-shadow: var(--shadow-lg);
    max-width: 900px;
    margin: 0 auto;
}

.player-grid {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 40px;
    align-items: center;
}

.album-art {
    width: 200px;
    height: 200px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    position: relative;
}

.album-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.album-art.playing img {
    animation: rotate 20s linear infinite;
}

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

.player-info h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.player-info .artist {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

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

.play-btn {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    box-shadow: var(--shadow-glow);
}

.play-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 40px rgba(255, 51, 102, 0.5);
}

.play-btn:active {
    transform: scale(0.95);
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.volume-icon {
    font-size: 20px;
    color: var(--text-secondary);
}

.volume-slider {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: var(--bg-tertiary);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
}

.volume-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: none;
}

.stats {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 15px;
}

.visualizer {
    display: flex;
    gap: 4px;
    align-items: flex-end;
    height: 40px;
    margin-top: 32px;
}

.bar {
    width: 6px;
    background: linear-gradient(180deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 3px;
    opacity: 0.3;
    transition: all 0.3s;
}

.visualizer.active .bar {
    opacity: 1;
    animation: wave 1s ease-in-out infinite;
}

.bar:nth-child(1) { animation-delay: 0s; }
.bar:nth-child(2) { animation-delay: 0.1s; }
.bar:nth-child(3) { animation-delay: 0.2s; }
.bar:nth-child(4) { animation-delay: 0.3s; }
.bar:nth-child(5) { animation-delay: 0.4s; }
.bar:nth-child(6) { animation-delay: 0.5s; }
.bar:nth-child(7) { animation-delay: 0.6s; }
.bar:nth-child(8) { animation-delay: 0.7s; }

@keyframes wave {
    0%, 100% { height: 20%; }
    50% { height: 100%; }
}

.chat-section {
    padding: 60px 0 100px;
}

.chat-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    max-width: 900px;
    margin: 0 auto;
}

.chat-header {
    padding: 24px 32px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    font-size: 20px;
    font-weight: 700;
}

.online-count {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 14px;
}

.online-dot {
    width: 8px;
    height: 8px;
    background: #00ff88;
    border-radius: 50%;
}

.chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 24px 32px;
}

.login-prompt {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
}

.message {
    margin-bottom: 16px;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.message-user {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 4px;
}

.message-text {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.5;
}

.message.system .message-text {
    color: var(--text-tertiary);
    font-style: italic;
}

.chat-input {
    padding: 24px 32px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 16px;
}

.chat-input input {
    flex: 1;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 20px;
    color: var(--text-primary);
    font-size: 15px;
    outline: none;
    transition: all 0.3s;
}

.chat-input input:focus {
    border-color: var(--accent-primary);
    background: var(--bg-primary);
}

.send-btn {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.send-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.send-btn:active {
    transform: translateY(0);
}

footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 40px 0;
    text-align: center;
}

.footer-content {
    color: var(--text-tertiary);
    font-size: 14px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-top: 16px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent-primary);
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 42px;
    }
    
    .player-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .album-art {
        width: 100%;
        max-width: 300px;
        height: auto;
        aspect-ratio: 1;
        margin: 0 auto;
    }
    
    .player-card {
        padding: 32px 24px;
    }
    
    .nav-links {
        gap: 16px;
    }
    
    .chat-messages {
        height: 300px;
    }
}

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

::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
}

::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-secondary);
}

.pwa-prompt {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 32px;
    max-width: 400px;
    box-shadow: var(--shadow-lg);
    z-index: 10000;
    animation: slideUp 0.5s ease-out;
}

.pwa-prompt.hidden {
    display: none;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(100px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pwa-prompt-content {
    position: relative;
    text-align: center;
}

.pwa-close {
    position: absolute;
    top: -16px;
    right: -16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.pwa-close:hover {
    background: var(--accent-primary);
    color: white;
    transform: rotate(90deg);
}

.pwa-icon {
    font-size: 64px;
    color: var(--accent-primary);
    margin-bottom: 16px;
}

.pwa-prompt h3 {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.pwa-prompt p {
    color: var(--text-secondary);
    margin-bottom: 24px;
    font-size: 15px;
}

.pwa-install {
    width: 100%;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    border-radius: 12px;
    padding: 14px;
    color: white;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
    box-shadow: var(--shadow-glow);
    margin-bottom: 24px;
}

.pwa-install:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 40px rgba(255, 51, 102, 0.5);
}

.pwa-install:active {
    transform: translateY(0);
}

.pwa-instructions {
    background: var(--bg-tertiary);
    border-radius: 12px;
    padding: 16px;
    text-align: left;
}

.pwa-instructions p {
    margin: 8px 0;
    font-size: 13px;
    color: var(--text-secondary);
}

.pwa-instructions strong {
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .pwa-prompt {
        bottom: 16px;
        right: 16px;
        left: 16px;
        max-width: none;
        padding: 24px;
    }
}
