/* ============================================
   games.css — ゲームページ共通スタイル
   ============================================ */

/* ===== ハブページ ===== */
.games-hero {
  padding: 140px 24px 60px;
  text-align: center;
}

.games-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -1.5px;
  margin-bottom: 12px;
}

.games-hero p {
  color: var(--text-muted);
  font-size: 1.05rem;
}

.games-main {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px 100px;
}

/* ===== フィルターバー ===== */
.filter-bar {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.filter-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0 14px;
  transition: border-color 0.2s;
}

.filter-search:focus-within {
  border-color: var(--accent);
}

.filter-search__icon {
  font-size: 1rem;
  opacity: 0.5;
  flex-shrink: 0;
}

.filter-search input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  padding: 12px 0;
  font-size: 0.9rem;
  font-family: var(--font);
  color: var(--text);
}

.filter-search input::placeholder {
  color: var(--text-muted);
  opacity: 0.6;
}

.filter-search button {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  font-size: 0.85rem;
  opacity: 0.6;
  transition: opacity 0.15s;
}

.filter-search button:hover { opacity: 1; }

.tag-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: 0.8rem;
  font-family: var(--font);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.tag-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.tag-btn.active {
  background: rgba(148, 128, 255, 0.12);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.filter-count {
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--text-muted);
  text-align: right;
  margin-top: -6px;
  margin-bottom: 6px;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.game-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  text-align: center;
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
  cursor: pointer;
  display: block;
}

.game-card:hover {
  border-color: var(--accent);
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(124, 106, 247, 0.2);
}

.game-card__icon {
  font-size: 3rem;
  margin-bottom: 16px;
  display: block;
}

.game-card h2 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.game-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.game-card__badge {
  display: inline-block;
  background: rgba(124, 106, 247, 0.15);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--accent);
}

/* ===== ゲームページ共通レイアウト ===== */
.game-page {
  min-height: 100vh;
  padding: 100px 24px 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.game-header {
  text-align: center;
  margin-bottom: 32px;
}

.game-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -1px;
  margin-bottom: 8px;
}

.game-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.game-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 32px;
  transition: color 0.2s;
}

.game-back:hover { color: var(--accent); }

/* ===== スコアボード ===== */
.scoreboard {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

.score-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 20px;
  text-align: center;
  min-width: 80px;
}

.score-item__label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.score-item__value {
  font-size: 1.4rem;
  font-weight: 700;
  font-family: var(--mono);
  color: var(--accent);
}

