/* Import trendy fonts */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* Modern CSS Variables and Styles */
:root {
    --neon-blue: #00d4ff;
    --neon-purple: #8b5cf6;
    --neon-pink: #ff0080;
    --neon-green: #00ff88;
    --neon-yellow: #ffff00;
    --cyber-dark: #0a0a0f;
    --cyber-darker: #050508;
    --glass-light: rgba(255, 255, 255, 0.1);
    --glass-lighter: rgba(255, 255, 255, 0.05);
    --mystery: #8b5cf6;
}

/* Neon utility classes */
.bg-neon-blue { background-color: var(--neon-blue); }
.bg-neon-purple { background-color: var(--neon-purple); }
.bg-neon-yellow { background-color: var(--neon-yellow); }
.bg-neon-pink { background-color: var(--neon-pink); }
.bg-neon-green { background-color: var(--neon-green); }

.text-neon-blue { color: var(--neon-blue); }
.text-neon-purple { color: var(--neon-purple); }
.text-neon-yellow { color: var(--neon-yellow); }
.text-neon-pink { color: var(--neon-pink); }
.text-neon-green { color: var(--neon-green); }

body {
    margin: 0;
    font-family: 'Space Grotesk', system-ui, sans-serif;
    background: 
        radial-gradient(circle at 20% 20%, rgba(139, 92, 246, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 0, 128, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(0, 212, 255, 0.2) 0%, transparent 50%),
        linear-gradient(135deg, #0a0a0f 0%, #1a0b2e 25%, #16213e 50%, #0f3460 75%, #0a0a0f 100%);
    color: white;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Animated background particles */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(0, 212, 255, 0.3), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(139, 92, 246, 0.3), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255, 0, 128, 0.3), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(0, 255, 136, 0.3), transparent);
    background-repeat: repeat;
    background-size: 150px 100px;
    animation: sparkle 20s linear infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes sparkle {
    0% { transform: translateY(0px); }
    100% { transform: translateY(-100px); }
}

/* Glass morphism effects */
.glass {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.7) 0%, 
        rgba(0, 0, 0, 0.5) 100%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.glass-strong {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.8) 0%, 
        rgba(0, 0, 0, 0.6) 100%);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.glass-minimal {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.6) 0%, 
        rgba(0, 0, 0, 0.4) 100%);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.glass-minimal-header {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.85) 0%, 
        rgba(0, 0, 0, 0.75) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.glass-minimal-footer {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.95) 0%, 
        rgba(0, 0, 0, 0.90) 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.3);
}

/* Button Styles */
.btn-primary {
    background: linear-gradient(135deg, var(--neon-blue) 0%, var(--neon-purple) 100%);
    color: white;
    padding: 16px 32px; /* Increased padding for better touch targets */
    border-radius: 16px;
    border: none;
    font-weight: 600;
    font-size: 16px; /* Increased font size for better readability */
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); /* Faster transitions for mobile */
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-height: 48px; /* Minimum touch target size for accessibility */
    box-shadow: 
        0 0 20px rgba(0, 212, 255, 0.3),
        0 4px 15px rgba(0, 0, 0, 0.2);
    /* Prevent text selection on touch */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    /* Improve touch response */
    -webkit-tap-highlight-color: transparent;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 
        0 0 30px rgba(0, 212, 255, 0.5),
        0 8px 25px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover::before {
    left: 100%;
}

/* Active state for mobile touch feedback */
.btn-primary:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 
        0 0 15px rgba(0, 212, 255, 0.4),
        0 2px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.1s ease;
}

/* Focus state for accessibility */
.btn-primary:focus {
    outline: 2px solid var(--neon-blue);
    outline-offset: 2px;
}

