
/* 全局样式设定 */
body {
    margin: 0;
    padding: 0;
    font-family: 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: #ffffff;
    line-height: 1.6;
}

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: rgba(30, 60, 114, 0.9);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    z-index: 1000;
    transition: background-color 0.3s ease;
}

.navbar.scrolled {
    background-color: rgba(30, 60, 114, 1);
}

.navbar a {
    color: #ffffff;
    padding: 14px 20px;
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
    rel: nofollow;
}

.navbar a:hover {
    background-color: #2a5298;
    transform: scale(1.05);
}

/* 主要内容区域样式 */
.main-content {
    display: flex;
    flex-direction: column;
    padding: 100px 20px 20px 20px; /* 留出导航栏空间 */
    max-width: 1200px;
    margin: 0 auto;
}

/* 提示信息样式 */
.prominent-note {
    background-color: rgba(255, 126, 95, 0.8);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-size: 1.2em;
    margin-bottom: 20px;
}

/* 文章内容样式 */
article {
    background-color: rgba(240, 244, 248, 0.8);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    color: #333333;
}

article h2, article h3, article h4 {
    color: #1e3c72;
}

article code {
    background-color: #f0f4f8;
    padding: 2px 4px;
    border-radius: 4px;
    font-family: 'Courier New', Courier, monospace;
}

article pre {
    background-color: #f0f4f8;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 20px;
}

article pre code {
    color: #2a5298;
}

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

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

/* 代码示例区块样式 */
.code-example {
    background-color: #ffffff;
    color: #2a5298;
    padding: 20px;
    border-radius: 8px;
    font-family: 'Courier New', Courier, monospace;
    overflow-x: auto;
}

.code-example code {
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .navbar a {
        display: none;
    }
    
    .navbar .menu-icon {
        display: block;
        cursor: pointer;
    }
    
    .sidebar-nav {
        top: 60px;
    }

    .main-content {
        padding: 80px 10px 10px 10px;
    }
}

@media (max-width: 1200px) {
    .main-content {
        flex-direction: column;
    }
}

/* 按钮样式 */
.button {
    background: linear-gradient(45deg, #ff7e5f, #feb47b);
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    color: #ffffff;
    cursor: pointer;
    transition: background 0.3s ease;
}

.button:hover {
    background: linear-gradient(45deg, #feb47b, #ff7e5f);
}

/* 固定侧边导航样式 */
.sidebar-nav {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%) translateX(100%);
    background-color: #2a5298;
    padding: 10px;
    border-radius: 8px 0 0 8px;
    transition: transform 0.3s ease;
}

.sidebar-nav.open {
    transform: translateY(-50%) translateX(0);
}

.sidebar-toggle {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    background-color: #ff7e5f;
    border: none;
    border-radius: 4px 0 0 4px;
    padding: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.sidebar-toggle:hover {
    background-color: #feb47b;
}

/* 仪表盘样式 */
.dashboard {
    display: flex;
    justify-content: space-around;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.dashboard-item {
    text-align: center;
    animation: slideIn 1s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chart {
    width: 100px;
    height: 100px;
    background: conic-gradient(#4e73df 75%, #e74a3b 0%);
    border-radius: 50%;
    margin: 0 auto 10px;
    position: relative;
}

.chart::before {
    content: '75%';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #ffffff;
    font-weight: bold;
}

/* 推荐模块样式 */
.recommendation {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    padding: 20px;
    background-color: #f8f9fc;
}

.recommendation-item {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.recommendation-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.recommendation-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.recommendation-item .info {
    padding: 10px;
}

.recommendation-item .info h4 {
    margin: 0 0 10px;
    font-size: 1.2em;
    color: #2a5298;
}

.recommendation-item .info p {
    margin: 0;
    color: #555555;
}

