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

/* 全局字体设置 */
body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #0A1F3D, #6C5CE7, #00FFC6);
    background-size: 400% 400%;
    animation: gradientAnimation 15s ease infinite;
    color: #FFFFFF;
    line-height: 1.6;
}

/* 渐变动画关键帧 */
@keyframes gradientAnimation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 容器样式 */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* 头部样式 */
header {
    text-align: center;
    padding: 50px 0;
    background: rgba(10, 31, 61, 0.8);
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

header h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 3em;
    margin-bottom: 20px;
    background: linear-gradient(90deg, #FFD700, #FFFFFF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    font-size: 1.5em;
    color: #FFD700;
}

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

nav a {
    text-decoration: none;
    color: #FFFFFF;
    font-size: 1.2em;
    position: relative;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #FFD700;
}

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

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

/* 主内容区样式 */
main {
    margin-top: 50px;
}

article {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    margin-bottom: 50px;
}

article h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.5em;
    margin-bottom: 20px;
    color: #FFD700;
}

article h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.8em;
    margin-top: 30px;
    color: #00FFC6;
}

article p {
    font-size: 1.2em;
    margin-bottom: 20px;
}

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

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

.article-image {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}

.article-image img {
    width: 100%;
    max-width: 320px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

/* 响应式设计 */
@media (max-width: 1440px) {
    header h1 {
        font-size: 2.5em;
    }

    header p {
        font-size: 1.2em;
    }

    nav a {
        font-size: 1em;
    }

    article h2 {
        font-size: 2em;
    }

    article h3 {
        font-size: 1.5em;
    }

    article p, article code {
        font-size: 1em;
    }
}

@media (max-width: 1200px) {
    .container {
        width: 95%;
    }

    .article-image {
        justify-content: center;
    }
}

@media (max-width: 1024px) {
    header h1 {
        font-size: 2.2em;
    }

    article {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    nav {
        flex-direction: column;
        gap: 15px;
    }

    article h2 {
        font-size: 1.8em;
    }

    article h3 {
        font-size: 1.3em;
    }
}

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

    header p {
        font-size: 1em;
    }

    nav a {
        font-size: 0.9em;
    }

    article h2 {
        font-size: 1.5em;
    }

    article p, article code {
        font-size: 0.9em;
    }

    .article-image img {
        max-width: 100%;
    }
}

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

    navigation a {
        font-size: 0.8em;
    }

    article h2 {
        font-size: 1.2em;
    }

    article h3 {
        font-size: 1em;
    }

    article p, article code {
        font-size: 0.8em;
    }
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background: #FFD700;
    color: #0A1F3D;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1em;
    transition: transform 0.3s, background 0.3s;
    position: relative;
    overflow: hidden;
}

.button:hover {
    background: #FFFFFF;
    transform: scale(1.05);
}

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

.button:hover::after {
    width: 200px;
    height: 200px;
    opacity: 1;
}

/* 波纹扩散效果 */
.ripple-button {
    position: relative;
    overflow: hidden;
}

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

.ripple-button:hover::after {
    width: 200px;
    height: 200px;
    opacity: 1;
}

