@font-face {
  font-family: PaijuRound;
  src: url("assets/round.woff") format("woff");
  font-display: swap;
}
:root {
  color-scheme: light;
  --ink: #383525;
  --paper: #fbf6e8;
  --edge: #d9ceb0;
  --green: #275c49;
  --red: #cf473d;
  --sans: "Nunito", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --title: PaijuRound, "Microsoft YaHei", sans-serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.45 var(--sans);
  background-image: radial-gradient(
    ellipse at 40% 0%,
    #fffcf4,
    transparent 72%
  );
}
button,
input {
  font: inherit;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  cursor: default;
}
button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: 3px solid #e78b39;
  outline-offset: 3px;
}
button {
  touch-action: manipulation;
}
button:active:not(:disabled) {
  filter: brightness(0.95);
}
[hidden] {
  display: none !important;
}
i[data-icon] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.15em;
  height: 1.15em;
  flex-shrink: 0;
}
i svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.shell {
  max-width: 1320px;
  width: calc(100% - clamp(32px, 8vw, 128px));
  margin: 0 auto;
  padding-bottom: 40px;
}
.mast {
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.identity {
  display: flex;
  align-items: center;
  gap: 10px;
}
.identity img {
  width: 49px;
  height: 49px;
}
.identity h1,
.library h2,
dialog h2 {
  font-family: var(--title);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.025em;
  margin: 0;
}
.identity h1 {
  font-size: clamp(25px, 3vw, 38px);
  color: #303d32;
}
.rule-link,
.tool,
.sun-btn,
.felt-btn,
.quiet-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: 10px;
  line-height: 1.3;
}
.rule-link {
  background: #fffaf0;
  border: 1px solid var(--edge);
  padding: 8px 13px;
  font-size: 14px;
  color: #575943;
  font-weight: 600;
}
.rule-link:hover,
.quiet-btn:hover {
  background: #f4ecd8;
}
.board {
  isolation: isolate;
  position: relative;
  overflow: hidden;
  border: 3px solid #8c8260;
  border-bottom: 5px solid #827651;
  border-radius: 24px;
  height: clamp(506px, 38.8vw, 555px);
  background: #309561 url("assets/courtyard.webp") center 48% / cover no-repeat;
  box-shadow:
    0 4px 0 #d9d1b7,
    0 8px 22px #594c2712;
}
.board:after {
  content: "";
  inset: 0;
  position: absolute;
  pointer-events: none;
  border-radius: 21px;
  box-shadow: inset 0 0 0 2px #ffefc34f;
  z-index: 7;
}
.controls {
  position: absolute;
  left: 22px;
  top: 22px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
  z-index: 6;
}
.tool,
.sun-btn,
.felt-btn {
  border: 1.6px solid #725637;
  font-size: 15px;
  font-weight: 750;
  box-shadow:
    0 3px 0 #68502fb3,
    0 4px 6px #38472622;
  min-height: 41px;
  padding: 8px 16px;
  transition:
    filter 0.15s,
    translate 0.15s;
}
.tool:hover:not(:disabled),
.sun-btn:hover:not(:disabled),
.felt-btn:hover:not(:disabled) {
  filter: brightness(1.06);
  translate: 0 -1px;
}
.tool {
  min-width: 124px;
}
.tool.edit,
.sun-btn {
  background: linear-gradient(#ffe997, #ffcc65);
  color: #503c23;
  border-color: #9c7138;
}
.tool.lead,
.tool.judge,
.tool.hint,
.tool.restart {
  background: #fff7e4;
  color: #384d3e;
  border-color: #9e977a;
}
.analysis-actions {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.tool:disabled {
  color: #6f725f;
  background: #eee8d5;
  border-color: #a8a38b;
  box-shadow: 0 2px 0 #7e806460;
}
.hint[aria-pressed="true"] {
  background: #306d53;
  color: #fff6d7;
  border-color: #21513e;
}
.opponent {
  --sprite: clamp(228px, 18.3vw, 257px);
  position: absolute;
  width: var(--sprite);
  height: var(--sprite);
  left: 50%;
  top: 9px;
  transform: translateX(-50%);
  z-index: 2;
}
.landlord-art,
.grip {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}
.landlord-art {
  filter: drop-shadow(0 3px 2px #153a2929);
}
.grip {
  z-index: 1;
}
.held-hand {
  position: absolute;
  bottom: 3.5%;
  height: 30%;
  width: 100%;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.fan {
  position: relative;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.playing-card {
  position: relative;
  display: inline-block;
  width: var(--cw);
  height: calc(var(--cw) * 1.34);
  flex: 0 0 var(--cw);
  border-radius: calc(var(--cw) * 0.115);
  border: 1.5px solid #a0957d;
  background: linear-gradient(130deg, #fffef9 30%, #fff5d9);
  color: #263a49;
  padding: 0;
  box-shadow:
    0 2px 0 #a59170,
    0 3px 5px #16392944;
  text-align: left;
  vertical-align: bottom;
}
.playing-card.red,
.red {
  color: var(--red);
}
.corner-rank,
.corner-suit {
  position: absolute;
  left: 7%;
  display: block;
  z-index: 1;
}
.corner-rank {
  top: 8%;
  font-size: calc(var(--cw) * 0.32);
}
.corner-suit {
  top: 35%;
  font-size: calc(var(--cw) * 0.15);
}
.pip-art {
  position: absolute;
  bottom: 8%;
  right: 7%;
  width: 59%;
  height: 50%;
  object-fit: contain;
  pointer-events: none;
}
.joker .corner-rank {
  top: 7%;
  font-size: calc(var(--cw) * 0.43);
}
.joker .corner-suit {
  top: 44%;
  font-size: calc(var(--cw) * 0.12);
}
.fan .playing-card {
  position: absolute;
  left: calc(50% + var(--offset));
  bottom: 0;
  transform: translate(-50%, var(--drop)) rotate(var(--tilt));
  transform-origin: 50% 90%;
  box-shadow: 0 1px 2px #36311e60;
}
.fan .corner-rank {
  font-size: calc(var(--cw) * 0.34);
}
.fan .joker .corner-rank {
  font-size: calc(var(--cw) * 0.44);
}
.ghost {
  display: inline-flex;
  position: relative;
  isolation: isolate;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  border: 2px dashed #e4f5d8ba;
  background: #d4ffd522;
  color: #f3ffdf;
  box-shadow: inset 0 0 0 4px #e7ffdd12;
  cursor: pointer;
}
.ghost:hover {
  background: #e8ffe03d;
}
.ghost span {
  font:
    400 40px/1 Arial,
    sans-serif;
}
.me-ghost {
  width: 86px;
  height: 113px;
}
.landlord-ghost {
  width: 42%;
  height: 92%;
  border-color: #fff0bcbf;
  background: #8c774b80;
  transform: rotate(-2deg);
}
.landlord-ghost span {
  font-size: 30px;
}
.midtable {
  position: absolute;
  top: 48.5%;
  left: 2%;
  width: 96%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #fff7dd;
  pointer-events: none;
}
.turn-note {
  color: #f9ffe5;
  font-weight: 750;
  font-size: 14px;
  text-shadow: 0 1px 3px #18402e;
  border-radius: 20px;
  padding: 3px 12px;
  background: #205d3da3;
}
.recent {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px 18px;
  flex-wrap: wrap;
}
.trick-group {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  justify-content: center;
}
.trick-seat {
  font-size: 13px;
  color: #fff9df;
  font-weight: 700;
  text-shadow: 0 1px 3px #173c2d;
}
.trick-cards {
  display: inline-flex;
  gap: 2px;
  flex-wrap: wrap;
  justify-content: center;
}
.trick-card {
  border-radius: 4px;
  background: #fff6de;
  color: #263a49;
  box-shadow: 0 1px 1px #30593f;
  font: 800 17px/1.2 var(--sans);
  padding: 2px 5px;
}
.trick-card.red {
  color: var(--red);
}
.pass-word {
  color: #ffebad;
}
.player {
  position: absolute;
  bottom: 21px;
  left: 0;
  width: 100%;
  z-index: 4;
  text-align: center;
  pointer-events: none;
}
.player-hand {
  width: calc(100% - 38px);
  margin: auto;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 14px 8px 6px;
  scrollbar-width: thin;
  scrollbar-color: #cfe3ab88 transparent;
  pointer-events: auto;
}
.my-row {
  --cw: 88px;
  display: flex;
  align-items: flex-end;
  margin: 0 auto;
  height: calc(var(--cw) * 1.34 + 2px);
}
.my-row .playing-card + .playing-card {
  margin-left: calc(var(--step) - var(--cw));
}
.my-row button.playing-card:hover:not(.picked) {
  transform: translateY(-4px);
}
.playing-card.picked {
  transform: translateY(-10px);
  border-color: #ffc537;
  box-shadow:
    0 0 0 2px #ffe386,
    0 3px 0 #976e23;
}
.playing-card.picked:after {
  content: "";
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='m4 9 3 3 7-7' fill='none' stroke='%234e421d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  position: absolute;
  bottom: 3%;
  right: 4%;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: #ffd56c;
  text-align: center;
  font: bold 14px/18px sans-serif;
  color: #4e421d;
}
.player-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  min-height: 29px;
  margin-top: 3px;
  pointer-events: none;
}
.player-footer button {
  pointer-events: auto;
  min-width: 88px;
  min-height: 36px;
  padding: 6px 14px;
}
.your-label {
  font-size: 15px;
  color: #effbe2;
  letter-spacing: 0.08em;
  font-weight: 700;
  text-shadow: 0 1px 2px #265f3f;
}
.felt-btn {
  background: #397d58;
  color: #fff5d5;
  border-color: #b5d39c;
  box-shadow: 0 2px 0 #285d42;
}
.felt-btn:disabled,
.sun-btn:disabled {
  filter: saturate(0.3);
  opacity: 0.58;
}
.library {
  margin-top: 26px;
}
.library-heading {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
}
.library h2,
dialog h2 {
  font-size: 27px;
}
.book-icon {
  display: inline-flex;
  color: #49795d;
  align-items: center;
  font-size: 21px;
}
.cases {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.case {
  min-width: 0;
  background: #fffdf5;
  border: 1.5px solid #d8ceb4;
  border-radius: 14px;
  padding: 13px 15px 15px;
  text-align: left;
  box-shadow: 0 3px 0 #e9dfc7;
  transition:
    background 0.15s,
    border-color 0.15s;
}
.case:hover,
.case.active {
  background: #fff9e8;
  border-color: #a9ad82;
}
.case-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.case-head strong {
  font-size: 18px;
  letter-spacing: 0.015em;
}
.case-action {
  font: 700 21px/20px var(--sans);
  color: #637c59;
}
.case-line {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
}
.seat {
  font-size: 13px;
  font-weight: 650;
  color: #737664;
  flex: none;
}
.case-cards {
  display: flex;
  flex: 1;
  min-width: 0;
  gap: 2px;
}
.tiny-card {
  display: inline-flex;
  flex: 0 1 25px;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 34px;
  border-radius: 4px;
  border: 1px solid #ddd2ba;
  background: #fffcf2;
  box-shadow: 0 1px 0 #e9ddc6;
  color: #263a49;
}
.tiny-card.red {
  color: var(--red);
}
.tiny-card .mini-rank {
  font-size: 13px;
  max-width: 95%;
}
.tiny-card .mini-suit {
  font-size: 8px;
  margin-top: 2px;
}
.tiny-card.joker .mini-rank {
  font-size: 9px;
}
.analysis-panel {
  padding: 14px 16px 15px;
  border: 2px solid #ba853b;
  border-radius: 13px;
  box-shadow:
    0 3px 0 #8d703b61,
    0 5px 14px #433d2424;
  background: #fffae9;
  color: #3e412e;
}
.analysis-panel h3,
.analysis-panel p {
  margin: 4px 0;
  font-size: 15px;
}
.analysis-panel #feedback {
  font-weight: 750;
}
#feedback:not([hidden]) + #strategies:not([hidden]) {
  margin-top: 6px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}
.strategy-chip,
.quiet-btn {
  background: #fffbed;
  border: 1px solid #bfc5a8;
  padding: 5px 10px;
  font-size: 14px;
  border-radius: 7px;
}
.strategy-chip {
  font-weight: 700;
}
dialog {
  background: #fff9eb;
  color: var(--ink);
  width: min(715px, calc(100% - 24px));
  max-height: 90dvh;
  overflow-y: auto;
  border: 2px solid #b5aa88;
  border-radius: 18px;
  padding: 23px;
  box-shadow:
    0 8px 0 #72674755,
    0 15px 80px #27392655;
}
dialog::backdrop {
  background: #24382cca;
  backdrop-filter: blur(3px);
}
.dialog-head,
.dialog-foot,
.field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.close {
  border: 0;
  border-radius: 50%;
  background: #eee8d4;
  color: #58624e;
  width: 30px;
  height: 30px;
  font: 24px/1 Arial;
}
.editor-help {
  font-size: 14px;
  color: #696b59;
  margin: 9px 0 15px;
}
.edit-side {
  padding: 13px 0 15px;
  border-top: 1px solid #ded5be;
}
.field-head {
  justify-content: flex-start;
  gap: 9px;
}
.field-label {
  font-weight: 750;
  font-size: 17px;
}
.count {
  color: #77796a;
  font-size: 13px;
}
.clear {
  margin-left: auto;
  border: 0;
  background: none;
  color: #667957;
  font-size: 13px;
}
.hand-input {
  width: 100%;
  margin: 8px 0 12px;
  border: 1px solid #beb59b;
  background: #fffef9;
  border-radius: 8px;
  padding: 9px 11px;
  color: #283c30;
}
.picker {
  display: grid;
  grid-template-columns: repeat(15, minmax(0, 1fr));
  gap: 4px;
}
.pick-card {
  position: relative;
  min-width: 0;
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  padding: 3px 0 2px;
  height: 52px;
  background: #fffdf4;
  border: 1px solid #c8bca0;
  border-bottom: 2px solid #b7a888;
  border-radius: 6px;
  color: #c9433b;
}
.pick-card .picker-rank {
  font-size: 16px;
}
.pick-card:nth-last-child(-n + 2) .picker-rank {
  font-size: 12px;
  color: #525e75;
}
.picker-pip {
  width: 20px;
  height: 20px;
  object-fit: contain;
  margin-top: 2px;
}
.pick-card.chosen {
  border-color: #789e79;
  background: #e5f2d8;
}
.pick-card:disabled {
  opacity: 0.38;
}
.quantity {
  position: absolute;
  top: -6px;
  right: -2px;
  background: #376944;
  border-radius: 50%;
  color: white;
  font: bold 11px/15px Arial;
  min-width: 15px;
  padding: 0 2px;
  box-shadow: 0 0 0 1px #fff7e3;
}
.dialog-foot {
  margin-top: 9px;
  padding-top: 13px;
  border-top: 1px solid var(--edge);
}
.quiet-btn {
  font-weight: 600;
  min-height: 34px;
}
.error {
  color: #a43529;
  font-size: 14px;
  margin: 3px 0;
}
.credit {
  font-size: 13px;
  color: #627349;
}
#rules {
  max-width: 500px;
}
#rules h3 {
  font-size: 17px;
  margin-bottom: 4px;
}
#rules p {
  font-size: 15px;
  margin: 8px 0;
}
#rules a {
  color: inherit;
}
@media (min-width: 1540px) {
  .board {
    height: 575px;
  }
  .my-row {
    --cw: 94px;
  }
}
@media (max-width: 1000px) {
  .shell {
    width: calc(100% - 34px);
  }
  .case {
    padding: 11px 10px;
  }
  .cases {
    gap: 9px;
  }
  .case-line {
    gap: 4px;
  }
  .case-cards {
    gap: 1px;
  }
  .tiny-card {
    height: 30px;
  }
  .tiny-card .mini-rank {
    font-size: 14px;
  }
  .controls {
    left: 15px;
    top: 15px;
  }
  .my-row {
    --cw: 80px;
  }
}
@media (max-width: 760px) {
  .shell {
    width: calc(100% - 24px);
  }
  .mast {
    height: 66px;
  }
  .identity {
    gap: 5px;
  }
  .identity img {
    width: 40px;
    height: 40px;
  }
  .identity h1 {
    font-size: 27px;
  }
  .rule-link {
    font-size: 13px;
    padding: 6px 8px;
  }
  .board {
    height: 504px;
    border-radius: 18px;
  }
  .board:after {
    border-radius: 15px;
  }
  .cases {
    grid-template-columns: 1fr;
  }
  .case {
    padding: 12px 16px;
  }
  .case-cards {
    gap: 3px;
  }
  .tiny-card {
    height: 33px;
    flex-basis: 26px;
  }
  .tiny-card .mini-rank {
    font-size: 16px;
  }
  .library {
    margin-top: 23px;
  }
  .library h2 {
    font-size: 25px;
  }
  .case-head {
    margin-bottom: 5px;
  }
  .my-row {
    --cw: 76px;
  }
  .tool {
    min-width: 113px;
    padding: 7px 11px;
    font-size: 14px;
  }
  .picker {
    grid-template-columns: repeat(8, minmax(0, 1fr));
    row-gap: 9px;
  }
}
@media (max-width: 599px) {
  .shell {
    width: calc(100% - 18px);
  }
  .mast {
    height: 60px;
  }
  .identity h1 {
    font-size: clamp(19px, 5.6vw, 27px);
  }
  .identity img {
    width: 34px;
    height: 34px;
  }
  .rule-link {
    font-size: 12px;
  }
  .board {
    height: 526px;
    background-size: auto 100%;
    background-position: 50% 50%;
    border-width: 2px 2px 4px;
  }
  .controls {
    display: contents;
  }
  .tool {
    min-width: 94px;
    min-height: 35px;
    font-size: 13px;
    border-radius: 9px;
    padding: 7px 9px;
    gap: 4px;
  }
  .tool.edit,
  .tool.lead {
    position: absolute;
    left: 10px;
    z-index: 6;
  }
  .tool.edit {
    top: 12px;
  }
  .tool.lead {
    top: 57px;
  }
  .analysis-actions {
    position: absolute;
    bottom: 12px;
    left: 0;
    width: 100%;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    gap: 9px;
    z-index: 6;
  }
  .analysis-actions > .tool {
    min-width: 110px;
  }
  .opponent {
    --sprite: 198px;
    left: 55%;
    top: 11px;
  }
  .midtable {
    top: 43.5%;
    gap: 4px;
  }
  .turn-note {
    font-size: 13px;
  }
  .player {
    bottom: 65px;
  }
  .player-hand {
    width: 100%;
    padding-left: 5px;
    padding-right: 5px;
  }
  .my-row {
    --cw: 69px;
  }
  .me-ghost {
    width: 75px;
    height: 101px;
  }
  .recent {
    gap: 4px 12px;
  }
  .trick-cards {
    gap: 1px;
  }
  .trick-card {
    font-size: 14px;
    padding: 2px 3px;
  }
  .player-footer button {
    min-width: 73px;
    font-size: 14px;
    min-height: 33px;
  }
  .library-heading {
    padding-left: 3px;
  }
  .case {
    border-radius: 11px;
  }
  .library {
    margin-top: 20px;
  }
  dialog {
    padding: 15px;
  }
  dialog h2 {
    font-size: 24px;
  }
  .pick-card {
    height: 45px;
  }
  .edit-side {
    padding: 10px 0 12px;
  }
  .hand-input {
    margin: 6px 0 9px;
  }
  .editor-help {
    margin: 7px 0 10px;
  }
  .picker {
    gap: 7px 4px;
  }
  .picker-pip {
    width: 17px;
    height: 17px;
  }
}
@media (max-width: 370px) {
  .identity h1 {
    font-size: 19px;
  }
  .tool.edit,
  .tool.lead {
    left: 6px;
  }
  .opponent {
    --sprite: 186px;
    left: 57%;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
.playing-card.ten .corner-rank {
  font-size: calc(var(--cw) * 0.265);
  top: 8%;
}
.held-hand {
  bottom: 5%;
}
#record {
  margin-top: 12px;
  color: #526249;
  font-size: 14px;
}
#record summary {
  cursor: pointer;
  font-weight: 650;
}
#history {
  margin: 7px 0;
  padding-left: 2em;
}
@media (max-width: 599px) {
  .opponent {
    top: 33px;
    --sprite: 202px;
  }
  .opponent.wide-fan {
    left: 50%;
  }
  .midtable {
    top: 47%;
  }
}

