@property --theme-color-1 { syntax: '<color>'; inherits: true; initial-value: #FF0080; }
@property --theme-color-2 { syntax: '<color>'; inherits: true; initial-value: #7928CA; }

* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --theme-color-1: #FF0080;
    --theme-color-2: #7928CA;
    --primary-gradient: linear-gradient(135deg, var(--theme-color-1), var(--theme-color-2));
    --glass-bg: rgba(10, 10, 10, 0.75); 
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --card-shadow: 0 60px 100px -10px #000000;
    --text-white: #ffffff;
    --text-grey: rgba(255, 255, 255, 0.7);
    --vol-factor: 0.5; 
    transition: --theme-color-1 2.5s ease-in-out, --theme-color-2 2.5s ease-in-out;
}

html { background: #050505; height: 100%; overflow-x: hidden; /* <--- THIS STOPS THE WEIRD SHIFTING */
    width: 100vw;       /* <--- THIS LOCKS THE VIEWPORT WIDTH */ }

body {
    font-family: 'Outfit', sans-serif;
    background: transparent;
    color: var(--text-white);
    min-height: 100dvh; 
    display: flex; flex-direction: column; align-items: center;
    overflow-x: hidden;
    padding-top: 20px; padding-bottom: 80px; 
    -webkit-font-smoothing: antialiased;
    user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
}

/* --- ICONS HELPER --- */
svg { display: block; }
.icon-fill { fill: currentColor; stroke: none; }
.icon-stroke { fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

/* --- CUSTOM SCROLLBAR --- */
::-webkit-scrollbar { width: 12px; }
::-webkit-scrollbar-track { background: #050505; }
::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.15); 
    border-radius: 20px; border: 3px solid #050505; 
}
::-webkit-scrollbar-thumb:hover { background-color: rgba(255, 255, 255, 0.25); }

img[src=""], img:not([src]) { visibility: hidden; opacity: 0 !important; }

/* --- SLEEK TOOLTIPS --- */
[data-tooltip] { position: relative; }
[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute; bottom: 100%; left: 50%; 
    transform: translateX(-50%) translateY(-12px);
    background: rgba(10, 10, 10, 0.95); border: 1px solid rgba(255,255,255,0.15);
    color: #fff; padding: 6px 12px; border-radius: 8px;
    font-family: 'Outfit', sans-serif; font-size: 0.75rem; font-weight: 700; 
    text-transform: uppercase; letter-spacing: 0.5px;
    white-space: nowrap; pointer-events: none; opacity: 0; 
    transition: opacity 0.2s ease, transform 0.2s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.5); backdrop-filter: blur(4px);
    z-index: 10000;
}
[data-tooltip]:hover::after { opacity: 1; transform: translateX(-50%) translateY(-15px); }

/* --- BACKGROUND FX --- */
.animated-bg {
    position: fixed; top: -50%; left: -50%; width: 200%; height: 200%; z-index: 0;
    background: radial-gradient(circle at 50% 50%, #111, #000 70%);
    pointer-events: none;
    will-change: transform; 
}
.noise-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 1;
    opacity: 0.03; 
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    pointer-events: none;
}

.orb {
    position: fixed; border-radius: 50%; filter: blur(100px); z-index: 0;
    opacity: 0.35; animation: floatOrb 25s infinite ease-in-out;
    will-change: transform; 
    transform: translateZ(0);
}
.orb-1 { width: 60vh; height: 60vh; background: var(--theme-color-2); top: -10%; left: -10%; }
.orb-2 { width: 50vh; height: 50vh; background: var(--theme-color-1); bottom: 0%; right: -10%; animation-delay: -5s; }

@keyframes floatOrb {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -30px) scale(1.1); }
    100% { transform: translate(0, 0) scale(1); }
}

body.party-mode-active .orb { animation-duration: 5s; opacity: 0.6; }

