@font-face {
  font-family:Rubik;
  src:url('/assets/fonts/Rubik-Regular.ttf') format('truetype');
  font-style:normal;
  font-weight:400 550;
  font-display:swap;
}

@font-face {
  font-family:Rubik;
  src:url('/assets/fonts/Rubik-Bold.ttf') format('truetype');
  font-style:normal;
  font-weight:600 900;
  font-display:swap;
}

@font-face {
  font-family:Lora;
  src:url('/assets/fonts/Lora.ttf') format('truetype');
  font-weight:400 700;
  font-style:normal;
  font-display:swap;
}

:root {
  color-scheme:light;
  --ink:#243e35;
  --muted:#526458;
  --forest:#285446;
  --paper:#f8f6ec;
  --panel:#fffdf6;
  --line:#cfcfbc;
  --gold:#ab8339;
  --serif:Lora,Georgia,serif;
  --sans:Rubik,system-ui,sans-serif;
  --gutter:clamp(1rem,5vw,5.25rem);
}

* {
  box-sizing:border-box;
}

html {
  min-width:300px;
  background:var(--paper);
}

body {
  margin:0;
  color:var(--ink);
  font:1rem/1.48 var(--sans);
  background:radial-gradient(ellipse at 86% 28%,#efeada77,transparent 58%),var(--paper);
}

button,input,select {
  font:inherit;
}

button {
  cursor:pointer;
  color:inherit;
}

button:disabled {
  cursor:default;
}

input,button,select {
  -webkit-tap-highlight-color:transparent;
}

button:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible {
  outline:3px solid #1972aa;
  outline-offset:3px;
}

[hidden] {
  display:none!important;
}

.icon-bank {
  position:absolute;
  width:0;
  height:0;
  pointer-events:none;
  overflow:hidden;
}

.icon {
  display:inline-block;
  width:1.2rem;
  height:1.2rem;
  flex:none;
  fill:none;
  stroke:currentColor;
  stroke-width:1.65;
  stroke-linecap:round;
  stroke-linejoin:round;
  vertical-align:middle;
  pointer-events:none;
}

h1,h2,h3,p,figure,fieldset,ul {
  margin:0;
}

fieldset {
  min-width:0;
  padding:0;
  border:0;
}

button {
  border:0;
}

img {
  max-width:100%;
}

h1,h2 {
  font-family:var(--serif);
}

.topbar {
  border-bottom:1px solid var(--line);
  background:#faf9f1e8;
}

.topbar-inner {
  width:min(100%,1500px);
  min-height:4.7rem;
  margin:0 auto;
  padding:.65rem var(--gutter);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
}

.wordmark {
  display:flex;
  align-items:center;
  gap:.7rem;
  font:700 clamp(1.05rem,2vw,1.3rem)/1.15 var(--serif);
  letter-spacing:-.043em;
}

.wordmark img {
  width:2.55rem;
  height:2.55rem;
  flex:none;
}

.topbar nav {
  display:flex;
  align-items:center;
  gap:.55rem;
}

.nav-button,.utility-button,.icon-button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  min-height:2.7rem;
  background:transparent;
  color:var(--ink);
  font-size:.91rem;
  line-height:1.2;
  border:1px solid var(--line);
  border-radius:.5rem;
  padding:.55rem .95rem;
}

.nav-button:hover,.utility-button:hover,.icon-button:hover {
  background:#e8ebdd;
  border-color:#99a68e;
}

.home-button {
  display:none;
}

body:has(#game:not([hidden])) .home-button,body:has(#results:not([hidden])) .home-button {
  display:inline-flex;
}

.lobby,.game-shell,.results-shell {
  max-width:1500px;
  margin:0 auto;
  padding:0 var(--gutter);
}

.lobby-layout {
  display:grid;
  grid-template-columns:minmax(0,1.02fr) minmax(0,1fr);
  grid-template-areas:'intro art' 'setup art';
  grid-template-rows:auto auto;
  column-gap:clamp(1rem,3.8vw,4.2rem);
  padding:clamp(1.6rem,3.6vw,4rem) 0 clamp(2.4rem,4vw,4.5rem);
  align-items:center;
}