.btn-secondary {
    background: linear-gradient(135deg, var(--neon-pink) 0%, var(--neon-purple) 100%);
    color: white;
    padding: 16px 32px; /* Increased padding for better touch targets */
    border-radius: 16px;
    border: none;
    font-weight: 600;
    font-size: 16px; /* Increased font size for better readability */
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); /* Faster transitions for mobile */
    position: relative;
    min-height: 48px; /* Minimum touch target size for accessibility */
    /* Prevent text selection on touch */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    /* Improve touch response */
    -webkit-tap-highlight-color: transparent;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 0 20px rgba(255, 0, 128, 0.3);
}

/* Secondary button interactive states */
.btn-secondary:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 
        0 0 30px rgba(255, 0, 128, 0.5),
        0 8px 25px rgba(0, 0, 0, 0.3);
}

.btn-secondary:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 
        0 0 15px rgba(255, 0, 128, 0.4),
        0 2px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.1s ease;
}

.btn-secondary:focus {
    outline: 2px solid var(--neon-pink);
    outline-offset: 2px;
}

.btn-success {
    background: linear-gradient(135deg, var(--neon-green) 0%, var(--neon-blue) 100%);
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.3);
    color: #0a0a0f;
}

.btn-tap-round {
    background: linear-gradient(135deg, var(--neon-blue) 0%, var(--neon-purple) 100%);
    color: white;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 
        0 0 30px rgba(0, 212, 255, 0.4),
        0 8px 25px rgba(0, 0, 0, 0.3),
        inset 0 2px 0 rgba(255, 255, 255, 0.3);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .btn-tap-round {
        width: 160px;
        height: 160px;
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .btn-tap-round {
        width: 140px;
        height: 140px;
        font-size: 1.1rem;
    }
}

.btn-tap-round::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
    border-radius: 50%;
}

.btn-tap-round:hover {
    transform: scale(1.1);
    box-shadow: 
        0 0 40px rgba(0, 212, 255, 0.6),
        0 12px 35px rgba(0, 0, 0, 0.4),
        inset 0 2px 0 rgba(255, 255, 255, 0.4);
}

.btn-tap-round:not(:disabled):not(.scale-90) {
    animation: tap-pulse 2s ease-in-out infinite;
}

@keyframes tap-pulse {
    0%, 100% { 
        box-shadow: 
            0 0 30px rgba(0, 212, 255, 0.4),
            0 8px 25px rgba(0, 0, 0, 0.3),
            inset 0 2px 0 rgba(255, 255, 255, 0.3);
    }
    50% { 
        box-shadow: 
            0 0 45px rgba(0, 212, 255, 0.6),
            0 12px 35px rgba(0, 0, 0, 0.4),
            inset 0 2px 0 rgba(255, 255, 255, 0.4);
    }
}

.btn-tap-round:hover::before {
    left: 100%;
}

.btn-tap-round:active {
    transform: scale(0.9);
}

/* Elegant Tap Button */
.elegant-tap-btn {
    width: 100px;
    height: 100px;
    border: none;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    z-index: 10;
    outline: none;
}

.elegant-tap-btn:hover {
    transform: scale(1.1);
}

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

.elegant-tap-btn.clicking {
    animation: tap-spin 0.6s ease-out;
}

.elegant-tap-btn.energized {
    animation: tap-glow 1s ease-in-out infinite alternate;
}

.elegant-tap-btn.hyper-spin {
    animation: hyper-spin 0.3s linear infinite;
}

.elegant-tap-btn.ultra-spin {
    animation: ultra-spin 0.2s linear infinite;
}

.elegant-tap-btn.mega-spin {
    animation: mega-spin 0.1s linear infinite;
}

.btn-glow {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, 
        rgba(0, 212, 255, 0.8) 0%, 
        rgba(139, 92, 246, 0.8) 50%,
        rgba(255, 0, 128, 0.8) 100%);
    box-shadow: 
        0 0 20px rgba(0, 212, 255, 0.5),
        0 0 40px rgba(139, 92, 246, 0.3),
        0 0 60px rgba(255, 0, 128, 0.2);
    animation: gentle-pulse 2s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

