.choice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.choice {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  min-height: 100px;
  font-size: 18px;
}

.choice .number {
  background: #fff;
  color: #9b173a;
}

.open-here {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 12px 18px;
  border: 2px solid #b31942;
  border-radius: 10px;
  background: #fff7fa;
  font-size: 20px;
}

:focus-visible {
  outline: 5px solid #ffc400;
  outline-offset: 4px;
  box-shadow: 0 0 0 8px rgba(23, 35, 58, .35);
}

.choice:focus-visible {
  background: #6f0f2c;
  color: #fff;
  transform: scale(1.02);
}

.choice:focus-visible .number {
  background: #ffc400;
  color: #17233a;
}

.kiosk-frame:focus,
.kiosk-frame:focus-visible {
  outline: 7px solid #ffc400;
  outline-offset: 3px;
  box-shadow: 0 0 0 10px rgba(23, 35, 58, .45);
}

[hidden] {
  display: none !important;
}

.keyboard-guide {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  padding: 14px 16px;
  margin-bottom: 12px;
  border: 2px solid #b31942;
  border-radius: 10px;
  background: #fff7fa;
  color: #17233a;
}

.keyboard-guide strong { width: 100%; font-size: 18px; }
.keyboard-guide span { white-space: nowrap; }
.keyboard-guide kbd {
  display: inline-block;
  min-width: 30px;
  padding: 4px 7px;
  border: 1px solid #8b95a5;
  border-bottom-width: 3px;
  border-radius: 5px;
  background: white;
  font: inherit;
  font-weight: 700;
  text-align: center;
}

.kiosk-frame { height: calc(100vh - 260px); min-height: 520px; }

.iframe-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  padding: 18px;
  background: rgba(15, 25, 43, .82);
}

.iframe-modal-shell {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(260px, 1fr);
  gap: 16px;
  width: 100%;
  height: 100%;
  padding: 16px;
  border: 5px solid #ffc400;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 22px 70px #0008;
}

.iframe-area { min-width: 0; min-height: 0; }
.iframe-area .kiosk-frame { width: 100%; height: 100%; min-height: 0; border-radius: 10px; }
.keyboard-sidebar { overflow: auto; padding: 18px; border-radius: 12px; background: #fff7dc; }
.keyboard-sidebar h2 { margin-top: 0; font-size: 27px; }
.key-list { display: grid; gap: 12px; margin-top: 20px; }
.key-list span { display: grid; gap: 7px; justify-items: center; padding: 15px 10px; border-radius: 10px; background: #fff; text-align: center; }
.key-list b { display: block; }

@media (max-width: 700px), (orientation: portrait) {
  .choice-grid { grid-template-columns: 1fr; }
  .keyboard-guide span { white-space: normal; }
  .kiosk-frame { height: calc(100vh - 360px); min-height: 500px; }
  .iframe-modal { padding: 8px; }
  .iframe-modal-shell { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; padding: 8px; }
  .keyboard-sidebar { max-height: 34vh; }
  .key-list { grid-template-columns: 1fr 1fr; }
}
