/* ===== SCROLLBAR AUSBLENDEN (global) ===== */
* {
  scrollbar-width: none;        /* Firefox */
  -ms-overflow-style: none;     /* IE / Edge */
}
*::-webkit-scrollbar {
  display: none;                /* Chrome / Safari / Opera */
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg-dark:      #0d1117;
  --bg-card:      #161b22;
  --bg-input:     #21262d;
  --border:       #30363d;
  --accent:       #e63946;
  --accent-hover: #c1121f;
  --text:         #e6edf3;
  --text-muted:   #8b949e;
  --success:      #3fb950;
}

html, body {
  height: 100%;
  margin: 0;
  overflow: hidden;
  font-family: 'Segoe UI', system-ui, sans-serif;
  background: var(--bg-dark);
  color: var(--text);
}

body {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}

/* ===== TOPBAR ===== */
.topbar {
  height: 56px;
  flex-shrink: 0;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 20px;
  z-index: 1000;
}

.topbar-left { flex-shrink: 0; }
.topbar-right { flex-shrink: 0; }

.logo-small {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
}

.topbar-center {
  display: flex;
  gap: 18px;
  min-width: 0;
  flex: 0 1 auto;
  justify-content: flex-start;
  overflow: hidden;
}

@media (min-width: 601px) and (max-width: 1180px) {
  .topbar { gap: 10px; padding: 0 12px; }
  .topbar-center { gap: 12px; }
  .topbar-center #clockDate,
  .topbar-center .clock-sep { display: none; }
}

.stat {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
}

.stat-icon {
  font-size: 16px;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
  color: var(--text-muted);
}

/* ===== DROPDOWN ===== */
.dropdown {
  position: relative;
}

.btn-menu {
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 7px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s;
}

.btn-menu:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  min-width: 240px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  overflow: hidden;
  z-index: 6000; /* über Sidebars (5000) und fast allem anderen */
  max-height: 70vh;
  overflow-y: auto;
}

.menu-search-wrap {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--bg-card);
  padding: 8px 10px 7px;
  border-bottom: 1px solid var(--border);
}
.menu-search-wrap input {
  width: 100%;
  box-sizing: border-box;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-input);
  color: var(--text);
  font-size: 13px;
  outline: none;
}
.menu-search-wrap input:focus { border-color: var(--accent); }

.dropdown-menu {
  scrollbar-width: thin;
  scrollbar-color: var(--accent, #e63946) transparent;
}
.dropdown-menu::-webkit-scrollbar {
  display: block;
  width: 12px;
}
.dropdown-menu::-webkit-scrollbar-track {
  background: transparent;
}
.dropdown-menu::-webkit-scrollbar-thumb {
  background-color: var(--accent, #e63946);
  border-radius: 20px;
  border: 3px solid var(--bg-card, #161b22);
}
.dropdown-menu::-webkit-scrollbar-thumb:hover {
  background-color: #ff5a67;
}

.dropdown-menu.open {
  display: block;
  animation: fadeDown 0.15s ease;
}

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  transition: background 0.15s;
}

.dropdown-menu a:hover {
  background: var(--bg-input);
}

.dropdown-menu a.menu-promo {
  margin: 5px 10px;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 800;
  box-shadow: 0 1px 6px rgba(0,0,0,0.25);
}
.dropdown-menu a.menu-promo:hover {
  filter: brightness(1.22);
}

#dropdownMenu .menu-promo-row {
  display: flex;
  gap: 6px;
  margin: 6px 10px 4px;
}
#dropdownMenu .menu-promo-pill {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 4px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  border: 1px solid var(--border);
  background: var(--bg-input);
  color: var(--text);
  transition: background 0.15s, border-color 0.15s;
}
#dropdownMenu .menu-promo-vip { color: #d6a93a; border-color: rgba(210,153,34,0.30); }
#dropdownMenu .menu-promo-vip:hover { background: rgba(210,153,34,0.12); border-color: rgba(210,153,34,0.55); }
#dropdownMenu .menu-promo-shop { color: #ff9f1c; border-color: rgba(255,159,28,0.30); }
#dropdownMenu .menu-promo-shop:hover { background: rgba(255,159,28,0.12); border-color: rgba(255,159,28,0.55); }

.dropdown-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}

.dropdown-divider:has(+ .dropdown-category) {
  display: none;
}

.logout-link {
  color: var(--accent) !important;
}

/* ===== HAUPTBEREICH ===== */
.game-wrapper {
  flex: 1;
  display: flex;
  overflow: hidden;
  min-height: 0;
}

/* ===== SIDEBAR LINKS ===== */
.sidebar {
  width: 280px;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  overflow-y: auto;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;

  position: relative;
  z-index: 50;
}

.sidebar-section {
  padding: 18px;
  border-bottom: 1px solid var(--border);
}

