
/* 重置浏览器默认样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 设置全局字体和背景色 */
body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #0D47A1 70%, #4CAF50 25%, #FFC107 5%);
    color: #333333;
    line-height: 1.6;
    overflow-x: hidden;
    padding-top: 70px; /* 为固定导航栏留出空间 */
}

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: rgba(13, 71, 161, 0.9);
    color: #ffffff;
    padding: 15px 50px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s;
}

.navbar:hover {
    background-color: rgba(13, 71, 161, 1);
}

.navbar a {
    color: #ffffff;
    text-decoration: none;
    margin: 0 15px;
    font-size: 16px;
    position: relative;
}

.navbar a::after {
    content: '';
    display: block;
    width: 0;
    height: 2px;
    background: #FFC107;
    transition: width .3s;
}

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

/* 主体部分样式 */
.container {
    width: 90%;
    max-width: 1200px;
    margin: auto;
    padding: 20px 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

/* 文章样式 */
article {
    background-color: rgba(255, 255, 255, 0.8);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    animation: fadeIn 2s ease-in-out;
}

article h2, article h3 {
    color: #0D47A1;
    margin-bottom: 20px;
}

article h2 {
    font-size: 24px;
}

article h3 {
    font-size: 20px;
    margin-top: 30px;
}

article p {
    font-size: 16px;
    margin-bottom: 20px;
}

/* 代码块样式 */
code {
    background-color: #f4f4f4;
    padding: 2px 4px;
    border-radius: 4px;
    font-family: 'Courier New', Courier, monospace;
    color: #d63384;
}

pre code {
    display: block;
    padding: 20px;
    background-color: #f8f9fa;
    border-left: 5px solid #0D47A1;
    overflow-x: auto;
    border-radius: 5px;
    font-size: 14px;
    line-height: 1.5;
}

/* 图片样式 */
img {
    width: 100%;
    max-width: 320px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

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

/* 图片容器 */
.image-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.image-grid img {
    flex: 1 1 calc(25% - 40px);
    max-width: calc(25% - 40px);
}

@media (max-width: 1200px) {
    .image-grid img {
        flex: 1 1 calc(33.333% - 40px);
        max-width: calc(33.333% - 40px);
    }
}

@media (max-width: 768px) {
    .image-grid img {
        flex: 1 1 calc(50% - 40px);
        max-width: calc(50% - 40px);
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 15px 20px;
    }

    .navbar a {
        margin: 0 5px;
        font-size: 14px;
    }

    .image-grid img {
        flex: 1 1 100%;
        max-width: 100%;
    }

    article {
        padding: 20px;
    }

    article h2 {
        font-size: 20px;
    }

    article h3 {
        font-size: 18px;
    }

    article p {
        font-size: 14px;
    }
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #FFC107;
    color: #0D47A1;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-size: 16px;
    transition: background-color 0.3s, transform 0.3s;
}

.button:hover {
    background-color: #FFA000;
    transform: translateY(-3px);
}

/* 跨度区块样式 */
.section-highlight {
    background: rgba(13, 71, 161, 0.1);
    padding: 20px;
    border-left: 5px solid #FFC107;
    margin: 30px 0;
    border-radius: 5px;
}

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

/* 折叠内容样式 */
.collapsible {
    background-color: #0D47A1;
    color: white;
    cursor: pointer;
    padding: 15px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 18px;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.collapsible:hover {
    background-color: #1565C0;
}

.content {
    padding: 0 15px;
    display: none;
    overflow: hidden;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 0 0 5px 5px;
}

.visible-content {
    display: block;
}

/* 强调文本样式 */
.highlight-text {
    color: #FFC107;
    font-weight: bold;
}

/* 引导区样式 */
.hero-section {
    background: url('https://images.gptkong.com/demo/sample4.png') no-repeat center center/cover;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.hero-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(13, 71, 161, 0.6);
    border-radius: 10px;
}

.hero-text {
    position: relative;
    color: #ffffff;
    font-size: 32px;
    text-align: center;
    z-index: 1;
    animation: fadeIn 2s ease-in-out;
}

/* 响应式文本 */
@media (max-width: 768px) {
    .hero-text {
        font-size: 24px;
    }
}


