/* 滚动动画CSS文件 */

/* 初始状态：隐藏元素 */
.animate-on-scroll {
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* 淡入效果 */
.animate-fade-in {
    transform: translateY(30px);
}

/* 从左滑入效果 */
.animate-slide-in-left {
    transform: translateX(-50px);
}

/* 从右滑入效果 */
.animate-slide-in-right {
    transform: translateX(50px);
}

/* 从下滑入效果 */
.animate-slide-in-bottom {
    transform: translateY(50px);
}

/* 缩放效果 */
.animate-zoom-in {
    transform: scale(0.9);
}

/* 旋转效果 */
.animate-rotate-in {
    transform: rotate(-5deg) scale(0.9);
}

/* 激活状态：显示元素并应用动画 */
.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0) translateX(0) scale(1) rotate(0);
}

/* 交错动画延迟 */
.animate-on-scroll:nth-child(1) {
    transition-delay: 0.1s;
}

.animate-on-scroll:nth-child(2) {
    transition-delay: 0.2s;
}

.animate-on-scroll:nth-child(3) {
    transition-delay: 0.3s;
}

.animate-on-scroll:nth-child(4) {
    transition-delay: 0.4s;
}

.animate-on-scroll:nth-child(5) {
    transition-delay: 0.5s;
}

.animate-on-scroll:nth-child(6) {
    transition-delay: 0.6s;
}

.animate-on-scroll:nth-child(7) {
    transition-delay: 0.7s;
}

.animate-on-scroll:nth-child(8) {
    transition-delay: 0.8s;
}

/* 滚动进度指示器 */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background-color: var(--primary-red);
    z-index: 9999;
    transition: width 0.1s ease;
}

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}

/* 滚动触发区域调整 */
@media (max-width: 768px) {
    .animate-on-scroll {
        transition-duration: 0.6s;
    }
}