.sidebar-section h3 {
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.hint {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ===== SUCHE ===== */
.search-box {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.search-box input {
  flex: 1;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  color: var(--text);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

.search-box input:focus {
  border-color: var(--accent);
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.btn-search {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 9px 13px;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-search:hover {
  background: var(--accent-hover);
}

.search-result-item {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  margin-top: 6px;
  font-size: 12px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
  line-height: 1.4;
}

.search-result-item:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ===== WACHEN-BUTTONS ===== */
.station-types {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 10px;
}

.station-btn {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--text);
  font-size: 13px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
  line-height: 1.6;
}

.station-btn:hover {
  border-color: var(--accent);
}

.station-btn.active {
  border-color: var(--accent);
  background: rgba(230,57,70,0.1);
}

.station-btn small {
  color: var(--text-muted);
  font-size: 11px;
}

/* ===== WACHENLISTE ===== */
.station-item {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 7px;
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s;
}

.station-item:hover {
  border-color: var(--accent);
}

.station-item .station-name {
  font-weight: 600;
  margin-bottom: 2px;
}

.station-item .station-type {
  color: var(--text-muted);
  font-size: 11px;
}

/* ===== KARTE ===== */
#map {
  flex: 1;
  min-width: 0;
  min-height: 0;
  z-index: 1;
  touch-action: none;
}

/* ===== EINSATZ SIDEBAR RECHTS ===== */
.mission-sidebar {
  width: 260px;
  background: var(--bg-card);
  border-left: 1px solid var(--border);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;

  position: relative;
  z-index: 50;
}


.vstab-bar {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
  padding: 4px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
.vstab-bar::-webkit-scrollbar { height: 4px; }
.vstab-bar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.vstab {
  position: relative;
  flex: 1 1 auto;
  min-width: 64px;
  max-width: 140px;
  padding: 7px 10px 7px 10px;
  border-radius: 7px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: background 0.18s, color 0.18s, border-color 0.18s, transform 0.1s;
  white-space: nowrap;
  user-select: none;
}
.vstab:hover {
  background: rgba(255,255,255,0.04);
  color: var(--text);
}
.vstab:active { transform: scale(0.96); }

.vstab-icon {
  font-size: 16px;
  line-height: 1;
}
.vstab-label {
  font-size: 10.5px;
  line-height: 1.1;
  letter-spacing: 0.2px;
}

.vstab.active {
  background: linear-gradient(135deg, rgba(56,139,253,0.95), rgba(56,139,253,0.75));
  color: #fff;
  border-color: rgba(56,139,253,0.6);
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(56,139,253,0.25);
}
.vstab.active .vstab-label { color: #fff; }


.vstab-count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--border);
  color: var(--text);
  font-size: 9.5px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  border-radius: 9px;
  border: 1.5px solid var(--bg-input);
  box-sizing: border-box;
}
.vstab.active .vstab-count {
  background: #fff;
  color: var(--info);
  border-color: rgba(56,139,253,0.6);
}
.vstab-count.zero {
  opacity: 0.4;
  background: var(--bg-dark);
}


@media (max-width: 380px) {
  .vstab-label { display: none; }
  .vstab { min-width: 48px; padding: 8px 6px; }
  .vstab-icon { font-size: 18px; }
}

.mission-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.mission-sidebar-header h3 {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.btn-generate {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-generate:hover {
  background: var(--accent-hover);
}

#missionList {
  overflow-y: auto;
  flex: 1;
}

.mission-item {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background 0.15s;
}

.mission-item:hover {
  background: var(--bg-input);
}

.mission-item-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 6px;
}

.mission-item-name {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 5px;
}

.mission-badge {
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 20px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}

.badge-offen  { background: rgba(210,153,34,0.2); color: #d29922; }
.badge-aktiv  { background: rgba(63,185,80,0.2);  color: var(--success); }
.badge-nachalarmierung { background: rgba(56,139,253,0.2); color: var(--info); border: 1px solid rgba(56,139,253,0.4); }

.mission-item-reward {
  font-size: 11px;
  color: var(--success);
  font-weight: 600;
}

.mission-item-sub {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ===== FOOTER ===== */
.game-footer {
  height: 36px;
  flex-shrink: 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  font-size: 12px;
  color: var(--text-muted);
  z-index: 1000;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--accent);
}

/* ===== MODAL WACHE BAUEN ===== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  z-index: 9000;
  align-items: center;
  justify-content: center;
}

.modal-overlay.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 28px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.6);
  animation: slideUp 0.2s ease;
}


#missionModal .modal-box {

  max-width: 95vw;
  max-height: 92vh;
  width: 900px;
  height: 92vh;
  overflow: hidden;
  padding: 0;
  display: flex;
  flex-direction: column;
  position: relative;
}

@supports (height: 100dvh) {
  .modal-overlay { height: 100dvh; }
  #missionModal .modal-box {
    max-height: 92dvh;
    height: 92dvh;
  }
}

#missionModal .modal-box > .modal-actions {
  position: sticky;
  bottom: 0;
  z-index: 3;
}


@media (min-width: 901px) {
  #missionModal .modal-box {
    min-width: 480px;
    min-height: 400px;
    resize: both;
  }
 
  #missionModal .modal-box::after {
    content: "";
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 14px;
    height: 14px;
    background-image: linear-gradient(135deg,
      transparent 40%, var(--border) 40% 50%,
      transparent 50% 60%, var(--border) 60% 70%,
      transparent 70% 80%, var(--border) 80% 90%, transparent 90%);
    pointer-events: none;
    opacity: 0.6;
  }
}


#missionModal .modal-box > * {
  flex-shrink: 0;
  margin-left: 28px;
  margin-right: 28px;
}


#missionModal .modal-box > .modal-header {
  margin-top: 24px;
}


#missionModal .modal-box > #vehicleSelectList {
  flex: 1 1 auto;
  flex-shrink: 1;
  min-height: 70px;
  overflow-y: auto;
  margin-bottom: 12px;
  
  max-height: none !important;
}

#missionModal .modal-box > #missionInfoScroll {
  flex-shrink: 0;
  max-height: 22vh;
  overflow-y: auto;
  overflow-x: hidden;
}


#missionModal .modal-box > .modal-actions {
  margin-left: 0;
  margin-right: 0;
  padding: 14px 28px calc(24px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--border);
  background: var(--bg-card);
}


@media (max-width: 900px) and (min-width: 769px) {
  #missionModal .modal-box {
    max-width: 95vw;
  }
  #missionModal .modal-box > * {
    margin-left: 22px;
    margin-right: 22px;
  }
  #missionModal .modal-box > .modal-header {
    margin-top: 20px;
  }
  #missionModal .modal-box > .modal-actions {
    margin-left: 0;
    margin-right: 0;
    padding: 12px 22px 20px;
  }
}

/* ── Alarmierungsfenster: konfigurierbare Fahrzeuglisten-Dichte (⚙️-Button) ── */
#missionModal .modal-box.ao-compact > #missionInfoScroll { max-height: 12vh; }
#missionModal .modal-box.ao-compact #vehicleRequirementHint { display: none; }
#missionModal .modal-box.ao-compact #missionRewardCard { padding: 3px 12px; margin-bottom: 6px; }
#missionModal .modal-box.ao-compact #missionRequiredBox { padding: 6px 12px; margin-bottom: 6px; }
#missionModal .modal-box.ao-compact .vehicle-select-label { margin-bottom: 4px; }
#missionModal .modal-box.ao-compact .vehicle-select-item {
  padding: 4px 10px;
  font-size: 12px;
  margin-bottom: 4px;
  gap: 8px;
}
#missionModal .modal-box.ao-compact .vehicle-select-item.selected { padding: 2px 8px; }

#missionModal .modal-box.ao-large .vehicle-select-item {
  padding: 13px 15px;
  font-size: 15px;
  margin-bottom: 8px;
}
#missionModal .modal-box.ao-large .vehicle-select-item.selected { padding: 11px 13px; }

/* Baseline für kleine/kurze Auflösungen: fixe Blöcke schrumpfen, damit die
   Fahrzeugliste immer mehrere Zeilen statt nur ~1 zeigt (kein Einstellen nötig) */
@media (max-height: 720px) {
  #missionModal .modal-box > #missionInfoScroll { max-height: 15vh; }
  #missionModal #vehicleRequirementHint { display: none; }
  #missionModal #missionRewardCard { padding: 3px 12px; margin-bottom: 6px; }
  #missionModal #missionRequiredBox { padding: 7px 12px; margin-bottom: 7px; }
}
@media (max-height: 560px) {
  #missionModal .modal-box { height: 96vh; max-height: 96vh; }
  #missionModal .modal-box > #missionInfoScroll { max-height: 9vh; }
  #missionModal .modal-box > .modal-header { margin-top: 14px; }
}

.ba-resize-hint { display: none; }

@media (min-width: 768px) {
  #confirmModal .modal-box.confirm-resizable {
    width: 720px;
    max-width: 96vw !important;
    max-height: 90vh;
    min-width: 380px;
    min-height: min(360px, 80vh);
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    resize: both;
  }
  #confirmModal .modal-box.confirm-resizable > * {
    flex-shrink: 0;
    margin-left: 26px;
    margin-right: 26px;
  }
  #confirmModal .modal-box.confirm-resizable > .modal-header {
    margin-top: 24px;
  }
  #confirmModal .modal-box.confirm-resizable > #confirmBodyHtml {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
  }
  #confirmModal .modal-box.confirm-resizable > #confirmBodyHtml > div:first-child {
    max-height: none !important;
    overflow: visible !important;
  }
  #confirmModal .modal-box.confirm-resizable > .modal-actions {
    margin-top: 14px;
    margin-bottom: 22px;
  }
  #confirmModal .modal-box.confirm-resizable::after {
    content: "";
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background-image: linear-gradient(135deg,
      transparent 35%, var(--border) 35% 45%,
      transparent 45% 55%, var(--border) 55% 65%,
      transparent 65% 75%, var(--border) 75% 85%, transparent 85%);
    pointer-events: none;
    opacity: 0.7;
  }
  .ba-resize-hint { display: flex; }
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.modal-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 6px;
}

.modal-header span {
  font-size: 36px;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.4));
}

.modal-header h2 {
  font-size: 20px;
  font-weight: 700;
}

.modal-subtitle {
  color: var(--text-muted);
  font-size: 13px;
  margin-bottom: 24px;
}

.modal-input-group {
  position: relative;
  margin-bottom: 16px;
}

.modal-input-group label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modal-input-group input {
  width: 100%;
  background: var(--bg-input);
  border: 2px solid var(--border);
  border-radius: 10px;
  padding: 13px 48px 13px 14px;
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.modal-input-group input:focus {
  border-color: var(--accent);
}

.modal-input-group input::placeholder {
  color: var(--text-muted);
}

.input-counter {
  position: absolute;
  right: 14px;
  bottom: 14px;
  font-size: 11px;
  color: var(--text-muted);
}

.modal-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.modal-info strong {
  color: var(--success);
  font-size: 14px;
}

.modal-actions {
  display: flex;
  gap: 10px;
}

.btn-cancel {
  flex: 1;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: 10px;
  padding: 12px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel:hover {
  border-color: var(--text-muted);
  color: var(--text);
}

.btn-confirm {
  flex: 2;
  background: var(--accent);
  border: none;
  color: white;
  border-radius: 10px;
  padding: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.btn-confirm:hover {
  background: var(--accent-hover);
}

.btn-confirm:active {
  transform: scale(0.98);
}

.btn-confirm:disabled {
  background: var(--bg-input);
  color: var(--text-muted);
  cursor: not-allowed;
  transform: none;
}

/* ===== FAHRZEUG AUSWAHL ===== */
.vehicle-select-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 8px;
}

.vehicle-select-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: border-color 0.2s;
  font-size: 13px;
}

.vehicle-select-item.relevant {
  border-color: rgba(63,185,80,0.4);
  background: rgba(63,185,80,0.04);
}

.vehicle-select-item:hover {
  border-color: var(--accent);
}


.vehicle-select-item.selected {
  border: 3px solid var(--success) !important;
  background: rgba(63,185,80,0.20) !important;
  box-shadow: 0 0 0 1px rgba(63,185,80,0.4), inset 0 0 0 1px rgba(63,185,80,0.15);
  padding: 7px 10px;   /* kompensiert die 3px Border (2px breiter) */
  transform: translateZ(0); /* hint für browser dass das ein neuer layer ist */
}

.vehicle-select-item.unselected {

  border-color: var(--border) !important;
  background: var(--bg-input) !important;
  opacity: 0.85;
}


@media (max-width: 768px) {
  .vehicle-select-item.selected {
    border-width: 4px !important;
    background: rgba(63,185,80,0.28) !important;
    box-shadow: 0 0 0 2px rgba(63,185,80,0.5), 0 4px 12px rgba(63,185,80,0.2);
    padding: 6px 9px;
  }

  .vehicle-select-item .vcheck { font-size: 22px !important; }
  .vehicle-select-item.selected .vcheck {
    color: var(--success);
    text-shadow: 0 0 4px rgba(63,185,80,0.6);
    font-weight: 900;
  }
}

.vehicle-select-item.unavailable {
  opacity: 0.4;
  cursor: not-allowed;
}

.vehicle-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dot-verfügbar { background: var(--success); }
.dot-einsatz   { background: var(--accent); }

/* ===== TIMER ===== */
.timer-box {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.timer-box strong {
  font-size: 18px;
  color: var(--success);
  font-variant-numeric: tabular-nums;
}

/* ===== ANIMATIONEN ===== */
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.2); }
}

