/* ==========================================================================
   全局重置与变量定义
   ========================================================================== */
:root {
    --brand-red: #FF3333;
    --brand-blue: #00C3FF;
    --brand-yellow: #FFD500;
    --bg-dark: #121212;
    --bg-card: #1E1E1E;
    --text-primary: #FFFFFF;
    --text-secondary: #AAAAAA;
    --gap-sm: 8px;
    --gap-md: 16px;
    --gap-lg: 24px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    width: 100%;
    height: 100%;
    background-color: #000;
    font-family: var(--font-family);
    color: var(--text-primary);
    overflow-x: hidden;
}

/* ==========================================================================
   电脑端背景 (全屏模糊+网格)
   ========================================================================== */
.desktop-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 50% 50%, rgba(255, 51, 51, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 195, 255, 0.05) 0%, transparent 40%),
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 30px 30px, 30px 30px;
    z-index: -1;
    display: none; /* 移动端默认隐藏 */
    transform: translateZ(0);
    will-change: transform;
}

/* ==========================================================================
   主容器 (手机壳/全屏容器)
   ========================================================================== */
#app-container {
    width: 100%;
    height: 100dvh; /* 移动端全屏高度 */
    /* 加强版呼吸灯颜色：深紫、亮暗蓝、猩红、亮海蓝 */
    background: linear-gradient(135deg, #2a0845, #1e3c72, #8a031e, #005c97);
    background-size: 400% 400%;
    animation: background-breathe 8s ease-in-out infinite;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

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

/* 可滚动内容区域 */
.scrollable-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    transform: translateZ(0);
}

/* ==========================================================================
   动画剧场 (Hero Section Cinematic Sequence)
   ========================================================================== */
.animation-stage {
    position: relative;
    height: 250px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 20px;
    background: transparent; /* 改为透明，让底层的主呼吸灯背景透上来 */
}

.stage-layer {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none; /* 防止遮挡下方交互 */
}


/* 2. 时空裂缝 */
.rift {
    z-index: 11;
    background: radial-gradient(ellipse at center, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 60%);
    opacity: 0;
    transform: scaleX(0.1) scaleY(0);
    animation: rift-open-fast 4s forwards;
}
@keyframes rift-open-fast {
    0%, 5% { opacity: 0; transform: scaleX(0.1) scaleY(0); }
    8% { opacity: 1; transform: scaleX(0.1) scaleY(1); }
    12%, 15% { opacity: 1; transform: scaleX(1) scaleY(1); }
    20%, 100% { opacity: 0; transform: scaleX(2) scaleY(2); }
}

/* 3. 墙壁炸裂特效 (高速版) */
.cinematic-bricks {
    z-index: 13;
    opacity: 0;
    animation: bricks-show-fast 4s forwards;
}
@keyframes bricks-show-fast {
    0%, 12% { opacity: 0; }
    13%, 25% { opacity: 1; }
    30%, 100% { opacity: 0; }
}