.intro {
  grid-area:intro;
  align-self:end;
}

.eyebrow {
  display:flex;
  align-items:center;
  gap:.65rem;
  font-size:.73rem;
  font-weight:600;
  letter-spacing:.145em;
  line-height:1.45;
  text-transform:uppercase;
  color:#63725c;
}

.eyebrow>span {
  display:inline-block;
  width:1.8rem;
  height:1px;
  background:var(--gold);
  position:relative;
}

.eyebrow>span:after {
  content:'';
  position:absolute;
  right:0;
  top:-2px;
  width:5px;
  height:5px;
  transform:rotate(45deg);
  background:var(--gold);
}

.intro h1 {
  font-size:clamp(3rem,5vw,5.3rem);
  font-weight:600;
  line-height:1.01;
  letter-spacing:-.066em;
  margin:1.25rem 0 1.15rem;
  color:#203e34;
}

.lead {
  max-width:31rem;
  color:#43594c;
  font-size:clamp(1.025rem,1.45vw,1.32rem);
  line-height:1.5;
  letter-spacing:-.015em;
}

.facts {
  padding:0;
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:.55rem 1.28rem;
  list-style:none;
  margin:1.4rem 0 0;
  color:#526455;
  font-size:.91rem;
}

.facts li {
  display:flex;
  align-items:center;
  gap:.38rem;
}

.facts .icon {
  width:1.1rem;
  height:1.1rem;
}

.hero-art {
  grid-area:art;
  position:relative;
  width:min(100%,36.75rem);
  justify-self:end;
  padding:.3rem .6rem .5rem 1.4rem;
  isolation:isolate;
}

.map-mount {
  aspect-ratio:1;
  transform:rotate(1.4deg);
  position:relative;
  background:#ece4c9;
  padding:clamp(.24rem,.42vw,.4rem);
  box-shadow:0 .6rem 1.5rem -.7rem #3b3b2490,0 .15rem .25rem #78785470,0 0 0 1px #b4ad88;
  outline:1px solid #faf3dc;
  outline-offset:-2px;
  border-radius:.2rem;
}

.map-print {
  position:relative;
}

.map-seal {
  position:absolute;
  right:2.97%;
  bottom:4.08%;
  width:19.1%;
  height:auto;
  border-radius:50%;
}

.city-map {
  display:block;
  width:100%;
  height:auto;
}

.tile-stack {
  position:absolute;
  bottom:.6rem;
  left:-.3rem;
  width:25%;
  aspect-ratio:1.3;
  pointer-events:none;
  filter:drop-shadow(.15rem .45rem .3rem #202f2350);
}

.tile-stack img {
  position:absolute;
  width:74%;
  height:auto;
  aspect-ratio:1;
  padding:2px;
  background:#d9dfbd;
  border-radius:4%;
  box-shadow:0 2px #8f967b,0 3px #8f967b,0 4px #a4a48b;
  transform:rotate(-17deg);
  bottom:4%;
  left:0;
}

.tile-stack img+img {
  bottom:1%;
  left:36%;
  transform:rotate(8deg);
}

.setup {
  grid-area:setup;
  align-self:start;
  margin-top:1.75rem;
  max-width:32.5rem;
  border-top:1px solid var(--line);
  padding-top:1.45rem;
}

.setup-fields {
  display:grid;
  grid-template-columns:minmax(8.5rem,.9fr) minmax(13rem,1.1fr);
  gap:clamp(.6rem,1.3vw,1.25rem);
}

.setup label,.setup legend {
  font-size:.91rem;
  font-weight:600;
  line-height:1.3;
}

.setup legend {
  padding:0;
}

.name-field>label,.bots-field legend {
  display:block;
  margin-bottom:.5rem;
}

.name-field input {
  width:100%;
  height:2.85rem;
  padding:.55rem .75rem;
  border-radius:.45rem;
  background:var(--panel);
  border:1px solid #b7bfad;
  color:var(--ink);
  font-size:1rem;
}

.name-field input::placeholder {
  color:#727e70;
}

.bot-choices {
  display:flex;
  gap:.3rem;
}

.bot-choices label {
  flex:1;
  position:relative;
  cursor:pointer;
}

.bot-choices input {
  position:absolute;
  opacity:0;
  width:1px;
  height:1px;
}

.bot-choices span {
  height:2.85rem;
  display:grid;
  place-items:center;
  white-space:nowrap;
  line-height:1;
  padding:0 .34rem;
  border:1px solid #b7bfad;
  background:#fbfaf1;
  border-radius:.45rem;
  font-weight:400;
  font-size:.94rem;
}

.bot-choices input:checked+span {
  color:#fffdf2;
  background:#456553;
  border-color:#456553;
  font-weight:600;
}

.bot-choices input:focus-visible+span {
  outline:3px solid #1972aa;
  outline-offset:2px;
}

.bot-choices label:hover span {
  border-color:var(--forest);
}

.lobby-actions,.turn-actions,.dialog-actions,#result-actions {
  display:flex;
  gap:.65rem;
  flex-wrap:wrap;
  align-items:center;
}

