/**
 * AOS - Animate On Scroll 优化版
 * 针对天津诚悦供应链网站进行了性能优化
 */

/* 核心动画样式 */
[data-aos] {
  pointer-events: none;
}

[data-aos].aos-animate {
  pointer-events: auto;
}

[data-aos="fade-up"] {
  opacity: 0;
  transform: translate3d(0, 100px, 0);
  transition-property: opacity, transform;
}

[data-aos="fade-up"].aos-animate {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

[data-aos="fade-down"] {
  opacity: 0;
  transform: translate3d(0, -100px, 0);
  transition-property: opacity, transform;
}

[data-aos="fade-down"].aos-animate {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

[data-aos="fade-right"] {
  opacity: 0;
  transform: translate3d(-100px, 0, 0);
  transition-property: opacity, transform;
}

[data-aos="fade-right"].aos-animate {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

[data-aos="fade-left"] {
  opacity: 0;
  transform: translate3d(100px, 0, 0);
  transition-property: opacity, transform;
}

[data-aos="fade-left"].aos-animate {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

[data-aos="zoom-in"] {
  opacity: 0;
  transform: scale(0.6);
  transition-property: opacity, transform;
}

[data-aos="zoom-in"].aos-animate {
  opacity: 1;
  transform: scale(1);
}

[data-aos="zoom-out"] {
  opacity: 0;
  transform: scale(1.2);
  transition-property: opacity, transform;
}

[data-aos="zoom-out"].aos-animate {
  opacity: 1;
  transform: scale(1);
}

/* 默认过渡属性 */
[data-aos] {
  transition-duration: 400ms;
  transition-timing-function: ease;
  transition-delay: 0ms;
}

/* 过渡延迟 */
[data-aos-delay="100"] { transition-delay: 100ms; }
[data-aos-delay="200"] { transition-delay: 200ms; }
[data-aos-delay="300"] { transition-delay: 300ms; }
[data-aos-delay="400"] { transition-delay: 400ms; }
[data-aos-delay="500"] { transition-delay: 500ms; }
[data-aos-delay="600"] { transition-delay: 600ms; }
[data-aos-delay="700"] { transition-delay: 700ms; }
[data-aos-delay="800"] { transition-delay: 800ms; }
[data-aos-delay="900"] { transition-delay: 900ms; }
[data-aos-delay="1000"] { transition-delay: 1000ms; }

/* 过渡持续时间 */
[data-aos-duration="50"] { transition-duration: 50ms; }
[data-aos-duration="100"] { transition-duration: 100ms; }
[data-aos-duration="150"] { transition-duration: 150ms; }
[data-aos-duration="200"] { transition-duration: 200ms; }
[data-aos-duration="250"] { transition-duration: 250ms; }
[data-aos-duration="300"] { transition-duration: 300ms; }
[data-aos-duration="350"] { transition-duration: 350ms; }
[data-aos-duration="400"] { transition-duration: 400ms; }
[data-aos-duration="450"] { transition-duration: 450ms; }
[data-aos-duration="500"] { transition-duration: 500ms; }
[data-aos-duration="550"] { transition-duration: 550ms; }
[data-aos-duration="600"] { transition-duration: 600ms; }
[data-aos-duration="650"] { transition-duration: 650ms; }
[data-aos-duration="700"] { transition-duration: 700ms; }
[data-aos-duration="750"] { transition-duration: 750ms; }
[data-aos-duration="800"] { transition-duration: 800ms; }
[data-aos-duration="850"] { transition-duration: 850ms; }
[data-aos-duration="900"] { transition-duration: 900ms; }
[data-aos-duration="950"] { transition-duration: 950ms; }
[data-aos-duration="1000"] { transition-duration: 1000ms; }
[data-aos-duration="1050"] { transition-duration: 1050ms; }
[data-aos-duration="1100"] { transition-duration: 1100ms; }
[data-aos-duration="1150"] { transition-duration: 1150ms; }
[data-aos-duration="1200"] { transition-duration: 1200ms; }
[data-aos-duration="1250"] { transition-duration: 1250ms; }
[data-aos-duration="1300"] { transition-duration: 1300ms; }
[data-aos-duration="1350"] { transition-duration: 1350ms; }
[data-aos-duration="1400"] { transition-duration: 1400ms; }
[data-aos-duration="1450"] { transition-duration: 1450ms; }
[data-aos-duration="1500"] { transition-duration: 1500ms; }
[data-aos-duration="1550"] { transition-duration: 1550ms; }
[data-aos-duration="1600"] { transition-duration: 1600ms; }
[data-aos-duration="1650"] { transition-duration: 1650ms; }
[data-aos-duration="1700"] { transition-duration: 1700ms; }
[data-aos-duration="1750"] { transition-duration: 1750ms; }
[data-aos-duration="1800"] { transition-duration: 1800ms; }
[data-aos-duration="1850"] { transition-duration: 1850ms; }
[data-aos-duration="1900"] { transition-duration: 1900ms; }
[data-aos-duration="1950"] { transition-duration: 1950ms; }
[data-aos-duration="2000"] { transition-duration: 2000ms; }
[data-aos-duration="2050"] { transition-duration: 2050ms; }
[data-aos-duration="2100"] { transition-duration: 2100ms; }
[data-aos-duration="2150"] { transition-duration: 2150ms; }
[data-aos-duration="2200"] { transition-duration: 2200ms; }
[data-aos-duration="2250"] { transition-duration: 2250ms; }
[data-aos-duration="2300"] { transition-duration: 2300ms; }
[data-aos-duration="2350"] { transition-duration: 2350ms; }
[data-aos-duration="2400"] { transition-duration: 2400ms; }
[data-aos-duration="2450"] { transition-duration: 2450ms; }
[data-aos-duration="2500"] { transition-duration: 2500ms; }
[data-aos-duration="2550"] { transition-duration: 2550ms; }
[data-aos-duration="2600"] { transition-duration: 2600ms; }
[data-aos-duration="2650"] { transition-duration: 2650ms; }
[data-aos-duration="2700"] { transition-duration: 2700ms; }
[data-aos-duration="2750"] { transition-duration: 2750ms; }
[data-aos-duration="2800"] { transition-duration: 2800ms; }
[data-aos-duration="2850"] { transition-duration: 2850ms; }
[data-aos-duration="2900"] { transition-duration: 2900ms; }
[data-aos-duration="2950"] { transition-duration: 2950ms; }
[data-aos-duration="3000"] { transition-duration: 3000ms; }

/* 缓动函数 */
[data-aos-easing="linear"] { transition-timing-function: linear; }
[data-aos-easing="ease"] { transition-timing-function: ease; }
[data-aos-easing="ease-in"] { transition-timing-function: ease-in; }
[data-aos-easing="ease-out"] { transition-timing-function: ease-out; }
[data-aos-easing="ease-in-out"] { transition-timing-function: ease-in-out; }
[data-aos-easing="ease-in-back"] { transition-timing-function: cubic-bezier(0.600, -0.280, 0.735, 0.045); }
[data-aos-easing="ease-out-back"] { transition-timing-function: cubic-bezier(0.175, 0.885, 0.320, 1.275); }
[data-aos-easing="ease-in-out-back"] { transition-timing-function: cubic-bezier(0.680, -0.550, 0.265, 1.550); }

/* 减少动画支持 */
@media (prefers-reduced-motion: reduce) {
  [data-aos] {
    transition-duration: 0.01ms !important;
    transition-delay: 0.01ms !important;
  }
  
  [data-aos="fade-up"],
  [data-aos="fade-down"],
  [data-aos="fade-left"],
  [data-aos="fade-right"],
  [data-aos="zoom-in"],
  [data-aos="zoom-out"] {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* 性能优化 */
[data-aos] {
  will-change: opacity, transform;
  backface-visibility: hidden;
  perspective: 1000px;
}

/* 移动端优化 */
@media (max-width: 768px) {
  [data-aos] {
    transition-duration: 300ms;
  }
  
  [data-aos="fade-up"],
  [data-aos="fade-down"] {
    transform: translate3d(0, 50px, 0);
  }
  
  [data-aos="fade-left"],
  [data-aos="fade-right"] {
    transform: translate3d(30px, 0, 0);
  }
}