.wall-breaker {
    width: 120px;
    height: 120px;
    position: relative;
}
.wall {
    width: 80px;
    height: 80px;
    position: relative;
    margin: 0 auto;
}
.brick {
    position: absolute;
    width: 35px;
    height: 15px;
    background: linear-gradient(135deg, #444, #222);
    border: 1px solid #111;
    border-radius: 2px;
    animation: float-shatter-fast 4s forwards;
}

.b1 { top: 10px; left: 5px; --tx: -80px; --ty: -60px; --r: -45deg; }
.b2 { top: 10px; left: 45px; --tx: 80px; --ty: -80px; --r: 60deg; }
.b3 { top: 30px; left: -10px; --tx: -100px; --ty: 20px; --r: -20deg; }
.b4 { top: 30px; left: 30px; --tx: 40px; --ty: 60px; --r: 80deg; }
.b5 { top: 50px; left: 10px; --tx: -60px; --ty: 80px; --r: -70deg; }
.b6 { top: 50px; left: 50px; --tx: 100px; --ty: 40px; --r: 30deg; }

@keyframes float-shatter-fast {
    0%, 12% { transform: translate(0, 0) rotate(0deg) scale(1); opacity: 1; }
    22%, 100% { transform: translate(var(--tx, 0), var(--ty, 0)) rotate(var(--r, 0deg)) scale(1.5); opacity: 0; }
}

.shockwave {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid var(--brand-blue);
    box-shadow: 0 0 20px var(--brand-red), inset 0 0 10px var(--brand-yellow);
    opacity: 0;
    animation: shock-fast 4s forwards;
}
@keyframes shock-fast {
    0%, 12% { transform: translate(-50%, -50%) scale(0); opacity: 1; }
    20%, 100% { transform: translate(-50%, -50%) scale(20); opacity: 0; }
}

/* 环境粒子 (火花上升) - 保持 */
.magic-particles {
    z-index: 15;
}
.particle-system {
    position: absolute;
    bottom: -150px;
    width: 6px;
    height: 6px;
    background: #FFD500;
    border-radius: 50%;
    filter: blur(1px);
    box-shadow: 
        20px 0px #FF3333, -30px 20px #FFD500, 50px 40px #fff,
        -50px -10px #FF3333, 80px 10px #FFD500, -80px 30px #fff,
        10px 60px #FF3333, -10px 80px #FFD500, 40px 100px #fff;
    opacity: 0;
    animation: particles-rise-fast 4s forwards ease-out;
}
@keyframes particles-rise-fast {
    0%, 15% { opacity: 0; transform: translateY(0); }
    20%, 90% { opacity: 0.8; transform: translateY(-300px); }
    100% { opacity: 0; transform: translateY(-400px); }
}

/* 4. 角色降落 */
.hero-landing {
    z-index: 20;
}
.character-loli {
    position: absolute;
    bottom: 20%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
    width: 100%;
    display: flex;
    justify-content: center;
}
.character-loli img {
    height: auto;
    width: 100%;
    max-width: 600px;
    max-height: 70vh;
    animation: char-glow-breathe 8s ease-in-out infinite; /* 人物本身散发呼吸灯光晕 */
}

@keyframes char-glow-breathe {
    0% { filter: drop-shadow(0 0 30px rgba(255, 51, 51, 0.8)); }
    33% { filter: drop-shadow(0 0 50px rgba(0, 195, 255, 0.9)); }
    66% { filter: drop-shadow(0 0 40px #bf00ff); }
    100% { filter: drop-shadow(0 0 30px rgba(255, 51, 51, 0.8)); }
}
@keyframes hero-drop-fast {
    0%, 10% { opacity: 0; transform: scale(2) translateY(-50px); }
    14% { opacity: 1; transform: scale(1) translateY(10px); } /* 砸地 */
    18%, 100% { opacity: 1; transform: scale(1) translateY(0); }
}

/* Live2D 模拟呼吸浮动 */
.epic-breathing {
    animation: breathe 4s ease-in-out infinite;
    animation-delay: 0.72s; 
}
@keyframes breathe {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-10px) scale(1.02); }
}

/* 5. 史诗级光效 UI */
.epic-ui {
    z-index: 30;
    width: 100%;
    padding: 30px 0;
    margin-top: 20px;
}
.cinematic-logo {
    font-size: 56px;
    font-weight: 900;
    letter-spacing: -1px;
    margin-bottom: 20px;
    text-shadow: 0 0 20px rgba(0, 195, 255, 0.5), 0 5px 30px rgba(255, 51, 51, 0.5);
    animation: brand-glow 3s ease-in-out infinite alternate;
    position: relative;
}



@keyframes brand-glow {
    0% { text-shadow: 0 0 10px rgba(0, 195, 255, 0.3), 0 0 20px rgba(255, 51, 51, 0.3); }
    100% { text-shadow: 0 0 30px rgba(0, 195, 255, 0.8), 0 0 50px rgba(255, 51, 51, 0.8), 0 0 70px rgba(255, 213, 0, 0.6); }
}



.logo-red { color: #FF3333; }
.logo-blue { color: #00C3FF; }
.logo-yellow { color: #FFD500; }

.cinematic-text {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    opacity: 0;
    margin-bottom: 10px;
    letter-spacing: 2px;
}
.text-up {
    animation: text-epic-slide-up-fast 4s forwards;
    font-size: 22px; /* 移动端调小防换行断层 */
    color: #FFFF88; /* 高亮浅黄色 */
    /* 强硬的黑色描边级阴影 */
    text-shadow: 0 0 5px #000, 0 0 10px #000, 0 0 15px #000, 0 2px 20px rgba(0,0,0,0.9);
}
.text-down {
    animation: text-epic-slide-down-fast 4s forwards;
    font-size: 16px; /* 移动端调小 */
    color: #00C3FF;
    /* 强硬的黑色描边级阴影 */
    text-shadow: 0 0 5px #000, 0 0 10px #000, 0 0 15px #000, 0 2px 20px rgba(0,0,0,0.9);
}

@keyframes text-epic-slide-up-fast {
    0%, 28% { opacity: 0; transform: translateY(50px) scale(0.5); }
    33% { opacity: 1; transform: translateY(-10px) scale(1.1); text-shadow: 0 0 40px #fff, 0 0 80px #FFFF88; }
    38%, 100% { opacity: 1; transform: translateY(0) scale(1); text-shadow: 0 0 5px #000, 0 0 10px #000, 0 0 20px #000, 0 0 20px #FFFF88; }
}
@keyframes text-epic-slide-down-fast {
    0%, 35% { opacity: 0; transform: translateY(-50px) scale(0.5); }
    40% { opacity: 1; transform: translateY(10px) scale(1.1); text-shadow: 0 0 40px #fff, 0 0 80px #00C3FF; }
    45%, 100% { opacity: 1; transform: translateY(0) scale(1); text-shadow: 0 0 5px #000, 0 0 10px #000, 0 0 20px #000, 0 0 20px #00C3FF; }
}

/* 6. CTA 按钮淡入 */
.cinematic-cta {
    position: relative;
    z-index: 31;
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    max-width: 400px;
    margin: 15px auto 0;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    animation: cta-epic-fade-fast 4s forwards ease-out;
}
@keyframes cta-epic-fade-fast {
    0%, 48% { opacity: 0; transform: translateY(20px); pointer-events: none; }
    58%, 100% { opacity: 1; transform: translateY(0); pointer-events: auto; }
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 48px; /* 适合手指点击 */
    border-radius: 24px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--brand-red), #D61A1A);
    color: #fff;
    box-shadow: 0 8px 20px rgba(255, 51, 51, 0.3);
}
.btn-primary:active { transform: scale(0.98); }

.btn-secondary {
    background: rgba(255,255,255,0.05);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.1);
}
.btn-secondary:active { background: rgba(255,255,255,0.1); }

/* 底部/顶部导航栏 (手机版/平板版底部) */
.category-nav {
    width: 100%;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 100;
    padding: 10px 0;
    border-radius: 0 0 20px 20px;
    transform: translateZ(0);
    will-change: transform;
}

/* ==========================================================================
   全局电脑端顶部档案标签 (大屏显示) - 极简毛玻璃发光风 (Premium Glassmorphism)
   ========================================================================== */
.global-desktop-tabs {
    display: none; /* 手机端隐藏 */
}

@media (min-width: 768px) {
    .global-desktop-tabs {
        display: flex;
        justify-content: center;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 999;
        /* 高级通透毛玻璃背景 */
        background: rgba(10, 10, 10, 0.4);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        padding-top: 15px;
        padding-bottom: 10px;
        pointer-events: none; /* 让背景点击穿透 */
    }
    
    .tabs-container {
        display: flex;
        gap: 15px; /* 卡片间距 */
        pointer-events: auto; /* 恢复标签的点击 */
    }
    
    /* 玻璃质感悬浮卡片 */
    .tab-item {
        position: relative;
        padding: 12px 30px;
        color: rgba(255, 255, 255, 0.6);
        text-decoration: none;
        font-weight: 700;
        font-size: 20px;
        letter-spacing: 2px;
        background: rgba(255, 255, 255, 0.03); /* 极弱的白光底色 */
        border: 1px solid rgba(255, 255, 255, 0.05);
        border-radius: 12px; /* 圆润包边 */
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
        transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
        overflow: hidden;
    }
    
    /* 高亮/选中特效：纯白发光文字 + 霓虹底光 */
    .tab-item:hover, .tab-item.active {
        color: #ffffff; /* 极致纯白 */
        background: rgba(255, 255, 255, 0.1);
        border-color: rgba(255, 255, 255, 0.3);
        box-shadow: 0 8px 25px rgba(0, 195, 255, 0.2), inset 0 0 20px rgba(255, 255, 255, 0.05);
        transform: translateY(-2px);
        text-shadow: 0 0 10px rgba(255, 255, 255, 0.5); /* 文字发光 */
    }

    /* 炫彩底边线特效 */
    .tab-item.active::after, .tab-item:hover::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 3px;
        background: linear-gradient(90deg, #FF3333, #00C3FF, #FFD500);
        box-shadow: 0 -2px 10px rgba(0, 195, 255, 0.5);
    }

    .tab-glow {
        display: none; /* 移除原本的光块 */
    }

    /* 腾出顶部空间给 app-container */
    #app-container {
        margin-top: 80px;
    }
}

/* 手机端毛玻璃风 */
.category-list {
    display: flex;
    justify-content: space-evenly;
    gap: 12px;
    overflow-x: auto;
    list-style: none;
    padding: 0 15px;
}
.category-list::-webkit-scrollbar {
    display: none;
}
.category-item {
    white-space: nowrap;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    font-size: 13px;
    color: rgba(255,255,255,0.6);
    cursor: pointer;
    flex: 1;
    text-align: center;
    transition: all 0.3s ease;
}
/* 手机端选中高亮 */
.category-item.active {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-weight: 700;
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 15px rgba(0, 195, 255, 0.2);
    text-shadow: 0 0 8px rgba(255,255,255,0.5);
}

/* ==========================================================================
   小红书风格 博客瀑布流 (使用 Grid 实现更稳定的列排布)
   ========================================================================== */
.blog-grid {
    padding: 0 var(--gap-md) 40px;
    display: grid;
    grid-template-columns: 1fr; /* 移动端单列显示，避免卡片过于狭长 */
    gap: 12px;
}

.blog-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    transform: translateZ(0);
    will-change: transform, box-shadow;
}
.blog-card:hover {
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 195, 255, 0.2), 0 0 15px rgba(255, 51, 51, 0.1);
    border-color: rgba(0, 195, 255, 0.3);
}
.blog-card:active {
    transform: scale(0.98);
}

.card-excerpt {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-content {
    padding: 15px; /* 增加一点内边距让正方形更饱满 */
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card-title {
    font-size: 16px; /* 原本是 14px，调大增强标题感 */
    font-weight: 600; /* 加粗一点显得更有力量感 */
    line-height: 1.4;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: auto; /* 强制底部对齐，充满剩余空间 */
}

/* ==========================================================================
   页脚
   ========================================================================== */
.app-footer {
    text-align: center;
    padding: 20px 0;
    font-size: 12px;
    color: #666;
    border-top: 1px solid rgba(255,255,255,0.05);
}

/* ==========================================================================
   响应式设计：电脑端显示为居中手机模拟器
   ========================================================================== */
@media (min-width: 769px) {
    body {
        display: flex;
        justify-content: center;
        align-items: center;
    }
    
    .desktop-bg {
        display: block;
    }

    #app-container {
        width: 1300px; /* 大幅度拓宽，适应现代电脑屏幕 */
        max-width: 96vw;
        height: 94vh; /* 撑满高度 */
        max-height: 1200px; 
        min-height: 700px;
        border-radius: 24px;
        box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8),
                    0 0 0 14px #222, 
                    0 0 0 15px #333;
        margin: 40px 0;
        overflow: hidden;
    }

    /* 自定义电脑端的滚动条，保持质感 */
    .scrollable-content::-webkit-scrollbar {
        width: 6px;
    }
    .scrollable-content::-webkit-scrollbar-thumb {
        background: rgba(255,255,255,0.2);
        border-radius: 6px;
    }

    /* 随着屏幕大幅拓宽，瀑布流调整为 4 列，以防卡片太宽 */
    .blog-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
        padding: 0 30px 40px;
    }

    .cinematic-cta {
        flex-direction: row;
        gap: 20px;
        max-width: 600px;
    }
    .btn {
        flex: 1;
    }
    
    .animation-stage {
        height: 350px;
    }
    .cinematic-logo {
        font-size: 64px;
        margin-bottom: 30px;
    }
    .text-up {
        font-size: 32px; /* 电脑端放大 */
        margin-bottom: 20px;
    }
    .text-down {
        font-size: 22px; /* 电脑端放大 */
    }
    .category-nav {
        display: none !important;
    }
    .card-title {
        font-size: 18px; /* 电脑端进一步放大标题 */
    }
    .blog-card {
        aspect-ratio: 1 / 1; /* 仅在电脑端强制卡片为正方形 */
    }
}

/* ==========================================================================
   背景流星划过特效 (Meteor Shower Effect)
   ========================================================================== */
body.home-page::before {
    content: '';
    position: fixed;
    /* 将流星的物理中心精确定位在屏幕正中央 */
    top: 50%;
    left: 50%;
    margin-top: -15px; /* 高度30的一半 */
    margin-left: -1000px; /* 长度2000的一半 */
    width: 2000px; /* 长度 */
    height: 30px; /* 宽度 */
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 1));
    border-radius: 50%;
    filter: drop-shadow(0 0 100px rgba(0, 195, 255, 1)) drop-shadow(0 0 200px rgba(255, 255, 255, 0.8));
    animation: meteor-strike 30s linear infinite;
    pointer-events: none;
    z-index: 9999; /* 强制页面最高层级，绝对不会被遮挡 */
}

