/* GLAD-O-POLIS 2.0 — Das Spielbrett.
   Maße und Schriftgrade sind vom gedruckten Brett (referenz/brett.html)
   übernommen. Das Brett wird in Originalgröße aufgebaut und als Ganzes
   skaliert — deshalb bricht keine Feldbeschriftung um, egal wie klein der
   Bildschirm ist. Farben ausschließlich über die Werte aus tokens.css. */

.brett-buehne {
  position: relative;
  flex: 0 0 auto;
  overflow: hidden;
}

.brett {
  position: absolute;
  left: 0;
  top: 0;
  /* Breite und Hoehe setzt js/ui/brett.js auf die Originalmasse des
     gedruckten Bretts; skaliert wird das Ganze ueber transform. */
  transform-origin: top left;
  display: grid;
  grid-template-columns: 145px repeat(9, 90px) 145px;
  grid-template-rows: 145px repeat(9, 90px) 145px;
  gap: 1px;
  background: var(--blau);
  border: 1px solid var(--blau);
  box-sizing: border-box;
}

/* ---------- Felder ---------- */

.feld {
  position: relative;
  background: var(--papier-hell);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.feld-knopf {
  width: 90px;
  height: 145px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
  text-align: center;
}

.feld--ecke .feld-knopf {
  width: 145px;
  height: 145px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
}

.feld-knopf--sonder {
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 6px;
}

.feld-knopf:focus-visible {
  outline: 3px solid var(--rot);
  outline-offset: -3px;
}

.feld-band {
  height: 26px;
  border-bottom: 1px solid var(--blau);
  flex: 0 0 auto;
}

.feld-koerper {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 9px 5px 8px;
}

.feld-name {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--blau);
}

.feld-name--klein { font-size: 13px; line-height: 1.05; letter-spacing: .03em; }
.feld-name--eng { font-size: 12px; }
.feld-name--karte { font-size: 14px; line-height: 1; letter-spacing: .04em; }
.feld-name--rot { color: var(--rot); }

.feld-preis {
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--blau-hell);
}

.feld-preis--abgabe { color: var(--rot); }
.feld-preis--zweizeilig { font-size: 11px; line-height: 1.1; letter-spacing: 0; }

.feld-symbol { color: var(--blau); display: flex; }
.feld-symbol--rot { color: var(--rot); }
.feld-symbol--messing { color: var(--messing); }

/* ---------- Ecken ---------- */

.ecke-titel {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 17px;
  line-height: 1;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--blau);
}
.ecke-titel--klein { font-size: 14px; line-height: 1.1; }

.ecke-unterzeile {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 11px;
  line-height: 1.15;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--blau);
}
.ecke-unterzeile--normal {
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--blau-hell);
}

.ecke-los {
  font-family: var(--schrift-titel);
  font-size: 25px;
  line-height: .95;
  letter-spacing: -.01em;
  color: var(--rot);
}
.ecke-pfeil { color: var(--rot); display: flex; }
.ecke-pfeil svg { width: 40px; height: 22px; }

/* ---------- Besitz und Bauten ---------- */

.feld-besitz {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
  padding: 2px;
}

.feld-besitz--belegt { box-shadow: inset 0 0 0 3px var(--besitzfarbe); }

.bau {
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--gruen-wappen);
  border: 1px solid var(--kontur);
  margin-top: 28px;
}

.bau--leuchtturm {
  width: 20px;
  height: 14px;
  background: var(--rot);
  color: var(--papier-hell);
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 10px;
  line-height: 12px;
  text-align: center;
}

.bau-hinweis {
  align-self: flex-end;
  margin: 0 0 2px 0;
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 10px;
  line-height: 1;
  padding: 1px 3px;
  border-radius: 2px;
  background: var(--messing-dunkel);
  color: var(--papier-hell);
}
.bau-hinweis--denkmal { background: var(--blau-hell); }

.feld--beliehen .feld-knopf { opacity: .55; }

/* ---------- Figuren ---------- */

.figurenebene { position: absolute; inset: 0; pointer-events: none; }

.figur {
  position: absolute;
  width: 26px;
  height: 26px;
  margin: -13px 0 0 -13px;
  border-radius: 50%;
  background: var(--figurfarbe);
  border: 2px solid var(--papier-hell);
  box-shadow: 0 1px 3px rgba(20, 36, 61, .45);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: left var(--dauer-figur) linear, top var(--dauer-figur) linear;
}

.figur-zeichen {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 12px;
  line-height: 1;
  color: var(--papier-hell);
}

.figur--amzug { box-shadow: 0 0 0 3px var(--gold-krone), 0 1px 3px rgba(20, 36, 61, .45); }
.figur--pleite { opacity: .45; }

/* ---------- Mitte ---------- */

