/* style.css */

/* Utility to hide elements */
.hidden {
  display: none;
}

/* Body layout */
body {
  font-family: 'Baloo 2', sans-serif;
  background: linear-gradient(145deg, #ffeabf, #ffd6b2);
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  color: #333;
  text-align: center;
}

/* Quiz & Snapshot containers */
#quiz-container,
#result-snapshot {
  width: 90%;
  max-width: 500px;
  background: white;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Progress bar */
#progress-bar-container {
  width: 100%;
  height: 8px;
  background: #ddd;
  border-radius: 5px;
  margin-bottom: 20px;
}
#progress-bar {
  width: 0%;
  height: 100%;
  background: #ff8c42;
  border-radius: 5px;
  transition: width 0.4s ease;
}

/* Trivia box */
.trivia-box {
  background: #f9f9f9;
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  display: none;
}
.trivia-box p {
  margin: 0;
  font-size: 1rem;
}

/* Question styling */
.question-box {
  margin-bottom: 20px;
}
.question {
  font-size: 1.4rem;
  margin-bottom: 15px;
}

/* Answer buttons */
.answer-btn {
  display: block;
  width: 100%;
  margin: 8px 0;
  padding: 12px;
  background: #4caf50;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s ease;
}
.answer-btn:hover {
  background: #45a049;
}

/* Hidden containers after quiz end or before confirm */
#result-snapshot.hidden,
#quiz-container.hidden,
#confirm-container.hidden {
  display: none;
}

/* Snapshot header and restart button */
.snapshot-header h1 {
  margin-top: 0;
}
#restart-btn {
  margin-top: 20px;
  padding: 12px 20px;
  background: #ff8c42;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
}
#restart-btn:hover {
  background: #ff6a00;
}
/* — HOST INTRO — */
#host-intro {
  text-align: center;
  padding: 2rem;
  background: rgba(0,0,0,0.05);
  border-radius: 10px;
  margin: 1rem auto;
  max-width: 500px;
}
.host-img {
  width: 120px;
  margin-bottom: 1rem;
}
#host-text {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}
#host-start-btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 25px;
  background: #4caf50;
  color: #fff;
  cursor: pointer;
  transition: transform 0.2s;
}
#host-start-btn:hover {
  transform: scale(1.05);
}

/* — QUIZ / GAME WRAPPER — */
#quiz-game.hidden { display: none; }

/* — DOOR PICK — */
#door-container {
  display: flex;
  justify-content: space-around;
  margin: 1rem 0;
}
.door {
  width: 100px;
  height: 140px;
  background: #654321;
  border: 3px solid #333;
  border-radius: 5px;
  color: #fff;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  perspective: 600px;
  transition: transform 0.6s;
}
.door.open {
  transform: perspective(600px) rotateY(-120deg);
}
/* Base styles & existing rules (keep all your current CSS above) */

/* — POLL STYLES — */
.poll-wrap {
  margin: 1rem 0;
}
.poll-btn {
  display: block;
  width: 100%;
  padding: 0.75rem;
  font-size: 1.1rem;
  background: #4caf50;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
  margin-bottom: 0.5rem;
}
.poll-btn:hover {
  background: #45a049;
}
.poll-bar {
  position: relative;
  background: #eee;
  height: 1.5rem;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 1rem;
}
.poll-fill {
  position: absolute;
  left: 0; top: 0;
  height: 100%;
  width: 0;
  background: #3ea2ff;
  transition: width 0.3s;
}
.poll-label {
  position: absolute;
  left: 0.5rem; top: 50%;
  transform: translateY(-50%);
  font-size: 0.9rem;
  color: #fff;
}
/* Optional “Next” button after poll */
.next-btn {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.5rem 1rem;
  background: #096fbd;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.next-btn:disabled {
  background: #999;
  cursor: not-allowed;
}
/* Block‐Timer Styles */
#block-timer {
  font-size: 1.25rem;
  font-weight: bold;
  color: #d32f2f;
  text-align: center;
  margin: 1rem 0;
}
/* Emoji‑Block Timer (matches your 15 s timer style) */
#emoji-block-timer {
  font-size: 1.25rem;
  font-weight: bold;
  color: #d32f2f;
  text-align: center;
  margin: 1rem 0;
}

/* Emoji Showdown Styles (already in your file) */
.emoji-wrap {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin: 1rem 0;
}
.emoji-btn {
  font-size: 2.5rem;
  padding: 0.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
}
/* Ranked‑Trio slots */
.trio-slots {
  display: flex;
  justify-content: space-around;
  margin: 1rem 0;
}
.trio-slot {
  width: 30%;
  min-height: 4rem;
  border: 2px dashed #888;
  border-radius: 6px;
  text-align: center;
  line-height: 4rem;
  font-weight: bold;
}

/* Ranked‑Trio cards */
.trio-cards {
  display: flex;
  justify-content: space-around;
  margin: 1rem 0;
}
.trio-card {
  width: 30%;
  padding: 1rem;
  border: 2px solid #444;
  border-radius: 6px;
  background: #f0f0f0;
  text-align: center;
  cursor: grab;
  user-select: none;
}

/* Submit button */
#trio-submit {
  display: block;
  margin: 1rem auto;
  padding: 0.5rem 1rem;
}