@keyframes meteor-strike {
    0% {
        opacity: 1;
        /* 在屏幕正中心旋转45度，退后3000px */
        transform: rotate(45deg) translate(-3000px, 0);
    }
    10% {
        opacity: 0;
        /* 冲过屏幕中心，飞跃到右下角极远处 */
        transform: rotate(45deg) translate(3000px, 0);
    }
    100% {
        opacity: 0;
        transform: rotate(45deg) translate(3000px, 0);
    }
}


/* ==========================================================================
   首页 实力排行榜 (Rank Board)
   ========================================================================== */
.rank-board {
    max-width: 1100px;
    margin: 40px auto;
    padding: 30px;
    background: linear-gradient(135deg, rgba(224, 242, 254, 0.5) 0%, rgba(200, 230, 255, 0.5) 100%);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --header-bg: #153a7b;
    --tier1-color: #d2a13b;
    --tier2-color: #0076c0;
    --tier3-color: #802c8c;
    --text-dark: #333333;
    --text-muted: #666666;
    --text-light: #999999;
    --card-bg: #ffffff;
}

.rank-board header {
    background-color: var(--header-bg);
    color: white;
    text-align: center;
    padding: 30px 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.rank-board .tier-section {
    background-color: var(--card-bg);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.rank-board .tier-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #f0f2f5;
    padding-bottom: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.rank-board .tier-title-area {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.rank-board .tier-title-area h2 {
    font-size: 24px;
    font-weight: bold;
    margin: 0;
}

.rank-board .tier-1 .tier-title-area h2 { color: var(--tier1-color); }
.rank-board .tier-2 .tier-title-area h2 { color: var(--tier2-color); }
.rank-board .tier-3 .tier-title-area h2 { color: var(--tier3-color); }

.rank-board .stars {
    font-size: 18px;
    letter-spacing: 2px;
}
.rank-board .tier-1 .stars { color: var(--tier1-color); }
.rank-board .tier-2 .stars { color: var(--tier2-color); }
.rank-board .tier-3 .stars { color: var(--tier3-color); }

.rank-board .tier-features {
    font-size: 14px;
    color: var(--text-muted);
    align-self: center;
}

.rank-board .rank-card-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.rank-board .rank-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
    color: var(--text-dark);
}
.rank-board .rank-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.rank-board .rank-card-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
}
.rank-board .tier-1 .rank-card-title { color: var(--tier1-color); }
.rank-board .tier-2 .rank-card-title { color: var(--tier2-color); }
.rank-board .tier-3 .rank-card-title { color: var(--tier3-color); }
.rank-board .rank-card-subtitle {
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 12px;
    font-weight: 500;
}
.rank-board .rank-card-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
    text-align: justify;
}

