/* ==================== 自定义优雅样式库 ==================== */

/* 统一的渐变动画定义 */
@keyframes gradientAnimation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 渐变标题样式 */
.elegant-title {
    font-size: 1.8em;
    font-weight: bold;
    background: linear-gradient(45deg, #FF6347, #FFD700, #FF4500, #1E90FF);
    background-size: 400%;
    animation: gradientAnimation 5s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
    margin: 1.5rem 0;
    padding: 10px 0;
    display: block;
}

.elegant-divider {
    width: 100%;
    height: 4px;
    margin: 20px 0;
    background: linear-gradient(90deg, #6b6eff, #4ecdc4, #d14545, #96e6a1);
    background-size: 300% 100%;
    animation: gradientAnimation 4s ease infinite;
    border: none;
    display: block;
}

.elegant-video {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 1.5rem auto;
    display: block;
}

.elegant-video video {
    width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
}

/* 确保自定义标签在转换前不显示 */
bt, fgx, sp {
    display: none;
}

/* 视频容器样式 - 增强版本 */
.elegant-video {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 1.5rem auto;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    background: #fff;
}

.elegant-video .video-container {
    position: relative;
    width: 100%;
}

/* 视频容器样式 - 极简版本 */
.elegant-video {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
}

.elegant-video video {
    width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
}

.elegant-video .video-player {
    width: 100%;
    height: auto;
    border-radius: 4px;
    cursor: pointer;
}

/* 深色模式适配 */
[data-theme="dark"] .elegant-video {
    background: transparent;
}

.elegant-video .video-info {
    padding: 15px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-top: 1px solid #dee2e6;
}

.elegant-video .video-title {
    font-size: 16px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 10px;
}

.elegant-video .video-controls {
    display: flex;
    gap: 10px;
}

.elegant-video .play-btn,
.elegant-video .fullscreen-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.elegant-video .play-btn:hover,
.elegant-video .fullscreen-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.elegant-video .play-btn:active,
.elegant-video .fullscreen-btn:active {
    transform: translateY(0);
}

/* 深色模式适配 */
[data-theme="dark"] .elegant-video {
    background: #2d3748;
}

[data-theme="dark"] .elegant-video .video-info {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    border-top-color: #4a5568;
}

[data-theme="dark"] .elegant-video .video-title {
    color: #e2e8f0;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .elegant-video {
        margin: 1rem auto;
        border-radius: 8px;
    }
    
    .elegant-video .video-info {
        padding: 12px 15px;
    }
    
    .elegant-video .video-title {
        font-size: 14px;
    }
    
    .elegant-video .play-btn,
    .elegant-video .fullscreen-btn {
        padding: 6px 12px;
        font-size: 13px;
    }
}

/* 悬停效果 */
.elegant-video:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
    transition: all 0.3s ease;
}

