/* BALKANOPOLY — the board, in the old-atlas style. Everything inside #board is sized in "cqw" units
   (1cqw = 1% of the board's width), so the whole board scales as one piece. */
#boardWrap {
  flex: 0 1 calc(100dvh - 62px);
  min-width: 0;
  min-height: 0;
  container-type: size;
  display: flex;
  overflow: hidden;
  position: relative;
}
#board {
  --b: min(100cqw, 100cqh);
  width: var(--b);
  height: var(--b);
  margin: auto;
  flex: none;
  container-type: inline-size;
  position: relative;
  display: grid;
  grid-template-columns: 1.5fr repeat(9, minmax(0, 1fr)) 1.5fr;
  grid-template-rows: 1.5fr repeat(9, minmax(0, 1fr)) 1.5fr;
  gap: 0.35cqw;
  background: #6b5539;
  border: 0.5cqw double #3b2d1d;
  box-sizing: border-box;
  box-shadow: 0 1.5cqw 4cqw rgba(59, 45, 29, 0.45);
}
body.zoomed #boardWrap {
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
body.zoomed #board {
  --b: max(760px, min(100cqw, 100cqh));
}

/* ----- tiles ----- */
.tile {
  position: relative;
  background: #f3e6c8;
  color: #3b2d1d;
  display: flex;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  transition:
    opacity 0.2s,
    filter 0.2s;
}
.tile:hover {
  filter: brightness(1.04);
}
.side-top {
  flex-direction: column-reverse;
}
.side-bottom {
  flex-direction: column;
}
.side-left {
  flex-direction: row-reverse;
}
.side-right {
  flex-direction: row;
}
.band {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.3cqw;
  padding: 0.3cqw 0.5cqw;
  background: var(--gc, #4a3a28);
  position: relative;
  z-index: 1;
}
.side-top .band,
.side-bottom .band {
  height: 2.5cqw;
}
.side-left .band,
.side-right .band {
  width: 3.2cqw;
  flex-direction: column;
  justify-content: flex-start;
  padding: 0.5cqw 0.3cqw;
}

.tile .flag {
  width: 2.9cqw;
  height: 1.93cqw;
  border-radius: 0;
  box-shadow: 0 0 0 0.12cqw #3b2d1d;
}
.band .bi {
  display: grid;
  place-items: center;
  width: 2cqw;
  height: 2cqw;
}
.band .bi svg {
  width: 100%;
  height: 100%;
}
.body {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2cqw;
  padding: 0.35cqw;
  text-align: center;
  position: relative;
  z-index: 1;
}
/* room reserved for player tokens */
.side-top .body {
  padding-top: 4.4cqw;
}
.side-bottom .body {
  padding-bottom: 4.4cqw;
}
.side-left .body {
  padding: 0.3cqw 0.35cqw 3.7cqw 1.2cqw;
}
.side-right .body {
  padding: 0.3cqw 1.2cqw 3.7cqw 0.35cqw;
}
.corner .body {
  padding: 0.3cqw 0.4cqw 5.4cqw !important;
  gap: 0.3cqw;
  justify-content: flex-start;
}
.nm {
  font-family: 'EB Garamond', Georgia, serif;
  font-weight: 700;
  font-size: 1.75cqw;
  line-height: 1;
  hyphens: manual;
  -webkit-hyphens: manual;
  overflow-wrap: break-word;
  max-width: 100%;
}
.nm.long {
  font-size: 1.5cqw;
  letter-spacing: -0.01em;
}
.pr {
  /* prices in typewriter numbers (design kit v8.1) */
  font-family: 'Courier Prime', 'Courier New', monospace;
  font-weight: 400;
  font-size: 1.4cqw;
  line-height: 1.15;
  color: #5c4830;
  white-space: nowrap;
}
.ic {
  display: grid;
  place-items: center;
  width: 3cqw;
  height: 3cqw;
}
.ic svg {
  width: 100%;
  height: 100%;
}
.corner {
  background: #ead6ac;
}
.corner .ic {
  width: 3.4cqw;
  height: 3.4cqw;
  margin-top: 0.3cqw;
}
.t-tax .ic {
  width: 2.3cqw;
  height: 2.3cqw;
}
.t-tax .nm {
  font-size: 1.55cqw;
}
.corner .nm {
  font-family: 'IM Fell English SC', Georgia, serif;
  font-weight: 400;
  font-size: 1.9cqw;
  letter-spacing: 0.04em;
}
.t-airport .nm {
  font-family: 'IM Fell English SC', Georgia, serif;
  font-weight: 400;
  font-size: 2cqw;
  letter-spacing: 0.06em;
}
.t-chance,
.t-chest,
.t-tax {
  background: #efdfba;
}
.tile.focus {
  outline: 0.45cqw solid #b5543c;
  outline-offset: -0.45cqw;
  z-index: 2;
  animation: glow 1s infinite alternate;
}
@keyframes glow {
  to {
    outline-color: #c9a24a;
  }
}
.tile.dest {
  outline: 0.45cqw dashed #7a3e1d;
  outline-offset: -0.45cqw;
  z-index: 2;
  animation: destp 0.7s infinite alternate;
}
@keyframes destp {
  from {
    box-shadow: inset 0 0 0 0 rgba(201, 162, 74, 0);
  }
  to {
    box-shadow: inset 0 0 0 2cqw rgba(201, 162, 74, 0.45);
  }
}
.tile.sib {
  outline: 0.4cqw solid #3b2d1d;
  outline-offset: -0.4cqw;
  box-shadow: 0 0 1.4cqw 0.3cqw rgba(59, 45, 29, 0.55);
  z-index: 2;
}
.tile.dim,
.pin.dim {
  opacity: 0.28;
}

/* ownership: tint + wax seal (owner's colour and initial) + crown on a complete country;
   houses are little drawn houses under the name, a hotel is one grand-hotel drawing */
/* v8.1b: a softer tint and a thinner owner edge, the same on every side */
.owned {
  background: color-mix(in srgb, var(--oc) 22%, #f3e6c8);
  box-shadow: inset 0 0 0 0.22cqw var(--oc);
}
.ob,
.cr {
  position: absolute;
  z-index: 3;
  display: none;
}
.ob {
  width: 2.7cqw;
  height: 2.7cqw;
  min-width: 14px;
  min-height: 14px;
  filter: drop-shadow(0 0.12cqw 0.12cqw rgba(59, 45, 29, 0.45));
}
.cr {
  width: 2cqw;
  height: 2cqw;
  min-width: 11px;
  min-height: 11px;
}
.owned .ob {
  display: block;
}
.ob svg {
  width: 100%;
  height: 100%;
  display: block;
}
.owned.full .cr {
  display: block;
}
.cr svg {
  width: 100%;
  height: 100%;
}
.side-top .ob {
  right: 0.25cqw;
  top: 0.25cqw;
}
.side-top .cr {
  right: 3.7cqw;
  top: 0.6cqw;
}
.side-right .ob {
  right: 0.25cqw;
  bottom: 0.25cqw;
}
.side-right .cr {
  right: 0.9cqw;
  bottom: 3.7cqw;
}
.side-bottom .ob {
  right: 0.25cqw;
  bottom: 0.25cqw;
}
.side-bottom .cr {
  right: 3.7cqw;
  bottom: 0.6cqw;
}
.side-left .ob {
  left: 0.25cqw;
  bottom: 0.25cqw;
}
.side-left .cr {
  left: 0.9cqw;
  bottom: 3.7cqw;
}
.hs {
  display: none;
  align-items: flex-end;
  justify-content: center;
  min-height: 2.2cqw;
}
.built .hs {
  display: flex;
}
.built .pr {
  display: none;
}
.built .cr {
  display: none !important;
}
.hs svg {
  flex: none;
  display: block;
}
.hs .hse {
  width: 2.15cqw;
  height: 2.15cqw;
}
.hs .hse + .hse {
  margin-left: -0.35cqw;
}
.hs .htl {
  width: 4.2cqw;
  height: 2.7cqw;
}
.hs .hn {
  display: none;
  font:
    italic 700 1.6cqw/1 'EB Garamond',
    Georgia,
    serif;
  color: #3b2d1d;
  margin-left: 0.1cqw;
}
@container (max-width:560px) {
  .hs .hse + .hse {
    display: none;
  }
  .hs .hn {
    display: inline;
    font-size: 2.1cqw;
  }
  .hs .hse {
    width: 2.6cqw;
    height: 2.6cqw;
  }
  .hs .htl {
    width: 4.6cqw;
    height: 3cqw;
  }
}
/* two-line names (Stara Zagora, Thessaloniki): smaller seal and smaller house drawings (still one drawing per house) */
.l2 .ob {
  width: 2.3cqw;
  height: 2.3cqw;
}
.side-top.l2.built .body {
  padding-top: 3.2cqw;
}
.side-bottom.l2.built .body {
  padding-bottom: 3.2cqw;
}
.l2 .hs {
  min-height: 1.8cqw;
}
.l2 .hs .hse {
  width: 1.55cqw;
  height: 1.55cqw;
}
.l2 .hs .htl {
  width: 3.2cqw;
  height: 2cqw;
}
.mk {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 2;
  background: repeating-linear-gradient(45deg, #0000 0 0.8cqw, rgba(59, 45, 29, 0.16) 0.8cqw 1.1cqw);
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
  padding: 1.3cqw;
}
.side-top .mk {
  align-items: flex-start;
}
.side-left .mk {
  justify-content: flex-start;
  padding-left: 1.4cqw;
}
.side-right .mk {
  justify-content: flex-end;
  padding-right: 1.4cqw;
}
.mortgaged .mk {
  display: flex;
}
.mortgaged .nm,
.mortgaged .pr {
  opacity: 0.55;
}
.mk em {
  /* v8.1b: a neat upright label instead of a tilted red stamp; the hatching says the rest */
  font-style: normal;
  font-family: 'Courier Prime', 'Courier New', monospace;
  font-weight: 700;
  font-size: 0.95cqw;
  letter-spacing: 0.02em;
  color: #9a2b1d;
  border: 0.12cqw solid #9a2b1d;
  padding: 0.1cqw 0.4cqw;
  background: #f3e6c8e6;
}

/* ----- centre: title, map, dice, journal ----- */
#center {
  grid-row: 2/11;
  grid-column: 2/11;
  margin: 0.4cqw;
  background: #efe1bf;
  box-shadow: inset 0 0 4cqw rgba(107, 85, 57, 0.45);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.4cqw 2cqw 1.6cqw;
  gap: 0.6cqw;
  color: #3b2d1d;
  min-height: 0;
  overflow: hidden;
  position: relative;
}
.cart {
  display: flex;
  align-items: center;
  gap: 1.6cqw;
}
.cart span {
  width: 7cqw;
  height: 1px;
  background: #4a3a28;
}
.cart b {
  font-family: 'IM Fell English SC', Georgia, serif;
  font-weight: 400;
  font-size: 4.6cqw;
  line-height: 1;
  letter-spacing: 0.08em;
}
.ctag {
  font-family: 'EB Garamond', Georgia, serif;
  font-style: italic;
  font-size: 1.35cqw;
  letter-spacing: 0.22em;
  color: #6b5539;
  margin-top: -0.2cqw;
}
.mapwrap {
  position: relative;
  width: 65cqw;
  aspect-ratio: 1536/1024;
  flex: none;
  border: 1px solid #6b5539;
  box-shadow:
    0 0 0 0.5cqw #efe1bf,
    0 0 0 0.62cqw #6b5539;
}
.mapwrap > svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
#pins,
#notes {
  position: absolute;
  inset: 0;
}
#notes {
  pointer-events: none;
  z-index: 6;
}
.pin {
  position: absolute;
  width: 0;
  height: 0;
  cursor: pointer;
  z-index: 2;
  transition: opacity 0.2s;
}
.pin .pmark {
  position: absolute;
  left: 0;
  top: 0;
}
.pin .dot {
  position: absolute;
  left: -0.55cqw;
  top: -0.55cqw;
  width: 1.1cqw;
  height: 1.1cqw;
  border-radius: 50%;
  background: #f3e6c8;
  border: 0.22cqw solid #6b5539;
  box-sizing: border-box;
  display: block;
}
.pin .pplane {
  position: absolute;
  left: -1cqw;
  top: -1cqw;
  width: 2cqw;
  height: 2cqw;
  border-radius: 50%;
  background: #6b5539;
  display: grid;
  place-items: center;
  border: 0.15cqw solid #f3e6c8;
  box-sizing: border-box;
}
.pin.owned .pplane {
  background: var(--oc);
  border-color: #3b2d1d;
}
.pin .pplane svg {
  width: 70%;
  height: 70%;
}
.plab {
  position: absolute;
  white-space: nowrap;
  font-family: 'EB Garamond', Georgia, serif;
  font-style: italic;
  font-size: max(1.35cqw, 9px);
  line-height: 1;
  color: #3b2d1d;
  text-shadow:
    0 0 2px #f3e6c8,
    0 0 2px #f3e6c8,
    0 0 3px #f3e6c8;
}
.pin.owned .plab {
  font-style: normal;
  font-weight: 700;
}
.pin:hover {
  z-index: 5;
}
.pin:hover .plab {
  text-decoration: underline;
}
.note {
  position: absolute;
  transform: translate(-8%, -100%) translateY(-3.6cqw);
  max-width: 24cqw;
  background: #fbf4e2;
  border: 1px solid #3b2d1d;
  box-shadow: 0.3cqw 0.3cqw 0 rgba(59, 45, 29, 0.35);
  padding: 0.5cqw 0.8cqw;
  font-family: 'EB Garamond', Georgia, serif;
  font-size: max(1.35cqw, 10px);
  line-height: 1.2;
  color: #3b2d1d;
  animation: notein 0.35s cubic-bezier(0.3, 1.4, 0.5, 1);
  transition:
    opacity 0.5s,
    transform 0.5s;
}
.note::after {
  content: '';
  position: absolute;
  left: 6%;
  bottom: -0.7cqw;
  width: 1.2cqw;
  height: 1.2cqw;
  background: #fbf4e2;
  border-right: 1px solid #3b2d1d;
  border-bottom: 1px solid #3b2d1d;
  transform: rotate(45deg);
}
.note.flip {
  transform: translate(-92%, -100%) translateY(-3.6cqw);
}
.note.flip::after {
  left: auto;
  right: 6%;
}
.note.below {
  transform: translate(-8%, 0) translateY(2cqw);
}
.note.below.flip {
  transform: translate(-92%, 0) translateY(2cqw);
}
.note.below::after {
  bottom: auto;
  top: -0.7cqw;
  transform: rotate(225deg);
}
.note.go {
  opacity: 0;
}
@keyframes notein {
  from {
    opacity: 0;
    scale: 0.7;
  }
}
.hlchip {
  position: absolute;
  left: 50%;
  top: 0.8cqw;
  transform: translateX(-50%);
  z-index: 7;
  border: 1px solid #3b2d1d;
  background: #fbf4e2;
  color: #3b2d1d;
  font-family: 'EB Garamond', Georgia, serif;
  font-weight: 700;
  font-size: max(1.4cqw, 11px);
  padding: 0.4cqw 1cqw;
  cursor: pointer;
  box-shadow: 0.3cqw 0.3cqw 0 rgba(59, 45, 29, 0.35);
}
.jfull {
  position: absolute;
  inset: 0;
  z-index: 8;
  background: #fbf4e2;
  display: flex;
  flex-direction: column;
  border: 1px solid #6b5539;
}
.jhead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8cqw 1.2cqw;
  border-bottom: 1px solid #c9b48c;
  font-family: 'IM Fell English SC', Georgia, serif;
  font-size: max(2cqw, 14px);
}
.jhead b {
  font-weight: 400;
}
#log {
  flex: 1;
  overflow-y: auto;
  padding: 0.4cqw 1.2cqw;
  font-family: 'EB Garamond', Georgia, serif;
  font-size: max(1.6cqw, 12px);
  line-height: 1.35;
  scrollbar-width: thin;
}
#log div {
  padding: 0.45cqw 0;
  border-bottom: 1px dashed #d4c29c;
  color: #3b2d1d;
}
#log div span {
  display: inline-block;
  min-width: 5.6cqw;
  color: #8a7553;
  font-style: italic;
  margin-right: 0.6cqw;
}
#log div:first-child {
  font-weight: 700;
}
.crow {
  display: flex;
  align-items: stretch;
  gap: 1.2cqw;
  width: 62cqw;
  margin-top: 0.6cqw;
  min-height: 0;
}
.dice {
  display: flex;
  gap: 1cqw;
  align-items: center;
  filter: drop-shadow(0 0.5cqw 0.6cqw rgba(59, 45, 29, 0.5));
}
/* the Vacation fund sits on the Vacation corner itself */
.vpot {
  display: inline-block;
  margin-top: 0.3cqw;
  padding: 0.25cqw 0.7cqw;
  background: #fbf4e2;
  border: 0.15cqw solid #c9a24a;
  box-shadow: 0 0 0 0.12cqw #6b5539;
  font-family: 'Courier Prime', 'Courier New', monospace;
  font-size: max(1.9cqw, 11px);
  font-weight: 700;
  line-height: 1.1;
  color: #3b2d1d;
  white-space: nowrap;
}
.jstrip {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.2cqw;
  padding: 0.4cqw max(7.5cqw, 64px) 0.4cqw 1cqw;
  border: 1px solid #6b5539;
  background: #f3e6c8;
  text-align: left;
  font-family: 'EB Garamond', Georgia, serif;
  font-size: max(1.4cqw, 11px);
  line-height: 1.2;
  color: #3b2d1d;
  cursor: pointer;
  position: relative;
}
.jstrip span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.jstrip span:first-child {
  font-weight: 700;
}
.jstrip span.old {
  color: #6b5539;
}
.jstrip em {
  /* v8.1c: the "journal" hint has its own space on the right, so it never covers the text */
  position: absolute;
  right: 0.6cqw;
  top: 50%;
  transform: translateY(-50%);
  font-family: 'Courier Prime', 'Courier New', monospace;
  font-style: normal;
  font-size: max(1.05cqw, 9px);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b5539;
}
.jstrip:hover {
  background: #fbf4e2;
}