/* Hide card 3 and 4 on mobile */
@media (max-width: 576px) {
    .rank-board .rank-card-grid { 
        grid-template-columns: 1fr; 
    }
    .rank-board .tier-header { 
        flex-direction: column; 
        align-items: flex-start; 
    }
    .rank-board .rank-card:nth-child(n+3) {
        display: none !important;
    }
}
@media (max-width: 992px) and (min-width: 577px) {
    .rank-board .rank-card-grid { grid-template-columns: repeat(2, 1fr); }
}

/* CTA Button */
.rank-cta-btn {
    display: inline-block;
    padding: 6px 16px;
    font-size: 14px;
    font-weight: bold;
    color: white;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-radius: 20px;
    text-decoration: none;
    margin-left: 15px;
    box-shadow: 0 2px 8px rgba(220, 38, 38, 0.4);
    transition: all 0.3s ease;
}
.rank-cta-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.6);
}

/* ==========================================================================
   机场页面 实力排行榜 (Airport Rank Board)
   ========================================================================== */
#airport-ranking-board .ar-container {
    max-width: 1200px;
    margin: 0 auto;
    background: linear-gradient(135deg, rgba(224, 242, 254, 0.5) 0%, rgba(200, 230, 255, 0.5) 100%);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 20px;
}

/* 第一梯队专属青色底板 */
#airport-ranking-board .ar-tier-1-container {
    background: linear-gradient(135deg, rgba(204, 255, 245, 0.6) 0%, rgba(128, 255, 229, 0.4) 100%);
    box-shadow: 0 8px 32px rgba(0, 204, 153, 0.15);
    border: 1px solid rgba(0, 255, 204, 0.2);
}

#airport-ranking-board .ar-tier-divider {
    text-align: center;
    margin: 40px auto 30px auto;
    max-width: 1200px;
}
#airport-ranking-board .ar-tier-divider h2 {
    color: #ffffff;
    font-size: 28px;
    font-weight: 800;
    text-shadow: 0 4px 15px rgba(0,0,0,0.5);
    letter-spacing: 2px;
    margin-bottom: 8px;
}
#airport-ranking-board .ar-tier-divider p {
    color: rgba(255,255,255,0.8);
    font-size: 15px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

#airport-ranking-board .ar-ranking-section {
    background-color: #ffffff;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.04);
}

/* 神魔之塔 稀有大卡片边框特效 (Gacha Rare Card Effect on Section) */
#airport-ranking-board .ar-rank-top1,
#airport-ranking-board .ar-rank-top2,
#airport-ranking-board .ar-rank-top3 {
    position: relative;
    z-index: 2;
}

/* 发光渐变动态边框 */
#airport-ranking-board .ar-rank-top1::before,
#airport-ranking-board .ar-rank-top2::before,
#airport-ranking-board .ar-rank-top3::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 14px;
    padding: 4px;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 10;
    background-size: 200% 200%;
    animation: gacha-border-spin 3s linear infinite;
}

/* 镭射扫光特效 (Foil Sweep) */
#airport-ranking-board .ar-rank-top1::after,
#airport-ranking-board .ar-rank-top2::after,
#airport-ranking-board .ar-rank-top3::after {
    content: '';
    position: absolute;
    inset: -4px;
    clip-path: inset(0 round 14px);
    background: linear-gradient(105deg, transparent 20%, rgba(255,255,255,0.8) 25%, transparent 30%);
    background-size: 200% 200%;
    animation: gacha-foil-sweep 4s infinite;
    pointer-events: none;
    z-index: 11;
}

/* TOP1: UR神话级 金钻红莲 (Gold/Crimson/Diamond) */
#airport-ranking-board .ar-rank-top1::before {
    background-image: linear-gradient(135deg, #ffd700, #ff0055, #ffffff, #ffd700, #ff0055);
}
#airport-ranking-board .ar-rank-top1 {
    box-shadow: 0 4px 25px rgba(255, 215, 0, 0.25);
}

/* TOP2: SSR传说级 冰晶星河 (Ice Blue/Cyan/Diamond) */
#airport-ranking-board .ar-rank-top2::before {
    background-image: linear-gradient(135deg, #00f2fe, #4facfe, #ffffff, #00f2fe, #4facfe);
}
#airport-ranking-board .ar-rank-top2 {
    box-shadow: 0 4px 25px rgba(0, 242, 254, 0.25);
}

/* TOP3: SR史诗级 虚空幻紫 (Amethyst/Magenta/Diamond) */
#airport-ranking-board .ar-rank-top3::before {
    background-image: linear-gradient(135deg, #8e2de2, #f64f59, #ffffff, #8e2de2, #f64f59);
}
#airport-ranking-board .ar-rank-top3 {
    box-shadow: 0 4px 25px rgba(142, 45, 226, 0.25);
}
#airport-ranking-board .ar-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #f4f5f7;
    padding-bottom: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}
#airport-ranking-board .ar-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
#airport-ranking-board .ar-rank-title {
    font-size: 24px;
    font-weight: 800;
}
#airport-ranking-board .ar-rank-top1 .ar-rank-title { color: #d97706; }
#airport-ranking-board .ar-rank-top2 .ar-rank-title { color: #0284c7; }
#airport-ranking-board .ar-rank-top3 .ar-rank-title { color: #9333ea; }
#airport-ranking-board .ar-rank-top4 .ar-rank-title { color: #000000; }
#airport-ranking-board .ar-rank-top5 .ar-rank-title { color: #000000; }
#airport-ranking-board .ar-rank-other .ar-rank-title { color: #475569; }

#airport-ranking-board .ar-stars {
    font-size: 18px;
    letter-spacing: 2px;
    color: #f59e0b;
}

#airport-ranking-board .ar-header-right {
    font-size: 14px;
    color: #64748b;
}
#airport-ranking-board .ar-header-right strong {
    color: #334155;
}

#airport-ranking-board .ar-btn-official {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 16px;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    color: white;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(225, 29, 72, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
}
#airport-ranking-board .ar-btn-official:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.6);
}

#airport-ranking-board .ar-grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}



