:root {
  --bg: #11151c;
  --panel: #1a2029;
  --border: #2c3540;
  --text: #d7dee8;
  --muted: #8a97a8;
  --ok: #35c46a;
  --warn: #e8b93a;
  --down: #e8503a;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}

header {
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  position: relative;
  z-index: 10;
}

h1 { margin: 0; font-size: 20px; }

#meta { padding: 6px 20px 10px; color: var(--muted); font-size: 13px; }
#meta b { color: var(--text); }

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.loading-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.55);
  z-index: 9999;
}
.loading-overlay[hidden] { display: none; }

.spinner-lg {
  width: 56px;
  height: 56px;
  border: 5px solid rgba(255, 255, 255, 0.2);
  border-top-color: #4a90d9;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.toolbar {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 10px 20px;
}

.toolbar-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.toolbar-sep {
  width: 1px;
  align-self: stretch;
  min-height: 24px;
  background: var(--border);
}

@media (max-width: 900px) {
  .toolbar-sep { display: none; }
}

.field {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

.field-check {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

.probe-context {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  row-gap: 4px;
  padding: 8px 20px;
  font-size: 13px;
  color: var(--text);
  background: rgba(74, 144, 217, 0.08);
  border-top: 1px solid var(--border);
}

.probe-context.placeholder { color: var(--muted); font-style: italic; }
.probe-context b { color: #4a90d9; }

/* kazdy fragment (Sonda/Klient/MAC/...) zawija sie jako calosc — nigdy w
   srodku etykiety/wartosci — a separator "|" wedruje razem ze swoim
   fragmentem, wiec nigdy nie zostaje osierocony na koncu zawinietej linii */
.ctx-item {
  white-space: nowrap;
  max-width: 100%;
  overflow-wrap: break-word;
}
.ctx-item + .ctx-item::before {
  content: "|";
  color: var(--border);
  margin: 0 8px;
}

/* widok udostepniony linkiem z tokenem (bez logowania, patrz app.js:
   startSharedApp) — chowa cale menu zarzadzania/uzytkownika i selektor
   sondy (jest tylko jedna, ustalona przez token), zeby zostaly wylacznie
   host/zakres/wykresy tej jednej sondy */
.shared-mode .user-bar,
.shared-mode #manage-menu,
.shared-mode #probe-field,
.shared-mode #probe-picker,
.shared-mode #probe-context,
.shared-mode .toolbar-sep {
  display: none;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--muted);
  font-size: 16px;
  padding: 80px 20px;
}

#app-footer {
  padding: 16px 20px 24px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
  border-top: 1px solid var(--border);
  margin-top: 24px;
}
#app-footer a { color: var(--muted); }

#login-view {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

#login-view[hidden] { display: none; }

.login-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px 32px;
  min-width: 300px;
}

.login-box h1 { text-align: center; margin-bottom: 20px; }

#login-form { display: flex; flex-direction: column; gap: 12px; }
#login-form label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
#login-form input { padding: 7px 10px; font-size: 14px; }

#login-form button {
  margin-top: 6px;
  background: #4a90d9;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 600;
}

#login-form button:hover { background: #3a7fc4; }

#login-msg { min-height: 18px; font-size: 13px; color: var(--down); }

.user-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}

.inactivity-countdown {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 7px;
}
.inactivity-countdown.warn { color: var(--down); border-color: var(--down); }
.inactivity-countdown:empty { display: none; }

.btn-ghost {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 5px 12px;
  cursor: pointer;
  font-size: 12px;
}

.btn-ghost:hover { background: var(--panel); border-color: #4a90d9; }

.btn-primary {
  background: var(--ok);
  color: #0b2214;
  border: none;
  border-radius: 4px;
  padding: 6px 14px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
}

.btn-primary:hover { background: #2ea85c; }

#password-form, #user-add-form, #client-add-form { display: flex; flex-direction: column; gap: 10px; margin-bottom: 10px; }
#password-form label, #user-add-form label, #client-add-form label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
#password-msg, #user-add-msg, #client-add-msg { min-height: 18px; font-size: 13px; color: var(--down); }

.modal-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.modal-head-row h2 { margin: 0; }

#users-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-bottom: 6px; }
#users-table th { text-align: left; color: var(--muted); font-weight: 600; padding: 4px 8px 6px; border-bottom: 1px solid var(--border); }
#users-table td { padding: 5px 8px; border-bottom: 1px solid var(--border); }
#users-table button {
  background: none;
  border: 1px solid var(--down);
  color: var(--down);
  border-radius: 4px;
  padding: 2px 8px;
  cursor: pointer;
  font-size: 12px;
}
#users-table button:hover { background: rgba(232, 80, 58, 0.15); }

select, input, button {
  font-family: inherit;
}

select, input {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 13px;
}

#reset-zoom {
  background: #4a90d9;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 5px 12px;
  cursor: pointer;
  font-size: 13px;
}

