/* =========================================
   MODERN PROFESSIONAL ANIMATIONS FOR CODALEA
   ========================================= */

/* Global Animation Variables and Base Styles */
:root {
    --animation-speed-fast: 0.3s;
    --animation-speed-normal: 0.6s;
    --animation-speed-slow: 1.2s;
    --easing-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --easing-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --easing-elastic: cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* =========================================
   HERO SECTION ANIMATIONS
   ========================================= */

.hero-section {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, 
        rgba(26, 26, 46, 0.95) 0%, 
        rgba(22, 33, 62, 0.95) 50%, 
        rgba(15, 52, 96, 0.95) 100%);
}

/* Enhanced Hero Particles */
.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.hero-particle {
    position: absolute;
    background: rgba(6, 182, 212, 0.6);
    border-radius: 50%;
    animation: heroFloat linear infinite;
}

.hero-particle-1 {
    width: 8px;
    height: 8px;
    top: 20%;
    left: 10%;
    animation-duration: 15s;
    animation-delay: 0s;
}

.hero-particle-2 {
    width: 12px;
    height: 12px;
    top: 60%;
    left: 85%;
    animation-duration: 18s;
    animation-delay: 2s;
}

.hero-particle-3 {
    width: 6px;
    height: 6px;
    top: 80%;
    left: 20%;
    animation-duration: 12s;
    animation-delay: 4s;
}

.hero-particle-4 {
    width: 10px;
    height: 10px;
    top: 30%;
    left: 70%;
    animation-duration: 20s;
    animation-delay: 1s;
}

.hero-particle-5 {
    width: 5px;
    height: 5px;
    top: 10%;
    left: 50%;
    animation-duration: 14s;
    animation-delay: 3s;
}

.hero-particle-6 {
    width: 9px;
    height: 9px;
    top: 70%;
    left: 60%;
    animation-duration: 16s;
    animation-delay: 5s;
}

@keyframes heroFloat {
    0% {
        transform: translateY(0) rotate(0deg) scale(1);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) rotate(360deg) scale(0.5);
        opacity: 0;
    }
}

/* Hero Content Animations - Subtle Professional Entrance */
.hero-content {
    position: relative;
    z-index: 2;
    opacity: 0;
    transform: translateY(30px);
    visibility: hidden;
}

