:root {
  --bg-dark: #111315;
  --panel: rgba(16, 18, 21, 0.78);
  --panel-2: rgba(22, 24, 27, 0.88);
  --line: rgba(202, 207, 214, 0.22);
  --line-strong: rgba(228, 232, 236, 0.42);
  --text: #edf0f2;
  --muted: #a1a8af;
  --accent: #d8dde2;
  --shadow: rgba(0, 0, 0, 0.5);
}

* {
  box-sizing: border-box;
  user-select: none;
}

html, body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: #0d0f11;
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
}

/* FIX: inset entfernt und durch top/left/right/bottom/width/height ersetzt */
.bg,
.overall-overlay,
.vignette,
.noise,
.layout {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
}

.bg {
  background: url("assets/background.jpg") center center / cover no-repeat;
  transform: scale(1.03);
  filter: saturate(0.86) contrast(0.94) brightness(0.88);
}

.overall-overlay {
  background:
    linear-gradient(to bottom, rgba(10,11,13,0.30), rgba(10,11,13,0.18) 30%, rgba(10,11,13,0.24) 70%, rgba(10,11,13,0.42)),
    rgba(18, 20, 24, 0.16);
  pointer-events: none;
}

.vignette {
  background:
    linear-gradient(to bottom, rgba(0,0,0,0.58), rgba(0,0,0,0.16) 22%, rgba(0,0,0,0.18) 58%, rgba(0,0,0,0.72)),
    radial-gradient(circle at center, transparent 34%, rgba(0,0,0,0.44) 100%);
}

.noise {
  opacity: 0.035;
  background-image:
    linear-gradient(rgba(255,255,255,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 4px 4px, 4px 4px;
  mix-blend-mode: soft-light;
}

.layout {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px 42px 26px;
}

.topbar {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* FIX: min() durch max-width ersetzt */
.logo {
  width: 31vw;
  max-width: 520px;
  filter: drop-shadow(0 8px 26px rgba(0,0,0,0.42));
}

.side-panels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4vh;
  pointer-events: none;
}

.spacer {
  flex: 1;
}

.faction-wrap {
  position: relative;
  width: 280px;
  height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* FIX: inset: 14px ersetzt */
.faction-glow {
  position: absolute;
  top: 14px;
  left: 14px;
  right: 14px;
  bottom: 14px;
  border-radius: 0;
  filter: blur(55px);
  opacity: 1;
  z-index: 0;
  animation: pulseGlow 4.8s ease-in-out infinite;
}

.axis-glow {
  background:
    radial-gradient(circle at center,
      rgba(120, 12, 18, 0.00) 0%,
      rgba(120, 12, 18, 0.18) 22%,
      rgba(120, 12, 18, 0.38) 42%,
      rgba(85, 8, 14, 0.9) 58%,
      rgba(50, 4, 8, 0.18) 76%,
      rgba(0, 0, 0, 0.00) 100%);
}

.us-glow {
  background:
    radial-gradient(circle at center,
      rgba(18, 40, 112, 0.00) 0%,
      rgba(18, 40, 112, 0.18) 22%,
      rgba(18, 40, 112, 0.38) 42%,
      rgba(10, 28, 82, 0.9) 58%,
      rgba(6, 16, 40, 0.16) 76%,
      rgba(0, 0, 0, 0.00) 100%);
  animation-delay: 0.8s;
}

@keyframes pulseGlow {
  0%   { transform: scale(0.92); opacity: 0.48; }
  50%  { transform: scale(1.06); opacity: 1; }
  100% { transform: scale(0.92); opacity: 0.48; }
}

.faction-card {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 14px;
  background: linear-gradient(to bottom, rgba(20,22,25,0.50), rgba(10,11,13,0.30));
  border: 1px solid var(--line);
  box-shadow: 0 16px 38px rgba(0,0,0,0.18), inset 0 1px 0 rgba(255,255,255,0.04);
  backdrop-filter: blur(2px);
}

.faction-card img {
  width: 100%;
  display: block;
}

.footer-ui {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 6px;
}

/* FIX: min() durch max-width und gap durch margin-bottom ersetzt */
.notice-box {
  width: 72vw;
  max-width: 760px;
  padding: 13px 16px;
  margin-bottom: 14px;
  background: linear-gradient(to bottom, rgba(18,20,23,0.72), rgba(11,12,14,0.78));
  border: 1px solid var(--line-strong);
  box-shadow: 0 10px 26px rgba(0,0,0,0.20), inset 0 1px 0 rgba(255,255,255,0.03);
  text-align: center;
}

.notice-title {
  font-size: 11px;
  letter-spacing: 0.28em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 7px;
}

.notice-text {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

/* FIX: min() durch max-width ersetzt */
.loading-panel {
  width: 76vw;
  max-width: 920px;
  padding: 8px 10px 6px;
  background: rgba(13, 14, 17, 0.50);
  border: 1px solid rgba(228, 232, 236, 0.20);
  box-shadow: 0 10px 24px rgba(0,0,0,0.20);
  backdrop-filter: blur(4px);
}

.bar-shell {
  position: relative;
  height: 8px;
  overflow: hidden;
  background: rgba(5, 6, 8, 0.72);
  border: 1px solid rgba(228, 232, 236, 0.14);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.42);
}

.bar-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #565d66 0%, #cfd5db 52%, #717981 100%);
  box-shadow: 0 0 8px rgba(255,255,255,0.10);
  transition: width 0.18s ease-out;
}

/* FIX: inset: 0 ersetzt */
.bar-glow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.10), transparent 58%);
  pointer-events: none;
}

