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

body {
    background: linear-gradient(135deg, #6A0DAD, #1E90FF);
    color: #FFFFFF;
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* 动态粒子背景 */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    pointer-events: none;
    z-index: 0;
    background-image: radial-gradient(white 1px, transparent 1px);
    background-size: 20px 20px;
    animation: moveParticles 10s linear infinite;
    opacity: 0.1;
}

@keyframes moveParticles {
    from {
        transform: translate(0, 0);
    }
    to {
        transform: translate(-100px, -100px);
    }
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* 头部样式 */
header {
    text-align: center;
    padding: 50px 0;
}

header h1 {
    font-size: 3rem;
    font-weight: bold;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
    color: #FF8C00;
    transform: perspective(500px) rotateX(10deg);
}

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

nav a {
    color: #FFFFFF;
    text-decoration: none;
    font-size: 1.2rem;
    position: relative;
}

nav a::after {
    content: '';
    display: block;
    width: 0;
    height: 2px;
    background: #32CD32;
    transition: width 0.3s;
}

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

nav a[rel="nofollow"] {
    cursor: default;
}

/* 主要内容区域 */
main {
    display: flex;
    flex-direction: column;
    gap: 50px;
}

/* 示例展示 */
.article-section {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.article-section h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #FFD700;
}

.article-section h3 {
    font-size: 2rem;
    margin-top: 30px;
    color: #ADFF2F;
}

.article-section p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.article-section pre {
    background: #2F4F4F;
    padding: 15px;
    border-radius: 10px;
    overflow-x: auto;
}

.article-section code {
    color: #7FFFD4;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1rem;
}

.article-section::before {
    content: '示例展示';
    display: block;
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #FF69B4;
}

/* 项目展示 */
.projects-section {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.projects-section h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #FFD700;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.card {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.5s ease, box-shadow 0.5s ease;
    perspective: 1000px;
}

.card:hover {
    transform: rotateY(15deg);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.4);
}

.card img {
    width: 100%;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
}

.card-content {
    padding: 15px;
}

.card-content h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #00FA9A;
}

.card-content p {
    font-size: 1rem;
    margin-bottom: 10px;
}

.card-content ul {
    list-style: none;
}

.card-content li {
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.card-content a {
    color: #1E90FF;
    text-decoration: none;
}

.card-content a:hover {
    text-decoration: underline;
}

/* 代码块样式 */
pre {
    background: #2F4F4F;
    padding: 15px;
    border-radius: 10px;
    overflow-x: auto;
}

code {
    color: #7FFFD4;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1rem;
}

/* 视觉冲击力强的按钮 */
button {
    background-color: #1E90FF;
    color: white;
    border: none;
    padding: 15px 30px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    font-size: 1rem;
    border-radius: 5px;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #32CD32;
}

button::before {
    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%);
    animation: ripple 0.6s ease-out;
}

@keyframes ripple {
    from {
        width: 0;
        height: 0;
        opacity: 1;
    }
    to {
        width: 300px;
        height: 300px;
        opacity: 0;
    }
}

/* 页脚样式 */
footer {
    text-align: center;
    padding: 20px 0;
    font-size: 1rem;
    color: #FFFFFF;
    background: rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 1;
    border-top: 1px solid #FFFFFF;
}

/* 响应式设计 */
@media (max-width: 320px) {
    header h1 {
        font-size: 2rem;
    }

    nav a {
        font-size: 1rem;
    }

    .article-section h2 {
        font-size: 2rem;
    }

    .projects-section h2 {
        font-size: 2rem;
    }
}

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

    nav a {
        font-size: 1.1rem;
    }

    .article-section h2, .projects-section h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .grid-container {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .article-section, .projects-section {
        padding: 20px;
    }
}

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

    nav a {
        font-size: 1.2rem;
    }

    .article-section h2, .projects-section h2 {
        font-size: 2.5rem;
    }
}

@media (min-width: 1200px) {
    .container {
        padding: 40px;
    }

    .card-content h3 {
        font-size: 1.8rem;
    }

    .card-content p, .card-content li {
        font-size: 1.1rem;
    }
}

@media (min-width: 1440px) {
    header h1 {
        font-size: 3.5rem;
    }

    .card-content h3 {
        font-size: 2rem;
    }

    .card-content p, .card-content li {
        font-size: 1.2rem;
    }
}

