body {
  font-family: Arial, sans-serif;
  background-color: #f0f0f0;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.container {
  width: 90%;
  max-width: 800px;
  background-color: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  text-align: center;
}

h1 {
  color: #333;
}

#explanation {
  font-size: 20px;
}
.stageselect {
  height: 60px;
  display: flex;
  justify-content: center;
  margin: 10px auto;
}

.stageselect p {
  margin: auto 5px;
}

.stageselect button {
  width: 150px;
  margin: 0 5px;
}

#renda {
  display: flex;
  width: 90%;
}

#renda p {
  margin-bottom: 0;
}

#ren {
  margin-right: auto;
}

#zen {
  margin-left: auto;
}

#timeBoard {
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
}

.time-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.next-word-text {
  width: 90%;
  display: flex;
  margin-bottom: 0;
}

.time-text {
  margin: 20px 0 -20px 0;
}

.time-large {
  font-size: 28px; /* 残り時間の数字を大きくする */
  font-weight: bold;
}

#meterA, #meterB {
  width: 90%; /* メーターの幅を統一 */
  height: 20px; /* メーターの高さを統一 */
  border-radius: 5px; /* 角を少し丸める */
  background-color: #f0f0f0; /* 背景色を設定 */
}

#gameArea {
  position: relative;
  height: 200px;
  background-color: #eef;
  border: 2px solid #ccc;
  border-radius: 10px;
  padding: 0 20px;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#wordContainer {
  text-align: center;
  font-size: 40px;
  font-weight: bold;
  color: #333;
}

#word {
  margin-bottom: 10px;
}

#morse {
  font-size: 18px; /* モールスをさらに小さくする */
  color: #555;
  display: flex;
  gap: 0px; /* モールス符号の間隔をゼロに */
  flex-wrap: wrap; /* 必要に応じて折り返す */
}

#morse span {
  display: inline-block;
}

.matched {
  color: rgba(0, 0, 0, 0.3);
}

.unmatched {
  color: gray;
}

#scoreBoard {
  display: flex;
  justify-content: space-between;
  margin: 20px 0;
}

#controls {
  display: flex;
  justify-content: center;
  gap: 20px;
}

button {
  padding: 10px 20px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  background-color: #007BFF;
  color: #fff;
  transition: background-color 0.2s ease;
}

button:hover {
  background-color: #0056b3;
}

button:disabled {
  background-color: #cccccc;
  cursor: not-allowed;
}

.sliders-container {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.slider-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* スコア表示のスタイル */
#resultDisplay {
  display: none; /* 初期非表示 */
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(255, 255, 255, 0.9);
  border: 2px solid #333;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

#resultDisplay h2 {
  margin: 0 0 10px;
  font-size: 24px;
  color: #333;
}

#resultDisplay p {
  margin: 5px 0;
  font-size: 18px;
  color: #555;
}

#resultDisplay button {
  margin-top: 15px;
  padding: 10px 20px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  background-color: #007BFF;
  color: #fff;
  transition: background-color 0.2s ease;
}

#resultDisplay button:hover {
  background-color: #0056b3;
}
