/* 3D Perspective Effects */
:root {
    --perspective: 1000px;
}

/* 3D Card Flip Animation - Hover only */
.service-card, .glass-card, .leader-card, .resource-card {
    perspective: var(--perspective);
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.service-card:hover, .glass-card:hover, .leader-card:hover, .resource-card:hover {
    transform: rotateY(5deg) rotateX(-5deg) translateZ(20px);
}

/* Floating 3D Animation - One time only */
@keyframes float3d {
    0% { transform: translateY(0px); }
    100% { transform: translateY(-40px); }
}

.float-icon {
    animation: float3d 1.2s ease-out forwards !important;
}

/* Title Glow - One time only */
@keyframes titleGlow {
    0% { text-shadow: 0 0 10px rgba(102, 126, 234, 0.3); }
    100% { text-shadow: 0 0 30px rgba(102, 126, 234, 0.8); }
}

.hero-title, .section-title {
    animation: titleGlow 1.5s ease-out forwards;
}

/* Liquid Swipe Animation - One time only */
@keyframes liquidSwipe {
    0% { clip-path: polygon(0 0, 0 0, 0 100%, 0% 100%); }
    100% { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
}

.service-card, .resource-card {
    animation: liquidSwipe 0.8s ease-out forwards;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }
.service-card:nth-child(4) { animation-delay: 0.4s; }
.service-card:nth-child(5) { animation-delay: 0.5s; }
.service-card:nth-child(6) { animation-delay: 0.6s; }

/* Bounce In Animation - One time only */
@keyframes bounceIn {
    0% { opacity: 0; transform: scale(0.3) translateY(50px); }
    50% { opacity: 1; transform: scale(1.05); }
    100% { transform: scale(1); }
}

.feature-card, .industry-card {
    animation: bounceIn 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55) 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; }

/* Slide In Animation - One time only */
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-100px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(100px); }
    to { opacity: 1; transform: translateX(0); }
}

.about-cards > div:nth-child(1) {
    animation: slideInLeft 0.8s ease-out forwards;
}

.about-cards > div:nth-child(2) {
    animation: slideInRight 0.8s ease-out forwards;
}

/* Blob Animation - One time only */
@keyframes blobAnimation {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(20px, 20px) scale(1.05); }
}

.hero-bg {
    animation: blobAnimation 2s ease-out forwards;
}

/* Staggered Text Animation - One time only */
@keyframes staggerText {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.process-step {
    animation: staggerText 0.6s ease-out forwards;
}

.process-step:nth-child(1) { animation-delay: 0.1s; }
.process-step:nth-child(2) { animation-delay: 0.2s; }
.process-step:nth-child(3) { animation-delay: 0.3s; }
.process-step:nth-child(4) { animation-delay: 0.4s; }
.process-step:nth-child(5) { animation-delay: 0.5s; }
.process-step:nth-child(6) { animation-delay: 0.6s; }

/* Expand Animation - One time only */
@keyframes expandIn {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.stat-card {
    animation: expandIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.stat-card:nth-child(1) { animation-delay: 0.2s; }
.stat-card:nth-child(2) { animation-delay: 0.4s; }
.stat-card:nth-child(3) { animation-delay: 0.6s; }
.stat-card:nth-child(4) { animation-delay: 0.8s; }

/* Hover Lift Effect */
.engagement-card {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.engagement-card:hover {
    transform: translateY(-15px) rotateX(5deg) rotateZ(2deg);
    box-shadow: 0 30px 60px rgba(102, 126, 234, 0.3);
}

/* 3D Tilt on Hover */
.leader-card:hover {
    transform: perspective(1000px) rotateX(5deg) rotateY(10deg) translateZ(30px);
}

/* Tech Logo Hover */
.tech-logo {
    transition: all 0.3s ease;
}

.tech-logo:hover {
    transform: translateY(-5px) scale(1.05);
}

/* Smooth Scroll Behavior */
html {
    scroll-behavior: smooth;
}

/* Reduce animations for accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