.lobby-actions {
  margin-top:1.15rem;
}

.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.6rem;
  min-height:2.85rem;
  line-height:1.25;
  padding:.7rem 1.15rem;
  border:1px solid #bdc5b3;
  border-radius:.5rem;
  background:var(--panel);
  font-weight:600;
  text-align:center;
}

.button:hover {
  background:#e9eddf;
}

.button.primary {
  color:#fffdf2;
  background:var(--forest);
  border-color:#274d40;
}

.button.primary:hover {
  background:#183e31;
}

.button:disabled {
  opacity:.55;
}

.button.play-button {
  min-height:3.3rem;
  padding:.75rem 1.7rem;
  font-size:1.08rem;
  box-shadow:0 3px 0 #183a30;
}

.play-button .icon {
  width:1.1rem;
  height:1.1rem;
}

.button.secondary {
  color:var(--forest);
  background:#f8faf0;
}

.button.secondary:hover {
  background:#e4eadc;
}

.collection {
  border-top:1px solid #c5c7b2;
  padding:1.65rem 0 2rem;
}

.collection-heading {
  display:flex;
  align-items:baseline;
  gap:1.15rem;
  flex-wrap:wrap;
}

.collection h2 {
  font-size:clamp(1.45rem,2vw,1.85rem);
  letter-spacing:-.04em;
  font-weight:600;
}

.collection-heading p {
  font-size:.95rem;
  color:var(--muted);
}

.key-list {
  list-style:none;
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  padding:0;
  margin:1rem 0 0;
}

.key-list li {
  display:flex;
  align-items:center;
  gap:clamp(.4rem,.8vw,.9rem);
  color:var(--ink);
  padding:.1rem .9rem;
  border-left:1px solid #d5d6c6;
}

.key-list li:first-child {
  padding-left:0;
  border-left:0;
}

.key-list li:last-child {
  padding-right:0;
}

.key-list svg {
  width:clamp(2rem,4.1vw,3.5rem);
  height:2rem;
  color:var(--key);
  transform:rotate(-18deg);
  flex:none;
}

.key-list span {
  font-size:clamp(.84rem,1.04vw,.99rem);
  line-height:1.25;
}

.game-shell,.results-shell {
  padding-top:1.5rem;
  padding-bottom:2.4rem;
}

.game-head {
  display:flex;
  align-items:end;
  justify-content:space-between;
  gap:1rem;
  margin-bottom:1rem;
}

.game-head h1,.results-shell>h1 {
  font-size:clamp(2rem,3.1vw,3rem);
  letter-spacing:-.055em;
  line-height:1.15;
  font-weight:600;
}

.game-head .eyebrow {
  margin-bottom:.4rem;
}

.clocks {
  display:flex;
  align-items:center;
  gap:1.2rem;
}

.clocks>div {
  display:grid;
  line-height:1.25;
}

.clocks>div+div {
  padding-left:1.2rem;
  border-left:1px solid var(--line);
}

.clocks span {
  color:var(--muted);
  font-size:.84rem;
}

.clocks strong {
  font:600 clamp(1.25rem,2vw,1.6rem)/1.25 var(--sans);
  font-variant-numeric:tabular-nums;
}

