:root {
  color-scheme: dark;
  --bg0: #090b11;
  --bg1: #0f1820;
  --panel: rgba(7, 11, 16, 0.72);
  --line: rgba(180, 210, 220, 0.16);
  --text: #ecf6f5;
  --muted: #9db4b5;
  --accent: #d3eee5;
  --button: #13252d;
  --button-alt: #0e141c;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at top, rgba(73, 106, 109, 0.18), transparent 34%),
    linear-gradient(180deg, var(--bg1), var(--bg0) 50%, #040507);
  color: var(--text);
  font-family: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
}

body {
  overflow: hidden;
}

#app {
  position: relative;
  width: 100vw;
  height: 100vh;
}

#scene {
  width: 100%;
  height: 100%;
  display: block;
}

.panel {
  position: absolute;
  top: 24px;
  left: 24px;
  width: min(340px, calc(100vw - 32px));
  padding: 18px 18px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.32);
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1;
}

.copy {
  margin: 10px 0 18px;
  color: var(--muted);
  line-height: 1.45;
}

.controls {
  display: grid;
  gap: 12px;
}

label {
  display: grid;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

input[type="range"] {
  width: 100%;
}

.actions {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

button {
  appearance: none;
  border: 1px solid rgba(211, 238, 229, 0.18);
  border-radius: 999px;
  padding: 10px 14px;
  background: var(--button);
  color: var(--text);
  cursor: pointer;
  transition: transform 120ms ease, background 120ms ease;
}

button:hover {
  transform: translateY(-1px);
}

button.secondary {
  background: var(--button-alt);
}

.status {
  margin: 14px 0 0;
  min-height: 18px;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 768px) {
  .panel {
    top: auto;
    bottom: 16px;
    left: 16px;
    right: 16px;
    width: auto;
  }
}

.panel > summary { cursor: pointer; padding: 10px 0; }
@media (min-width: 769px) { .panel > summary { display: none; } }
@media (max-width: 768px) {
  .panel { padding: 0 12px; bottom: max(8px, env(safe-area-inset-bottom)); }
  .panel-content { max-height: 40dvh; overflow-y: auto; padding-bottom: 12px; }
}
