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

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
}

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

/* 头部样式 */
header {
    background-color: #333;
    color: #fff;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 8px;
}

header h1 {
    text-align: center;
    margin-bottom: 20px;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
    flex-wrap: wrap;
}

nav ul li {
    margin: 0 10px;
}

nav ul li button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
}

nav ul li button:hover {
    background-color: #45a049;
}

/* 题目容器样式 */
.question-container {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

#question-header {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #ddd;
}

#question-header h2 {
    margin-bottom: 10px;
}

#question-info {
    font-size: 14px;
    color: #666;
}

#question-content {
    font-size: 18px;
    margin-bottom: 20px;
    line-height: 1.5;
}

#options-container {
    margin-bottom: 20px;
}

.option {
    background-color: #f9f9f9;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    border-left: 4px solid #4CAF50;
    cursor: pointer;
    transition: all 0.3s ease;
}

.option:hover {
    background-color: #f1f1f1;
    transform: translateX(5px);
}

#answer-container {
    margin-bottom: 20px;
}

#user-answer {
    width: 100%;
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
}

#btn-submit {
    background-color: #008CBA;
    color: white;
    border: none;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
}

#btn-submit:hover {
    background-color: #007bb5;
}

#result-container {
    margin-bottom: 20px;
    padding: 10px;
    border-radius: 4px;
}

.result-correct {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.result-incorrect {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

#action-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

#action-buttons button {
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ddd;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
}

#action-buttons button:hover {
    background-color: #e0e0e0;
}

#btn-favorite-toggle {
    background-color: #ffc107;
    color: #333;
    border: 1px solid #ffc107;
}

#btn-favorite-toggle:hover {
    background-color: #e0a800;
}

/* 底部样式 */
footer {
    text-align: center;
    margin-top: 20px;
    padding: 10px;
    background-color: #333;
    color: #fff;
    border-radius: 8px;
}

/* 分页容器样式 */
#pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
    gap: 10px;
}

#pagination-info {
    font-size: 14px;
    color: #666;
}

#pagination-container button {
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ddd;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
}

#pagination-container button:hover {
    background-color: #e0e0e0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    nav ul {
        flex-direction: column;
        align-items: center;
    }
    
    nav ul li {
        margin: 5px 0;
    }
    
    #action-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    #action-buttons button {
        width: 100%;
    }
    
    #pagination-container {
        flex-direction: column;
        gap: 5px;
    }
    
    #pagination-container button {
        width: 100%;
    }
}