/* ===== ゲームコントロール ===== */
.game-controls {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ===== オーバーレイ（ゲームオーバー・勝利） ===== */
.game-overlay {
  position: absolute;
  inset: 0;
  background: rgba(13, 13, 20, 0.88);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border-radius: var(--radius);
  backdrop-filter: blur(4px);
  z-index: 10;
}

.game-overlay h2 {
  font-size: 2rem;
  font-weight: 700;
}

.game-overlay p {
  color: var(--text-muted);
  font-size: 1rem;
}

/* ===== マインスイーパー ===== */
.ms-wrapper {
  position: relative;
  display: inline-block;
}

.ms-board {
  display: grid;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  user-select: none;
}

.ms-cell {
  width: 32px;
  height: 32px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  font-family: var(--mono);
  cursor: pointer;
  transition: background 0.1s;
  border: 1px solid transparent;
}

.ms-cell--hidden {
  background: var(--surface-2);
  border-color: var(--border);
}
.ms-cell--hidden:hover { background: rgba(124, 106, 247, 0.15); border-color: var(--accent); }

.ms-cell--revealed {
  background: var(--bg);
  cursor: default;
}

.ms-cell--flagged {
  background: rgba(124, 106, 247, 0.15);
  border-color: var(--accent);
}

.ms-cell--mine { background: rgba(248, 113, 113, 0.2); }

.ms-cell[data-n="1"] { color: #60a5fa; }
.ms-cell[data-n="2"] { color: #4ade80; }
.ms-cell[data-n="3"] { color: #f87171; }
.ms-cell[data-n="4"] { color: #a78bfa; }
.ms-cell[data-n="5"] { color: #fb923c; }
.ms-cell[data-n="6"] { color: #2dd4bf; }
.ms-cell[data-n="7"] { color: #e2e2f0; }
.ms-cell[data-n="8"] { color: #8888aa; }

.ms-difficulty {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  justify-content: center;
}

.ms-diff-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font);
}
.ms-diff-btn:hover,
.ms-diff-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(124, 106, 247, 0.1);
}

/* ===== テトリス ===== */
.tetris-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  flex-wrap: wrap;
  justify-content: center;
}

.tetris-board-wrap {
  position: relative;
}

canvas#tetrisBoard {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-dark);
}

.tetris-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 140px;
}

.tetris-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.tetris-panel h3 {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

canvas#nextPiece,
canvas#holdPiece {
  display: block;
  margin: 0 auto;
}

.tetris-side--left {
  order: -1;   /* ボードの左に配置 */
}

.tetris-keys {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.9;
}

.tetris-keys kbd {
  display: inline-block;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 6px;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text);
}

/* ===== ホームランダービー ===== */
.homerun-wrap {
  position: relative;
  width: 100%;
  max-width: 800px;
}

canvas#homerunCanvas {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-dark, #0a0a10);
}

/* ============================================
   脱出ゲーム
   ============================================ */
.er-room-tag {
  display: inline-block;
  background: var(--surface-2);
  border: 1px solid var(--border);
  padding: 2px 12px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  margin-top: 6px;
}

.er-layout {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 20px;
  width: 100%;
  max-width: 960px;
}

/* ===== ステージ（部屋）===== */
.er-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  /* 床と壁のラインを示すグラデーション（テーマで上書き）*/
  background: linear-gradient(180deg, #2a2540 0%, #2a2540 60%, #4a3528 60%, #5a4030 100%);
}

.er-stage::before {
  /* 中央光のハイライト */
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 35%, rgba(255, 220, 160, 0.07) 0%, transparent 60%),
    repeating-linear-gradient(
      90deg,
      transparent 0px, transparent 39px,
      rgba(0, 0, 0, 0.08) 40px
    );
  pointer-events: none;
}

