/**
 * 项目名称：梯子游戏技巧攻略
 * 文件功能：全站统一样式表
 * 版本：1.0
 */

/* ==================== 基础变量 ==================== */
:root {
    --bg-primary: #07111f;
    --bg-secondary: #0d1b2e;
    --bg-card: rgba(13, 27, 46, 0.65);
    --bg-card-hover: rgba(20, 40, 68, 0.8);
    --color-blue: #008cff;
    --color-cyan: #00d9ff;
    --text-primary: #e0e8f5;
    --text-secondary: #8ba3c4;
    --text-muted: #5a7090;
    --border-glow: rgba(0, 140, 255, 0.15);
    --border-hover: rgba(0, 217, 255, 0.35);
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 20px rgba(0, 140, 255, 0.1);
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition: all 0.3s ease;
    --max-width: 1200px;
}

/* ==================== 粒子背景画布 ==================== */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* ==================== 重置 ==================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* 科技背景纹理 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(0, 140, 255, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(0, 217, 255, 0.04) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* 隐藏导航滚动条箭头 */
.main-nav {
    scrollbar-width: none;  /* Firefox */
    -ms-overflow-style: none;  /* IE/Edge */
}
.main-nav::-webkit-scrollbar {
    display: none;  /* Chrome/Safari */
}

a {
    color: var(--color-cyan);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--color-blue);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ==================== 容器 ==================== */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* ==================== Header ==================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: rgba(7, 17, 31, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-glow);
    z-index: 1000;
    transition: var(--transition);
}

.header-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.logo-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.logo-img {
    height: 36px;
    width: auto;
}

.logo-text {
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 1px;
}

.main-nav {
    flex: 1;
    overflow: hidden;
    -webkit-overflow-scrolling: touch;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 5px;
    justify-content: center;
    white-space: nowrap;
}

.nav-list li a {
    display: block;
    padding: 8px 16px;
    color: var(--text-secondary);
    font-size: 14px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    position: relative;
}

.nav-list li a:hover,
.nav-list li a.active {
    color: var(--color-cyan);
    background: rgba(0, 140, 255, 0.08);
}

.nav-list li a.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--color-cyan);
    border-radius: 2px;
}

.header-placeholder {
    height: 60px;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-btn span {
    width: 22px;
    height: 2px;
    background: var(--color-cyan);
    border-radius: 2px;
    transition: var(--transition);
}

/* ==================== Banner ==================== */
.banner {
    position: relative;
    width: 100%;
    height: 420px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.banner-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(7, 17, 31, 0.85) 0%, rgba(7, 17, 31, 0.6) 100%);
    z-index: 1;
}

.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 0 20px;
}

.banner-title {
    font-size: 42px;
    font-weight: 700;
    background: linear-gradient(135deg, #fff, var(--color-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
    letter-spacing: 2px;
}

.banner-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 28px;
    letter-spacing: 1px;
}

.banner-btn {
    display: inline-block;
    padding: 12px 36px;
    background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
    color: #fff;
    font-size: 15px;
    border-radius: var(--radius-md);
    transition: var(--transition);
    box-shadow: 0 4px 20px rgba(0, 140, 255, 0.3);
}

.banner-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(0, 140, 255, 0.5);
    color: #fff;
}

/* ==================== 玻璃卡片通用样式 ==================== */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-glow);
    border-radius: var(--radius-md);
    padding: 24px;
    transition: var(--transition);
    box-shadow: var(--shadow-card);
}

.glass-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
    box-shadow: var(--shadow-glow), var(--shadow-card);
    transform: translateY(-2px);
}

/* ==================== Section通用 ==================== */
.section {
    padding: 50px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-title {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, var(--color-blue), var(--color-cyan));
    border-radius: 3px;
}

.section-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 15px;
}

/* ==================== 热门关键词模块 ==================== */
.keywords-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.keyword-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
}

.keyword-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, rgba(0, 140, 255, 0.15), rgba(0, 217, 255, 0.1));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--color-cyan);
    flex-shrink: 0;
}

.keyword-info h3 {
    font-size: 16px;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.keyword-info p {
    font-size: 12px;
    color: var(--text-muted);
}

/* ==================== 文章列表 ==================== */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.article-card {
    overflow: hidden;
    padding: 0;
}

.article-card-thumb {
    width: 100%;
    height: 160px;
    overflow: hidden;
    position: relative;
}

.article-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.article-card:hover .article-card-thumb img {
    transform: scale(1.05);
}

.article-card-body {
    padding: 20px;
}

.article-card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-card-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
}

