/* Animations for Jellybean Cyber */

/* Fade In Animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.active {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered Delay for Grid Items */
.features-grid .feature-card:nth-child(1),
.solutions-grid .solution-card:nth-child(1) {
    transition-delay: 0.1s;
}

.features-grid .feature-card:nth-child(2),
.solutions-grid .solution-card:nth-child(2) {
    transition-delay: 0.2s;
}

.features-grid .feature-card:nth-child(3),
.solutions-grid .solution-card:nth-child(3) {
    transition-delay: 0.3s;
}

.solutions-grid .solution-card:nth-child(4) {
    transition-delay: 0.4s;
}

.solutions-grid .solution-card:nth-child(5) {
    transition-delay: 0.5s;
}

.solutions-grid .solution-card:nth-child(6) {
    transition-delay: 0.6s;
}

.solutions-grid .solution-card:nth-child(7) {
    transition-delay: 0.7s;
}

/* Header Scroll Animation */
.header {
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.header.scrolled {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

/* Security Shield Animation */
.security-shield {
    animation: shieldPulse 3s infinite alternate;
}

@keyframes shieldPulse {
    0% {
        box-shadow: 0 10px 30px rgba(0, 102, 255, 0.2);
    }
    100% {
        box-shadow: 0 20px 50px rgba(0, 102, 255, 0.4);
    }
}

.shield-inner {
    animation: innerGlow 3s infinite alternate;
}

@keyframes innerGlow {
    0% {
        opacity: 0.7;
    }
    100% {
        opacity: 0.9;
    }
}

/* Particle Animations */
.data-particles .particle {
    animation-duration: 4s;
    animation-iteration-count: infinite;
}

.particle.p1 {
    animation-delay: 0s;
}

.particle.p2 {
    animation-delay: 0.5s;
}

.particle.p3 {
    animation-delay: 1s;
}

.particle.p4 {
    animation-delay: 1.5s;
}

.particle.p5 {
    animation-delay: 2s;
}

.particle.p6 {
    animation-delay: 2.5s;
}

@keyframes particleMove {
    0% {
        transform: translate(0, 0);
    }
    25% {
        transform: translate(50px, 30px);
    }
    50% {
        transform: translate(20px, 60px);
    }
    75% {
        transform: translate(-30px, 40px);
    }
    100% {
        transform: translate(0, 0);
    }
}

/* Security Diagram Animation */
.diagram-layer {
    animation: pulse 3s infinite;
    opacity: 0.7;
}

.layer1 {
    animation-delay: 0s;
}

.layer2 {
    animation-delay: 0.5s;
}

.layer3 {
    animation-delay: 1s;
}

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

/* Button Hover Animation */
.btn {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: height 0.3s ease;
    z-index: -1;
}

.btn:hover::after {
    height: 100%;
}

/* Feature Card Hover Animation */
.feature-card, .solution-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover, .solution-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Social Icon Hover Animation */
.social-icon {
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-5px);
}

/* Learn More Link Animation */
.learn-more .arrow {
    transition: transform 0.3s ease;
}

.learn-more:hover .arrow {
    transform: translateX(5px);
}

/* Form Input Focus Animation */
input, textarea {
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus, textarea:focus {
    box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

/* Mobile Menu Animation */
.mobile-menu {
    transition: right 0.3s ease;
}

.mobile-menu-btn span {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Testimonial Slide Animation */
.testimonial-slide {
    opacity: 0;
    transition: opacity 0.5s ease;
    position: absolute;
    width: 100%;
}

.testimonial-slide.active {
    opacity: 1;
    position: relative;
}

/* Approach Step Animation */
.approach-step {
    transition: transform 0.3s ease;
}

.approach-step:hover {
    transform: translateX(5px);
}

/* Navigation Link Animation */
.nav-list a::after {
    transition: width 0.3s ease;
}

/* Staggered Animation for Footer Links */
.footer-links ul li {
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.5s ease forwards;
}

.footer-links ul li:nth-child(1) {
    animation-delay: 0.1s;
}

.footer-links ul li:nth-child(2) {
    animation-delay: 0.2s;
}

.footer-links ul li:nth-child(3) {
    animation-delay: 0.3s;
}

.footer-links ul li:nth-child(4) {
    animation-delay: 0.4s;
}

.footer-links ul li:nth-child(5) {
    animation-delay: 0.5s;
}

.footer-links ul li:nth-child(6) {
    animation-delay: 0.6s;
}

.footer-links ul li:nth-child(7) {
    animation-delay: 0.7s;
}

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