/* FPS / teljesítmény ablak — chat-stílusú, húzható */
body:not(.wu-in-game) #perf-panel {
  display: none !important;
}

#perf-panel {
  display: none;
  position: fixed;
  left: 12px;
  bottom: 118px;
  top: auto;
  right: auto;
  z-index: 2147483150;
  width: 240px;
  max-width: min(320px, calc(100vw - 16px));
  padding: 0;
  box-sizing: border-box;
  font: 11px/1.4 Consolas, "Courier New", monospace;
  font-variant-numeric: tabular-nums;
  color: #d4e8f8;
  background: rgba(6, 12, 24, 0.92);
  border: 1px solid rgba(110, 190, 255, 0.42);
  border-radius: 10px;
  pointer-events: auto;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 12px 28px rgba(0, 0, 0, 0.5),
    0 0 16px rgba(40, 140, 220, 0.1);
  overflow: hidden;
  user-select: none;
}

#perf-panel.show {
  display: block;
}

#perf-panel.perf-dragging {
  opacity: 0.94;
  box-shadow:
    0 0 0 1px rgba(120, 200, 255, 0.35) inset,
    0 16px 36px rgba(0, 0, 0, 0.65);
}

#perf-panel .perf-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 8px 6px 10px;
  cursor: grab;
  background: linear-gradient(180deg, rgba(36, 80, 130, 0.7), rgba(12, 28, 48, 0.95));
  border-bottom: 1px solid rgba(120, 190, 255, 0.28);
  color: #dff2ff;
  letter-spacing: 0.05em;
}

#perf-panel.perf-dragging .perf-titlebar {
  cursor: grabbing;
}

#perf-panel .perf-title-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

#perf-panel .perf-grip {
  display: grid;
  grid-template-columns: repeat(3, 3px);
  gap: 2px;
  opacity: 0.65;
}

#perf-panel .perf-grip span {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #8ec8f0;
}

#perf-panel .perf-label {
  font: 700 10px Orbitron, sans-serif;
  text-transform: uppercase;
}

#perf-panel-close {
  position: static;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(80, 140, 190, 0.45);
  border-radius: 4px;
  background: rgba(8, 20, 36, 0.85);
  color: #9ec8e8;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 0;
}

#perf-panel-close:hover {
  color: #fff;
  border-color: #4ec8ff;
}

#perf-panel-body {
  margin: 0;
  padding: 8px 10px 9px;
  white-space: pre;
  color: #7CFF9A;
  font: inherit;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.55);
  background: rgba(2, 8, 16, 0.45);
}
