
/* 基本重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 引入字体 */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&family=Orbitron:wght@500;700&display=swap');

/* 全局样式 */
body {
    font-family: 'Roboto', sans-serif;
    background: radial-gradient(circle at top right, #001f3f, #000814);
    color: #f0f0f0;
    line-height: 1.6;
    letter-spacing: 0.5px;
    overflow-x: hidden;
}

/* 导航栏样式 */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 220px;
    height: 100vh;
    background: linear-gradient(135deg, #0d1b2a, #415a77);
    padding-top: 20px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.5);
    z-index: 1000;
}

.sidebar h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5em;
    text-align: center;
    margin-bottom: 30px;
    color: #ff8c00;
}

.sidebar ul {
    list-style: none;
}

.sidebar ul li {
    margin: 20px 0;
}

.sidebar ul li a {
    text-decoration: none;
    color: #f0f0f0;
    font-size: 1.1em;
    display: block;
    padding: 10px 20px;
    border-radius: 5px;
    transition: background 0.3s, transform 0.3s;
}

.sidebar ul li a:hover {
    background: rgba(255,140,0,0.2);
    transform: translateX(5px);
}

/* 内容区域样式 */
.content {
    margin-left: 240px;
    padding: 40px;
    background: linear-gradient(135deg, rgba(0,31,63,0.9), rgba(0,8,20,0.9));
    min-height: 100vh;
    position: relative;
    animation: backgroundMove 15s linear infinite;
}

@keyframes backgroundMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.content h1, .content h2, .content h3, .content h4 {
    font-family: 'Orbitron', sans-serif;
    color: #ff8c00;
    margin-bottom: 20px;
}

.content p {
    margin-bottom: 20px;
    font-size: 1em;
}

.content pre {
    background: #1a1a1a;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    margin-bottom: 20px;
}

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

.content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.content table, .content th, .content td {
    border: 1px solid #555;
}

.content th, .content td {
    padding: 10px;
    text-align: left;
}

.content th {
    background: #333;
}

.content img {
    width: 100%;
    max-width: 320px;
    height: auto;
    margin: 10px 0;
    border-radius: 10px;
}

.content .示例展示 {
    background: rgba(255, 140, 0, 0.1);
    padding: 20px;
    border-left: 5px solid #ff8c00;
    margin-bottom: 40px;
}

.content .示例展示 h2 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

.content .示例展示 p {
    font-size: 1em;
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #ff8c00;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.3s, background 0.3s;
    text-decoration: none;
    font-size: 1em;
}

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

.button:active {
    transform: scale(0.95);
}

/* 卡片样式 */
.card {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 15px rgba(0,0,0,0.5);
}

/* 数据可视化样式 */
.chart {
    width: 100%;
    height: 300px;
    background: #222;
    border-radius: 10px;
    margin-bottom: 20px;
    position: relative;
}

.chart::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200px;
    height: 200px;
    margin-left: -100px;
    margin-top: -100px;
    border: 2px solid #ff8c00;
    border-radius: 50%;
    animation: rotate 10s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* 网络节点粒子效果 */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    pointer-events: none;
}

.particle {
    width: 5px;
    height: 5px;
    background: #fff;
    border-radius: 50%;
    position: absolute;
    animation: move 15s linear infinite;
}

@keyframes move {
    0% { transform: translate(0, 0); opacity: 1; }
    100% { transform: translate(100px, 100px); opacity: 0; }
}

/* 响应式设计 */
@media (max-width: 1440px) {
    .content {
        padding: 30px;
    }
}

@media (max-width: 1200px) {
    .content {
        padding: 20px;
    }
}

@media (max-width: 1024px) {
    .sidebar {
        width: 180px;
    }
    .content {
        margin-left: 200px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 150px;
    }
    .content {
        margin-left: 170px;
        padding: 15px;
    }
    .content h1, .content h2, .content h3, .content h4 {
        font-size: 1.2em;
    }
}

@media (max-width: 480px) {
    .sidebar {
        width: 120px;
    }
    .content {
        margin-left: 140px;
        padding: 10px;
    }
    .sidebar h1 {
        font-size: 1.2em;
    }
    .sidebar ul li a {
        font-size: 1em;
        padding: 8px 15px;
    }
}

@media (max-width: 320px) {
    .sidebar {
        display: none;
    }
    .content {
        margin-left: 0;
        padding: 10px;
    }
}


