
/* 全局样式 */
body {
    margin: 0;
    padding: 0;
    font-family: 'Open Sans', sans-serif;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: #ffffff;
    line-height: 1.6;
}

a {
    color: #34C759;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.8);
    padding: 10px 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.navbar {
    display: flex;
    justify-content: center;
    align-items: center;
}

.navbar a {
    margin: 0 15px;
    font-size: 16px;
    font-weight: bold;
    transition: color 0.3s ease;
}

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

.main {
    padding-top: 80px;
}

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

.card {
    background-color: #1a1a1a;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.card:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.card-content {
    padding: 15px;
}

.card-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
}

.card-text {
    font-size: 14px;
    margin-bottom: 15px;
}

.card-interactive {
    color: #34C759;
    font-weight: bold;
}

.article-section {
    background-color: #1e1e1e;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.article-section h2 {
    font-size: 24px;
    margin-bottom: 20px;
    text-align: center;
}

.article-section h3 {
    font-size: 20px;
    margin-top: 20px;
    margin-bottom: 10px;
    color: #34C759;
}

.article-section pre {
    background-color: #2a2a2a;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    font-size: 14px;
    margin-bottom: 20px;
}

.article-section code {
    color: #34C759;
}

.footer {
    text-align: center;
    padding: 20px 0;
    background: rgba(0, 0, 0, 0.8);
    position: relative;
    bottom: 0;
    width: 100%;
}

@media (max-width: 1440px) {
    .card img {
        height: 140px;
    }
}

@media (max-width: 1200px) {
    .card img {
        height: 130px;
    }
}

@media (max-width: 1024px) {
    .navbar a {
        margin: 0 10px;
        font-size: 15px;
    }
}

@media (max-width: 768px) {
    .card img {
        height: 120px;
    }
    .article-section h2 {
        font-size: 22px;
    }
    .article-section h3 {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .navbar {
        flex-direction: column;
    }
    .navbar a {
        margin: 10px 0;
        font-size: 14px;
    }
    .card img {
        height: 100px;
    }
    .article-section h2 {
        font-size: 20px;
    }
    .article-section h3 {
        font-size: 16px;
    }
}

@media (max-width: 320px) {
    .card img {
        height: 90px;
    }
    .card-title {
        font-size: 16px;
    }
    .card-text {
        font-size: 12px;
    }
}

