/* ============================================================
   Sora视频生成平台 - 主题背景装饰
   添加电影/视频相关的视觉元素
   版本：1.0
   日期：2026-01-22
   ============================================================ */

/* ========== 全局背景优化 - 电影氛围 ========== */
body {
    position: relative;
    overflow-x: hidden;
}

/* 动态渐变背景（紫-蓝-粉电影调色板） - 增强可见度 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 10% 20%, rgba(102, 126, 234, 0.25) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(249, 115, 22, 0.20) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(139, 92, 246, 0.15) 0%, transparent 70%),
        radial-gradient(circle at 30% 60%, rgba(79, 172, 254, 0.12) 0%, transparent 60%),
        radial-gradient(circle at 70% 30%, rgba(249, 115, 22, 0.18) 0%, transparent 55%);
    z-index: 0;
    pointer-events: none;
    animation: backgroundPulse 20s ease-in-out infinite;
}

@keyframes backgroundPulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* 胶片孔装饰（左右两侧） - 增强可见度 */
body::after {
    content: '';
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    background-image:
        /* 左侧胶片孔 */
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 25px,
            rgba(249, 115, 22, 0.20) 25px,
            rgba(249, 115, 22, 0.20) 35px
        ),
        /* 右侧胶片孔 */
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 25px,
            rgba(102, 126, 234, 0.18) 25px,
            rgba(102, 126, 234, 0.18) 35px
        );
    background-position: 0 0, calc(100% - 0px) 0;
    background-size: 25px 100%, 25px 100%;
    background-repeat: no-repeat;
    z-index: 0;
    pointer-events: none;
    opacity: 1;
    box-shadow: inset 3px 0 8px rgba(249, 115, 22, 0.15),
                inset -3px 0 8px rgba(102, 126, 234, 0.15);
}

/* ========== 登录页面装饰 ========== */

/* 电影镜头光晕 */
.auth-section {
    position: relative;
}

.auth-section::before {
    content: '';
    position: absolute;
    top: -20%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(
        circle,
        rgba(249, 115, 22, 0.35) 0%,
        rgba(139, 92, 246, 0.22) 40%,
        transparent 70%
    );
    border-radius: 50%;
    filter: blur(60px);
    animation: lensFlare 15s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes lensFlare {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.5;
    }
    50% {
        transform: translate(50px, 30px) scale(1.2);
        opacity: 0.8;
    }
}

/* 右下角光晕 - 增强可见度 */
.auth-section::after {
    content: '';
    position: absolute;
    bottom: -10%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(
        circle,
        rgba(102, 126, 234, 0.30) 0%,
        rgba(79, 172, 254, 0.18) 40%,
        transparent 70%
    );
    border-radius: 50%;
    filter: blur(50px);
    animation: lensFlare2 18s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes lensFlare2 {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.6;
    }
    50% {
        transform: translate(-40px, -25px) scale(1.15);
        opacity: 0.9;
    }
}

/* 登录框周围的播放按钮装饰 - 增强可见度 */
.auth-box::after {
    content: '▶';
    position: absolute;
    right: -60px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 60px;
    color: rgba(249, 115, 22, 0.25);
    pointer-events: none;
    animation: playButtonPulse 3s ease-in-out infinite;
    text-shadow: 0 0 30px rgba(249, 115, 22, 0.6);
}

@keyframes playButtonPulse {
    0%, 100% {
        opacity: 0.3;
        transform: translateY(-50%) scale(1);
    }
    50% {
        opacity: 0.6;
        transform: translateY(-50%) scale(1.1);
    }
}

/* 电影胶片装饰点 */
.auth-box {
    position: relative;
}

/* 左上角装饰 */
.auth-box .auth-header::before {
    content: '🎬';
    position: absolute;
    left: -50px;
    top: 0;
    font-size: 40px;
    opacity: 0.15;
    animation: float 6s ease-in-out infinite;
}

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

/* ========== 主页面装饰 ========== */

/* 任务创建区域装饰 */
.create-task-box {
    position: relative;
    overflow: visible !important;
}

/* 摄像机图标装饰 */
.create-task-box h2::before {
    content: '🎥';
    margin-right: 10px;
    font-size: 26px;
    filter: drop-shadow(0 0 10px rgba(249, 115, 22, 0.4));
    animation: cameraShake 4s ease-in-out infinite;
}

@keyframes cameraShake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-3deg); }
    75% { transform: rotate(3deg); }
}

/* 视频帧装饰线 - 增强可见度 */
.create-task-box::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 4px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(249, 115, 22, 0.7) 10%,
        rgba(139, 92, 246, 0.8) 30%,
        rgba(102, 126, 234, 0.9) 50%,
        rgba(139, 92, 246, 0.8) 70%,
        rgba(249, 115, 22, 0.7) 90%,
        transparent 100%
    );
    box-shadow: 0 0 20px rgba(249, 115, 22, 0.6),
                0 0 30px rgba(102, 126, 234, 0.4);
    animation: filmStrip 3s linear infinite;
}

@keyframes filmStrip {
    0% { transform: translateX(-50%) scaleX(0.9); opacity: 0.5; }
    50% { transform: translateX(-50%) scaleX(1); opacity: 1; }
    100% { transform: translateX(-50%) scaleX(0.9); opacity: 0.5; }
}