.elegant-tap-btn.hyper-spin .btn-glow {
    box-shadow: 
        0 0 30px rgba(0, 212, 255, 0.7),
        0 0 60px rgba(139, 92, 246, 0.5),
        0 0 90px rgba(255, 0, 128, 0.3);
    animation: intense-pulse 1s ease-in-out infinite;
}

.elegant-tap-btn.ultra-spin .btn-glow {
    box-shadow: 
        0 0 40px rgba(0, 212, 255, 0.8),
        0 0 80px rgba(139, 92, 246, 0.6),
        0 0 120px rgba(255, 0, 128, 0.4);
    animation: ultra-pulse 0.5s ease-in-out infinite;
}

.elegant-tap-btn.mega-spin .btn-glow {
    box-shadow: 
        0 0 50px rgba(0, 212, 255, 1),
        0 0 100px rgba(139, 92, 246, 0.8),
        0 0 150px rgba(255, 0, 128, 0.6),
        0 0 200px rgba(255, 255, 255, 0.3);
    animation: mega-pulse 0.2s ease-in-out infinite;
}

.btn-content {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    pointer-events: none;
}

.floating-effects {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

.float-emoji {
    position: absolute;
    font-size: 1.5rem;
    animation: float-up 1s ease-out forwards;
}

.float-emoji:nth-child(1) {
    top: 20%;
    left: 20%;
    animation-delay: 0s;
}

.float-emoji:nth-child(2) {
    top: 20%;
    right: 20%;
    animation-delay: 0.2s;
}

.float-emoji:nth-child(3) {
    bottom: 20%;
    left: 20%;
    animation-delay: 0.4s;
}

.float-emoji:nth-child(4) {
    bottom: 20%;
    right: 20%;
    animation-delay: 0.6s;
}

.tap-instruction {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes tap-spin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1); }
}

@keyframes hyper-spin {
    0% { transform: rotate(0deg) scale(1.1); }
    100% { transform: rotate(360deg) scale(1.1); }
}

@keyframes ultra-spin {
    0% { transform: rotate(0deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1.2); }
}

@keyframes mega-spin {
    0% { transform: rotate(0deg) scale(1.3); }
    100% { transform: rotate(360deg) scale(1.3); }
}

@keyframes tap-glow {
    0% { filter: brightness(1) saturate(1); }
    100% { filter: brightness(1.3) saturate(1.5); }
}

@keyframes gentle-pulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.8;
    }
    50% { 
        transform: scale(1.05);
        opacity: 1;
    }
}

@keyframes intense-pulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.9;
    }
    50% { 
        transform: scale(1.1);
        opacity: 1;
    }
}

@keyframes ultra-pulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.95;
    }
    50% { 
        transform: scale(1.15);
        opacity: 1;
    }
}

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

@keyframes float-up {
    0% { 
        transform: translateY(0) scale(0.5);
        opacity: 0;
    }
    50% { 
        transform: translateY(-30px) scale(1);
        opacity: 1;
    }
    100% { 
        transform: translateY(-60px) scale(0.5);
        opacity: 0;
    }
}

/* Rainbow text effect */
.text-rainbow {
    background: linear-gradient(45deg, #ff0000, #ff8000, #ffff00, #80ff00, #00ff00, #00ff80, #00ffff, #0080ff, #0000ff, #8000ff, #ff00ff, #ff0080);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rainbow-flow 2s ease-in-out infinite;
}

@keyframes rainbow-flow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .elegant-tap-btn {
        width: 80px;
        height: 80px;
    }
    .float-emoji {
        font-size: 1.2rem;
    }
}

.card {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.7) 0%, 
        rgba(0, 0, 0, 0.5) 100%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
    padding: 24px;
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.neon-text {
    font-family: 'Orbitron', monospace;
    text-shadow: 
        0 0 5px currentColor,
        0 0 10px currentColor,
        0 0 15px currentColor;
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.animate-bounce {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(-10%); }
    50% { transform: translateY(0); }
}

