.strategy-pack {
  --st-fern: #28785e;
  --st-amber: #b46a35;
  --st-ink: #274d42;
  --st-line: #b6c6b7;
  width: 100%;
  margin: 1.2rem auto 0;
}
.strategy-pack button {
  font: inherit;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.strategy-pack button:focus-visible {
  outline: 3px solid #3575a3;
  outline-offset: 2px;
  z-index: 4;
}
.strategy-pack button:not(:disabled) {
  cursor: pointer;
}
.strategy-pack button:not(:disabled):hover {
  filter: brightness(1.06);
}
.strategy-pack button:not(:disabled):active {
  transform: scale(0.94);
}
.strategy-pack button {
  transition:
    background-color 0.18s,
    box-shadow 0.18s,
    transform 0.15s;
}
.strategy-pack .st-player-0 {
  color: var(--st-fern);
}
.strategy-pack .st-player-1 {
  color: var(--st-amber);
}
.st-score {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  margin: 0 0 1rem;
  font-size: 0.85rem;
}
.st-score strong {
  font-size: 1.5rem;
  margin-left: 0.45rem;
}
.st-grid {
  display: grid;
  grid-template-columns: repeat(var(--st-cols), minmax(0, 1fr));
  width: min(100%, 430px);
  margin: auto;
  overflow: hidden;
  border: 1px solid var(--st-line);
  border-radius: 12px;
  background: #d0d9c9;
  gap: 1px;
}
.st-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  min-width: 0;
  padding: 0;
  border: 0;
  background: #f8f4e8;
  color: var(--st-ink);
}
.st-cell:disabled {
  opacity: 1;
}
.st-stone {
  font-size: clamp(17px, 3.8vw, 31px);
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.st-hint-dot {
  width: 12%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #50866b;
  opacity: 0.5;
}
.st-gomoku {
  border: 9px solid #d9c19a;
  background: #bbae8b;
  border-radius: 8px;
  gap: 1px;
}
.st-gomoku .st-cell {
  background: #f0dfbd;
  position: relative;
}
.st-gomoku .st-cell:empty:after {
  content: "+";
  color: #b29a78;
  font-weight: 300;
}
.st-gomoku .st-stone {
  font-size: clamp(16px, 3.8vw, 29px);
}
.st-reversi {
  border: 7px solid #285f4c;
  gap: 1px;
  background: #69997f;
}
.st-reversi .st-cell {
  background: #e0eadb;
}
.st-reversi .st-stone {
  width: 75%;
  height: 75%;
  border-radius: 50%;
  box-shadow:
    inset 0 -3px 0 #0002,
    0 2px 3px #0002;
  font-size: 0;
}
.st-reversi .st-player-0 .st-stone {
  background: var(--st-fern);
}
.st-reversi .st-player-1 .st-stone {
  background: #d58b49;
}
.st-dots {
  display: grid;
  grid-template-columns: 14px 1fr 14px 1fr 14px 1fr 14px;
  grid-template-rows: 14px 1fr 14px 1fr 14px 1fr 14px;
  width: min(90%, 370px);
  aspect-ratio: 1;
  margin: 1.5rem auto;
  align-items: stretch;
}
.st-dot {
  border-radius: 50%;
  background: #355b4a;
  z-index: 2;
}
.st-edge {
  position: relative;
  border: 0;
  background: transparent !important;
  padding: 0;
  overflow: visible;
}
.st-edge:before {
  content: "";
  position: absolute;
  inset: -8px;
  z-index: 1;
}
.st-edge span {
  display: block;
  border-radius: 5px;
  background: #d3ddcb;
  position: absolute;
}
.st-edge.horizontal span {
  height: 6px;
  top: 4px;
  width: 100%;
}
.st-edge.vertical span {
  width: 6px;
  left: 4px;
  height: 100%;
}
.st-edge:not(:disabled):hover span {
  background: #81a48d;
}
.st-edge.claimed.st-player-0 span {
  background: var(--st-fern);
}
.st-edge.claimed.st-player-1 span {
  background: var(--st-amber);
}
.st-box {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 3px;
  border-radius: 6px;
}
.st-box.st-player-0 {
  background: #dcebd8;
}
.st-box.st-player-1 {
  background: #f2dfc6;
}
.st-mancala {
  display: grid;
  grid-template-columns: minmax(36px, 1fr) 6fr minmax(36px, 1fr);
  gap: 6px;
  padding: 12px 8px;
  border-radius: 48px;
  background: #e9d4b0;
  border: 1px solid #c8ae81;
  max-width: 620px;
  margin: auto;
}
.st-pits {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px 5px;
}
.st-pit {
  border: 1px solid #c3aa83;
  border-radius: 50%;
  background: #f9ecd3;
  min-width: 0;
  min-height: 66px;
  padding: 5px 0;
  box-shadow: inset 0 3px 8px #82683a22;
}
.st-pit:not(:disabled) {
  outline: 2px solid #779b6b;
  outline-offset: 1px;
}
.st-pit strong {
  display: block;
  font-size: 1rem;
}
.st-seeds {
  display: block;
  font-size: 9px;
  line-height: 10px;
  width: 80%;
  margin: 0 auto 3px;
  overflow-wrap: anywhere;
  letter-spacing: 1px;
}
.st-store {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  text-align: center;
  border: 1px solid #c3aa83;
  border-radius: 45px;
  background: #debf8e;
  box-shadow: inset 0 3px 8px #82683a22;
}
.st-store strong {
  font-size: 1.5rem;
}
.st-store small {
  font-size: 9px;
}
.st-directions {
  text-align: center;
  font-size: 0.8rem;
  color: #718073;
  margin: 10px auto;
}
.st-checkers {
  background: #a9b6a2;
  border: 6px solid #728773;
}
.st-checkers .light {
  background: #eeeada;
}
.st-checkers .dark {
  background: #b4c5a9;
}
.st-checker {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 77%;
  height: 77%;
  border-radius: 50%;
  background: currentColor;
  box-shadow:
    inset 0 0 0 3px #ffffff5c,
    0 3px 0 #0002;
  font-size: 0;
}
.st-checker.king:after {
  content: "♛";
  font-size: clamp(18px, 5vw, 30px);
  color: #fff9de;
}
.st-checkers .st-player-0 .st-checker {
  color: #2d7959;
}
.st-checkers .st-player-1 .st-checker {
  color: #b76c3c;
}
.st-checkers .st-selectable .st-checker {
  outline: 2px solid #f9f5d4;
  outline-offset: 1px;
}
.st-checkers .selected {
  box-shadow: inset 0 0 0 4px #f2e295;
  background: #8fa788;
}
.st-checkers .destination {
  box-shadow: inset 0 0 0 3px #368669;
  background: #d8ead0;
}
.st-checkers .destination:empty:after {
  content: "○";
  font-size: 1.5rem;
  color: #3e7e61;
}
.st-nim {
  max-width: 420px;
  margin: auto;
  display: grid;
  gap: 14px;
}
.st-heap {
  border: 1px solid #dce3d4;
  padding: 17px;
  border-radius: 14px;
  background: #f5f5e9;
}
.st-nim-stones {
  display: flex;
  gap: 12px;
  justify-content: center;
  min-height: 37px;
  margin: 10px 0;
  color: var(--st-fern);
  font-size: 26px;
}
.st-nim-stones small {
  font-size: 13px;
}
.st-take {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
}
.st-take button {
  border: 1px solid #c8d5bb;
  border-radius: 8px;
  background: #fffdf3;
  color: #315d46;
  padding: 9px 11px;
  font-size: 12px;
}
.st-take button:disabled {
  opacity: 0.5;
}
.st-hex-legend {
  display: flex;
  gap: 2rem;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
}
.st-hex {
  width: min(100%, 440px);
  padding: 12px 0;
  margin: auto;
  --hex: calc(100% / 10.5);
}
.st-hex-row {
  display: flex;
  margin-left: calc(var(--st-row) * 4.65%);
  width: 70%;
  gap: 2px;
  margin-top: -2.3%;
}
.st-hex-cell {
  flex: 1 1 0;
  min-width: 0;
  aspect-ratio: 0.9;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  border: 0;
  padding: 0;
  background: #e1e5d2;
  color: #607860;
  font-size: 1.2rem;
}
.st-hex-cell.occupied.st-player-0 {
  background: #398266;
  color: #fff;
}
.st-hex-cell.occupied.st-player-1 {
  background: #c37c43;
  color: #fff;
}
.st-hex-row:first-child .st-hex-cell {
  box-shadow: inset 0 3px #398266;
}
.st-hex-row:last-child .st-hex-cell {
  box-shadow: inset 0 -3px #398266;
}
.st-hex-cell:first-child {
  border-left: 3px solid #c37c43;
}
.st-hex-cell:last-child {
  border-right: 3px solid #c37c43;
}
.st-seas {
  display: grid;
  gap: 25px;
}
.st-seas h3 {
  font-family: inherit !important;
  font-size: 1rem !important;
  margin: 0 0 4px !important;
}
.st-seas p {
  font-size: 0.78rem;
  color: #6c7b70;
  margin: 0 0 12px;
}
.st-sea {
  max-width: 350px;
  background: #b5d0d0;
  border: 5px solid #aac8c5;
  border-radius: 12px;
}
.st-sea .st-cell {
  background: #edf5ed;
  font-size: 1.5rem;
  color: #6e99a7;
}
.st-sea .st-coordinate {
  font-size: clamp(8px, 2vw, 10px);
  color: #769894;
}
.st-sea .hit {
  background: #f7d6b9;
  color: #a85330;
}
.st-sea .miss {
  background: #dae8e4;
}
.st-sea .ship {
  background: #7b9c8c;
  color: #f9faf2;
}
.st-sea .ship.hit {
  background: #c87955;
  color: #fff;
}
.st-fleet {
  max-width: 250px;
}
.st-fleet .st-cell {
  font-size: 1rem;
}
.st-phase {
  text-align: center;
  border-radius: 20px;
  background: #e4edde;
  padding: 9px 16px;
  width: max-content;
  max-width: 100%;
  margin: 0 auto 15px;
  font-size: 0.85rem;
}
.st-isolation {
  gap: 4px;
  background: #f1f1e2;
  border: 0;
  max-width: 360px;
}
.st-isolation .st-cell {
  border-radius: 7px;
  border: 1px solid #d8e0cb;
  background: #e8eedc;
}
.st-isolation .removed {
  background: #f7f6ed;
  border: 1px dashed #e1e2d5;
  box-shadow: inset 0 2px 6px #00000005;
}
.st-isolation .st-legal {
  background: #d7e6c8;
  border-color: #84a77a;
}
.st-isolation .st-pawn {
  font-size: 2rem;
}
.st-ultimate {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  max-width: 420px;
  margin: auto;
}
.st-mini-board {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2px;
  border: 2px solid #d8dfcc;
  border-radius: 8px;
  padding: 5px;
  background: #ebedde;
  overflow: hidden;
}
.st-mini-board.required {
  border-color: #77a27e;
  background: #dbe8d2;
}
.st-mini-cell {
  aspect-ratio: 1;
  border: 0;
  padding: 0;
  min-width: 0;
  background: #fffdf1;
  font-size: clamp(18px, 5vw, 29px) !important;
  display: flex;
  align-items: center;
  justify-content: center;
}
.st-mini-board.closed .st-mini-cell {
  opacity: 0.25;
}
.st-mini-result {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(50px, 18vw, 90px);
  background: #fffdf366;
  pointer-events: none;
}
.st-board-number {
  position: absolute;
  top: 1px;
  left: 2px;
  font-size: 9px;
  line-height: 1;
  color: #657a64;
  pointer-events: none;
}
.st-rules {
  max-width: 520px;
  margin: 20px auto;
  text-align: left;
  border-top: 1px solid #dce2d2;
  padding-top: 12px;
}
.st-rules summary {
  cursor: pointer;
  font-size: 0.83rem;
  font-weight: 600;
  color: #56775c;
  padding: 8px;
}
.st-rules p {
  font-size: 0.84rem;
  line-height: 1.65;
  padding: 0 8px;
  color: #637163;
}
.strategy-pack .game-notice {
  max-width: 480px;
  margin: 18px auto 0;
  font-size: 0.87rem;
  line-height: 1.6;
  min-height: 2em;
}
@media (min-width: 900px) {
  .st-seas {
    grid-template-columns: 1.2fr 1fr;
    align-items: start;
    gap: 15px;
  }
  .st-fleet {
    width: 100%;
  }
  .st-seas .st-coordinate {
    font-size: 8px;
  }
}
@media (max-width: 400px) {
  .st-mancala {
    padding: 10px 5px;
    gap: 4px;
  }
  .st-pits {
    gap: 6px 3px;
  }
  .st-pit {
    min-height: 58px;
  }
  .st-take button {
    padding: 9px;
  }
  .st-ultimate {
    gap: 5px;
  }
  .st-mini-board {
    padding: 3px;
    gap: 1px;
  }
  .st-checkers {
    border-width: 4px;
  }
  .st-seeds {
    font-size: 7px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .strategy-pack button {
    transition: none;
  }
}

.st-hex-row:first-child {
  margin-top: 0;
}
.st-hex-cell:focus-visible {
  background: #d4e6bc;
  box-shadow: inset 0 0 0 4px #3575a3;
}
.strategy-pack .st-checker.king:after {
  line-height: 1;
}
