@import url('https://fonts.googleapis.com/css2?family=Anton&family=Bebas+Neue&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background:
        radial-gradient(circle at 20% 50%, rgba(138, 43, 226, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(0, 191, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 50% 20%, rgba(255, 0, 255, 0.1) 0%, transparent 50%),
        linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 50%, #0f0f0f 100%);
    color: #fff;
    overflow-x: hidden;
    min-height: 100vh;
    animation: bgShift 20s ease-in-out infinite alternate;
    position: relative;
}

@keyframes bgShift {
    0% {
        background-position: 0% 50%, 100% 100%, 50% 0%, 0% 50%;
    }
    100% {
        background-position: 100% 50%, 0% 0%, 50% 100%, 100% 50%;
    }
}

/* Particle canvas */
#particleCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

/* Scanline effect */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.15) 1px,
        transparent 1px,
        transparent 2px
    );
    pointer-events: none;
    z-index: 99;
    opacity: 0.3;
    animation: scanlineMove 8s linear infinite;
}

@keyframes scanlineMove {
    0% { transform: translateY(0); }
    100% { transform: translateY(10px); }
}

/* Vignette effect */
.vignette {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, transparent 0%, rgba(0, 0, 0, 0.6) 100%);
    pointer-events: none;
    z-index: 98;
}

/* Floating images container */
#floatingContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}

.floating-image {
    position: absolute;
    border-radius: 16px;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(255, 255, 255, 0.1),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
    opacity: 0.9;
    transition: opacity 0.5s ease, transform 0.5s ease;
    filter: brightness(1.05) saturate(1.2);
    animation: floatGlow 4s ease-in-out infinite;
    will-change: transform, opacity;
}

@keyframes floatGlow {
    0%, 100% {
        filter: brightness(1.05) saturate(1.2) drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
    }
    50% {
        filter: brightness(1.15) saturate(1.3) drop-shadow(0 0 20px rgba(255, 255, 255, 0.3));
    }
}

.floating-image:hover {
    opacity: 1;
    transform: scale(1.05) !important;
    box-shadow:
        0 12px 48px rgba(0, 0, 0, 0.8),
        0 0 60px rgba(255, 255, 255, 0.3),
        inset 0 0 0 2px rgba(255, 255, 255, 0.2);
    z-index: 100 !important;
}

/* Depth layers for parallax effect */
.floating-image.layer-1 {
    filter: brightness(1.05) saturate(1.2) blur(0px);
    z-index: 5;
}

.floating-image.layer-2 {
    filter: brightness(0.95) saturate(1.1) blur(1px);
    opacity: 0.7;
    z-index: 3;
}

.floating-image.layer-3 {
    filter: brightness(0.85) saturate(1.0) blur(2px);
    opacity: 0.5;
    z-index: 1;
}

/* Main content */
.main-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 60px 30px;
    overflow: visible;
}

/* BUSSIN title */
.bussin-title {
    font-family: 'Impact', 'Anton', sans-serif;
    font-size: clamp(70px, 16vw, 220px);
    font-weight: 900;
    font-style: italic;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: linear-gradient(135deg,
        #ff00ff 0%,
        #00ffff 25%,
        #ff00ff 50%,
        #ffff00 75%,
        #00ffff 100%);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 40px rgba(255, 0, 255, 0.8))
            drop-shadow(0 0 80px rgba(0, 255, 255, 0.6))
            drop-shadow(0 15px 60px rgba(255, 255, 255, 0.4));
    margin-bottom: 60px;
    padding: 20px 40px;
    animation: titleRainbow 6s linear infinite, titleGlow 3s ease-in-out infinite;
    position: relative;
    white-space: nowrap;
    overflow: visible;
    display: inline-block;
}

@keyframes titleRainbow {
    0% { background-position: 0% 50%; }
    100% { background-position: 300% 50%; }
}

@keyframes titleGlow {
    0%, 100% {
        filter: drop-shadow(0 0 40px rgba(255, 0, 255, 0.8))
                drop-shadow(0 0 80px rgba(0, 255, 255, 0.6))
                drop-shadow(0 15px 60px rgba(255, 255, 255, 0.4));
    }
    33% {
        filter: drop-shadow(0 0 50px rgba(0, 255, 255, 0.9))
                drop-shadow(0 0 90px rgba(255, 0, 255, 0.7))
                drop-shadow(0 15px 70px rgba(0, 255, 255, 0.5));
    }
    66% {
        filter: drop-shadow(0 0 50px rgba(255, 255, 0, 0.9))
                drop-shadow(0 0 90px rgba(255, 0, 255, 0.7))
                drop-shadow(0 15px 70px rgba(255, 255, 0, 0.5));
    }
}

/* Upload section */
.upload-section {
    background: rgba(20, 20, 20, 0.7);
    backdrop-filter: blur(20px);
    padding: 40px;
    border-radius: 25px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    border: 2px solid rgba(255, 255, 255, 0.15);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.6),
        0 0 80px rgba(138, 43, 226, 0.3),
        inset 0 0 80px rgba(138, 43, 226, 0.05);
    position: relative;
    animation: sectionPulse 4s ease-in-out infinite;
}

