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

/* CSS变量定义 */
:root {
    --deep-blue: #000066;
    --purple-black: #660099;
    --silver-gray: #C0C0C0;
    --bright-orange: #FFA500;
    --fluorescent-green: #00FF00;
    --background-gradient: linear-gradient(135deg, #000066, #660099);
    --font-primary: 'Roboto', sans-serif;
    --font-secondary: 'Orbitron', sans-serif;
    --transition-speed: 0.3s;
    --nav-width: 250px;
}

/* 全局样式 */
body {
    font-family: var(--font-primary);
    background: var(--background-gradient);
    color: #fff;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 固定侧边导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--nav-width);
    height: 100%;
    background-color: rgba(26, 26, 26, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 20px;
    z-index: 1000;
}

.navbar a {
    color: #fff;
    text-decoration: none;
    margin: 15px 0;
    font-family: var(--font-secondary);
    font-size: 1.2em;
    transition: color var(--transition-speed), transform var(--transition-speed);
}

.navbar a:hover {
    color: var(--bright-orange);
    transform: scale(1.1);
}

/* 主内容区域 */
.main-content {
    margin-left: var(--nav-width);
    padding: 40px;
    background: rgba(0, 0, 0, 0.5);
    min-height: 100vh;
    overflow: hidden;
    position: relative;
}

/* 标题样式 */
.header {
    text-align: center;
    margin-bottom: 40px;
}

.header h1 {
    font-family: var(--font-secondary);
    font-size: 3em;
    background: var(--brightness-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: typing 4s steps(40, end), blink-caret .75s step-end infinite;
    white-space: nowrap;
    overflow: hidden;
    border-right: .15em solid var(--bright-orange);
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: var(--bright-orange); }
}

/* 文章内容样式 */
article {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
}

article h2, article h3 {
    font-family: var(--font-secondary);
    margin-bottom: 20px;
    color: var(--fluorescent-green);
}

article p {
    margin-bottom: 15px;
    font-size: 1em;
    line-height: 1.8;
}

article pre {
    background: rgba(0, 0, 0, 0.7);
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    margin-bottom: 15px;
}

article code {
    color: var(--bright-orange);
    font-family: 'Courier New', Courier, monospace;
}

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

article table, article th, article td {
    border: 1px solid var(--fluorescent-green);
}

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

article img {
    width: 100%;
    max-width: 320px;
    margin: 10px 0;
    border-radius: 5px;
}

/* 示例数据展示 */
.sample-data {
    margin-top: 50px;
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
}

.sample-data h2 {
    color: var(--bright-orange);
    margin-bottom: 20px;
}

.sample-data ul, .sample-data table {
    margin-bottom: 20px;
}

.sample-data li {
    margin-bottom: 10px;
    font-size: 1em;
}

.sample-data table th {
    background: var(--fluorescent-green);
    color: #000;
}

.sample-data table td {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

/* 动画与互动效果 */
.button {
    background-color: #007BFF;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background-color var(--transition-speed), transform var(--transition-speed);
    font-size: 1em;
}

.button:hover {
    background-color: #0056b3;
    transform: scale(1.1);
}

/* 视觉冲击力背景 */
.particle-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://images.gptkong.com/demo/sample1.png') repeat;
    opacity: 0.2;
    z-index: -1;
    animation: moveParticles 20s linear infinite;
}

@keyframes moveParticles {
    from { background-position: 0 0; }
    to { background-position: 1000px 1000px; }
}

/* 响应式设计 */
@media (max-width: 1440px) {
    .header h1 {
        font-size: 2.5em;
    }
}

@media (max-width: 1200px) {
    .navbar {
        width: 200px;
    }
    .main-content {
        margin-left: 200px;
        padding: 30px;
    }
}

@media (max-width: 1024px) {
    .header h1 {
        font-size: 2em;
    }
    article {
        padding: 15px;
    }
}

@media (max-width: 768px) {
    .navbar {
        width: 180px;
    }
    .main-content {
        margin-left: 180px;
        padding: 20px;
    }
    .header h1 {
        font-size: 1.8em;
    }
}

@media (max-width: 480px) {
    .navbar {
        width: 150px;
    }
    .main-content {
        margin-left: 150px;
        padding: 15px;
    }
    article h2 {
        font-size: 1.5em;
    }
}

@media (max-width: 320px) {
    .navbar {
        width: 120px;
    }
    .main-content {
        margin-left: 120px;
        padding: 10px;
    }
    .header h1 {
        font-size: 1.5em;
    }
    article p, .sample-data li {
        font-size: 0.9em;
    }
}