/* 3D dice: ivory with sepia pips */
.die3 {
  width: 5.4cqw;
  height: 5.4cqw;
  perspective: 40cqw;
}
.cube {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.95s cubic-bezier(0.2, 0.75, 0.25, 1.05);
}
.face {
  position: absolute;
  inset: 0;
  background: #fbf4e2;
  border-radius: 0.9cqw;
  display: grid;
  grid-template: repeat(3, 1fr) / repeat(3, 1fr);
  padding: 0.75cqw;
  box-shadow:
    inset 0 0 0 0.18cqw #8a7553,
    inset 0 -0.35cqw 0 #d9c59c;
  backface-visibility: hidden;
}
.face i {
  border-radius: 50%;
  margin: 14%;
}
.face i.on {
  background: #3b2d1d;
}
.f1 {
  transform: translateZ(2.7cqw);
}
.f6 {
  transform: rotateY(180deg) translateZ(2.7cqw);
}
.f2 {
  transform: rotateY(90deg) translateZ(2.7cqw);
}
.f5 {
  transform: rotateY(-90deg) translateZ(2.7cqw);
}
.f3 {
  transform: rotateX(90deg) translateZ(2.7cqw);
}
.f4 {
  transform: rotateX(-90deg) translateZ(2.7cqw);
}