#reset-zoom:hover { background: #3a7fc4; }

#analyze-btn {
  background: var(--ok);
  color: #0b2214;
  border: none;
  border-radius: 4px;
  padding: 6px 16px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
}

#analyze-btn:hover { background: #2ea85c; }
#analyze-btn:disabled { opacity: 0.6; cursor: wait; }

/* menu rozwijane: przycisk + lista (Zarzadzanie, wybor hostow do analizy) */
.dropdown { position: relative; }

.dropdown-btn {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 12px;
  cursor: pointer;
  font-size: 13px;
}

.dropdown-btn:hover { background: var(--panel); border-color: #4a90d9; }

.dropdown-list {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 60;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px;
  min-width: 210px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.5);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dropdown-list[hidden] { display: none; }

.dropdown-list button {
  background: none;
  border: none;
  color: var(--text);
  text-align: left;
  padding: 8px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  white-space: nowrap;
}

.dropdown-list button:hover { background: rgba(74, 144, 217, 0.15); }
.dropdown-list button.danger { color: var(--down); }
.dropdown-list button.danger:hover { background: rgba(232, 80, 58, 0.15); }

#clients-modal, #client-add-modal, #probes-modal, #password-modal,
#users-modal, #user-add-modal, #info-modal, #confirm-modal, #map-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

#clients-modal[hidden], #client-add-modal[hidden], #probes-modal[hidden],
#password-modal[hidden], #users-modal[hidden], #user-add-modal[hidden],
#info-modal[hidden], #confirm-modal[hidden], #map-modal[hidden] { display: none; }

/* modal otwierany z innego modala (albo nad innym) musi byc nad nim */
#user-add-modal, #client-add-modal, #info-modal, #confirm-modal { z-index: 120; }

.modal-actions button.danger {
  background: none;
  border: 1px solid var(--down);
  color: var(--down);
}
.modal-actions button.danger:hover { background: rgba(232, 80, 58, 0.15); }

.modal-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px 22px;
  min-width: 320px;
  max-width: 90vw;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.modal-box h2 { margin: 0 0 12px; font-size: 16px; }

.modal-box.wide { min-width: 520px; }

.modal-box.map-modal-box {
  width: min(1000px, 92vw);
  max-width: 92vw;
}

.map-msg { color: var(--muted); font-size: 12px; margin-left: auto; }

#probes-map {
  width: 100%;
  height: min(70vh, 640px);
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg);
}

/* standardowe (jasne) kafelki OpenStreetMap przemalowane filtrem na ciemny,
   czarno-szary wyglad — bez zaleznosci od osobnego zrodla "ciemnych" kafelkow.
   grayscale(1) PELNE (nie czesciowe) — inaczej invert() zamienia resztki
   koloru (np. zielone tereny) na fioletowy odcien zamiast czystej szarosci */
#probes-map .leaflet-tile-pane {
  filter: invert(1) grayscale(1) brightness(0.75) contrast(1.15);
}

/* Leaflet renderuje wlasny (jasny) popup — dopasowanie do ciemnego motywu panelu */
.leaflet-popup-content-wrapper, .leaflet-popup-tip {
  background: var(--panel);
  color: var(--text);
}
.leaflet-popup-content { font-size: 13px; margin: 10px 12px; }
.leaflet-popup-content b { color: #4a90d9; }
.leaflet-popup-close-button { color: var(--muted) !important; }
.map-probe-popup .dot { margin-right: 4px; }
.map-probe-popup-count {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 600;
}
.map-probe-link { cursor: pointer; }
.map-probe-link:hover b { text-decoration: underline; }
.map-probe-popup-item {
  padding: 4px 0;
  border-top: 1px solid var(--border);
}
.map-probe-popup-item:first-child { padding-top: 0; border-top: none; }
.map-probe-popup-loc {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid var(--border);
  color: var(--muted);
}

.modal-actions {
  margin-top: 14px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

#reset-all-confirm {
  background: var(--down);
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 6px 12px;
  font-weight: 600;
  cursor: pointer;
}

#reset-all-confirm:hover {
  background: #d6432f;
}

#reset-all-cancel {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 12px;
  cursor: pointer;
}

#clients-edit-msg, #probes-edit-msg { min-height: 18px; font-size: 13px; color: var(--down); margin-bottom: 8px; }

.client-header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.client-header input[type="text"]:first-child { flex: 2; min-width: 160px; }
.client-header .client-limit-input { max-width: 130px; }