/* 代码块样式 */
.elegant-code {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-left: 4px solid #667eea;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 1.5rem 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 引用块样式 */
.elegant-quote {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border-left: 4px solid #ffc107;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 1.5rem 0;
    font-style: italic;
    color: #856404;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 提示框样式 */
.elegant-tip {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    border-left: 4px solid #17a2b8;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 1.5rem 0;
    color: #0c5460;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 警告框样式 */
.elegant-warning {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border-left: 4px solid #dc3545;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 1.5rem 0;
    color: #721c24;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 成功框样式 */
.elegant-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-left: 4px solid #28a745;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 1.5rem 0;
    color: #155724;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 深色模式适配 */
[data-theme="dark"] .elegant-title {
    background: linear-gradient(45deg, #ff6b6b, #feca57, #48dbfb, #ff9ff3);
}

[data-theme="dark"] .elegant-divider {
    background: linear-gradient(90deg, #ff6b6b, #feca57, #48dbfb, #ff9ff3);
}

[data-theme="dark"] .elegant-code {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
    border-left-color: #764ba2;
    color: #e2e8f0;
}

[data-theme="dark"] .elegant-quote {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    border-left-color: #ecc94b;
    color: #e2e8f0;
}

[data-theme="dark"] .elegant-tip {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
    border-left-color: #4299e1;
    color: #e2e8f0;
}

[data-theme="dark"] .elegant-warning {
    background: linear-gradient(135deg, #744210 0%, #5a2e0f 100%);
    border-left-color: #e53e3e;
    color: #fed7d7;
}

[data-theme="dark"] .elegant-success {
    background: linear-gradient(135deg, #22543d 0%, #1a4731 100%);
    border-left-color: #38a169;
    color: #c6f6d5;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .elegant-title {
        font-size: 1.2em;
        margin: 1rem 0;
        padding: 8px 0;
    }
    
    .elegant-divider {
        margin: 15px 0;
        height: 3px;
    }
    
    .elegant-video {
        margin: 1rem auto;
        max-width: 100%;
    }
    
    .elegant-code,
    .elegant-quote,
    .elegant-tip,
    .elegant-warning,
    .elegant-success {
        padding: 12px 15px;
        margin: 1rem 0;
        font-size: 13px;
    }
}

/* 悬停效果 */
.elegant-code:hover,
.elegant-quote:hover,
.elegant-tip:hover,
.elegant-warning:hover,
.elegant-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* 炫酷标题基础样式 */
.cool-title {
    font-size: 2.2em;
    font-weight: 800;
    text-align: center;
    margin: 2rem 0;
    padding: 20px;
    border-radius: 15px;
    position: relative;
    overflow: hidden;
}

/* bt1: 霓虹灯效果标题 */
.cool-title.neon {
    background: linear-gradient(45deg, #ff00cc, #3333ff, #00ffcc, #ffcc00);
    background-size: 400% 400%;
    animation: gradientAnimation 3s ease infinite, neonGlow 2s ease-in-out infinite alternate;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* bt2: 3D立体效果标题 */
.cool-title.three-d {
    font-size: 2.5em;
    font-weight: 900;
    color: #ff6b6b;
    text-shadow: 
        3px 3px 0 #ffd166,
        6px 6px 0 #06d6a0,
        9px 9px 0 #118ab2;
    transform: perspective(500px) rotateX(10deg);
    transition: all 0.3s ease;
}

.cool-title.three-d:hover {
    transform: perspective(500px) rotateX(0deg) scale(1.05);
    text-shadow: 
        5px 5px 0 #ffd166,
        10px 10px 0 #06d6a0,
        15px 15px 0 #118ab2;
}

/* bt3: 打字机效果标题 */
.cool-title.typewriter {
    font-family: 'Courier New', monospace;
    font-size: 1.8em;
    font-weight: 700;
    color: #00ff88;
    border-right: 3px solid #00ff88;
    white-space: nowrap;
    overflow: hidden;
    animation: typing 3s steps(40, end), blink-caret 0.75s step-end infinite;
}

/* bt4: 粒子浮动效果标题 */
.cool-title.particle {
    font-size: 2em;
    font-weight: 800;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96e6a1);
    background-size: 400% 400%;
    animation: gradientAnimation 4s ease infinite, particleFloat 3s ease-in-out infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* bt5: 金属质感效果标题 */
.cool-title.metal {
    font-size: 2.2em;
    font-weight: 900;
    background: linear-gradient(to bottom, #e0e0e0, #b0b0b0, #808080);
    background-size: 100% 200%;
    animation: metalShine 2s ease-in-out infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

/* bt6: 火焰效果标题 */
.cool-title.fire {
    font-size: 2.5em;
    font-weight: 900;
    background: linear-gradient(45deg, #ff8a00, #ff2070, #ff00cc);
    background-size: 300% 300%;
    animation: fireAnimation 2s ease infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px #ff4400, 0 0 40px #ff4400;
}

/* bt7: 星空效果标题 */
.cool-title.starry {
    font-size: 2em;
    font-weight: 800;
    color: transparent;
    background: linear-gradient(45deg, #667eea, #764ba2, #f093fb);
    background-size: 400% 400%;
    animation: gradientAnimation 5s ease infinite, starTwinkle 2s ease-in-out infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 动画定义 */
@keyframes neonGlow {
    0% {
        text-shadow: 0 0 5px #fff, 0 0 10px #ff00de, 0 0 15px #ff00de, 0 0 20px #ff00de;
    }
    100% {
        text-shadow: 0 0 10px #fff, 0 0 20px #ff00de, 0 0 30px #ff00de, 0 0 40px #ff00de;
    }
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: #00ff88 }
}

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

@keyframes metalShine {
    0%, 100% { background-position: 0% 0%; }
    50% { background-position: 0% 100%; }
}

@keyframes fireAnimation {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes starTwinkle {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* 确保自定义标签在转换前不显示 */
bt, bt1, bt2, bt3, bt4, bt5, bt6, bt7, fgx, sp {
    display: none;
}

/* 深色模式适配 */
[data-theme="dark"] .cool-title {
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

[data-theme="dark"] .cool-title.fire {
    text-shadow: 0 0 30px #ff4400, 0 0 60px #ff4400;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .cool-title {
        font-size: 1.6em;
        margin: 1.5rem 0;
        padding: 15px;
    }
    
    .cool-title.three-d {
        font-size: 1.8em;
        text-shadow: 
            2px 2px 0 #ffd166,
            4px 4px 0 #06d6a0,
            6px 6px 0 #118ab2;
    }
    
    .cool-title.typewriter {
        font-size: 1.4em;
    }
    
    .cool-title.particle,
    .cool-title.metal,
    .cool-title.fire,
    .cool-title.starry {
        font-size: 1.6em;
    }
}

/* ==================== 炫酷分隔线样式 ==================== */

/* 基础分隔线样式 */
.cool-divider {
    width: 100%;
    height: 6px;
    margin: 25px 0;
    border: none;
    display: block;
    position: relative;
    overflow: hidden;
}

/* 霓虹灯动态分隔线 <fgx1> */
.neon-divider {
    background: linear-gradient(90deg, 
        #ff00ff, #00ffff, #ffff00, #ff00ff);
    background-size: 300% 100%;
    animation: gradientAnimation 3s ease infinite;
    box-shadow: 0 0 10px #ff00ff, 0 0 20px #ff00ff, 0 0 30px #ff00ff;
    border-radius: 3px;
}

/* 波浪动画分隔线 <fgx2> */
.wave-divider {
    background: linear-gradient(90deg, 
        #4ecdc4, #44a08d, #093637, #44a08d, #4ecdc4);
    background-size: 200% 100%;
    animation: waveAnimation 4s ease-in-out infinite;
    position: relative;
}

.wave-divider::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, rgba(255,255,255,0.8), transparent);
    animation: waveFlow 3s linear infinite;
}

@keyframes waveAnimation {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes waveFlow {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* 粒子流动分隔线 <fgx3> */
.particle-divider {
    background: #1a1a1a;
    position: relative;
}

.particle-divider::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 0% 50%, 
        #ff6b6b, transparent 20%),
        radial-gradient(circle at 100% 50%, 
        #4ecdc4, transparent 20%);
    background-size: 50px 50px;
    animation: particleMove 4s linear infinite;
}

@keyframes particleMove {
    0% { background-position: 0% 0%, 100% 0%; }
    100% { background-position: 100% 0%, 0% 0%; }
}

/* 流光溢彩分隔线 <fgx4> */
.lightflow-divider {
    background: linear-gradient(90deg, 
        #ff6b6b, #ffa726, #66bb6a, #42a5f5, #ab47bc);
    background-size: 400% 100%;
    animation: lightFlow 6s ease infinite;
    position: relative;
}

.lightflow-divider::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, rgba(255,255,255,0.9), transparent);
    animation: lightShine 3s ease-in-out infinite;
}

@keyframes lightFlow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes lightShine {
    0% { left: -100%; }
    50%, 100% { left: 100%; }
}

/* 3D立体分隔线 <fgx5> */
.three-d-divider {
    background: linear-gradient(90deg, 
        #8a2387, #e94057, #f27121);
    background-size: 200% 100%;
    animation: threeDAnimation 5s ease infinite;
    border-radius: 0;
    box-shadow: 
        0 4px 8px rgba(0,0,0,0.3),
        inset 0 1px 0 rgba(255,255,255,0.2);
    transform: perspective(100px) rotateX(5deg);
}

@keyframes threeDAnimation {
    0%, 100% { 
        background-position: 0% 50%;
        transform: perspective(100px) rotateX(5deg) scaleX(1);
    }
    50% { 
        background-position: 100% 50%;
        transform: perspective(100px) rotateX(5deg) scaleX(1.05);
    }
}

/* 火焰效果分隔线 <fgx6> */
.fire-divider {
    background: linear-gradient(90deg, 
        #ff0000, #ff7b00, #ffbb00, #ff7b00, #ff0000);
    background-size: 200% 100%;
    animation: fireAnimation 3s ease infinite;
    border-radius: 8px;
    box-shadow: 
        0 0 10px #ff4400,
        0 0 20px #ff4400,
        0 0 30px #ff4400;
}

@keyframes fireAnimation {
    0%, 100% { 
        background-position: 0% 50%;
        opacity: 0.8;
    }
    50% { 
        background-position: 100% 50%;
        opacity: 1;
    }
}

/* 星空闪烁分隔线 <fgx7> */
.starry-divider {
    background: #0a0a2a;
    position: relative;
    overflow: visible;
}

.starry-divider::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    width: 100%;
    height: 26px;
    background-image: 
        radial-gradient(circle at 20% 50%, #fff 2px, transparent 3px),
        radial-gradient(circle at 40% 30%, #fff 1px, transparent 2px),
        radial-gradient(circle at 60% 70%, #fff 2px, transparent 3px),
        radial-gradient(circle at 80% 40%, #fff 1px, transparent 2px);
    background-size: 100px 100px;
    animation: starTwinkle 4s ease-in-out infinite;
}

@keyframes starTwinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* 深色模式适配 */
[data-theme="dark"] .cool-divider {
    opacity: 0.9;
}

[data-theme="dark"] .neon-divider {
    box-shadow: 0 0 15px #ff00ff, 0 0 30px #ff00ff;
}

[data-theme="dark"] .fire-divider {
    box-shadow: 
        0 0 15px #ff4400,
        0 0 30px #ff4400,
        0 0 45px #ff4400;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .cool-divider {
        height: 4px;
        margin: 20px 0;
    }
    
    .three-d-divider {
        transform: perspective(80px) rotateX(5deg);
    }
}

/* 确保自定义分隔线标签在转换前不显示 */
fgx1, fgx2, fgx3, fgx4, fgx5, fgx6, fgx7 {
    display: none;
}