/* 基础重置和变量 */
:root {
    --primary-color: #4CAF50;
    --primary-hover: #45a049;
    --secondary-color: #2196F3;
    --accent-color: #FF6B35;
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-light: #999999;
    --background: #ffffff;
    --background-alt: #f8f9fa;
    --border-color: #e0e0e0;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-hover: 0 4px 20px rgba(0,0,0,0.15);
    --radius: 8px;
    --radius-large: 12px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--background);
}

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

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo h2 {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-cta {
    background: var(--primary-color);
    color: white;
    padding: 10px 20px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-cta:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: 0.3s;
}

/* 英雄区块 */
.hero {
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* 游戏预览 */
.game-preview {
    display: flex;
    align-items: center;
    gap: 2rem;
    justify-content: center;
    padding: 2rem;
}

.preview-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow);
    text-align: center;
    min-width: 150px;
}

.preview-card h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.preview-count {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.preview-question {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-light);
}

.vs-indicator {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: inherit;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-outline:hover {
    background: var(--text-primary);
    color: white;
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

/* 部分样式 */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* 功能区块 */
.features {
    padding: 80px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.feature-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.feature-link:hover {
    color: var(--primary-hover);
}

/* 游戏模式 */
.game-modes {
    padding: 80px 0;
    background: var(--background-alt);
}

.modes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.mode-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow);
}

.mode-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.mode-card p {
    color: var(--text-secondary);
}

/* 玩法说明 */
.how-to-play {
    padding: 80px 0;
}

.gameplay-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin: 3rem 0;
}

.step {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
}

.step-number {
    background: var(--primary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.step-content p {
    color: var(--text-secondary);
}

.play-cta {
    text-align: center;
    margin-top: 3rem;
}

/* 博客区块 */
.blog {
    padding: 80px 0;
    background: var(--background-alt);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.blog-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-date {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.blog-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.blog-card p {
    color: var(--text-secondary);
}

.blog-cta {
    text-align: center;
}

/* 最终CTA */
.final-cta {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    text-align: center;
}

.final-cta h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.final-cta p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* 推荐语 */
.testimonials {
    padding: 80px 0;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow);
    text-align: center;
}

.testimonial p {
    font-style: italic;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.testimonial-author {
    font-weight: 600;
    color: var(--primary-color);
}

/* FAQ */
.faq {
    padding: 80px 0;
    background: var(--background-alt);
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3rem;
}

.faq-category h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.faq-item {
    margin-bottom: 2rem;
}

.faq-item h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.faq-item p {
    color: var(--text-secondary);
}

/* 页脚 */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
}

.footer-links a:hover {
    color: white;
}

/* SEO优化的隐藏文本 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 结构化数据辅助样式 */
.structured-content {
    /* 确保内容对搜索引擎友好 */
}

/* 图片SEO优化 */
img {
    max-width: 100%;
    height: auto;
}

/* 链接SEO优化 */
a {
    color: inherit;
    text-decoration: none;
}

a:focus,
a:hover {
    text-decoration: underline;
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* 标题层次优化 */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin: 0 0 1rem 0;
}

h1 {
    font-size: clamp(2rem, 5vw, 3rem);
}

h2 {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
}

/* 内容可读性优化 */
p {
    line-height: 1.6;
    margin: 0 0 1rem 0;
    max-width: 70ch; /* 优化阅读长度 */
}

/* 跳转链接（无障碍） */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 9999;
}

.skip-link:focus {
    top: 6px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .game-preview {
        flex-direction: column;
        gap: 1rem;
    }
    
    .vs-indicator {
        transform: rotate(90deg);
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .features-grid,
    .modes-grid,
    .blog-grid,
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
    
    .gameplay-steps {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .faq-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
    }
}

/* Modal Showcase Styles */
.showcase-modal {
    display: flex;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    position: relative;
    max-width: 1000px;
    width: 100%;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-content-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    cursor: pointer;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: white;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.modal-close:hover {
    background: #f0f0f0;
    color: #333;
}

.modal-container {
    position: relative;
    min-height: 400px;
}

.modal-image-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    height: 100%;
    min-height: 400px;
}

.modal-image-item {
    position: relative;
    overflow: hidden;
}

.modal-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
}

.modal-label {
    position: absolute;
    bottom: 20px;
    left: 20px;
    color: white;
    font-size: 18px;
    font-weight: 600;
}

.modal-text-section {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 40px;
    text-align: center;
    color: white;
    z-index: 5;
}

.modal-text-content {
    color: white;
    max-width: 400px;
}

.modal-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.2;
    color: white;
}

.modal-subtitle {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 24px;
    opacity: 1;
    color: white;
}

.modal-btn {
    background: #6366F1;
    color: white;
    border: none;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
}

.modal-btn:hover {
    background: #4F46E5;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

/* Responsive Modal */
@media (max-width: 768px) {
    .modal-container {
        min-height: 300px;
    }
    
    .modal-image-section {
        min-height: 300px;
    }
    
    .modal-text-section {
        padding: 25px 25px;
    }
    
    .modal-content {
        max-width: 100%;
    }
    
    .modal-title {
        font-size: 24px;
    }
    
    .modal-subtitle {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .modal-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
        font-size: 24px;
    }
    
    .modal-label {
        font-size: 14px;
        bottom: 10px;
        left: 10px;
    }
    
    .modal-image-section {
        grid-template-columns: 1fr;
        min-height: 250px;
    }
    
    .modal-text-section {
        padding: 15px 15px;
    }
    
    .modal-title {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .modal-subtitle {
        font-size: 13px;
        margin-bottom: 12px;
    }
}