.board,
.analysis-panel,
.library,
dialog,
#record,
.mast {
  user-select: none;
  -webkit-user-select: none;
}
.hand-input {
  user-select: text;
  -webkit-user-select: text;
}
img,
.card-glyph {
  -webkit-user-drag: none;
}
.card-glyph {
  fill: currentColor;
  pointer-events: none;
  flex-shrink: 0;
  vertical-align: middle;
}
.move-art {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.23em;
  vertical-align: middle;
}
.move-art .card-glyph {
  font-size: 0.9em;
}
.trick-card {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
}
.trick-card .card-glyph {
  font-size: 0.82em;
}
.quantity {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 15px;
}
.quantity .card-glyph {
  font-size: 9px;
}
.table-wrap {
  position: relative;
}
.notice-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
  color: #7a4e1e;
  font-weight: 800;
  margin: 0 0 7px;
}
.notice-title i {
  color: #815723;
  border-radius: 8px;
  background: #ffe29b;
  width: 27px;
  height: 27px;
  padding: 4px;
}
.analysis-panel #feedback {
  font-size: 17px;
}
.sources summary {
  cursor: pointer;
  color: #53694d;
}
.sources li {
  margin: 5px 0;
}
@media (min-width: 850px) {
  .table-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }
  .table-wrap > * {
    grid-area: 1 / 1;
  }
  .table-wrap .board {
    min-height: clamp(506px, 38.8vw, 555px);
    height: auto;
  }
  .analysis-panel {
    z-index: 8;
    place-self: start end;
    width: clamp(205px, 21%, 294px);
    /* Reserve the bottom of the table for the hand and its controls. */
    margin: 19px 19px 220px;
  }
  .strategy-chip {
    max-width: 100%;
  }
}
@media (min-width: 1540px) {
  .table-wrap .board {
    min-height: 575px;
  }
}
@media (max-width: 849px) {
  .analysis-panel {
    margin-top: 11px;
    border-left: 6px solid #d09134;
    background: #fff2c9;
    scroll-margin-bottom: 12px;
  }
  .analysis-panel .notice-title {
    font-size: 16px;
  }
}
@media (max-width: 599px) {
  .tool.restart {
    position: absolute;
    left: 10px;
    top: 102px;
    z-index: 6;
  }
}
