/* ================= 基础样式 ================= */
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { 
    font-family: "Microsoft YaHei", "PingFang SC", -apple-system, sans-serif; 
    color: #333; 
    background: #fff; 
    line-height: 1.6; 
    user-select: none; /* 禁止全站选中 */
    -webkit-user-select: none;
}
a { color: inherit; text-decoration: none; }
:root { --primary: #c8102e; --primary-dark: #9a0c23; --gold: #d5b064; --dark: #1a1a1a; }

/* ================= 顶部导航 ================= */
.site-header { position: fixed; top: 0; left: 0; width: 100%; height: 80px; background: rgba(255,255,255,0.96); backdrop-filter: blur(10px); z-index: 999; display: flex; align-items: center; padding: 0 60px; box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
.header-logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.header-logo-img { height: 50px; width: auto; display: block; pointer-events: none; /* 穿透鼠标 */ }
.main-nav { flex: 1; text-align: center; }
.main-nav ul { display: flex; gap: 36px; list-style: none; justify-content: center; }
.main-nav a {
    font-size: 15px;
    color: #333;
    position: relative;
    padding: 6px 0;
    white-space: nowrap;
    transition: color 0.28s ease;
}

.main-nav a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
    transform: translateX(-50%);
    transition: width 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.main-nav a:hover { color: var(--primary); }
.main-nav a:hover::after { width: 100%; }
.main-nav a.active { color: var(--primary); }
.main-nav a.active::after { width: 100%; }
.main-nav a:focus-visible { color: var(--primary); outline: none; }
.main-nav a:focus-visible::after { width: 100%; }

/* 汉堡按钮 */
.nav-toggle { display: none; width: 40px; height: 40px; border: none; background: transparent; cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; margin-left: auto; padding: 0; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: #333; border-radius: 2px; transition: transform 0.3s ease, opacity 0.3s ease; }
.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ================= Banner ================= */
.page-banner {
    margin-top: 80px;
    height: 200px;
    background: linear-gradient(135deg, #5a0818 0%, #8b0f24 50%, #c8102e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
}
.page-banner h1 { font-size: 34px; letter-spacing: 5px; margin-bottom: 8px; }
.page-banner p { font-size: 13px; color: var(--gold); letter-spacing: 3px; }

/* ================= 面包屑 ================= */
.breadcrumb { max-width: 1200px; margin: 0 auto; padding: 24px 20px; font-size: 14px; color: #888; }
.breadcrumb span { margin: 0 8px; color: #ccc; }

/* ================= 详情内容 ================= */
.detail-container { max-width: 1200px; margin: 0 auto; padding: 0 20px 60px; }
.article-header { border-bottom: 1px solid #eee; padding-bottom: 24px; margin-bottom: 40px; }
.article-tag { display: inline-block; background: var(--gold); color: #222; padding: 4px 12px; font-size: 13px; border-radius: 2px; margin-bottom: 16px; }
.article-title { font-size: 30px; font-weight: bold; color: #222; line-height: 1.4; margin-bottom: 16px; }
.article-meta { font-size: 14px; color: #999; }

/* 正文排版 */
.article-content { font-size: 16px; line-height: 2; color: #444; }
.article-content p { margin-bottom: 20px; text-indent: 2em; }
.article-content h3 { font-size: 20px; color: #222; margin: 30px 0 15px; padding-left: 12px; border-left: 4px solid var(--primary); }

/* 核心防下载：正文图片样式 */
.article-content img { 
    max-width: 100%; 
    height: auto; 
    display: block; 
    margin: 20px auto; 
    border-radius: 4px; 
    pointer-events: none; /* 鼠标直接穿透图片，无法触发右键菜单 */
    -webkit-user-drag: none; /* 禁止在 Safari/Chrome 中拖拽 */
}

/* ================= 上下篇导航 ================= */
.article-pager { margin-top: 50px; padding-top: 30px; border-top: 1px solid #eee; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.pager-card { padding: 16px 20px; border: 1px solid #eee; border-radius: 6px; transition: 0.2s; }
.pager-card:hover { border-color: var(--primary); }
.pager-card.next { text-align: right; }
.pager-label { font-size: 13px; color: #999; margin-bottom: 8px; }
.pager-title { font-size: 15px; color: #333; }

.back-btn { display: inline-block; margin-top: 30px; padding: 10px 28px; border: 1px solid var(--primary); color: var(--primary); border-radius: 30px; transition: 0.2s; }
.back-btn:hover { background: var(--primary); color: #fff; }

/* ================= 页脚 ================= */
footer { background: var(--dark); color: #999; padding: 60px 20px; text-align: center; border-top: 1px solid #2a2a2a; }
.footer-copy { font-size: 13px; color: #666; border-top: 1px solid #333; padding-top: 24px; margin-top: 24px; }

/* ================= 响应式 ================= */
@media (min-width: 1920px) {
    .site-header { padding: 0 120px; }
    .header-logo-img { height: 56px; }
}
@media (min-width: 1366px) and (max-width: 1919px) {
    .site-header { padding: 0 80px; }
}
@media (min-width: 1024px) and (max-width: 1365px) {
    .site-header { padding: 0 30px; }
    .main-nav ul { gap: 20px; }
    .main-nav a { font-size: 14px; }
}
@media (min-width: 768px) and (max-width: 1023px) {
    .site-header { padding: 0 20px; height: 70px; }
    .header-logo-img { height: 44px; }
    .main-nav ul { gap: 12px; }
    .main-nav a { font-size: 13px; }
    .page-banner { margin-top: 70px; height: 170px; }
    .page-banner h1 { font-size: 28px; letter-spacing: 4px; }
    .page-banner p { font-size: 12px; }
}
@media (max-width: 767px) {
    .site-header { padding: 0 16px; height: 64px; }
    .header-logo-img { height: 40px; }
    .nav-toggle { display: flex; }
    .main-nav {
        position: fixed; top: 64px; left: 0; width: 100%; background: #fff;
        box-shadow: 0 8px 24px rgba(0,0,0,0.1); transform: translateY(-120%);
        transition: transform 0.3s ease; z-index: 998; display: block; text-align: left;
    }
    .main-nav.open { transform: translateY(0); }
    .main-nav ul { flex-direction: column; gap: 0; padding: 8px 0; }
    .main-nav li { border-bottom: 1px solid #f0f0f0; }
    .main-nav a { display: block; padding: 14px 24px; font-size: 15px; }
    .main-nav a::after, .main-nav a.active::after, .main-nav a:hover::after { display: none; }

    .page-banner { margin-top: 64px; height: 130px; }
    .page-banner h1 { font-size: 21px; letter-spacing: 2px; }
    .page-banner p { font-size: 11px; letter-spacing: 1.5px; }

    .detail-container { padding: 0 16px 40px; }
    .article-title { font-size: 22px; }
    .article-pager { grid-template-columns: 1fr; }
}