#game {
  --match-gold: #f4cb70;
  --match-wash: #edf5e8;
  --match-line: #d3e5d7;
  --match-muted: #466156;
  display: grid;
  gap: 1rem;
  max-width: 48rem;
  margin-inline: auto;
}

.match-options {
  min-inline-size: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.match-options legend {
  margin: 0 0 .45rem;
  padding: 0;
  font-weight: 800;
}

.match-options > div {
  display: flex;
  gap: .4rem;
}

.match-options label {
  flex: 1 1 0;
  display: flex;
  position: relative;
  min-width: 0;
}

.match-options input {
  position: absolute;
  inset: 0;
  width: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.match-options label span {
  display: grid;
  flex: 1;
  min-height: 48px;
  place-items: center;
  padding: .4rem .2rem;
  border: 1px solid var(--match-line);
  border-radius: .7rem;
  background-color: #fffdf6;
  color: var(--game-ink, #18483d);
  font-weight: 750;
}

.match-options input:checked + span {
  border-color: var(--game-accent, #206554);
  background: var(--game-tint, #e4f2e8);
  box-shadow: inset 0 0 0 1px var(--game-accent, #206554);
}

.match-options input:focus-visible + span {
  outline: 3px solid var(--game-ink, #18483d);
  outline-offset: 3px;
}

.match-note {
  margin: .3rem 0 0;
  color: var(--match-muted);
  font-size: .88rem;
}

.match-help {
  border-top: 1px solid var(--match-line);
}

.match-help summary {
  display: list-item;
  min-height: 44px;
  padding: .65rem 0;
  color: var(--game-accent, #206554);
  cursor: pointer;
  font-weight: 800;
}

.match-help p {
  margin: 0 0 .6rem;
  color: var(--match-muted);
  font-size: .92rem;
}

.match-secret-name-grid {
  display: grid;
  min-width: 0;
  gap: .75rem;
}

.match-secret-names {
  min-width: 0;
  padding: 0 .75rem;
  border: 1px solid var(--match-line, #d3e5d7);
  border-radius: .7rem;
  background: #fffdf6;
}

.match-secret-names summary {
  min-height: 48px;
  padding: .7rem 0;
  color: var(--game-ink, #18483d);
  font-weight: 750;
  cursor: pointer;
}

.match-secret-names summary span {
  color: var(--match-muted, #466156);
  font-size: .8rem;
  font-weight: 650;
}

.match-secret-name-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: .55rem;
  padding-bottom: .75rem;
}

.match-secret-name-grid label {
  display: grid;
  min-width: 0;
  gap: .3rem;
  font-weight: 750;
  font-size: .9rem;
}

.match-secret-name-grid input {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: .5rem .65rem;
  border: 1px solid #9ab6a7;
  border-radius: .65rem;
  background: #fffefa;
  color: var(--game-ink, #18483d);
  font: inherit;
  font-size: 1rem;
}

.match-secret-names:not([open]) > :not(summary) {
  display: none;
}

@media (min-width: 620px) {
  .match-secret-name-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
