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

/* 定义根变量以便统一管理颜色 */
:root {
    --primary-color: #1A237E; /* 深蓝色作为主色调 */
    --secondary-color: #424242; /* 灰色作为辅色 */
    --accent-color: #FF9800; /* 橙色作为点缀色 */
    --background-color: #f5f5f5; /* 背景色 */
    --text-color: #333333; /* 正文字体颜色 */
    --font-family: 'Roboto', sans-serif; /* 全局字体 */
}

/* 页面主体样式 */
body {
    background-color: var(--background-color);
    color: var(--text-color);
    font-family: var(--font-family);
    line-height: 1.6;
    padding: 20px;
}

/* 容器设置，使用流式布局 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

/* 标题样式 */
h2, h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
}

h2 {
    font-size: 2em;
}

h3 {
    font-size: 1.5em;
}

/* 段落样式 */
p {
    font-size: 16px;
    margin-bottom: 20px;
}

/* 高亮文本 */
.accent {
    color: var(--accent-color);
}

/* 代码块样式 */
pre {
    background: #eeeeee;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

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

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: var(--primary-color);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    z-index: 1000;
}

.navbar a {
    color: white;
    margin: 0 15px;
    text-decoration: none;
    transition: color 0.3s;
}

.navbar a:hover {
    color: var(--accent-color);
}

/* 首屏样式 */
.hero {
    position: relative;
    height: 100vh;
    background: url('https://images.gptkong.com/demo/sample1.png') no-repeat center center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 3em;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.2em;
}

/* 图片样式 */
img.decorative {
    width: 320px;
    height: 320px;
    border-radius: 16px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: transform 0.3s, box-shadow 0.3s;
}

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

/* 分节布局 */
.section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 20px;
    padding: 60px 40px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.section:nth-child(even) {
    background: #fafafa;
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s, transform 0.3s;
}

.button:hover {
    background-color: darken(var(--accent-color), 10%);
    transform: scale(1.05);
}

/* 代码块特效 */
pre code {
    background: #f0f0f0;
    padding: 10px;
    border-radius: 4px;
    display: block;
    overflow-x: auto;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2em;
    }

    .section {
        grid-template-columns: 1fr;
        padding: 40px 20px;
    }

    img.decorative {
        width: 100%;
        height: auto;
    }
}

@media (max-width: 480px) {
    .navbar {
        flex-direction: column;
        align-items: center;
    }

    .navbar a {
        margin: 10px 0;
    }

    .hero-content h1 {
        font-size: 1.5em;
    }

    .button {
        padding: 8px 16px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    opacity: 0;
    animation: fadeIn 1s forwards;
}

/* 滚动行为 */
html {
    scroll-behavior: smooth;
}

/* 提示信息样式 */
.prompt-message {
    text-align: center;
    font-size: 1.2em;
    color: var(--accent-color);
    margin-bottom: 40px;
}

/* 折叠区域样式 */
.collapsible {
    background-color: #e0e0e0;
    color: #333;
    cursor: pointer;
    padding: 18px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 1em;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.collapsible:hover {
    background-color: #d5d5d5;
}

.content {
    padding: 0 18px;
    display: none;
    overflow: hidden;
    background-color: #f9f9f9;
    border-left: 4px solid var(--accent-color);
}

/* 图表与资讯区块 */
.data-chart, .news-ticker {
    padding: 40px;
    background-color: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-radius: 8px;
    animation: fadeIn 1s forwards;
}

/* 切换效果 */
.section-content {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 1s forwards;
    animation-delay: 0.5s;
}

/* 增加层次感 */
.section-title {
    margin-bottom: 20px;
    font-size: 2em;
    color: var(--primary-color);
}

/* 图标样式 */
.icon {
    width: 24px;
    height: 24px;
    fill: var(--secondary-color);
    transition: fill 0.3s;
}

.icon:hover {
    fill: var(--accent-color);
}