.article-card-btn {
    color: var(--color-cyan);
    font-size: 13px;
    transition: var(--transition);
}

.article-card-btn:hover {
    color: var(--color-blue);
}

/* ==================== 网站介绍模块 ==================== */
.intro-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
}

.intro-card {
    text-align: center;
    padding: 32px 24px;
}

.intro-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0, 140, 255, 0.12), rgba(0, 217, 255, 0.08));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--color-cyan);
    border: 1px solid var(--border-glow);
}

.intro-card h3 {
    font-size: 17px;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.intro-card p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ==================== Footer ==================== */
.site-footer {
    position: relative;
    background: linear-gradient(180deg, rgba(7, 17, 31, 0.95) 0%, rgba(3, 8, 18, 0.98) 100%);
    border-top: 1px solid rgba(0, 140, 255, 0.12);
    padding: 0;
    margin-top: 60px;
    overflow: hidden;
}

/* 顶部光效分割线 */
.footer-glow-line {
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, rgba(0, 140, 255, 0.6) 30%, rgba(0, 217, 255, 0.8) 50%, rgba(0, 140, 255, 0.6) 70%, transparent 100%);
    box-shadow: 0 0 12px rgba(0, 140, 255, 0.4);
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 48px 20px 32px;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 36px;
}

/* === 第一栏：品牌区 === */
.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo-img {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    filter: drop-shadow(0 0 6px rgba(0, 140, 255, 0.4));
}

.footer-logo-text {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 1px;
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.footer-logo-sub {
    font-size: 12px;
    font-weight: 400;
    color: rgba(0, 217, 255, 0.7);
    letter-spacing: 2px;
}

.footer-desc {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.9;
}

/* 社交图标 */
.footer-social {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}

.social-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.4);
    background: rgba(0, 140, 255, 0.06);
    border: 1px solid rgba(0, 140, 255, 0.12);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-icon:hover {
    color: #fff;
    background: rgba(0, 140, 255, 0.2);
    border-color: rgba(0, 217, 255, 0.5);
    box-shadow: 0 0 12px rgba(0, 140, 255, 0.3);
    transform: translateY(-2px);
}

/* === 通用栏目标题 === */
.footer-title {
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 18px;
    position: relative;
    padding-left: 14px;
    letter-spacing: 1px;
}

.footer-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 3px;
    bottom: 3px;
    width: 3px;
    border-radius: 2px;
    background: linear-gradient(180deg, var(--color-blue), var(--color-cyan));
}

/* === 链接列表 === */
.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links li a {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.42);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.link-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(0, 140, 255, 0.3);
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.footer-links li a:hover {
    color: var(--color-cyan);
}

.footer-links li a:hover .link-dot {
    background: var(--color-cyan);
    box-shadow: 0 0 6px rgba(0, 217, 255, 0.6);
}

/* === 联系信息 === */
.footer-contact {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(0, 140, 255, 0.08);
}

.footer-contact-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-contact-value {
    font-size: 14px;
    color: rgba(0, 217, 255, 0.7);
    font-weight: 500;
}

/* === 底部版权栏 === */
.footer-bottom {
    background: rgba(0, 0, 0, 0.3);
    border-top: 1px solid rgba(0, 140, 255, 0.06);
}

.footer-bottom-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 18px 20px;
    text-align: center;
}

.footer-copyright {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.footer-icp {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.22);
    margin-bottom: 2px;
}

/* === 回到顶部按钮 === */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(0, 140, 255, 0.3);
    background: rgba(7, 17, 31, 0.85);
    backdrop-filter: blur(8px);
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    color: #fff;
    border-color: var(--color-cyan);
    background: rgba(0, 140, 255, 0.2);
    box-shadow: 0 0 16px rgba(0, 140, 255, 0.4);
}

