/* NPN RF Command Center v1 */

#npn-rf-command-center {
  position: fixed;
  left: 18px;
  top: 94px;
  width: 390px;
  max-width: calc(100vw - 36px);
  max-height: calc(100dvh - 112px);
  z-index: 2147482400;
  color: #f4f8ff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  pointer-events: auto;
}

#npn-rf-command-center.npn-rf-minimized {
  display: none !important;
}

.npn-rf-shell {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-height: inherit;
  min-height: 0;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 22px;
  background:
    radial-gradient(circle at 15% 0%, rgba(118,255,209,.13), transparent 20rem),
    linear-gradient(180deg, rgba(8,13,23,.96), rgba(4,8,14,.92));
  box-shadow: 0 22px 58px rgba(0,0,0,.46), inset 0 1px 0 rgba(255,255,255,.08);
  backdrop-filter: blur(18px);
  overflow: hidden;
}

.npn-rf-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex: 0 0 auto;
  gap: 12px;
  padding: 14px 14px 11px;
  border-bottom: 1px solid rgba(255,255,255,.10);
}

.npn-rf-title b {
  display: block;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.npn-rf-title span {
  display: block;
  margin-top: 4px;
  color: rgba(244,248,255,.62);
  font-size: 11px;
}

.npn-rf-actions {
  display: flex;
  gap: 7px;
  flex: 0 0 auto;
}

.npn-rf-actions button,
.npn-rf-presets button {
  min-height: 28px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  color: #f4f8ff;
  padding: 0 10px;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
  cursor: pointer;
}

.npn-rf-actions button:hover,
.npn-rf-presets button:hover {
  background: rgba(255,255,255,.14);
}

.npn-rf-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 13px 14px 14px;
  display: grid;
  gap: 12px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  -webkit-overflow-scrolling: touch;
}

.npn-rf-body::-webkit-scrollbar {
  width: 9px;
}

.npn-rf-body::-webkit-scrollbar-track {
  background: rgba(0,0,0,.24);
  border-left: 1px solid rgba(255,255,255,.06);
}

.npn-rf-body::-webkit-scrollbar-thumb {
  background: rgba(118,255,209,.42);
  border: 2px solid rgba(4,8,14,.92);
  border-radius: 999px;
}

.npn-rf-body::-webkit-scrollbar-thumb:hover {
  background: rgba(118,255,209,.68);
}

.npn-rf-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.npn-rf-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
}

.npn-rf-field {
  min-width: 0;
}

.npn-rf-field label {
  display: block;
  color: rgba(244,248,255,.58);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 5px;
}

.npn-rf-field input,
.npn-rf-field select {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  background: rgba(0,0,0,.20);
  color: #f4f8ff;
  padding: 0 10px;
  font-size: 13px;
  outline: none;
}

.npn-rf-field input:focus,
.npn-rf-field select:focus {
  border-color: rgba(118,255,209,.42);
}

.npn-rf-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
}

.npn-rf-card {
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 15px;
  background: rgba(0,0,0,.18);
  padding: 9px;
  min-width: 0;
}

.npn-rf-card span {
  display: block;
  color: rgba(244,248,255,.56);
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.npn-rf-card b {
  display: block;
  margin-top: 5px;
  color: #f4f8ff;
  font-size: 18px;
  font-weight: 950;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.npn-rf-card small {
  display: block;
  margin-top: 4px;
  color: rgba(244,248,255,.52);
  font-size: 10px;
  line-height: 1.25;
}

.npn-rf-wide {
  grid-column: 1 / -1;
}

.npn-rf-status {
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 16px;
  padding: 10px;
  background: rgba(0,0,0,.18);
}

.npn-rf-status b {
  display: block;
  font-size: 13px;
}

.npn-rf-status p {
  margin: 5px 0 0;
  color: rgba(244,248,255,.64);
  font-size: 11px;
  line-height: 1.35;
}

.npn-rf-ok b { color: #74f29c; }
.npn-rf-warn b { color: #ffd166; }
.npn-rf-bad b { color: #ff5f6d; }

.npn-rf-dock-chip {
  box-sizing: border-box !important;
  display: grid !important;
  grid-template-columns: 28px minmax(0, 1fr) auto !important;
  align-items: center !important;
  gap: 10px !important;
  width: 470px !important;
  max-width: calc(100vw - 72px) !important;
  min-height: 76px !important;
  padding: 0 20px !important;
  border: 1px solid rgba(255,255,255,.15) !important;
  border-radius: 0 !important;
  background: rgba(32, 40, 48, .88) !important;
  color: #f4f8ff !important;
  box-shadow: none !important;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  cursor: pointer !important;
  pointer-events: auto !important;
  text-align: left !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.npn-rf-dock-chip:hover {
  background: rgba(42, 52, 61, .92) !important;
  border-color: rgba(255,255,255,.24) !important;
}

.npn-rf-chip-icon {
  color: #ffc94a !important;
  font-size: 20px !important;
}

.npn-rf-chip-label {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  font-size: 24px !important;
  font-weight: 950 !important;
  letter-spacing: -.03em !important;
}

.npn-rf-chip-restore {
  color: rgba(244,248,255,.68) !important;
  font-size: 20px !important;
  font-weight: 950 !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
}

#npn-rf-fallback-dock {
  position: fixed;
  left: 30px;
  right: 30px;
  bottom: 22px;
  z-index: 2147482900;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 16px;
  pointer-events: none;
  padding: 20px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 28px;
  background: rgba(4, 11, 19, .92);
  box-shadow: 0 18px 60px rgba(0,0,0,.38);
}

@media (max-width: 760px) {
  #npn-rf-command-center {
    left: 10px;
    right: 10px;
    top: 76px;
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 96px);
  }

  .npn-rf-grid,
  .npn-rf-results {
    grid-template-columns: 1fr;
  }

  .npn-rf-dock-chip {
    width: 100% !important;
    min-height: 68px !important;
  }

  .npn-rf-chip-label {
    font-size: 19px !important;
  }

  .npn-rf-chip-restore {
    font-size: 15px !important;
  }
}

/* NPN RF Site Planner v2 */
.npn-rf-sites-grid {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  background: rgba(0,0,0,.13);
  padding: 10px;
}

.npn-rf-wide-button {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  color: #f4f8ff;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.npn-rf-wide-button:hover {
  background: rgba(255,255,255,.14);
}

.npn-rf-lon-field label {
  opacity: 0;
}

#npnRfCopy {
  min-width: 52px;
}

/* NPN RF Antenna Cable v3 */
.npn-rf-antenna-grid,
.npn-rf-cable-grid {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  background: rgba(0,0,0,.13);
  padding: 10px;
}

.npn-rf-loss-note {
  margin-top: 5px;
  color: rgba(244,248,255,.58);
  font-size: 10px;
}

.npn-rf-loss-note b {
  color: #f4f8ff;
}

.npn-rf-total-loss {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  background: rgba(0,0,0,.20);
  color: #ffd166;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 950;
}

.npn-rf-sites-grid {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  background: rgba(0,0,0,.13);
  padding: 10px;
}

.npn-rf-wide-button {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  color: #f4f8ff;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.npn-rf-wide-button:hover {
  background: rgba(255,255,255,.14);
}

.npn-rf-lon-field label {
  opacity: 0;
}

#npnRfCopy {
  min-width: 52px;
}