.animate-glow {
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { box-shadow: 0 0 20px rgba(0, 212, 255, 0.3); }
    to { box-shadow: 0 0 40px rgba(0, 212, 255, 0.6); }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.animate-shimmer {
    animation: shimmer 2s ease-in-out infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Random floating animations for tap effects */
.animate-float-random-1 {
    animation: float-random-1 1.5s ease-out forwards;
    top: 20%; left: 10%;
}
.animate-float-random-2 {
    animation: float-random-2 1.8s ease-out forwards;
    top: 30%; right: 15%;
}
.animate-float-random-3 {
    animation: float-random-3 1.3s ease-out forwards;
    bottom: 25%; left: 20%;
}
.animate-float-random-4 {
    animation: float-random-4 1.6s ease-out forwards;
    top: 15%; right: 30%;
}
.animate-float-random-5 {
    animation: float-random-5 1.4s ease-out forwards;
    bottom: 35%; right: 25%;
}
.animate-float-random-6 {
    animation: float-random-6 1.7s ease-out forwards;
    top: 40%; left: 30%;
}
.animate-float-random-7 {
    animation: float-random-7 1.2s ease-out forwards;
    bottom: 15%; left: 35%;
}
.animate-float-random-8 {
    animation: float-random-8 1.9s ease-out forwards;
    top: 25%; right: 40%;
}

@keyframes float-random-1 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.5); opacity: 0; }
    50% { transform: translate(-30px, -50px) rotate(180deg) scale(1.2); opacity: 1; }
    100% { transform: translate(-60px, -100px) rotate(360deg) scale(0.3); opacity: 0; }
}

@keyframes float-random-2 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.3); opacity: 0; }
    50% { transform: translate(40px, -60px) rotate(-90deg) scale(1.1); opacity: 1; }
    100% { transform: translate(80px, -120px) rotate(-180deg) scale(0.2); opacity: 0; }
}

@keyframes float-random-3 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.4); opacity: 0; }
    50% { transform: translate(-20px, 40px) rotate(270deg) scale(1.3); opacity: 1; }
    100% { transform: translate(-40px, 80px) rotate(540deg) scale(0.1); opacity: 0; }
}

@keyframes float-random-4 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.6); opacity: 0; }
    50% { transform: translate(25px, -35px) rotate(120deg) scale(1.0); opacity: 1; }
    100% { transform: translate(50px, -70px) rotate(240deg) scale(0.4); opacity: 0; }
}

@keyframes float-random-5 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.2); opacity: 0; }
    50% { transform: translate(-35px, 25px) rotate(-150deg) scale(1.4); opacity: 1; }
    100% { transform: translate(-70px, 50px) rotate(-300deg) scale(0.1); opacity: 0; }
}

@keyframes float-random-6 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.5); opacity: 0; }
    50% { transform: translate(15px, -45px) rotate(45deg) scale(1.1); opacity: 1; }
    100% { transform: translate(30px, -90px) rotate(90deg) scale(0.3); opacity: 0; }
}

@keyframes float-random-7 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.3); opacity: 0; }
    50% { transform: translate(-40px, 30px) rotate(-60deg) scale(1.2); opacity: 1; }
    100% { transform: translate(-80px, 60px) rotate(-120deg) scale(0.2); opacity: 0; }
}

@keyframes float-random-8 {
    0% { transform: translate(0, 0) rotate(0deg) scale(0.4); opacity: 0; }
    50% { transform: translate(50px, -20px) rotate(300deg) scale(1.0); opacity: 1; }
    100% { transform: translate(100px, -40px) rotate(600deg) scale(0.1); opacity: 0; }
}