/* ----- player pieces: a drawn pawn in the player's colour, their emblem on it, initials below ----- */
#tokens {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 5;
}
.tok {
  position: absolute;
  transform: translate(-50%, -62%);
  transition:
    left 0.17s linear,
    top 0.17s linear,
    opacity 0.2s;
  z-index: 1;
  width: max(3.2cqw, 20px);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.tok.jump {
  transition:
    left 0.5s ease-in-out,
    top 0.5s ease-in-out;
}
.tok .pw {
  display: block;
  width: 100%;
  filter: drop-shadow(0 0.3cqw 0.3cqw rgba(59, 45, 29, 0.5));
}
.tok .pw svg {
  display: block;
  width: 100%;
  height: auto;
}
.tok b {
  position: absolute;
  top: 44%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-weight: 400;
  font-size: max(1.15cqw, 8px);
  line-height: 1;
  pointer-events: none;
}
/* v9.6: the pawn's emblem on a small paper disc */
.tok b:has(svg) {
  width: max(1.7cqw, 12px);
  height: max(1.7cqw, 12px);
  border-radius: 50%;
  background: #fbf4e2;
  border: 1px solid #3b2d1d;
  display: grid;
  place-items: center;
}
.tok b svg.emb {
  width: 82%;
  height: 82%;
}
.tok i {
  font-style: normal;
  font-family: 'EB Garamond', Georgia, serif;
  font-weight: 800;
  font-size: max(0.95cqw, 7px);
  line-height: 1;
  background: #3b2d1d;
  color: #f3e6c8;
  padding: 0.1cqw 0.35cqw;
  margin-top: -0.25cqw;
  border-radius: 0.2cqw;
  white-space: nowrap;
}
.tok.hop .pw {
  animation: hop var(--hopt, 0.17s) cubic-bezier(0.45, 0, 0.55, 1);
}
.tok.walking {
  transition-timing-function: linear;
}
@keyframes hop {
  0%,
  100% {
    transform: none;
  }
  50% {
    transform: translateY(-1cqw) scale(1.08);
  }
}
.tok.active {
  z-index: 3;
}
.tok.active .pw {
  animation: bob 1s ease-in-out infinite alternate;
  filter: drop-shadow(0 0 0.7cqw var(--c)) drop-shadow(0 0.3cqw 0.3cqw rgba(59, 45, 29, 0.5));
}
.tok.hop.active .pw {
  animation: hop var(--hopt, 0.17s) cubic-bezier(0.45, 0, 0.55, 1);
}
@keyframes bob {
  to {
    transform: translateY(-0.5cqw);
  }
}
.tok.jail::after {
  content: '';
  position: absolute;
  right: -0.6cqw;
  top: -0.4cqw;
  width: max(1.5cqw, 10px);
  height: max(1.5cqw, 10px);
  background: no-repeat center/contain
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23f3e6c8' stroke='%233b2d1d' stroke-width='2'%3E%3Crect x='5' y='11' width='14' height='10' rx='1'/%3E%3Cpath d='M8 11V7a4 4 0 018 0v4' fill='none'/%3E%3C/svg%3E");
}
.tok.out {
  display: none;
}
.tok.dim {
  opacity: 0.3;
}

/* houses pop in, freshly bought tiles flash, money floats, coins fly */
.hs svg.pop {
  animation: popin 0.55s cubic-bezier(0.3, 1.6, 0.5, 1);
}
@keyframes popin {
  0% {
    transform: scale(0) translateY(-1cqw);
  }
  70% {
    transform: scale(1.5);
  }
  100% {
    transform: scale(1);
  }
}
.tile.bought {
  animation: flash 0.9s ease-out;
}
@keyframes flash {
  0% {
    box-shadow:
      inset 0 0 0 0.32cqw var(--oc),
      0 0 0 0 var(--oc);
  }
  40% {
    box-shadow:
      inset 0 0 0 0.32cqw var(--oc),
      0 0 1.6cqw 0.7cqw var(--oc);
    transform: scale(1.06);
    z-index: 3;
  }
  100% {
    box-shadow:
      inset 0 0 0 0.32cqw var(--oc),
      0 0 0 0 transparent;
  }
}
.fly {
  position: absolute;
  transform: translate(-50%, -140%);
  font-family: 'EB Garamond', Georgia, serif;
  font-weight: 800;
  font-size: max(2cqw, 13px);
  white-space: nowrap;
  pointer-events: none;
  z-index: 8;
  text-shadow:
    0 0 3px #f3e6c8,
    0 0 3px #f3e6c8,
    0 0 5px #f3e6c8;
  animation: floatup 1.6s ease-out forwards;
}
.fly.up {
  color: #2f6b3a;
}
.fly.down {
  color: #9a2b1d;
}
@keyframes floatup {
  0% {
    opacity: 0;
    transform: translate(-50%, -90%) scale(0.7);
  }
  15% {
    opacity: 1;
    transform: translate(-50%, -150%) scale(1.15);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -330%) scale(1);
  }
}
.coin {
  position: absolute;
  transform: translate(-50%, -50%);
  width: max(2cqw, 13px);
  height: max(2cqw, 13px);
  border-radius: 50%;
  background: #e0b84a;
  border: 0.2cqw solid #7a5a1d;
  box-sizing: border-box;
  pointer-events: none;
  z-index: 9;
  transition:
    left 0.8s cubic-bezier(0.4, 0, 0.2, 1),
    top 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}