.client-ips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  padding-left: 4px;
}

.client-ip-add-form { display: flex; gap: 6px; }
.client-ip-add-form input { max-width: 200px; }

#clients-modal-close, #client-add-modal-close, #probes-modal-close {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 5px 14px;
  cursor: pointer;
}

.probe-client {
  margin-bottom: 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
}

.probe-client h3 {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

.probe-client h3 b { color: var(--text); }

.probe-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.probe-row:last-child { border-bottom: none; }

.probe-row .probe-ip { color: var(--muted); font-size: 12px; min-width: 110px; }
.probe-row .probe-mac { color: var(--muted); font-size: 10px; opacity: 0.8; }
.probe-row input[type="text"] { flex: 1; }

.probe-row button {
  background: var(--ok);
  color: #0b2214;
  border: none;
  border-radius: 4px;
  padding: 4px 10px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.probe-row .btn-ghost {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  font-weight: 400;
  white-space: nowrap;
}

.probe-row button.danger {
  background: none;
  border: 1px solid var(--down);
  color: var(--down);
}
.probe-row button.danger:hover { background: rgba(232, 80, 58, 0.15); }
.probe-row .btn-ghost:hover { background: var(--panel); border-color: #4a90d9; }

.probe-hosts-panel {
  padding: 8px 0 12px 118px;
  border-bottom: 1px solid var(--border);
}

.probe-hosts-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.probe-hosts-empty { color: var(--muted); font-size: 12px; }

.host-chip-sm {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2px 4px 2px 10px;
  font-size: 12px;
}

.host-chip-sm button {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 2px 6px;
  border-radius: 50%;
}
.host-chip-sm button:hover { background: rgba(232, 80, 58, 0.2); color: var(--down); }

.probe-hosts-add-form { display: flex; gap: 8px; }
.probe-hosts-add-form input { flex: 1; max-width: 240px; }
.probe-hosts-add-form button {
  background: var(--ok);
  color: #0b2214;
  border: none;
  border-radius: 4px;
  padding: 4px 12px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.probe-speedtest-form {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.probe-speedtest-form input[type="number"] {
  width: 90px;
}

#host-picker-list {
  left: 0;
  right: auto;
  padding: 8px 12px;
  max-height: 280px;
  overflow-y: auto;
}

.dropdown-list label {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 3px 0;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
}

#host-picker-list label.all-hosts {
  border-bottom: 1px solid var(--border);
  padding-bottom: 6px;
  margin-bottom: 4px;
  font-weight: 600;
}

#analysis { padding: 12px 20px 0; }

.analysis-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-left: 5px solid var(--muted);
  border-radius: 6px;
  padding: 12px 16px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.3);
}

.analysis-box.verdict-ok { border-left-color: var(--ok); }
.analysis-box.verdict-warn { border-left-color: var(--warn); }
.analysis-box.verdict-critical { border-left-color: var(--down); }

.analysis-head { display: flex; align-items: center; gap: 12px; }
.analysis-head h2 { margin: 0; font-size: 16px; }
.analysis-time { color: var(--muted); font-size: 12px; }

#analysis-close {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 16px;
  cursor: pointer;
}

.verdict { margin: 8px 0; font-size: 14px; }
.verdict p { margin: 4px 0; }

.findings { margin-top: 8px; }
.findings td, .findings th { text-align: left; }
.findings tbody tr { cursor: pointer; }
.findings tbody tr:hover td { background: rgba(74, 144, 217, 0.10); }
.findings td.finding-text { white-space: normal; }
.findings tr.sev-critical td:first-child { color: var(--down); font-weight: 700; }
.findings tr.sev-warn td:first-child { color: var(--warn); font-weight: 700; }
.findings tr.sev-info td:first-child { color: var(--muted); }

.ai-summary {
  margin: 10px 0;
  padding: 10px 12px;
  background: rgba(74, 144, 217, 0.08);
  border: 1px solid var(--border);
  border-radius: 6px;
}
.ai-summary h3 { margin: 0 0 6px; font-size: 13px; color: var(--muted); }
.ai-summary p { margin: 0; font-size: 14px; line-height: 1.5; }

#host-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 20px;
}