/* Enhanced Asset rarity colors with neon effects */
.rarity-common { 
    border: 2px solid #6b7280; 
    background: linear-gradient(135deg, rgba(107, 114, 128, 0.2) 0%, rgba(107, 114, 128, 0.05) 100%);
    box-shadow: 0 0 15px rgba(107, 114, 128, 0.3);
}
.rarity-rare { 
    border: 2px solid var(--neon-blue); 
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2) 0%, rgba(0, 212, 255, 0.05) 100%);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}
.rarity-epic { 
    border: 2px solid var(--neon-purple); 
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2) 0%, rgba(139, 92, 246, 0.05) 100%);
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.4);
}
.rarity-ultra-rare { 
    border: 2px solid var(--neon-pink); 
    background: linear-gradient(135deg, rgba(255, 0, 128, 0.2) 0%, rgba(255, 0, 128, 0.05) 100%);
    box-shadow: 0 0 30px rgba(255, 0, 128, 0.4);
}
.rarity-legendary { 
    border: 2px solid var(--neon-yellow); 
    background: linear-gradient(135deg, rgba(255, 255, 0, 0.2) 0%, rgba(255, 255, 0, 0.05) 100%);
    box-shadow: 0 0 35px rgba(255, 255, 0, 0.4);
    animation: legendary-glow 2s ease-in-out infinite alternate;
}

/* Synergy asset styling */
.rarity-mystery {
    border: 2px solid #8b5cf6;
    background: linear-gradient(135deg, 
        rgba(139, 92, 246, 0.3) 0%, 
        rgba(75, 0, 130, 0.2) 50%,
        rgba(139, 92, 246, 0.1) 100%);
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.4);
    animation: mystery-glow 3s ease-in-out infinite alternate;
}

.text-mystery {
    color: #a855f7;
    text-shadow: 
        0 0 10px rgba(168, 85, 247, 0.8),
        0 0 20px rgba(168, 85, 247, 0.6),
        0 0 30px rgba(168, 85, 247, 0.4);
}

.border-mystery {
    border-color: rgba(168, 85, 247, 0.6);
}

@keyframes legendary-glow {
    from { box-shadow: 0 0 35px rgba(255, 255, 0, 0.4); }
    to { box-shadow: 0 0 50px rgba(255, 255, 0, 0.7); }
}

@keyframes mystery-glow {
    0% { 
        box-shadow: 0 0 25px rgba(139, 92, 246, 0.4);
        border-color: rgba(139, 92, 246, 0.6);
    }
    50% { 
        box-shadow: 0 0 40px rgba(168, 85, 247, 0.6);
        border-color: rgba(168, 85, 247, 0.8);
    }
    100% { 
        box-shadow: 0 0 25px rgba(139, 92, 246, 0.4);
        border-color: rgba(139, 92, 246, 0.6);
    }
}

/* Progress bars with neon effects */
.progress-bar {
    background: linear-gradient(90deg, var(--neon-blue), var(--neon-purple), var(--neon-pink));
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    animation: progress-glow 2s ease-in-out infinite alternate;
}

@keyframes progress-glow {
    from { box-shadow: 0 0 10px rgba(0, 212, 255, 0.5); }
    to { box-shadow: 0 0 20px rgba(0, 212, 255, 0.8); }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--neon-blue), var(--neon-purple));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--neon-purple), var(--neon-pink));
}

/* Responsive design */
@media (max-width: 768px) {
    .container { padding: 16px; }
    .card { padding: 20px; }
    body::before { animation-duration: 15s; }
}

/* Special effects for gaming feel */
.cyber-border {
    position: relative;
}

.cyber-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--neon-blue), var(--neon-purple), var(--neon-pink), var(--neon-green));
    border-radius: inherit;
    z-index: -1;
    animation: border-spin 3s linear infinite;
}

@keyframes border-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.holographic {
    background: linear-gradient(45deg, 
        rgba(0, 212, 255, 0.1) 0%,
        rgba(139, 92, 246, 0.1) 25%,
        rgba(255, 0, 128, 0.1) 50%,
        rgba(0, 255, 136, 0.1) 75%,
        rgba(0, 212, 255, 0.1) 100%);
    background-size: 400% 400%;
    animation: holographic-shift 4s ease infinite;
}

