* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: #fafafa;
  color: #111;
  font: 13px/1.4 ui-monospace, "SF Mono", Menlo, monospace;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
#root { min-height: 100%; display: flex; align-items: center; justify-content: center; padding: 24px 16px; }
.synth { width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 20px; }
.head { display: flex; justify-content: space-between; align-items: baseline; }
.title { letter-spacing: 0.3em; font-size: 12px; }
.dim { color: #999; }
canvas.scope { width: 100%; height: 56px; display: block; border-top: 1px solid #111; border-bottom: 1px solid #111; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.seg { display: flex; border: 1px solid #111; }
.seg button, .oct button {
  font: inherit; background: none; border: 0; color: #111; padding: 6px 12px; cursor: pointer;
}
.seg button + button { border-left: 1px solid #111; }
.seg button.on { background: #111; color: #fafafa; }
.oct { display: flex; align-items: center; gap: 4px; border: 1px solid #111; }
.oct span { min-width: 2.5em; text-align: center; }
.knobs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; }
.knob { display: flex; flex-direction: column; gap: 6px; }
.knob .lbl { display: flex; justify-content: space-between; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 16px; background: none; }
input[type=range]::-webkit-slider-runnable-track { height: 1px; background: #111; }
input[type=range]::-moz-range-track { height: 1px; background: #111; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 10px; height: 10px; background: #111; border-radius: 50%; margin-top: -4.5px; }
input[type=range]::-moz-range-thumb { width: 10px; height: 10px; background: #111; border: 0; border-radius: 50%; }
.kb { position: relative; height: 160px; display: flex; touch-action: none; }
.w {
  flex: 1; border: 1px solid #111; margin-left: -1px; background: #fafafa;
  display: flex; align-items: flex-end; justify-content: center; padding-bottom: 8px; color: #bbb; font-size: 11px;
}
.w:first-child { margin-left: 0; }
.w.on { background: #111; color: #fafafa; }
.b {
  position: absolute; top: 0; width: 8%; height: 60%; background: #111; color: #666; font-size: 10px;
  display: flex; align-items: flex-end; justify-content: center; padding-bottom: 6px;
}
.b.on { background: #fafafa; border: 1px solid #111; color: #111; }
.hint { text-align: center; color: #999; font-size: 11px; }
@media (hover: none) { .w span, .b span, .hint { display: none; } }