/* ===== EINSATZ EINSTELLUNGEN ===== */

.mission-settings-collapse {
  border-bottom: 1px solid var(--border);
}
.mission-settings-collapse > .mission-settings {
  border-bottom: none;
  padding-top: 4px;
}
.mission-settings-summary {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-muted);
  user-select: none;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.mission-settings-summary::-webkit-details-marker { display: none; }
.mission-settings-summary::before {
  content: '▶';
  font-size: 9px;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
}
.mission-settings-collapse[open] > .mission-settings-summary::before {
  transform: rotate(90deg);
}
.mission-settings-summary:hover {
  background: var(--bg-input);
}

.mission-settings {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-muted);
}

.setting-row select {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 11px;
  padding: 3px 6px;
  cursor: pointer;
  outline: none;
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-input);
  border-radius: 20px;
  border: 1px solid var(--border);
  transition: 0.2s;
}

.toggle-slider:before {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  left: 2px;
  top: 2px;
  background: var(--text-muted);
  border-radius: 50%;
  transition: 0.2s;
}

.toggle-switch input:checked + .toggle-slider {
  background: rgba(63,185,80,0.2);
  border-color: var(--success);
}

.toggle-switch input:checked + .toggle-slider:before {
  background: var(--success);
  transform: translateX(16px);
}

/* ===== DROPDOWN KATEGORIEN ===== */
.dropdown-category {
  margin-top: 8px;
  padding: 7px 16px 6px 13px;
  font-size: 11px;
  font-weight: 800;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 1px;
  background: linear-gradient(90deg, rgba(230,57,70,0.14), rgba(230,57,70,0.03));
  border-left: 3px solid var(--accent);
}

.dropdown-category.collapsible {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.dropdown-category.collapsible:hover { filter: brightness(1.3); }
.dropdown-category .cat-label { flex: 1; }
.dropdown-category .cat-chev {
  display: inline-block;
  font-size: 9px;
  color: var(--text-muted);
  transition: transform 0.15s ease;
  flex-shrink: 0;
}
.dropdown-category.cat-open .cat-chev {
  transform: rotate(90deg);
  color: var(--accent);
}
.dropdown-category .cat-count {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-muted);
  background: rgba(255,255,255,0.07);
  border-radius: 9px;
  padding: 1px 7px;
  flex-shrink: 0;
}

.menu-allcats-btn {
  display: block;
  width: 100%;
  margin-top: 7px;
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 7px;
  cursor: pointer;
}
.menu-allcats-btn:hover { color: var(--text); border-color: var(--accent); }

.dropdown-menu {
  max-height: 70vh;
  overflow-y: auto;
}

/* ===== MISSION KARTE MIT DISTANZ ===== */
.mission-distance {
  font-size: 10px;
  color: var(--text-muted);
}

/* ===== SMOOTH MAP ===== */
.leaflet-map-pane,
.leaflet-tile-pane {
  will-change: transform;
}

.btn-buy-vehicle {
  margin-top: 6px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
}
.btn-buy-vehicle:hover { border-color: var(--accent); color: var(--accent); }

.chat-msg { display: flex; flex-direction: column; gap: 2px; max-width: 80%; }
.chat-msg.own { align-self: flex-end; align-items: flex-end; }
.chat-user { font-size: 11px; color: var(--text-muted); font-weight: 600; }
.chat-text { background: var(--bg-input); border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; font-size: 13px; line-height: 1.4; }
.chat-msg.own .chat-text { background: rgba(230,57,70,0.15); border-color: var(--accent); }
.chat-time { font-size: 10px; color: var(--text-muted); }



@keyframes vipExpiringPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); transform: scale(1); }
  50% { box-shadow: 0 0 0 8px rgba(239, 68, 68, 0); transform: scale(1.05); }
}


.kasse-slider {
  -webkit-appearance: none;
  appearance: none;
  height: 10px;
  background: linear-gradient(90deg, rgba(56,139,253,0.2), rgba(56,139,253,0.5));
  border-radius: 6px;
  outline: none;
  border: 1px solid rgba(56,139,253,0.4);
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.3);
}
.kasse-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  background: linear-gradient(135deg, #58a6ff, #1f6feb);
  border: 3px solid #fff;
  border-radius: 50%;
  cursor: grab;
  box-shadow: 0 2px 8px rgba(56,139,253,0.6), 0 0 0 2px rgba(56,139,253,0.3);
  transition: transform 0.15s, box-shadow 0.15s;
}
.kasse-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 2px 12px rgba(56,139,253,0.8), 0 0 0 3px rgba(56,139,253,0.4);
}
.kasse-slider::-webkit-slider-thumb:active {
  cursor: grabbing;
  transform: scale(1.2);
}
.kasse-slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  background: linear-gradient(135deg, #58a6ff, #1f6feb);
  border: 3px solid #fff;
  border-radius: 50%;
  cursor: grab;
  box-shadow: 0 2px 8px rgba(56,139,253,0.6);
  transition: transform 0.15s;
}
.kasse-slider::-moz-range-thumb:hover { transform: scale(1.15); }

/* Verbands-Kürzel zwischen Icon und Username */
.chat-verband-tag {
  display: inline-block;
  font-weight: 700;
  font-size: 0.85em;
  color: #eab308;
  background: rgba(234, 179, 8, 0.12);
  border: 1px solid rgba(234, 179, 8, 0.4);
  padding: 0 5px;
  border-radius: 4px;
  margin-right: 4px;
  letter-spacing: 0.3px;
}

/* Sticker im Chat — etwas größer und ohne Padding-Effekt */
.chat-sticker {
  display: inline-block;
  max-height: 48px;
  max-width: 80px;
  vertical-align: middle;
  border-radius: 6px;
  margin: 2px 4px;
  transition: transform 0.15s;
}
.chat-sticker:hover { transform: scale(1.15); }

/* Trigger-Hint im Text-Body */
.chat-effect-trigger {
  background: rgba(167,139,250,0.18);
  color: #a78bfa;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.9em;
  font-weight: 600;
  display: inline-block;
  margin: 0 2px;
}

/* Effekt-Layer über Chat-Messages */
#chatEffectLayer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 5;
}
.chat-fx {
  position: absolute;
  user-select: none;
  pointer-events: none;
  will-change: transform, opacity;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* Picker-Tabs */
.chat-picker-tab {
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.chat-picker-tab:hover {
  border-color: var(--info) !important;
}
.chat-picker-tab.active {
  background: var(--bg-input) !important;
  color: var(--text) !important;
}

/* Sticker-Picker-Buttons hover */
#chatPickerSticker button:hover,
#chatPickerEffect button:hover {
  border-color: var(--info) !important;
  background: rgba(56,139,253,0.08) !important;
}

/* Mobile: Picker-Panel-Höhe anpassen */
@media (max-width: 600px) {
  #chatPickerPanel {
    max-height: 200px !important;
  }
  .chat-sticker {
    max-height: 40px;
    max-width: 70px;
  }
}

.verband-item { background: var(--bg-input); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; margin-bottom: 6px; }
.verband-mitglied { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 13px; }

/* ===== NOTIZEN ===== */
.notiz-card {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 8px;
  transition: border-color 0.2s;
}

.notiz-card:hover {
  border-color: var(--text-muted);
}

.notiz-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.notiz-titel {
  font-size: 14px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notiz-label-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  border: 1px solid;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.notiz-inhalt {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 8px;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 80px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.notiz-datum {
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.7;
}

.notiz-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 14px;
  padding: 2px 4px;
  border-radius: 4px;
  transition: background 0.15s;
  opacity: 0.7;
}

.notiz-btn:hover {
  background: var(--bg-dark);
  opacity: 1;
}

.station-category-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 8px 0 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}

