* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
  background: #000;
  color: #fff;
  overflow: hidden;
}

canvas { display: block; }

.logo {
  position: fixed;
  top: 20px;
  left: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.2);
  z-index: 1000;
}

.panel-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.4);
  font-size: 14px;
  cursor: pointer;
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: center;
}
.panel-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
}

.panel {
  position: fixed;
  top: 56px;
  right: 20px;
  width: 180px;
  background: rgba(0, 0, 0, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  padding: 14px;
  z-index: 1000;
  max-height: calc(100vh - 80px);
  overflow-y: auto;
  transition: opacity 0.2s, transform 0.2s;
}

.panel.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(10px);
}

.panel::-webkit-scrollbar { width: 2px; }
.panel::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 1px; }

.panel-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.35);
  margin-bottom: 14px;
  text-transform: uppercase;
}

.section {
  margin-bottom: 16px;
}

.section-title {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.2);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.control {
  margin-bottom: 10px;
}

.control-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3px;
}

.control-label {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
}

.control-value {
  font-size: 10px;
  font-family: 'SF Mono', monospace;
  color: rgba(255, 255, 255, 0.3);
}

.control-desc {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.18);
  line-height: 1.3;
  margin-top: 3px;
}

input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 1px;
  outline: none;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
}

input[type="range"]:hover::-webkit-slider-thumb {
  background: rgba(255, 255, 255, 0.8);
}

input[type="range"]::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
}

.toggles {
  display: flex;
  gap: 5px;
}

.toggle-btn {
  flex: 1;
  padding: 6px 0;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all 0.15s;
}

.toggle-btn:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.5);
}

.toggle-btn.active {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.7);
}

.action-btn {
  width: 100%;
  padding: 7px 0;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: all 0.15s;
  margin-top: 5px;
}

.action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
}

.dg { display: none !important; }

@media (max-width: 600px) {
  .panel {
    top: auto;
    bottom: 60px;
    right: 12px;
    left: 12px;
    width: auto;
    max-height: 45vh;
  }
  .panel-toggle {
    bottom: 16px;
    top: auto;
  }
  .logo {
    top: 14px;
    left: 14px;
  }
}
