
/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #0A192F, #6C5CE7);
    color: #FFFFFF;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
}

/* 背景波浪动画 */
@keyframes wave {
    0% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0); }
}

.wave-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,87,34,0.5), transparent);
    animation: wave 15s linear infinite;
    z-index: -1;
}

/* 磨砂玻璃效果 */
.frosted-glass {
    background: rgba(224, 224, 224, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.37);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

/* 导航栏 */
.navbar {
    width: 100%;
    padding: 15px 30px;
    background: rgba(224, 224, 224, 0.3);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    padding: 10px 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.navbar .logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #FFD700;
}

.navbar ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

.navbar ul li a {
    color: #FFFFFF;
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.navbar ul li a:hover {
    color: #FFD700;
}

/* 侧边栏菜单 */
.sidebar {
    position: fixed;
    top: 60px;
    right: -250px;
    width: 250px;
    height: 100%;
    background: rgba(224, 224, 224, 0.9);
    backdrop-filter: blur(10px);
    box-shadow: -2px 0 5px rgba(0,0,0,0.3);
    transition: right 0.3s ease;
    padding: 20px;
    z-index: 999;
}

.sidebar.active {
    right: 0;
}

.sidebar ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sidebar ul li a {
    color: #0A192F;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.sidebar ul li a:hover {
    color: #FFD700;
}

.toggle-button {
    position: fixed;
    top: 20px;
    right: 30px;
    background: none;
    border: none;
    color: #FFFFFF;
    font-size: 2rem;
    cursor: pointer;
    z-index: 1001;
}

/* 主内容区 */
.main-content {
    max-width: 1200px;
    width: 100%;
    margin-top: 100px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.article, .gallery {
    background: rgba(224, 224, 224, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.37);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.article h2, .article h3, .article h4 {
    color: #FFD700;
    margin-bottom: 10px;
}

.article pre {
    background: rgba(0, 0, 0, 0.7);
    padding: 15px;
    border-radius: 10px;
    overflow-x: auto;
    margin: 10px 0;
}

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

.article ul, .article ol {
    margin-left: 20px;
    margin-bottom: 10px;
}

.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

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

.button {
    position: relative;
    background-color: #FFD700;
    color: #0A192F;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    overflow: hidden;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300%;
    height: 300%;
    background: rgba(255, 215, 0, 0.5);
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    transition: all 0.3s ease;
}

.button:hover::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.button:hover {
    background-color: rgba(255, 215, 0, 0.8);
}

/* 响应式设计 */
@media (max-width: 1440px) {
    .main-content {
        max-width: 1000px;
    }
}

@media (max-width: 1200px) {
    .main-content {
        max-width: 900px;
    }
}

@media (max-width: 1024px) {
    .navbar ul {
        display: none;
    }
    .toggle-button {
        display: block;
    }
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .navbar .logo {
        font-size: 1.2rem;
    }
    .article pre {
        font-size: 0.8rem;
    }
}

@media (max-width: 320px) {
    .button {
        width: 100%;
        text-align: center;
    }
}