.badge-wasser        { background: rgba(56,139,253,0.2);  color: #388bfd; }
.badge-berg          { background: rgba(139,92,246,0.2);  color: #8b5cf6; }
.badge-flughafen     { background: rgba(251,191,36,0.2);  color: #fbbf24; }
.badge-kats          { background: rgba(239,68,68,0.2);   color: #ef4444; }
.badge-zoll          { background: rgba(34,197,94,0.2);   color: #22c55e; }
.badge-bundespolizei { background: rgba(99,102,241,0.2);  color: #6366f1; }
.badge-sanitaet      { background: rgba(236,72,153,0.2);  color: #ec4899; }

/* ===== UHR ===== */
.clock-stat {
  border-left: 1px solid var(--border);
  padding-left: 16px;
  margin-left: 8px;
}

.clock-display {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

#clockTime {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  letter-spacing: 0.5px;
  white-space: nowrap;
}

#clockDate {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.clock-sep {
  color: var(--border);
  font-size: 14px;
}

.session-label {
  font-size: 13px;
}

#sessionTime {
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--success);
  white-space: nowrap;
  cursor: default;
}

/* ===== PM CHAT ===== */
.btn-pm {
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 7px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  position: relative;
  transition: all 0.2s;
}

.btn-pm:hover {
  border-color: var(--accent);
}

.pm-badge {
  background: var(--accent);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 10px;
  vertical-align: top;
  margin-left: 2px;
}

.pm-conv-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: border-color 0.2s;
}

.pm-conv-item:hover {
  border-color: var(--accent);
}

.pm-conv-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #7c3aed);
  color: white;
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pm-unread-badge {
  background: var(--accent);
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 20px;
  flex-shrink: 0;
}

/* ===== WACHE ABREISSEN / FAHRZEUG VERKAUFEN ===== */
.btn-demolish {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.btn-demolish:hover {
  border-color: var(--accent);
  background: rgba(230,57,70,0.1);
}

.vehicle-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 8px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-top: 4px;
}

.btn-sell-vehicle {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: 5px;
  padding: 2px 7px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-sell-vehicle:hover:not(:disabled) {
  border-color: var(--success);
  color: var(--success);
}

.btn-sell-vehicle:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ===== BESTÄTIGUNGS-MODAL ===== */
.confirm-info-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 16px;
}

.confirm-info-box strong {
  color: var(--success);
  font-size: 15px;
}

/* ===== WACHEN & FAHRZEUG ÜBERSICHT ===== */
.wachen-block {
  margin-bottom: 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.wachen-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-card);
}

.wachen-vehicle-count {
  font-size: 11px;
  color: var(--text-muted);
  background: var(--bg-dark);
  padding: 3px 8px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.wachen-vehicle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
  padding: 12px;
}

.wachen-vehicle-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  transition: border-color 0.2s;
}

.wachen-vehicle-card:hover {
  border-color: var(--accent);
}

/* ===== RANGLISTE ===== */
.rang-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.rang-tab {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.rang-tab:hover {
  border-color: var(--accent);
  color: var(--text);
}

.rang-tab.active {
  background: rgba(230,57,70,0.1);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.rang-table {
  width: 100%;

  min-width: 980px;
  border-collapse: collapse;
  font-size: 12px;
}


.rang-table-scroll {
  position: relative;
  background:
    linear-gradient(to right, var(--bg-card) 30%, rgba(22,27,34,0)),
    linear-gradient(to right, rgba(22,27,34,0), var(--bg-card) 70%) 100% 0,
    radial-gradient(farthest-side at 0 50%, rgba(0,0,0,0.4), rgba(0,0,0,0)),
    radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,0.4), rgba(0,0,0,0)) 100% 0;
  background-repeat: no-repeat;
  background-color: var(--bg-card);
  background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%;
  background-attachment: local, local, scroll, scroll;
}
.rang-table-scroll::-webkit-scrollbar { height: 6px; }
.rang-table-scroll::-webkit-scrollbar-track { background: transparent; }
.rang-table-scroll::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

.rang-table thead tr {
  background: var(--bg-input);
  border-bottom: 2px solid var(--border);
}

.rang-table th {
  padding: 6px 8px;
  text-align: left;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.rang-table td {
  padding: 7px 8px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.rang-table tbody tr:hover {
  background: var(--bg-input);
}

.rang-top3 td {
  background: rgba(210,153,34,0.04);
}

.rang-me td {
  background: rgba(230,57,70,0.06) !important;
  border-left: 2px solid var(--accent);
}

.rang-active-col {
  color: var(--accent) !important;
  background: rgba(230,57,70,0.04);
}

.rang-pos {
  font-size: 16px;
  text-align: center;
  width: 40px;
}

.rang-player {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 120px;
}

.rang-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #7c3aed);
  color: white;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ===== EINSATZ FILTER ===== */
#missionFilterBar input:focus,
#missionFilterBar select:focus {
  border-color: var(--accent);
}

#missionFilterBar {
  margin-top: 10px;
  margin-bottom: 8px;
  padding: 0 2px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.mission-item {
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: border-color 0.2s;
}

.mission-item:hover { border-color: var(--accent); }

.mission-active {
  background: rgba(210,153,34,0.05);
  border-color: rgba(210,153,34,0.3);
}

.changelog-version { margin-bottom:20px; }
.changelog-version-header { display:flex;align-items:center;gap:10px;margin-bottom:10px;padding-bottom:8px;border-bottom:1px solid var(--border); }
.changelog-version ul { list-style:none;display:flex;flex-direction:column;gap:4px;font-size:13px; }
.changelog-version li { padding:3px 0;color:var(--text-muted); }
.changelog-tag { font-size:10px;padding:2px 8px;border-radius:10px;font-weight:700; }
.tag-current { background:rgba(63,185,80,0.15);color:var(--success);border:1px solid var(--success); }

/* ===== WACHE BAUEN BUTTON (Sidebar) ===== */
.btn-build-station {
  width: 100%;
  padding: 10px 14px;
  background: linear-gradient(135deg, rgba(230,57,70,0.12), rgba(124,58,237,0.12));
  border: 1px solid var(--accent);
  border-radius: 10px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
  letter-spacing: 0.3px;
}
.btn-build-station:hover {
  background: linear-gradient(135deg, rgba(230,57,70,0.22), rgba(124,58,237,0.22));
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(230,57,70,0.2);
}

/* ===== WACHE BAUEN PANEL — Typ-Karten ===== */
.station-type-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.18s;
  margin-bottom: 6px;
}
.station-type-card:hover {
  border-color: var(--accent);
  background: rgba(230,57,70,0.06);
  transform: translateX(3px);
}
.station-type-card.selected {
  border-color: var(--accent);
  background: rgba(230,57,70,0.12);
}
.station-type-card .stc-icon { font-size: 22px; flex-shrink: 0; }
.station-type-card .stc-info { flex: 1; }
.station-type-card .stc-name { font-size: 13px; font-weight: 700; color: var(--text); }
.station-type-card .stc-meta { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.station-type-card .stc-cost { font-size: 12px; font-weight: 700; color: var(--success); flex-shrink: 0; }

.station-category-title {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  padding: 10px 0 5px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 6px;
}
.hidden { display: none !important; }

/* ===== MODAL-INPUT (standalone) ===== */
.modal-input {
  width: 100%;
  box-sizing: border-box;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 13px;
  color: var(--text);
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  display: block;
  resize: vertical;
}
.modal-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(230,57,70,0.1);
}
.modal-input::placeholder { color: var(--text-muted); }
.modal-input:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Autofill-Hintergrund überschreiben (Chrome/Safari) */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px var(--bg-input) inset !important;
  -webkit-text-fill-color: var(--text) !important;
  caret-color: var(--text);
  border-color: var(--border) !important;
  transition: background-color 5000s ease-in-out 0s;
}
/* Chat-Eingaben: auf iOS/Safari erzwingen, dass der getippte Text sichtbar bleibt.
   LITERALE Farben statt var(--…): iOS Safari löst CSS-Variablen in
   -webkit-text-fill-color teils nicht auf -> fällt auf dunkle Systemfarbe zurück
   (dunkle Schrift auf dunklem Feld = unsichtbar). App ist dark-only, daher fix. */
#chatInput,
.fc-input {
  -webkit-appearance: none !important;
  appearance: none !important;
  color: #e6edf3 !important;
  -webkit-text-fill-color: #e6edf3 !important;
  caret-color: #e63946 !important;
  background-color: #21262d !important;
  opacity: 1 !important;
}
#chatInput::placeholder,
.fc-input::placeholder {
  color: #8b949e !important;
  -webkit-text-fill-color: #8b949e !important;
  opacity: 1 !important;
}
/* ===== FAHRZEUG-SHOP KARTEN ===== */
.vshop-card:hover:not(.vshop-cant-afford) {
  border-color: var(--accent) !important;
  background: rgba(230,57,70,0.05) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(230,57,70,0.15);
}
.vshop-card {
  transition: border-color 0.15s, background 0.15s, transform 0.15s, box-shadow 0.15s;
}
/* ===== FUNK-LOG ===== */
#radioLog {
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
#radioLog::-webkit-scrollbar { width: 4px; }
#radioLog::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

/* ===== VRS FAHRZEUG-TOOLTIP ===== */
.vrs-tooltip {
  background: var(--bg-card) !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
  border-radius: 8px !important;
  padding: 6px 10px !important;
  font-size: 11px !important;
  line-height: 1.6 !important;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4) !important;
}
.vrs-tooltip::before { display: none !important; }
/* ════ NOTIFICATION BELL PULSE ════ */
@keyframes notifPulse {
  0%   { transform: scale(1);   color: var(--text); }
  50%  { transform: scale(1.25); color: var(--accent); }
  100% { transform: scale(1);   color: var(--text); }
}
#notifBellBtn:hover {
  background: var(--bg-input);
}
#notifBellBadge {
  animation: notifBadgePulse 2s ease-in-out infinite;
}
@keyframes notifBadgePulse {
  0%, 100% { box-shadow: 0 1px 4px rgba(0,0,0,0.4); }
  50%      { box-shadow: 0 0 0 4px rgba(230,57,70,0.25); }
}
.leaflet-tooltip.lk-tooltip {
  background: rgba(168,85,247,0.92);
  color: #fff;
  border: 1px solid #e63946;
  border-radius: 6px;
  font-weight: 700;
  font-size: 11px;
  padding: 2px 7px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.45);
  white-space: nowrap;
  pointer-events: none;
}
.leaflet-tooltip.lk-tooltip::before { display: none; }