/* --- VISUALIZER LAYER --- */
.visualizer-layer {
    position: fixed; bottom: 0; left: 0; width: 100%; height: 60%; 
    z-index: 1; pointer-events: none;
    display: flex; align-items: flex-end; justify-content: center;
    opacity: 0; transition: opacity 1s ease;
    gap: 15px; padding: 0;
    user-select: none;
    mask-image: linear-gradient(to top, black 0%, transparent 80%);
    -webkit-mask-image: linear-gradient(to top, black 0%, transparent 80%);
    will-change: opacity;
}
.visualizer-layer.active { opacity: 0.6; }

.viz-bar {
    width: 80px; flex-shrink: 0; 
    background: linear-gradient(to top, var(--theme-color-1), var(--theme-color-2));
    height: 5%; border-radius: 12px 12px 0 0;
    animation: bounce 0.5s infinite ease-in-out alternate;
    will-change: height, transform, background; 
    transform: translateZ(0);
}

@keyframes bounce {
    0% { height: 5%; }
    100% { height: calc(5% + (95% * var(--vol-factor) * var(--bar-scale))); }
}

/* --- FLOATING TEXT --- */
.floating-text-container {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 1;
    overflow: hidden; pointer-events: none; mix-blend-mode: overlay; 
}
.floating-text {
    position: absolute; white-space: nowrap; font-family: 'Bebas Neue', sans-serif;
    text-transform: uppercase; color: rgba(255, 255, 255, 0.12); 
    font-size: 18vh; line-height: 0.8; opacity: 0; transition: opacity 1s ease;
}
.float-1 { top: 15%; animation: scrollLeft 60s linear infinite; }
.float-2 { bottom: 15%; animation: scrollRight 65s linear infinite; }
@keyframes scrollLeft { from { transform: translateX(100vw); } to { transform: translateX(-100%); } }
@keyframes scrollRight { from { transform: translateX(-100%); } to { transform: translateX(100vw); } }

body.party-mode-active .floating-text {
    color: rgba(255, 255, 255, 0.3);
    text-shadow: 0 0 20px var(--theme-color-1), 0 0 40px var(--theme-color-2);
    mix-blend-mode: screen; opacity: 0.9;
}

/* --- MAIN LAYOUT --- */
.container {
    width: 90%; max-width: 480px; margin: 0 auto;
    position: relative; z-index: 10; padding-bottom: 40px;
}
.hero-wrapper {
    position: relative; margin-top: 140px; margin-bottom: 30px;
    display: flex; justify-content: center;
}
.logo-layer {
    position: absolute; top: -110px; width: 100%; max-width: 400px;
    z-index: 20; display: flex; justify-content: center; pointer-events: none; 
}
.layout-img { width: 100%; height: auto; opacity: 0; display: block; }