.game-layout {
  display:grid;
  grid-template-columns:minmax(0,1.6fr) minmax(16rem,.85fr);
  gap:clamp(1rem,3.5vw,3rem);
  align-items:start;
}

.field-column {
  min-width:0;
}

.board-tools {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:.5rem;
  margin-bottom:.55rem;
}

.turn-label {
  font-size:.95rem;
  color:var(--muted);
}

#turn-name {
  color:var(--ink);
}

.utility-button {
  min-height:2.55rem;
  font-size:.86rem;
  padding:.45rem .7rem;
}

.utility-button .icon {
  width:1rem;
  height:1rem;
}

.board-window {
  width:100%;
  overflow:auto;
  overscroll-behavior:contain;
  border:clamp(3px,.5vw,7px) solid #566e53;
  border-radius:.5rem;
  box-shadow:0 3px 12px #35473524;
  background:#a6b691;
}

.board {
  display:grid;
  width:100%;
  grid-template-columns:repeat(7,minmax(0,1fr));
  aspect-ratio:1;
  gap:0;
  align-content:stretch;
  touch-action:manipulation;
}

.board.zoomed,.board-window.zoomed .board {
  min-width:48rem;
}

.tile {
  min-width:0;
  min-height:0;
  position:relative;
  aspect-ratio:1;
  display:grid;
  place-items:center;
  border:0;
  margin:0;
  padding:0;
  background:#cbd6aa;
  isolation:isolate;
  border-radius:0;
  -webkit-appearance:none;
  overflow:hidden;
}

.tile[disabled] {
  opacity:1;
}

.tile-art {
  display:block;
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  background-size:cover;
  background-position:center;
  transition:transform .28s ease;
}

.tile.legal {
  cursor:pointer;
}

.tile.legal:after,.tile.selected:after,.tile:focus-visible:after {
  content:'';
  position:absolute;
  inset:5%;
  border-radius:8%;
  border:clamp(2px,.33vw,5px) dashed #224f3e;
  box-shadow:0 0 0 2px #fff3bd, inset 0 0 0 2px #fff3bd;
  pointer-events:none;
  z-index:3;
}

.tile.legal:hover:after,.tile.selected:after,.tile:focus-visible:after {
  border-style:solid;
  border-color:#075c67;
  background:#ffffd126;
}

.tile:focus-visible {
  outline-offset:-4px;
  z-index:4;
}

.pawn {
  --pawn:#162c37;
  display:inline-grid;
  place-items:center;
  position:relative;
  isolation:isolate;
  width:1.65rem;
  height:1.65rem;
  background:var(--pawn);
  border:2px solid #fff8df;
  border-radius:50%;
  box-shadow:0 1px 3px #1e34115e;
  color:white;
  font:700 .88rem/1 var(--sans);
  z-index:2;
}

.pawn-1 {
  --pawn:#794226;
}

.pawn-2 {
  --pawn:#38424e;
}

.pawn-3 {
  --pawn:#925f11;
}

.tile .pawn {
  width:46%;
  height:46%;
  font-size:clamp(.7rem,2vw,1.55rem);
  box-shadow:0 1px 2px 2px #21342088;
}

.participants {
  padding-top:.25rem;
  min-width:0;
}

.participants>h2 {
  font-size:1.45rem;
  font-weight:600;
  letter-spacing:-.045em;
  margin-bottom:.75rem;
}

.players {
  display:grid;
  gap:.65rem;
}

.player-card {
  background:var(--panel);
  border:1px solid #c9cdbd;
  border-radius:.7rem;
  padding:.8rem 1rem;
}

.player-card.active {
  border:2px solid var(--forest);
  padding:calc(.8rem - 1px) calc(1rem - 1px);
  background:#f1f5e8;
}

.game-status {
  margin-top:.7rem;
  font-weight:600;
  min-height:1.5em;
}

.turn-actions:not(:empty) {
  margin-top:.6rem;
}

.results-shell {
  max-width:1100px;
}

.results-shell>.eyebrow {
  margin-bottom:.6rem;
}

#results-content {
  margin:1rem 0;
}

.results-shell table,.dialog-body table {
  border-collapse:collapse;
  max-width:100%;
}

