:root {
  font-family:
    Inter,
    ui-sans-serif,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #28493e;
  background: #f6f7f2;
  font-synthesis: none;
  --green: #285b48;
  --muted: #6d7e74;
  --line: #e0e6dd;
  --cream: #f6f7f2;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input {
  font: inherit;
}
button,
a,
input {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  cursor: default;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #cf8b36;
  outline-offset: 5px;
}
button {
  transition:
    background 0.2s,
    transform 0.2s,
    box-shadow 0.2s;
}
button:not(:disabled):active {
  transform: translateY(2px);
}
a {
  color: inherit;
  text-decoration: none;
}
.topbar {
  max-width: 1456px;
  margin: auto;
  padding: 26px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  font:
    700 33px Georgia,
    serif;
  letter-spacing: -1.7px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.brand-mark {
  font: 38px system-ui;
  color: #69905a;
  line-height: 1;
}
.brand-dot {
  color: #dc9766;
  margin-left: -9px;
}
.header-note {
  font-size: 14px;
  color: var(--muted);
  margin-right: 63px;
}
.icon-button {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 50px;
  min-height: 42px;
  min-width: 42px;
  padding: 9px 14px;
  font-size: 17px;
}
.icon-button span {
  font-size: 13px;
  margin-left: 4px;
}
.icon-button:hover {
  background: #e8eee5;
}
#app {
  max-width: 1456px;
  margin: auto;
  padding: 10px 48px 0;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 342px;
  gap: 24px;
  align-items: stretch;
}
.garden-scene {
  border-radius: 24px;
  overflow: hidden;
  position: relative;
  min-height: 510px;
  background: #b9dcdb;
}
.garden-scene > img {
  width: 100%;
  height: 100%;
  position: absolute;
  object-fit: cover;
  object-position: 48% 58%;
}
.scene-heading {
  position: absolute;
  left: 30px;
  top: 27px;
  text-shadow: 0 1px 12px #e0f3ed;
}
.eyebrow {
  display: block;
  font-size: 11px;
  letter-spacing: 1.8px;
  font-weight: 700;
  line-height: 1.7;
}
.scene-heading .eyebrow {
  font-size: 11px;
  color: #315e54;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  letter-spacing: -0.8px;
}
h1 {
  font-size: 43px;
  line-height: 1.12;
  margin-top: 7px;
}
.scene-label {
  position: absolute;
  bottom: 23px;
  left: 24px;
  background: #ffffffdd;
  border: 1px solid #ffffff80;
  border-radius: 40px;
  padding: 11px 16px;
  font-size: 13px;
  backdrop-filter: blur(10px);
}
.scene-label span {
  color: #4d8461;
  font-size: 20px;
  vertical-align: middle;
  margin-right: 5px;
}
.scene-help {
  position: absolute;
  right: 20px;
  bottom: 22px;
  background: #ffffffca;
  border-color: #ffffff80;
}
.side-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fffefa;
  padding: 30px 28px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.mini-icon {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: #eef2e7;
  color: #678153;
  display: grid;
  place-items: center;
  font-size: 32px;
  margin-bottom: 21px;
}
.side-card .eyebrow {
  color: #77836b;
}
.side-card h2 {
  font-size: 33px;
  line-height: 1.12;
  margin: 10px 0 14px;
}
.side-card > p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
}
.side-card label {
  font-size: 13px;
  font-weight: 600;
  margin: 24px 0 8px;
}
input {
  width: 100%;
  background: #fffefb;
  border: 1px solid #dce3d8;
  border-radius: 10px;
  min-height: 46px;
  padding: 12px 14px;
  color: var(--green);
  outline: none;
  font-size: 16px;
}
input:focus {
  border-color: #5f8b6c;
  box-shadow: 0 0 0 3px #dbe8d6;
}
input::placeholder {
  color: #97a097;
}
.primary,
.secondary {
  border: 0;
  border-radius: 11px;
  padding: 15px 18px;
  font-size: 14px;
  font-weight: 600;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--green);
  color: white;
}
.primary:hover {
  background: #1e4939;
  box-shadow: 0 4px 16px #285b4820;
}
.primary:disabled {
  opacity: 0.65;
}
.side-card > .primary,
.side-card > .secondary {
  width: 100%;
  margin-top: 12px;
}
.secondary {
  color: var(--green);
  background: #edf1e7;
}
.primary span {
  font-size: 20px;
}
.text-button {
  border: 0;
  background: transparent;
  font-size: 14px;
  padding: 10px 0;
  min-height: 40px;
}
.text-button:hover {
  color: #a96a36;
}
.side-card > .text-button {
  align-self: center;
  margin: 6px 0;
}
.text-button span {
  margin-left: 6px;
}
.quiet-note {
  font-size: 12px;
  color: #8c9689;
  border-top: 1px solid var(--line);
  text-align: center;
  width: 100%;
  margin-top: 14px;
  padding-top: 16px;
}
.side-card > .resume {
  font-size: 12px;
  margin-bottom: -12px;
}
.games-section {
  margin-top: 39px;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}
