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

body {
    font-family: 'Georgia', serif;
    background: linear-gradient(135deg, #8e9eab, #eef2f3);
    color: #333333;
    line-height: 1.6;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* 容器样式 */
.container {
    width: 100%;
    max-width: 1200px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    padding: 40px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

/* 头部样式 */
header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-family: 'Oswald', sans-serif;
    font-size: 3rem;
    color: #4b0082;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin-bottom: 10px;
}

header p {
    font-size: 1.2rem;
    color: #555555;
}

/* 导航栏样式 */
nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

nav a {
    text-decoration: none;
    color: #4b0082;
    font-weight: bold;
    position: relative;
}

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

nav a:hover::after {
    width: 100%;
}

/* 文章展示样式 */
.article {
    margin-bottom: 40px;
}

.article h2 {
    font-size: 2rem;
    color: #6a5acd;
    margin-bottom: 15px;
}

.article p {
    margin-bottom: 15px;
}

.article h3 {
    font-size: 1.5rem;
    color: #483d8b;
    margin-top: 20px;
    margin-bottom: 10px;
}

.article h4 {
    font-size: 1.2rem;
    color: #696969;
    margin-top: 15px;
    margin-bottom: 10px;
}

.article ul {
    list-style-type: disc;
    margin-left: 20px;
    margin-bottom: 15px;
}

.article pre {
    background: #f5f5f5;
    padding: 15px;
    border-radius: 10px;
    overflow-x: auto;
    margin-bottom: 15px;
}

.article code {
    font-family: 'Courier New', Courier, monospace;
    background: #e0e0e0;
    padding: 2px 4px;
    border-radius: 4px;
}

/* 图片样式 */
.images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
    justify-content: center;
}

.images img {
    width: 100%;
    max-width: 320px;
    border-radius: 10px;
    object-fit: cover;
}

/* 示例展示样式 */
.example-display {
    background: rgba(245, 245, 245, 0.9);
    padding: 20px;
    border-left: 5px solid #ff69b4;
    margin-bottom: 40px;
}

.example-display h2 {
    font-size: 1.8rem;
    color: #ff1493;
    margin-bottom: 10px;
}

.example-display p {
    font-size: 1rem;
    color: #333333;
}

/* 代码高亮样式 */
.code-block {
    background: #272822;
    color: #f8f8f2;
    padding: 20px;
    border-radius: 10px;
    overflow-x: auto;
    font-family: 'Courier New', Courier, monospace;
    margin-bottom: 20px;
}

.code-block code {
    display: block;
    white-space: pre;
}

/* 按钮样式 */
button {
    background: linear-gradient(135deg, #ff7e5f, #feb47b);
    border: none;
    padding: 10px 20px;
    color: #ffffff;
    font-size: 1rem;
    border-radius: 25px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

button:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

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

    header h1 {
        font-size: 2.5rem;
    }

    .article h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 1200px) {
    .container {
        padding: 25px;
    }

    header h1 {
        font-size: 2.2rem;
    }

    .article h2 {
        font-size: 1.6rem;
    }
}

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

    .images img {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    header h1 {
        font-size: 2rem;
    }

    nav {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    header h1 {
        font-size: 1.8rem;
    }

    .article h2 {
        font-size: 1.4rem;
    }

    button {
        width: 100%;
        padding: 12px;
    }
}

@media (max-width: 320px) {
    header h1 {
        font-size: 1.6rem;
    }

    .article h2 {
        font-size: 1.2rem;
    }

    .article p, .article li {
        font-size: 0.9rem;
    }
}

/* 动态粒子特效 */
.particle-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    animation: float 10s infinite ease-in-out;
}

@keyframes float {
    0% {
        transform: translateY(0) translateX(0);
        opacity: 1;
    }
    100% {
        transform: translateY(-1000px) translateX(1000px);
        opacity: 0;
    }
}