.results-shell th,.results-shell td,.dialog-body th,.dialog-body td {
  border-bottom:1px solid var(--line);
  padding:.55rem .7rem;
  text-align:left;
}

dialog {
  color:var(--ink);
  background:var(--panel);
  border:1px solid #aaa98f;
  width:min(38rem,calc(100vw - 2rem));
  max-height:calc(100dvh - 2rem);
  padding:1.4rem 1.5rem 1.5rem;
  overflow:auto;
  overscroll-behavior:contain;
  border-radius:1rem;
  box-shadow:0 20px 70px #11291d50;
  margin:auto;
}

dialog::backdrop {
  background:#172a2194;
  backdrop-filter:blur(3px);
}

.dialog-head {
  display:flex;
  align-items:start;
  gap:.75rem;
  justify-content:space-between;
  margin-bottom:1rem;
}

.dialog-head h2 {
  font:600 clamp(1.55rem,4vw,2.1rem)/1.14 var(--serif);
  letter-spacing:-.045em;
}

.icon-button {
  width:2.6rem;
  height:2.6rem;
  min-height:2.6rem;
  padding:0;
  flex:none;
}

.dialog-actions:not(:empty) {
  margin-top:1.1rem;
}

.dialog-body {
  overflow-wrap:break-word;
}

.dialog-body p+p,.dialog-body p+ul,.dialog-body p+ol,.dialog-body h3,.dialog-body details {
  margin-top:.8rem;
}

.dialog-body img {
  height:auto;
  max-height:54vh;
  object-fit:contain;
}

.dialog-body input:not([type=radio]):not([type=checkbox]) {
  max-width:100%;
}

.dialog-body li+li {
  margin-top:.3rem;
}

.script-note {
  padding:1rem;
  text-align:center;
}

@media(min-width:1450px) {
  .lobby-layout {
    padding-top:3rem;
    padding-bottom:3.5rem;
  }
  .hero-art {
    width:min(100%,39rem);
  }
}

@media(max-width:1000px) {
  :root {
    --gutter:clamp(1.2rem,3.7vw,3rem);
  }
  .lobby-layout {
    column-gap:1.2rem;
    grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);
  }
  .intro h1 {
    font-size:clamp(2.7rem,5.2vw,3.5rem);
  }
  .setup {
    margin-top:1.2rem;
    padding-top:1rem;
  }
  .name-field input,.bot-choices span {
    height:2.7rem;
  }
  .setup-fields {
    grid-template-columns:minmax(6rem,.8fr) minmax(10.7rem,1.2fr);
    gap:.6rem;
  }
  .hero-art {
    padding-left:.6rem;
  }
  .facts {
    gap:.65rem .85rem;
  }
  .collection {
    padding-top:1.2rem;
  }
  .key-list li {
    padding-left:.6rem;
    padding-right:.6rem;
  }
  .key-list svg {
    width:2.25rem;
  }
  .game-layout {
    grid-template-columns:minmax(0,1.55fr) minmax(14rem,.85fr);
    gap:1rem;
  }
}