/* ==================== 动画 ==================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(0, 140, 255, 0.1);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 140, 255, 0.25);
    }
}

/* ==================== 移动端适配（基础） ==================== */
@media (max-width: 768px) {
    .header-inner {
        gap: 10px;
    }

    .logo-text {
        font-size: 16px;
    }

    .main-nav {
        display: none;
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        background: rgba(7, 17, 31, 0.98);
        backdrop-filter: blur(12px);
        padding: 10px 0;
        border-bottom: 1px solid var(--border-glow);
    }

    .main-nav.open {
        display: block;
    }

    .nav-list {
        flex-direction: column;
        gap: 0;
    }

    .nav-list li a {
        display: block;
        padding: 12px 20px;
        border-radius: 0;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .banner {
        height: 280px;
    }

    .banner-title {
        font-size: 28px;
    }

    .banner-subtitle {
        font-size: 14px;
    }

    .section {
        padding: 30px 0;
    }

    .section-title {
        font-size: 22px;
    }

    .keywords-grid {
        grid-template-columns: 1fr;
    }

    .article-grid {
        grid-template-columns: 1fr;
    }

    .intro-grid {
        grid-template-columns: 1fr;
    }

    .footer-inner {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
        padding: 32px 16px 20px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .back-to-top {
        right: 16px;
        bottom: 16px;
        width: 40px;
        height: 40px;
    }

    /* 文章/栏目页响应式 */
    .category-title {
        font-size: 24px;
    }

    .article-detail-title {
        font-size: 22px;
    }

    .article-detail-body {
        font-size: 15px;
    }

    .article-detail-body h2 {
        font-size: 18px;
    }

    .article-nav {
        flex-direction: column;
    }

    .related-list {
        grid-template-columns: 1fr;
    }

    .article-detail {
        padding: 16px 0 40px;
    }
}

@media (max-width: 480px) {
    .footer-inner {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-brand {
        grid-column: auto;
    }

    /* 文章/栏目页响应式 */
    .category-title {
        font-size: 20px;
    }

    .article-detail-title {
        font-size: 18px;
    }

    .article-detail-body {
        font-size: 14px;
        line-height: 1.8;
    }
}

/* ==================== 面包屑导航 ==================== */
.breadcrumb {
    padding: 16px 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.breadcrumb a {
    color: var(--accent-blue);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--accent-cyan);
}

.breadcrumb span {
    color: rgba(255, 255, 255, 0.3);
}

/* ==================== 栏目页样式 ==================== */
.category-header {
    text-align: center;
    padding: 40px 0 32px;
}

.category-title {
    font-size: 32px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 12px;
    letter-spacing: 2px;
}

.category-desc {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.5);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ==================== 文章详情页样式 ==================== */
.article-detail {
    max-width: 860px;
    margin: 0 auto;
    padding: 24px 0 60px;
}

.article-detail-header {
    text-align: center;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(0, 140, 255, 0.15);
    margin-bottom: 32px;
}

.article-detail-title {
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    line-height: 1.5;
    margin-bottom: 16px;
    letter-spacing: 1px;
}

.article-detail-meta {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.4);
}

.article-detail-meta a {
    color: var(--accent-blue);
    text-decoration: none;
}

.article-detail-meta a:hover {
    color: var(--accent-cyan);
}

.article-detail-body {
    font-size: 16px;
    line-height: 1.9;
    color: rgba(255, 255, 255, 0.82);
}

.article-detail-body h2 {
    font-size: 22px;
    font-weight: 600;
    color: #fff;
    margin: 36px 0 16px;
    padding-left: 14px;
    border-left: 3px solid var(--accent-blue);
    letter-spacing: 1px;
}

.article-detail-body p {
    margin-bottom: 18px;
}

.article-detail-body strong {
    color: var(--accent-cyan);
    font-weight: 600;
}

/* ==================== 上下篇导航 ==================== */
.article-nav {
    display: flex;
    gap: 16px;
    margin: 40px 0;
}

.article-nav-item {
    flex: 1;
    padding: 20px 24px;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: block;
}

.article-nav-item:hover {
    border-color: var(--accent-blue);
    transform: translateY(-2px);
}

.article-nav-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 6px;
}

.article-nav-title {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
}

/* ==================== 相关文章推荐 ==================== */
.related-articles {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid rgba(0, 140, 255, 0.15);
}

.related-title {
    font-size: 20px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 20px;
    letter-spacing: 1px;
}

.related-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.related-item {
    padding: 18px 20px;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: block;
}

.related-item:hover {
    border-color: var(--accent-blue);
    transform: translateY(-2px);
}

.related-item h4 {
    font-size: 15px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 8px;
    line-height: 1.5;
}

.related-item span {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.4);
}

/* ==================== 文章/栏目页响应式补充（合并到基础响应式） ==================== */
/* 已合并到上方 @media 基础响应式中，避免重复定义 */