@keyframes holographic-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Synergy Box Casino-Style Animations */
.mystery-box-container {
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.9) 0%, 
        rgba(20, 20, 40, 0.9) 50%,
        rgba(0, 0, 0, 0.9) 100%);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.mystery-box-container:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
    border-color: rgba(0, 212, 255, 0.6);
}

.mystery-box {
    position: relative;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.8) 0%, 
        rgba(40, 40, 80, 0.8) 50%,
        rgba(0, 0, 0, 0.8) 100%);
    border: 3px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.mystery-box:hover {
    transform: scale(1.1);
    box-shadow: 
        0 0 40px rgba(139, 92, 246, 0.6),
        inset 0 0 20px rgba(255, 255, 255, 0.1);
}

.mystery-box.spinning {
    animation: casino-spin 0.1s linear infinite;
    transform: scale(1.2);
    box-shadow: 
        0 0 60px rgba(255, 255, 0, 0.8),
        0 0 100px rgba(255, 0, 128, 0.6),
        inset 0 0 30px rgba(255, 255, 255, 0.2);
}

.mystery-box-face {
    font-size: 4rem;
    transition: all 0.1s ease;
    text-align: center;
    z-index: 2;
    position: relative;
}

.mystery-sparkles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

.sparkle {
    position: absolute;
    font-size: 1.5rem;
    animation: sparkle-float 3s ease-in-out infinite;
    opacity: 0.7;
}

.sparkle-1 {
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.sparkle-2 {
    top: 10%;
    right: 10%;
    animation-delay: 0.5s;
}

.sparkle-3 {
    bottom: 10%;
    left: 10%;
    animation-delay: 1s;
}

.sparkle-4 {
    bottom: 10%;
    right: 10%;
    animation-delay: 1.5s;
}

.mystery-tap-hint {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    white-space: nowrap;
    animation: hint-bounce 2s ease-in-out infinite;
    z-index: 10;
}

.spinning-indicator {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--neon-blue), var(--neon-purple));
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    white-space: nowrap;
    animation: indicator-pulse 0.5s ease-in-out infinite alternate;
    z-index: 10;
}

.asset-reveal {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.96s cubic-bezier(0.4, 0, 0.2, 1);
}

.asset-reveal.revealed {
    opacity: 1;
    transform: scale(1);
}

/* Casino-style spinning animation */
@keyframes casino-spin {
    0% { 
        transform: scale(1.2) rotateY(0deg) rotateX(0deg);
        filter: hue-rotate(0deg);
    }
    25% { 
        transform: scale(1.2) rotateY(90deg) rotateX(5deg);
        filter: hue-rotate(90deg);
    }
    50% { 
        transform: scale(1.2) rotateY(180deg) rotateX(0deg);
        filter: hue-rotate(180deg);
    }
    75% { 
        transform: scale(1.2) rotateY(270deg) rotateX(-5deg);
        filter: hue-rotate(270deg);
    }
    100% { 
        transform: scale(1.2) rotateY(360deg) rotateX(0deg);
        filter: hue-rotate(360deg);
    }
}

@keyframes sparkle-float {
    0%, 100% { 
        transform: translateY(0px) scale(1);
        opacity: 0.7;
    }
    50% { 
        transform: translateY(-10px) scale(1.2);
        opacity: 1;
    }
}

@keyframes hint-bounce {
    0%, 100% { 
        transform: translateX(-50%) translateY(0px);
        opacity: 0.8;
    }
    50% { 
        transform: translateX(-50%) translateY(-5px);
        opacity: 1;
    }
}

@keyframes indicator-pulse {
    0% { 
        transform: translateX(-50%) scale(1);
        box-shadow: 0 0 20px rgba(0, 212, 255, 0.5);
    }
    100% { 
        transform: translateX(-50%) scale(1.05);
        box-shadow: 0 0 30px rgba(0, 212, 255, 0.8);
    }
}