.coin.go {
  animation: coinarc 0.8s ease-in-out;
}
@keyframes coinarc {
  50% {
    transform: translate(-50%, -50%) translateY(-4cqw) scale(1.35);
  }
}
@media (prefers-reduced-motion: reduce) {
  .tok,
  .tok .pw,
  .cube {
    transition: none !important;
    animation: none !important;
  }
  .hs svg.pop,
  .tile.bought,
  .fly,
  .coin,
  .note {
    animation: none !important;
    transition: none !important;
  }
}
/* the Vacation corner holds the fund under its name: smaller icon, tighter spacing, above the pawns */
.t-vacation .body {
  gap: 0.15cqw !important;
  padding-top: 0.2cqw !important;
}
.t-vacation .ic {
  width: 2.3cqw !important;
  height: 2.3cqw !important;
  margin-top: 0 !important;
}
.t-vacation .nm {
  font-size: 1.7cqw !important;
}
.t-vacation .ic {
  display: none !important;
}
.t-vacation .body {
  padding-top: 0.8cqw !important;
}

/* ---- painted map: owned countries and borders (js/map.js) ---- */
.pmap {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.pmap .wash {
  mix-blend-mode: multiply;
}
.pmap .flood {
  opacity: 0;
  transition:
    opacity 1.2s ease,
    fill 0.6s;
}
.pmap .flood.on {
  opacity: 0.42;
}
.pmap .borders {
  fill: none;
  stroke: #5a4630;
  stroke-width: 2.2;
  stroke-dasharray: 9 6;
  stroke-linejoin: round;
  opacity: 0.75;
}
@media (prefers-reduced-motion: reduce) {
  .pmap .flood {
    transition: none;
  }
}

/* owner's ribbon: a thick stripe in the owner's colour along the inner side of the space, right next to
   the country band, so the board's inner ring shows at a glance who owns what */
.tile.owned::after {
  content: '';
  position: absolute;
  z-index: 2;
  pointer-events: none;
  background: var(--oc);
  box-shadow: 0 0 0 0.12cqw rgba(59, 45, 29, 0.55);
}
.side-top.owned::after {
  left: 0;
  right: 0;
  bottom: 2.5cqw;
  height: 0.75cqw;
}
.side-bottom.owned::after {
  left: 0;
  right: 0;
  top: 2.5cqw;
  height: 0.75cqw;
}
.side-left.owned::after {
  top: 0;
  bottom: 0;
  right: 3.2cqw;
  width: 0.75cqw;
}
.side-right.owned::after {
  top: 0;
  bottom: 0;
  left: 3.2cqw;
  width: 0.75cqw;
}
/* a whole country: the ribbon gets a gold edge */
.tile.owned.full::after {
  box-shadow:
    0 0 0 0.16cqw #c9a24a,
    0 0 0 0.3cqw #3b2d1d;
}
/* mortgaged: dashed, faded ribbon */
.tile.owned.mortgaged::after {
  background: repeating-linear-gradient(45deg, var(--oc) 0 0.45cqw, transparent 0.45cqw 0.9cqw);
  opacity: 0.7;
}
.side-left.owned .body {
  padding-right: 0.95cqw;
}
.side-right.owned .body {
  padding-left: 0.95cqw;
}
.side-left.owned .nm,
.side-right.owned .nm {
  font-size: 1.62cqw;
  letter-spacing: -0.02em;
}
.side-top.owned.l2 .body {
  padding-bottom: 0.6cqw;
}
.side-bottom.owned.l2 .body {
  padding-top: 0.6cqw;
}
.side-top.owned.l2 .body,
.side-bottom.owned.l2 .body {
  justify-content: flex-start;
  padding-top: 2.6cqw;
}
.side-bottom.owned.l2 .body {
  justify-content: flex-end;
  padding: 0.3cqw 0.35cqw 4.4cqw;
}
.owned.l2 .nm {
  font-size: 1.45cqw;
}

/* buying: the wax seal stamps down and the owner's ribbon paints along the edge */
.tile.bought .ob {
  animation: stamp 0.75s cubic-bezier(0.3, 1.3, 0.5, 1) both;
}
@keyframes stamp {
  0% {
    transform: scale(2.6) rotate(-25deg);
    opacity: 0;
  }
  55% {
    transform: scale(0.88) rotate(4deg);
    opacity: 1;
  }
  75% {
    transform: scale(1.06) rotate(-1deg);
  }
  100% {
    transform: none;
  }
}
.tile.bought .ob::after {
  content: '';
  position: absolute;
  inset: -20%;
  border-radius: 50%;
  border: 0.25cqw solid var(--oc);
  animation: inkring 0.9s 0.35s ease-out both;
  pointer-events: none;
}
@keyframes inkring {
  from {
    transform: scale(0.6);
    opacity: 0.8;
  }
  to {
    transform: scale(2);
    opacity: 0;
  }
}
.side-top.bought::after,
.side-bottom.bought::after {
  animation: paintx 0.7s 0.45s ease-out both;
  transform-origin: left;
}
.side-left.bought::after,
.side-right.bought::after {
  animation: painty 0.7s 0.45s ease-out both;
  transform-origin: top;
}
@keyframes paintx {
  from {
    transform: scaleX(0);
  }
}
@keyframes painty {
  from {
    transform: scaleY(0);
  }
}
/* the turn ribbon */
.ribbon {
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 1cqw;
  padding: 0.9cqw 4cqw;
  background: linear-gradient(#fbf4e2, #efe1bf);
  border-top: 0.3cqw solid var(--c, #7a3e1d);
  border-bottom: 0.3cqw solid var(--c, #7a3e1d);
  box-shadow: 0 0.6cqw 1.6cqw rgba(59, 45, 29, 0.45);
  font-family: 'IM Fell English SC', Georgia, serif;
  font-size: 3.2cqw;
  color: #3b2d1d;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%);
  clip-path: polygon(0 0, 100% 0, 97% 50%, 100% 100%, 0 100%, 3% 50%);
}
.ribbon b {
  font-weight: 400;
  letter-spacing: 0.04em;
}
.ribbon .rseal {
  display: grid;
  place-items: center;
  width: 4cqw;
  height: 4cqw;
  border-radius: 50%;
  background: radial-gradient(
    circle at 35% 30%,
    color-mix(in srgb, var(--c) 60%, #fff),
    var(--c) 60%,
    color-mix(in srgb, var(--c) 60%, #000)
  );
  color: #fbf4e2;
  font-size: 2.4cqw;
  box-shadow: 0 0 0 0.15cqw #3b2d1d;
}
.ribbon.go {
  animation: ribbon 1.7s cubic-bezier(0.25, 0.8, 0.3, 1) both;
}
@keyframes ribbon {
  0% {
    opacity: 0;
    transform: translate(-130%, -50%) skewX(-12deg);
  }
  22% {
    opacity: 1;
    transform: translate(-50%, -50%) skewX(0);
  }
  78% {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
  100% {
    opacity: 0;
    transform: translate(30%, -50%) skewX(10deg);
  }
}
@media (prefers-reduced-motion: reduce) {
  .ribbon.go {
    animation: ribbonfade 1.7s both;
  }
  @keyframes ribbonfade {
    0%,
    100% {
      opacity: 0;
    }
    20%,
    80% {
      opacity: 1;
    }
  }
  .tile.bought .ob,
  .tile.bought .ob::after,
  .tile.bought::after {
    animation: none !important;
  }
}

/* a whole country owned: clean fill and a solid border in the owner's colour (ink-lined) */
.pmap .flood.on {
  opacity: 0.5;
}
.pmap .owned-borders path {
  fill: none;
  stroke-width: 7;
  stroke-linejoin: round;
  opacity: 0;
  transition: opacity 0.8s;
  paint-order: stroke;
}
.pmap .owned-borders path.on {
  opacity: 1;
  filter: drop-shadow(0 0 1.5px #3b2d1d) drop-shadow(0 0 1px #3b2d1d);
}

/* ---- everything centred in its box (v6.9.2) ----
   name, price and icon sit in the middle of the space next to the colour band (or the whole square
   when there is no band); pawns, houses and seals draw on top as before */
.tile .body,
.tile.corner .body,
.tile.t-vacation .body {
  justify-content: center !important;
  align-items: center !important;
  padding: 0.4cqw !important;
  gap: 0.25cqw !important;
}
.tile .body > * {
  flex: none;
}
.tile.corner .ic {
  margin-top: 0;
}
/* the owner's wax seal (and the country crown) sit ON the owner's ribbon next to the colour band,
   never on the name; the text moves a little away from the ribbon */
.tile.owned .ob {
  /* v8.1b: smaller seal, always in the same spot on the owner's ribbon */
  width: 2.3cqw !important;
  height: 2.3cqw !important;
  top: auto !important;
  bottom: auto !important;
  left: auto !important;
  right: auto !important;
}
.tile.owned .cr {
  width: 1.6cqw !important;
  height: 1.6cqw !important;
  top: auto !important;
  bottom: auto !important;
  left: auto !important;
  right: auto !important;
}
.tile.side-top.owned .ob { bottom: 1.725cqw !important; right: 0.3cqw !important; }
.tile.side-top.owned .cr { bottom: 2.075cqw !important; right: 2.8cqw !important; }
.tile.side-bottom.owned .ob { top: 1.725cqw !important; right: 0.3cqw !important; }
.tile.side-bottom.owned .cr { top: 2.075cqw !important; right: 2.8cqw !important; }
.tile.side-left.owned .ob { right: 2.425cqw !important; bottom: 0.3cqw !important; }
.tile.side-left.owned .cr { right: 2.775cqw !important; bottom: 2.8cqw !important; }
.tile.side-right.owned .ob { left: 2.425cqw !important; bottom: 0.3cqw !important; }
.tile.side-right.owned .cr { left: 2.775cqw !important; bottom: 2.8cqw !important; }
.tile.side-top.owned .body { padding-bottom: 1.7cqw !important; }
.tile.side-bottom.owned .body { padding-top: 1.7cqw !important; }
.tile.side-left.owned .body { padding-right: 1.7cqw !important; }
.tile.side-right.owned .body { padding-left: 1.7cqw !important; }
