/*=====================================================
    TECH/AI ANIMATIONS FOR WHY CHOOSE US & SERVICES
======================================================*/

/* ============================================
   PARTICLE NETWORK ANIMATION (Universal)
============================================ */

/* Container for any section */
.tech-particles-network {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

/* Ensure sections with particles have position relative */
.why-choose-us,
.services-section,
.portfolio-showcase,
.process-two,
.testimonial-two {
    position: relative;
}

/* Individual Particles */
.tech-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(92, 176, 233, 0.6);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(92, 176, 233, 0.8), 0 0 20px rgba(92, 176, 233, 0.4);
    animation: particle-float 20s infinite ease-in-out;
}

/* Connection Lines */
.tech-connection-line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(92, 176, 233, 0.4) 50%, 
        transparent 100%);
    transform-origin: left center;
    opacity: 0;
    animation: line-pulse 3s infinite ease-in-out;
}

/* Particle Float Animation */
@keyframes particle-float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.6;
    }
    25% {
        transform: translate(30px, -40px) scale(1.2);
        opacity: 0.8;
    }
    50% {
        transform: translate(-20px, 20px) scale(0.8);
        opacity: 1;
    }
    75% {
        transform: translate(40px, 30px) scale(1.1);
        opacity: 0.7;
    }
}

/* Line Pulse Animation */
@keyframes line-pulse {
    0%, 100% {
        opacity: 0;
    }
    50% {
        opacity: 0.6;
    }
}

/* Particle Glow Effect */
.tech-particle::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    background: radial-gradient(circle, rgba(92, 176, 233, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: particle-glow 2s infinite ease-in-out;
}

@keyframes particle-glow {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.3;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0.6;
    }
}

/* ============================================
   SERVICES SECTION - Circuit Board Animation
============================================ */

.services-section {
    position: relative;
}

/* Circuit Board Container */
.tech-circuit-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
    opacity: 0.4;
}

/* Circuit Lines */
.tech-circuit-line {
    position: absolute;
    background: rgba(92, 176, 233, 0.3);
}

.tech-circuit-line.horizontal {
    width: 200px;
    height: 2px;
}

.tech-circuit-line.vertical {
    width: 2px;
    height: 200px;
}

/* Circuit Nodes */
.tech-circuit-node {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(92, 176, 233, 0.6);
    border: 2px solid rgba(92, 176, 233, 0.8);
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(92, 176, 233, 0.8);
    animation: node-pulse 2s infinite ease-in-out;
}

@keyframes node-pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 15px rgba(92, 176, 233, 0.8);
    }
    50% {
        transform: scale(1.5);
        box-shadow: 0 0 25px rgba(92, 176, 233, 1), 0 0 40px rgba(92, 176, 233, 0.5);
    }
}

/* Data Stream Animation */
.tech-data-stream {
    position: absolute;
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(92, 176, 233, 0.8) 50%, 
        transparent 100%);
    opacity: 0;
    animation: data-flow 4s infinite ease-in-out;
}

@keyframes data-flow {
    0% {
        opacity: 0;
        transform: translateX(-100px);
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateX(300px);
    }
}

/* Glowing Circuit Paths */
.tech-circuit-glow {
    position: absolute;
    width: 150px;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(143, 136, 255, 0.6) 50%, 
        transparent 100%);
    box-shadow: 0 0 10px rgba(143, 136, 255, 0.8);
    animation: circuit-glow 3s infinite ease-in-out;
}

@keyframes circuit-glow {
    0%, 100% {
        opacity: 0.3;
        box-shadow: 0 0 10px rgba(143, 136, 255, 0.6);
    }
    50% {
        opacity: 1;
        box-shadow: 0 0 20px rgba(143, 136, 255, 1), 0 0 30px rgba(143, 136, 255, 0.5);
    }
}

/* AI Binary Code Rain Effect */
.tech-binary-rain {
    position: absolute;
    top: -100%;
    color: rgba(92, 176, 233, 0.4);
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    animation: binary-fall 15s linear infinite;
    pointer-events: none;
    text-shadow: 0 0 8px rgba(92, 176, 233, 0.8);
}

