
/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', 'Open Sans', sans-serif;
    background: linear-gradient(135deg, #1a237e, #424242);
    color: #ffffff;
    line-height: 1.6;
    padding: 20px;
}

/* 渐变背景与动画 */
.header {
    background: radial-gradient(circle, #004c99, transparent);
    padding: 40px 20px;
    text-align: center;
    position: relative;
    animation: aurora-move 15s linear infinite;
}

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

/* 标题样式 */
.header h1 {
    font-size: 2.5em;
    color: #ff9800;
    margin-bottom: 10px;
}

.header p {
    font-size: 1.2em;
    color: #ffffff;
}

/* 导航栏 */
.navbar {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 20px 0;
}

.navbar a {
    color: #ffffff;
    text-decoration: none;
    font-size: 1em;
    position: relative;
    transition: color 0.3s ease;
}

.navbar a::after {
    content: '';
    display: block;
    width: 0;
    height: 2px;
    background: #ff9800;
    transition: width 0.3s;
    position: absolute;
    bottom: -5px;
    left: 0;
}

.navbar a:hover::after {
    width: 100%;
}

.navbar a:hover {
    color: #ff9800;
}

/* 主要内容区 */
.main {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

/* 轮播图 */
.carousel {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
    border-radius: 10px;
}

.carousel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: slide 20s infinite;
}

@keyframes slide {
    0% { transform: translateX(0); }
    25% { transform: translateX(-100%); }
    50% { transform: translateX(-200%); }
    75% { transform: translateX(-300%); }
    100% { transform: translateX(0); }
}

/* 模块化布局 */
.section {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.section h2 {
    color: #ff9800;
    margin-bottom: 15px;
    font-size: 1.8em;
}

.section p {
    font-size: 1em;
    color: #e0e0e0;
}

/* 图文并茂 */
.content-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.content-grid img {
    width: 100%;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.content-grid img:hover {
    transform: scale(1.05);
}

.content-grid .text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 示例展示 */
.example-article {
    background: rgba(0, 76, 153, 0.8);
    padding: 20px;
    border-radius: 10px;
    color: #ffffff;
}

.example-article h2 {
    font-size: 2em;
    margin-bottom: 10px;
    color: #ff9800;
}

.example-article h3 {
    font-size: 1.5em;
    margin-top: 20px;
    color: #ff9800;
}

.example-article p {
    margin: 10px 0;
    font-size: 1em;
    color: #dddddd;
}

.example-article pre {
    background: #263238;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 10px 0;
}

.example-article code {
    color: #ff9800;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.95em;
}

.example-article table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.example-article th, .example-article td {
    border: 1px solid #ff9800;
    padding: 8px;
    text-align: left;
    color: #ffffff;
}

.example-article th {
    background: #004c99;
}

.example-article li {
    margin-bottom: 10px;
}

/* 提示信息 */
.reference-note {
    text-align: center;
    font-size: 1em;
    color: #ff9800;
    margin: 30px 0;
}

/* 代码展示样式 */
.code-preview {
    background: #1c313a;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 20px 0;
}

.code-preview code {
    color: #00e676;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9em;
}

/* 响应式设计 */
@media (min-width: 480px) {
    .content-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .navbar {
        gap: 50px;
    }

    .header h1 {
        font-size: 3em;
    }
}

@media (min-width: 1024px) {
    .main {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .section {
        flex: 1 1 45%;
        margin: 10px;
    }

    .carousel {
        height: 400px;
    }
}

@media (min-width: 1200px) {
    body {
        padding: 40px;
    }

    .header h1 {
        font-size: 3.5em;
    }

    .section {
        padding: 30px;
    }

    .example-article h2 {
        font-size: 2.5em;
    }

    .example-article h3 {
        font-size: 1.8em;
    }
}

@media (min-width: 1440px) {
    .carousel {
        height: 500px;
    }

    .navbar a {
        font-size: 1.2em;
    }
}

/* 其他视觉元素 */
.button {
    display: inline-block;
    padding: 12px 25px;
    background: #ff9800;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s ease, transform 0.3s ease;
}

.button:hover {
    background: #e68900;
    transform: scale(1.05);
}

.icon {
    width: 24px;
    height: 24px;
    fill: currentColor;
    transition: transform 0.2s ease;
}

.icon:hover {
    transform: translateY(-2px);
}

footer {
    text-align: center;
    padding: 20px;
    background: rgba(0, 76, 153, 0.9);
    border-radius: 10px;
    margin-top: 40px;
    color: #ffffff;
}

/* 图片样式 */
.image-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.image-gallery img {
    width: 100%;
    max-width: 320px;
    border-radius: 8px;
    object-fit: cover;
}

/* 数据可视化样式 */
.chart {
    width: 100%;
    height: 300px;
    background: #263238;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ff9800;
    font-size: 1.5em;
}

