.softmatch-stage {
  display: flex;
  flex-direction: column;
  padding: 14px;
  background:
    radial-gradient(ellipse at top, rgba(168, 213, 206, 0.25), transparent 55%),
    var(--surface-elevated);
}

.softmatch-hud {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--ink-muted);
  margin-bottom: 12px;
  flex-shrink: 0;
}

.softmatch-hud strong {
  color: var(--ink);
}

.softmatch-board {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
  gap: 10px;
  min-height: 0;
}

.tile {
  position: relative;
  border: none;
  padding: 0;
  border-radius: 14px;
  cursor: pointer;
  background: transparent;
  perspective: 600px;
  -webkit-tap-highlight-color: transparent;
}

.tile:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.tile-inner {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  transform-style: preserve-3d;
  transition: transform 0.35s var(--ease-out);
  box-shadow: 0 4px 14px var(--shadow);
}

.tile.is-flipped .tile-inner,
.tile.is-matched .tile-inner {
  transform: rotateY(180deg);
}

.tile-face {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  backface-visibility: hidden;
  display: grid;
  place-items: center;
}

.tile-back {
  background: linear-gradient(145deg, #d7e2ec, #c5d3e0);
}

.tile-back::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
}

.tile-front {
  transform: rotateY(180deg);
  background: var(--tile-color, #a8d5ce);
}

.tile-front::after {
  content: "";
  width: 28%;
  height: 28%;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}

.tile.is-matched {
  pointer-events: none;
}

.tile.is-matched .tile-inner {
  box-shadow: 0 0 0 2px rgba(47, 143, 132, 0.35);
}

.tile:disabled {
  cursor: default;
}

@media (prefers-reduced-motion: reduce) {
  .tile-inner {
    transition: none;
  }
}
