
/* 全局样式 */
body {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #4B0082, #6A5ACD, #FFD700);
    color: #2F4F4F;
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

header {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(90deg, #8B4513, #FFD700);
    color: white;
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    position: relative;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.1);
    z-index: -1;
}

.module {
    background: #EEDC82;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    overflow: hidden;
    position: relative;
}

.module:hover {
    transform: translateY(-10px);
}

.module img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 15px 15px 0 0;
}

.module-content {
    padding: 20px;
    text-align: center;
}

.module-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: #8B4513;
}

.module-text {
    font-size: 1rem;
    color: #2F4F4F;
}

pre {
    background: #2F4F4F;
    color: #FFD700;
    padding: 15px;
    border-radius: 10px;
    overflow-x: auto;
    font-size: 0.9rem;
}

code {
    font-family: 'Courier New', monospace;
    color: #FFD700;
}

.parallax {
    background-image: url('https://images.gptkong.com/demo/sample1.png');
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
    height: 300px;
    position: relative;
}

.parallax::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    header {
        font-size: 1.5rem;
        padding: 20px;
    }

    .container {
        grid-template-columns: 1fr;
    }

    pre {
        font-size: 0.8rem;
    }
}

/* 动画与交互 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.module {
    animation: fadeIn 1s ease-in-out;
}

.foreground {
    animation: move 2s infinite alternate;
}

@keyframes move {
    from { transform: translateY(0); }
    to { transform: translateY(-10px); }
}

