/* Advanced Animations and Effects */

/* Animation Keyframes */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-20px); }
    60% { transform: translateY(-10px); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes wave {
    0% { transform: rotate(0deg); }
    10% { transform: rotate(14deg); }
    20% { transform: rotate(-8deg); }
    30% { transform: rotate(14deg); }
    40% { transform: rotate(-4deg); }
    50% { transform: rotate(10deg); }
    60% { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}

@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes border-dance {
    0% { border-radius: 60% 40% 30% 70%/60% 30% 70% 40%; }
    50% { border-radius: 30% 60% 70% 40%/50% 60% 30% 60%; }
    100% { border-radius: 60% 40% 30% 70%/60% 30% 70% 40%; }
}

@keyframes shimmer {
    0% { 
        background: linear-gradient(90deg, #00a8b5, transparent);
        background-size: 200% 100%;
        background-position: -200% 0;
    }
    100% { 
        background: linear-gradient(90deg, #00a8b5, transparent);
        background-size: 200% 100%;
        background-position: 200% 0;
    }
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Hover Effects */
.hover-bounce:hover {
    animation: bounce 1s ease infinite;
}

.hover-shake:hover {
    animation: shake 0.82s cubic-bezier(.36,.07,.19,.97) both;
}

.hover-spin:hover {
    animation: spin 1s linear infinite;
}

.hover-wave:hover {
    animation: wave 1s ease-in-out infinite;
    transform-origin: 70% 70%;
}

/* Gradient Effects */
.gradient-text {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color), var(--primary-color));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: gradient-shift 3s ease infinite;
}

.gradient-border {
    position: relative;
    border: 2px solid transparent;
    background: linear-gradient(white, white) padding-box,
                linear-gradient(45deg, var(--primary-color), var(--secondary-color)) border-box;
    animation: gradient-shift 3s ease infinite;
}

/* Morphing Effects */
.morph-border {
    border: 2px solid var(--primary-color);
    animation: border-dance 4s ease-in-out infinite;
}

/* Card Effects */
.card-hover-3d {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    perspective: 1000px;
}

.card-hover-3d:hover {
    transform: rotateY(10deg) rotateX(5deg);
}

.card-hover-lift {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover-lift:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* Image Effects */
.img-blur-hover {
    transition: filter 0.3s ease;
}

.img-blur-hover:hover {
    filter: blur(2px);
}

.img-grayscale {
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.img-grayscale:hover {
    filter: grayscale(0%);
}

/* Text Effects */
.text-shadow-hover {
    text-shadow: 0 0 0 rgba(0,0,0,0);
    transition: text-shadow 0.3s ease;
}

.text-shadow-hover:hover {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.text-underline-animated {
    position: relative;
    text-decoration: none;
}

.text-underline-animated::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -2px;
    left: 0;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.text-underline-animated:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Button Effects */
.btn-gradient {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    background-size: 200% auto;
    color: white;
    border: none;
    transition: all 0.3s ease;
}

.btn-gradient:hover {
    background-position: right center;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.btn-pulse {
    position: relative;
    overflow: hidden;
}

.btn-pulse::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255,255,255,0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.btn-pulse:hover::after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    100% {
        transform: scale(20, 20);
        opacity: 0;
    }
}

/* Loading Effects */
.loading-dots::after {
    content: '...';
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { content: '.'; }
    33% { content: '..'; }
    66% { content: '...'; }
}

/* Scroll Animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.scroll-reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Animations */
@media (max-width: 768px) {
    .card-hover-3d:hover {
        transform: none;
    }
    
    .hover-bounce:hover,
    .hover-shake:hover,
    .hover-spin:hover,
    .hover-wave:hover {
        animation: none;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Hero Section Animations */
@keyframes float {
    0% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
    100% {
        transform: translateY(0) rotate(0deg);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% center;
    }
    100% {
        background-position: 200% center;
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(13, 202, 240, 0.4);
    }
    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(13, 202, 240, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(13, 202, 240, 0);
    }
}

/* Add animation classes */
.hero-content {
    animation: fadeInUp 1s ease-out;
}

.hero-title {
    animation: fadeInUp 1s ease-out 0.2s backwards;
}

.hero-subtitle {
    animation: fadeInUp 1s ease-out 0.4s backwards;
}

.hero-buttons {
    animation: fadeInUp 1s ease-out 0.6s backwards;
}

.hero-stats {
    animation: fadeInUp 1s ease-out 0.8s backwards;
}

.hero-image {
    animation: fadeInRight 1s ease-out 0.6s backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

/* Featured Products Animations */
.featured-products .section-title {
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards;
}

.featured-products .product-card {
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
}

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

/* About Section Animations */
.about-section .content-wrapper {
    opacity: 0;
    animation: fadeInLeft 0.8s ease-out forwards;
}

.about-section .image-wrapper {
    opacity: 0;
    animation: fadeInRight 0.8s ease-out forwards;
    animation-delay: 0.3s;
}

.about-section .btn {
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
    animation-delay: 0.6s;
}

/* Animation Classes */
.animate-on-scroll {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.animated {
    opacity: 1;
}

/* Hover Animations */
.product-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.about-section .btn {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-section .btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(13, 202, 240, 0.2);
}

/* Category Showcase Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes iconRotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.category-card {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    opacity: 0;
}

.category-card.animate-in {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.category-icon-wrapper {
    animation: scaleIn 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.2s;
    opacity: 0;
}

.category-card.animate-in .category-icon-wrapper {
    animation: scaleIn 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.category-card h3 {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.3s;
    opacity: 0;
}

.category-card.animate-in h3 {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.category-card p {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.4s;
    opacity: 0;
}

.category-card.animate-in p {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.category-card .btn {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.5s;
    opacity: 0;
}

.category-card.animate-in .btn {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Hover Animations */
.category-card:hover .category-icon-wrapper i {
    animation: iconRotate 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-card:hover .category-icon-wrapper::before {
    animation: gradientFlow 3s ease infinite;
    background-size: 200% 200%;
}

/* Staggered Animation Delays */
.category-card:nth-child(1) { animation-delay: 0.1s; }
.category-card:nth-child(2) { animation-delay: 0.2s; }
.category-card:nth-child(3) { animation-delay: 0.3s; }
.category-card:nth-child(4) { animation-delay: 0.4s; }
.category-card:nth-child(5) { animation-delay: 0.5s; }
.category-card:nth-child(6) { animation-delay: 0.6s; }

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .category-card,
    .category-icon-wrapper,
    .category-card h3,
    .category-card p,
    .category-card .btn {
        animation: none;
        opacity: 1;
        transform: none;
    }
    
    .category-card:hover .category-icon-wrapper i {
        animation: none;
    }
    
    .category-card:hover .category-icon-wrapper::before {
        animation: none;
    }
}

/* Story Page Animations */
@keyframes storyHeroFadeIn {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes storyImageReveal {
    from {
        opacity: 0;
        transform: scale(0.95) translateX(30px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateX(0);
    }
}

@keyframes storyContentSlide {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes valueItemPop {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes goalIconFloat {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
    100% {
        transform: translateY(0);
    }
}

@keyframes impactNumberCount {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Story Hero Section */
.story-hero-content {
    opacity: 0;
    animation: storyHeroFadeIn 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.story-hero-image {
    opacity: 0;
    animation: storyImageReveal 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.3s;
}

/* Story Section Animations */
.story-section {
    opacity: 0;
    transition: opacity 0.6s ease;
}

.story-section.animate-in {
    opacity: 1;
}

.story-section.animate-in .story-image-wrapper {
    animation: storyImageReveal 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.story-section.animate-in .story-text-content {
    animation: storyContentSlide 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Mission Values Animation */
.value-item {
    opacity: 0;
    transform: scale(0.8);
}

.story-section.animate-in .value-item {
    animation: valueItemPop 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.story-section.animate-in .value-item:nth-child(1) { animation-delay: 0.2s; }
.story-section.animate-in .value-item:nth-child(2) { animation-delay: 0.4s; }
.story-section.animate-in .value-item:nth-child(3) { animation-delay: 0.6s; }

/* Vision Goals Animation */
.goal-item {
    opacity: 0;
    transform: translateY(20px);
}

.story-section.animate-in .goal-item {
    animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.story-section.animate-in .goal-item:nth-child(1) { animation-delay: 0.2s; }
.story-section.animate-in .goal-item:nth-child(2) { animation-delay: 0.4s; }
.story-section.animate-in .goal-item:nth-child(3) { animation-delay: 0.6s; }

.goal-icon {
    animation: goalIconFloat 3s ease-in-out infinite;
}

.goal-item:hover .goal-icon {
    animation-play-state: paused;
}

/* Impact Section Animation */
.impact-card {
    opacity: 0;
    transform: translateY(30px);
}

.impact-card.animate-in {
    animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

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

.impact-number {
    opacity: 0;
    transform: translateY(20px);
}

.impact-card.animate-in .impact-number {
    animation: impactNumberCount 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.3s;
}

.impact-icon {
    transition: transform 0.4s ease;
}

.impact-card:hover .impact-icon {
    transform: scale(1.1) rotate(5deg);
}

/* Hover Effects */
.story-hero-image:hover img {
    transform: scale(1.02);
}

.value-item:hover {
    transform: translateY(-5px);
}

.goal-item:hover {
    transform: translateY(-5px);
}

.impact-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .story-hero-content,
    .story-hero-image,
    .story-section,
    .value-item,
    .goal-item,
    .impact-card,
    .impact-number,
    .goal-icon {
        animation: none !important;
        opacity: 1;
        transform: none !important;
        transition: none !important;
    }
    
    .story-hero-image:hover img,
    .value-item:hover,
    .goal-item:hover,
    .impact-card:hover {
        transform: none !important;
    }
}

/* Enhanced Story Page Animations */
@keyframes storyHeroReveal {
    0% {
        clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes storyImageFloat {
    0% {
        transform: translateY(0) rotate(-2deg);
    }
    50% {
        transform: translateY(-15px) rotate(0deg);
    }
    100% {
        transform: translateY(0) rotate(-2deg);
    }
}

@keyframes storySectionReveal {
    0% {
        opacity: 0;
        transform: translateY(40px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes storyValuePulse {
    0% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(176, 224, 230, 0.15);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 15px 40px rgba(176, 224, 230, 0.25);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(176, 224, 230, 0.15);
    }
}

@keyframes storyGoalSlide {
    0% {
        opacity: 0;
        transform: translateX(-30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes storyImpactCount {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes storyIconGlow {
    0% {
        box-shadow: 0 0 5px rgba(0, 168, 181, 0.2);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 168, 181, 0.4);
    }
    100% {
        box-shadow: 0 0 5px rgba(0, 168, 181, 0.2);
    }
}

/* Story Hero Animations */
.story-hero-content h1 {
    animation: storyHeroReveal 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.3s;
}

.story-hero-content p {
    animation: storyHeroReveal 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.6s;
}

.story-hero-image {
    animation: storyImageFloat 6s ease-in-out infinite;
}

/* Story Section Animations */
.story-section {
    opacity: 0;
    animation: storySectionReveal 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.story-section:nth-child(2) {
    animation-delay: 0.2s;
}

.story-section:nth-child(3) {
    animation-delay: 0.4s;
}

/* Mission Values Animations */
.value-item {
    opacity: 0;
    animation: storyValuePulse 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.value-item:nth-child(1) { animation-delay: 0.2s; }
.value-item:nth-child(2) { animation-delay: 0.4s; }
.value-item:nth-child(3) { animation-delay: 0.6s; }

.value-item i {
    animation: storyIconGlow 3s ease-in-out infinite;
}

/* Vision Goals Animations */
.goal-item {
    opacity: 0;
    animation: storyGoalSlide 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.goal-item:nth-child(1) { animation-delay: 0.3s; }
.goal-item:nth-child(2) { animation-delay: 0.5s; }
.goal-item:nth-child(3) { animation-delay: 0.7s; }

.goal-icon {
    animation: storyIconGlow 3s ease-in-out infinite;
}

/* Impact Section Animations */
.impact-card {
    opacity: 0;
    animation: storyImpactCount 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

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

.impact-icon {
    animation: storyIconGlow 3s ease-in-out infinite;
}

.impact-number {
    opacity: 0;
    animation: storyImpactCount 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    animation-delay: 0.3s;
}

/* Hover Effects */
.story-hero-image:hover {
    animation-play-state: paused;
}

.value-item:hover {
    animation: storyValuePulse 0.6s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.goal-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(176, 224, 230, 0.25);
}

.impact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(176, 224, 230, 0.25);
}

.impact-card:hover .impact-icon {
    animation: storyIconGlow 1.5s ease-in-out infinite;
}

/* Scroll Progress Animation */
.scroll-progress {
    animation: storyHeroReveal 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .story-hero-content h1,
    .story-hero-content p,
    .story-hero-image,
    .story-section,
    .value-item,
    .goal-item,
    .impact-card,
    .impact-icon,
    .impact-number,
    .scroll-progress {
        animation: none !important;
        transition: none !important;
    }
    
    .story-hero-image:hover,
    .value-item:hover,
    .goal-item:hover,
    .impact-card:hover {
        transform: none !important;
        box-shadow: none !important;
    }
}

/* Animation Base Classes */
.animate-on-scroll {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Animation Types */
.fadeInLeft {
    transform: translateX(-50px);
}

.fadeInRight {
    transform: translateX(50px);
}

.fadeInUp {
    transform: translateY(50px);
}

/* Animated States */
.animate.fadeInLeft,
.animate.fadeInRight,
.animate.fadeInUp {
    opacity: 1;
    transform: translate(0);
}

/* Story Page Specific Animations */
.story-hero-content.animate.fadeInLeft,
.story-hero-image.animate.fadeInRight {
    transition-delay: 0.2s;
}

.story-image-wrapper.animate.fadeInLeft,
.story-image-wrapper.animate.fadeInRight {
    transition-delay: 0.3s;
}

.story-text-content.animate.fadeInLeft,
.story-text-content.animate.fadeInRight {
    transition-delay: 0.4s;
}

.value-item.animate.fadeInUp,
.goal-item.animate.fadeInUp,
.impact-card.animate.fadeInUp {
    transition-delay: calc(var(--delay, 0) * 1s);
}

/* Enhanced Animation Effects */
.story-hero-image img {
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.story-hero-image.animate img {
    transform: perspective(1000px) rotateY(0deg);
}

.value-item,
.goal-item,
.impact-card {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.value-item:hover,
.goal-item:hover,
.impact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Animation Timing for Different Elements */
.section-title.animate.fadeInUp {
    transition-delay: 0.2s;
}

.mission-values .value-item:nth-child(1),
.vision-goals .goal-item:nth-child(1),
.impact-card:nth-child(1) {
    --delay: 0.1;
}

.mission-values .value-item:nth-child(2),
.vision-goals .goal-item:nth-child(2),
.impact-card:nth-child(2) {
    --delay: 0.2;
}

.mission-values .value-item:nth-child(3),
.vision-goals .goal-item:nth-child(3),
.impact-card:nth-child(3) {
    --delay: 0.3;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .animate-on-scroll {
        transition: none;
        opacity: 1;
        transform: none;
    }
    
    .animate-on-scroll.animate {
        transform: none;
    }
    
    .value-item:hover,
    .goal-item:hover,
    .impact-card:hover {
        transform: none;
    }
}

/* Enhanced Story Page Animations */

/* Parallax Background Effect */
.story-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 20%, rgba(176, 224, 230, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(176, 224, 230, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(176, 224, 230, 0.08) 0%, transparent 50%);
    animation: parallaxFloat 20s ease-in-out infinite;
    pointer-events: none;
}

@keyframes parallaxFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-20px) rotate(1deg); }
    66% { transform: translateY(10px) rotate(-1deg); }
}

/* Floating Elements */
.story-hero::after {
    content: '';
    position: absolute;
    top: 10%;
    right: 10%;
    width: 100px;
    height: 100px;
    background: linear-gradient(45deg, rgba(13, 202, 240, 0.1), rgba(13, 202, 240, 0.05));
    border-radius: 50%;
    animation: floatElement 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes floatElement {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-30px) scale(1.1); }
}

/* Enhanced Hero Content Animations */
.story-hero-content h1 {
    animation: storyTitleReveal 1.2s ease-out 0.3s both;
    transform-origin: left center;
}

@keyframes storyTitleReveal {
    0% {
        opacity: 0;
        transform: translateX(-50px) scale(0.8);
        filter: blur(5px);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
        filter: blur(0);
    }
}

.story-hero-content p {
    animation: storySubtitleReveal 1s ease-out 0.6s both;
}

@keyframes storySubtitleReveal {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Enhanced Image Animations */
.story-hero-image {
    animation: storyImageEntrance 1.5s ease-out 0.4s both;
    transform-style: preserve-3d;
}

@keyframes storyImageEntrance {
    0% {
        opacity: 0;
        transform: perspective(1000px) rotateY(-15deg) translateZ(-100px) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: perspective(1000px) rotateY(-5deg) translateZ(0) scale(1);
    }
}

.story-hero-image:hover {
    animation: storyImageHover 0.6s ease-out both;
}

@keyframes storyImageHover {
    0% { transform: perspective(1000px) rotateY(-5deg) translateZ(0); }
    50% { transform: perspective(1000px) rotateY(0deg) translateZ(20px); }
    100% { transform: perspective(1000px) rotateY(0deg) translateZ(0); }
}

/* Enhanced Section Animations */
.story-section {
    animation: sectionReveal 1s ease-out both;
    animation-play-state: paused;
}

.story-section.animate-in {
    animation-play-state: running;
}

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

/* Enhanced Value Items */
.value-item {
    animation: valueItemEntrance 0.8s ease-out both;
    animation-play-state: paused;
    transform-origin: center bottom;
}

.value-item.animate-in {
    animation-play-state: running;
}

@keyframes valueItemEntrance {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.value-item:hover {
    animation: valueItemHover 0.4s ease-out both;
}

@keyframes valueItemHover {
    0% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-8px) scale(1.02); }
    100% { transform: translateY(-5px) scale(1.01); }
}

.value-item i {
    animation: iconPulse 2s ease-in-out infinite;
    animation-play-state: paused;
}

.value-item:hover i {
    animation-play-state: running;
}

@keyframes iconPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Enhanced Goal Items */
.goal-item {
    animation: goalItemSlide 0.8s ease-out both;
    animation-play-state: paused;
}

.goal-item.animate-in {
    animation-play-state: running;
}

@keyframes goalItemSlide {
    0% {
        opacity: 0;
        transform: translateX(-40px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

.goal-item:hover {
    animation: goalItemHover 0.4s ease-out both;
}

@keyframes goalItemHover {
    0% { transform: translateX(0); }
    50% { transform: translateX(5px); }
    100% { transform: translateX(3px); }
}

.goal-icon {
    animation: goalIconFloat 3s ease-in-out infinite;
    animation-play-state: paused;
}

.goal-item:hover .goal-icon {
    animation-play-state: running;
}

@keyframes goalIconFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-5px) rotate(5deg); }
}

/* Enhanced Impact Cards */
.impact-card {
    animation: impactCardReveal 0.8s ease-out both;
    animation-play-state: paused;
}

.impact-card.animate-in {
    animation-play-state: running;
}

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

.impact-card:hover {
    animation: impactCardHover 0.4s ease-out both;
}

@keyframes impactCardHover {
    0% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-10px) scale(1.03); }
    100% { transform: translateY(-8px) scale(1.02); }
}

.impact-icon {
    animation: impactIconGlow 2s ease-in-out infinite;
    animation-play-state: paused;
}

.impact-card:hover .impact-icon {
    animation-play-state: running;
}

@keyframes impactIconGlow {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 0 0 rgba(13, 202, 240, 0);
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 0 20px rgba(13, 202, 240, 0.3);
    }
}

.impact-number {
    animation: impactNumberCount 2s ease-out both;
    animation-play-state: paused;
}

.impact-card.animate-in .impact-number {
    animation-play-state: running;
}

@keyframes impactNumberCount {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }
    50% {
        opacity: 1;
        transform: scale(1.2);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Enhanced Text Animations */
.section-title {
    animation: titleReveal 1s ease-out both;
    animation-play-state: paused;
}

.section-title.animate-in {
    animation-play-state: running;
}

@keyframes titleReveal {
    0% {
        opacity: 0;
        transform: translateY(-30px);
        filter: blur(3px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

.section-text {
    animation: textReveal 1s ease-out 0.3s both;
    animation-play-state: paused;
}

.story-section.animate-in .section-text {
    animation-play-state: running;
}

@keyframes textReveal {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Enhanced Image Wrapper Animations */
.story-image-wrapper {
    animation: imageWrapperReveal 1s ease-out 0.2s both;
    animation-play-state: paused;
}

.story-section.animate-in .story-image-wrapper {
    animation-play-state: running;
}

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

/* Enhanced Text Content Animations */
.story-text-content {
    animation: textContentReveal 1s ease-out 0.4s both;
    animation-play-state: paused;
}

.story-section.animate-in .story-text-content {
    animation-play-state: running;
}

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

/* Staggered Animation Delays */
.value-item:nth-child(1) { animation-delay: 0.2s; }
.value-item:nth-child(2) { animation-delay: 0.4s; }
.value-item:nth-child(3) { animation-delay: 0.6s; }

.goal-item:nth-child(1) { animation-delay: 0.3s; }
.goal-item:nth-child(2) { animation-delay: 0.5s; }
.goal-item:nth-child(3) { animation-delay: 0.7s; }

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

/* Enhanced Hover Effects */
.story-hero-image:hover img {
    animation: imageZoom 0.6s ease-out both;
}

@keyframes imageZoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.05); }
}

.value-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(176, 224, 230, 0.3);
}

.goal-item:hover {
    transform: translateX(3px);
    box-shadow: 0 10px 25px rgba(176, 224, 230, 0.2);
}

.impact-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(176, 224, 230, 0.25);
}

.impact-card:hover .impact-icon {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(13, 202, 240, 0.3);
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #00a8b5, #0dcaf0);
    z-index: 9999;
    transition: width 0.1s ease;
}

/* Responsive Animations */
@media (max-width: 768px) {
    .story-hero-content h1 {
        animation-duration: 0.8s;
    }
    
    .story-hero-image {
        animation-duration: 1s;
    }
    
    .value-item,
    .goal-item,
    .impact-card {
        animation-duration: 0.6s;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .story-hero-content h1,
    .story-hero-content p,
    .story-hero-image,
    .story-section,
    .value-item,
    .goal-item,
    .impact-card,
    .section-title,
    .section-text,
    .story-image-wrapper,
    .story-text-content {
        animation: none !important;
        transition: none !important;
    }
    
    .story-hero-image:hover,
    .value-item:hover,
    .goal-item:hover,
    .impact-card:hover {
        transform: none !important;
    }
    
    .story-hero::before,
    .story-hero::after {
        animation: none !important;
    }
} 