/* jogar.css — tela do jogador (celular). */

body.jogar {
  color: var(--paper);
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1rem;
  background: var(--navy);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.logo-small {
  height: 28px;
}
.conn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--mist);
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  background: #888;
}
.dot-open {
  background: #3ddc84;
}
.dot-reconnecting {
  background: var(--alert);
}
.dot-offline {
  background: var(--danger);
}

.jogar .page {
  padding-top: 1rem;
  gap: 1rem;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
}
.jogar h1 {
  color: var(--paper);
}
.jogar .lead {
  color: var(--mist);
  text-align: center;
}

/* Entrada */
.names {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.couple {
  display: flex;
  gap: 0.6rem;
}
.name-btn {
  flex: 1;
  min-height: 56px;
  background: var(--paper);
  color: var(--navy);
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.2;
  padding: 0.5rem 0.75rem;
}
.name-btn:hover {
  background: #eef3fa;
}
.name-btn:disabled {
  opacity: 0.45;
}
.name-btn small {
  display: block;
  font-size: 0.75rem;
  font-weight: 400;
}

/* Cabeçalho da rodada e último número */
.round-head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: var(--mist);
  font-size: 0.95rem;
}
.round-head strong {
  color: var(--paper);
}
.pattern-icon {
  display: inline-grid;
  grid-template-columns: repeat(5, 6px);
  gap: 1px;
  vertical-align: middle;
}
.pattern-icon i {
  width: 6px;
  height: 6px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 1px;
}
.pattern-icon i.on {
  background: var(--teal);
}
.last-box {
  width: 100%;
  text-align: center;
  padding: 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
}
.last-label {
  color: var(--mist);
  font-size: 0.85rem;
}
.last-number {
  font-size: clamp(3rem, 18vw, 5rem);
  font-weight: 700;
  line-height: 1.1;
  color: var(--teal);
}
.pop {
  animation: pop 0.4s ease-out;
}
@keyframes pop {
  0% {
    transform: scale(0.6);
    opacity: 0;
  }
  70% {
    transform: scale(1.08);
  }
  100% {
    transform: none;
    opacity: 1;
  }
}
.prev {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  color: var(--mist);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}
.count {
  color: var(--mist);
  font-size: 0.75rem;
  margin-top: 0.25rem;
}

/* Cartela */
.card-wrap {
  width: 100%;
  background: var(--paper);
  color: var(--navy);
  border-radius: 16px;
  padding: 0.75rem;
  box-shadow: var(--shadow);
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  gap: 0.5rem;
}
.card-head h2 {
  font-size: 1.05rem;
  font-weight: 700;
}
.chip {
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: #eef3fa;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
}
.chip-hot {
  background: var(--alert);
  color: var(--paper);
  animation: pulse 1.2s infinite;
}
.chip-done {
  background: var(--teal);
  color: var(--paper);
}
@keyframes pulse {
  50% {
    transform: scale(1.06);
  }
}
.grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
}
.cell {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #eef3fa;
  font-weight: 500;
  font-size: clamp(1rem, 5vw, 1.4rem);
  transition: background 0.2s, color 0.2s, transform 0.2s;
}
.cell.head {
  aspect-ratio: auto;
  min-height: 28px;
  background: transparent;
  color: var(--teal-dark);
  font-weight: 700;
  font-size: 1rem;
}
.cell.marked {
  background: var(--teal);
  color: var(--paper);
}
.cell.free {
  background: var(--teal-dark);
  color: var(--paper);
}
.cell.hot {
  box-shadow: inset 0 0 0 3px var(--alert);
}
.cell.last {
  transform: scale(1.06);
  box-shadow: 0 0 0 3px var(--navy);
}

/* Grade 1–75 */
button.light,
.ghost.light {
  background: transparent;
  color: var(--mist);
  border: 2px solid rgba(255, 255, 255, 0.25);
}
.board-box {
  width: 100%;
}
.board {
  display: grid;
  grid-template-columns: auto repeat(15, 1fr);
  gap: 3px;
  width: 100%;
}
.board-letter {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal);
  font-weight: 700;
  padding-right: 4px;
}
.board-cell {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--mist);
}
.board-cell.marked {
  background: var(--teal);
  color: var(--paper);
  font-weight: 700;
}
.board-cell.last {
  outline: 2px solid var(--alert);
}
