/* 基础样式和全局设置 */

/* 全局重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 基础body样式 */
body {
    font-family: sans-serif;
    background: #333;
    min-height: 100vh;
    color: white;
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
}

/* 动态背景系统 */
body::before {
    content: "";
    position: fixed;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    z-index: -1;
    background-size: cover;
    background-position: center;
    background-image: var(--bg-image, url('../background/1.png'));
    transition: opacity 1s ease-in-out, transform 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform: var(--bg-transform, translate(0, 0));
    will-change: transform;
    opacity: 1;
}

/* 背景淡入动画 */
@keyframes bgFade {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.bg-fade::before {
    animation: bgFade 1.5s forwards;
    background-image: var(--bg-image);
}

/* 通用容器 */
.container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}

/* 隐藏/显示状态 */
.hidden {
    display: none !important;
}

/* 加载动画 */
.video-loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 15px 25px;
    border-radius: 20px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* 通用动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideDown {
    from { 
        opacity: 0; 
        transform: translateX(-50%) translateY(-30px); 
    }
    to { 
        opacity: 1; 
        transform: translateX(-50%) translateY(0); 
    }
}