.logo-color-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: var(--primary-gradient);
    -webkit-mask-image: url("images/BTL_logo_2024v2.png");
    mask-image: url("images/BTL_logo_2024v2.png");
    -webkit-mask-size: contain; mask-size: contain;
    -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
    -webkit-mask-position: center; mask-position: center;
    filter: drop-shadow(0 0 25px var(--theme-color-1));
    animation: bobLogo 5s ease-in-out infinite;
}
@keyframes bobLogo {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* --- PLAYER CARD --- */
.player-card {
    position: relative; z-index: 15; 
    background-color: #050505;
    border-radius: 44px; 
    aspect-ratio: 1 / 1;
    display: flex; flex-direction: column; justify-content: space-between;
    padding: 25px 20px;
    
    border: none; text-align: center; width: 100%; overflow: hidden; 
    transition: transform 0.3s ease; transform: translateZ(0); 
    -webkit-transform: translateZ(0);
    
    box-shadow: 
        inset 0 1px 0 rgba(255, 255, 255, 0.2), 
        0 20px 60px -10px rgba(0, 0, 0, 0.9);
}

/* THE FALLBACK VISUAL (When art is missing) */
/* Sits BEHIND the buffer images but ON TOP of the black background */
.fallback-mesh {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    z-index: 0; /* Level 0 */
    overflow: hidden;
    
    /* Cool Cyber Gradient Fallback */
    background: 
        radial-gradient(circle at 20% 30%, var(--theme-color-1), transparent 50%),
        radial-gradient(circle at 80% 70%, var(--theme-color-2), transparent 50%),
        #111;
    background-size: 150% 150%;
    animation: pulseFallback 8s ease-in-out infinite alternate;
}

@keyframes pulseFallback {
    0% { opacity: 0.5; background-position: 0% 0%; }
    100% { opacity: 0.8; background-position: 100% 100%; }
}

.player-card::after {
    content: ''; position: absolute; top:0; left:0; width:100%; height:100%;
    z-index: 1; pointer-events: none;
    box-shadow: 
        inset 0 0 0 2px rgba(0,0,0,1), 
        inset 0 0 0 3px rgba(255,255,255,0.1),
        inset 0 20px 40px rgba(0,0,0,0.9),
        inset 0 -100px 60px rgba(0,0,0,0.8);
    background: transparent;
    border-radius: 44px;
}

#art-container {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    z-index: 0; pointer-events: none;
    will-change: transform;
    filter: brightness(1.1) contrast(1.1); 
}

body.hype-mode-active #art-container {
    animation: artPulse 0.48s infinite cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
@keyframes artPulse {
    0%, 100% { transform: scale(1); }
    30% { transform: scale(1.03); }
}

.bg-buffer {
    position: absolute; top: -25%; left: -25%; width: 150%; height: 150%;
    opacity: 0; z-index: 2; 
    transition: opacity 1.5s ease-in-out;
    background-position: center center;
    background-repeat: repeat; 
    will-change: transform, background-size;
}
.bg-buffer.active { opacity: 1; }
.bg-buffer::after {
    content: ''; position: absolute; top:0; left:0; width:100%; height:100%;
    background: rgba(0,0,0,0.4); 
}

@keyframes vj-grid { 0% { background-size: 100% auto; transform: rotate(0deg); } 40% { background-size: 25% auto; transform: rotate(0deg); } 50% { background-size: 25% auto; transform: rotate(2deg); } 100% { background-size: 100% auto; transform: rotate(0deg); } }
@keyframes vj-drift { 0% { background-position: 0% 0%; background-size: 60% auto; transform: scale(1); } 50% { transform: scale(1.05); } 100% { background-position: 100% 100%; background-size: 60% auto; transform: scale(1); } }
@keyframes vj-spin { 0% { background-size: 80% auto; transform: rotate(0deg) scale(1.2); } 50% { background-size: 120% auto; transform: rotate(-5deg) scale(1.4); } 100% { background-size: 80% auto; transform: rotate(0deg) scale(1.2); } }
@keyframes vj-color { 0% { background-size: 100% auto; filter: hue-rotate(0deg); } 50% { background-size: 110% auto; filter: hue-rotate(30deg); } 100% { background-size: 100% auto; filter: hue-rotate(0deg); } }

.player-content { 
    position: relative; z-index: 10; 
    height: 100%; 
    display: flex; flex-direction: column; justify-content: center;
}

/* --- SLEEK BEBAS PLAYER TEXT --- */
.title-mask, .remix-mask, .artist-mask {
    width: 100%; overflow: hidden;
    display: flex; justify-content: center; position: relative;
    mask-image: none; -webkit-mask-image: none; 
    /* Fix Shadow Cutoff */
    padding-bottom: 30px; margin-bottom: -30px;
}

.title-mask { z-index: 3; margin-top: 5px; } 
.remix-mask { z-index: 2; display: none; }
.artist-mask { margin-bottom: 25px; z-index: 1; }

