.screen {
  display: none;
}

.screen.active {
  display: block;
}

.top-bar {
  text-align: center;
}

.progress-bar {
  width: 100%;
  height: 6px;
  background: #ddd;
}
#progress-fill {
  height: 100%;
  width: 0%;
  background: #4caf50;
}

.center {
  /* display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin: 10px 0; */
  display: flex;
  flex-direction: column;
  align-items: center;
}

.reel {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  margin-bottom: 6px;
}

.reel.horizontal {
  /* grid-column: 1 / span 2;
  justify-content: center;
  flex-direction: row; */
  display: flex;
  justify-content: center;
  margin-bottom: 8px;
}

.reel.vertical {
  /* display: flex;
  grid-row: 2;
  grid-column: 1;
  height: 110px;
  flex-direction: column;
  justify-content: center; */
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 120px;
}

.reel-item {
  width: 36px;
  height: 36px;
  opacity: 0.3;
  font-size: min(8vw, 40px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.reel-item.active {
  font-size: 32px;
  opacity: 1;
  transform: scale(1.2);
}

.main-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.left {
  display: flex;
  justify-content: center;
}

.right {
  display: flex;
  justify-content: center;
}

.input {
  /* grid-row: 2;
  grid-column: 2;

  width: min(20vw, 100px);
  height: min(20vw, 100px);

  border: 3px solid #000;
  background: #fff;

  font-size: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative; */
  width: 100px;
  height: 100px;

  border: 3px solid #000;
  background: #fff;

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 36px;
  color: black;
  position: relative; 
}

.start-btn {
  width: 100%;
  height: 100%;
  font-size: 20px;
}

.character {
  width: 96px;
  height: 96px;

  background-image: url("./img/100masu-sprite.png");
  background-repeat: no-repeat;
  background-position: 0 0;

  image-rendering: pixelated; /* ドット絵なら */
}

.keypad {
  display: grid;
  grid-template-columns: repeat(3, 70px);
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
}

.keypad button {
  width: 70px;
  height: 70px;
  font-size: 20px;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(11, 1fr);
  gap: 0;
  margin-top: 10px;
  border: 2px solid #000;
}

.result-cell {
  border: 1px solid #000;
  background: #fff;

  /* 正方形 */
  aspect-ratio: 1 / 1;

  /* 中央配置 */
  display: flex;
  align-items: center;
  justify-content: center;

  font-size: clamp(12px, 2.5vw, 18px);
}

/* 見出し（上・左） */
.result-header {
  background: #f0f0f0;
  font-weight: bold;
  color: #000;
}

/* 色分け */
.correct {
  color: blue;
}

.wrong {
  color: red;
}

/* 履歴 */
#history {
  margin-top: 10px;
  font-size: 14px;
}