/*
 * Estilos para o jogo “Show do Milhão – Edição Redes”.
 * Inspirado no layout do programa original, com tons de azul escuro,
 * elementos dourados e acabamento luminoso. A estrutura é composta
 * pela área do apresentador (à esquerda) e pelo palco de perguntas
 * (à direita).
 */

/* Paleta de cores e variáveis utilitárias */
:root {
  --bg: #0b1026;
  --card: #11183a;
  --accent: #1e2a70;
  --gold: #f2c84b;
  --green: #38d16a;
  --red: #f45b69;
  --text: #e8ecff;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: radial-gradient(circle at 60% -10%, #1b2a7a 0%, #0b1026 55%, #050815 100%);
  color: var(--text);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 16px;
  /* Permite rolagem quando o conteúdo for longo, como na tela de resumo */
  overflow-y: auto;
}

/* Contêiner principal com apresentador e palco */
.container {
  width: min(1100px, 100%);
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 16px;
}

/* Área do apresentador */
.host {
  background: linear-gradient(180deg, #13215c, #0c1438);
  border: 1px solid #24307a;
  border-radius: 16px;
  padding: 14px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .05);
}
.host:before {
  content: "";
  position: absolute;
  inset: -40px -40px auto auto;
  width: 200px;
  height: 200px;
  opacity: .08;
  background: radial-gradient(circle, #6dc1ff, transparent 60%);
  filter: blur(8px);
  transform: translate(30px, -30px);
}
.host-img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid #20308a;
}
.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: #081036;
  border: 1px solid #1b2a7a;
  color: #8fb4ff;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: .6px;
  text-transform: uppercase;
}
.host h2 {
  margin: 10px 0 8px;
  font-size: 20px;
}
.host p {
  margin: 6px 0 0;
  opacity: .9;
  font-size: 14px;
  line-height: 1.35;
}

/* Escada de valores */
.ladder {
  margin-top: 12px;
  display: grid;
  gap: 6px;
  max-height: 360px;
  overflow: auto;
  padding-right: 4px;
}
.step {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  border-radius: 10px;
  background: linear-gradient(180deg, #0b143d, #0a1233);
  border: 1px solid #20308a;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 14px;
}
.step.active {
  background: linear-gradient(180deg, #102166, #0b173f);
  border-color: #2a49d1;
  box-shadow: 0 0 0 2px #2a49d144;
}
.step .money {
  color: var(--gold);
  font-weight: 700;
}

/* Palco das perguntas */
.stage {
  background: linear-gradient(180deg, #0f1a4d 0%, #0e153f 100%);
  border: 1px solid #2a3a9a;
  border-radius: 16px;
  padding: 16px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .05);
}
.header {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: .6px;
  text-transform: uppercase;
  color: var(--gold);
  text-shadow: 0 2px 0 #000;
  display: flex;
  align-items: center;
  gap: 8px;
}
.edition {
  color: #9ad3ff;
}
.chips {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.chip {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid #2e43a7;
  background: #0a1233;
  font-size: 12px;
  color: #cbd6ff;
}
.chip.small {
  font-size: 11px;
  opacity: .85;
}
.timer {
  padding: 6px 10px;
  border-radius: 10px;
  border: 1px solid #2e43a7;
  background: #0a1233;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

/* Pergunta e opções */
.question {
  margin: 8px 0 12px;
  padding: 16px;
  border-radius: 12px;
  background: linear-gradient(180deg, #0c1438, #0a1230);
  border: 1px solid #2a3a9a;
  font-size: 18px;
  line-height: 1.4;
}
.options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.btn {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #2a3a9a;
  background: #0a1230;
  color: #eaf0ff;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: .2s transform;
}
.btn:hover:not([disabled]) {
  transform: translateY(-1px);
}
.btn.correct {
  background: #0d2e1e;
  border-color: #2e8b57;
  box-shadow: 0 0 0 2px #2e8b5750;
}
.btn.wrong {
  background: #3a0e17;
  border-color: #b63b4a;
  box-shadow: 0 0 0 2px #b63b4a50;
}
.btn:disabled {
  opacity: .5;
  cursor: not-allowed;
}

/* Barra de progresso */
.progress {
  height: 6px;
  background: #091233;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 10px;
  border: 1px solid #1a2a7a;
}
.progress > div {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #48b6ff, #8fd3ff);
  transition: width .3s;
}

/* Rodapé e controles */
.footer {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  margin-top: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.control {
  padding: 10px 12px;
  border-radius: 10px;
  background: #0a1230;
  border: 1px solid #2a3a9a;
  cursor: pointer;
  font-weight: 700;
  color: #eaf0ff;
}
.control:disabled {
  opacity: .5;
  cursor: not-allowed;
}

/* Esconde os botões de seleção de modo dentro do jogo, pois a escolha ocorre na tela inicial */
#start-classic,
#start-study {
  display: none;
}
.status {
  font-size: 14px;
  opacity: .9;
}

/* Poster promocional integrado ao palco */
.poster-inline {
  margin-top: 12px;
  width: 100%;
  display: flex;
  justify-content: center;
}
.poster-inline-img {
  /* Diminui a imagem para caber inteira dentro do palco */
  width: 60%;
  max-width: 420px;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid #2a3a9a;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

/* ======= Tela inicial (start-screen) ======= */
.start-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  z-index: 9999;
  /* Usa o pôster como fundo; ajusta para que a imagem apareça inteira. 
     O restante é preenchido com cor escura. */
  background-image: url('host.jpg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  background-color: #050815;
  color: var(--text);
  text-align: center;
}

/* Dark overlay para melhorar legibilidade do texto */
.start-screen .start-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Opacidade reduzida para o pôster ficar mais visível */
  background: rgba(0, 0, 0, 0.3);
  z-index: -1;
}

.start-content {
  position: relative;
  padding: 20px;
  border-radius: 12px;
  backdrop-filter: blur(4px);
}

.start-title {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
  color: var(--gold);
  text-shadow: 0 2px 0 #000;
}
.start-subtitle {
  font-size: 16px;
  margin-bottom: 20px;
  opacity: .9;
}
.start-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.start-btn {
  padding: 12px 20px;
  font-size: 16px;
  font-weight: 700;
  border-radius: 10px;
  border: 1px solid #2a3a9a;
  background: #0a1230;
  color: #eaf0ff;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
  transition: background .2s, transform .2s;
}
.start-btn:hover {
  background: #14265c;
  transform: translateY(-2px);
}

/* Explicação no modo estudo */
.explanation {
  margin-top: 10px;
  opacity: .95;
  font-size: 14px;
}

/* Motivo para aparecer nos dispositivos menores */
@media (max-width: 900px) {
  .container { grid-template-columns: 1fr; }
}