.track-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(3.5rem, 15vw, 6.5rem);
    line-height: 0.9; font-weight: 400; 
    background: linear-gradient(to bottom, #ffffff 40%, rgba(255, 255, 255, 0.5));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; color: transparent;
    display: inline-block; padding: 0 5px; will-change: transform;
    white-space: nowrap;
    filter: drop-shadow(0 2px 2px rgba(0,0,0,0.95));
}

.track-remix {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(1.2rem, 5vw, 2.5rem); 
    font-weight: 400; color: rgba(255, 255, 255, 0.85); 
    text-transform: uppercase; letter-spacing: 1px; line-height: 1;
    display: inline-block; padding: 0 5px; will-change: transform;
    white-space: nowrap;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
}

.track-artist {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(1.5rem, 6vw, 2.5rem); 
    color: rgba(255, 255, 255, 0.9); font-weight: 400;
    text-transform: uppercase; letter-spacing: 2px; 
    display: inline-block; padding: 0 5px; will-change: transform;
    white-space: nowrap;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
}

.track-title.scrolling, .track-remix.scrolling, .track-artist.scrolling { 
    animation: scroll-text 12s linear infinite; text-align: left; 
}
@keyframes scroll-text { 0% { transform: translateX(0); } 70% { transform: translateX(var(--scroll-dist)); } 100% { transform: translateX(0); } }

/* --- PLAY BUTTON --- */
.play-wrapper { display: flex; justify-content: center; margin-bottom: 30px; position: relative; }
.play-ripple {
    position: absolute; width: 120px; height: 120px; border-radius: 50%;
    background: var(--primary-gradient); opacity: 0; transform: scale(0.8); z-index: 0;
}
.playing .play-ripple { animation: ripple 2s infinite cubic-bezier(0, 0.2, 0.8, 1); }
@keyframes ripple { 0% { transform: scale(0.9); opacity: 0.6; } 100% { transform: scale(2.2); opacity: 0; } }

