.game-root { min-height: 46rem; }

.recall-num {
  display: inline-block;
  min-width: 2ch;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.recall-go {
  min-width: 8.6rem;
  white-space: nowrap;
}

.recall-stage {
  width: min(100%, 34rem);
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  user-select: none;
}

.recall-status {
  min-height: 4.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.12rem;
  text-align: center;
}

.recall-line,
.recall-note {
  margin: 0;
  line-height: 1.35;
  min-height: 1.35em;
}

.recall-line { color: #f4f0e8; }

.recall-note {
  color: #d5ddd6;
  font-size: 0.95rem;
}

.recall-note.is-good { color: #e0b948; }

.recall-panel {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 0.8rem;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 42%),
    #14241e;
  box-shadow:
    inset 0 0 0 1px rgba(232, 217, 168, 0.38),
    inset 0 12px 24px rgba(0, 0, 0, 0.25);
}

.recall-board,
.recall-choices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
}

.recall-slot {
  aspect-ratio: 1;
  min-width: 0;
  min-height: var(--tap-min);
  border-radius: 14px;
  position: relative;
}

.recall-blank,
.recall-cover {
  width: 100%;
  height: 100%;
  border-radius: 14px;
}

.recall-blank {
  background: rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.recall-cover {
  background: #d7cbb6;
  box-shadow:
    inset 0 0 0 1px rgba(70, 55, 30, 0.28),
    inset 0 -8px 14px rgba(0, 0, 0, 0.06);
}

.recall-tile {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: #fffdf7;
  box-shadow:
    inset 0 0 0 1px rgba(184, 146, 58, 0.45),
    0 1px 0 rgba(255, 255, 255, 0.35);
}

button.recall-tile {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  font: inherit;
  cursor: pointer;
  touch-action: manipulation;
}

button.recall-tile:focus-visible {
  outline: 3px solid #e0b948;
  outline-offset: 3px;
}

.recall-tile.is-right {
  box-shadow:
    inset 0 0 0 3px #e0b948,
    0 0 0 2px rgba(224, 185, 72, 0.85);
}

.recall-tile.is-miss {
  background: #f6e4e1;
  box-shadow: inset 0 0 0 3px #a3302f;
}

.recall-mark {
  width: 58%;
  height: 58%;
  overflow: visible;
  pointer-events: none;
}

.recall-mark circle,
.recall-mark path,
.recall-mark rect { fill: currentColor; }

.recall-key {
  position: absolute;
  top: 0.35rem;
  left: 0.45rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: #5c564c;
  opacity: 0.85;
  pointer-events: none;
}

.recall-tray {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 0.65rem 0.7rem 0.7rem;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.22);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.recall-tray.is-live {
  box-shadow: inset 0 0 0 1px rgba(224, 185, 72, 0.75);
}

.recall-tray.is-idle { opacity: 0.5; }

.recall-tray.is-idle .recall-tray-label { visibility: hidden; }

.recall-tray-label {
  margin: 0;
  min-height: 1.35em;
  line-height: 1.35;
  text-align: center;
  font-size: 0.95rem;
  color: #d5ddd6;
}

@media (max-width: 640px), (pointer: coarse) {
  .recall-key { display: none; }
  .recall-note.is-keys { visibility: hidden; }
}
