/* ===== INDEX PAGE STYLES ===== */

/* Hero Section with Interactive Background */
.hero {
    min-height: calc(100vh - 56px);
    background: var(--hero-gradient, linear-gradient(135deg, #667eea 0%, #764ba2 100%));
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--hero-text, white);
    position: relative;
    overflow: hidden;
}

/* Animated Background Canvas */
#backgroundCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

/* Floating Particles */
.particle {
    position: absolute;
    background: var(--particle-bg, rgba(255, 255, 255, 0.1));
    border-radius: 50%;
    pointer-events: none;
    animation: float 6s infinite ease-in-out;
}

.particle:nth-child(1) {
    width: 20px;
    height: 20px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    width: 15px;
    height: 15px;
    top: 60%;
    left: 20%;
    animation-delay: 1s;
}

.particle:nth-child(3) {
    width: 25px;
    height: 25px;
    top: 30%;
    left: 80%;
    animation-delay: 2s;
}

.particle:nth-child(4) {
    width: 12px;
    height: 12px;
    top: 80%;
    left: 70%;
    animation-delay: 3s;
}

.particle:nth-child(5) {
    width: 18px;
    height: 18px;
    top: 15%;
    left: 60%;
    animation-delay: 4s;
}

.particle:nth-child(6) {
    width: 22px;
    height: 22px;
    top: 70%;
    left: 40%;
    animation-delay: 5s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.7;
    }

    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 1;
    }
}

/* Gradient Wave Animation */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg,
            rgba(102, 126, 234, 0.8) 0%,
            rgba(118, 75, 162, 0.8) 25%,
            rgba(102, 126, 234, 0.8) 50%,
            rgba(118, 75, 162, 0.8) 75%,
            rgba(102, 126, 234, 0.8) 100%);
    background-size: 400% 400%;
    animation: gradientWave 8s ease infinite;
    z-index: 1;
}

@keyframes gradientWave {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* Interactive Glow Effect */
.hero::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 4s ease-in-out infinite;
    z-index: 1;
}

@keyframes pulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.8;
    }
}

.hero-content {
    max-width: 800px;
    padding: 40px 20px;
    position: relative;
    z-index: 10;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    animation: fadeInUp 1s ease-out;
}

.hero .subtitle {
    font-size: 1.3rem;
    margin-bottom: 30px;
    opacity: 0.95;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero .description {
    font-size: 1.1rem;
    margin-bottom: 40px;
    opacity: 0.9;
    line-height: 1.8;
    animation: fadeInUp 1s ease-out 0.4s both;
}

.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease-out 0.6s both;
}

.index-btn {
    display: inline-block;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    text-align: center;
    min-width: 160px;
}

.index-btn-primary {
    background: var(--accent-color);
    color: var(--white);
    box-shadow: var(--shadow-accent);
}

.index-btn-primary:hover {
    background: var(--accent-hover-color);
    color: var(--white);
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: var(--shadow-accent-hover);
}

.index-btn-secondary {
    background: var(--glass-bg);
    color: var(--hero-text, white);
    border: 2px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.index-btn-secondary:hover {
    background: var(--glass-bg-hover);
    color: var(--hero-text, white);
    text-decoration: none;
    transform: translateY(-2px);
    border-color: var(--glass-border-hover);
}

/* Features Section */
.features {
    padding: 80px 20px;
    background: var(--features-bg);
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.features-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 60px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.feature-card {
    background: var(--card-bg);
    padding: 40px 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: var(--icon-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 24px;
    color: var(--white);
    animation: float 3s ease-in-out infinite;
}

.feature-card:nth-child(2) .feature-icon {
    animation-delay: 0.5s;
}

.feature-card:nth-child(3) .feature-icon {
    animation-delay: 1s;
}

.feature-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #333;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .hero .subtitle {
        font-size: 1.1rem;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .index-btn {
        width: 100%;
        max-width: 280px;
    }

    .features {
        padding: 60px 20px;
    }

    .features h2 {
        font-size: 2rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    /* Mobile optimizations for interactive background */
    .particle {
        animation-duration: 8s;
        /* Slower animation on mobile */
    }

    .hero::before {
        animation-duration: 12s;
        /* Slower gradient animation */
    }

    .hero::after {
        width: 200px;
        height: 200px;
        animation-duration: 6s;
    }

    #backgroundCanvas {
        opacity: 0.7;
        /* Reduce canvas opacity on mobile for better text readability */
    }
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {

    .particle,
    .hero::before,
    .hero::after,
    .feature-icon {
        animation: none;
    }

    #backgroundCanvas {
        display: none;
    }
}