#view-pool {
  display: none;
}

#view-pool.active {
  display: block;
}

.pool-card {
  padding: 1rem;
  margin-bottom: .9rem;
}

.pool-card h2 {
  margin-bottom: .35rem;
}

.pool-name-form,
.bonus-form {
  display: grid;
  gap: .75rem;
  margin: 1rem 0 .75rem;
}

.pool-name-form label,
.bonus-form label {
  display: grid;
  gap: .35rem;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 800;
}

.new-player-field {
  display: none !important;
}

.new-player-field.show {
  display: grid !important;
}

.pool-name-form input,
.pool-name-form select,
.pool-prediction-form input,
.pool-result-form input,
.bonus-form input,
.bonus-form select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: .8rem;
  background: var(--card);
  color: var(--ink);
  font-weight: 800;
  min-height: 48px;
}

.pool-name-form .primary,
.bonus-form .primary,
.bonus-form .secondary {
  width: 100%;
}

.bonus-host-details,
.host-result-details {
  margin-top: 1rem;
}

.player-management {
  display: grid;
  gap: .55rem;
  margin-top: .8rem;
}

.player-management div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .75rem;
  padding: .65rem .7rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,237,213,.35);
}

.danger-mini {
  border: 1px solid #b91c1c;
  background: #dc2626;
  color: #fff;
  border-radius: 999px;
  padding: .4rem .65rem;
  font-weight: 900;
  font-size: .78rem;
}

.pool-match {
  margin-bottom: .9rem;
}

.pool-prediction-form,
.pool-result-form {
  margin-top: .9rem;
  grid-template-columns: 1fr 1fr;
  align-items: end;
}

.pool-prediction-form .small-btn,
.pool-result-form .small-btn {
  min-height: 46px;
}

.pool-prediction-form [data-delete-prediction],
.pool-result-form [data-delete-result] {
  background: #fff7ed;
  color: var(--grass);
  border: 1px solid var(--line);
}

.prediction-overview {
  display: grid;
  gap: .45rem;
  margin-top: .65rem;
}

.prediction-overview div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: .55rem .65rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,237,213,.35);
}

.prediction-overview span {
  font-weight: 900;
  color: var(--grass);
}

@media (min-width: 520px) {
  .pool-name-form {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
    align-items: end;
  }

  .pool-name-form .primary {
    width: auto;
  }

  .bonus-form {
    grid-template-columns: 1fr 1fr auto;
    align-items: end;
  }

  .bonus-form .primary,
  .bonus-form .secondary {
    width: auto;
  }

  .pool-prediction-form,
  .pool-result-form {
    grid-template-columns: 1fr 1fr auto auto;
  }
}

@media (prefers-color-scheme: dark) {
  .pool-name-form input,
  .pool-name-form select,
  .pool-prediction-form input,
  .pool-result-form input,
  .bonus-form input,
  .bonus-form select {
    background: #1a0f08;
  }

  .pool-prediction-form [data-delete-prediction],
  .pool-result-form [data-delete-result] {
    background: #2a170d;
  }

  .prediction-overview div,
  .player-management div {
    background: rgba(42,23,13,.58);
  }
}
