
/* 全局样式与背景渐变 */
body {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #004FF9, #B621FE);
    color: white;
    overflow-x: hidden;
    min-height: 100vh;
}

/* 首屏沉浸式设计 */
.header {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.1));
    z-index: 1;
}

.header h1 {
    font-size: 48px;
    background: -webkit-linear-gradient(#004FF9, #B621FE);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
    z-index: 2;
    animation: float 5s infinite ease-in-out;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.navbar a {
    color: white;
    text-decoration: none;
    margin: 0 15px;
    font-size: 18px;
    position: relative;
    transition: all 0.3s ease;
}

.navbar a:hover {
    color: #FF1B6B;
}

.navbar a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: #FF1B6B;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.navbar a:hover::after {
    transform: scaleX(1);
}

/* 内容模块布局 */
.container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 20px;
}

.module {
    flex: 1 1 calc(33.33% - 20px);
    margin: 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    padding: 20px;
    transition: transform 0.3s ease;
}

.module:hover {
    transform: scale(1.05);
}

.module img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 10px;
}

/* 文章排版与代码高亮 */
article {
    background: rgba(0, 0, 0, 0.8);
    padding: 20px;
    border-radius: 10px;
    margin: 20px;
}

article h2, article h3 {
    color: #FF1B6B;
}

article p {
    line-height: 1.6;
    font-size: 16px;
}

pre {
    background: #1E1E1E;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
}

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

/* 动画效果与交互 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background: linear-gradient(135deg, #00FFA3, #FF1B6B);
    color: white;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.button:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.2);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .module {
        flex: 1 1 100%;
    }

    article h2 {
        font-size: 24px;
    }

    pre {
        font-size: 14px;
    }
}

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

    .navbar a {
        font-size: 16px;
    }
}

