/* Guide-Seiten (scripts/build-site.ts) – gleiche Anmutung wie das Spiel (client/src/style.css), ohne Spiel-JS.
   Eigene Tokens mit Präfix --site-, damit sie nicht mit den Spiel-Tokens (client/src/ui/panel.css, lädt der Turm-Schießstand) kollidieren. */
:root {
  --site-bg: #1d1712;
  --site-panel: rgba(38, 30, 22, 0.94);
  --site-ink: #140d08;
  --site-text: #f4e4c1;
  --site-muted: #a4ad9c;
  --site-accent: #ffd23f;
  --site-combo: #c9a2ff;
  color-scheme: dark;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--site-bg);
  color: var(--site-text);
  font: 16px/1.55 'Segoe UI', system-ui, sans-serif;
}
a {
  color: var(--site-accent);
}
/* Kopfzeile: Logo, Reiter mit Symbol (aktiv gelb wie die Umschalter im Spiel), Sprachwahl, Spielen */
.site-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px 18px;
  padding: 10px 18px;
  background: linear-gradient(180deg, rgba(52, 40, 28, 0.97), rgba(31, 24, 17, 0.97));
  border-bottom: 3px solid var(--site-ink);
  /* feine Kristall-Kante unter der Tusche-Linie */
  box-shadow:
    0 2px 0 rgba(164, 92, 255, 0.45),
    0 6px 14px rgba(0, 0, 0, 0.35);
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
  font-family: 'Bangers', 'Impact', sans-serif;
  font-size: 28px;
  letter-spacing: 0.05em;
  white-space: nowrap;
  color: var(--site-accent);
  text-decoration: none;
  text-shadow: 2px 2px 0 var(--site-ink);
}
.logo img {
  display: block;
  filter: drop-shadow(2px 2px 0 var(--site-ink));
}
.site-nav {
  display: flex;
  gap: 6px;
  flex: 1;
  min-width: 0;
}
.site-nav a {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  color: var(--site-text);
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: 8px;
}
.site-nav a .ti {
  flex: none;
  width: 20px;
  height: 20px;
  color: var(--site-accent);
}
.site-nav a:hover {
  background: rgba(244, 228, 193, 0.08);
  border-color: rgba(20, 13, 8, 0.6);
}
.site-nav a[aria-current='page'] {
  color: var(--site-ink);
  background: var(--site-accent);
  border-color: var(--site-ink);
  box-shadow: 2px 2px 0 var(--site-ink);
}
.site-nav a[aria-current='page'] .ti {
  color: var(--site-ink);
}
.head-end {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}
/* Sprachwahl wie in der Startkarte (client/src/ui/panel.css `.lang-switch`) */
.lang-switch {
  display: inline-flex;
  border: 2px solid var(--site-ink);
  border-radius: 8px;
  overflow: hidden;
}
.lang-switch a {
  padding: 4px 9px;
  color: var(--site-muted);
  background: rgba(0, 0, 0, 0.25);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
.lang-switch a + a {
  border-left: 2px solid var(--site-ink);
}
.lang-switch a:hover {
  color: var(--site-text);
}
.lang-switch a[aria-current='true'] {
  color: var(--site-ink);
  background: var(--site-accent);
}
.play {
  display: inline-block;
  padding: 6px 14px;
  background: var(--site-accent);
  color: var(--site-ink);
  font-weight: 700;
  text-decoration: none;
  border: 3px solid var(--site-ink);
  border-radius: 8px;
  box-shadow: 3px 3px 0 var(--site-ink);
}
.play.big {
  padding: 10px 26px;
  font-size: 20px;
}
main {
  max-width: 980px;
  margin: 0 auto;
  padding: 16px 16px 40px;
}
h1 {
  font-family: 'Bangers', 'Impact', sans-serif;
  font-size: 44px;
  letter-spacing: 0.04em;
  color: var(--site-accent);
  text-shadow: 3px 3px 0 var(--site-ink);
  margin: 12px 0 8px;
}
h2 {
  margin: 28px 0 10px;
  font-size: 24px;
}
h3 {
  margin: 0 0 6px;
  font-size: 18px;
}
h2 small,
h3 small {
  color: var(--site-muted);
  font-weight: 400;
  font-size: 14px;
}
.lead {
  font-size: 18px;
  color: var(--site-text);
}
.muted {
  color: var(--site-muted);
  font-size: 14px;
}
.card {
  margin: 12px 0;
  padding: 12px 16px;
  background: var(--site-panel);
  border: 2px solid var(--site-ink);
  border-radius: 10px;
  box-shadow: 4px 4px 0 var(--site-ink);
}
.card > h2 {
  margin-top: 0;
}
ul {
  padding-left: 20px;
}
ul.combos li::marker {
  color: var(--site-combo);
}
.table {
  overflow-x: auto;
  margin: 10px 0;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;
}
th,
td {
  text-align: left;
  padding: 6px 10px;
  border-bottom: 1px solid rgba(244, 228, 193, 0.15);
  vertical-align: top;
}
th {
  color: var(--site-muted);
  font-weight: 600;
  white-space: nowrap;
}
/* Screenshots der Anleitung (npm run guide-shots) */
.shot {
  margin: 12px 0 18px;
}
.shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 2px solid var(--site-ink);
  border-radius: 10px;
  box-shadow: 4px 4px 0 var(--site-ink);
  background: #4a4a2a;
}
.shot figcaption {
  margin-top: 8px;
  color: var(--site-muted);
  font-size: 14px;
}
.cta {
  margin: 36px 0 0;
  text-align: center;
}
footer {
  padding: 18px 16px 28px;
  text-align: center;
  color: var(--site-muted);
  font-size: 13px;
}
.notfound {
  text-align: center;
  padding-top: 18vh;
}
/* Schmal: Logo und Sprachwahl/Spielen oben, die Reiter als wischbare Zeile darunter */
@media (max-width: 1180px) {
  .site-head {
    flex-wrap: wrap;
    padding: 8px 12px;
  }
  .head-end {
    margin-left: auto;
  }
  .site-nav {
    order: 3;
    flex-basis: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .site-nav::-webkit-scrollbar {
    display: none;
  }
}
@media (max-width: 600px) {
  h1 {
    font-size: 34px;
  }
  .logo {
    font-size: 22px;
  }
  .logo img {
    width: 30px;
    height: 30px;
  }
  .site-head .play span {
    display: none;
  }
}

/* Gegner-Name in der Tabelle: Symbol, Name und Schild „Flieger“ in einer Zeile */
.ename {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.ename .eicon {
  margin-right: 2px;
}
.ename small {
  padding: 0 5px;
  color: var(--site-muted);
  border: 1px solid rgba(244, 228, 193, 0.3);
  border-radius: 4px;
  font-size: 11px;
}
/* Gegner-Symbole (SVG wie im Spiel) */
.eicon {
  display: inline-block;
  width: var(--s, 32px);
  height: var(--s, 32px);
  margin-right: 8px;
  vertical-align: middle;
}
.eicon svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* Turm-Schießstand (client/src/showroom.ts): breiter als der Text, Beschriftung über dem Bild */
.showroom {
  position: relative;
  width: min(1400px, calc(100vw - 32px));
  left: 50%;
  transform: translateX(-50%);
}
.sr-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 10px;
}
.sr-tabs button {
  padding: 4px 10px;
  font: inherit;
  font-size: 14px;
  color: var(--site-text);
  background: var(--site-panel);
  border: 2px solid var(--site-ink);
  border-radius: 6px;
  cursor: pointer;
}
.sr-tabs button[aria-pressed='true'] {
  color: var(--site-ink);
  background: var(--site-accent);
}
.sr-tabs .sr-fire {
  margin-left: auto;
}
.sr-view {
  position: relative;
  overflow: hidden;
  height: clamp(360px, 78vh, 900px);
  border: 2px solid var(--site-ink);
  border-radius: 10px;
  box-shadow: 4px 4px 0 var(--site-ink);
  background: #4a4a2a;
}
.sr-view canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}
.sr-heads {
  position: absolute;
  inset: 0 0 auto;
  height: 28px;
  background: rgba(20, 13, 8, 0.72);
  pointer-events: none;
}
.sr-heads span,
.sr-row {
  position: absolute;
  top: 0;
  left: 0;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  pointer-events: none;
}
.sr-heads span {
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  line-height: 28px;
  color: var(--site-accent);
}
.sr-row {
  padding: 1px 6px;
  color: var(--site-text);
  background: rgba(20, 13, 8, 0.78);
  border-radius: 4px;
}
/* Detail-Karte des Spiels (client/src/ui/panel.css) rechts im Bild – wie die rechte Spalte im Spiel */
.sr-view #info {
  position: absolute;
  z-index: 1;
  top: 38px;
  right: 10px;
  width: 272px;
  max-height: calc(100% - 48px);
  overflow-y: auto;
  line-height: 1.35;
  user-select: none;
}
@media (max-width: 600px) {
  .sr-view #info {
    top: auto;
    bottom: 8px;
    left: 8px;
    right: 8px;
    width: auto;
    max-height: 55%;
  }
}
.sr-fallback {
  position: absolute;
  inset: 40% 0 auto;
  text-align: center;
  color: var(--site-muted);
}
.showroom.sr-ready .sr-fallback {
  display: none;
}
.showroom:not(.sr-ready) .sr-heads {
  display: none;
}