.aao-rule-l2 input[type="number"]::-webkit-outer-spin-button,
.aao-rule-l2 input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.aao-rule-l2 input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

.help-btn-pulse {
  animation: helpBtnPulse 2.2s ease-in-out infinite;
}
@keyframes helpBtnPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(56,139,253,0.55); }
  50%      { box-shadow: 0 0 0 6px rgba(56,139,253,0); }
}
@media (prefers-reduced-motion: reduce) {
  .help-btn-pulse { animation: none; }
}

.dash-help {
  --dh-gap: 14px;
  font-size: 13.5px;
  line-height: 1.72;
  color: var(--text);
  overflow-wrap: anywhere;
}
.dash-help > h3:first-child { margin-top: 0; }
.dash-help h3 {
  font-size: 15.5px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.dash-help h4 {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 9px;
  padding: 0 0 7px;
  border-bottom: 1px solid var(--border);
  letter-spacing: -0.005em;
}
.dash-help .dh-sec {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-left: 3px solid var(--info);
  border-radius: 11px;
  padding: 12px 14px;
  margin-bottom: var(--dh-gap);
  scroll-margin-top: 8px;
}
.dash-help .dh-intro {
  background: rgba(56,139,253,0.07);
  border: 1px solid rgba(56,139,253,0.28);
  border-radius: 11px;
  padding: 12px 14px;
  margin-bottom: var(--dh-gap);
}
.dash-help p { margin: 0 0 9px; }
.dash-help p:last-child, .dash-help ul:last-child, .dash-help ol:last-child { margin-bottom: 0; }
.dash-help ul, .dash-help ol { margin: 0 0 9px; padding-left: 18px; }
.dash-help li { margin-bottom: 6px; padding-left: 2px; }
.dash-help li:last-child { margin-bottom: 0; }
.dash-help li > strong:first-child { color: var(--text); }
.dash-help strong { color: var(--text); font-weight: 700; }
.dash-help em { color: var(--text-muted); font-style: italic; }
.dash-help table { width: 100%; border-collapse: collapse; font-size: 12px; }
.dash-help th {
  text-align: left; padding: 6px 10px 6px 0; white-space: nowrap;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted); font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.4px; font-size: 10px;
}
.dash-help td {
  padding: 6px 10px 6px 0; vertical-align: top;
  border-bottom: 1px solid rgba(128,128,128,0.14);
}
.dash-help tr:last-child td { border-bottom: none; }
.dash-help > div[style*="overflow-x"] { margin-bottom: 9px; }

.dh-toolbar {
  position: sticky; top: -14px; z-index: 3;
  background: var(--bg-card);
  margin: -14px -16px 12px; padding: 12px 16px 10px;
  border-bottom: 1px solid var(--border);
}
.dh-search {
  width: 100%; box-sizing: border-box;
  padding: 8px 11px; border-radius: 9px;
  background: var(--bg-input); border: 1px solid var(--border);
  color: var(--text); font-size: 12.5px; outline: none;
}
.dh-search:focus { border-color: var(--info); }
.dh-nav {
  display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px;
  max-height: 104px; overflow-y: auto; overscroll-behavior-y: contain;
}
.dh-nav button {
  padding: 4px 10px; border-radius: 20px; cursor: pointer;
  font-size: 11px; font-weight: 700; white-space: nowrap;
  border: 1px solid var(--border); background: var(--bg-input);
  color: var(--text-muted); transition: all .12s;
}
.dh-nav button:hover { border-color: var(--info); color: var(--info); }
.dh-hit { background: rgba(210,153,34,0.30); border-radius: 3px; }
.dh-leer {
  text-align: center; padding: 22px 0;
  color: var(--text-muted); font-size: 12.5px;
}
@media (max-width: 700px) {
  .dash-help { font-size: 15.5px; line-height: 1.7; }
  .dash-help h3 { font-size: 17px; }
  .dash-help h4 { font-size: 15.5px; }
  .dash-help .dh-sec, .dash-help .dh-intro { padding: 12px 13px; }
  .dash-help th, .dash-help td { padding-right: 7px; font-size: 14px; }
  .dash-help table { font-size: 14px; }
  .dash-help ul, .dash-help ol { padding-left: 20px; }
  .dash-help li { margin-bottom: 8px; }
  .dh-search { font-size: 16px; padding: 10px 12px; }
  .dh-nav {
    gap: 6px;
    flex-wrap: nowrap;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    padding-bottom: 2px;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent);
  }
  .dh-nav::-webkit-scrollbar { display: none; }
  .dh-nav button {
    font-size: 13px;
    padding: 7px 13px;
    flex: 0 0 auto;
    scroll-snap-align: start;
  }
  .dh-leer { font-size: 14px; }
  #subModalOverlay { padding: 8px !important; }
  #subModalBox { max-width: none !important; max-height: 94vh !important; }
}

@supports (height: 100dvh) {
  @media (max-width: 700px) {
    #subModalBox { max-height: 94dvh !important; }
  }
}

