/* 全局通用样式 */
* {
  box-sizing: border-box;
}
body {
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(135deg, #74ABE2, #5563DE);
  margin: 0;
  padding: 0;
  color: #333;
  transition: background 0.5s, color 0.5s;
}
/* 深色模式 */
body.dark {
  background: #222;
  color: #ddd;
}
.container {
  width: 90%;
  max-width: 600px;
  margin: 50px auto;
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  animation: fadeIn 0.5s ease-in-out;
}
body.dark .container {
  background: #333;
  color: #ddd;
}
h1, h2 {
  text-align: center;
  margin-top: 0;
}
.btn {
  display: inline-block;
  padding: 10px 20px;
  margin: 8px;
  background-color: #5563DE;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.btn:hover {
  background-color: #3d4bb7;
}
button:disabled {
  background-color: #999;
  cursor: not-allowed;
}
.question {
  font-size: 1.2em;
  margin-bottom: 20px;
}
.answer {
  font-size: 1.1em;
  margin: 20px 0;
  color: #28a745;
  display: none; /* 初始隐藏答案 */
}
.navigation {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}
/* 进度条样式 */
.progress-container {
  margin: 10px 0;
}
.progress-text {
  text-align: center;
  margin-bottom: 5px;
}
.progress-bar {
  width: 100%;
  background-color: #ddd;
  border-radius: 20px;
  overflow: hidden;
}
.progress-bar-inner {
  height: 10px;
  width: 0;
  background-color: #5563DE;
  transition: width 0.3s;
}
/* 顶部工具栏 */
.topbar {
  position: fixed;
  top: 10px;
  right: 10px;
  z-index: 1000;
}
.topbar button {
  background-color: transparent;
  border: none;
  font-size: 1em;
  color: #fff;
  cursor: pointer;
  padding: 5px 10px;
}
@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
/* 复选框样式 */
.option-group {
  text-align: center;
  margin: 15px 0;
}
.option-group input {
  margin-right: 5px;
}
/* 隐藏元素的辅助类 */
.hidden {
  display: none !important;
}
/* 跟读结果 */
.recognitionResult {
  margin: 10px 0;
  color: #666;
}
/* 识别结果中正确/错误词标记 */
.word-correct {
  color: green;
}
.word-wrong {
  color: red;
}