.hero-content.animate-entrance {
    visibility: visible;
    animation: heroContentSubtleSlideIn 1.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes heroContentSubtleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(40px);
        filter: blur(5px);
    }
    25% {
        opacity: 0.3;
        transform: translateY(25px);
        filter: blur(3px);
    }
    50% {
        opacity: 0.6;
        transform: translateY(12px);
        filter: blur(1px);
    }
    75% {
        opacity: 0.85;
        transform: translateY(4px);
        filter: blur(0.5px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

/* Code Editor Container - Elegant Slide-in Animation */
.code-editor-container {
    opacity: 0;
    transform: translateX(50px) scale(0.95);
    visibility: hidden;
}

.code-editor-container.animate-entrance {
    visibility: visible;
    animation: codeEditorSubtleEntrance 1.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes codeEditorSubtleEntrance {
    0% {
        opacity: 0;
        transform: translateX(60px) scale(0.92);
        filter: blur(4px);
    }
    20% {
        opacity: 0.2;
        transform: translateX(45px) scale(0.94);
        filter: blur(3px);
    }
    40% {
        opacity: 0.5;
        transform: translateX(30px) scale(0.96);
        filter: blur(2px);
    }
    60% {
        opacity: 0.75;
        transform: translateX(15px) scale(0.98);
        filter: blur(1px);
    }
    80% {
        opacity: 0.9;
        transform: translateX(5px) scale(1.005);
        filter: blur(0.3px);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
        filter: blur(0);
    }
}

/* Hero Section Elements Control */
.hero-content .gradient-text {
    opacity: 0;
    visibility: hidden;
}

.hero-content.animate-entrance .gradient-text {
    visibility: visible;
    animation: gradientTextReveal 1.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.3s forwards;
}

@keyframes gradientTextReveal {
    0% {
        opacity: 0;
        transform: translateY(25px) scale(0.95);
        filter: blur(2px);
    }
    30% {
        opacity: 0.4;
        transform: translateY(15px) scale(0.97);
        filter: blur(1px);
    }
    60% {
        opacity: 0.7;
        transform: translateY(8px) scale(0.99);
        filter: blur(0.5px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.hero-title {
    opacity: 0;
    transform: translateX(-40px);
    visibility: hidden;
}

.hero-content.animate-entrance .hero-title {
    visibility: visible;
    animation: heroTitleReveal 1.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.2s forwards;
}

@keyframes heroTitleReveal {
    0% {
        opacity: 0;
        transform: translateX(-50px) scale(0.95);
        filter: blur(2px);
    }
    40% {
        opacity: 0.5;
        transform: translateX(-25px) scale(0.97);
        filter: blur(1px);
    }
    70% {
        opacity: 0.8;
        transform: translateX(-8px) scale(0.99);
        filter: blur(0.3px);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
        filter: blur(0);
    }
}

.hero-subtitle {
    opacity: 0;
    visibility: hidden;
}

.hero-content.animate-entrance .hero-subtitle {
    visibility: visible;
    animation: heroSubtitleFade 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.5s forwards;
}

@keyframes heroSubtitleFade {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
        filter: blur(1.5px);
    }
    50% {
        opacity: 0.6;
        transform: translateY(10px) scale(0.98);
        filter: blur(0.7px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Welcome Text Control */
.welcome-text {
    opacity: 0;
    visibility: hidden;
}

.hero-content.animate-entrance .welcome-text {
    visibility: visible;
    animation: welcomeTextFade 1.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.8s forwards;
}

@keyframes welcomeTextFade {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
        filter: blur(1px);
    }
    40% {
        opacity: 0.4;
        transform: translateY(12px) scale(0.985);
        filter: blur(0.5px);
    }
    70% {
        opacity: 0.7;
        transform: translateY(5px) scale(0.995);
        filter: blur(0.2px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Floating Icons Animation */
.floating-icons {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.floating-icon {
    position: absolute;
    color: rgba(6, 182, 212, 0.4);
    animation: iconFloat ease-in-out infinite;
}

.floating-icon:nth-child(1) {
    top: 15%;
    right: 10%;
    animation-duration: 6s;
    animation-delay: 0s;
}

.floating-icon:nth-child(2) {
    top: 70%;
    left: 5%;
    animation-duration: 8s;
    animation-delay: 2s;
}

.floating-icon:nth-child(3) {
    top: 40%;
    right: 20%;
    animation-duration: 7s;
    animation-delay: 1s;
}

.floating-icon:nth-child(4) {
    bottom: 20%;
    left: 15%;
    animation-duration: 9s;
    animation-delay: 3s;
}

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.4;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0.8;
    }
}

/* =========================================
   FEATURES SECTION ANIMATIONS
   ========================================= */

.features-section {
    position: relative;
    overflow: hidden;
}

/* Enhanced Floating Shapes */
.features-floating-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.floating-shape {
    position: absolute;
    opacity: 0.1;
    animation: shapeFloat ease-in-out infinite;
}

.floating-shape.triangle {
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-bottom: 26px solid rgba(37, 99, 235, 0.8);
}

.floating-shape.circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(6, 182, 212, 0.8);
}

.floating-shape.square {
    width: 25px;
    height: 25px;
    background: rgba(37, 99, 235, 0.8);
    border-radius: 4px;
    transform: rotate(45deg);
}

.floating-shape-1 {
    top: 10%;
    left: 5%;
    animation-duration: 8s;
    animation-delay: 0s;
}

.floating-shape-2 {
    top: 20%;
    right: 10%;
    animation-duration: 12s;
    animation-delay: 1s;
}

.floating-shape-3 {
    top: 60%;
    left: 8%;
    animation-duration: 10s;
    animation-delay: 2s;
}

.floating-shape-4 {
    top: 80%;
    right: 15%;
    animation-duration: 14s;
    animation-delay: 0.5s;
}

.floating-shape-5 {
    top: 40%;
    left: 50%;
    animation-duration: 9s;
    animation-delay: 3s;
}

.floating-shape-6 {
    top: 70%;
    right: 40%;
    animation-duration: 11s;
    animation-delay: 1.5s;
}

.floating-shape-7 {
    top: 30%;
    left: 80%;
    animation-duration: 13s;
    animation-delay: 4s;
}

.floating-shape-8 {
    top: 90%;
    left: 30%;
    animation-duration: 7s;
    animation-delay: 2.5s;
}

@keyframes shapeFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.1;
    }
    25% {
        transform: translateY(-30px) rotate(90deg);
        opacity: 0.3;
    }
    50% {
        transform: translateY(-60px) rotate(180deg);
        opacity: 0.2;
    }
    75% {
        transform: translateY(-30px) rotate(270deg);
        opacity: 0.3;
    }
}

/* Feature Cards Enhanced Animation */
.feature-card {
    transition: all var(--animation-speed-normal) var(--easing-smooth);
    transform: translateY(0);
    opacity: 1;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(6, 182, 212, 0.1), 
        transparent);
    transition: left 0.6s var(--easing-smooth);
    z-index: 1;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(37, 99, 235, 0.15);
}

.feature-icon {
    transition: all var(--animation-speed-normal) var(--easing-bounce);
    position: relative;
    z-index: 2;
}

.feature-card:hover .feature-icon {
    transform: scale(1.15) rotate(5deg);
    color: #06b6d4;
}

/* Feature Cards Staggered Animation on Scroll */
.feature-card {
    opacity: 0;
    transform: translateY(60px);
    animation: featureSlideIn var(--animation-speed-slow) var(--easing-smooth) forwards;
}

.feature-card:nth-child(1) { animation-delay: 0.1s; }
.feature-card:nth-child(2) { animation-delay: 0.2s; }
.feature-card:nth-child(3) { animation-delay: 0.3s; }
.feature-card:nth-child(4) { animation-delay: 0.4s; }
.feature-card:nth-child(5) { animation-delay: 0.5s; }
.feature-card:nth-child(6) { animation-delay: 0.6s; }

@keyframes featureSlideIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   ABOUT SECTION ANIMATIONS
   ========================================= */

.about-section-enhanced {
    position: relative;
    overflow: hidden;
}

/* Enhanced Code Matrix Background */
.about-code-matrix {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.matrix-line {
    position: absolute;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: rgba(6, 182, 212, 0.15);
    white-space: nowrap;
    animation: matrixScroll linear infinite;
    transform: translateX(100vw);
}

.matrix-line-1 {
    top: 10%;
    animation-duration: 20s;
    animation-delay: 0s;
}

.matrix-line-2 {
    top: 25%;
    animation-duration: 25s;
    animation-delay: 3s;
}

.matrix-line-3 {
    top: 40%;
    animation-duration: 18s;
    animation-delay: 6s;
}

.matrix-line-4 {
    top: 55%;
    animation-duration: 22s;
    animation-delay: 2s;
}

.matrix-line-5 {
    top: 70%;
    animation-duration: 24s;
    animation-delay: 8s;
}

.matrix-line-6 {
    top: 85%;
    animation-duration: 19s;
    animation-delay: 5s;
}

.matrix-line-7 {
    top: 15%;
    animation-duration: 21s;
    animation-delay: 10s;
}

.matrix-line-8 {
    top: 60%;
    animation-duration: 23s;
    animation-delay: 7s;
}

@keyframes matrixScroll {
    0% {
        transform: translateX(100vw);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateX(-100vw);
        opacity: 0;
    }
}

/* Tech Orbit Enhanced Animation */
.tech-orbit {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto;
    animation: orbitRotate 20s linear infinite;
}

.central-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
}

.rotating-logo {
    animation: logoSpin 10s linear infinite reverse;
}

.orbit-item {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: 100px 0;
    animation: orbitMove 12s linear infinite;
    transform: translate(-50%, -50%) rotate(var(--angle)) translateX(100px) rotate(calc(-1 * var(--angle)));
}

@keyframes orbitRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes logoSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes orbitMove {
    from { transform: translate(-50%, -50%) rotate(var(--angle)) translateX(100px) rotate(calc(-1 * var(--angle))); }
    to { transform: translate(-50%, -50%) rotate(calc(var(--angle) + 360deg)) translateX(100px) rotate(calc(-1 * (var(--angle) + 360deg))); }
}

/* Enhanced skills bars animations */
.skills-container {
    margin-top: 2rem;
    background: rgba(248, 250, 252, 0.95);
    border-radius: 16px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(226, 232, 240, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.skill-item {
    background: rgba(255, 255, 255, 0.8);
    padding: 1.2rem;
    border-radius: 12px;
    border: 1px solid rgba(226, 232, 240, 0.5);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.skill-item:hover {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.15);
}

/* Colombian Pride Section */
.colombian-pride-section {
    position: relative;
    margin: 3rem 0;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, rgba(8, 20, 45, 0.98) 0%, rgba(15, 25, 55, 0.95) 100%);
    border-radius: 24px;
    overflow: hidden;
    border: 2px solid rgba(255, 215, 0, 0.3);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 215, 0, 0.1);
}

.pride-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    z-index: 10;
    background: rgba(0, 0, 0, 0.3);
    padding: 2rem;
    border-radius: 16px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 215, 0, 0.2);
}

/* Flag background animation */
.flag-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    z-index: 1;
}

.flag-stripe {
    width: 100%;
    height: 33.33%;
    position: absolute;
    animation: waveFlag 4s ease-in-out infinite;
}

.flag-stripe.yellow {
    top: 0;
    background: linear-gradient(90deg, #FFD700, #FFA500, #FFD700);
    animation-delay: 0s;
}

.flag-stripe.blue {
    top: 33.33%;
    background: linear-gradient(90deg, #0033A0, #004FBF, #0033A0);
    animation-delay: 0.5s;
}

.flag-stripe.red {
    top: 66.66%;
    background: linear-gradient(90deg, #CE1126, #FF1744, #CE1126);
    animation-delay: 1s;
}

@keyframes waveFlag {
    0%, 100% { transform: translateX(0) scaleX(1); }
    25% { transform: translateX(5px) scaleX(1.02); }
    50% { transform: translateX(-3px) scaleX(0.98); }
    75% { transform: translateX(2px) scaleX(1.01); }
}

/* Code particles background */
.code-particles-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    overflow: hidden;
}

.code-particle {
    position: absolute;
    font-family: 'Courier New', monospace;
    font-size: 1.2rem;
    color: rgba(255, 215, 0, 0.3);
    animation: floatCode var(--duration, 5s) ease-in-out infinite;
    animation-delay: var(--delay, 0s);
    left: calc(5% + (90% * var(--random-x, 0.5)));
    top: calc(10% + (80% * var(--random-y, 0.5)));
    text-shadow: 0 0 10px currentColor;
}

.code-particle:nth-child(odd) {
    color: rgba(0, 51, 160, 0.4);
}

.code-particle:nth-child(3n) {
    color: rgba(206, 17, 38, 0.3);
}

@keyframes floatCode {
    0%, 100% { 
        transform: translateY(0) rotate(0deg); 
        opacity: 0.3; 
    }
    25% { 
        transform: translateY(-20px) rotate(90deg); 
        opacity: 0.6; 
    }
    50% { 
        transform: translateY(-10px) rotate(180deg); 
        opacity: 0.4; 
    }
    75% { 
        transform: translateY(-30px) rotate(270deg); 
        opacity: 0.7; 
    }
}

/* Bogotá skyline */
.bogota-skyline {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    z-index: 3;
    animation: skylinePulse 6s ease-in-out infinite;
}

@keyframes skylinePulse {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.02); }
}

/* Colombian heart */
.colombia-heart {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    animation: heartBeat 3s ease-in-out infinite;
}

.colombia-heart svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.5));
}