@keyframes sectionPulse {
    0%, 100% {
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.6),
            0 0 80px rgba(138, 43, 226, 0.3),
            inset 0 0 80px rgba(138, 43, 226, 0.05);
    }
    50% {
        box-shadow:
            0 12px 48px rgba(0, 0, 0, 0.7),
            0 0 100px rgba(0, 191, 255, 0.4),
            inset 0 0 100px rgba(0, 191, 255, 0.08);
    }
}

.upload-section h2 {
    font-family: 'Impact', 'Anton', sans-serif;
    font-style: italic;
    font-size: 36px;
    margin-bottom: 10px;
    letter-spacing: 0.08em;
    background: linear-gradient(135deg, #ff00ff, #00ffff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 20px rgba(255, 0, 255, 0.6));
}

.upload-section p {
    color: #ccc;
    margin-bottom: 30px;
    font-size: 16px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

#imageUpload {
    display: block;
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

#imageUpload:hover {
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.1);
}

.generate-btn {
    font-family: 'Impact', 'Anton', sans-serif;
    font-style: italic;
    font-size: 24px;
    padding: 18px 50px;
    background: linear-gradient(135deg, #ff00ff, #ff0080, #ff00ff);
    background-size: 200% 200%;
    border: 2px solid rgba(255, 0, 255, 0.5);
    border-radius: 50px;
    color: #fff;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s ease;
    box-shadow:
        0 4px 20px rgba(255, 0, 255, 0.5),
        0 0 40px rgba(255, 0, 255, 0.3),
        inset 0 0 20px rgba(255, 255, 255, 0.1);
    animation: btnGlow 3s ease-in-out infinite;
    position: relative;
    overflow: hidden;
}

@keyframes btnGlow {
    0%, 100% {
        background-position: 0% 50%;
        box-shadow:
            0 4px 20px rgba(255, 0, 255, 0.5),
            0 0 40px rgba(255, 0, 255, 0.3),
            inset 0 0 20px rgba(255, 255, 255, 0.1);
    }
    50% {
        background-position: 100% 50%;
        box-shadow:
            0 6px 30px rgba(255, 0, 128, 0.7),
            0 0 60px rgba(255, 0, 128, 0.5),
            inset 0 0 30px rgba(255, 255, 255, 0.15);
    }
}

.generate-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    transform: rotate(45deg);
    animation: btnShine 3s linear infinite;
}

@keyframes btnShine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.generate-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow:
        0 8px 40px rgba(255, 0, 255, 0.8),
        0 0 80px rgba(255, 0, 255, 0.6),
        inset 0 0 40px rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 0, 255, 0.8);
}

.generate-btn:active {
    transform: translateY(-1px) scale(0.98);
}

.generate-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    animation: none;
}

