/* ── Scroll behavior ─────────────────────────────────────────── */
html { scroll-behavior: smooth; }

/* ── CSS2DRenderer overlay (Three.js injeta <div> filho direto) ─ */
#canvas-container > div {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  pointer-events: none !important;
}

/* ── Título com gradiente ────────────────────────────────────── */
.gradient-title {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  background: linear-gradient(135deg, #FF9800, #4CAF50, #2196F3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Mode tabs ───────────────────────────────────────────────── */
.mode-tab:hover:not(.active) {
  background-color: #161b22;
  color: #e6edf3;
  border-color: #FF9800;
}
.mode-tab.active {
  background-color: rgba(255, 152, 0, 0.15);
  color: #FF9800;
  border-color: #FF9800;
  font-weight: 600;
}

/* ── Value card left border colors (por ID) ──────────────────── */
#card-S  { border-left-color: #FF9800; }
#card-P  { border-left-color: #4CAF50; }
#card-Q  { border-left-color: #2196F3; }
#card-D  { border-left-color: #E91E63; }
#card-N  { border-left-color: #00BCD4; }
#card-FP { border-left-color: #CE93D8; }
#card-S1 { border-left-color: #FFD54F; }

/* ── Range sliders ───────────────────────────────────────────── */
.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 5px;
  border-radius: 3px;
  background: #21262d;
  outline: none;
  cursor: pointer;
  border: 1px solid #30363d;
}
.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #FF9800;
  border: 2px solid #0d1117;
  cursor: pointer;
  transition: transform 0.1s;
}
.slider::-webkit-slider-thumb:hover { transform: scale(1.2); }
.slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #FF9800;
  border: 2px solid #0d1117;
  cursor: pointer;
}
.slider-phi::-webkit-slider-thumb,
.slider-phi::-moz-range-thumb { background: #CE93D8; }
.slider-thd::-webkit-slider-thumb,
.slider-thd::-moz-range-thumb { background: #E91E63; }

/* ── Info boxes ──────────────────────────────────────────────── */
.info-box {
  background: rgba(33, 150, 243, 0.07);
  border: 1px solid rgba(33, 150, 243, 0.25);
}
.info-box--D {
  background: rgba(233, 30, 99, 0.07);
  border-color: rgba(233, 30, 99, 0.25);
}
.info-box--N {
  background: rgba(0, 188, 212, 0.07);
  border-color: rgba(0, 188, 212, 0.25);
}

/* ── Labels 3D (criados por makeLabel() em script.js) ────────── */
.label-3d {
  background: rgba(13, 17, 23, 0.85);
  border: 1px solid #30363d;
  border-radius: 5px;
  padding: 2px 7px;
  font-family: 'Courier New', Courier, monospace;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}