.loading-meta {
  margin-top: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.status-line {
  color: var(--text);
  font-size: 12px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.percent {
  color: var(--accent);
  font-size: 12px;
  min-width: 40px;
  text-align: right;
}

/* FIX: gap entfernt, dafür margins an den kindern */
.sub-meta {
  margin-top: 3px;
  display: flex;
  align-items: center;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0.84;
}

.sub-meta > * {
  margin-right: 10px;
}

.sub-meta > *:last-child {
  margin-right: 0;
}

.divider {
  width: 1px;
  height: 10px;
  background: rgba(228, 232, 236, 0.16);
}

@media (max-width: 1100px) {
  .faction-wrap { width: 220px; height: 220px; }
  .notice-box { width: 80vw; max-width: 700px; }
}

@media (max-width: 860px) {
  .layout { padding: 20px 22px 20px; }
  .logo { width: 66vw; max-width: 460px; }
  .notice-box { width: 90vw; }
  .faction-wrap { display: none; }
  .loading-panel { width: 90vw; }
}

.smoke {
  position: absolute;
  bottom: -5%;
  left: 0;
  width: 100%;
  height: 130%;
  pointer-events: none;

  background:
    radial-gradient(circle at 20% 100%, rgba(255,255,255,0.08), transparent 60%),
    radial-gradient(circle at 50% 100%, rgba(255,255,255,0.06), transparent 70%),
    radial-gradient(circle at 80% 100%, rgba(255,255,255,0.07), transparent 60%);

  filter: blur(50px);
  animation: smokeRise 30s linear infinite;
  opacity: 0.8;
}

@keyframes smokeRise {
  0% { transform: translateY(0px) scale(1); opacity: 0.5; }
  50% { transform: translateY(-60px) scale(1.08); opacity: 0.8; }
  100% { transform: translateY(-120px) scale(1.15); opacity: 0.4; }
}

/* --- MAP INFO BOX --- */
.spacer {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.map-info-box {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 480px;
  padding: 12px;
  background: linear-gradient(to bottom, rgba(20,22,25,0.65), rgba(10,11,13,0.45));
  border: 1px solid var(--line-strong);
  box-shadow: 0 16px 38px rgba(0,0,0,0.25), inset 0 1px 0 rgba(255,255,255,0.04);
  backdrop-filter: blur(4px);
  margin: 0 20px;
  /* Standardmäßig etwas ausblenden, bis die Daten da sind */
  opacity: 0; 
  transition: opacity 0.5s ease;
}

.map-image-wrapper {
  width: 140px;
  height: 85px;
  flex-shrink: 0;
  border: 1px solid var(--line);
  margin-right: 16px;
  overflow: hidden;
  background: #000;
}

.map-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.1);
}

.map-text-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.map-title {
  font-size: 13px;
  letter-spacing: 0.18em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 6px;
  font-weight: bold;
}

.map-desc {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

@media (max-width: 1100px) {
  .map-info-box { flex-direction: column; text-align: center; padding: 16px; }
  .map-image-wrapper { margin-right: 0; margin-bottom: 12px; width: 100%; height: 100px; }
}
@media (max-width: 860px) {
  .map-info-box { display: none; /* Auf ganz kleinen Handys ausblenden */ }
}