.play-btn {
    width: 120px; height: 120px; border-radius: 50%; background: #fff;
    border: none; color: #000; cursor: pointer; z-index: 1;
    display: flex; align-items: center; justify-content: center;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background 0.3s;
    box-shadow: 0 15px 40px rgba(0,0,0,0.5);
    -webkit-tap-highlight-color: transparent;
}
.play-btn:active { transform: scale(0.92); }
.play-btn svg { width: 60px; height: 60px; }
.play-icon { margin-left: 6px; } 
.stop-icon, .loader-icon { display: none; }
.playing .play-btn { background: var(--primary-gradient); color: #fff; box-shadow: 0 10px 50px rgba(0,0,0, 0.5); }
.playing .play-icon { display: none; }
.playing .stop-icon { display: block; } 
.loading .play-btn { background: #333; cursor: wait; }
.loading .play-icon, .loading .stop-icon { display: none; }
.loading .loader-icon { 
    display: block; width: 30px; height: 30px; border: 3px solid rgba(255,255,255,0.3); 
    border-top: 3px solid #fff; border-radius: 50%; animation: spin 1s linear infinite; 
}
@keyframes spin { 100% { transform: rotate(360deg); } }

/* --- VOLUME SLIDER --- */
.volume-box {
    display: flex; align-items: center; justify-content: center; gap: 15px;
    background: rgba(0,0,0,0.25); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    padding: 12px 20px; border-radius: 30px; width: 90%; margin: 0 auto; border: 1px solid rgba(255,255,255,0.1); 
}
.vol-icon { width: 24px; height: 24px; transition: fill 0.3s ease; cursor: pointer; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5)); }
.vol-icon.high { fill: var(--theme-color-1); filter: drop-shadow(0 0 5px var(--theme-color-1)); }
input[type=range] { -webkit-appearance: none; width: 100%; background: transparent; cursor: pointer; }
input[type=range]:focus { outline: none; }
input[type=range]::-webkit-slider-runnable-track { 
    width: 100%; height: 6px; border-radius: 3px;
    background: linear-gradient(90deg, var(--theme-color-1) var(--vol-percent, 30%), rgba(255,255,255,0.3) var(--vol-percent, 30%));
}
input[type=range]::-webkit-slider-thumb { 
    height: 18px; width: 18px; border-radius: 50%; background: #fff; -webkit-appearance: none; margin-top: -6px; box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

/* --- ACTION BUTTONS --- */
.floating-action-wrapper {
    position: fixed; bottom: 30px; left: 30px; z-index: 2000;
    display: none; transition: opacity 0.5s ease; opacity: 0;
}
.floating-action-wrapper.visible { display: block; opacity: 1; } 

.default-fab {
    width: 60px; height: 60px; border-radius: 50%; background: rgba(30,30,30,0.8);
    border: 1px solid rgba(255, 255, 255, 0.2); color: #fff;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    backdrop-filter: blur(10px); transition: transform 0.3s, opacity 0.2s;
}
.default-fab:active { transform: scale(0.9); }
.default-fab svg { width: 30px; height: 30px; }

.split-pill {
    display: flex; align-items: center; background: rgba(20,20,20,0.95);
    border-radius: 30px; box-shadow: 0 10px 40px rgba(0,0,0,0.6);
    border: 1px solid rgba(255,255,255,0.2); position: absolute; bottom: 0; left: 0;
    opacity: 0; pointer-events: none; transform: scale(0.8);
    transition: all 0.3s; width: 120px; height: 60px;
}
.party-controls-active .default-fab { opacity: 0; pointer-events: none; transform: scale(0.5); }
.party-controls-active .split-pill { opacity: 1; pointer-events: all; transform: scale(1); }

.split-btn {
    flex: 1; height: 100%; border: none; background: transparent; color: #fff; 
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background 0.2s; position: relative;
}
.split-btn:first-child { border-radius: 30px 0 0 30px; }
.split-btn:last-child { border-radius: 0 30px 30px 0; }
.split-btn:active { background: rgba(255,255,255,0.15); }
.split-btn svg { width: 24px; height: 24px; }
.split-divider { width: 1px; height: 60%; background: rgba(255,255,255,0.2); }

.hype-on { color: #FFEB3B; text-shadow: 0 0 10px #FFEB3B; }
.hype-on svg { filter: drop-shadow(0 0 5px #FFEB3B); animation: pulseHypeBtn 0.5s infinite alternate; }
@keyframes pulseHypeBtn { from { transform: scale(1); } to { transform: scale(1.2); } }

#castBtn { 
    position: fixed; bottom: 30px; right: 30px; width: 60px; height: 60px;
    border-radius: 50%; background: rgba(30,30,30,0.8);
    border: 1px solid rgba(255, 255, 255, 0.2); color: #fff;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; z-index: 2000; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: all 0.3s; visibility: hidden; backdrop-filter: blur(10px);
}
#castBtn.casting { background: #fff; color: var(--theme-color-1); box-shadow: 0 0 20px var(--theme-color-1); animation: pulseCast 2s infinite; }
#castBtn svg { width: 28px; height: 28px; }
@keyframes pulseCast {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

/* --- BUTTONS --- */
.big-share-btn, .donate-btn, .app-btn, .contact-btn {
    display: block; width: 100%; text-decoration: none; text-align: center;
    font-weight: 700; font-size: 1.1rem; text-transform: uppercase; letter-spacing: 1px;
    padding: 14px 0; border-radius: 16px; color: #fff; 
    border: 1px solid rgba(255,255,255,0.2); transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3); cursor: pointer;
}
.big-share-btn, .donate-btn, .contact-btn { background: var(--primary-gradient); }
.app-btn { background: rgba(40, 40, 40, 0.6); backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,0.3); }
.big-share-btn:hover, .donate-btn:hover, .app-btn:hover, .contact-btn:hover {
    transform: translateY(-2px); box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    background: #fff; color: #000; text-shadow: none; border-color: #fff;
}

/* --- UNIFORM CARD SPACING (FIXED) --- */
.donation-card, .history-card, .share-card, .contact-card, .app-install-container {
    margin-bottom: 24px; /* Standardized for sleek look */
}

/* --- DONATION CARD --- */
.donation-card {
    position: relative; background: transparent; border-radius: 24px; padding: 2px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3); overflow: hidden; z-index: 10;
    transition: opacity 0.3s ease, margin-top 0.3s ease;
}
.donation-border {
    position: absolute; inset: 0; pointer-events: none; z-index: 1; border-radius: 24px; overflow: hidden;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude; padding: 2px; 
}
.donation-border::before {
    content: ""; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
    background: conic-gradient(from 0deg, transparent 0%, transparent 20%, var(--theme-color-1) 50%, var(--theme-color-2) 70%, transparent 90%);
    animation: rotateBorder 4s linear infinite;
}
@keyframes rotateBorder { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.donation-inner { 
    position: relative; background: rgba(20, 20, 20, 0.4); 
    backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
    border-radius: 22px; padding: 25px; text-align: center; z-index: 2; 
    border: 1px solid rgba(255, 255, 255, 0.05); 
}

.close-donation {
    position: absolute; top: 12px; right: 15px; width: 24px; height: 24px; 
    cursor: pointer; z-index: 10; opacity: 0; transition: opacity 0.3s ease;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,0.1); border-radius: 50%;
}
.donation-card:hover .close-donation { opacity: 1; }
.close-donation:hover { background: rgba(255,255,255,0.3); }
.close-donation:hover svg { stroke: #fff; }
.close-donation svg { width: 14px; height: 14px; stroke: #aaa; transition: stroke 0.2s; }

.rainbow-hearts { font-size: 1.6rem; margin-bottom: 5px; display: flex; justify-content: center; gap: 5px; }
.rainbow-hearts span { animation: heartWave 2s ease-in-out infinite; }
.rainbow-hearts span:nth-child(2) { animation-delay: 0.1s; }
.rainbow-hearts span:nth-child(3) { animation-delay: 0.2s; }
.rainbow-hearts span:nth-child(4) { animation-delay: 0.3s; }
.rainbow-hearts span:nth-child(5) { animation-delay: 0.4s; }
.rainbow-hearts span:nth-child(6) { animation-delay: 0.5s; }
@keyframes heartWave { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

.donate-btn { margin-top: 15px; }
.donate-text {
    display: inline-block; transition: opacity 0.5s, transform 0.5s, filter 0.5s;
    opacity: 1; transform: translateY(0); filter: blur(0);
}
.donate-text.fade-out { opacity: 0; transform: translateY(10px); filter: blur(8px); }

.share-card {
    background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px; padding: 20px; text-align: center; backdrop-filter: blur(10px);
}
.share-title { font-weight: 900; font-size: 1.1rem; text-transform: uppercase; margin-bottom: 10px; color: #fff; letter-spacing: 1px; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }

.history-card { 
    background: rgba(10, 10, 10, 0.6); border: var(--glass-border); border-radius: 30px; 
    padding: 30px 20px; min-height: 400px; 
    position: relative; z-index: 10; backdrop-filter: blur(20px); transition: transform 0.4s ease; 
}
.history-title { text-align: center; font-size: 0.9rem; font-weight: 900; text-transform: uppercase; letter-spacing: 6px; color: var(--text-white); opacity: 0.8; margin-bottom: 30px; display: block; }
#history-display-container { display: flex; flex-direction: column; gap: 12px; }
.cctrack {
    position: relative; background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05); border-radius: 16px;
    padding: 16px 16px 16px 60px !important; display: flex !important; 
    flex-direction: column; transition: transform 0.2s, background 0.2s;
}
#history-display-container img, #history-buffer img { display: none !important; }
.force-hidden { position: fixed !important; top: -9999px !important; }
.cctrack.hidden-row { display: none !important; }
.cctrack:hover { background: rgba(255, 255, 255, 0.08); transform: scale(1.02); }

.cctrack::before {
    content: ''; position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
    width: 24px; height: 24px; background-color: rgba(255,255,255,0.3);
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8z'/%3E%3C/svg%3E");
    -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center;
}
.cctrack:not(.hidden-row):first-of-type {
    background: linear-gradient(90deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02));
    border-left: 2px solid var(--theme-color-1);
}
@keyframes pulse-color { 0%, 100% { background-color: var(--theme-color-1); opacity: 1; } 50% { background-color: #fff; opacity: 0.7; } }
.cctrack:not(.hidden-row):first-of-type::before {
    background-color: var(--theme-color-1); animation: pulse-color 2s infinite ease-in-out;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 9v6h2V9H3zm4-5v16h2V4H7zm4 3v10h2V7h-2zm4 4v2h2v-2h-2z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 9v6h2V9H3zm4-5v16h2V4H7zm4 3v10h2V7h-2zm4 4v2h2v-2h-2z'/%3E%3C/svg%3E");
}
.cctitle { font-weight: 800; font-size: 1.1rem; color: #fff; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ccartist { font-size: 0.85rem; color: rgba(255,255,255,0.6); font-weight: 500; text-transform: uppercase; }
.cccover, .ccalbum, .ccbuy { display: none !important; }

.custom-context-menu {
    display: none; position: absolute; z-index: 9999;
    background: rgba(20, 20, 20, 0.95); backdrop-filter: blur(20px); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 12px; 
    padding: 8px; width: 220px; box-shadow: 0 15px 40px rgba(0,0,0,0.6);
}
.ctx-item { color: #fff; padding: 12px 15px; font-size: 0.9rem; cursor: pointer; border-radius: 8px; transition: 0.2s; display: flex; align-items: center; gap: 10px; }
.ctx-item:hover { background: rgba(255,255,255,0.1); }
.ctx-icon { width: 18px; height: 18px; opacity: 0.8; }
.ctx-divider { height: 1px; background: rgba(255,255,255,0.1); margin: 6px 0; }

.app-install-container { display: none; }
.app-install-container.active { display: block; animation: fadeUp 0.5s ease; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.contact-card { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 20px; padding: 25px 20px; text-align: center; backdrop-filter: blur(10px); }
.contact-btn { margin-top: 15px; }
footer { margin-top: 40px; text-align: center; font-size: 0.75rem; color: #888; padding-bottom: 20px; }

.live-bar {
    position: fixed; bottom: 0; left: 0; width: 100%; height: 4px; z-index: 100;
    background: transparent; opacity: 0.3; pointer-events: none; transition: 0.3s; overflow: hidden;
}
.live-bar::after {
    content: ''; position: absolute; top: 0; left: 0; bottom: 0; width: 200%; 
    background: linear-gradient(90deg, var(--theme-color-1), var(--theme-color-2), #fff, var(--theme-color-2), var(--theme-color-1));
    background-size: 50% 100%; background-repeat: repeat-x; will-change: transform;
}
.live-bar.active-stream { height: 6px; opacity: 1; box-shadow: 0 0 15px var(--theme-color-1); }
.live-bar.active-stream::after { animation: flow 4s linear infinite; }
@keyframes flow { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

@media (max-width: 600px) {
    .hero-wrapper { margin-top: 100px; }
    .logo-layer { width: 85%; top: -80px; }
    .play-btn { width: 100px; height: 100px; }
    .play-ripple { width: 100px; height: 100px; }
    .floating-action-wrapper { display: none !important; }
    #castBtn { bottom: 20px; right: 20px; }
}