.section-heading .eyebrow {
  color: #869180;
  font-size: 10px;
}
.section-heading h2 {
  font-size: 31px;
  margin-top: 5px;
}
.filters {
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 30px;
}
.filters button {
  border: 0;
  background: transparent;
  border-radius: 30px;
  padding: 9px 15px;
  font-size: 12px;
  white-space: nowrap;
}
.filters button.active {
  background: #e3eadc;
  color: #365b3e;
}
.game-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.game-card {
  text-align: left;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #fffefa;
}
.game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px #27493e0a;
}
.game-art {
  height: 133px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.river .game-art {
  background: #dbe9e5;
  color: #65a4a2;
}
.petal .game-art {
  background: #efe4da;
  color: #c87565;
}
.classic .game-art {
  background: #e7e9d9;
  color: #959d60;
}
.four .game-art {
  background: #e2e6ed;
  color: #8a98b2;
}
.card-arrow {
  position: absolute;
  bottom: 14px;
  right: 14px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  background: #ffffff80;
  border-radius: 50%;
  font-size: 19px;
}
.mini-pipes {
  font: 700 54px/0.65 monospace;
  letter-spacing: -4px;
  transform: rotate(-12deg);
  text-shadow:
    0 6px #b0cfca,
    0 10px 14px #4d817b25;
}
.mini-cards {
  display: flex;
  gap: 12px;
  transform: rotate(-12deg);
}
.mini-cards span {
  background: #fff8ee;
  box-shadow:
    0 5px #dbcdbb,
    0 8px 15px #a98d7530;
  border-radius: 10px;
  height: 70px;
  width: 53px;
  display: grid;
  place-items: center;
  font-size: 40px;
}
.mini-cards span:nth-child(2) {
  transform: translateY(9px) rotate(20deg);
  color: #aa935c;
}
.mini-ttt {
  font: 40px/0.8 Georgia;
  transform: rotate(-12deg);
  text-shadow: 0 4px #cdd3b5;
  letter-spacing: 5px;
}
.mini-four {
  font: 22px/0.9 monospace;
  letter-spacing: 4px;
  background: #f3f3f0;
  border-radius: 10px;
  transform: rotate(-12deg);
  padding: 13px;
  box-shadow:
    0 6px #c4ccd8,
    0 9px 15px #62728e20;
}
.game-copy {
  padding: 18px 19px;
}
.game-copy .eyebrow {
  font-size: 9px;
  letter-spacing: 1.25px;
  color: #7d8b7e;
}
.game-copy h3 {
  font-size: 25px;
  margin: 6px 0 8px;
  letter-spacing: -0.4px;
}
.game-copy p {
  font-size: 13px;
  line-height: 1.6;
  color: #7a887e;
  min-height: 43px;
}
.game-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid #edf0e8;
  margin-top: 16px;
  padding-top: 13px;
  font-size: 10px;
  color: #899184;
}
.game-meta > span {
  white-space: nowrap;
}
footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 31px 0;
  color: #869080;
  font-size: 12px;
}
.footer-brand {
  font-size: 20px;
  letter-spacing: -0.7px;
  color: #7a8c76;
}
footer .text-button {
  font-size: 12px;
}
.room-title {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.room-title .icon-button {
  min-width: 32px;
  min-height: 32px;
  padding: 4px;
  font-size: 18px;
}
.players {
  width: 100%;
  display: grid;
  gap: 18px;
  margin: 10px 0 18px;
}
.player {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 500;
}
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #e8eddc;
  font-family: Georgia;
  font-size: 23px;
}
.avatar.seat-1 {
  background: #f4e2cf;
  color: #b27c48;
}
.player small {
  display: block;
  font-size: 11px;
  color: #8b978a;
  font-weight: 400;
  margin-top: 3px;
}
.player small:first-child {
  display: inline;
}
.player.empty {
  color: #a0a69a;
}
.player.empty .avatar {
  background: transparent;
  border: 1px dashed #bcc7b3;
  font-size: 22px;
}
.growth {
  width: 100%;
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 23px;
}
.growth > div:not(.progress) {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  margin: 8px 0;
}
.growth strong {
  font: 30px Georgia;
}
.growth > div > span:last-child {
  margin-left: auto;
  color: #b7a85c;
  font-size: 24px;
}
.progress {
  height: 6px;
  border-radius: 10px;
  background: #e7eadf;
  overflow: hidden;
  margin: 10px 0;
}
.progress > span {
  display: block;
  height: 100%;
  background: #8da56e;
  border-radius: 10px;
  transition: width 1s;
}
.growth p {
  font-size: 12px;
  color: #8b9786;
  line-height: 1.6;
}
.room-card .room-footer {
  margin-top: auto;
  padding-top: 24px;
  font-size: 11px;
  color: #94a08f;
  line-height: 1.8;
}
.garden-bed {
  position: absolute;
  bottom: 79px;
  left: 24px;
  display: flex;
  gap: 5px;
  background: #ffffffb8;
  border-radius: 14px;
  padding: 6px;
  backdrop-filter: blur(12px);
}
.plot {
  width: 32px;
  height: 34px;
  display: grid;
  place-items: center;
  font-size: 23px;
  border-radius: 8px;
  background: #edf1e0aa;
  color: #879b6b;
}
.grown {
  animation: bloom 0.6s ease;
}
.continue-game {
  margin-top: 18px;
  width: max-content;
}
.vote-banner,
.vote-note {
  background: #e9eedf;
  border: 1px solid #d9e1cc;
  border-radius: 12px;
  padding: 12px 18px;
  margin: 15px 0;
  font-size: 14px;
}
.play-surface {
  background: #edf2e7;
  border-radius: 24px;
  border: 1px solid #dde5d5;
  min-height: 540px;
  padding: 18px 30px 24px;
  text-align: center;
}
.play-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.play-top .eyebrow {
  font-size: 10px;
  color: #85917b;
}
.play-top > .text-button {
  font-size: 12px;
}
.play-top .icon-button {
  min-width: 32px;
  min-height: 32px;
  padding: 4px;
  font-size: 14px;
}
.play-surface h1 {
  font-size: 35px;
  margin-top: 13px;
}
.instructions {
  color: #74826e;
  font-size: 13px;
  max-width: 440px;
  margin: 10px auto;
  line-height: 1.6;
}
.turn-pill {
  display: inline-block;
  padding: 8px 14px;
  background: #e0e6d9;
  border-radius: 22px;
  font-size: 12px;
  margin: 6px 0 18px;
}
.turn-pill.your-turn {
  background: #d6e6c5;
  color: #3a6635;
}
.water-wrap {
  width: min(310px, 80%);
  position: relative;
  margin: 0 auto 20px;
}
.water-board {
  display: grid;
  grid-template-columns: repeat(var(--river-size,3), 1fr);
  gap: 7px;
  background: #c0d4c3;
  padding: 9px;
  border-radius: 17px;
  transform: perspective(900px) rotateX(13deg);
  box-shadow:
    0 8px 0 #91b09a,
    0 16px 30px #49695720;
}
.pipe {
  aspect-ratio: 1;
  border: 0;
  background: #f7f5df;
  border-radius: 9px;
  box-shadow: 0 4px #d3d4b7;
  padding: 0;
  overflow: hidden;
}
.pipe svg {
  display: block;
  width: 100%;
  height: 100%;
  fill: #76b8b2;
}
.channel {
  stroke: #76b8b2;
  stroke-width: 19;
  stroke-linecap: round;
  fill: none;
}
.pipe:hover:not(:disabled) {
  background: #fffde9;
}
.pipe:disabled {
  opacity: 1;
}
.spring,
.destination {
  position: absolute;
  font-size: 25px;
  z-index: 1;
}
.spring {
  left: -34px;
  top: 12%;
}
.destination {
  right: -35px;
  bottom: 9%;
}
.board-caption {
  font-size: 12px;
  color: #839079;
  display: flex;
  gap: 20px;
  justify-content: center;
}
.board-caption span {
  color: #9aa58e;
}
.memory-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  max-width: 360px;
  margin: 0 auto 20px;
}
.memory-tile {
  aspect-ratio: 1.05;
  border: 1px solid #d3ddc8;
  background: #dee7ce;
  border-radius: 12px;
  font-size: 33px;
  box-shadow: 0 4px #c3cfb1;
}
.memory-tile > span {
  color: #8da573;
  font-size: 33px;
}
.memory-tile.flipped {
  background: #fffbed;
  box-shadow: 0 4px #e3debc;
}
.memory-tile.matched {
  background: #edf4df;
  box-shadow: 0 3px #c2d3ae;
  border-color: #bfd0a8;
}
.ttt-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  max-width: 310px;
  margin: 0 auto 20px;
}
.ttt-tile {
  aspect-ratio: 1;
  border: 0;
  border-radius: 13px;
  background: #fffced;
  box-shadow: 0 4px #dadfc7;
  font: 60px/0.8 Georgia;
}
.ttt-tile.seat-0 {
  color: #508f74;
}
.ttt-tile.seat-1 {
  color: #c58e54;
}
.four-board {
  display: flex;
  gap: 7px;
  max-width: 420px;
  padding: 14px;
  margin: 0 auto 20px;
  background: #d4dfc7;
  border-radius: 15px;
  box-shadow: 0 7px #aebe9f;
}
.four-column {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  background: transparent;
  padding: 0;
  border: 0;
  border-radius: 50px;
}
.four-column:hover:not(:disabled) {
  background: #f6f9ec77;
}
.pebble {
  aspect-ratio: 1;
  width: 100%;
  border-radius: 50%;
  background: #eff3e6;
  box-shadow: inset 0 3px #b5c5a5;
}
.pebble.seat-0 {
  background: #64977c;
  box-shadow: inset 0 -3px #467557;
}
.pebble.seat-1 {
  background: #d6a76b;
  box-shadow: inset 0 -3px #b98b51;
}
.result {
  margin-top: 20px;
}
.result h2 {
  font-size: 25px;
}
.result p {
  font-size: 13px;
  color: #7b896f;
  margin: 7px 0 13px;
}
.result .primary {
  margin: auto;
  min-height: 40px;
  padding: 10px 25px;
}
.vote-note {
  font-size: 12px;
  margin-bottom: 0;
}
.vote-note .text-button {
  font-size: 12px;
  padding: 0 7px;
}
.small-note {
  font-size: 12px !important;
}
#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 20px);
  background: #244a3f;
  color: #fffdf0;
  border-radius: 14px;
  box-shadow: 0 8px 30px #183c3426;
  padding: 15px 23px;
  font-size: 14px;
  line-height: 1.5;
  max-width: calc(100% - 32px);
  width: max-content;
  opacity: 0;
  transition: 0.25s;
  pointer-events: none;
  z-index: 10;
}
#toast.visible {
  transform: translate(-50%, 0);
  opacity: 1;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fffef8;
  color: var(--green);
  padding: 35px;
  max-width: 500px;
  width: calc(100% - 32px);
  box-shadow: 0 30px 100px #17382b30;
}
dialog::backdrop {
  background: #203b3555;
  backdrop-filter: blur(5px);
}
dialog h2 {
  font-size: 31px;
  padding-right: 30px;
}
dialog p {
  font-size: 15px;
  line-height: 1.65;
  margin: 18px 0;
}
dialog .close {
  position: absolute;
  right: 15px;
  top: 15px;
}
dialog input {
  font-size: 12px;
}
dialog .primary {
  width: 100%;
}
@keyframes bloom {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}
@media (min-width: 1450px) {
  .garden-scene {
    min-height: 560px;
  }
}
@media (max-width: 1100px) {
  .topbar {
    padding: 24px 28px;
  }
  #app {
    padding: 8px 28px 0;
  }
  .workspace {
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 18px;
  }
  .side-card {
    padding: 25px 23px;
  }
  .garden-scene {
    min-height: 510px;
  }
  .game-cards {
    gap: 13px;
  }
  .game-copy {
    padding: 15px;
  }
  .game-meta {
    font-size: 10px;
  }
  .game-meta > span {
    display: none;
  }
  .scene-heading {
    left: 24px;
  }
  .scene-heading h1 {
    font-size: 37px;
  }
  .game-copy h3 {
    font-size: 23px;
  }
}
@media (max-width: 800px) {
  .topbar {
    padding: 19px 20px;
  }
  .brand {
    font-size: 30px;
  }
  .brand-mark {
    font-size: 33px;
  }
  .header-note {
    display: none;
  }
  #app {
    padding: 4px 20px 0;
  }
  .workspace {
    grid-template-columns: 1fr;
  }
  .garden-scene {
    min-height: 430px;
  }
  .garden-scene > img {
    object-position: 50% 63%;
  }
  .side-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 24px;
    padding: 25px;
  }
  .side-card > .mini-icon {
    display: none;
  }
  .side-card > .eyebrow,
  .side-card > h2,
  .side-card > p {
    grid-column: 1;
  }
  .side-card > h2 {
    grid-row: 2 / span 2;
    font-size: 31px;
    margin-top: 6px;
  }
  .side-card > p {
    grid-row: 4 / span 2;
  }
  .side-card > label {
    grid-column: 2;
    grid-row: 1;
    margin: 0 0 7px;
  }
  .side-card > input {
    grid-column: 2;
    grid-row: 2;
  }
  .side-card > #create {
    grid-column: 2;
    grid-row: 3;
  }
  .side-card > #practice,
  .side-card > #cancel-invite {
    grid-column: 2;
    grid-row: 4;
    margin-bottom: 0;
  }
  .quiet-note {
    grid-column: 2;
    grid-row: 5;
    margin-top: 4px;
    padding-top: 12px;
  }
  .side-card > .resume {
    grid-column: 2;
  }
  .game-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
  .game-art {
    height: 145px;
  }
  .game-copy p {
    min-height: 0;
  }
  .game-meta > span {
    display: inline;
  }
  .room-card {
    display: flex;
  }
  .room-card .players {
    grid-template-columns: 1fr 1fr;
  }
  .room-card .growth {
    padding-top: 17px;
    margin-top: 10px;
  }
  .room-card > h2 {
    margin: 10px 0;
  }
  .room-card .room-footer {
    padding-top: 10px;
  }
  .room-card > .primary {
    max-width: 400px;
  }
  .game-copy .eyebrow {
    font-size: 10px;
  }
  .game-copy p {
    font-size: 14px;
  }
  .game-meta {
    font-size: 12px;
  }
  .section-heading h2 {
    font-size: 28px;
  }
  .play-surface {
    min-height: 530px;
  }
  .room-card .growth > p {
    font-size: 13px;
  }
  footer > span:nth-child(2) {
    display: none;
  }
}
@media (max-width: 520px) {
  .topbar {
    padding: 18px 18px;
  }
  #app {
    padding: 0 14px;
  }
  .icon-button span {
    font-size: 12px;
  }
  .garden-scene {
    min-height: 300px;
    border-radius: 19px;
  }
  .garden-scene > img {
    object-position: 50% 65%;
  }
  .scene-heading {
    left: 20px;
    top: 19px;
  }
  .scene-heading h1 {
    font-size: 32px;
  }
  .scene-heading .eyebrow {
    font-size: 9px;
  }
  .scene-label {
    font-size: 10px;
    padding: 8px 11px;
    left: 16px;
    bottom: 16px;
  }
  .scene-help {
    right: 14px;
    bottom: 14px;
    min-width: 34px;
    min-height: 34px;
    padding: 5px;
  }
  .side-card {
    padding: 25px;
    display: flex;
    border-radius: 19px;
  }
  .side-card > .eyebrow {
    font-size: 10px;
  }
  .side-card > h2 {
    font-size: 32px;
    max-width: 240px;
    margin: 8px 0 12px;
  }
  .side-card > p {
    font-size: 14px;
  }
  .side-card > label {
    margin: 20px 0 7px;
    font-size: 14px;
  }
  .side-card > .text-button {
    margin: 7px 0 !important;
  }
  .quiet-note {
    font-size: 12px;
    margin-top: 10px;
    padding-top: 15px;
  }
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 17px;
  }
  .games-section {
    margin-top: 30px;
  }
  .section-heading h2 {
    font-size: 30px;
  }
  .filters {
    width: 100%;
    justify-content: space-between;
  }
  .filters button {
    flex: 1;
    font-size: 12px;
    padding: 9px 8px;
  }
  .game-cards {
    gap: 12px;
  }
  .game-art {
    height: 117px;
  }
  .game-copy {
    padding: 14px 12px;
  }
  .game-copy h3 {
    font-size: 22px;
  }
  .game-copy .eyebrow {
    font-size: 8px;
    letter-spacing: 0.7px;
  }
  .game-copy p {
    font-size: 12px;
    min-height: 57px;
    line-height: 1.6;
  }
  .game-meta {
    font-size: 10px;
    margin-top: 10px;
    padding-top: 10px;
  }
  .game-meta > span {
    display: none;
  }
  .mini-pipes {
    font-size: 47px;
  }
  .mini-ttt {
    font-size: 33px;
  }
  .mini-cards span {
    width: 43px;
    height: 60px;
    font-size: 33px;
  }
  .mini-four {
    font-size: 18px;
  }
  .brand.footer-brand {
    font-size: 19px;
  }
  footer {
    padding: 23px 5px;
  }
  .garden-bed {
    bottom: 62px;
    left: 16px;
    padding: 4px;
  }
  .plot {
    width: 27px;
    height: 30px;
    font-size: 20px;
  }
  .room-card .players {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }
  .room-card > h2 {
    max-width: none;
  }
  .play-surface {
    padding: 14px 15px 25px;
    min-height: 500px;
  }
  .play-top .eyebrow {
    font-size: 8px;
    letter-spacing: 0.9px;
  }
  .play-surface h1 {
    font-size: 32px;
  }
  .instructions {
    font-size: 13px;
  }
  .water-wrap {
    max-width: 270px;
    width: 78%;
  }
  .water-board {
    gap: 6px;
    padding: 7px;
  }
  .spring,
  .destination {
    font-size: 22px;
  }
  .spring {
    left: -28px;
  }
  .destination {
    right: -28px;
  }
  .memory-board {
    gap: 9px;
  }
  .memory-tile {
    font-size: 30px;
  }
  .four-board {
    padding: 10px;
    gap: 5px;
  }
  .four-column {
    gap: 7px;
  }
  .board-caption {
    font-size: 11px;
    gap: 13px;
  }
  .turn-pill {
    font-size: 12px;
  }
  .continue-game {
    width: 100%;
  }
  .vote-banner {
    font-size: 13px;
  }
  .game-copy h3 {
    letter-spacing: -0.5px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
/* Readable overlays and primary instructions at small screen sizes. */
.garden-scene:after {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 145px;
  background: linear-gradient(#d9efdfaa, transparent);
  pointer-events: none;
}
.scene-heading {
  z-index: 1;
}
.side-card > p {
  font-size: 16px;
}
.side-card label {
  font-size: 14px;
}
.instructions {
  font-size: 14px;
}
.game-copy .eyebrow {
  font-size: 10px;
}
.game-copy p {
  font-size: 14px;
  min-height: 45px;
}
.game-meta {
  font-size: 12px;
}
.game-meta > span {
  display: none;
}
.side-card > .small-note {
  font-size: 13px !important;
}
.side-card > .room-footer {
  font-size: 12px;
}
@media (max-width: 520px) {
  .game-copy p {
    font-size: 13px;
    min-height: 65px;
  }
  .game-copy .eyebrow {
    font-size: 9px;
    letter-spacing: 0.5px;
  }
  .game-meta {
    font-size: 11px;
  }
  .side-card > p {
    font-size: 16px;
  }
  .scene-heading h1 {
    font-size: 31px;
  }
}
.pipe .channel {
  stroke: #b9cfbd;
}
.pipe svg {
  fill: #b9cfbd;
}
.pipe.flowing .channel {
  stroke: #59b7bc;
}
.pipe.flowing svg {
  fill: #59b7bc;
}
.pipe.flowing {
  background: #fbf8df;
}
.pipe.flowing .channel {
  stroke-dasharray: 5 1;
  animation: water-flow 2s linear infinite;
}
@keyframes water-flow {
  to {
    stroke-dashoffset: -24;
  }
}
.player small:first-child {
  display: block;
}
.player small.you {
  display: inline;
}
#copy-invite {
  margin-top: 14px;
}
#native-share {
  width: 100%;
  margin-top: 6px;
}
/* Two-player classics */
.game-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.ludo .game-art {
  background: #e5ebd9;
}
.uno .game-art {
  background: #efe2d5;
}
.mini-ludo {
  font-size: 76px;
  color: #568a68;
  transform: rotate(-12deg);
  line-height: 1;
}
.mini-ludo span {
  font-size: 33px;
  color: #c39357;
  vertical-align: middle;
}
.mini-uno {
  display: flex;
  gap: 6px;
  transform: rotate(-10deg);
}
.mini-uno span {
  display: grid;
  place-items: center;
  width: 46px;
  height: 67px;
  border-radius: 9px;
  background: #b95f55;
  color: #fff9ea;
  font: bold 29px Georgia;
  border: 3px solid #fff9ea;
  box-shadow: 0 5px #c5b49d;
}
.mini-uno span:nth-child(2) {
  background: #638a64;
  transform: translateY(-8px) rotate(12deg);
}
.mini-uno span:nth-child(3) {
  background: #6488a7;
  transform: rotate(20deg);
}
.game-notice {
  font-size: 14px;
  line-height: 1.5;
  margin: 14px auto;
  color: #65765c;
  max-width: 450px;
}
.color-red {
  --card: #ad4d48;
  --light: #f8e6df;
}
.color-yellow {
  --card: #846018;
  --light: #f6e7b4;
}
.color-green {
  --card: #3a7755;
  --light: #d9edda;
}
.color-blue {
  --card: #3d7194;
  --light: #deedf5;
}
.color-wild {
  --card: #54486c;
  --light: #ede3f6;
}
.uno-table {
  max-width: 560px;
  margin: auto;
}
.opponent-hand {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: #74816b;
  margin: 0 0 16px;
}
.card-back {
  background: #386c58;
  color: #dcebbb;
  border: 4px solid #fff9e9;
  border-radius: 13px;
  box-shadow: 0 4px #b2c2a7;
  display: grid;
  place-items: center;
  font-size: 38px;
}
.opponent-hand .card-back {
  width: 30px;
  height: 40px;
  border-width: 2px;
  font-size: 24px;
  border-radius: 6px;
  transform: rotate(-9deg);
}
.uno-center {
  display: flex;
  gap: 24px;
  justify-content: center;
}
.uno-center .eyebrow {
  margin-bottom: 8px;
  font-size: 10px;
}
.draw-pile,
.discard {
  width: 90px !important;
  height: 126px !important;
}
.draw-pile small {
  font-size: 12px;
}
.draw-pile:disabled {
  opacity: 0.75;
}
.uno-card {
  position: relative;
  background: var(--card);
  color: #fffaf0;
  border: 3px solid #fff9ea;
  border-radius: 11px;
  padding: 6px;
  box-shadow: 0 4px 0 #b5bda8;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
  aspect-ratio: 0.69;
  text-align: left;
}
.uno-card strong {
  font: 700 clamp(24px, 4vw, 38px)/1 Georgia;
  text-align: center;
  letter-spacing: -2px;
  border-radius: 50%;
  background: #ffffff20;
  padding: 10px 0;
}
.card-corner {
  font-size: 12px;
  font-weight: 700;
}
.card-color {
  font-size: 10px;
  text-align: right;
}
.uno-card:disabled:not(.discard) {
  opacity: 0.6;
  box-shadow: 0 2px #bbc1af;
}
.uno-card.playable {
  outline: 2px solid #789860;
  outline-offset: 2px;
  cursor: pointer;
}
.uno-card.playable:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 12px #25483d20;
}
.uno-card.just-drawn {
  outline: 3px solid #c89023;
  outline-offset: 2px;
}
.active-color {
  background: var(--light);
  color: var(--card);
  border-radius: 30px;
  padding: 7px 15px;
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  margin-top: 17px;
}
.hand-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  margin: 21px 0 13px;
}
.hand-heading .text-button {
  font-size: 12px;
}
.uno-hand {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(65px, 1fr));
  gap: 12px;
  padding: 6px 5px 12px;
  max-height: 350px;
  overflow: auto;
}
.hand-hint {
  font-size: 12px;
  color: #7c8973;
  margin: 12px 0 20px;
}
.color-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
}
.color-picker button {
  min-height: 54px;
  border: 0;
  border-radius: 12px;
  background: var(--card);
  color: #fffaf0;
  font-weight: 600;
}
.ludo-board {
  display: grid;
  grid-template-columns: repeat(15, 1fr);
  grid-template-rows: repeat(15, 1fr);
  aspect-ratio: 1;
  max-width: 435px;
  margin: 0 auto 23px;
  background: #e0e6d8;
  border: 7px solid #c8d2bb;
  border-radius: 17px;
  box-shadow: 0 7px #a9b99d;
  gap: 1px;
  overflow: hidden;
}
.ludo-cell {
  background: #fffbed;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  min-height: 0;
  min-width: 0;
  font-size: 17px;
  color: #91a185;
}
.ludo-cell.safe {
  background: #e9eddb;
}
.ludo-cell.start-green,
.lane.player-0 {
  background: #abca9a;
}
.ludo-cell.start-orange,
.lane.player-1 {
  background: #e1bb85;
}
.ludo-yard {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
  border-radius: 14px;
  margin: 6px;
}
.yard-0 {
  grid-area: 1 / 1 / 7 / 7;
  background: #c8dcb6;
  color: #37664d;
}
.yard-1 {
  grid-area: 10 / 10 / 16 / 16;
  background: #eed0a7;
  color: #8f642d;
}
.ludo-yard .eyebrow {
  font-size: 10px;
  letter-spacing: 1px;
}
.ludo-yard small {
  font-size: 11px;
}
.yard-pieces {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.yard-slot {
  width: 29px;
  height: 29px;
  background: #fff9e777;
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.ludo-piece {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  color: #fffbed;
  font-size: 11px;
  font-weight: bold;
  border: 1px solid #fff8de;
  box-shadow: 0 2px #476d5340;
  flex-shrink: 0;
}
.player-0.ludo-piece {
  background: #397858;
}
.player-1.ludo-piece {
  background: #a36b28;
}
.ludo-piece.stacked {
  width: 45%;
  height: 45%;
  font-size: 8px;
}
.yard-slot .ludo-piece {
  width: 26px;
  height: 26px;
  font-size: 12px;
}
.ludo-rest {
  display: grid;
  place-items: center;
  color: #b0c0a4;
  background: #e6eadc;
  font-size: 50px;
  border-radius: 14px;
  margin: 6px;
}
.rest-top {
  grid-area: 1 / 10 / 7 / 16;
}
.rest-bottom {
  grid-area: 10 / 1 / 16 / 7;
}
.ludo-home {
  grid-area: 7 / 7 / 10 / 10;
  background: conic-gradient(
    #dce4c8 0deg 90deg,
    #dcac72 90deg 180deg,
    #dce4c8 180deg 270deg,
    #91b784 270deg
  );
  display: grid;
  place-items: center;
  font-size: 28px;
  color: #fff9e9;
}
.dice-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 17px;
}
.die {
  font: 65px/1 Georgia;
  color: #456a52;
}
.dice-row .primary {
  min-width: 160px;
  justify-content: center;
}
.ludo-controls {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 9px;
  max-width: 435px;
  margin: 0 auto 18px;
}
.piece-choice {
  border: 1px solid #9db18d;
  border-radius: 12px;
  padding: 10px 4px;
  background: #e3efd7;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 48px;
}
.piece-choice.player-1 {
  background: #f2dfc2;
  border-color: #d7b37d;
}
.piece-choice strong {
  font: 22px Georgia;
}
.piece-choice span {
  font-size: 11px;
}
.piece-choice:disabled {
  opacity: 0.5;
  border-color: transparent;
}
.ludo-summary {
  font-size: 11px;
  line-height: 1.7;
  color: #76846c;
  margin-bottom: 20px;
}
.play-surface.uno,
.play-surface.ludo {
  min-width: 0;
}
@media (max-width: 800px) {
  .game-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .uno-hand {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
  }
  .uno-card strong {
    font-size: 27px;
    padding: 8px 0;
  }
  .uno-card {
    padding: 5px;
  }
  .uno-center {
    gap: 20px;
  }
  .uno-table {
    width: 100%;
  }
  .ludo-board {
    border-width: 5px;
    gap: 1px;
  }
  .ludo-piece {
    width: 14px;
    height: 14px;
    font-size: 9px;
  }
  .yard-pieces {
    gap: 6px;
  }
  .yard-slot {
    width: 23px;
    height: 23px;
  }
  .yard-slot .ludo-piece {
    width: 22px;
    height: 22px;
    font-size: 10px;
  }
  .ludo-yard {
    gap: 5px;
    margin: 3px;
    border-radius: 9px;
  }
  .ludo-yard .eyebrow {
    font-size: 8px;
  }
  .ludo-yard small {
    font-size: 9px;
  }
  .ludo-rest {
    margin: 3px;
    font-size: 35px;
  }
  .piece-choice {
    gap: 3px;
    flex-direction: column;
    padding: 7px 2px;
  }
  .piece-choice strong {
    font-size: 20px;
  }
  .ludo-summary {
    font-size: 10px;
  }
  .hand-heading {
    font-size: 12px;
  }
  .game-notice {
    font-size: 13px;
  }
}
.ludo-piece.crowded {
  width: 30%;
  height: 30%;
  font-size: 7px;
}
.play-surface {
  scroll-margin-top: 14px;
}
.ludo-team {
  font-size: 13px;
  color: #76846b;
  margin: -3px 0 15px;
}
/* Motion-first classics: actual SVG symbols, flower pieces and a 3D die. */
.motion-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1000;
  overflow: hidden;
  perspective: 1000px;
}
.motion-object {
  position: absolute;
  margin: 0 !important;
  pointer-events: none;
}
.motion-object svg {
  width: 100%;
  height: 100%;
}
.motion-object.uno-card {
  aspect-ratio: auto;
}
.motion-object.flower-flight {
  transform: none;
  border: none;
  background: none;
  padding: 0;
  filter: drop-shadow(0 7px 4px #1c503c30);
}
.is-playing .instructions,
.is-playing .board-caption,
.is-playing .side-card > h2,
.is-playing .side-card > .small-note,
.is-playing .side-card > .room-footer,
.is-playing .quiet-note {
  display: none;
}
.is-playing .room-card {
  align-self: start;
}
.is-playing .room-card .growth {
  margin-top: 7px;
}
.is-playing .room-card > .secondary {
  font-size: 12px;
}
.is-playing footer {
  display: none;
}
.is-playing .play-surface {
  padding-bottom: 24px;
}
.is-playing .play-surface h1 {
  font-size: 29px;
}
.is-playing .turn-pill {
  font-size: 12px;
  margin: 10px 0 23px;
}
.is-playing .room-title {
  margin-bottom: 18px;
}
.is-playing .workspace {
  grid-template-columns: minmax(0, 1fr) 270px;
}
.ludo-board {
  position: relative;
  max-width: 500px;
  overflow: visible;
  perspective: 900px;
  background: #e3e9d9;
  box-shadow:
    0 9px 0 #a8b996,
    0 20px 30px #56734a14;
}
.ludo-cell svg {
  width: 60%;
  height: 60%;
}
.ludo-board .ludo-cell {
  border-radius: 3px;
}
.ludo-yard {
  margin: 5px;
  border: 1px solid #ffffff70;
  box-shadow: inset 0 3px 10px #718b5e15;
  position: relative;
}
.yard-score {
  position: absolute;
  left: 10px;
  top: 8px;
  font-size: 11px;
  color: #54764b;
}
.yard-1 .yard-score {
  color: #966b39;
}
.ludo-rest svg {
  width: 40%;
  height: 40%;
  opacity: 0.23;
  --petal: #87a678;
}
.ludo-home svg {
  width: 65%;
  height: 65%;
  color: #fbf1cf;
}
.flower-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}
.flower-token {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 8.5%;
  aspect-ratio: 1;
  height: auto;
  border: 0;
  padding: 0;
  background: none;
  border-radius: 50%;
  pointer-events: auto;
  filter: drop-shadow(0 4px 1px #41613840);
  z-index: 2;
  transition:
    filter 0.2s,
    scale 0.2s;
}
.flower-token svg {
  width: 100%;
  height: 100%;
  display: block;
}
.flower-token.in-yard {
  width: 13%;
}
.flower-token.at-home {
  width: 7%;
  pointer-events: none;
}
.flower-token:disabled {
  opacity: 1;
}
.flower-token.can-move {
  cursor: pointer;
  z-index: 5;
  filter: drop-shadow(0 0 4px #fffdeb) drop-shadow(0 4px 1px #41613850);
  animation: flower-breathe 1.8s ease-in-out infinite;
}
.flower-token.can-move:before {
  content: "";
  position: absolute;
  inset: 8%;
  border: 2px solid #fff3ac;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #f1f3be77;
  z-index: -1;
}
.flower-token.can-move:hover {
  scale: 1.15;
}
.flower-token.can-move:active {
  transform: translate(-50%, -50%) scale(0.92);
}
.flower-dock {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin: 18px auto 0;
}
.flower-choice {
  width: 53px;
  height: 59px;
  border: 1px solid #c2d3ad;
  border-radius: 13px;
  background: #fcfaed;
  padding: 4px;
  box-shadow: 0 3px #c5d0b6;
  position: relative;
}
.flower-choice svg {
  width: 100%;
  height: 43px;
}
.flower-choice:disabled {
  opacity: 0.5;
  box-shadow: none;
}
.flower-choice:not(:disabled) {
  outline: 2px solid #a8bc78;
  outline-offset: 3px;
}
.flower-progress {
  display: block;
  height: 3px;
  background: linear-gradient(
    to right,
    #709463 var(--progress),
    #e8eddf var(--progress)
  );
  border-radius: 4px;
}
.dice-row {
  margin-top: 31px;
  gap: 28px;
  min-height: 80px;
}
.dice-button {
  width: 80px;
  height: 80px;
  padding: 0;
  background: transparent;
  border: 0;
  perspective: 500px;
  display: grid;
  place-items: center;
  cursor: pointer;
  border-radius: 20px;
}
.dice-button:not(:disabled):hover {
  background: #dfe8d4;
}
.dice-button:disabled {
  opacity: 0.8;
}
.die-cube {
  width: 48px;
  height: 48px;
  position: relative;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  display: block;
}
.die-face {
  position: absolute;
  inset: 0;
  display: block;
  background: #fffcee;
  color: #386448;
  border: 1px solid #d9e0ca;
  border-radius: 9px;
  box-shadow: inset 0 0 8px #c5d4ac40;
  backface-visibility: hidden;
}
.die-face svg {
  width: 100%;
  height: 100%;
}
.face-0 {
  transform: translateZ(24px);
}
.face-1 {
  transform: rotateY(180deg) translateZ(24px);
}
.face-2 {
  transform: rotateY(90deg) translateZ(24px);
}
.face-3 {
  transform: rotateY(-90deg) translateZ(24px);
}
.face-4 {
  transform: rotateX(90deg) translateZ(24px);
}
.face-5 {
  transform: rotateX(-90deg) translateZ(24px);
}
.dice-prompt {
  font-size: 14px;
  min-width: 142px;
  text-align: left;
  color: #546e4e;
}
.dice-prompt small {
  display: block;
  font-size: 11px;
  color: #819174;
  margin-top: 6px;
}
.uno-table {
  max-width: 610px;
}
.uno-center {
  align-items: center;
  gap: 25px;
  margin: 16px auto 20px;
  position: relative;
  max-width: 300px;
  perspective: 900px;
}
.uno-card {
  border-width: 4px;
  border-color: #fff8e5;
  position: relative;
  overflow: hidden;
  border-radius: 13px;
  box-shadow:
    0 4px #b8bdac,
    0 8px 16px #41604c15;
  background: var(--card);
  transform-style: preserve-3d;
}
.uno-card:before {
  content: "";
  position: absolute;
  left: 7%;
  top: 17%;
  width: 85%;
  height: 67%;
  border-radius: 50%;
  transform: rotate(25deg);
  background: #fff7e915;
  pointer-events: none;
}
.card-emblem {
  position: absolute;
  inset: 23% 13%;
  display: grid;
  place-items: center;
  color: #fff8e5;
}
.card-emblem svg {
  width: 100%;
  height: 100%;
}
.card-number {
  font: 700 clamp(28px, 4vw, 51px)/1 Georgia;
  letter-spacing: -2px;
}
.card-corner {
  position: absolute;
  left: 6px;
  top: 5px;
  width: 19px;
  height: 20px;
  display: grid;
  place-items: center;
}
.card-corner svg {
  width: 100%;
  height: 100%;
}
.card-corner .card-number {
  font: 700 16px/1 Georgia;
  letter-spacing: 0;
}
.card-corner.bottom {
  left: auto;
  top: auto;
  right: 6px;
  bottom: 5px;
  transform: rotate(180deg);
}
.uno-card.discard {
  transform: rotate(7deg);
  width: 93px !important;
  height: 132px !important;
}
.uno-card:disabled:not(.discard) {
  opacity: 0.84;
  filter: saturate(0.8);
  box-shadow: 0 3px #b6c0a9;
}
.uno-card.playable {
  outline: 2px solid #8fac69;
  outline-offset: 3px;
}
.uno-card.playable:hover {
  z-index: 1;
  transform: translateY(-10px) rotate(-3deg);
  filter: brightness(1.08);
}
.uno-card.just-drawn {
  outline-color: #e6b155;
}
.uno-hand {
  gap: 15px;
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
  /* Keep the lifted/rotated card and outline inside the scroll viewport. */
  padding: 26px 12px 20px;
  max-height: 420px;
}
.draw-pile {
  width: 92px !important;
  height: 132px !important;
  background: repeating-linear-gradient(
    45deg,
    #3c7159,
    #3c7159 7px,
    #396c56 7px,
    #396c56 14px
  );
  transform: rotate(-5deg);
  border: 4px solid #fff8e5;
  box-shadow:
    2px 3px #fff8e5,
    3px 5px #b5c3a8,
    4px 8px #fff8e5,
    5px 10px #a9bba0;
  position: relative;
}
.draw-pile svg {
  width: 52%;
  height: 52%;
  color: #e8e9b9;
}
.card-back svg {
  width: 58%;
  height: 58%;
}
.color-beacon {
  position: absolute;
  right: 6px;
  bottom: -8px;
  width: 26px;
  height: 26px;
  border: 5px solid #f9f7e8;
  background: var(--card);
  box-shadow: 0 2px #b3c2a4;
  border-radius: 50%;
}
.opponent-hand {
  margin: 0 0 30px;
  gap: 12px;
  height: 67px;
  position: relative;
}
.opponent-fan {
  position: relative;
  width: 126px;
  height: 63px;
}
.opponent-fan .card-back {
  position: absolute;
  left: calc(50% + (var(--fan) - (var(--total) - 1) / 2) * 10px);
  top: 3px;
  transform: translateX(-50%)
    rotate(calc((var(--fan) - (var(--total) - 1) / 2) * 7deg));
  transform-origin: center 150%;
  width: 39px;
  height: 56px;
  border: 2px solid #fff8e5;
  font-size: 0;
  border-radius: 7px;
  box-shadow: 0 3px #b3c1a9;
}
.count-badge {
  background: #dfe8d4;
  border-radius: 20px;
  padding: 5px 10px;
  font-size: 12px;
}
.hand-heading {
  font-size: 12px;
  color: #77896b;
  margin-top: 17px;
}
.hand-heading b {
  display: inline-block;
  background: #d9e4cd;
  padding: 3px 8px;
  border-radius: 20px;
  margin-left: 4px;
}
.keep-card {
  border: 1px solid #c2d2b2;
  border-radius: 20px;
  background: #fffced;
  padding: 8px 13px;
  font-size: 12px;
}
.compact-notice {
  font-size: 12px;
  min-height: 18px;
  margin: 8px auto;
}
.color-picker button {
  min-height: 65px;
  border-radius: 18px;
}
.play-surface.uno {
  background: radial-gradient(ellipse at center, #edf2df, #e4ecda);
}
.play-surface.ludo {
  background: linear-gradient(145deg, #f1f4e8, #e8eedf);
}
@keyframes flower-breathe {
  50% {
    filter: drop-shadow(0 0 7px #fff6ad) drop-shadow(0 4px 2px #41613840);
  }
}
@media (max-width: 800px) {
  .is-playing .workspace {
    grid-template-columns: 1fr;
  }
  .is-playing .room-card {
    padding: 13px 20px;
    display: block;
  }
  .is-playing .room-card .room-title,
  .is-playing .room-card .growth,
  .is-playing .room-card > .secondary {
    display: none;
  }
  .is-playing .room-card .players {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    margin: 0;
  }
  .is-playing .room-card .player {
    font-size: 12px;
  }
  .is-playing .room-card .avatar {
    width: 30px;
    height: 30px;
    font-size: 18px;
  }
  .is-playing .workspace > .room-card {
    order: -1;
  }
  .is-playing .play-surface {
    padding-top: 12px;
  }
}
@media (max-width: 520px) {
  .uno-hand {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 11px;
    padding: 24px 10px 18px;
  }
  .card-emblem .card-number {
    font-size: 32px;
  }
  .card-corner {
    width: 13px;
    height: 16px;
    left: 4px;
    top: 4px;
  }
  .card-corner.bottom {
    right: 4px;
    bottom: 4px;
  }
  .card-corner .card-number {
    font-size: 13px;
  }
  .uno-card {
    border-width: 3px;
    border-radius: 10px;
  }
  .ludo-board {
    max-width: 360px;
    border-width: 4px;
  }
  .flower-token {
    width: 9.5%;
  }
  .flower-token.in-yard {
    width: 16%;
  }
  .flower-dock {
    margin-top: 12px;
    gap: 14px;
  }
  .flower-choice {
    width: 49px;
    height: 54px;
  }
  .flower-choice svg {
    height: 40px;
  }
  .dice-row {
    margin-top: 20px;
    gap: 18px;
    min-height: 65px;
  }
  .die-cube {
    width: 42px;
    height: 42px;
  }
  .face-0 {
    transform: translateZ(21px);
  }
  .face-1 {
    transform: rotateY(180deg) translateZ(21px);
  }
  .face-2 {
    transform: rotateY(90deg) translateZ(21px);
  }
  .face-3 {
    transform: rotateY(-90deg) translateZ(21px);
  }
  .face-4 {
    transform: rotateX(90deg) translateZ(21px);
  }
  .face-5 {
    transform: rotateX(-90deg) translateZ(21px);
  }
  .dice-button {
    width: 69px;
    height: 69px;
  }
  .dice-prompt {
    font-size: 12px;
    min-width: 120px;
  }
  .yard-score {
    font-size: 9px;
    left: 7px;
    top: 5px;
  }
  .is-playing .workspace {
    gap: 12px;
  }
  .is-playing .turn-pill {
    margin-bottom: 17px;
  }
  .uno-center {
    margin-bottom: 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .flower-token.can-move {
    animation: none;
  }
  .uno-card.playable:hover {
    transform: none;
  }
}
.game-search {
  margin: 0 0 22px;
  max-width: 360px;
  background: #fffdf5;
}
.game-cards {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.game-card .game-copy {
  padding: 14px 17px 17px;
}
.game-card .game-copy h3 {
  font-size: 23px;
  margin: 5px 0 0;
}
.game-card .game-art {
  height: 126px;
}
.game-card.arcade .game-art {
  background: #e7ecdd;
}
.game-card.strategy .game-art {
  background: #e8e7d9;
}
.game-card:nth-child(4n + 2) .game-art {
  background: #e4ece5;
}
.game-card:nth-child(4n + 3) .game-art {
  background: #f0e6d8;
}
.game-card:nth-child(4n) .game-art {
  background: #e3e8eb;
}
.catalog-icon {
  width: 133px;
  height: 97px;
  transform: rotate(-7deg);
  filter: drop-shadow(0 5px 1px #80987d20);
}
.catalog-ludo {
  display: flex;
  align-items: center;
  gap: 0;
  transform: rotate(-8deg);
}
.catalog-ludo > svg {
  width: 46px;
  height: 64px;
  --petal: #e1c383;
}
.catalog-ludo > svg:nth-child(2) {
  background: #fff9e8;
  border-radius: 9px;
  width: 45px;
  height: 45px;
  padding: 4px;
  color: #628765;
  box-shadow: 0 5px #c2ceac;
  transform: rotate(12deg);
}
.catalog-cards {
  display: flex;
  transform: rotate(-11deg);
}
.catalog-cards > span {
  width: 42px;
  height: 63px;
  background: var(--card);
  color: #fff6e2;
  border: 3px solid #fff9e9;
  border-radius: 8px;
  margin-left: -5px;
  padding: 5px;
  box-shadow: 0 4px #c4c8b2;
  display: flex;
  align-items: center;
}
.catalog-cards > span:nth-child(2) {
  transform: translateY(-7px) rotate(8deg);
}
.catalog-cards > span:nth-child(3) {
  transform: rotate(15deg);
}
.catalog-cards svg {
  width: 100%;
  height: 100%;
}
.catalog-pairs {
  display: flex;
  gap: 15px;
  transform: rotate(-8deg);
}
.catalog-pairs svg {
  background: #fff7e8;
  width: 47px;
  height: 66px;
  padding: 4px;
  border-radius: 10px;
  box-shadow: 0 5px #d9c8b4;
}
.catalog-pairs svg:last-child {
  transform: rotate(15deg) translateY(4px);
}
.empty-games {
  padding: 24px;
  font-size: 15px;
  color: #819071;
}
@media (max-width: 1100px) {
  .game-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 700px) {
  .game-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .game-card .game-copy h3 {
    font-size: 21px;
  }
  .game-card .game-art {
    height: 109px;
  }
  .game-card .game-copy {
    padding: 13px;
  }
  .game-search {
    max-width: none;
  }
  .catalog-icon {
    width: 115px;
    height: 86px;
  }
}
.card-penalty {
  font: 700 15px/1 system-ui;
  letter-spacing: -1px;
}

/* Team colors remain readable on every flower, including moving tokens. */
.ludo-teams {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin: -8px 0 16px;
  font-size: 12px;
  font-weight: 700;
}
.player-0 {
  --team: #347b66;
}
.player-1 {
  --team: #c06b37;
}
.team-label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--team);
}
.team-label i {
  width: 13px;
  height: 13px;
  border: 3px solid var(--team);
  border-radius: 50%;
  background: #fff8df;
}
.ludo-yard.yard-0 {
  border: 3px solid #347b66;
  background: #cee4d4;
}
.ludo-yard.yard-1 {
  border: 3px solid #c06b37;
  background: #f2d5b7;
}
.yard-team {
  position: absolute;
  left: 8px;
  top: 6px;
  font-size: 10px;
  font-weight: 750;
  color: #245b49;
}
.yard-1 .yard-team {
  color: #88401e;
}
.yard-score {
  left: auto;
  right: 8px;
  top: 6px;
}
.flower-token::after {
  content: "";
  position: absolute;
  inset: 5%;
  border: 2px solid var(--team, #347b66);
  border-radius: 50%;
  background: color-mix(in srgb, var(--team, #347b66) 12%, transparent);
  z-index: -1;
}
.flower-token svg ellipse,
.flower-token svg path[fill="var(--petal)"],
.flower-choice svg ellipse,
.flower-choice svg path[fill="var(--petal)"] {
  stroke: var(--team);
  stroke-width: 1.8;
}
.flower-choice {
  border-color: var(--team) !important;
}
/* A played card lands above the visible discard pile. */
.discard-stack {
  position: relative;
  flex: 0 0 93px;
  width: 93px;
  height: 132px;
  isolation: isolate;
}
.discard-stack .discard {
  z-index: 5;
}
.discard-stack .discard-under {
  position: absolute !important;
  inset: 0;
  width: 93px;
  height: 132px;
  transform: translate(
      calc((var(--stack) - 2) * 2px),
      calc((3 - var(--stack)) * 2px)
    )
    rotate(calc((var(--stack) - 1) * -7deg));
  z-index: var(--stack);
}
.motion-layer > .motion-object {
  position: absolute !important;
  transform-origin: top left;
  opacity: 1;
  visibility: visible;
}
.motion-layer > .motion-object.flower-flight {
  transform-origin: center;
}
@media (max-width: 520px) {
  .yard-team,
  .yard-score {
    font-size: 8px;
    top: 4px;
  }
  .yard-team {
    left: 4px;
  }
  .yard-score {
    right: 4px;
  }
  .ludo-teams {
    margin-top: -5px;
    margin-bottom: 12px;
  }
}

.motion-layer .board-travel{display:grid;place-items:center;border-radius:8px}.motion-layer .board-travel .st-checker{width:76%;height:76%;border-radius:50%;background:#4e816b;color:#fff8dc;display:grid;place-items:center;box-shadow:0 3px #345747}.motion-layer .board-travel.st-player-1 .st-checker{background:#c5914d}.motion-layer .arc-number{display:grid;place-items:center;font-size:26px;font-weight:700}.motion-layer .st-cell.board-travel{background:none;border:0}

.play-tools{display:flex;align-items:center;gap:5px}.play-tools .icon-button{flex-shrink:0}

/* Three entry modes stay separate and comfortably tappable on phones. */
.side-card > .mode-self{margin-top:12px;font-size:14px;min-height:48px;gap:10px;justify-content:space-between}
.side-card > .mode-hint{font-size:12px;line-height:1.5;margin:10px 0 0;color:var(--muted)}

.side-card > #practice{min-height:48px;width:100%}

/* The shared home and games remain separate, persistent sections. */
.section-nav{display:flex;align-items:center;gap:6px;padding:5px;width:max-content;max-width:100%;margin:8px auto 28px;background:#e9eee4;border:1px solid #dfe6d9;border-radius:19px}
.section-nav button{display:flex;align-items:center;justify-content:center;gap:9px;min-height:45px;padding:10px 24px;border:0;background:transparent;border-radius:14px;font-size:14px;font-weight:600;color:#718173;transition:background .2s,color .2s,box-shadow .2s}
.section-nav button svg{width:21px;height:21px}
.section-nav button[aria-current=page]{background:#fffdf6;color:#315845;box-shadow:0 3px 9px #42513b0b}
.section-nav button:hover{color:#254f3b}
.cozy-room-tools{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:0 auto 20px;max-width:1200px}
.cozy-room-people,.cozy-room-tools>div:last-child{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.home-person{display:inline-flex;align-items:center;gap:8px;font-size:13px;font-weight:600}
.home-person i{display:grid;place-items:center;width:32px;height:32px;border-radius:50%;background:#dce8d5;color:#41694b;font-size:12px;font-style:normal}
.home-person i.seat-1{background:#efdecb;color:#936950}
.people-join{font-family:Georgia,serif;color:#a4af99}.room-kind{font-size:11px;color:#84907f;margin-left:4px}
.cozy-room-tools .secondary{width:auto;padding:11px 15px;margin:0;font-size:12px}.cozy-room-tools .text-button{font-size:12px}.cozy-room-tools .icon-button{border:1px solid #e1e7da}
.games-intro{display:grid;grid-template-columns:minmax(0,1fr) 310px;gap:32px;align-items:center;margin:8px 0 36px}.games-intro h1{font:normal 48px/1.15 Georgia,serif;margin:12px 0;color:#2a513e}.games-intro p{color:#7a8675;font-size:15px}.games-intro>.room-card{padding:20px}.games-intro>.room-card .growth,.games-intro>.room-card h2,.games-intro>.room-card .room-footer{display:none}.games-intro .secondary{max-width:360px}.games-intro .players{margin:16px 0}
.welcome-features{display:grid;grid-template-columns:repeat(3,1fr);gap:24px;margin:34px 0 18px}.welcome-features>div{background:#fafaf5;border:1px solid #e4e8df;border-radius:24px;padding:26px}.welcome-features>div>span{display:inline-flex;padding:12px;border-radius:14px;background:#edf0e5;color:#68866c}.welcome-features svg{width:23px;height:23px}.welcome-features h3{font:normal 25px Georgia,serif;margin:20px 0 10px}.welcome-features p{max-width:260px;font-size:14px;line-height:1.65;color:#7b8675;margin:0}
@media(max-width:760px){.section-nav{margin:0 auto 22px;gap:3px}.section-nav button{padding:10px 17px;font-size:13px;gap:7px}.section-nav button svg{width:19px;height:19px}.cozy-room-tools{align-items:flex-start;gap:8px;margin-bottom:16px}.cozy-room-tools .room-kind{display:none}.cozy-room-tools .secondary{max-width:130px;font-size:11px;padding:10px}.cozy-room-tools .icon-button{display:grid;width:32px;height:32px;min-width:32px}.cozy-room-tools>div:last-child{justify-content:flex-end;gap:4px}.cozy-room-people{gap:6px}.home-person{font-size:12px;max-width:116px;overflow:hidden}.home-person i{width:25px;height:25px;flex-shrink:0}.games-intro{display:block;margin:5px 0 25px}.games-intro h1{font-size:36px}.games-intro>.room-card{margin-top:20px}.games-intro>.room-card .empty,.games-intro>.room-card .small-note{display:none}.welcome-features{grid-template-columns:1fr;gap:12px;margin-top:18px}.welcome-features>div{padding:22px}.welcome-features h3{display:inline-block;margin:0 0 0 15px;font-size:23px}.welcome-features p{margin-top:12px;max-width:none}.welcome-home .garden-scene{min-height:310px}.welcome-home #setup{margin-top:0}.cozy-room-tools .text-button{max-width:112px;line-height:1.5}}
@media(max-width:350px){.section-nav button{padding:10px 8px;gap:5px;font-size:12px}.home-person{max-width:91px;font-size:11px}.cozy-room-tools .secondary{max-width:108px}.cozy-room-tools{gap:4px}}

@media(max-width:480px){.filters{flex-wrap:wrap;border-radius:16px}.filters button{flex:1 1 42%;min-height:40px}}

/* A brief, non-blocking celebration after a confirmed win. */
.victory-layer{position:fixed;inset:0;z-index:1000;overflow:hidden;pointer-events:none;contain:strict}
.victory-badge{position:absolute;top:max(28px,env(safe-area-inset-top));left:50%;transform:translateX(-50%);display:grid;justify-items:center;gap:3px;max-width:calc(100% - 32px);width:max-content;padding:12px 26px 19px;background:#fffcf1f5;border:1px solid #e2d9b9;border-radius:24px;box-shadow:0 10px 36px #385b3920;animation:victory-badge 3.4s ease both;text-align:center}
.victory-badge strong{font:600 23px/1.25 Georgia,serif;color:#42664f;overflow-wrap:anywhere}
.victory-stars{display:block;width:100px;height:40px;color:#cba454;margin:0 auto 8px}.victory-stars svg{width:100%;height:100%}
.victory-badge .victory-stars{margin-bottom:0}
.victory-particle{position:absolute;top:-24px;left:var(--x);width:var(--size);height:calc(var(--size)*.58);background:var(--color);border-radius:2px;opacity:0;animation:victory-fall var(--duration) var(--delay) cubic-bezier(.18,.6,.4,1) both;will-change:transform}
.victory-particle.star{height:var(--size);clip-path:polygon(50% 0%,61% 35%,98% 35%,68% 57%,79% 94%,50% 72%,21% 94%,32% 57%,2% 35%,39% 35%)}
@keyframes victory-fall{0%{opacity:0;transform:translate3d(0,-15px,0) rotate(0)}10%{opacity:1}75%{opacity:1}100%{opacity:0;transform:translate3d(var(--drift),85vh,0) rotate(var(--spin))}}
@keyframes victory-badge{0%{opacity:0;translate:0 -8px}12%,75%{opacity:1;translate:0 0}100%{opacity:0;translate:0 0}}
@media(prefers-reduced-motion:reduce){.victory-particle{display:none}.victory-badge{animation:none}}

.water-wrap.expanded{width:calc(100% - 30px);max-width:420px}.water-wrap.expanded .water-board{gap:4px;padding:6px}.water-wrap.expanded .spring{left:-22px;font-size:18px;top:4%}.water-wrap.expanded .destination{right:-22px;font-size:18px;bottom:4%}

.puzzle-size-picker{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:16px;margin:16px auto 22px;color:var(--muted)}
.puzzle-size-picker label{display:flex;align-items:center;gap:10px;font-size:14px}.puzzle-size-picker select{padding:9px 12px;border:1px solid #c4d0b6;background:#fffdf2;border-radius:12px;color:#40583e;font:inherit}.puzzle-size-picker .text-button{font-size:14px}
/* Let internally scrollable game boards shrink within the workspace grid. */
.workspace > .play-surface{min-width:0}

.room-lobby{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 22px;margin:0 0 20px;background:#fffdf2;border:1px solid #d8dfcc;border-radius:20px}.room-lobby strong{display:block;font-family:var(--serif,Georgia,serif);font-size:22px;margin-top:5px}.room-lobby p{margin:6px 0 0;font-size:14px;color:#718169}.room-lobby button{flex-shrink:0}.room-code-share{display:flex;align-items:center;flex-direction:column;gap:12px;margin:24px 0 8px;padding-top:22px;border-top:1px solid #d8dfcc}.room-code-share strong{font-size:30px;letter-spacing:3px;font-variant-numeric:tabular-nums}.room-code-share small{color:#718169}.game-card:disabled{cursor:default;opacity:.65}@media(max-width:600px){.room-lobby{align-items:stretch;flex-direction:column;padding:16px}.room-lobby button{width:100%}.topbar{flex-wrap:wrap;gap:10px}#join-room{white-space:nowrap}}
