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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  font-family: system-ui, -apple-system, sans-serif;
}

#canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
}

#panel {
  position: fixed;
  top: 12px;
  right: 12px;
  width: 230px;
  background: rgba(15, 15, 25, 0.75);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  color: #dde;
  font-size: 12px;
  user-select: none;
  z-index: 10;
}

#panelHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

#fps { font-weight: 400; opacity: 0.6; }

#panel.collapsed #controls { display: none; }
#panel.collapsed #panelHeader { border-bottom: none; }

#controls { padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }

#status {
  font-size: 11px;
  opacity: 0.75;
  min-height: 14px;
}

label { display: flex; flex-direction: column; gap: 3px; }
label.row { flex-direction: row; justify-content: space-between; align-items: center; }

input[type="range"] { width: 100%; accent-color: #6af; }

select {
  background: #223;
  color: #dde;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 5px;
  padding: 3px 5px;
  font-size: 12px;
}

.buttons { display: flex; gap: 8px; }

button {
  flex: 1;
  background: #334;
  color: #dde;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  padding: 6px 0;
  font-size: 12px;
  cursor: pointer;
}
button:hover { background: #445; }

.hint { font-size: 10px; opacity: 0.5; text-align: center; }

#cameraPrompt {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  z-index: 20;
}

#cameraPrompt.hidden { display: none; }

#cameraPromptBox {
  width: min(320px, calc(100vw - 32px));
  padding: 24px 20px;
  background: rgba(15, 15, 25, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  color: #dde;
  text-align: center;
}

#cameraPromptBox p {
  font-size: 14px;
  margin-bottom: 8px;
}

.cameraPromptHint {
  font-size: 11px !important;
  opacity: 0.6;
  margin-bottom: 12px !important;
}

.cameraSelectLabel {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  font-size: 11px;
  margin-bottom: 4px;
}

#cameraSelect {
  width: 100%;
  background: #223;
  color: #dde;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 5px;
  padding: 6px 8px;
  font-size: 12px;
}

#cameraPromptBox button {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 10px 0;
  font-size: 13px;
}

#cameraPromptBox button.secondary {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.2);
}
