/*
==========================================
移动端加载动画优化
==========================================
专门为移动端优化的加载动画样式
*/

@media screen and (max-width: 768px) {
    /* 移动端加载动画优化 */
    .loading {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: #000;
        display: flex;
        justify-content: center;
        align-items: center;
        z-index: 9999;
    }

    .loading-text {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        align-items: center;
        max-width: 90vw;
        text-align: center;
    }

    .loading-text-words {
        color: #fff;
        font-size: 1.2rem;
        font-weight: 600;
        margin: 0.2rem;
        animation: loading-animation 1.5s infinite;
        opacity: 0;
    }

    /* 移动端字符动画延迟优化 */
    .loading-text-words:nth-child(1) { animation-delay: 0.1s; }
    .loading-text-words:nth-child(2) { animation-delay: 0.2s; }
    .loading-text-words:nth-child(3) { animation-delay: 0.3s; }
    .loading-text-words:nth-child(4) { animation-delay: 0.4s; }
    .loading-text-words:nth-child(5) { animation-delay: 0.5s; }
    .loading-text-words:nth-child(6) { animation-delay: 0.6s; }
    .loading-text-words:nth-child(7) { animation-delay: 0.7s; }
    .loading-text-words:nth-child(8) { animation-delay: 0.8s; }
    .loading-text-words:nth-child(9) { animation-delay: 0.9s; }
    .loading-text-words:nth-child(10) { animation-delay: 1.0s; }
    .loading-text-words:nth-child(11) { animation-delay: 1.1s; }
    .loading-text-words:nth-child(12) { animation-delay: 1.2s; }
    .loading-text-words:nth-child(13) { animation-delay: 1.3s; }
    .loading-text-words:nth-child(14) { animation-delay: 1.4s; }
    .loading-text-words:nth-child(15) { animation-delay: 1.5s; }
    .loading-text-words:nth-child(16) { animation-delay: 1.6s; }
    .loading-text-words:nth-child(17) { animation-delay: 1.7s; }
    .loading-text-words:nth-child(18) { animation-delay: 1.8s; }
    .loading-text-words:nth-child(19) { animation-delay: 1.9s; }

    @keyframes loading-animation {
        0% {
            opacity: 0;
            transform: translateY(20px);
        }
        50% {
            opacity: 1;
            transform: translateY(0);
        }
        100% {
            opacity: 0;
            transform: translateY(-20px);
        }
    }

    /* 小屏幕优化 */
    @media screen and (max-width: 480px) {
        .loading-text-words {
            font-size: 1rem;
            margin: 0.15rem;
        }
    }

    /* 超小屏幕优化 */
    @media screen and (max-width: 360px) {
        .loading-text-words {
            font-size: 0.9rem;
            margin: 0.1rem;
        }
    }

    /* 横屏模式优化 */
    @media screen and (max-width: 768px) and (orientation: landscape) {
        .loading-text {
            flex-direction: row;
            flex-wrap: wrap;
        }
        
        .loading-text-words {
            font-size: 1rem;
            margin: 0.1rem 0.2rem;
        }
    }
}

/* 减少动画以提高性能 */
@media (prefers-reduced-motion: reduce) {
    .loading-text-words {
        animation: none;
        opacity: 1;
        transform: none;
    }
} 