.er-room--living   { background: linear-gradient(180deg, #2c2640 0%, #2c2640 60%, #4a3528 60%, #5a4030 100%); }
.er-room--study    { background: linear-gradient(180deg, #1f2a3a 0%, #1f2a3a 60%, #4a3a2a 60%, #5a4630 100%); }
.er-room--bedroom  { background: linear-gradient(180deg, #3a253a 0%, #3a253a 60%, #5a4528 60%, #6b5232 100%); }

.er-error {
  padding: 32px;
  color: var(--text-muted);
  text-align: center;
}

/* ===== ホットスポット ===== */
.er-hotspot {
  position: absolute;
  transform: translate(-50%, -50%);
  background: transparent;
  border: 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 8px;
  border-radius: 12px;
  transition: background 0.15s, transform 0.15s;
  color: var(--text);
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
}

.er-hotspot:hover,
.er-hotspot:focus-visible {
  background: rgba(148, 128, 255, 0.20);
  transform: translate(-50%, -50%) scale(1.06);
  outline: none;
}

.er-hotspot:active { transform: translate(-50%, -50%) scale(0.97); }

.er-emoji {
  font-size: 2.6rem;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.6));
  line-height: 1;
}

.er-label {
  font-size: 0.68rem;
  margin-top: 4px;
  background: rgba(0,0,0,0.7);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 4px;
  font-family: var(--mono);
  white-space: nowrap;
  color: var(--text);
}

/* ===== サイドバー / インベントリ ===== */
.er-sidebar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  align-self: start;
  position: sticky;
  top: 90px;
}

.er-sidebar-title {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 12px;
  font-family: var(--mono);
}

.er-inventory {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 80px;
}

.er-inv-empty {
  color: var(--text-muted);
  font-size: 0.82rem;
  text-align: center;
  padding: 16px 0;
  line-height: 1.6;
}

.er-inv-slot {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  text-align: left;
  color: var(--text);
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
  width: 100%;
}

.er-inv-slot:hover {
  border-color: var(--accent);
  background: rgba(148, 128, 255, 0.10);
}

.er-inv-slot:active { transform: scale(0.98); }

.er-inv-icon { font-size: 1.6rem; }

.er-inv-name {
  font-size: 0.85rem;
  font-weight: 500;
}

/* ===== ダイアログ ===== */
.er-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(6px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: er-fade-in 0.18s ease;
}

@keyframes er-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.er-dialog {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 480px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: er-pop-in 0.22s cubic-bezier(0.34, 1.4, 0.64, 1);
}

@keyframes er-pop-in {
  from { transform: scale(0.92); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.er-dialog h3 {
  font-size: 1.25rem;
  margin-bottom: 12px;
  color: var(--accent);
}

.er-instr {
  font-size: 0.92rem;
  line-height: 1.7;
  margin-bottom: 18px;
  color: var(--text-muted);
}

.er-msg {
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text);
  margin-bottom: 4px;
}

.er-dlg-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 18px;
  flex-wrap: wrap;
}

/* シーケンス・パズル */
.er-seq-display {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 18px 0;
  transition: transform 0.1s;
}

.er-seq-display--wrong {
  animation: er-shake 0.4s;
}

.er-seq-slot {
  width: 50px;
  height: 50px;
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  background: var(--surface-2);
  color: var(--text-muted);
}

.er-seq-slot--filled {
  border-color: var(--accent);
  background: rgba(148, 128, 255, 0.12);
}

.er-seq-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 4px;
}

.er-seq-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
  transition: all 0.12s;
}

.er-seq-btn:hover {
  border-color: var(--accent);
  background: rgba(148, 128, 255, 0.12);
}

.er-seq-btn:active { transform: scale(0.96); }

.er-seq-icon { font-size: 1.8rem; line-height: 1; }
.er-seq-name { font-size: 0.78rem; color: var(--text-muted); }

/* テキスト/数値入力 */
.er-input {
  width: 100%;
  background: var(--surface-2);
  border: 2px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  font-size: 1.4rem;
  font-family: var(--mono);
  color: var(--text);
  letter-spacing: 0.18em;
  text-align: center;
  margin-bottom: 4px;
  outline: none;
  transition: border-color 0.15s;
  text-transform: uppercase;
}

.er-input:focus { border-color: var(--accent); }

.er-input--wrong {
  border-color: #f87171;
  animation: er-shake 0.4s;
}

@keyframes er-shake {
  0%, 100% { transform: translateX(0); }
  25%      { transform: translateX(-7px); }
  75%      { transform: translateX(7px); }
}

/* アイテム詳細 */
.er-item-detail {
  text-align: center;
  margin-bottom: 8px;
}

.er-item-icon-big {
  font-size: 4rem;
  margin-bottom: 12px;
  filter: drop-shadow(0 4px 12px rgba(148, 128, 255, 0.5));
}

.er-item-detail h3 { margin-bottom: 12px; }

.er-item-desc {
  text-align: left;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 0.92rem;
  line-height: 1.85;
  font-family: var(--mono);
  color: var(--text);
  white-space: pre-wrap;
}

/* エンディング */
.er-ending {
  text-align: center;
  padding: 12px 0 8px;
}

.er-ending h2 {
  font-size: 2rem;
  background: linear-gradient(135deg, #fff 20%, var(--accent) 55%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
}

.er-ending p {
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text);
}

/* モバイル */
@media (max-width: 720px) {
  .er-layout {
    grid-template-columns: 1fr;
  }

  .er-sidebar {
    position: static;
    padding: 12px;
  }

  .er-inventory {
    flex-direction: row;
    flex-wrap: wrap;
    min-height: 0;
  }

  .er-inv-slot {
    flex: 0 0 auto;
    padding: 8px 10px;
  }

  .er-inv-name { font-size: 0.78rem; }

  .er-emoji { font-size: 2rem; }
  .er-label { font-size: 0.62rem; padding: 1px 6px; }

  .er-dialog { padding: 20px; }

  .er-seq-slot {
    width: 42px;
    height: 42px;
    font-size: 1.5rem;
  }

  .er-seq-icon { font-size: 1.6rem; }

  .er-input {
    font-size: 1.2rem;
    padding: 12px 14px;
  }
}

/* ============================================
   モバイル対応（共通）
   ============================================ */

/* デスクトップ/モバイルで操作説明を出し分け */
.game-help-mobile { display: none; }
.game-help-desktop { display: block; }

@media (max-width: 720px) {
  .game-help-mobile  { display: block; }
  .game-help-desktop { display: none; }
}

/* ===== マインスイーパー: モバイル用 ===== */

/* 旗モードトグル */
.ms-mode {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}

.ms-mode-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 0.88rem;
  color: var(--text-muted);
  cursor: pointer;
  font-family: var(--font);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ms-mode-btn .ms-mode-state {
  font-family: var(--mono);
  font-size: 0.75rem;
  background: var(--surface-2);
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--text-muted);
  transition: all 0.2s;
}

