/* =========================
   全局基础样式（深色风格）
========================= */
@font-face {
  font-family: "Wubi Units";
  src: url("./黑体字根.ttf");
}

.wubi-radical {
  font-family: "Wubi Units", monospace;
  font-size: 1.6em;
  letter-spacing: 0.08em;
}
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    background: #34495e; /* 第一背景*/
    font-family: "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
    color: #e0e0e0; /* 浅灰文字 */
}

/* =========================
   主容器
========================= */
.container {
    width: 1600px;
    margin: 30px auto;
    background: rgba(52, 73, 94, 0.9); /* 第二背景 */
    border-radius: 10px;
    padding: 20px 26px 26px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.5); /* 更深阴影 */
}

/* =========================
   课程选择区域
========================= */
.file-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    gap: 10px;
    flex-wrap: wrap;
}

/* 统一三个下拉+label行内间距 */
.file-selector > label {
    font-size: 22px;
    cursor: default;
    color: #e0e0e0;
    margin-right: 4px;
}

/* 三个下拉框统一样式：dirSelect / lessonSelect / timeSelect */
#dirSelect,
#lessonSelect,
#timeSelect {
    font-size: 20px;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid #555;
    outline: none;
    background: #3a3a3a;
    color: #e0e0e0;
    min-width: 160px;
}

#dirSelect:focus,
#lessonSelect:focus,
#timeSelect:focus {
    border-color: #27ae60;
    box-shadow: 0 0 6px rgba(46, 204, 113, 0.4);
}

/* =========================
   按钮通用
========================= */
button {
    cursor: pointer;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 15px;
    transition: all 0.15s ease;
    background: #3a3a3a;
    color: #e0e0e0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

button:active {
    transform: scale(0.97);
}

/* =========================
   功能按钮
========================= */
.button-group {
    text-align: center;
    margin-bottom: 12px;
}

.btn-secondary {
    background: linear-gradient(135deg, #3a3a3a, #4a4a4a);
    color: #e0e0e0;
    margin: 0 8px;
}

.btn-game {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    color: #fff;
    margin-top: 6px;
}

/* =========================
   游戏区域
========================= */
#gameArea {
    margin-top: 16px;
}

/* 进度显示 */
#gameProgress {
    font-size: 14px;
    color: #cccccc;
    margin-bottom: 10px;
}

/* =========================
   单词 / 句子显示区
========================= */
#gameDisplay {
    border-radius: 8px;
    padding: 16px 18px;
    margin-bottom: 14px;
	text-align: center;
}

/* 第一行：单词 */
#line1 {
    font-size: 80px;
    font-weight: bold;
    color: #ffffff;
    margin-bottom: 6px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.7);
}

/* 第二行：翻译 */
#line2 {
    font-size: 65px;
    color: #eeeeee;
    margin-bottom: 6px;
}

/* 第三行：音标*/
#line3 {
    font-size: 65px;
    color: #eeffee;
    margin-bottom: 6px;
}

/* 第四行：例句 */
#line4 {
    font-size: 60px;
    color: #eeffee;
    margin-bottom: 6px;
    text-align: center;
    text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

.hidden {
    display: none !important;
}

/* =========================
   输入区域
========================= */
.input-area {
    text-align: center;
    margin-top: 10px;
}

#answerInput {
    width: 70%;
    font-size: 50px;
    padding: 8px 12px;
    border-radius: 6px;
    border: 2px solid #555;
    outline: none;
    background: #3a3a3a;
    color: #e0e0e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

#answerInput:focus {
    border-color: #27ae60;
    background: #444;
    box-shadow: 0 0 8px #27ae60;
}

/* =========================
   结果提示
========================= */
#gameResult {
    text-align: center;
    font-size: 18px;
    margin-top: 10px;
    min-height: 24px;
}

.correct {
    color: #2ecc71;
    text-shadow: 0 0 6px #2ecc71;
}

.wrong {
    color: #e74c3c;
    text-shadow: 0 0 6px #e74c3c;
}

/* =========================
   喇叭按钮（朗读）
========================= */
.speaker-btn {
    margin-left: 6px;
    font-size: 16px;
    background: #3a3a3a;
    color: #e0e0e0;
    padding: 4px 8px;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.speaker-btn:hover {
    background: #27ae60;
    color: #fff;
}

/* =========================
   重新开始按钮
========================= */
.btn-reset {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: #fff;
    margin-top: 14px;
}

/* =========================
   响应式（可选）
========================= */
@media (max-width: 960px) {
    .container {
        width: 94%;
    }

    #answerInput {
        width: 90%;
    }

    .file-selector {
        flex-direction: column;
        gap:8px;
    }
}