@keyframes gacha-border-spin {
    0% { background-position: 0% 0%; }
    100% { background-position: 200% 200%; }
}
@keyframes gacha-foil-sweep {
    0% { background-position: 200% 200%; }
    20% { background-position: -100% -100%; }
    100% { background-position: -100% -100%; }
}

@media (max-width: 950px) {
    #airport-ranking-board .ar-grid-container {
        display: flex;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 12px;
        gap: 12px;
    }
    #airport-ranking-board .ar-info-card {
        flex: 0 0 280px;
    }
}

#airport-ranking-board .ar-info-card {
    background-color: rgba(224, 242, 254, 0.5);
    backdrop-filter: blur(5px);
    border: 1px solid #eef0f4;
    border-radius: 8px;
    padding: 18px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: all 0.3s ease;
    color: #333;
}
#airport-ranking-board .ar-info-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.06);
}
#airport-ranking-board .ar-card-index-title {
    font-size: 15px;
    font-weight: 700;
}
#airport-ranking-board .ar-card-subtitle {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
}
#airport-ranking-board .ar-card-desc {
    font-size: 13px;
    color: #475569;
    line-height: 1.5;
}

/* ==========================================================================
   软件下载中心 (Software Download Center)
   ========================================================================== */
#software-download-center {
  --sd-bg-color: transparent;
  --sd-card-bg: #ffffff;
  --sd-text-main: #1e293b;
  --sd-text-muted: #64748b;
  display: flex;
  justify-content: center;
}
#software-download-center .sd-wrapper {
  max-width: 1200px;
  width: 100%;
  margin-bottom: 20px;
  background-color: var(--sd-bg-color);
  padding: 40px 30px;
  border-radius: 16px;
}
#software-download-center .sd-welcome-header { text-align: center; margin-bottom: 40px; }
#software-download-center .sd-welcome-header h1 {
  font-size: 32px; font-weight: 700; letter-spacing: -0.5px; margin-bottom: 8px;
  background: linear-gradient(135deg, #fff, #ddd);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
#software-download-center .sd-welcome-header p { color: #ccc; font-size: 14px; }
#software-download-center .sd-download-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px;
}
#software-download-center .sd-app-card {
  background: var(--sd-card-bg); border-radius: 16px; padding: 24px 20px; text-align: center;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease; position: relative; overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.8); display: flex; flex-direction: column; justify-content: space-between;
  color: var(--sd-text-main);
}
#software-download-center .sd-app-card:hover { transform: translateY(-4px); box-shadow: 0 12px 20px -5px rgba(0, 0, 0, 0.08); }
#software-download-center .sd-app-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 4px; }
#software-download-center .sd-card-win::before { background: #0078d4; }
#software-download-center .sd-card-android::before { background: #3ddc84; }
#software-download-center .sd-card-ios::before { background: #000000; }
#software-download-center .sd-icon-wrapper {
  width: 56px; height: 56px; border-radius: 14px; margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center; font-size: 26px;
}
#software-download-center .sd-card-win .sd-icon-wrapper { color: #0078d4; background: #f3f9fe; }
#software-download-center .sd-card-android .sd-icon-wrapper { color: #3ddc84; background: #f0fdf4; }
#software-download-center .sd-card-ios .sd-icon-wrapper { color: #1a1a1a; background: #f8fafc; }
#software-download-center .sd-app-title { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
#software-download-center .sd-app-meta { font-size: 11px; color: var(--sd-text-muted); margin-bottom: 18px; }
#software-download-center .sd-dl-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  padding: 10px 14px; border-radius: 10px; font-size: 13px; font-weight: 600; color: #ffffff;
  text-decoration: none; margin-bottom: 10px; transition: filter 0.2s;
}
#software-download-center .sd-dl-btn:hover { filter: brightness(1.1); }
#software-download-center .sd-card-win .sd-dl-btn { background: linear-gradient(135deg, #0078d4, #005a9e); }
#software-download-center .sd-card-android .sd-dl-btn { background: linear-gradient(135deg, #3ddc84, #10b981); }
#software-download-center .sd-card-ios .sd-dl-btn { background: linear-gradient(135deg, #1e293b, #0f172a); }
#software-download-center .sd-sub-group {
  display: flex; flex-direction: column; gap: 6px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed #e2e8f0;
}
#software-download-center .sd-sub-link {
  display: flex; align-items: center; justify-content: space-between; padding: 8px 12px;
  background: #f8fafc; border-radius: 6px; font-size: 11px; color: var(--sd-text-main);
  text-decoration: none; font-weight: 500; border: 1px solid #f1f5f9; transition: background 0.2s;
}
#software-download-center .sd-sub-link:hover { background: #f1f5f9; }
#software-download-center .sd-sub-link i { color: var(--sd-text-muted); font-size: 12px; }

/* ==========================================================================
   Ghost Tabs Optimization
   ========================================================================== */
.tab-item {
    background: transparent !important;
    border: 2px solid rgba(255,255,255,0.3) !important;
    border-radius: 30px;
}
.tab-item:hover, .tab-item.active {
    background: rgba(255,255,255,0.1) !important;
    border-color: rgba(255,255,255,0.8) !important;
}
.tab-glow { display: none !important; }


/* ==========================================================================
   User Requests Overrides (Fixes)
   ========================================================================== */

/* 1. 取消 Clashvpnss 的 特效/发光 */
.epic-glow, .epic-glow span, .logo-red, .logo-blue, .logo-yellow {
    text-shadow: none !important;
    animation: none !important;
    filter: none !important;
}

/* 2. 首页的 Clashvpnss 放到中间 */
.cinematic-content.epic-ui {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    width: 100% !important;
    text-align: center !important;
    margin: 0 auto !important;
    position: relative !important;
    left: 0 !important;
    transform: none !important;
}
.cinematic-logo {
    margin: 0 auto 10px auto !important;
    text-align: center !important;
}

/* 3. 下方按钮 做成方形按钮 */
.btn {
    border-radius: 6px !important;
}
.cinematic-cta .btn {
    border-radius: 6px !important;
}
.rank-cta-btn {
    border-radius: 6px !important;
}
.ar-btn-official {
    border-radius: 6px !important;
}
.sd-dl-btn {
    border-radius: 6px !important;
}

/* 4. 网页版的文章最下面的红色/绿色按钮做成左右结构 */
@media (min-width: 768px) {
    .article-cta, .cta-group, .bottom-cta {
        display: flex !important;
        flex-direction: row !important;
        justify-content: center !important;
        gap: 20px !important;
        max-width: 800px !important;
        margin: 40px auto 0 !important;
    }
    .article-cta .btn, .cta-group .btn, .bottom-cta .btn {
        flex: 0 1 45% !important;
        margin: 0 !important;
    }
}