.brett-mitte {
  grid-column: 2 / 11;
  grid-row: 2 / 11;
  background: var(--papier-hell);
  position: relative;
  overflow: hidden;
}

.mitte-beschlusslage {
  position: absolute;
  left: 199px;
  top: 22px;
  width: 420px;
  height: 60px;
  box-sizing: border-box;
  border: 1.5px dashed var(--messing);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 4px 8px;
}

.mitte-beschlusslage-titel {
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--messing);
}

.mitte-beschlusslage-inhalt {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

.beschluss-marke {
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 11px;
  line-height: 1;
  padding: 3px 6px;
  border-radius: var(--radius-s);
  background: var(--messing);
  color: var(--papier-hell);
  white-space: nowrap;
}

.mitte-raute {
  position: absolute;
  top: 112px;
  width: 150px;
  height: 150px;
  box-sizing: border-box;
  border: 1.5px solid var(--blau);
  transform: rotate(45deg);
  display: flex;
  align-items: center;
  justify-content: center;
}
.mitte-raute--hell { left: 40px; background: var(--papier); }
.mitte-raute--dunkel { left: 628px; background: var(--blau); }

.mitte-raute-text {
  transform: rotate(-45deg);
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 17px;
  line-height: 1.05;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-align: center;
  color: var(--blau);
}
.mitte-raute--dunkel .mitte-raute-text { color: var(--papier); }

.mitte-wappen { position: absolute; left: 313px; top: 84px; }

.mitte-titel {
  position: absolute;
  left: 0;
  top: 322px;
  width: 818px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 14px;
  transform: rotate(-3deg);
}
.mitte-titel-haupt {
  font-family: var(--schrift-titel);
  font-size: 62px;
  line-height: 1;
  letter-spacing: -.02em;
  color: var(--blau);
}
.mitte-titel-zwei {
  font-family: var(--schrift-titel);
  font-size: 34px;
  line-height: 1;
  letter-spacing: -.01em;
  color: var(--rot);
  margin-top: 7px;
}

.mitte-unterzeile {
  position: absolute;
  left: 0;
  top: 404px;
  width: 818px;
  text-align: center;
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--blau-hell);
}

.mitte-kasse {
  position: absolute;
  left: 339px;
  top: 448px;
  width: 140px;
  height: 140px;
  box-sizing: border-box;
  border: 2px solid var(--messing);
  border-radius: 50%;
  background: var(--papier);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.mitte-kasse-titel {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 18px;
  line-height: 1;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--messing-dunkel);
  text-align: center;
}
.mitte-kasse-betrag {
  font-family: var(--schrift-eng);
  font-weight: 700;
  font-size: 22px;
  line-height: 1;
  color: var(--blau);
  font-variant-numeric: tabular-nums;
}

.mitte-kalender { position: absolute; left: 49px; top: 626px; width: 720px; }
.mitte-kalender-titel {
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--blau-hell);
  margin-bottom: 7px;
  text-align: center;
}
.mitte-kalender-leiste {
  display: flex;
  border: 1.5px solid var(--blau);
  border-radius: 4px;
  overflow: hidden;
}
.kalender-feld {
  flex-grow: 1;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--blau);
  font-family: var(--schrift-eng);
  font-weight: 600;
  font-size: 15px;
  color: var(--blau);
}
.kalender-feld--vorbei { background: var(--papier-linie); }
.kalender-feld--marker { background: var(--messing); color: var(--papier-hell); font-weight: 700; }
.kalender-feld--wahltag {
  flex-grow: 2.6;
  border-right: 0;
  background: var(--rot);
  color: var(--papier-hell);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: .1em;
}
.kalender-feld--wahltag.kalender-feld--marker { background: var(--rot-dunkel); }

.mitte-spruch {
  position: absolute;
  left: 0;
  top: 726px;
  width: 818px;
  text-align: center;
  font-family: var(--schrift-text);
  font-style: italic;
  font-size: 17px;
  color: var(--messing-dunkel);
}

/* Auf sehr kleinen Bildschirmen wird das Brett zur Übersicht: Farbe, Besitz
   und Figuren bleiben, die Kleinschrift verschwindet. Die vollständigen
   Angaben stehen in der Feldliste und in der Feldauskunft. */
.brett-buehne--knapp .feld-preis,
.brett-buehne--knapp .ecke-unterzeile,
.brett-buehne--knapp .mitte-spruch { display: none; }

.brett-buehne--winzig .feld-name,
.brett-buehne--winzig .mitte-beschlusslage,
.brett-buehne--winzig .mitte-unterzeile { display: none; }

.brett-buehne--winzig .feld-symbol svg { width: 44px; height: 44px; }
.brett-buehne--winzig .feld-band { height: 40px; }

@media (prefers-reduced-motion: reduce) {
  .figur { transition: none; }
}
.bewegung-aus .figur { transition: none; }
