/* ====================================
   PARALLAX BRIDGE TRANSITION STYLES
   ==================================== */

.parallax-bridge {
    min-height: 150vh;
    position: relative;
    background: linear-gradient(
        180deg,
        rgba(13, 13, 13, 0.95) 0%,
        rgba(127, 90, 240, 0.03) 20%,
        rgba(127, 90, 240, 0.06) 50%,
        rgba(127, 90, 240, 0.03) 80%,
        #0a0a0a 100%
    );
    display: flex;
    align-items: center;
    justify-content: center;
}

.parallax-bridge::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(
        180deg,
        rgba(13, 13, 13, 0.8) 0%,
        transparent 100%
    );
    pointer-events: none;
    z-index: 1;
}

.bridge-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.parallax-layers {
    position: relative;
    width: 100%;
    height: 100%;
}

.parallax-layers > div {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Layer 1 - Fade text at top */
.layer-1 {
    top: -20%;
}

.fade-text {
    font-size: clamp(1rem, 2vw, 1.5rem);
    color: var(--text-secondary);
    opacity: 0.6;
    text-align: center;
    animation: fadeInOut 4s ease-in-out infinite;
}

/* Layer 2 - Floating tech elements */
.layer-2 {
    top: 0%;
}

.tech-elements {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    align-items: center;
    opacity: 0.4;
}

.tech-float {
    font-size: clamp(1.5rem, 4vw, 3rem);
    font-weight: 600;
    color: var(--accent);
    opacity: 0;
    animation: techFloat 6s ease-in-out infinite;
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tech-float:nth-child(1) { animation-delay: 0s; }
.tech-float:nth-child(2) { animation-delay: 2s; }
.tech-float:nth-child(3) { animation-delay: 4s; }

/* Layer 3 - Pre-introduction text */
.layer-3 {
    top: 20%;
}

.pre-intro {
    text-align: center;
    opacity: 0;
    animation: preIntroReveal 3s ease 2s forwards;
}

.gradient-text {
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 700;
    background: linear-gradient(
        135deg,
        var(--text-primary) 0%,
        var(--accent) 50%,
        var(--accent-hover) 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(127, 90, 240, 0.3);
}

/* Scroll-triggered parallax effect */
.parallax-bridge[data-scroll] .layer-1 {
    transform: translateY(var(--scroll-speed-1, 0));
}

.parallax-bridge[data-scroll] .layer-2 {
    transform: translateY(var(--scroll-speed-2, 0));
}

.parallax-bridge[data-scroll] .layer-3 {
    transform: translateY(var(--scroll-speed-3, 0));
}

/* Background elements for depth */
.parallax-bridge::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 20% 30%, rgba(127, 90, 240, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(255, 119, 198, 0.04) 0%, transparent 50%);
    animation: backgroundPulse 8s ease-in-out infinite;
    z-index: 0;
}

/* Bottom gradient for smooth transition to footer */
.parallax-bridge .bridge-bottom-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 200px;
    background: linear-gradient(
        0deg,
        #0a0a0a 0%,
        rgba(10, 10, 10, 0.8) 50%,
        transparent 100%
    );
    pointer-events: none;
    z-index: 2;
}

/* Animations */
@keyframes fadeInOut {
    0%, 100% {
        opacity: 0.3;
        transform: translateY(0);
    }
    50% {
        opacity: 0.8;
        transform: translateY(-10px);
    }
}

@keyframes techFloat {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.8);
    }
    50% {
        opacity: 0.7;
        transform: translateY(-20px) scale(1.1);
    }
    100% {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
}

@keyframes preIntroReveal {
    0% {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    100% {
        opacity: 0.9;
        transform: translateY(0) scale(1);
    }
}

@keyframes backgroundPulse {
    0%, 100% {
        opacity: 0.3;
    }
    50% {
        opacity: 0.6;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .parallax-bridge {
        min-height: 120vh;
    }
    
    .tech-elements {
        gap: 2rem;
    }
    
    .layer-1 {
        top: -10%;
    }
    
    .layer-3 {
        top: 30%;
    }
}

@media (max-width: 480px) {
    .parallax-bridge {
        min-height: 100vh;
    }
    
    .tech-elements {
        gap: 1.5rem;
    }
    
    .fade-text {
        padding: 0 1rem;
    }
}

/* Reduced motion accessibility */
@media (prefers-reduced-motion: reduce) {
    .parallax-bridge::before,
    .fade-text,
    .tech-float,
    .pre-intro {
        animation: none !important;
    }
    
    .pre-intro {
        opacity: 0.9;
    }
    
    .tech-float {
        opacity: 0.4;
    }
    
    .fade-text {
        opacity: 0.6;
    }
}