.heart-pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border: 2px solid rgba(255, 215, 0, 0.5);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes heartBeat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Pride message */
.pride-message {
    margin: 2rem 0;
    position: relative;
    z-index: 10;
}

.typewriter-text {
    font-family: 'Inter', sans-serif;
    font-size: 2.2rem;
    font-weight: 900;
    color: #FFD700;
    text-shadow: 
        0 0 20px #FFD700,
        0 0 40px #FFD700,
        0 0 60px #FFD700,
        3px 3px 0px #000000,
        -1px -1px 0px #000000,
        1px -1px 0px #000000,
        -1px 1px 0px #000000;
    line-height: 1.3;
    animation: typewriter 4s steps(50) 1s both;
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid #FFD700;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    background: none;
    -webkit-text-fill-color: #FFD700;
}

.typewriter-text::before {
    display: none;
}

.cursor {
    animation: blink 1s infinite;
}

@keyframes typewriter {
    from { 
        width: 0; 
    }
    to { 
        width: 100%; 
    }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

@keyframes glow-pulse {
    0%, 100% { 
        text-shadow: 
            0 0 5px rgba(255, 215, 0, 1),
            0 0 10px rgba(255, 215, 0, 0.8),
            0 0 15px rgba(255, 215, 0, 0.6),
            2px 2px 4px rgba(0, 0, 0, 0.9);
    }
    50% { 
        text-shadow: 
            0 0 10px rgba(255, 215, 0, 1),
            0 0 20px rgba(255, 215, 0, 0.9),
            0 0 30px rgba(255, 215, 0, 0.7),
            0 0 40px rgba(255, 255, 255, 0.5),
            2px 2px 6px rgba(0, 0, 0, 1);
    }
}

/* Floating code elements */
.floating-code {
    position: relative;
    margin-top: 2rem;
    height: 60px;
}

.code-element {
    position: absolute;
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    font-weight: bold;
    color: #06b6d4;
    text-shadow: 0 0 15px currentColor;
    animation: floatElement 6s ease-in-out infinite;
    animation-delay: var(--delay, 0s);
    opacity: 0;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.code-element:nth-child(1) { left: 20%; color: #FFD700; }
.code-element:nth-child(2) { left: 30%; color: #0033A0; }
.code-element:nth-child(3) { left: 40%; color: #CE1126; }
.code-element:nth-child(4) { left: 60%; color: #FFD700; }
.code-element:nth-child(5) { left: 70%; color: #0033A0; }
.code-element:nth-child(6) { left: 80%; color: #CE1126; }

@keyframes floatElement {
    0%, 100% { 
        opacity: 0; 
        transform: translate(-50%, -50%) translateY(20px) scale(0.8); 
    }
    10%, 90% { 
        opacity: 1; 
        transform: translate(-50%, -50%) translateY(0) scale(1); 
    }
    50% { 
        transform: translate(-50%, -50%) translateY(-10px) scale(1.1); 
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .typewriter-text {
        font-size: 1.5rem;
        white-space: normal;
        animation: none;
        border-right: none;
        color: #FFD700;
        -webkit-text-fill-color: #FFD700;
        text-shadow: 
            0 0 15px #FFD700,
            0 0 30px #FFD700,
            0 0 45px #FFD700,
            2px 2px 0px #000000,
            -1px -1px 0px #000000,
            1px -1px 0px #000000,
            -1px 1px 0px #000000;
        background: none;
        font-weight: 900;
    }
    
    .typewriter-text::before {
        display: none;
    }
    
    .colombian-pride-section {
        padding: 2rem 1rem;
        margin: 2rem 0;
    }
    
    .colombia-heart {
        width: 60px;
        height: 60px;
    }
    
    .floating-code {
        display: none;
    }
}

.skill-bar-bg {
    position: relative;
    overflow: hidden;
}

.skill-bar-fill {
    position: relative;
    overflow: hidden;
}

@keyframes skillShimmer {
    0% {
        transform: translateX(-100%);
    }
    50% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Expertise Highlight Animation */
.expertise-highlight {
    opacity: 0;
    transform: translateY(40px);
    animation: expertiseReveal 1.5s var(--easing-smooth) 0.8s forwards;
}

@keyframes expertiseReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.expertise-item {
    transition: all var(--animation-speed-normal) var(--easing-smooth);
}

.expertise-item:hover {
    transform: scale(1.05);
}

.expertise-number {
    animation: numberCount 2s var(--easing-smooth) 1s forwards;
}

/* =========================================
   EQUIRENT SHOWCASE ANIMATIONS
   ========================================= */

.client-showcase-section {
    position: relative;
    overflow: hidden;
}

/* Enhanced Client Floating Elements */
.client-floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.floating-gear {
    position: absolute;
    animation: gearSpin ease-in-out infinite;
    opacity: 0.1;
}

.floating-gear-1 {
    top: 15%;
    left: 10%;
    animation-duration: 12s;
    animation-direction: normal;
}

.floating-gear-2 {
    top: 70%;
    right: 15%;
    animation-duration: 8s;
    animation-direction: reverse;
}

@keyframes gearSpin {
    0% {
        transform: rotate(0deg) scale(1);
        opacity: 0.1;
    }
    50% {
        transform: rotate(180deg) scale(1.1);
        opacity: 0.2;
    }
    100% {
        transform: rotate(360deg) scale(1);
        opacity: 0.1;
    }
}

.floating-car {
    position: absolute;
    animation: carFloat ease-in-out infinite;
    opacity: 0.15;
}

.floating-car-1 {
    top: 40%;
    right: 8%;
    animation-duration: 6s;
}

@keyframes carFloat {
    0%, 100% {
        transform: translateY(0px) translateX(0px);
        opacity: 0.15;
    }
    25% {
        transform: translateY(-15px) translateX(10px);
        opacity: 0.25;
    }
    50% {
        transform: translateY(-30px) translateX(0px);
        opacity: 0.2;
    }
    75% {
        transform: translateY(-15px) translateX(-10px);
        opacity: 0.25;
    }
}

.floating-code {
    position: absolute;
    animation: codeFlicker ease-in-out infinite;
    opacity: 0.1;
}

.floating-code-1 {
    top: 80%;
    left: 20%;
    animation-duration: 4s;
}

@keyframes codeFlicker {
    0%, 100% {
        opacity: 0.1;
        transform: scale(1);
    }
    50% {
        opacity: 0.3;
        transform: scale(1.05);
    }
}

/* Equirent Project Cards Animation */
.equirent-project-card {
    transition: all var(--animation-speed-normal) var(--easing-smooth);
    opacity: 0;
    transform: translateY(50px) rotateX(15deg);
    animation: projectReveal 1.2s var(--easing-smooth) forwards;
    perspective: 1000px;
}

.equirent-project-card:nth-child(1) { animation-delay: 0.2s; }
.equirent-project-card:nth-child(2) { animation-delay: 0.4s; }
.equirent-project-card:nth-child(3) { animation-delay: 0.6s; }

@keyframes projectReveal {
    to {
        opacity: 1;
        transform: translateY(0) rotateX(0deg);
    }
}

.equirent-project-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 35px rgba(37, 99, 235, 0.2);
}

/* Project Icon Animations */
.project-icon {
    transition: all var(--animation-speed-normal) var(--easing-bounce);
    position: relative;
    overflow: hidden;
}

.project-icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all var(--animation-speed-normal) var(--easing-smooth);
    z-index: -1;
}

.equirent-project-card:hover .project-icon::before {
    width: 120%;
    height: 120%;
}

.equirent-project-card:hover .project-icon {
    transform: scale(1.1) rotate(5deg);
    color: #06b6d4;
}

/* =========================================
   CONTACT SECTION ANIMATIONS
   ========================================= */

.contact-network-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

/* Enhanced Network Nodes */
.network-node {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(6, 182, 212, 0.6);
    border-radius: 50%;
    animation: networkPulse ease-in-out infinite;
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.3);
}

@keyframes networkPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.6;
        box-shadow: 0 0 10px rgba(6, 182, 212, 0.3);
    }
    50% {
        transform: scale(1.5);
        opacity: 1;
        box-shadow: 0 0 20px rgba(6, 182, 212, 0.6);
    }
}

/* Enhanced Network Lines */
.network-line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(6, 182, 212, 0.4) 20%, 
        rgba(6, 182, 212, 0.8) 50%, 
        rgba(6, 182, 212, 0.4) 80%, 
        transparent 100%);
    animation: networkFlow linear infinite;
    transform-origin: left center;
}

@keyframes networkFlow {
    0% {
        opacity: 0;
        transform: scaleX(0);
    }
    20% {
        opacity: 1;
        transform: scaleX(0.3);
    }
    80% {
        opacity: 1;
        transform: scaleX(1);
    }
    100% {
        opacity: 0;
        transform: scaleX(1);
    }
}

/* Contact Cards Enhanced 3D Animation */
.contact-card {
    perspective: 1000px;
    transition: all var(--animation-speed-normal) var(--easing-smooth);
}

.contact-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s var(--easing-smooth);
    transform-style: preserve-3d;
}

.contact-card:hover .contact-card-inner {
    transform: rotateY(180deg);
}

.contact-card-front, .contact-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.contact-card-front {
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(255, 255, 255, 0.05) 100%);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.contact-card-back {
    background: linear-gradient(135deg, 
        rgba(37, 99, 235, 0.1) 0%, 
        rgba(6, 182, 212, 0.1) 100%);
    border: 1px solid rgba(6, 182, 212, 0.3);
    transform: rotateY(180deg);
}

/* Contact Icon Animations */
.contact-icon-container {
    position: relative;
    display: inline-block;
}

.contact-icon {
    transition: all var(--animation-speed-normal) var(--easing-bounce);
    position: relative;
    z-index: 2;
}

.contact-card:hover .contact-icon {
    transform: scale(1.2) rotate(10deg);
    color: #06b6d4;
}

/* Email Particles Animation */
.email-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.email-particle {
    position: absolute;
    opacity: 0;
    animation: emailFloat 3s ease-in-out infinite;
}

.email-particle:nth-child(1) {
    top: 10%;
    left: 80%;
    animation-delay: 0s;
}

.email-particle:nth-child(2) {
    top: 70%;
    left: 10%;
    animation-delay: 0.5s;
}

.email-particle:nth-child(3) {
    top: 40%;
    right: 10%;
    animation-delay: 1s;
}

.email-particle:nth-child(4) {
    bottom: 20%;
    left: 70%;
    animation-delay: 1.5s;
}

@keyframes emailFloat {
    0%, 100% {
        opacity: 0;
        transform: translateY(0) scale(0.8);
    }
    25% {
        opacity: 0.6;
        transform: translateY(-20px) scale(1);
    }
    50% {
        opacity: 1;
        transform: translateY(-40px) scale(1.1);
    }
    75% {
        opacity: 0.6;
        transform: translateY(-20px) scale(1);
    }
}

/* WhatsApp Bubbles Animation */
.whatsapp-bubbles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.chat-bubble {
    position: absolute;
    opacity: 0;
    animation: bubbleFloat 4s ease-in-out infinite;
    color: #25D366;
}

.chat-bubble:nth-child(1) {
    top: 15%;
    right: 15%;
    animation-delay: 0s;
}

.chat-bubble:nth-child(2) {
    top: 60%;
    left: 15%;
    animation-delay: 0.7s;
}

.chat-bubble:nth-child(3) {
    top: 80%;
    right: 20%;
    animation-delay: 1.4s;
}

.chat-bubble:nth-child(4) {
    top: 35%;
    left: 70%;
    animation-delay: 2.1s;
}

@keyframes bubbleFloat {
    0%, 100% {
        opacity: 0;
        transform: translateY(0) scale(0.5);
    }
    30% {
        opacity: 0.8;
        transform: translateY(-15px) scale(1);
    }
    60% {
        opacity: 1;
        transform: translateY(-30px) scale(1.2);
    }
    80% {
        opacity: 0.6;
        transform: translateY(-15px) scale(1);
    }
}

/* =========================================
   INTERSECTION OBSERVER ANIMATIONS
   ========================================= */

/* Initial states for scroll-triggered animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(60px);
    transition: all 1.2s var(--easing-smooth);
}

.animate-on-scroll.animate-left {
    transform: translateX(-60px);
}

.animate-on-scroll.animate-right {
    transform: translateX(60px);
}

.animate-on-scroll.animate-scale {
    transform: scale(0.8);
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0) translateX(0) scale(1);
}

/* Staggered animations for multiple elements */
.stagger-animation {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s var(--easing-smooth);
}

.stagger-animation.animated {
    opacity: 1;
    transform: translateY(0);
}

.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }

/* =========================================
   RESPONSIVE ANIMATIONS
   ========================================= */

@media (max-width: 768px) {
    /* Reduce animation intensity on mobile */
    .hero-particle {
        animation-duration: 8s;
    }
    
    .floating-shape {
        animation-duration: 6s;
    }
    
    .matrix-line {
        font-size: 12px;
        animation-duration: 15s;
    }
    
    .tech-orbit {
        width: 150px;
        height: 150px;
    }
    
    .orbit-item {
        transform-origin: 75px 0;
    }
    
    /* Disable complex animations on very small screens */
    @media (max-width: 480px) {
        .hero-particles,
        .features-floating-shapes,
        .about-code-matrix,
        .client-floating-elements,
        .contact-network-bg {
            display: none;
        }
        
        .feature-card:hover,
        .equirent-project-card:hover,
        .contact-card:hover {
            transform: translateY(-5px) scale(1.01);
        }
    }
}

/* =========================================
   PERFORMANCE OPTIMIZATIONS
   ========================================= */

/* Optimize animations for better performance */
.hero-particle,
.floating-shape,
.matrix-line,
.network-node,
.network-line {
    will-change: transform, opacity;
}

/* Pause animations when not in view (handled by JavaScript) */
.animation-paused * {
    animation-play-state: paused;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero-particles,
    .features-floating-shapes,
    .about-code-matrix,
    .client-floating-elements,
    .contact-network-bg {
        display: none;
    }
}

/* =========================================
   CUSTOM SCROLLBAR ANIMATIONS
   ========================================= */

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(42, 42, 42, 0.1);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #2563eb 0%, #06b6d4 100%);
    border-radius: 10px;
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #06b6d4 0%, #2563eb 100%);
}