/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft Yahei", Arial, sans-serif;
}

body {
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* 顶部背景区域 - 核心优化部分 */
.header-banner {
    position: relative;
    width: 100%;
    height: 350px; /* 降低高度，避免视觉过于夸张 */
    overflow: hidden; /* 裁剪超出部分 */
}

.banner-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover; 
    background-position: center center;
    background-repeat: no-repeat;
    filter: brightness(0.9);
    z-index: 1;
}

.site-title {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 2rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    z-index: 2;
    text-align: center;
    padding: 0 20px;
    width: 100%;
}

/* 导航栏样式 - 优化位置，紧贴banner */
.nav-container {
    background-color: #0080c5; /* 主蓝色 */
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    margin-top: -1px; /* 消除和banner之间的缝隙 */
}

.nav-list {
    display: flex;
    justify-content: center;
    list-style: none;
}

.nav-item {
    padding: 1rem 2rem;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s;
    font-size: 1.1rem;
}

.nav-item:hover, .nav-item.active {
    background-color: #0056b3; /* 深蓝色 hover/active 状态 */
}

/* 内容区域样式 */
.content-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.content-section {
    display: none; /* 默认隐藏 */
    background-color: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.content-section.active {
    display: block; /* 激活的板块显示 */
}

/* Markdown内容样式优化（适配富文本展示） */
.content-section h1, .content-section h2, .content-section h3 {
    color: #0080C5;
    margin: 1.5rem 0 1rem;
}

.content-section p {
    margin: 1rem 0;
    font-size: 1.05rem;
}

.content-section table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.content-section table th, .content-section table td {
    border: 1px solid #ddd;
    padding: 0.8rem;
    text-align: left;
}

.content-section table th {
    background-color: #f2f8ff;
    color: #0080c5;
}

.content-section a {
    color: #0080c5;
    text-decoration: none;
}

.content-section a:hover {
    text-decoration: underline;
}

.content-section img {
    max-width: 100%;
    height: auto;
    margin: 1rem 0;
    border-radius: 4px;
}

/* 页脚样式 */
.footer-container {
    background-color: #0080c5;
    color: white;
    text-align: center;
    padding: 1.5rem;
    margin-top: 2rem;
}

/* 响应式适配 */
@media (max-width: 768px) {
    .nav-list {
        flex-direction: column;
    }
    .nav-item {
        text-align: center;
        padding: 1rem;
    }
    .site-title {
        font-size: 1.5rem;
    }
    .header-banner {
        height: 250px; /* 移动端进一步降低高度 */
    }
}

/* 可选：如果需要背景图铺满且不变形，替换banner-bg的样式为这个 */
/* .banner-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover; 
    background-position: center center;
    background-repeat: no-repeat;
    filter: brightness(0.9);
    z-index: 1;
} */