/* 排序成句专属样式（公共组件、变量见 ../../style.css）
   复用护眼童趣主题：暖色底、降饱和柔和配色、大圆角 */

#app {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 20px;
  align-items: start;
  width: 100%;
  max-width: 760px;
}

#sidebar {
  background: var(--panel);
  border-radius: 18px;
  padding: 22px 20px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.actions { display: flex; flex-direction: column; gap: 8px; }
.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.btn-row .btn { padding: 10px 8px; }

.progress-dots { display: flex; flex-wrap: wrap; gap: 6px; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--border); transition: background .15s; }
.dot.current { background: var(--primary); opacity: 0.45; }
.dot.done { background: var(--primary); }

.stat-value.muted { color: var(--primary); opacity: 0.4; }

#play-area {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 26px;
  padding: 36px 24px;
  min-height: 360px;
  background: var(--panel);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

/* 出题区固定高度：解析面板显隐不改变题目位置 */
.question-zone {
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
}

/* 提示：翻译 */
.clue { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.clue-text { font-size: 20px; font-weight: 600; color: var(--text); text-align: center; }

/* 槽位：成句区（短语块按序填入） */
.slots { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 460px; }
.slot {
  padding: 10px 16px; font-size: 16px; font-weight: 600;
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--panel); color: var(--primary); cursor: pointer;
  transition: background .12s, border-color .12s, transform .08s;
}
.slot.empty { min-width: 56px; border-style: dashed; color: transparent; }
.slot.empty::before { content: "·"; color: var(--border); }
.slot.filled { background: #f0e9d6; color: var(--text); border-color: var(--border); }
.slot.wrong { border-color: #e57373; color: #e57373; background: #fdeaea; }
@media (hover: hover) {
  .slot.filled:hover:not(:disabled) { background: #ebe2cb; }
}
.slot:active:not(:disabled) { transform: translateY(1px); }
.slot:disabled { cursor: default; }

/* 短语块池 */
.pool { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; max-width: 460px; }
.tile {
  padding: 12px 16px; font-size: 16px; font-weight: 600;
  border: 1px solid var(--border); border-radius: 12px; cursor: pointer;
  background: var(--panel); color: var(--primary);
  box-shadow: 0 4px 12px -4px rgba(140, 100, 40, 0.18);
  transition: transform .12s, box-shadow .12s, opacity .12s;
}
@media (hover: hover) {
  .tile:hover:not(:disabled) { transform: translateY(-4px); box-shadow: 0 10px 20px -6px rgba(140, 100, 40, 0.28); }
}
.tile:active:not(:disabled) { transform: translateY(-1px); }
.tile.used { opacity: 0.25; box-shadow: none; }
.tile:disabled { cursor: default; }

.modal-content .win-record { color: var(--primary); font-size: 15px; min-height: 1.2em; }

@media (max-width: 640px) {
  #app { grid-template-columns: 1fr; }
  #play-area { padding: 24px 16px; min-height: 300px; gap: 20px; }
  .question-zone { min-height: 220px; gap: 20px; }
  .clue-text { font-size: 18px; }
  .slot, .tile { padding: 9px 12px; font-size: 14px; }
}
