/* ═══════════════════════════════════════════════════════════════════════
   INTAHUB - ADVANCED ANIMATIONS STYLESHEET
   Contains: Scroll animations, hover effects, transitions, keyframes
═══════════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════
   1. SCROLL-TRIGGERED ANIMATIONS
═══════════════════════════════════════════════ */

/* Fade & Slide Up */
[data-animate] {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-animate="fade-up"] {
    transform: translateY(60px);
}
[data-animate="fade-up"].animated {
    opacity: 1;
    transform: translateY(0);
}

[data-animate="fade-down"] {
    transform: translateY(-60px);
}
[data-animate="fade-down"].animated {
    opacity: 1;
    transform: translateY(0);
}

[data-animate="fade-left"] {
    transform: translateX(-60px);
}
[data-animate="fade-left"].animated {
    opacity: 1;
    transform: translateX(0);
}

[data-animate="fade-right"] {
    transform: translateX(60px);
}
[data-animate="fade-right"].animated {
    opacity: 1;
    transform: translateX(0);
}

/* Scale In */
[data-animate="zoom-in"] {
    transform: scale(0.8);
}
[data-animate="zoom-in"].animated {
    opacity: 1;
    transform: scale(1);
}

[data-animate="zoom-out"] {
    transform: scale(1.2);
}
[data-animate="zoom-out"].animated {
    opacity: 1;
    transform: scale(1);
}

/* Rotate In */
[data-animate="rotate-in"] {
    transform: rotate(-10deg) scale(0.9);
}
[data-animate="rotate-in"].animated {
    opacity: 1;
    transform: rotate(0) scale(1);
}

/* Flip In */
[data-animate="flip-in"] {
    transform: perspective(600px) rotateX(-30deg);
}
[data-animate="flip-in"].animated {
    opacity: 1;
    transform: perspective(600px) rotateX(0);
}

/* Stagger children animations */
.stagger-children > * {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.stagger-children.animated > *:nth-child(1) { transition-delay: 0.1s; }
.stagger-children.animated > *:nth-child(2) { transition-delay: 0.2s; }
.stagger-children.animated > *:nth-child(3) { transition-delay: 0.3s; }
.stagger-children.animated > *:nth-child(4) { transition-delay: 0.4s; }
.stagger-children.animated > *:nth-child(5) { transition-delay: 0.5s; }
.stagger-children.animated > *:nth-child(6) { transition-delay: 0.6s; }
.stagger-children.animated > * {
    opacity: 1;
    transform: translateY(0);
}

/* ═══════════════════════════════════════════════
   2. HOVER EFFECTS
═══════════════════════════════════════════════ */

/* Lift effect */
.hover-lift {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), 
                box-shadow 0.3s ease;
}
.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Glow effect */
.hover-glow {
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.hover-glow:hover {
    box-shadow: 0 0 30px rgba(200, 16, 46, 0.3), 0 10px 30px rgba(0, 0, 0, 0.2);
    transform: translateY(-4px);
}

/* Scale effect */
.hover-scale {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hover-scale:hover {
    transform: scale(1.05);
}

/* Shine effect */
.hover-shine {
    position: relative;
    overflow: hidden;
}
.hover-shine::before {
    content: '';
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transform: skewX(-25deg);
    transition: 0.5s;
}
.hover-shine:hover::before {
    left: 125%;
}

/* Border reveal */
.hover-border {
    position: relative;
}
.hover-border::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--red-bright);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}
.hover-border:hover::after {
    width: 100%;
}

/* ═══════════════════════════════════════════════
   3. ENTRANCE ANIMATIONS (On Page Load)
═══════════════════════════════════════════════ */

/* Slide in from right */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
.slide-in-right {
    animation: slideInRight 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Slide in from left */
@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
.slide-in-left {
    animation: slideInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Bounce in */
@keyframes bounceIn {
    0% {
        transform: scale(0.3);
        opacity: 0;
    }
    50% {
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.95);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}
.bounce-in {
    animation: bounceIn 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* Fade in with blur */
@keyframes fadeBlurIn {
    from {
        opacity: 0;
        filter: blur(10px);
    }
    to {
        opacity: 1;
        filter: blur(0);
    }
}
.fade-blur-in {
    animation: fadeBlurIn 0.8s ease-out forwards;
}

/* ═══════════════════════════════════════════════
   4. CONTINUOUS ANIMATIONS
═══════════════════════════════════════════════ */

/* Floating animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}
.float-animation {
    animation: float 3s ease-in-out infinite;
}
.float-animation-delayed {
    animation: float 3s ease-in-out 1.5s infinite;
}
.float-animation-slow {
    animation: float 5s ease-in-out infinite;
}

/* Pulse glow */
@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(200, 16, 46, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(200, 16, 46, 0.6), 0 0 60px rgba(200, 16, 46, 0.2);
    }
}
.pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite;
}

/* Rotate slow */
@keyframes rotateSlow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
.rotate-slow {
    animation: rotateSlow 20s linear infinite;
}

/* Shimmer effect */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}
.shimmer {
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    background-size: 200% 100%;
    animation: shimmer 2s linear infinite;
}

