* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --primary: #6a5acd;
    --secondary: #9370db;
    --accent: #ff6b6b;
    --dark: #2d2b55;
    --light: #f8f9fa;
    --gray: #6c757d;
    --border: #e0e0e0;
}

body {
    background-color: #f5f7ff;
    color: #333;
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 头部样式 */
header {
    background: linear-gradient(135deg, var(--dark), var(--primary));
    color: white;
    padding: 15px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.8rem;
    font-weight: bold;
}

.logo span {
    margin-right: 10px;
    font-size: 2rem;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 25px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 12px;
    border-radius: 5px;
    transition: all 0.3s;
}

nav ul li a:hover,
nav ul li a.active {
    background: rgba(255, 255, 255, 0.2);
}

.search-bar {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 30px;
    padding: 5px 15px;
    width: 300px;
}

.search-bar input {
    background: transparent;
    border: none;
    color: white;
    padding: 8px;
    width: 100%;
    outline: none;
}

.search-bar input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* 主内容区样式 */
.main-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    padding: 30px 0;
}

/* 页面样式 */
.page {
    display: none;
}

.page.active {
    display: block;
}

/* 首页样式 */
.hero {
    background: linear-gradient(rgba(45, 43, 85, 0.8), rgba(106, 90, 205, 0.8));
    color: white;
    text-align: center;
    padding: 80px 20px;
    border-radius: 10px;
    margin-bottom: 30px;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px;
}

.btn {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
}

.btn:hover {
    background: #ff5252;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
}

.section-title {
    font-size: 1.8rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--primary);
    display: flex;
    align-items: center;
}

.section-title span {
    margin-right: 10px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.news-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.card-img {
    height: 180px;
    background: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}
.card-img img{
    height: 180px;
    width: auto;
}

.card-content {
    padding: 20px;
}

.card-content h3 {
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    color: var(--gray);
    font-size: 0.9rem;
    margin-top: 15px;
}

/* 侧边栏样式 */
.sidebar {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    height: fit-content;
}

.sidebar-widget {
    margin-bottom: 30px;
}

.sidebar-widget h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border);
}

.category-list {
    list-style: none;
}

.category-list li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.category-list li:last-child {
    border-bottom: none;
}

.category-list a {
    text-decoration: none;
    color: var(--dark);
    display: flex;
    align-items: center;
    transition: color 0.3s;
}

.category-list a:hover {
    color: var(--primary);
}

.category-list a span {
    margin-right: 10px;
    font-size: 1.2rem;
}

.popular-games {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.game-tag {
    background: var(--light);
    padding: 8px 15px;
    border-radius: 30px;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.game-tag:hover {
    background: var(--primary);
    color: white;
    cursor: pointer;
}

/* 栏目页样式 */
.category-header {
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: white;
    padding: 40px 30px;
    border-radius: 10px;
    margin-bottom: 30px;
}

.category-header h1 {
    font-size: 2.5rem;
    display: flex;
    align-items: center;
}

.category-header h1 span {
    margin-right: 15px;
    font-size: 2.5rem;
}

/* 文章页样式 */
.article-header {
    text-align: center;
    margin-bottom: 30px;
}

.article-header h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.article-meta {
    color: var(--gray);
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.article-content {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    line-height: 1.8;
    margin-bottom: 40px;
}

.article-content p {
    margin-bottom: 20px;
}

.article-content img {
    max-width: 100%;
    border-radius: 10px;
    margin: 20px 0;
}

/* 网址导航页样式 */
.websites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.website-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
}

.website-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.website-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.website-card h3 {
    margin-bottom: 10px;
}

.website-card p {
    color: var(--gray);
    margin-bottom: 15px;
    font-size: 0.9rem;
}

/* 页脚样式 */
footer {
    background: var(--dark);
    color: white;
    padding: 50px 0 20px;
    margin-top: 50px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-column h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    background: var(--accent);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #ddd;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent);
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #aaa;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .main-content {
        grid-template-columns: 1fr;
    }

    .hero h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-wrap: wrap;
    }

    .logo {
        order: 1;
    }

    .mobile-menu-btn {
        display: block;
        order: 2;
    }

    nav {
        order: 4;
        width: 100%;
        margin-top: 20px;
        display: none;
    }

    nav.active {
        display: block;
    }

    nav ul {
        flex-direction: column;
    }

    nav ul li {
        margin: 10px 0;
    }

    .search-bar {
        order: 3;
        width: 100%;
        margin: 15px 0;
    }

    .news-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .hero {
        padding: 60px 20px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 40px 15px;
    }

    .article-content {
        padding: 25px;
    }

    .article-meta {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .category-header h1 {
        font-size: 2rem;
    }
}