/* 5. 修复首页弹窗样式 */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}
.modal-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    text-align: center;
}
.modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}
.modal-title {
    font-size: 20px;
    color: #ef4444;
    margin-bottom: 15px;
    font-weight: bold;
}
.modal-desc {
    font-size: 14px;
    color: #333;
    margin-bottom: 25px;
    line-height: 1.5;
}
.modal-btn {
    display: inline-block !important;
    padding: 10px 24px !important;
    border-radius: 6px !important;
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
    color: white !important;
    text-decoration: none !important;
    font-weight: bold !important;
    border: none !important;
}


/* ==========================================================================
   2026 机场推荐 绿色按钮 (btn-tertiary)
   ========================================================================== */
.btn-tertiary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: bold;
    color: white !important;
    background: linear-gradient(135deg, #10b981, #059669) !important; /* Green gradient */
    border-radius: 6px !important;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
    transition: all 0.3s ease;
    border: none;
}
.btn-tertiary:hover {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
    transform: translateY(-2px) !important;
    filter: brightness(1.1);
}

/* ==========================================================================
   全新高级软件下载中心 (Ultimate Software Download Center)
   ========================================================================== */
#software-download-center {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 0 20px 40px 20px;
}
.sd-wrapper {
    max-width: 1200px;
    width: 100%;
    position: relative;
    z-index: 10;
}
.sd-welcome-header {
    text-align: center;
    margin-bottom: 50px;
}
.sd-welcome-header h2 {
    font-size: 36px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 15px;
    letter-spacing: 1px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}
.sd-welcome-header p {
    color: rgba(255,255,255,0.7);
    font-size: 16px;
    max-width: 600px;
    margin: 0 auto;
}
.sd-download-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}
@media (max-width: 1024px) {
    .sd-download-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .sd-download-grid { grid-template-columns: 1fr; }
}

.sd-app-card {
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    padding: 30px 20px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}
.sd-app-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 4px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.sd-app-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    border-color: rgba(255,255,255,0.25);
    background: rgba(30, 41, 59, 0.85);
}
.sd-app-card:hover::before {
    opacity: 1;
}

.sd-icon-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 18px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #ffffff;
    box-shadow: inset 0 2px 10px rgba(255,255,255,0.2), 0 8px 20px rgba(0,0,0,0.3);
}
/* Specific Icon Colors */
.sd-card-win .sd-icon-wrapper { background: linear-gradient(135deg, #0078d4, #005a9e); }
.sd-card-mac .sd-icon-wrapper { background: linear-gradient(135deg, #5c5c5c, #1f1f1f); }
.sd-card-android .sd-icon-wrapper { background: linear-gradient(135deg, #3ddc84, #10b981); }
.sd-card-ios .sd-icon-wrapper { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.sd-card-linux .sd-icon-wrapper { background: linear-gradient(135deg, #f59e0b, #d97706); }
.sd-card-tv .sd-icon-wrapper { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.sd-card-router .sd-icon-wrapper { background: linear-gradient(135deg, #ef4444, #b91c1c); }
.sd-card-browser .sd-icon-wrapper { background: linear-gradient(135deg, #f43f5e, #be123c); }

.sd-app-title {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}
.sd-app-meta {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
    margin-bottom: 25px;
    line-height: 1.4;
}

.sd-dl-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 15px;
    border-radius: 12px !important;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    text-decoration: none;
    margin-bottom: 12px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    transition: all 0.3s ease;
}
.sd-dl-btn:hover {
    background: #ffffff;
    color: #1e293b;
    transform: scale(1.03);
    box-shadow: 0 5px 15px rgba(255,255,255,0.2);
}

.sd-sub-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 15px;
    margin-top: auto;
}
.sd-sub-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: rgba(0,0,0,0.2);
    border-radius: 8px;
    font-size: 12px;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: all 0.2s ease;
}
.sd-sub-link:hover {
    background: rgba(255,255,255,0.1);
    color: #ffffff;
}
.sd-sub-link i {
    font-size: 10px;
    opacity: 0.5;
}


/* ==========================================================================
   Kids Science Cards
   ========================================================================== */
#kids-science-cards {
    font-family: 'PingFang SC', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    color: #2C3E50;
    margin: 40px auto;
    padding: 0 20px;
    max-width: 1200px;
}

#kids-science-cards * {
    box-sizing: border-box;
}

#kids-science-cards .ksc-container {
    max-width: 1000px;
    margin: 0 auto;
    background-color: #EBF3FA;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
}

#kids-science-cards .ksc-main-header {
    text-align: center;
    margin-bottom: 40px;
}

#kids-science-cards .ksc-main-header h2 {
    color: #2B6CB0;
    font-size: 32px;
    margin-bottom: 12px;
    font-weight: 800;
}

#kids-science-cards .ksc-main-header p {
    color: #4A5568;
    font-size: 16px;
    margin: 0;
}

#kids-science-cards .ksc-cards-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

#kids-science-cards .ksc-card-cell {
    flex: 0 0 50%;
    max-width: 50%;
    padding: 15px;
    margin-bottom: 20px;
}

#kids-science-cards .ksc-kid-card {
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    border: 4px solid #4299E1;
    transition: transform 0.2s;
}

#kids-science-cards .ksc-kid-card:hover {
    transform: translateY(-5px);
}

/* Themes */
#kids-science-cards .ksc-theme-blue { border-color: #4299E1; }
#kids-science-cards .ksc-theme-blue .ksc-card-header { background-color: #4299E1; }
#kids-science-cards .ksc-theme-blue .ksc-story-box { background-color: #EBF8FF; border-color: #90CDF4; }
#kids-science-cards .ksc-theme-blue .ksc-story-title { color: #2B6CB0; }
#kids-science-cards .ksc-theme-blue .ksc-card-btn { background-color: #4299E1; }

#kids-science-cards .ksc-theme-green { border-color: #48BB78; }
#kids-science-cards .ksc-theme-green .ksc-card-header { background-color: #48BB78; }
#kids-science-cards .ksc-theme-green .ksc-story-box { background-color: #F0FFF4; border-color: #9AE6B4; }
#kids-science-cards .ksc-theme-green .ksc-story-title { color: #22543D; }
#kids-science-cards .ksc-theme-green .ksc-card-btn { background-color: #48BB78; }

#kids-science-cards .ksc-theme-purple { border-color: #9F7AEA; }
#kids-science-cards .ksc-theme-purple .ksc-card-header { background-color: #9F7AEA; }
#kids-science-cards .ksc-theme-purple .ksc-story-box { background-color: #FAF5FF; border-color: #D6BCFA; }
#kids-science-cards .ksc-theme-purple .ksc-story-title { color: #4C51BF; }
#kids-science-cards .ksc-theme-purple .ksc-card-btn { background-color: #9F7AEA; }

#kids-science-cards .ksc-theme-orange { border-color: #ED8936; }
#kids-science-cards .ksc-theme-orange .ksc-card-header { background-color: #ED8936; }
#kids-science-cards .ksc-theme-orange .ksc-story-box { background-color: #FFFAF0; border-color: #FBD38D; }
#kids-science-cards .ksc-theme-orange .ksc-story-title { color: #9C4221; }
#kids-science-cards .ksc-theme-orange .ksc-card-btn { background-color: #ED8936; }

#kids-science-cards .ksc-theme-red { border-color: #F56565; }
#kids-science-cards .ksc-theme-red .ksc-card-header { background-color: #F56565; }
#kids-science-cards .ksc-theme-red .ksc-story-box { background-color: #FFF5F5; border-color: #FEB2B2; }
#kids-science-cards .ksc-theme-red .ksc-story-title { color: #9B2C2C; }
#kids-science-cards .ksc-theme-red .ksc-card-btn { background-color: #F56565; }

#kids-science-cards .ksc-theme-cyan { border-color: #38B2AC; }
#kids-science-cards .ksc-theme-cyan .ksc-card-header { background-color: #38B2AC; }
#kids-science-cards .ksc-theme-cyan .ksc-story-box { background-color: #E6FFFA; border-color: #81E6D9; }
#kids-science-cards .ksc-theme-cyan .ksc-story-title { color: #234E52; }
#kids-science-cards .ksc-theme-cyan .ksc-card-btn { background-color: #38B2AC; }

#kids-science-cards .ksc-theme-pink { border-color: #ED64A6; }
#kids-science-cards .ksc-theme-pink .ksc-card-header { background-color: #ED64A6; }
#kids-science-cards .ksc-theme-pink .ksc-story-box { background-color: #FFF5F7; border-color: #FBB6CE; }
#kids-science-cards .ksc-theme-pink .ksc-story-title { color: #9B2C2C; }
#kids-science-cards .ksc-theme-pink .ksc-card-btn { background-color: #ED64A6; }

#kids-science-cards .ksc-theme-gold { border-color: #ECC94B; }
#kids-science-cards .ksc-theme-gold .ksc-card-header { background-color: #ECC94B; }
#kids-science-cards .ksc-theme-gold .ksc-story-box { background-color: #FFFFF0; border-color: #F6E05E; }
#kids-science-cards .ksc-theme-gold .ksc-story-title { color: #744210; }
#kids-science-cards .ksc-theme-gold .ksc-card-btn { background-color: #ECC94B; color: #2D3748; }

#kids-science-cards .ksc-card-header {
    padding: 24px;
    text-align: center;
    color: white;
}

#kids-science-cards .ksc-card-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: bold;
    letter-spacing: 1px;
}