/* Typing cursor */
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}
.typing-cursor::after {
    content: '|';
    animation: blink 1s step-end infinite;
    color: var(--red-bright);
}

/* ═══════════════════════════════════════════════
   5. SECTION TRANSITIONS
═══════════════════════════════════════════════ */

/* Gradient reveal */
@keyframes gradientReveal {
    from {
        opacity: 0;
        background-size: 0% 100%;
    }
    to {
        opacity: 1;
        background-size: 100% 100%;
    }
}
.gradient-reveal {
    background: linear-gradient(135deg, var(--red-bright), var(--red));
    background-size: 0% 100%;
    background-repeat: no-repeat;
    animation: gradientReveal 1s ease-out forwards;
}

/* Slide up reveal */
@keyframes slideUpReveal {
    from {
        clip-path: inset(100% 0 0 0);
    }
    to {
        clip-path: inset(0 0 0 0);
    }
}
.slide-up-reveal {
    animation: slideUpReveal 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* ═══════════════════════════════════════════════
   6. PARALLAX & SCROLL EFFECTS
═══════════════════════════════════════════════ */

/* Parallax container */
.parallax-container {
    overflow: hidden;
    position: relative;
}
.parallax-bg {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    transition: transform 0.1s linear;
}

/* Reveal on scroll */
.reveal-on-scroll {
    position: relative;
    overflow: hidden;
}
.reveal-on-scroll::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--navy);
    transform: scaleX(1);
    transform-origin: right;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}
.reveal-on-scroll.revealed::after {
    transform: scaleX(0);
}
.reveal-on-scroll > * {
    position: relative;
    z-index: 2;
}

/* ═══════════════════════════════════════════════
   7. CARD & ELEMENT ANIMATIONS
═══════════════════════════════════════════════ */

/* Card tilt on hover */
.card-tilt {
    transition: transform 0.3s ease;
    transform-style: preserve-3d;
    perspective: 1000px;
}
.card-tilt:hover {
    transform: rotateX(2deg) rotateY(-2deg);
}

/* Ripple effect */
.ripple {
    position: relative;
    overflow: hidden;
}
.ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}
.ripple:active::after {
    width: 300px;
    height: 300px;
}

/* Skeleton loading */
@keyframes skeletonLoading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 37%,
        rgba(255, 255, 255, 0.05) 63%
    );
    background-size: 200px 100%;
    animation: skeletonLoading 1.5s ease-in-out infinite;
    border-radius: 4px;
}

/* ═══════════════════════════════════════════════
   8. TEXT ANIMATIONS
═══════════════════════════════════════════════ */

/* Character by character reveal */
@keyframes charReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.char-reveal span {
    display: inline-block;
    opacity: 0;
    animation: charReveal 0.5s ease-out forwards;
}

/* Gradient text animation */
@keyframes gradientText {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}
.gradient-text-animated {
    background: linear-gradient(
        90deg,
        var(--red-bright),
        #FF6080,
        var(--red-bright)
    );
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientText 3s ease infinite;
}

/* ═══════════════════════════════════════════════
   9. PAGE TRANSITIONS
═══════════════════════════════════════════════ */

/* Page enter */
.page-enter {
    animation: pageEnter 0.5s ease-out;
}
@keyframes pageEnter {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Section divider animation */
@keyframes dividerGrow {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}
.animated-divider {
    width: 0;
    animation: dividerGrow 1s ease-out forwards;
}

/* ═══════════════════════════════════════════════
   10. UTILITY CLASSES
═══════════════════════════════════════════════ */

/* Animation delays */
.delay-100 { animation-delay: 0.1s !important; }
.delay-200 { animation-delay: 0.2s !important; }
.delay-300 { animation-delay: 0.3s !important; }
.delay-400 { animation-delay: 0.4s !important; }
.delay-500 { animation-delay: 0.5s !important; }
.delay-600 { animation-delay: 0.6s !important; }
.delay-700 { animation-delay: 0.7s !important; }
.delay-800 { animation-delay: 0.8s !important; }
.delay-900 { animation-delay: 0.9s !important; }
.delay-1000 { animation-delay: 1s !important; }

/* Animation durations */
.duration-fast { animation-duration: 0.3s !important; }
.duration-normal { animation-duration: 0.6s !important; }
.duration-slow { animation-duration: 1s !important; }
.duration-very-slow { animation-duration: 2s !important; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}