/* Advanced Styling with Glassmorphism, Animations, and Rich Aesthetics */

:root {
    --bg-color: #F8FAFC;
    --text-primary: #1E293B;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    background-image: url('https://www.transparenttextures.com/patterns/cubes.png');
    background-repeat: repeat;
    background-position: center 0;
    color: var(--text-primary);
    scroll-behavior: smooth;
    overflow-x: hidden;
}

/* Background Patterns */
.bg-grid-pattern {
    background-image: linear-gradient(rgba(255, 255, 255, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* Gradients */
.hero-gradient {
    background: linear-gradient(135deg, #1A2980 0%, #26D0CE 100%);
    background-size: 200% 200%;
    animation: gradientBG 15s ease infinite;
}

.gradient-bg-light {
    background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%);
}

@keyframes gradientBG {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* Glassmorphism Classes */
.glass-nav {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    box-shadow: 0 15px 40px 0 rgba(31, 38, 135, 0.12);
}

/* Typography & Glows */
.glow-text {
    text-shadow: 0 0 20px rgba(54, 162, 235, 0.5);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 1s ease-out forwards;
}

/* Floating Icons in Hero */
.floating-icons span {
    display: inline-block;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* Reveal on Scroll (Optional feature if implemented via JS or just CSS) */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Custom CSS Arrow */
.css-arrow-down {
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 20px solid #cbd5e1;
    margin: 15px auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* Chart Containers */
.chart-container {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    height: 350px;
    max-height: 400px;
}

@media (max-width: 640px) {
    .chart-container {
        height: 300px;
    }
}

/* Interactive Navigation Underline */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: #FF3366;
    /* brand-pink */
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}