.eli-sum {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 9px;
}
.eli-sum-top {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 10px; margin-bottom: 8px;
}
.eli-sum-lbl {
  font-size: 10px; font-weight: 800; letter-spacing: .5px;
  text-transform: uppercase; color: var(--text-muted);
}
.eli-sum-val { font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; }
.eli-sum-val small { font-size: 11px; font-weight: 700; color: var(--text-muted); margin-left: 5px; }
.eli-bar {
  display: flex; gap: 2px; height: 10px;
  border-radius: 6px; overflow: hidden; background: var(--bg-dark);
}
.eli-bar i { flex: 0 1 0; min-width: 0; height: 100%; transition: flex-grow .4s ease; }
.eli-bar i.done { background: var(--success); }
.eli-bar i.rdy { background: var(--info); }
.eli-bar i.miss { background: #d29922; }
.eli-legend {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 6px; margin-top: 10px;
}
.eli-leg { text-align: center; }
.eli-leg b {
  display: block; font-size: 15px; font-weight: 800;
  font-variant-numeric: tabular-nums; line-height: 1.2;
}
.eli-leg span { font-size: 9.5px; color: var(--text-muted); }
.eli-leg.done b { color: var(--success); }
.eli-leg.rdy b { color: var(--info); }
.eli-leg.miss b { color: #d29922; }
.eli-locks {
  display: flex; justify-content: center; gap: 20px;
  margin-top: 9px; padding-top: 9px;
  border-top: 1px solid var(--border);
  font-size: 10.5px; color: var(--text-muted);
}
.eli-locks b { font-variant-numeric: tabular-nums; font-weight: 800; }
.eli-locks .frei b { color: var(--success); }

.eli-tools { margin-bottom: 8px; }
.eli-row { display: flex; gap: 5px; margin-bottom: 6px; }
.eli-scroll {
  display: flex; gap: 4px; margin-bottom: 6px;
  overflow-x: auto; padding-bottom: 2px;
}
.eli-inp, .eli-sel {
  padding: 7px 9px; border-radius: 8px;
  background: var(--bg-input); border: 1px solid var(--border);
  color: var(--text); font-size: 11.5px; outline: none;
}
.eli-inp { flex: 1; min-width: 0; }
.eli-inp:focus, .eli-sel:focus { border-color: var(--info); }
.eli-sel { cursor: pointer; }
.eli-sel.full { width: 100%; margin-bottom: 6px; }
.eli-btn {
  flex-shrink: 0; white-space: nowrap; cursor: pointer;
  padding: 7px 11px; border-radius: 8px;
  border: 1px solid var(--info); background: rgba(56,139,253,0.10);
  color: var(--info); font-size: 10.5px; font-weight: 800;
}
.eli-btn:hover { background: rgba(56,139,253,0.20); }
.eli-fchip {
  cursor: pointer; white-space: nowrap;
  padding: 5px 11px; border-radius: 20px;
  font-size: 10px; font-weight: 700;
  border: 1px solid var(--border); background: var(--bg-input);
  color: var(--text-muted); transition: color .12s, border-color .12s, background .12s;
}
.eli-fchip:hover { color: var(--text); border-color: var(--text-muted); }
.eli-fchip b { margin-left: 5px; font-weight: 800; opacity: .75; font-variant-numeric: tabular-nums; }
.eli-fchip.wide { flex: 1; }
.eli-fchip.on { color: var(--text); }
.eli-fchip.on.a { border-color: var(--accent); background: rgba(230,57,70,0.12); }
.eli-fchip.on.s { border-color: var(--success); background: rgba(63,185,80,0.12); }
.eli-fchip.on.i { border-color: var(--info); background: rgba(56,139,253,0.12); }
.eli-ls {
  background: var(--bg-input); border: 1px solid var(--border);
  border-radius: 10px; padding: 9px 11px; margin-bottom: 9px;
}
.eli-ls-lbl {
  font-size: 10px; font-weight: 800; letter-spacing: .4px;
  text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px;
}
.eli-ls-hint { font-size: 10px; color: var(--info); margin-top: 6px; line-height: 1.5; }

.eli-list { display: grid; gap: 7px; grid-template-columns: 1fr; align-items: start; }
.eli-grp {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: 8px;
  margin: 8px 0 1px; padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.eli-grp:first-child { margin-top: 0; }
.eli-grp-name { font-size: 11.5px; font-weight: 800; letter-spacing: .3px; }
.eli-grp-cnt {
  margin-left: auto; font-size: 10px; color: var(--text-muted);
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.eli-card {
  background: var(--bg-input); border: 1px solid var(--border);
  border-left: 3px solid var(--border); border-radius: 10px;
  padding: 9px 11px 10px;
}
.eli-card.st-done { border-left-color: var(--success); }
.eli-card.st-rdy { border-left-color: var(--info); }
.eli-card.st-miss { border-left-color: #d29922; }
.eli-card.st-lock { border-left-color: #6e7681; }
.eli-top { display: flex; align-items: center; gap: 7px; }
.eli-ico { flex-shrink: 0; font-size: 14px; line-height: 1; }
.eli-name {
  min-width: 0; font-size: 12.5px; font-weight: 700;
  line-height: 1.35; overflow-wrap: anywhere;
}
.eli-tier {
  flex-shrink: 0; padding: 2px 6px; border-radius: 5px;
  font-size: 9.5px; font-weight: 800;
  background: var(--bg-dark); border: 1px solid var(--border); color: var(--text-muted);
}
.eli-state {
  margin-left: auto; flex-shrink: 0; white-space: nowrap;
  padding: 3px 9px; border-radius: 20px;
  font-size: 10px; font-weight: 800; border: 1px solid transparent;
}
.eli-state.st-done { color: var(--success); background: rgba(63,185,80,0.10); border-color: rgba(63,185,80,0.32); }
.eli-state.st-rdy { color: var(--info); background: rgba(56,139,253,0.10); border-color: rgba(56,139,253,0.32); }
.eli-state.st-miss { color: #d29922; background: rgba(210,153,34,0.10); border-color: rgba(210,153,34,0.35); }
.eli-state.st-lock { color: var(--text-muted); background: rgba(110,118,129,0.12); border-color: var(--border); }
.eli-evt {
  margin-left: 5px; padding: 1px 5px; border-radius: 4px;
  font-size: 9px; font-weight: 800; white-space: nowrap;
  color: #d29922; background: rgba(210,153,34,0.12); border: 1px solid rgba(210,153,34,0.35);
}
.eli-meta {
  display: flex; flex-wrap: wrap; gap: 3px 12px;
  margin-top: 7px; font-size: 10px; color: var(--text-muted);
}
.eli-meta b { color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; }
.eli-req { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--border); }
.eli-req-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; margin-bottom: 5px;
}
.eli-req-lbl {
  font-size: 9.5px; font-weight: 800; letter-spacing: .4px;
  text-transform: uppercase; color: var(--text-muted);
}
.eli-req-cnt { font-size: 10px; font-weight: 800; white-space: nowrap; }
.eli-req-cnt.ok { color: var(--success); }
.eli-req-cnt.miss { color: #d29922; }
.eli-cov {
  height: 5px; margin-bottom: 7px; border-radius: 3px;
  background: var(--bg-dark); overflow: hidden;
}
.eli-cov i { display: block; height: 100%; border-radius: 3px; background: var(--success); transition: width .4s ease; }
.eli-cov.miss i { background: #d29922; }
.eli-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.eli-chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 8px; border-radius: 7px;
  font-size: 10px; font-weight: 600; line-height: 1.35;
  border: 1px solid var(--border); background: var(--bg-card); color: var(--text);
}
.eli-chip b { font-weight: 800; font-variant-numeric: tabular-nums; }
.eli-chip.ok { border-color: rgba(63,185,80,0.28); background: rgba(63,185,80,0.07); }
.eli-chip.ok b { color: var(--success); }
.eli-chip.aequi { border-color: rgba(56,139,253,0.32); background: rgba(56,139,253,0.07); }
.eli-chip.aequi b { color: var(--info); }
.eli-chip.miss { border-color: rgba(210,153,34,0.45); background: rgba(210,153,34,0.10); }
.eli-chip.miss b { color: #d29922; }
.eli-chip .have { color: var(--text-muted); font-weight: 700; font-variant-numeric: tabular-nums; }
.eli-lock {
  display: flex; gap: 7px; align-items: flex-start;
  margin-top: 8px; padding: 6px 9px; border-radius: 8px;
  background: rgba(110,118,129,0.10); border: 1px solid var(--border);
  font-size: 10px; line-height: 1.5; color: var(--text-muted);
}
.eli-lock b { color: var(--text); font-weight: 700; }
.eli-leer {
  grid-column: 1 / -1; text-align: center;
  padding: 26px 10px; color: var(--text-muted); font-size: 12px;
}
.eli-mehr {
  grid-column: 1 / -1; text-align: center;
  padding: 10px 0 2px; color: var(--text-muted); font-size: 10.5px;
}

@media (min-width: 900px) {
  .eli-list { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 767px) {
  .eli-sum-val { font-size: 15px; }
  .eli-leg b { font-size: 13px; }
  .eli-name { font-size: 12px; }
  .eli-chip { font-size: 9.5px; padding: 3px 7px; }
}

.eli-basis {
  margin-top: 9px; padding-top: 9px;
  border-top: 1px solid var(--border);
  font-size: 10px; line-height: 1.55; color: var(--text-muted);
}
.eli-basis b { color: var(--text); font-variant-numeric: tabular-nums; }
.eli-basis strong { color: var(--text); font-weight: 700; }
.eli-sel.f1 { flex: 1; min-width: 0; }
.eli-sel.f2 { flex: 2; min-width: 0; }
.eli-beds { display: grid; gap: 3px; }
.eli-bed {
  display: flex; flex-wrap: wrap; align-items: baseline;
  gap: 2px 8px; font-size: 10px; line-height: 1.5;
}
.eli-bed > span:first-child { flex: 0 0 auto; }
.eli-bed-l { flex: 1 1 auto; min-width: 0; color: var(--text-muted); }
.eli-bed-v {
  flex: 0 1 auto; margin-left: auto; text-align: right;
  font-weight: 700; font-variant-numeric: tabular-nums;
}
.eli-bed-v em { font-style: normal; font-weight: 600; color: var(--text-muted); }
.eli-bed.ok .eli-bed-v { color: var(--success); }
.eli-bed.warn .eli-bed-v { color: #d29922; }
.eli-bed.info .eli-bed-v { color: var(--info); }
.eli-bed.full { display: grid; grid-template-columns: 15px minmax(0, 1fr); gap: 2px 6px; }
.eli-bed.full .eli-bed-v {
  grid-column: 2; margin-left: 0; text-align: left;
  font-weight: 600; overflow-wrap: anywhere;
}
.eli-note {
  margin-top: 8px; padding: 6px 9px; border-radius: 7px;
  background: rgba(56,139,253,0.07); border: 1px solid rgba(56,139,253,0.26);
  font-size: 10px; line-height: 1.5; color: var(--text-muted);
}
.eli-note strong { color: var(--info); font-weight: 700; }

.eli-lade { padding: 26px 4px 30px; text-align: center; }
.eli-lade p { margin-top: 12px; font-size: 12px; color: var(--text-muted); line-height: 1.5; }
.eli-lade-bar {
  height: 4px; border-radius: 3px; overflow: hidden;
  background: var(--bg-input); max-width: 320px; margin: 0 auto;
}
.eli-lade-bar i {
  display: block; height: 100%; width: 40%; border-radius: 3px;
  background: var(--info); animation: eliLade 1.1s ease-in-out infinite;
}
@keyframes eliLade {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(260%); }
}
@media (prefers-reduced-motion: reduce) {
  .eli-lade-bar i { animation: none; width: 100%; opacity: .5; }
}

.wr-kopf {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-input); border: 1px solid var(--border);
  border-radius: 12px; padding: 11px 14px; margin-bottom: 12px;
}
.wr-kopf.frei { border-color: rgba(63,185,80,0.45); background: rgba(63,185,80,0.07); }
.wr-kopf-ico { font-size: 22px; line-height: 1; flex-shrink: 0; }
.wr-kopf-txt { min-width: 0; }
.wr-kopf-t { font-size: 12.5px; font-weight: 800; }
.wr-kopf.frei .wr-kopf-t { color: var(--success); }
.wr-kopf-s { font-size: 10.5px; color: var(--text-muted); margin-top: 2px; line-height: 1.5; }
.wr-kopf-z {
  margin-left: auto; flex-shrink: 0; text-align: right;
  font-size: 15px; font-weight: 800; color: var(--info);
  font-variant-numeric: tabular-nums;
}
.wr-kopf-z small { display: block; font-size: 9px; font-weight: 700; color: var(--text-muted); }

.wr-buehne {
  display: flex; flex-direction: column; align-items: center;
  gap: 10px; padding: 6px 0 10px;
}
.wr-zeiger {
  font-size: 24px; line-height: 1; margin-bottom: -14px; z-index: 2;
  color: #fff; filter: drop-shadow(0 2px 5px rgba(0,0,0,0.6));
  transform: rotate(180deg);
}
.wr-rad {
  border-radius: 50%;
  box-shadow: 0 6px 28px rgba(0,0,0,0.45), 0 0 0 6px var(--bg-card), 0 0 0 7px var(--border);
  max-width: 100%; height: auto;
}
.wr-knoepfe {
  display: flex; flex-wrap: wrap; gap: 9px; justify-content: center;
  width: 100%; max-width: 430px; margin: 10px auto 0;
}
.wr-knoepfe .wr-btn { flex: 1 1 175px; min-width: 0; }
.wr-btn {
  padding: 13px 30px; border-radius: 12px; border: none; cursor: pointer;
  font-size: 15px; font-weight: 800; color: #fff;
  background: linear-gradient(135deg, #e63946, #d29922);
  box-shadow: 0 4px 16px rgba(230,57,70,0.35);
  transition: transform .12s, box-shadow .12s, filter .12s;
}
.wr-btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(230,57,70,0.45); }
.wr-btn:disabled {
  cursor: not-allowed; background: var(--bg-input);
  color: var(--text-muted); box-shadow: none;
}
.wr-btn.fl {
  font-size: 12.5px; padding: 10px 16px; line-height: 1.25;
  background: rgba(249,115,22,0.12); color: #fb923c;
  border: 1px solid rgba(249,115,22,0.45); box-shadow: none;
}
.wr-btn.fl:hover:not(:disabled) { background: rgba(249,115,22,0.22); box-shadow: none; }
.wr-btn.fl:disabled { background: var(--bg-input); border-color: var(--border); color: var(--text-muted); }
.wr-btn.fl small { display: block; font-size: 9.5px; font-weight: 700; opacity: .8; margin-top: 2px; }
.wr-ergebnis { min-height: 54px; text-align: center; margin-top: 2px; }
.wr-gewinn { animation: wrPop .45s cubic-bezier(.175,.885,.32,1.275); }
.wr-gewinn-ico { font-size: 30px; line-height: 1; }
.wr-gewinn-l { font-size: 19px; font-weight: 800; margin-top: 3px; }
.wr-gewinn-s { font-size: 11px; color: var(--text-muted); margin-top: 3px; }
@keyframes wrPop { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .wr-gewinn { animation: none; } }

.wr-tabelle { margin-top: 14px; }
.wr-tab-kopf {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; margin-bottom: 7px;
}
.wr-tab-lbl {
  font-size: 10px; font-weight: 800; letter-spacing: .5px;
  text-transform: uppercase; color: var(--text-muted);
}
.wr-tab-info { font-size: 10px; color: var(--info); font-weight: 700; }
.wr-liste { display: grid; gap: 4px; }
.wr-zeile {
  display: flex; align-items: center; gap: 9px;
  background: var(--bg-input); border: 1px solid var(--border);
  border-radius: 8px; padding: 6px 10px;
}
.wr-punkt { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.wr-name { font-size: 11.5px; font-weight: 700; min-width: 0; }
.wr-balken {
  margin-left: auto; width: 84px; height: 5px; flex-shrink: 0;
  background: var(--bg-dark); border-radius: 3px; overflow: hidden;
}
.wr-balken i { display: block; height: 100%; border-radius: 3px; }
.wr-chance {
  flex-shrink: 0; width: 42px; text-align: right;
  font-size: 10.5px; font-weight: 800; color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
.wr-fuss {
  margin-top: 10px; padding: 9px 11px; border-radius: 9px;
  background: rgba(56,139,253,0.07); border: 1px solid rgba(56,139,253,0.25);
  font-size: 10.5px; color: var(--text-muted); line-height: 1.55;
}
.wr-fuss b { color: var(--text); }
@media (max-width: 560px) {
  .wr-balken { width: 52px; }
  .wr-btn { padding: 12px 22px; font-size: 14px; }
}

.wr-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-bottom: 10px; }
.wr-tab {
  position: relative; display: flex; align-items: center; gap: 9px;
  padding: 9px 11px; border-radius: 11px; cursor: pointer; text-align: left;
  border: 1px solid var(--border); background: var(--bg-input); color: var(--text-muted);
  transition: border-color .15s, background .15s, color .15s, transform .12s;
}
.wr-tab:hover { transform: translateY(-1px); color: var(--text); }
.wr-tab-ico { font-size: 19px; line-height: 1; flex-shrink: 0; }
.wr-tab-txt { min-width: 0; line-height: 1.25; }
.wr-tab-txt b { display: block; font-size: 12.5px; font-weight: 800; }
.wr-tab-txt small { font-size: 9.5px; opacity: .8; }
.wr-tab.on { color: var(--text); background: rgba(230,57,70,0.10); border-color: var(--accent); }
.wr-tab.on.premium {
  background: linear-gradient(135deg, rgba(253,224,71,0.16), rgba(168,85,247,0.14));
  border-color: #fde047; box-shadow: 0 0 18px rgba(253,224,71,0.22);
}
.wr-tab.premium .wr-tab-ico { filter: drop-shadow(0 0 6px rgba(253,224,71,0.7)); }
.wr-tab-dot {
  position: absolute; top: 7px; right: 8px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--success); box-shadow: 0 0 0 0 rgba(63,185,80,0.6);
  animation: wrDot 1.8s ease-out infinite;
}
@keyframes wrDot {
  0% { box-shadow: 0 0 0 0 rgba(63,185,80,0.55); }
  70% { box-shadow: 0 0 0 7px rgba(63,185,80,0); }
  100% { box-shadow: 0 0 0 0 rgba(63,185,80,0); }
}

.wr-kopf.prem { border-color: rgba(253,224,71,0.45); background: rgba(253,224,71,0.07); }
.wr-kopf.frei.prem { border-color: rgba(253,224,71,0.7); background: rgba(253,224,71,0.12); }
.wr-kopf.frei.prem .wr-kopf-t { color: #fde047; }

.wr-buehne { position: relative; overflow: hidden; border-radius: 14px; }
.wr-glanz {
  position: absolute; inset: -40% 0 auto 0; height: 190px; pointer-events: none;
  background: radial-gradient(ellipse at 50% 0%, rgba(230,57,70,0.16), transparent 68%);
  opacity: .85; transition: opacity .3s;
}
.wr-buehne.prem .wr-glanz {
  background: radial-gradient(ellipse at 50% 0%, rgba(253,224,71,0.20), rgba(168,85,247,0.12) 45%, transparent 70%);
}
.wr-radbox {
  position: relative; border-radius: 50%; padding: 0; line-height: 0;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5), 0 0 0 7px var(--bg-card), 0 0 0 8px var(--border);
  transition: box-shadow .35s;
}
.wr-radbox.prem {
  box-shadow: 0 8px 32px rgba(0,0,0,0.55), 0 0 0 7px #1a1608, 0 0 0 9px #fde047,
    0 0 34px rgba(253,224,71,0.35);
}
.wr-buehne.dreht .wr-radbox { box-shadow: 0 8px 30px rgba(0,0,0,0.5), 0 0 0 7px var(--bg-card), 0 0 0 8px var(--accent), 0 0 42px rgba(230,57,70,0.45); }
.wr-buehne.dreht.prem .wr-radbox { box-shadow: 0 8px 30px rgba(0,0,0,0.55), 0 0 0 7px #1a1608, 0 0 0 9px #fde047, 0 0 55px rgba(253,224,71,0.6); }
.wr-buehne.dreht .wr-glanz { opacity: 1; }
.wr-buehne.treffer .wr-radbox { animation: wrPuls 1.1s ease-out; }
@keyframes wrPuls {
  0% { transform: scale(1); }
  25% { transform: scale(1.035); }
  100% { transform: scale(1); }
}
.wr-zeiger {
  text-shadow: 0 0 12px rgba(255,255,255,0.55);
  animation: wrZeiger 2.4s ease-in-out infinite;
}
@keyframes wrZeiger { 0%,100% { transform: rotate(180deg) translateY(0); } 50% { transform: rotate(180deg) translateY(-2px); } }
.wr-buehne.dreht .wr-zeiger { animation: wrZeigerFast .18s ease-in-out infinite; }
@keyframes wrZeigerFast { 0%,100% { transform: rotate(180deg) translateY(0); } 50% { transform: rotate(180deg) translateY(-4px); } }

.wr-btn.prem {
  background: linear-gradient(135deg, #eab308, #a855f7);
  box-shadow: 0 4px 18px rgba(234,179,8,0.4);
}
.wr-btn.prem:hover:not(:disabled) { box-shadow: 0 6px 24px rgba(234,179,8,0.55); }

.wr-gewinn.gross .wr-gewinn-ico { animation: wrTada 1s ease-out; }
@keyframes wrTada {
  0% { transform: scale(.6) rotate(-12deg); }
  40% { transform: scale(1.3) rotate(8deg); }
  70% { transform: scale(.95) rotate(-4deg); }
  100% { transform: scale(1) rotate(0); }
}
.wr-konfetti { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 5; }
.wr-konfetti i {
  position: absolute; top: -12px; width: 7px; height: 11px; border-radius: 1px;
  animation: wrFall 1.8s cubic-bezier(.25,.8,.5,1) forwards;
}
@keyframes wrFall {
  0% { transform: translateY(0) rotate(0); opacity: 1; }
  100% { transform: translateY(330px) rotate(540deg); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .wr-tab-dot, .wr-zeiger, .wr-buehne.dreht .wr-zeiger,
  .wr-buehne.treffer .wr-radbox, .wr-gewinn.gross .wr-gewinn-ico { animation: none; }
  .wr-konfetti { display: none; }
}
@media (max-width: 560px) {
  .wr-tab-txt b { font-size: 11.5px; }
  .wr-tab { padding: 8px 9px; gap: 7px; }
}


.els-help-ov {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  z-index: 10020;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  overscroll-behavior: contain;
}
.els-help-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0;
  max-width: 620px;
  width: 100%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.els-help-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.els-help-head h3 {
  margin: 0;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.els-help-badge {
  background: rgba(56,139,253,0.15);
  border: 1px solid var(--info);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  font-size: 12px;
  font-weight: 700;
  color: var(--info);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.els-help-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
  padding: 0 4px;
  flex-shrink: 0;
}
.els-help-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 16px 20px;
  font-size: 13px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.els-help-body img,
.els-help-body table { max-width: 100%; }
.els-help-body pre,
.els-help-body table { overflow-x: auto; }

@supports (height: 100dvh) {
  .els-help-box { max-height: 88dvh; }
}

@media (max-width: 700px) {
  .els-help-ov {
    padding: 0;
    align-items: flex-end;
  }
  .els-help-box {
    max-width: none;
    width: 100%;
    max-height: 92vh;
    border-radius: 16px 16px 0 0;
    border-left: none;
    border-right: none;
    border-bottom: none;
  }
  .els-help-head {
    padding: 14px 16px calc(14px);
    position: sticky;
    top: 0;
    background: var(--bg-card);
    border-radius: 16px 16px 0 0;
    z-index: 1;
  }
  .els-help-head h3 { font-size: 16px; }
  .els-help-close {
    font-size: 30px;
    padding: 0 10px;
    min-width: 44px;
    min-height: 44px;
  }
  .els-help-body {
    font-size: 15.5px;
    line-height: 1.68;
    padding: 16px 16px calc(24px + env(safe-area-inset-bottom, 0px));
  }
  .els-help-body h4 { font-size: 15px !important; }
  .els-help-body li { margin-bottom: 7px; }
  .els-help-body ul,
  .els-help-body ol { margin-left: 17px !important; padding-left: 0 !important; }
}

@supports (height: 100dvh) {
  @media (max-width: 700px) {
    .els-help-box { max-height: 92dvh; }
  }
}

@keyframes dlSchimmer {
  0%   { background-position: -180% 0; }
  100% { background-position: 280% 0; }
}
@keyframes dlFlamme {
  0%, 100% { transform: scale(1) translateY(0);   filter: drop-shadow(0 3px 14px rgba(230,57,70,.75)); }
  50%      { transform: scale(1.09) translateY(-3px); filter: drop-shadow(0 6px 26px rgba(255,159,28,.95)); }
}
@keyframes dlAuftauchen {
  from { opacity: 0; transform: translateY(7px) scale(.93); }
  to   { opacity: 1; transform: none; }
}
@keyframes dlHeuteRing {
  0%, 100% { box-shadow: 0 0 0 0 rgba(210,153,34,.65), 0 0 16px rgba(210,153,34,.5); }
  50%      { box-shadow: 0 0 0 6px rgba(210,153,34,0), 0 0 26px rgba(210,153,34,.85); }
}
@keyframes dlFunkeln {
  0%, 100% { opacity: .30; transform: rotate(0deg)   scale(1); }
  50%      { opacity: .70; transform: rotate(180deg) scale(1.15); }
}
.dl-kachel { animation: dlAuftauchen .34s ease-out both; }
.dl-heute  { animation: dlHeuteRing 1.9s ease-in-out infinite; }
.dl-flamme { animation: dlFlamme 2.4s ease-in-out infinite; }
.dl-balken-glanz {
  background-image: linear-gradient(100deg, transparent 20%, rgba(255,255,255,.55) 50%, transparent 80%);
  background-size: 200% 100%;
  animation: dlSchimmer 2.6s linear infinite;
}
.dl-aura { animation: dlFunkeln 7s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .dl-kachel, .dl-heute, .dl-flamme, .dl-balken-glanz, .dl-aura { animation: none; }
}

.leaflet-popup-content-wrapper {
  position: relative;
}
.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: var(--bg-card);
  color: var(--text);
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.55);
}
.leaflet-popup-content-wrapper {
  border: 1px solid var(--border);
}
.leaflet-container a.leaflet-popup-close-button {
  color: var(--text-muted);
}
.leaflet-container a.leaflet-popup-close-button:hover,
.leaflet-container a.leaflet-popup-close-button:focus {
  color: var(--accent);
}
.leaflet-popup-content a {
  color: var(--accent);
}
.leaflet-popup-content.leaflet-popup-scrolled {
  overscroll-behavior: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-right: 14px;
}
.leaflet-popup-content.leaflet-popup-scrolled::-webkit-scrollbar {
  width: 0;
  height: 0;
}
.el-rollbahn {
  position: absolute;
  right: 5px;
  width: 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.10);
  z-index: 5;
  pointer-events: auto;
}
.el-rollgriff {
  width: 8px;
  border-radius: 8px;
  background: var(--accent, #e63946);
  cursor: grab;
  transition: background 0.15s;
}
.el-rollgriff:active {
  cursor: grabbing;
  background: var(--accent-hover, #c1121f);
}


.aao-rule-row{content-visibility:auto;contain-intrinsic-size:auto 64px;display:flex;gap:6px;align-items:stretch;margin-bottom:4px;background:var(--bg-input);
  border:1px solid var(--border);border-radius:10px;padding:8px;transition:border-color .15s}
.aao-rule-row:hover{border-color:rgba(230,57,70,0.3)}
.aao-rule-l1{display:flex;gap:6px;flex:1;min-width:0;align-items:stretch}
.aao-rule-l2{display:flex;gap:6px;align-items:center}
.aao-hk{display:flex;align-items:center;justify-content:center;width:26px;flex-shrink:0;cursor:pointer;
  font-size:15px;color:var(--text-muted);user-select:none}
.aao-hk[data-an="1"]{color:var(--success)}
.aao-kat{width:42px;padding:0;border-radius:6px;background:var(--bg-card);border:1px solid var(--border);
  color:var(--text);font-size:14px;cursor:pointer;text-align:center;text-align-last:center}
.aao-kat[data-ohne-kat="1"]{border-color:#f7b11f}
.aao-fz{flex:1;padding:7px 10px;border-radius:6px;background:var(--bg-card);border:1px solid var(--border);
  color:var(--text);font-size:12px;cursor:pointer;text-align:left;display:flex;align-items:center;
  justify-content:space-between;gap:6px;min-width:0;transition:all .15s}
.aao-fz:hover{border-color:var(--accent);background:rgba(230,57,70,0.05)}
.aao-fz-l{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.aao-fz-l strong{color:var(--text);font-size:13px}
.aao-fz-n{font-size:10px;color:var(--text-muted);margin-left:6px;display:block;line-height:1.2;margin-top:2px}
.aao-fz-leer{color:var(--text-muted);font-style:italic}
.aao-fz-p{color:var(--text-muted);flex-shrink:0;font-size:10px}
.aao-anz{display:flex;align-items:center;gap:0;background:var(--bg-card);border:1px solid var(--border);
  border-radius:6px;padding:0 2px;flex-shrink:0}
.aao-anz>button{background:transparent;border:none;color:var(--text-muted);cursor:pointer;font-size:15px;
  width:24px;line-height:1;padding:6px 0;flex-shrink:0}
.aao-anz>input{width:52px;padding:0;background:transparent;border:none;color:var(--text);font-size:13px;
  font-weight:700;text-align:center;outline:none;font-variant-numeric:tabular-nums}
.aao-wache{padding:6px 4px;border-radius:6px;background:var(--bg-card);border:1px solid var(--border);
  color:var(--text-muted);font-size:10px;cursor:pointer;max-width:90px}
.aao-wache[data-gesetzt="1"]{color:var(--text)}
.aao-bed{padding:6px 8px;border-radius:6px;border:1px solid var(--border);background:var(--bg-card);
  color:var(--text-muted);cursor:pointer;font-size:11px}
.aao-bed[data-an="1"]{border-color:#a78bfa;background:rgba(168,139,250,0.15);color:#a78bfa}
.aao-weg{padding:0 10px;border-radius:6px;border:1px solid rgba(230,57,70,0.3);background:transparent;
  color:var(--accent);cursor:pointer;font-size:13px;transition:all .15s}
.aao-weg:hover{background:rgba(230,57,70,0.12)}
.vp-item{content-visibility:auto;contain-intrinsic-size:auto 38px}