/* ========== 任务卡片电影氛围 ========== */

/* 任务卡片左上角播放图标 - 增强可见度 */
.task-card::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    width: 40px;
    height: 40px;
    background:
        radial-gradient(circle at center,
            rgba(249, 115, 22, 0.40) 0%,
            transparent 70%);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.task-card:hover::before {
    opacity: 1;
    animation: playPulse 2s ease-in-out infinite;
}

@keyframes playPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.5;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.8;
    }
}

/* 任务卡片右下角电影胶片纹理 - 增强可见度 */
.task-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 60px;
    background:
        repeating-linear-gradient(
            45deg,
            transparent,
            transparent 5px,
            rgba(249, 115, 22, 0.12) 5px,
            rgba(249, 115, 22, 0.12) 10px
        );
    border-radius: 0 0 16px 0;
    opacity: 0.8;
    pointer-events: none;
}

/* ========== 页面顶部电影条装饰 ========== */
.header {
    position: relative;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(249, 115, 22, 0.9) 20%,
        rgba(139, 92, 246, 0.9) 40%,
        rgba(102, 126, 234, 1) 60%,
        rgba(139, 92, 246, 0.9) 80%,
        transparent 100%
    );
    box-shadow: 0 0 25px rgba(249, 115, 22, 0.8),
                0 0 35px rgba(102, 126, 234, 0.6);
    animation: filmRoll 8s linear infinite;
}

@keyframes filmRoll {
    0% { transform: translateX(-20%); }
    100% { transform: translateX(20%); }
}

/* ========== 导航标签视频主题 ========== */
.nav-item.active::before {
    content: '▶';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.8);
    animation: playIcon 1.5s ease-in-out infinite;
}

@keyframes playIcon {
    0%, 100% { opacity: 0.5; transform: translateY(-50%) translateX(0); }
    50% { opacity: 1; transform: translateY(-50%) translateX(2px); }
}

/* ========== 模态框电影幕布效果 ========== */
.modal {
    background: rgba(0, 0, 0, 0.92) !important; /* 更深的幕布感 */
}

.modal::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.03) 2px,
            rgba(0, 0, 0, 0.03) 4px
        );
    pointer-events: none;
    z-index: 1;
}

/* 模态框顶部电影条 */
.modal-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(
        90deg,
        rgba(249, 115, 22, 0.6),
        rgba(139, 92, 246, 0.6),
        rgba(102, 126, 234, 0.6)
    );
    box-shadow: 0 0 10px rgba(249, 115, 22, 0.4);
}

/* ========== 视频预览装饰 ========== */
.video-preview {
    position: relative;
}

/* 播放按钮覆盖层 */
.video-preview::before {
    content: '▶';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 60px;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 0 20px rgba(249, 115, 22, 0.8),
                 0 0 40px rgba(249, 115, 22, 0.5);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 2;
}

.video-preview:hover::before {
    opacity: 1;
    animation: playButtonGlow 2s ease-in-out infinite;
}

@keyframes playButtonGlow {
    0%, 100% {
        text-shadow: 0 0 20px rgba(249, 115, 22, 0.8),
                     0 0 40px rgba(249, 115, 22, 0.5);
    }
    50% {
        text-shadow: 0 0 30px rgba(249, 115, 22, 1),
                     0 0 60px rgba(249, 115, 22, 0.7);
    }
}

/* ========== 进度条电影胶片效果 ========== */
.progress-bar {
    position: relative;
    overflow: visible !important;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: -3px;
    left: 0;
    right: 0;
    bottom: -3px;
    background:
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 8px,
            rgba(249, 115, 22, 0.1) 8px,
            rgba(249, 115, 22, 0.1) 10px
        );
    pointer-events: none;
    z-index: 1;
}

/* ========== 响应式优化 ========== */
@media (max-width: 768px) {
    /* 移动端简化装饰 */
    body::after {
        opacity: 0.3;
    }

    .auth-section::before,
    .auth-section::after {
        opacity: 0.4;
        filter: blur(40px);
    }

    .auth-box::after,
    .auth-box .auth-header::before {
        display: none; /* 移除侧边装饰 */
    }

    .create-task-box::after {
        width: 90%;
    }
}

/* ========== 性能优化 ========== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* GPU加速 */
body::before,
body::after,
.auth-section::before,
.auth-section::after {
    will-change: transform, opacity;
    transform: translateZ(0);
}

/* ========== 加载动画装饰 ========== */
.loading-screen::before {
    content: '🎬';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 80px;
    opacity: 0.2;
    animation: loadingIcon 2s ease-in-out infinite;
}

@keyframes loadingIcon {
    0%, 100% {
        opacity: 0.1;
        transform: translate(-50%, -50%) rotate(0deg);
    }
    50% {
        opacity: 0.3;
        transform: translate(-50%, -50%) rotate(180deg);
    }
}

/* ========== Toast通知电影主题 ========== */
.toast::before {
    content: '▶';
    margin-right: 8px;
    color: rgba(249, 115, 22, 0.8);
    font-size: 12px;
}

.toast.success::before {
    content: '✓';
    color: rgba(67, 233, 123, 0.9);
}

.toast.error::before {
    content: '✕';
    color: rgba(245, 87, 108, 0.9);
}