#kids-science-cards .ksc-card-header p {
    margin: 6px 0 0 0;
    font-size: 14px;
    opacity: 0.9;
}

#kids-science-cards .ksc-card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

#kids-science-cards .ksc-story-box {
    border-radius: 14px;
    padding: 16px;
    border: 2px dashed;
    margin-bottom: 20px;
}

#kids-science-cards .ksc-story-title {
    font-weight: bold;
    font-size: 16px;
    margin-bottom: 8px;
}

#kids-science-cards .ksc-story-text {
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    color: #4A5568;
}

#kids-science-cards .ksc-info-list {
    margin: 0 0 20px 0;
    padding: 0;
    list-style: none;
    flex-grow: 1;
}

#kids-science-cards .ksc-info-item {
    margin-bottom: 16px;
    font-size: 14px;
    line-height: 1.6;
}

#kids-science-cards .ksc-info-item strong {
    color: #2D3748;
    display: block;
    margin-bottom: 4px;
    font-size: 15px;
}

#kids-science-cards .ksc-info-item p {
    margin: 0;
    color: #64748B;
}

#kids-science-cards .ksc-card-tip {
    background-color: #FFF5F5;
    border-left: 4px solid #E53E3E;
    padding: 12px;
    border-radius: 0 10px 10px 0;
    font-size: 13px;
    color: #C53030;
    margin-top: auto;
}

#kids-science-cards .ksc-card-tip strong {
    display: block;
    margin-bottom: 2px;
}

#kids-science-cards .ksc-card-action {
    padding: 0 24px 24px 24px;
}

#kids-science-cards .ksc-card-btn {
    display: block;
    width: 100%;
    padding: 12px;
    text-align: center;
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: opacity 0.2s;
}

#kids-science-cards .ksc-card-btn:hover {
    opacity: 0.9;
}

@media (max-width: 768px) {
    #kids-science-cards .ksc-card-cell {
        flex: 0 0 100%;
        max-width: 100%;
        padding: 10px 0;
    }
    #kids-science-cards {
        padding: 20px 15px;
    }
    #kids-science-cards .ksc-main-header h2 {
        font-size: 24px;
    }
}

/* ==========================================================================
   Protocol Explainer Styles
   ========================================================================== */
#protocol-explainer {
    font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    line-height: 1.8;
    color: #333;
    padding: 20px;
}

#protocol-explainer .pe-container {
    max-width: 850px;
    margin: 40px auto;
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

#protocol-explainer h2.pe-title {
    color: #2c3e50;
    text-align: center;
    font-size: 28px;
    margin-bottom: 10px;
    border: none;
    padding-left: 0;
}

#protocol-explainer .pe-subtitle {
    text-align: center;
    color: #7f8c8d;
    font-size: 16px;
    margin-bottom: 40px;
}

#protocol-explainer h3.pe-section-title {
    color: #2980b9;
    border-left: 5px solid #2980b9;
    padding-left: 12px;
    font-size: 20px;
    margin-top: 35px;
    margin-bottom: 15px;
}

#protocol-explainer p {
    margin: 15px 0;
    text-align: justify;
}

#protocol-explainer .pe-card {
    background-color: #ebf5fb;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #3498db;
}

#protocol-explainer .pe-card-vpn {
    background-color: #fef9e7;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #f39c12;
}

#protocol-explainer .pe-card-title {
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    font-size: 18px;
}

#protocol-explainer .pe-keyword {
    background-color: #f1c40f;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: bold;
    color: #333;
}

#protocol-explainer ul {
    padding-left: 20px;
    margin-bottom: 15px;
}

#protocol-explainer li {
    margin-bottom: 10px;
}

#protocol-explainer table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 15px;
}

#protocol-explainer th, #protocol-explainer td {
    border: 1px solid #e0e0e0;
    padding: 12px;
    text-align: left;
}

#protocol-explainer th {
    background-color: #f8f9fa;
    color: #2c3e50;
    font-weight: bold;
}

#protocol-explainer tr:nth-child(even) {
    background-color: #fafafa;
}

