
/* 
整体页面样式设计
采用HTML5和CSS3技术，结合响应式设计原则，确保页面在不同设备上均有良好展示效果。
主要色彩采用深蓝色与银灰色，辅以橙色与绿色作为点缀色，营造科技感与专业性。
*/

/* 全局样式 */
body {
    margin: 0;
    padding: 0;
    font-family: 'Open Sans', sans-serif; /* 正文字体，提升可读性 */
    background: linear-gradient(135deg, #0f2027, #203a43, #2c5364); /* 蓝紫渐变背景，增强现代感 */
    color: #fff; /* 文字颜色为白色，确保与深色背景对比度 */
}

/* 固定导航栏 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: rgba(44, 83, 100, 0.9); /* 半透明背景 */
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* 导航链接样式 */
.navbar a {
    color: #ffa500; /* 橙色用于强调导航链接 */
    text-decoration: none;
    margin: 0 15px;
    font-size: 16px;
    transition: color 0.3s ease;
}

.navbar a:hover {
    color: #2c5364; /* 悬停时颜色变化 */
}

/* 主容器 */
.container {
    max-width: 1200px;
    margin: 120px auto 0 auto; /* 顶部留出导航栏空间 */
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
}

/* 侧边栏样式 */
.sidebar {
    background-color: rgba(32, 58, 67, 0.8); /* 深色背景 */
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* 侧边导航链接 */
.sidebar a {
    display: block;
    color: #ffa500;
    text-decoration: none;
    margin: 10px 0;
    font-size: 16px;
    transition: color 0.3s ease;
}

.sidebar a:hover {
    color: #2c5364;
}

/* 内容区域样式 */
.content {
    background-color: rgba(44, 83, 100, 0.8); /* 深蓝色背景 */
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* 章节标题样式 */
.content h2, .content h3, .content h4 {
    color: #ffa500; /* 橙色用于标题，增强视觉层次 */
    font-family: 'Roboto', sans-serif; /* 标题字体，突出科技感 */
}

.content h2 {
    font-size: 24px;
    margin-bottom: 10px;
}

.content h3 {
    font-size: 20px;
    margin-bottom: 8px;
}

.content h4 {
    font-size: 18px;
    margin-bottom: 6px;
}

/* 段落样式 */
.content p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
}

/* 代码块样式 */
.content pre {
    background-color: #203a43;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 20px;
}

.content code {
    color: #ffd700;
    font-family: 'Courier New', Courier, monospace;
}

/* 按钮样式 */
.button {
    background-color: #2c5364;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: transform 0.3s, background-color 0.3s;
    font-size: 16px;
}

.button:hover {
    background-color: #ffa500;
    transform: scale(1.05);
}

/* 图片样式 */
img.decorative {
    width: 100%;
    max-width: 320px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s;
    margin: 20px 0;
}

img.decorative:hover {
    transform: scale(1.05);
}

/* 卡片式布局 */
.cards {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.card {
    background-color: #203a43;
    padding: 20px;
    border-radius: 8px;
    flex: 1 1 calc(33% - 40px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-10px);
}

/* 数据可视化样式 */
.data-point {
    width: 10px;
    height: 10px;
    background-color: #ffa500;
    border-radius: 50%;
    opacity: 0;
    animation: fadeIn 1s forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.data-point:nth-child(1) { animation-delay: 0.2s; }
.data-point:nth-child(2) { animation-delay: 0.4s; }
.data-point:nth-child(3) { animation-delay: 0.6s; }

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        grid-template-columns: 1fr;
    }
    
    .card {
        flex: 1 1 100%;
    }
    
    .navbar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .navbar a {
        margin: 5px 0;
    }
}

