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

/* 基础样式 */
body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
    background-image: linear-gradient(to bottom, #f5f5f5, #e0e0e0);
    min-height: 100vh;
}

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

/* 导航栏样式 */
.navbar {
    background-color: #333;
    color: #fff;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

.navbar-brand a {
    color: #fff;
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.navbar-menu {
    display: flex;
    gap: 1.5rem;
}

.navbar-menu a {
    color: #fff;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar-menu a:hover {
    color: #4CAF50;
}

.navbar-toggle {
    display: none;
    cursor: pointer;
}

.navbar-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* 主内容样式 */
.main {
    padding: 0 0 2rem;
}

.game-category {
    margin-bottom: 3rem;
    background-color: #fff;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.game-category h2 {
    margin-bottom: .5rem;
    color: #333;
    font-size: 1.5rem;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 0.5rem;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.game-card {
    background-color: #f9f9f9;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.game-card a {
    display: block;
    text-decoration: none;
    color: #333;
}

.game-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-bottom: 2px solid #4CAF50;
}

.game-card h3 {
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
}

/* 详情页样式 */
.game-detail {
    background-color: #fff;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.back-link {
    display: inline-block;
    margin-bottom: 1.5rem;
    color: #4CAF50;
    text-decoration: none;
    font-weight: 500;
}

.back-link:hover {
    text-decoration: underline;
}

.game-detail-content {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.game-detail-image {
    flex: 0 0 40%;
}

.game-detail-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.game-detail-info {
    flex: 1;
}

.game-detail-info h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.game-detail-info p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: #555;
}

.btn {
    display: inline-block;
    background-color: #4CAF50;
    color: #fff;
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #45a049;
}

.related-games {
    background-color: #fff;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.related-games h2 {
    margin-bottom: 1.5rem;
    color: #333;
    font-size: 1.5rem;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 0.5rem;
}

/* 联系表单样式 */
.contact-section {
    background-color: #fff;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.contact-section h2 {
    margin-bottom: 1.5rem;
    color: #333;
    font-size: 1.5rem;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 0.5rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea {
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

/* 隐私政策和服务条款样式 */
.privacy-section,
.terms-section {
    background-color: #fff;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.privacy-section h2,
.terms-section h2 {
    margin-bottom: 1.5rem;
    color: #333;
    font-size: 1.5rem;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 0.5rem;
}

.privacy-content h3,
.terms-content h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: #333;
    font-size: 1.2rem;
}

.privacy-content p,
.terms-content p {
    margin-bottom: 1rem;
    line-height: 1.8;
    color: #555;
}

.privacy-content ul,
.terms-content ul {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    color: #555;
}

.privacy-content li,
.terms-content li {
    margin-bottom: 0.5rem;
}

/* 页脚样式 */
.footer {
    background-color: #333;
    color: #fff;
    padding: 2rem 0;
    margin-top: 3rem;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.footer-brand a {
    color: #fff;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #4CAF50;
}

.footer-copyright {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: #999;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .navbar-menu {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: #333;
        flex-direction: column;
        align-items: center;
        padding: 1rem 0;
        gap: 1rem;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        transform: translateY(-150%);
        transition: transform 0.3s ease;
        z-index: 999;
    }

    .navbar-menu.active {
        transform: translateY(0);
    }

    .navbar-toggle {
        display: block;
    }

    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }

    .game-card img {
        height: 120px;
    }

    .game-detail-content {
        flex-direction: column;
    }

    .game-detail-image {
        flex: 0 0 100%;
    }

    .game-category{
        padding: 0.5rem 1.5rem 1.5rem;
    }
    .game-detail,
    .related-games,
    .contact-section,
    .privacy-section,
    .terms-section {
        padding: 1.5rem;
    }

    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .navbar-brand a {
        font-size: 1.5rem;
    }

    .game-category h2,
    .related-games h2,
    .contact-section h2,
    .privacy-section h2,
    .terms-section h2 {
        font-size: 1.3rem;
    }

    .game-detail-info h1 {
        font-size: 1.5rem;
    }

    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}