#protocol-explainer .pe-summary {
    background-color: #e8f8f5;
    border-left: 4px solid #2ecc71;
    padding: 15px;
    border-radius: 8px;
    font-weight: bold;
    color: #16a085;
    text-align: center;
    margin-top: 30px;
}

/* Floating CTA Widget */
        .floating-cta {
            position: fixed;
            right: 20px;
            bottom: 100px;
            z-index: 9999;
            display: flex;
            align-items: center;
            background: linear-gradient(135deg, var(--brand-red, #e74c3c), var(--brand-yellow, #f39c12));
            border-radius: 50px;
            padding: 13px;
            color: #fff !important;
            text-decoration: none;
            box-shadow: 0 4px 15px rgba(0,0,0,0.5);
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            overflow: hidden;
            width: 50px;
            height: 50px;
            box-sizing: border-box;
            white-space: nowrap;
        }
        .floating-cta:hover {
            width: 380px;
            padding: 13px 25px;
        }
        .floating-cta .cta-icon {
            font-size: 20px;
            display: flex;
            justify-content: center;
            align-items: center;
            min-width: 24px;
            animation: breathe 2s infinite ease-in-out;
        }
        .floating-cta .cta-text {
            opacity: 0;
            transition: opacity 0.3s ease;
            margin-left: 12px;
            font-weight: bold;
            font-size: 14px;
        }
        .floating-cta:hover .cta-text {
            opacity: 1;
            transition-delay: 0.1s;
        }
        @keyframes breathe {
            0% { transform: scale(1); }
            50% { transform: scale(1.15); }
            100% { transform: scale(1); }
        }
        @media (max-width: 768px) {
            .floating-cta {
                bottom: 150px;
                right: 15px;
            }
        }
        
        
/* Bottom Banner CTA (Option 2) */
        .bottom-banner-cta {
            position: fixed;
            bottom: 0;
            left: 0;
            width: 100%;
            background: rgba(18, 18, 18, 0.95);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            z-index: 9998;
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 12px 20px;
            box-sizing: border-box;
            box-shadow: 0 -4px 20px rgba(0,0,0,0.6);
            transform: translateY(100%);
            animation: slideUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
            animation-delay: 0.5s;
        }
        @keyframes slideUp {
            to { transform: translateY(0); }
        }
        .bottom-banner-content {
            display: flex;
            justify-content: space-between;
            align-items: center;
            width: 100%;
            max-width: 1000px;
        }
        .bottom-banner-text {
            color: #fff;
            font-size: 16px;
            font-weight: 500;
        }
        .bottom-banner-text span {
            color: var(--brand-yellow);
            margin: 0 5px;
        }
        .bottom-banner-btn {
            background: linear-gradient(135deg, var(--brand-red), var(--brand-yellow));
            color: #fff !important;
            padding: 10px 24px;
            border-radius: 6px;
            text-decoration: none;
            font-weight: bold;
            font-size: 15px;
            transition: opacity 0.3s;
            white-space: nowrap;
        }
        .bottom-banner-btn:hover {
            opacity: 0.9;
        }
        @media (max-width: 768px) {
            .bottom-banner-content {
                flex-direction: column;
                text-align: center;
            }
            .bottom-banner-text {
                font-size: 13px;
                margin-bottom: 12px;
                line-height: 1.6;
            }
            .bottom-banner-btn {
                width: 100%;
                text-align: center;
                padding: 12px 0;
            }
        }
    

/* ==========================================================================
   新版 App 风格手机底部导航
   ========================================================================== */
.mobile-app-nav, .mobile-nav-popup {
    display: none;
}
@media (max-width: 768px) {
    /* 强行隐藏电脑版和悬浮CTA */
    .global-desktop-tabs { display: none !important; }
    .floating-cta { display: none !important; }
    
    .mobile-app-nav {
        display: block;
        position: fixed;
        bottom: 0; left: 0; width: 100%;
        background: rgba(20, 20, 20, 0.85);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        z-index: 9999;
        /* 适配刘海屏底边 */
        padding-bottom: env(safe-area-inset-bottom);
    }

    
    .mobile-nav-visible {
        display: flex;
        justify-content: space-around;
        align-items: center;
        height: 60px;
    }
    
    .mn-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        color: rgba(255,255,255,0.4);
        text-decoration: none;
        transition: all 0.2s ease;
        cursor: pointer;
    }
    .mn-item.active {
        color: #fff;
    }
    .mn-icon {
        font-size: 22px;
        margin-bottom: 2px;
        transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    }
    .mn-item.active .mn-icon {
        transform: scale(1.2) translateY(-2px);
        text-shadow: 0 0 10px rgba(255,255,255,0.5);
    }
    .mn-text {
        font-size: 10px;
        font-weight: 500;
    }
    
    /* 全屏弹窗样式 */
    .mobile-nav-popup {
        position: fixed;
        top: 0; left: 0; width: 100%; height: 100vh;
        background: rgba(0,0,0,0.7);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        z-index: 10000;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
        display: flex;
        align-items: flex-end; /* 从底部升起 */
    }
    .mobile-nav-popup.show {
        opacity: 1;
        pointer-events: auto;
    }
    
    .mn-popup-content {
        width: 100%;
        background: #1c1c1e; /* 苹果深色模式卡片色 */
        border-radius: 20px 20px 0 0;
        padding: 24px;
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        padding-bottom: calc(24px + env(safe-area-inset-bottom));
    }
    .mobile-nav-popup.show .mn-popup-content {
        transform: translateY(0);
    }
    
    .mn-popup-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
        color: #fff;
    }
    .mn-popup-header h3 {
        font-size: 18px;
        margin: 0;
    }
    .mn-close-btn {
        width: 32px; height: 32px;
        background: rgba(255,255,255,0.1);
        border-radius: 50%;
        display: flex; align-items: center; justify-content: center;
        font-size: 14px;
        cursor: pointer;
        color: #fff;
    }
    
    .mn-popup-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .mn-popup-item {
        padding: 16px;
        background: rgba(255,255,255,0.05);
        border-radius: 12px;
        color: rgba(255,255,255,0.8);
        text-decoration: none;
        font-size: 16px;
        font-weight: 600;
        display: flex;
        align-items: center;
        transition: all 0.2s;
    }
    
    /* 隐藏已经在外面底部栏显示过的菜单，防止重复 */
    .mn-popup-grid a[href="index.html"],
    .mn-popup-grid a[href="faq.html"],
    .mn-popup-grid a[href="science.html"] {
        display: none !important;
    }

    .mn-popup-item.active {
        background: rgba(255,255,255,0.15);
        color: #fff;
        border: 1px solid rgba(255,255,255,0.2);
        box-shadow: 0 4px 15px rgba(0, 195, 255, 0.2);
    }
}
