#stage.morris-stage {
  display: grid;
  place-items: center;
  padding: 0.75rem;
}

.morris {
  position: relative;
  width: min(92%, 420px);
  aspect-ratio: 1;
}

.morris svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--muted);
}

.morris svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 0.045;
  stroke-linecap: square;
}

.points {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
}

.point {
  place-self: center;
  z-index: 1;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 50%;
  border: 2px solid var(--muted);
  background: var(--board);
  color: transparent;
  font-family: var(--font-display);
  font-size: 1.55rem;
  line-height: 1;
  letter-spacing: 0.04em;
  cursor: pointer;
}

.point.x,
.point.o {
  color: var(--ink);
}

.point.x {
  background: var(--acid);
  border-color: var(--acid);
}

.point.o {
  background: var(--paper);
  border-color: var(--paper);
}

.point.selected {
  box-shadow: 0 0 0 3px var(--ink);
}

.point.open {
  border-color: var(--acid);
  background: color-mix(in srgb, var(--acid) 28%, var(--board));
}

.point.win {
  box-shadow: 0 0 0 3px var(--acid);
}

.point:disabled {
  cursor: default;
}

.morris[hidden],
.morris-setup[hidden] {
  display: none !important;
}

.morris-setup {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  height: 100%;
  padding: 1rem;
  text-align: center;
}

.morris-setup-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 2rem;
  letter-spacing: 0.04em;
  color: var(--paper);
}

.morris-pad {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
  width: min(100%, 280px);
}

.morris-pad button {
  min-width: 7rem;
  padding: 0.75rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--paper);
  font: 500 1rem/1 "DM Sans", sans-serif;
  cursor: pointer;
}

.morris-pad button:hover {
  border-color: var(--acid);
  color: var(--acid);
}

.hud select {
  background: var(--panel);
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.2rem 0.35rem;
  font: inherit;
  margin-left: 0.35rem;
}
