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

/* 页面基础样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* 游戏容器：包含所有游戏界面 */
.game-container {
    width: 100%;
    max-width: 600px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* 屏幕通用样式：默认隐藏 */
.screen {
    display: none;
    padding: 40px;
    text-align: center;
}

/* 激活的屏幕：显示 */
.screen.active {
    display: block;
}

/* 开始界面样式 */
#start-screen {
    padding: 60px 40px;
}

/* 奖杯图标：带动画效果 */
.trophy-icon {
    font-size: 80px;
    margin-bottom: 20px;
    animation: bounce 2s ease-in-out infinite;
}

/* 弹跳动画 */
@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

/* 开始界面标题 */
#start-screen h1 {
    font-size: 2.2rem;
    color: #2c3e50;
    margin-bottom: 15px;
    font-weight: 700;
}

/* 副标题样式 */
.subtitle {
    font-size: 1.2rem;
    color: #5a6c7d;
    margin-bottom: 30px;
}

/* 球场预览图标 */
.stadium-preview {
    font-size: 2.5rem;
    margin-bottom: 40px;
    letter-spacing: 10px;
}

/* 主要按钮样式 */
.primary-btn {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border: none;
    padding: 15px 50px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

/* 按钮悬停效果 */
.primary-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
}

/* 答题界面样式 */
#quiz-screen {
    padding: 30px;
}

/* 进度条容器 */
.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 15px;
}

/* 进度条填充 */
.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db, #2ecc71);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

/* 题目计数器 */
.question-counter {
    font-size: 0.95rem;
    color: #7f8c8d;
    margin-bottom: 20px;
}

/* 答题内容区域 */
.quiz-content {
    margin-bottom: 20px;
}

/* 图片容器 */
.image-container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 25px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    background: #f8f9fa;
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 图片样式 */
.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 题目文本 */
.question-text {
    font-size: 1.15rem;
    color: #2c3e50;
    margin-bottom: 25px;
    line-height: 1.6;
    font-weight: 500;
}

/* 选项容器 */
.options-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 选项按钮 */
.option-btn {
    width: 100%;
    padding: 15px 20px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    color: #495057;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

/* 选项按钮悬停效果 */
.option-btn:hover {
    background: #e8f4fd;
    border-color: #3498db;
}

/* 正确选项样式 */
.option-btn.correct {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

/* 错误选项样式 */
.option-btn.wrong {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

/* 禁用的选项按钮 */
.option-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

/* 分数显示（已移除，保留样式） */
.score-display {
    padding: 12px;
    background: #f8f9fa;
    border-radius: 10px;
    font-size: 0.95rem;
    color: #495057;
}

/* 结果界面样式 */
#result-screen {
    padding: 50px 40px;
}

/* 结果图标 */
.result-icon {
    font-size: 70px;
    margin-bottom: 20px;
}

/* 结果标题 */
#result-screen h1 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 30px;
}

/* 统计信息容器 */
.result-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 30px;
}

/* 统计项 */
.stat-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* 统计标签 */
.stat-label {
    font-size: 0.9rem;
    color: #7f8c8d;
}

/* 统计数值 */
.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: #3498db;
}

/* 评级显示 */
.result-rank {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px 30px;
    border-radius: 15px;
    margin-bottom: 25px;
}

/* 评级标签 */
.rank-label {
    display: block;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 5px;
}

/* 评级数值 */
.rank-value {
    font-size: 1.6rem;
    font-weight: 700;
    color: white;
}

/* 结果描述 */
.result-description {
    font-size: 1rem;
    color: #5a6c7d;
    line-height: 1.6;
    margin-bottom: 30px;
}

/* 隐藏成就容器 */
.achievement-container {
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cc 100%);
    border: 2px solid #f0c14b;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 25px;
    text-align: center;
    animation: achievementPop 0.5s ease-out;
}

@keyframes achievementPop {
    0% {
        transform: scale(0.5);
        opacity: 0;
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.achievement-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 8px;
}

.achievement-icon {
    font-size: 2rem;
}

.achievement-name {
    font-size: 1.3rem;
    font-weight: bold;
    color: #b8860b;
}

.achievement-desc {
    font-size: 0.9rem;
    color: #8b7355;
    margin: 0;
}

/* 结果按钮容器 */
.result-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* 次要按钮 */
.secondary-btn {
    background: #f8f9fa;
    color: #3498db;
    border: 2px solid #3498db;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.secondary-btn:hover {
    background: #e8f4fd;
    transform: translateY(-2px);
}

/* 创建问题界面 */
#create-question-screen {
    padding: 30px;
    max-height: 80vh;
    overflow-y: auto;
}

/* 创建问题表单区域 */
.create-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
}

.create-section h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

/* 问题类型选择 */
.type-selector {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.type-selector label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 16px;
    border: 2px solid #e9ecef;
    border-radius: 20px;
    transition: all 0.2s ease;
}

.type-selector label:hover {
    border-color: #3498db;
    background: #e8f4fd;
}

.type-selector input[type="radio"]:checked + span {
    color: #3498db;
    font-weight: 600;
}

/* 表单组 */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #495057;
    font-weight: 500;
}

.form-group input[type="text"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

.form-group input[type="text"]:focus {
    outline: none;
    border-color: #3498db;
}

.form-group input[type="file"] {
    margin-bottom: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #6c757d;
}

/* 选项输入容器 */
#text-options-container,
#image-options-container {
    margin-bottom: 15px;
}

.option-input {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.option-input input {
    flex: 1;
}

.remove-option {
    background: #dc3545;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.remove-option:hover {
    background: #c82333;
    transform: scale(1.1);
}

/* 添加选项按钮 */
.add-option-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.add-option-btn:hover {
    background: #218838;
    transform: translateY(-1px);
}

/* 下拉选择框 */
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.form-group select:focus {
    outline: none;
    border-color: #3498db;
}

/* 正确答案复选框容器 */
.correct-answers-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 5px;
}

.correct-answer-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
}

.correct-answer-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.correct-answer-item label {
    margin: 0;
    cursor: pointer;
    flex: 1;
}

/* 创建问题按钮容器 */
.create-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
}

/* 语言切换按钮容器 */
.language-selector {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 30px;
}

/* 语言切换按钮 */
.lang-btn {
    padding: 8px 20px;
    border: 2px solid #e9ecef;
    background: white;
    border-radius: 20px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #6c757d;
}

.lang-btn:hover {
    border-color: #3498db;
    color: #3498db;
}

.lang-btn.active {
    background: #3498db;
    border-color: #3498db;
    color: white;
}

/* 响应式设计：移动端适配 */
@media (max-width: 480px) {
    .screen {
        padding: 30px 20px;
    }
    
    #start-screen h1 {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .trophy-icon {
        font-size: 60px;
    }
    
    .result-stats {
        gap: 20px;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .result-buttons,
    .create-buttons {
        flex-direction: column;
    }
    
    .type-selector {
        flex-direction: column;
        gap: 10px;
    }
}