/* Keep RFI layer selection and its legends together in reading order. */
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #ops-adsb-view-mode {
  order: -85 !important;
  margin: 8px 0 6px !important;
  padding: 0 !important;
  border: 0 !important;
  background: none !important;
  gap: 3px !important;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #ops-adsb-view-mode .ops-track-heading {
  margin: 0 !important;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #ops-adsb-view-mode .ops-view-help {
  display: none !important;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode .row.navis-layer-row {
  order: -84 !important;
  position: relative;
  margin: 0 0 8px !important;
  padding: 0 !important;
  border: 0 !important;
  background: none !important;
  box-shadow: none !important;
}
/* The section heading already identifies these controls. Keep the label accessible. */
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode .row.navis-layer-row > label {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip-path: inset(50%);
  white-space: nowrap;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #layerTog {
  flex: 1 1 100%;
  width: 100% !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 3px !important;
  gap: 3px !important;
  border-radius: 8px !important;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #layerTog button {
  height: 30px !important;
  min-height: 30px !important;
  padding: 4px 6px !important;
  line-height: 1.2;
  white-space: normal;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode :is(#hexbin-legend, #raw-legend) {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 8px !important;
  padding: 8px 0 0 !important;
  border: 0 !important;
  border-top: 1px solid rgba(148, 163, 184, .18) !important;
  border-radius: 0 !important;
  background: none !important;
  box-shadow: none !important;
  gap: 3px 6px;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #hexbin-legend { order: -83 !important; }
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode #raw-legend { order: -82 !important; }
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode :is(#hexbin-legend, #raw-legend) .rfi-click-hint {
  margin-top: 4px !important;
}
html body #rfi-panel #panel.ops-console-active.ops-rfi-mode :is(#hexbin-legend, #raw-legend) .rfi-click-hint small {
  line-height: 1.4;
}
@media (max-width: 768px) and (orientation: portrait) {
  html body #rfi-panel #panel.ops-console-active.ops-rfi-mode[data-ops-tab="map"] #ops-adsb-view-mode {
    margin-top: 0 !important;
  }
  html body #rfi-panel #panel.ops-console-active.ops-rfi-mode[data-ops-tab="map"] :is(#hexbin-legend, #raw-legend):last-child {
    margin-bottom: 0 !important;
  }
}