@media(max-width:720px) {
  .topbar-inner {
    min-height:3.8rem;
  }
  .wordmark {
    font-size:1.02rem;
    gap:.48rem;
  }
  .wordmark img {
    width:2rem;
    height:2rem;
  }
  .nav-button {
    min-height:2.65rem;
    padding:.5rem .65rem;
    font-size:.83rem;
  }
  .nav-button .icon {
    width:1.05rem;
    height:1.05rem;
  }
  .home-button span {
    display:none;
  }
  .lobby-layout {
    grid-template-columns:1fr .75fr;
    grid-template-areas:'intro art' 'setup setup';
    row-gap:1.2rem;
    padding:1.65rem 0 1.65rem;
  }
  .intro {
    align-self:center;
  }
  .intro h1 {
    font-size:clamp(2.05rem,5.75vw,2.7rem);
    margin:.7rem 0 .65rem;
  }
  .intro .eyebrow {
    font-size:.65rem;
    letter-spacing:.09em;
    gap:.35rem;
  }
  .intro .eyebrow>span {
    width:1rem;
  }
  .lead {
    font-size:1rem;
    line-height:1.4;
  }
  .facts {
    font-size:.82rem;
    margin-top:.85rem;
    gap:.3rem .65rem;
  }
  .facts .icon {
    width:.92rem;
    height:.92rem;
  }
  .hero-art {
    padding:0 .25rem .25rem 0;
  }
  .tile-stack {
    width:30%;
    bottom:0;
    left:-5%;
  }
  .setup {
    margin:0;
    max-width:none;
    padding-top:1rem;
  }
  .setup-fields {
    grid-template-columns:1fr 1.15fr;
  }
  .play-button {
    flex:1;
  }
  .lobby-actions {
    margin-top:.8rem;
  }
  .collection-heading {
    gap:.25rem .7rem;
  }
  .key-list {
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:.9rem .5rem;
  }
  .key-list li {
    border:0;
    padding:0;
  }
  .game-layout {
    grid-template-columns:minmax(0,1fr);
  }
  .participants>h2 {
    margin-bottom:.5rem;
  }
  .players {
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:.5rem;
  }
  .game-head {
    margin-bottom:.6rem;
  }
  .game-head .eyebrow {
    display:none;
  }
  .game-head h1 {
    font-size:1.7rem;
  }
  .game-shell,.results-shell {
    padding-top:1rem;
  }
  .clocks span {
    font-size:.75rem;
  }
  .clocks {
    gap:.6rem;
  }
  .clocks>div+div {
    padding-left:.6rem;
  }
}