.host-chip {
  padding: 6px 12px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--panel);
  cursor: pointer;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.host-chip.active { border-color: #4a90d9; box-shadow: 0 0 0 1px #4a90d9; }

.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.dot.ok { background: var(--ok); }
.dot.warn { background: var(--warn); }
.dot.down, .dot.error { background: var(--down); }
.dot.stale { background: var(--down); }
.dot.unknown { background: var(--muted); }

#latest-table { padding: 0 20px 12px; overflow-x: auto; }

table {
  border-collapse: collapse;
  width: 100%;
  background: var(--panel);
  font-size: 13px;
}

th, td {
  border: 1px solid var(--border);
  padding: 5px 10px;
  text-align: right;
  white-space: nowrap;
}

th { background: #202834; }
td:nth-child(2), th:nth-child(2) { text-align: left; }

tr.loss-warn td { background: rgba(232, 185, 58, 0.12); }
tr.loss-bad td  { background: rgba(232, 80, 58, 0.15); }

#charts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(560px, 1fr));
  gap: 14px;
  padding: 0 20px 24px;
}

.chart-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 20px 10px;
}

.nav-notice {
  margin: -4px 20px 10px;
  padding: 6px 12px;
  background: var(--panel);
  border: 1px solid var(--warn);
  border-radius: 4px;
  color: var(--warn);
  font-size: 13px;
}

.range-info {
  margin: 0 20px 10px;
  padding: 6px 12px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-left: 3px solid #4a90d9;
  border-radius: 4px;
  color: var(--text);
  font-size: 13px;
}

.range-info b { color: #4a90d9; }
.range-info .range-info-note { color: var(--muted); margin-left: 8px; }

.chart-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

#speedtest-box {
  margin: 0 20px 14px;
}

.section-divider {
  display: flex;
  align-items: center;
  margin: 4px 20px 14px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.section-divider::before,
.section-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.section-divider span { padding: 0 10px; }
.section-divider[hidden] { display: none; }

.chart-box h3 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.chart-box h3 b { color: var(--text); }

.chart-wrap { position: relative; height: 220px; }

@media (max-width: 620px) {
  #charts { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  body { overflow-x: hidden; }

  h1 { font-size: 17px; }

  .topbar {
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 12px;
  }

  .user-bar {
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    width: 100%;
    justify-content: flex-start;
  }

  #whoami { flex: 1 0 100%; }

  .user-bar .btn-ghost { flex: 1; text-align: center; }

  .toolbar {
    padding: 8px 12px;
    gap: 10px;
  }

  .toolbar-group {
    gap: 8px;
    width: 100%;
  }

  /* ujednolica pola z etykieta + select/input (Sonda/Host/Okres): zawsze
     etykieta nad polem na pelnej szerokosci, zamiast niespojnego zawijania
     zaleznego od dlugosci aktualnie wybranej opcji */
  .field {
    flex-direction: column;
    align-items: stretch;
    gap: 3px;
    width: 100%;
  }

  .field select, .field input:not([type="checkbox"]) {
    width: 100%;
  }

  .field-check { width: auto; }

  #probe-context, #meta { padding-left: 12px; padding-right: 12px; }

  #host-list { padding: 10px 12px; }

  #latest-table { padding: 0 12px 10px; }

  #analysis { padding: 10px 12px 0; }

  .chart-controls { margin: 0 12px 10px; gap: 6px; }

  .nav-notice, .range-info { margin-left: 12px; margin-right: 12px; }

  .section-divider { margin-left: 12px; margin-right: 12px; }

  #speedtest-box { margin-left: 12px; margin-right: 12px; }

  #charts { padding: 0 12px 20px; gap: 10px; }

  .chart-wrap { height: 180px; }

  table { font-size: 12px; }
  th, td { padding: 4px 6px; }

  .login-box {
    min-width: 0;
    width: 88vw;
    padding: 22px 18px;
  }

  .modal-box {
    min-width: 0;
    width: 92vw;
    padding: 14px 16px;
  }

  .modal-box.wide { min-width: 0; width: 94vw; }

  /* na mobile menu rozwijane (Zarzadzanie/wybor sond/hostow) nie da sie
     bezpiecznie pozycjonowac wzgledem wlasnego, waskiego przycisku (right:0
     przy waskim kontenerze przycina szerokosc do przycisku, wiec dlugie
     etykiety przycisku i tak wystaja poza ekran) — zamiast tego "karta"
     przypieta na stale do dolu ekranu, niezaleznie od polozenia przycisku */
  .dropdown-list, #host-picker-list {
    position: fixed;
    left: 12px;
    right: 12px;
    top: auto;
    bottom: 12px;
    max-width: none;
    max-height: 70vh;
    overflow-y: auto;
    box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.45);
  }

  .dropdown-list button, #host-picker-list label { white-space: normal; }

  .client-header input[type="text"]:first-child { min-width: 0; flex-basis: 100%; }
  .client-header .client-limit-input { max-width: 100%; }

  .probe-hosts-panel { padding-left: 12px; }

  .probe-row { flex-wrap: wrap; }
}