/* Loading indicator */
.loading {
    margin-top: 30px;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 15px;
    border: 5px solid rgba(255, 255, 255, 0.1);
    border-top: 5px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Result container */
.result {
    margin-top: 30px;
}

#resultImage {
    max-width: 100%;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.download-btn {
    font-family: 'Impact', 'Anton', sans-serif;
    font-style: italic;
    padding: 15px 40px;
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    border: none;
    border-radius: 50px;
    color: #fff;
    cursor: pointer;
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(76, 175, 80, 0.4);
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(76, 175, 80, 0.6);
}

/* Hidden class */
.hidden {
    display: none !important;
}

/* Music button */
.music-btn {
    position: fixed;
    top: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(138, 43, 226, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: musicBtnPulse 3s ease-in-out infinite;
}

@keyframes musicBtnPulse {
    0%, 100% {
        box-shadow:
            0 4px 20px rgba(0, 0, 0, 0.6),
            0 0 40px rgba(138, 43, 226, 0.3);
        border-color: rgba(138, 43, 226, 0.4);
    }
    50% {
        box-shadow:
            0 6px 30px rgba(0, 0, 0, 0.7),
            0 0 60px rgba(0, 191, 255, 0.5);
        border-color: rgba(0, 191, 255, 0.6);
    }
}

.music-icon {
    font-size: 24px;
    transition: all 0.3s ease;
    display: block;
    line-height: 1;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.5));
}

.music-btn:hover {
    transform: scale(1.15);
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.8),
        0 0 80px rgba(255, 0, 255, 0.6);
    border-color: rgba(255, 0, 255, 0.8);
}

.music-btn:active {
    transform: scale(0.95);
}

.music-btn.playing .music-icon::after {
    content: '⏹️';
}

.music-btn.stopped .music-icon::after {
    content: '▶️';
}

/* Solana CA container */
.ca-container {
    position: fixed;
    top: 30px;
    left: 30px;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(15px);
    padding: 15px 25px;
    border-radius: 18px;
    border: 2px solid rgba(0, 255, 163, 0.3);
    z-index: 1000;
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(0, 255, 163, 0.2),
        inset 0 0 40px rgba(0, 255, 163, 0.05);
    transition: all 0.3s ease;
    animation: caPulse 3s ease-in-out infinite;
}

@keyframes caPulse {
    0%, 100% {
        box-shadow:
            0 4px 20px rgba(0, 0, 0, 0.6),
            0 0 40px rgba(0, 255, 163, 0.2),
            inset 0 0 40px rgba(0, 255, 163, 0.05);
        border-color: rgba(0, 255, 163, 0.3);
    }
    50% {
        box-shadow:
            0 6px 30px rgba(0, 0, 0, 0.7),
            0 0 60px rgba(0, 255, 163, 0.4),
            inset 0 0 60px rgba(0, 255, 163, 0.1);
        border-color: rgba(0, 255, 163, 0.5);
    }
}

.ca-container:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.8),
        0 0 80px rgba(0, 255, 163, 0.5),
        inset 0 0 60px rgba(0, 255, 163, 0.15);
}

.ca-label {
    font-family: 'Impact', 'Anton', sans-serif;
    font-style: italic;
    font-size: 12px;
    color: #888;
    margin-bottom: 5px;
    letter-spacing: 0.15em;
    text-shadow: 0 0 10px rgba(0, 255, 163, 0.3);
}

.ca-value {
    font-family: 'Impact', 'Anton', sans-serif;
    font-style: italic;
    font-size: 18px;
    color: #fff;
    letter-spacing: 0.08em;
    background: linear-gradient(135deg, #00FFA3 0%, #00D4AA 50%, #00FFA3 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: caShine 3s linear infinite;
    filter: drop-shadow(0 0 20px rgba(0, 255, 163, 0.5));
}

@keyframes caShine {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

/* Responsive */
@media (max-width: 768px) {
    .upload-section {
        padding: 30px 20px;
    }

    .bussin-title {
        margin-bottom: 40px;
    }

    .generate-btn {
        font-size: 20px;
        padding: 15px 40px;
    }

    .ca-container {
        top: 20px;
        left: 20px;
        padding: 12px 20px;
    }

    .ca-label {
        font-size: 10px;
    }

    .ca-value {
        font-size: 16px;
    }

    .music-btn {
        top: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }

    .music-icon {
        font-size: 18px;
    }
}
