/* だれのえらんだ？: テーマ上書き（ピンク系）＋ゲーム画面スタイル
 *
 * 選択肢は「絵が主・文字は補助」（AGENTS.md）なので、絵文字を40pxで大きく置き、
 * ラベルは小さく下に添える。2列グリッドにしているのは、6〜8個の選択肢を
 * スマホ縦持ちで1画面に収めつつ、ボタンの高さ56px以上を守るため。
 */

:root {
  --party-accent: #e5508a;
  --party-accent-dark: #b93468;
  --party-accent-soft: #ffe3ee;
  --party-bg: #fff0f5;
  --party-card: #ffffff;
  --dg-ink: #5c1d38;
}

#dg-root {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.dg-screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: calc(env(safe-area-inset-top) + 16px) calc(env(safe-area-inset-right) + 14px)
    calc(env(safe-area-inset-bottom) + 20px) calc(env(safe-area-inset-left) + 14px);
  text-align: center;
}

.dg-screen h2 {
  font-size: 1.3rem;
  margin: 0;
}

.dg-progress {
  font-size: 0.9rem;
  opacity: 0.7;
  margin: 0;
}

.dg-question {
  font-size: 1.35rem;
  margin: 0;
  color: var(--dg-ink);
  line-height: 1.35;
}

.dg-question-sub {
  font-size: 1rem;
  margin: 0;
  color: var(--party-muted);
}

.dg-msg {
  font-size: 1.1rem;
  margin: 0;
}

.dg-msg-sub {
  font-size: 0.95rem;
  opacity: 0.75;
  margin: 0;
}

/* --- のこり時間バー --- */
.dg-timer-bar {
  width: min(340px, 92vw);
  height: 10px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.dg-timer-bar-fill {
  height: 100%;
  width: 100%;
  background: var(--party-accent);
  transition: width 0.2s linear;
}

/* --- 選択肢（2列グリッド） --- */
.dg-choice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: min(360px, 94vw);
}

.dg-choice-btn {
  min-height: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 8px 6px;
  border: none;
  border-radius: 18px;
  background: #fff;
  color: var(--dg-ink);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.14);
}

.dg-choice-btn[disabled] {
  opacity: 0.85;
}

.dg-choice-emoji {
  font-size: 40px;
  line-height: 1.1;
}

.dg-choice-label {
  font-size: 0.85rem;
  font-weight: bold;
  line-height: 1.2;
}

.dg-btn-selected {
  outline: 3px solid var(--party-accent-dark);
  background: var(--party-accent-soft);
  opacity: 1;
}

/* --- ふつうのボタン --- */
.dg-btn {
  min-height: 56px;
  padding: 0 22px;
  border-radius: 16px;
  border: none;
  background: #fff;
  color: var(--party-accent-dark);
  font-size: 1.05rem;
  font-weight: bold;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.15);
}

.dg-btn-primary {
  background: var(--party-accent);
  color: #fff;
  box-shadow: 0 3px 0 var(--party-accent-dark);
}

.dg-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* --- しゅやくの見出し --- */
.dg-target {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--party-accent-soft);
  border-radius: 999px;
  padding: 8px 18px 8px 12px;
  max-width: 94vw;
}

.dg-target-icon {
  font-size: 2.2rem;
  line-height: 1;
}

.dg-target-name {
  font-size: 1.15rem;
  font-weight: bold;
  color: var(--dg-ink);
}

/* しゅやく自身の待機画面に出す「きみのこたえ」 */
.dg-mypick {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: #fff;
  border-radius: 18px;
  padding: 12px 24px;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.12);
}

.dg-mypick-cap {
  font-size: 0.85rem;
  color: var(--party-muted);
}

.dg-mypick-emoji {
  font-size: 48px;
  line-height: 1.1;
}

.dg-mypick-label {
  font-size: 1rem;
  font-weight: bold;
  color: var(--dg-ink);
}

/* --- スキップ --- */
.dg-skip-icon {
  font-size: 64px;
  line-height: 1;
}

/* --- REVEAL --- */
.dg-reveal {
  cursor: pointer;
}

.dg-answer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.dg-answer-emoji {
  font-size: 80px;
  line-height: 1.05;
}

.dg-answer-label {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--dg-ink);
}

.dg-hits {
  width: min(360px, 94vw);
  background: #fff;
  border-radius: 18px;
  padding: 12px;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.1);
}

.dg-hits-cap {
  margin: 0 0 6px;
  font-weight: bold;
  color: var(--party-accent-dark);
}

.dg-hits-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.dg-hit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.4em;
}

.dg-hit-icon {
  font-size: 1.8rem;
  line-height: 1.1;
}

.dg-hit-name {
  font-size: 0.75rem;
  color: var(--dg-ink);
}

.dg-all-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: min(360px, 94vw);
}

.dg-all-cap {
  margin: 4px 0 0;
  font-size: 0.9rem;
  color: var(--party-muted);
}

.dg-all-row {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border-radius: 14px;
  padding: 8px 12px;
  text-align: left;
}

/* しゅやくが選んだ行だけ枠で目立たせる（「え、それ選んだの！？」の主役） */
.dg-all-row-target {
  outline: 3px solid var(--party-accent);
  background: var(--party-accent-soft);
}

.dg-all-emoji {
  font-size: 1.6rem;
  line-height: 1;
}

.dg-all-label {
  font-size: 0.9rem;
  font-weight: bold;
  color: var(--dg-ink);
  min-width: 5.5em;
}

.dg-all-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  font-size: 1.2rem;
  margin-left: auto;
}

.dg-tap-hint {
  margin: 2px 0 0;
  font-size: 0.8rem;
  color: var(--party-muted);
}

/* --- FINAL --- */
.dg-final-head {
  font-size: 1.15rem;
  color: var(--dg-ink);
}

.dg-winner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: var(--party-accent-soft);
  border-radius: 22px;
  padding: 14px 28px;
}

.dg-winner-icon {
  font-size: 64px;
  line-height: 1.05;
}

.dg-winner-name {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--dg-ink);
}

.dg-winner-pt {
  font-weight: bold;
  color: var(--party-accent-dark);
}

.dg-final-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(360px, 94vw);
}

.dg-final-row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border-radius: 14px;
  padding: 10px 14px;
}

.dg-final-medal {
  font-size: 1.3rem;
  min-width: 2em;
}

.dg-final-icon {
  font-size: 1.3rem;
}

.dg-final-name {
  flex: 1;
  text-align: left;
  font-weight: bold;
  color: var(--dg-ink);
}

.dg-final-pt {
  font-weight: bold;
  color: var(--party-accent-dark);
}
