
/* 全局样式设置，包含响应式布局和基础样式 */
body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
    color: #2c3e50;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* 导航栏样式 */
.navbar {
    width: 100%;
    background-color: rgba(44, 62, 80, 0.9);
    display: flex;
    justify-content: space-around;
    padding: 20px 0;
    position: fixed;
    top: 0;
    z-index: 1000;
}

.navbar a {
    color: #ecf0f1;
    text-decoration: none;
    font-size: 18px;
    transition: color 0.3s;
}

.navbar a:hover {
    color: #1abc9c;
}

/* 主内容区，带有顶部间距以避免被固定导航栏遮挡 */
.main-content {
    max-width: 1200px;
    width: 90%;
    margin-top: 100px;
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 40px;
}

/* 侧边栏样式 */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.sidebar img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 12px rgba(0,0,0,0.4);
}

/* 文章内容样式 */
.article-content {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
    color: #ecf0f1;
}

.article-content h2, .article-content h3, .article-content h4 {
    color: #1abc9c;
}

.article-content pre {
    background: rgba(0, 0, 0, 0.6);
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
}

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

/* 提示文字样式 */
.reference-note {
    width: 100%;
    text-align: center;
    background-color: rgba(46, 204, 113, 0.8);
    color: #2c3e50;
    padding: 15px 0;
    font-size: 20px;
    position: fixed;
    bottom: 0;
    left: 0;
}

/* 响应式设计，适配不同屏幕 */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
    }
    
    .navbar a {
        font-size: 16px;
    }
    
    .article-content {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .navbar a {
        font-size: 14px;
    }
    
    .article-content {
        padding: 15px;
    }
}