@media(max-width:520px) {
  :root {
    --gutter:1rem;
  }
  .lobby-layout {
    grid-template-columns:1fr;
    grid-template-areas:'art' 'intro' 'setup';
    padding-top:1rem;
    row-gap:1rem;
  }
  .hero-art {
    width:min(100%,21rem);
    justify-self:center;
    padding:0;
  }
  .map-mount {
    width:100%;
    transform:none;
    padding:.2rem;
  }
  .tile-stack {
    left:-.25rem;
    bottom:-.25rem;
    width:4.8rem;
  }
  .intro h1 {
    font-size:clamp(2.6rem,9.3vw,3.3rem);
    margin:.55rem 0 .5rem;
  }
  .intro h1 br {
    display:none;
  }
  .intro h1 br:after {
    content:' ';
  }
  .intro .eyebrow {
    font-size:.64rem;
  }
  .intro .lead {
    max-width:26rem;
  }
  .facts {
    margin-top:.7rem;
  }
  .setup-fields {
    grid-template-columns:minmax(6rem,.8fr) minmax(10rem,1.2fr);
  }
  .setup label,.setup legend {
    font-size:.84rem;
  }
  .bot-choices span {
    font-size:.88rem;
  }
  .setup {
    padding-top:.8rem;
  }
  .button.play-button {
    min-height:2.95rem;
  }
  .key-list {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .key-list li {
    gap:.5rem;
  }
  .collection-heading p {
    font-size:.88rem;
  }
  .topbar nav:has(.home-button:not([hidden])) {
    gap:.3rem;
  }
  .wordmark {
    max-width:12rem;
  }
  .game-shell {
    padding-left:.55rem;
    padding-right:.55rem;
  }
  .game-head h1 {
    font-size:1.45rem;
  }
  .clocks strong {
    font-size:1.1rem;
  }
  .gameshell .turn-label {
    font-size:.88rem;
  }
  .players {
    grid-template-columns:minmax(0,1fr);
  }
  dialog {
    width:calc(100vw - 1rem);
    max-height:calc(100dvh - .75rem);
    padding:1rem;
    border-radius:.8rem;
  }
  .dialog-head {
    margin-bottom:.75rem;
  }
  .dialog-head h2 {
    font-size:1.5rem;
  }
  .collection {
    padding-bottom:1.5rem;
  }
}

@media(max-width:360px) {
  .wordmark span {
    max-width:8rem;
  }
  .lobby-layout {
    row-gap:.8rem;
  }
  .setup-fields {
    grid-template-columns:minmax(0,1fr);
  }
  .setup-fields .name-field {
    max-width:none;
  }
  .bot-choices label {
    max-width:6.25rem;
  }
  .facts {
    font-size:.77rem;
  }
  .clocks span {
    font-size:.64rem;
  }
}

@media(prefers-reduced-motion:reduce) {
  *,*::before,*::after {
    scroll-behavior:auto!important;
    animation-duration:.01ms!important;
    transition-duration:.01ms!important;
  }
}

.bank-note:not(:empty) {
  font-size:.865rem;
  color:var(--muted);
  margin-top:.8rem;
  max-width:34rem;
  line-height:1.45;
}

.board-window.board-zoomed {
  overflow:auto;
  max-height:min(75dvh,52rem);
}

body[data-screen=lobby] .home-button {
  display:none;
}

@media(min-width:721px) and (max-width:980px) {
  .key-list {
    grid-template-columns:repeat(3,minmax(0,1fr));
    row-gap:.9rem;
  }
  .key-list li:nth-child(4) {
    border-left:0;
    padding-left:0;
  }
}

@media(max-width:360px) {
  .intro h1 {
    font-size:clamp(2rem,10vw,2.25rem);
  }
  .key-list {
    grid-template-columns:1fr;
  }
  .key-list li {
    gap:.65rem;
  }
  .key-list svg {
    height:1.55rem;
  }
}

.game-head {
  position:sticky;
  z-index:6;
  top:0;
  background:var(--paper);
  padding:.5rem 0;
  border-bottom:1px solid var(--line);
}

.game-sidebar {
  min-width:0;
}

.turn-panel {
  padding:.85rem 1rem;
  margin-bottom:1rem;
  border:1px solid #bec9b4;
  border-left:4px solid #567757;
  border-radius:.55rem;
  background:#edf2e4;
}

.turn-panel .game-status {
  margin:0;
  line-height:1.35;
}

.turn-actions {
  display:block;
}

.turn-actions:empty {
  display:none;
}

.turn-actions>.button {
  margin:.25rem .25rem .25rem 0;
}

@media(min-width:721px) {
  body:has(#game:not([hidden])) .topbar-inner {
    min-height:3.6rem;
    padding-top:.45rem;
    padding-bottom:.45rem;
  }
  body:has(#game:not([hidden])) .wordmark img {
    width:2.1rem;
    height:2.1rem;
  }
  .game-shell {
    --board-width:clamp(23.5rem,calc(100dvh - 13rem),50rem);
    --sidebar-width:clamp(17rem,31vw,27rem);
    --game-gap:clamp(1rem,3vw,2.4rem);
    max-width:calc(var(--board-width) + var(--sidebar-width) + var(--game-gap) + var(--gutter) * 2);
    padding-top:.55rem;
    padding-bottom:.65rem;
  }
  .game-layout {
    grid-template-columns:minmax(0,1.52fr) minmax(0,1fr);
    gap:var(--game-gap);
  }
  @supports(grid-template-columns:minmax(0,min(100%,1rem)) 1fr) {
    .game-layout {
      grid-template-columns:minmax(0,min(var(--board-width),60.5%)) minmax(0,1fr);
    }
  }
  .game-head {
    margin-bottom:.55rem;
  }
  .game-head h1 {
    font-size:clamp(1.8rem,3.8vh,2.5rem);
  }
  .game-head .eyebrow {
    display:none;
  }
  .turn-panel {
    margin-top:.1rem;
  }
}

@media(max-width:720px) {
  .turn-panel {
    margin-bottom:.7rem;
  }
  .game-head {
    margin-top:-.6rem;
  }
  .game-sidebar {
    margin-top:-.3rem;
  }
  .game-head h1 {
    max-width:44%;
  }
  .game-head>div:first-child {
    flex:1;
  }
  .game-head h1 {
    max-width:none;
  }
}

@media(max-width:360px) {
  body:has(#game:not([hidden])) .wordmark span,body:has(#results:not([hidden])) .wordmark span {
    max-width:6.8rem;
    font-size:.86rem;
  }
  body:has(#game:not([hidden])) .topbar-inner,body:has(#results:not([hidden])) .topbar-inner {
    padding-left:.6rem;
    padding-right:.6rem;
    gap:.3rem;
  }
  .game-head {
    gap:.4rem;
  }
  .game-head h1 {
    font-size:1.3rem;
  }
}