/* Mobile optimizations for synergy box */
@media (max-width: 768px) {
    .mystery-box {
        width: 100px;
        height: 100px;
    }
    
    .mystery-box-face {
        font-size: 3rem;
    }
    
    .sparkle {
        font-size: 1.2rem;
    }
    
    .mystery-tap-hint,
    .spinning-indicator {
        font-size: 0.7rem;
        padding: 6px 12px;
    }
}

@media (max-width: 480px) {
    .mystery-box {
        width: 80px;
        height: 80px;
    }
    
    .mystery-box-face {
        font-size: 2.5rem;
    }
    
    .sparkle {
        font-size: 1rem;
    }
}

/* Telegram Mini App Optimizations */
@supports (padding: max(0px)) {
    /* Safe area support for devices with notches */
    .safe-area-top {
        padding-top: max(env(safe-area-inset-top), 20px);
    }
    
    .safe-area-bottom {
        padding-bottom: max(env(safe-area-inset-bottom), 20px);
    }
    
    .safe-area-left {
        padding-left: max(env(safe-area-inset-left), 16px);
    }
    
    .safe-area-right {
        padding-right: max(env(safe-area-inset-right), 16px);
    }
}

/* Telegram WebApp specific styles */
.tg-viewport {
    /* Ensure content doesn't go behind system UI */
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
}

/* Improved touch targets for mobile */
.touch-target {
    min-height: 44px;
    min-width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Better contrast for text in Telegram */
.text-high-contrast {
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

/* Loading states for better UX */
.loading-shimmer {
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Disabled state improvements */
.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

/* Focus improvements for keyboard navigation */
*:focus {
    outline: 2px solid var(--neon-blue);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Remove focus outline for mouse users */
.js-focus-visible *:focus:not(.focus-visible) {
    outline: none;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .glass, .glass-strong {
        background: rgba(0, 0, 0, 0.9);
        border: 2px solid rgba(255, 255, 255, 0.8);
    }
    
    .text-white\/80, .text-white\/90 {
        color: rgba(255, 255, 255, 1);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .animate-bounce, .animate-pulse, .animate-spin {
        animation: none;
    }
}

/* Mobile/Telegram App specific improvements */
@media (max-width: 768px) {
    /* Ensure buttons have adequate height and spacing */
    .btn-primary {
        min-height: 56px; /* Increased from 48px for better touch targets */
        padding: 18px 32px; /* Increased vertical padding */
        margin: 8px 0; /* Add vertical margin for better spacing */
    }
    
    /* Improve spacing for claim/action containers */
    .card {
        padding: 24px; /* Ensure adequate padding */
        margin: 16px 0; /* Add vertical margin */
        min-height: auto; /* Ensure cards can expand */
    }
    
    /* Ensure main content has adequate spacing */
    main {
        padding-bottom: 6rem; /* Increased bottom padding for navigation */
    }
    
    /* Improve touch targets for all interactive elements */
    button, .touch-target {
        min-height: 48px;
        padding: 12px 16px;
        margin: 4px 0;
    }
    
    /* Specific improvements for claim/action areas */
    .space-y-4 > * + * {
        margin-top: 1.5rem; /* Increased spacing between elements */
    }
    
    .space-y-6 > * + * {
        margin-top: 2rem; /* Increased spacing for larger gaps */
    }
    
    /* Fix mystery box and asset card dimensions */
    .mystery-box-container {
        min-height: 280px; /* Ensure adequate height for mystery box */
        aspect-ratio: 1; /* Maintain square aspect ratio */
    }
    
    .aspect-square {
        min-height: 280px; /* Ensure minimum height for square elements */
    }
    
    /* Improve mystery box visibility and interaction */
    .mystery-box {
        min-width: 120px;
        min-height: 120px;
        padding: 20px;
    }
    
    /* Ensure asset cards have adequate height */
    .card.rarity-mystery,
    .card.rarity-common,
    .card.rarity-rare,
    .card.rarity-epic,
    .card.rarity-ultra-rare,
    .card.rarity-legendary {
        min-height: 400px; /* Ensure adequate height for asset cards */
    }
} 