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

/* 字体设置 */
body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #000033, #660099, #cc00ff);
    background-size: 200% 200%;
    animation: gradient-animation 15s ease infinite;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

/* 渐变动画 */
@keyframes gradient-animation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 标题字体 */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Orbitron', sans-serif;
    color: #ffffff;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

/* 容器布局 */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 0;
}

/* 模块化布局 */
.module {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
}

/* 标题样式 */
.module h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

/* 段落样式 */
.module p {
    font-size: 1em;
    margin-bottom: 15px;
    color: #cccccc;
}

/* 代码块样式 */
pre {
    background: rgba(0, 0, 0, 0.8);
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    margin-bottom: 20px;
}

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

/* 按钮样式 */
button {
    background: #000033;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    transition: background 0.3s ease, transform 0.3s ease;
}

button:hover {
    background: linear-gradient(45deg, #ff00ff, #00ffff);
    color: black;
    transform: scale(1.05);
}

/* 星星闪烁动画 */
@keyframes star-twinkle {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.star {
    position: absolute;
    width: 5px;
    height: 5px;
    background: white;
    border-radius: 50%;
    animation: star-twinkle 2s ease-in-out infinite;
}

/* 视差滚动 */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    height: 500px;
}

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

@media (max-width: 1200px) {
    .module {
        padding: 15px;
    }

    h1 {
        font-size: 2.5em;
    }
}

@media (max-width: 1024px) {
    .container {
        padding: 30px 0;
    }
}

@media (max-width: 768px) {
    .module {
        padding: 10px;
        max-width: 100%;
    }

    h1 {
        font-size: 32px;
    }

    button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 28px;
    }

    h2 {
        font-size: 1.5em;
    }
}

@media (max-width: 320px) {
    .module {
        padding: 5px;
    }

    h1 {
        font-size: 24px;
    }

    p {
        font-size: 0.9em;
    }
}

/* 动态星河背景 */
.star-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.star-container .star {
    top: calc(100% * var(--star-top));
    left: calc(100% * var(--star-left));
    width: calc(2px + var(--star-size));
    height: calc(2px + var(--star-size));
}

@keyframes aurora-move {
    0% { background: radial-gradient(circle, rgb(255, 87, 34), transparent); }
    50% { background: radial-gradient(circle, rgb(34, 193, 195), transparent); }
    100% { background: radial-gradient(circle, rgb(255, 87, 34), transparent); }
}

.aurora {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background: radial-gradient(circle, rgb(255, 87, 34), transparent);
    animation: aurora-move 15s linear infinite;
    opacity: 0.6;
}

/* 提示信息样式 */
.reference-note {
    text-align: center;
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #ffd700;
    animation: fade-in 2s ease-in-out;
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* 图文并茂样式 */
.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.image-grid img {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

/* 卡片式设计 */
.card {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 20px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.card:hover {
    transform: scale(1.05);
    border-color: #00ffff;
}

/* 社区分享区域 */
.community-share {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.community-share .card {
    flex: 1 1 calc(33.333% - 30px);
}

@media (max-width: 768px) {
    .community-share .card {
        flex: 1 1 calc(50% - 30px);
    }
}

@media (max-width: 480px) {
    .community-share .card {
        flex: 1 1 100%;
    }
}

