body { margin: 0; }
    #map { height: 600px; margin-bottom: 20px; }
    #time-slider { margin-top: 45px; margin-bottom: 60px; }
    .leaflet-control-attribution { display: none !important; }

    .legend {
      background: #fff; padding: 10px; border-radius: 5px;
      box-shadow: 0 0 15px rgba(0,0,0,.2); line-height: 1.6;
    }
    .legend input[type=checkbox]{ margin-right: 5px; }
    .legend .band-label{ margin-left: 10px; }
    .source-legend { min-width: 92px; }
    .source-legend input[type=checkbox] { vertical-align: middle; }

    .spinner {
      display:none; position:fixed; top:50%; left:50%; z-index:1000;
      width:100px; height:100px; margin:-50px 0 0 -50px;
      border:16px solid #f3f3f3; border-radius:50%;
      border-top:16px solid #3498db; animation:spin 2s linear infinite;
    }
    @keyframes spin { 0%{transform:rotate(0)} 100%{transform:rotate(360deg)} }

    .noUi-tooltip {
      background:#000; color:#fff; padding:3px 6px; border-radius:5px;
      font-size:.75rem; opacity:.6; transition:opacity .2s ease-in-out;
    }
    .noUi-handle-lower .noUi-tooltip { top:100%; bottom:auto; transform:translateY(10px); }
    .noUi-handle-upper .noUi-tooltip { bottom:100%; top:auto; transform:translateY(-10px); }

    .btn-discreet {
      font-size:.55rem; padding:.25rem; border-radius:.2rem;
      opacity:.5; transition:opacity .3s; height:1.5rem;
    }
    .btn-discreet:hover{ opacity:.2; }


.qrz-popup {
  min-width: 210px;
}

.qrz-popup-image {
  display: block;
  width: 100%;
  max-width: 260px;
  max-height: 190px;
  margin: 0 auto 10px;
  border-radius: 4px;
  object-fit: contain;
  background: #f1f1f1;
}

.qrz-popup-photo-placeholder {
  display: flex;
  min-height: 90px;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  color: #666;
  text-align: center;
  background: #f7f7f7;
}

.qrz-popup-details {
  line-height: 1.55;
}


/* Mode + Antennas nebeneinander oben links */
.source-antenna-control {
  display: flex;
  gap: 18px;
  min-width: 285px;
  align-items: flex-start;
}

.source-antenna-control .control-column {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
}

.source-antenna-control .control-column strong {
  margin-bottom: 2px;
}

.source-antenna-control label {
  display: block;
  margin: 0;
  cursor: pointer;
  line-height: 1.55;
}

.source-antenna-control .antenna-column {
  padding-left: 14px;
  border-left: 1px solid #d9d9d9;
}

.antenna-swatch {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin: 0 4px 0 1px;
  border-radius: 2px;
  vertical-align: middle;
}

@media (max-width: 700px) {
  .source-antenna-control {
    gap: 10px;
    min-width: 0;
    max-width: calc(100vw - 90px);
    font-size: 12px;
  }

  .source-antenna-control .antenna-column {
    padding-left: 10px;
  }
}


/* ---- Tabs WSPR / QRZ ---- */
#sourceTabs { margin-bottom: 10px; }
#sourceTabs .nav-link { font-weight: 600; padding: .4rem 1.4rem; cursor: pointer; }

/* Tab WSPR: keine QSO-Zeile, keine Antennenauswahl */
body.tab-wspr #qrzStatus,
body.tab-wspr .source-antenna-control { display: none !important; }

/* Tab QRZ: QSO-Zeile als Ueberschrift; WSPR-Ueberschrift, Bands und Zeitleiste ausblenden */
body.tab-qrz #summary,
body.tab-qrz .bands-legend { display: none !important; }
body.tab-qrz #time-slider { visibility: hidden; }
body.tab-qrz #qrzStatus { font-size: 1.5rem; font-weight: 500; line-height: 1.2; margin-bottom: .5rem; }
body.tab-qrz #qrzStatus.text-muted { color: #212529 !important; }

/* Antennenauswahl ohne Mode-Spalte: schmaler */
.source-antenna-control { min-width: 0; }