.ms-mode-btn.active {
  border-color: var(--accent-3);
  color: var(--accent-3);
  background: rgba(244, 114, 182, 0.1);
}

.ms-mode-btn.active .ms-mode-state {
  background: var(--accent-3);
  color: #fff;
}

/* セルサイズはJSで動的に決定するためここでは幅指定を上書きしない */
.ms-cell {
  width: var(--ms-cell-size, 32px);
  height: var(--ms-cell-size, 32px);
  /* タッチ操作で長押しメニューやテキスト選択を抑制 */
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  touch-action: manipulation;
}

@media (max-width: 720px) {
  .ms-board {
    padding: 8px;
    gap: 1px;
    /* 上級モードで横にあふれた場合はスクロール可能にする */
    max-width: 100%;
    overflow: auto;
  }

  .ms-cell {
    font-size: 0.78rem;
    border-radius: 3px;
  }

  .ms-difficulty {
    flex-wrap: wrap;
    gap: 6px;
  }

  .ms-diff-btn {
    font-size: 0.78rem;
    padding: 6px 12px;
  }
}

/* ===== テトリス: レスポンシブ ===== */
canvas#tetrisBoard {
  width: 100%;
  max-width: 300px;
  height: auto;
  aspect-ratio: 1 / 2;
  touch-action: none;
}

/* モバイル操作ボタン（デフォルトでは非表示、タッチ端末で表示） */
.tetris-mobile-ctrl {
  display: none;
  width: 100%;
  max-width: 360px;
  margin: 24px auto 0;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.tet-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-size: 1.4rem;
  font-family: var(--font);
  padding: 16px 0;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: background 0.1s, border-color 0.1s, transform 0.1s;
}

.tet-btn:active,
.tet-btn.is-pressed {
  background: rgba(148, 128, 255, 0.18);
  border-color: var(--accent);
  transform: scale(0.96);
}

.tet-btn--wide {
  grid-column: span 3;
  font-size: 1rem;
  padding: 14px 0;
  letter-spacing: 0.05em;
  font-weight: 600;
}

@media (max-width: 720px) {
  .tetris-layout {
    flex-direction: column;
    gap: 14px;
    align-items: center;
  }

  /* Hold / Next を横並びでボード上部に配置 */
  .tetris-side {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    min-width: 0;
    width: 100%;
  }
  .tetris-side--left { order: 0; }

  .tetris-panel {
    padding: 10px 14px;
    flex: 0 0 auto;
  }

  .tetris-panel h3 {
    font-size: 0.65rem;
    margin-bottom: 6px;
    text-align: center;
  }

  /* ホールド・ネクストのプレビューを少し小さめに */
  canvas#nextPiece,
  canvas#holdPiece {
    width: 70px;
    height: 70px;
  }

  /* モバイルではキーボード説明パネルは隠す */
  .tetris-panel:has(.tetris-keys) { display: none; }

  /* リスタート/ポーズボタンはモバイルでは横並び */
  .tetris-side .game-controls {
    flex-direction: row !important;
    justify-content: center;
    width: 100%;
  }

  /* 操作ボタンを表示 */
  .tetris-mobile-ctrl { display: grid; }

  /* ゲームページの上下余白を圧縮 */
  .game-page {
    padding: 90px 12px 40px;
  }
}

/* タッチ端末（hover不可）でも操作ボタンを出す */
@media (hover: none) and (pointer: coarse) {
  .tetris-mobile-ctrl { display: grid; }
}