@keyframes binary-fall {
    0% {
        top: -100%;
        opacity: 0;
    }
    10% {
        opacity: 0.8;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        top: 100%;
        opacity: 0;
    }
}

/* Hexagonal Grid Pattern (Tech Style) */
.tech-hex-pattern {
    position: absolute;
    width: 60px;
    height: 60px;
    opacity: 0.15;
    animation: hex-rotate 20s linear infinite;
}

.tech-hex-pattern::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><polygon points="50 1 95 25 95 75 50 99 5 75 5 25" fill="none" stroke="rgba(92,176,233,0.5)" stroke-width="2"/></svg>');
    background-size: contain;
}

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

/* Glowing Orbs (AI Energy) */
.tech-glow-orb {
    position: absolute;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(92, 176, 233, 0.3) 0%, transparent 70%);
    animation: orb-float 8s ease-in-out infinite;
    filter: blur(20px);
}

@keyframes orb-float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.4;
    }
    33% {
        transform: translate(50px, -30px) scale(1.2);
        opacity: 0.6;
    }
    66% {
        transform: translate(-30px, 40px) scale(0.9);
        opacity: 0.5;
    }
}

/* Scanning Line Effect */
.tech-scan-line {
    position: absolute;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(92, 176, 233, 0.8) 50%, 
        transparent 100%);
    box-shadow: 0 0 20px rgba(92, 176, 233, 0.8);
    animation: scan-vertical 5s linear infinite;
}

@keyframes scan-vertical {
    0% {
        top: 0%;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        top: 100%;
        opacity: 0;
    }
}

/* Pulse Ring Effect */
.tech-pulse-ring {
    position: absolute;
    border: 2px solid rgba(92, 176, 233, 0.5);
    border-radius: 50%;
    animation: pulse-expand 3s infinite ease-out;
}

@keyframes pulse-expand {
    0% {
        width: 20px;
        height: 20px;
        opacity: 1;
    }
    100% {
        width: 150px;
        height: 150px;
        opacity: 0;
    }
}

/* Digital Grid Lines */
.tech-grid-line {
    position: absolute;
    background: rgba(92, 176, 233, 0.1);
    animation: grid-fade 4s infinite ease-in-out;
}

@keyframes grid-fade {
    0%, 100% {
        opacity: 0.1;
    }
    50% {
        opacity: 0.4;
    }
}

/* Holographic Effect */
.tech-hologram {
    position: absolute;
    width: 80px;
    height: 80px;
    border: 2px solid rgba(92, 176, 233, 0.4);
    border-radius: 10px;
    animation: hologram-shift 5s infinite ease-in-out;
}

@keyframes hologram-shift {
    0%, 100% {
        transform: perspective(500px) rotateY(0deg) rotateX(0deg);
        opacity: 0.3;
    }
    25% {
        transform: perspective(500px) rotateY(10deg) rotateX(5deg);
        opacity: 0.5;
    }
    50% {
        transform: perspective(500px) rotateY(0deg) rotateX(10deg);
        opacity: 0.7;
    }
    75% {
        transform: perspective(500px) rotateY(-10deg) rotateX(5deg);
        opacity: 0.5;
    }
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .tech-particle {
        width: 3px;
        height: 3px;
    }
    
    .tech-circuit-line.horizontal {
        width: 150px;
    }
    
    .tech-circuit-line.vertical {
        height: 150px;
    }
    
    .tech-binary-rain {
        font-size: 10px;
    }
}

@media (max-width: 767px) {
    .tech-particle {
        width: 2px;
        height: 2px;
    }
    
    .tech-circuit-line.horizontal {
        width: 100px;
    }
    
    .tech-circuit-line.vertical {
        height: 100px;
    }
    
    .tech-circuit-node {
        width: 6px;
        height: 6px;
    }
    
    .tech-hex-pattern {
        width: 40px;
        height: 40px;
    }
}

