/* ==============================================
   JokeLab AI - Liquid Glass Stylesheet
   Aether Philosophy Implementation
   ============================================== */

/* ===== Core Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #0a0a0f 0%, #1a0a2e 50%, #0a0a0f 100%);
    background-attachment: fixed;
    min-height: 100vh;
}

/* ===== Liquid Glass Components ===== */

/* Glass Navigation */
.glass-nav {
    backdrop-filter: blur(20px) saturate(180%);
    background: rgba(10, 10, 15, 0.7);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

/* Glass Card - Standard */
.glass-card {
    backdrop-filter: blur(20px) saturate(180%);
    background: rgba(139, 92, 246, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.5rem; /* rounded-2xl */
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(139, 92, 246, 0.2);
    border-color: rgba(139, 92, 246, 0.3);
}

/* Glass Card - Large */
.glass-card-lg {
    backdrop-filter: blur(24px) saturate(180%);
    background: rgba(139, 92, 246, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.5rem; /* rounded-2xl */
    padding: 3rem;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4);
}

/* ===== Buttons (Consistent Roundness) ===== */

/* Primary Button */
.btn-primary {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    color: white;
    font-weight: 600;
    padding: 0.75rem 2rem;
    border-radius: 9999px; /* rounded-full */
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.5);
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:active {
    transform: scale(0.98);
}

/* Secondary Button */
.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    color: white;
    font-weight: 600;
    padding: 0.75rem 2rem;
    border-radius: 9999px; /* rounded-full */
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(139, 92, 246, 0.5);
    transform: scale(1.05);
}

/* Large Button Variant */
.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
}

/* ===== Tag Buttons ===== */
.tag-btn {
    padding: 0.75rem 1rem;
    border-radius: 1.5rem; /* rounded-2xl */
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.875rem;
    font-weight: 500;
}

.tag-btn:hover {
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
    color: white;
    transform: translateY(-2px);
}

.tag-btn.active {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.3), rgba(6, 182, 212, 0.3));
    border-color: rgba(139, 92, 246, 0.5);
    color: white;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.3);
}

/* ===== Hover Effects ===== */
.hover-lift {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
    transform: translateY(-8px);
}

/* ===== Animations ===== */

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

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

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

.fade-in-up {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Typewriter Effect */
@keyframes typing {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

.typewriter {
    overflow: hidden;
    border-right: 2px solid rgba(139, 92, 246, 0.7);
    white-space: nowrap;
    animation: typing 2s steps(40) 1s forwards, blink 0.75s step-end infinite;
}

/* ===== Gradient Utilities ===== */
.bg-gradient-radial {
    background: radial-gradient(circle at center, var(--tw-gradient-stops));
}

/* ===== Glow Effects ===== */
.glow-primary {
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.6),
                0 0 40px rgba(139, 92, 246, 0.4),
                0 0 60px rgba(139, 92, 246, 0.2);
}

.glow-accent {
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.6),
                0 0 40px rgba(245, 158, 11, 0.4);
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
    .glass-card,
    .glass-card-lg {
        padding: 1.5rem;
    }
    
    .btn-lg {
        padding: 0.875rem 2rem;
        font-size: 1rem;
    }
}

/* ===== Smooth Scroll ===== */
html {
    scroll-behavior: smooth;
}

/* ===== Focus States (Accessibility) ===== */
button:focus-visible,
a:focus-visible {
    outline: 2px solid rgba(139, 92, 246, 0.8);
    outline-offset: 4px;
    border-radius: 1rem;
}

/* ===== Loading State ===== */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    border-radius: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Pulse Animation for Status Badge ===== */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

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