* { box-sizing: border-box; }

body {
  margin: 0;
  background: #08090d;
  color: #d7dbe6;
  font-family: -apple-system, "Hiragino Sans", "Noto Sans JP", sans-serif;
  display: flex;
  justify-content: center;
  padding: 32px 16px 48px;
}

.wrap { width: 100%; max-width: 940px; }

header { margin-bottom: 20px; }

h1 {
  margin: 0 0 6px;
  font-size: 22px;
  letter-spacing: .12em;
  font-weight: 600;
}

.lead {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
  color: #7e879b;
}

.stage {
  display: flex;
  flex-direction: column;
  align-items: center;
}

canvas {
  width: min(100%, 620px);
  aspect-ratio: 1;
  display: block;
  border-radius: 10px;
  background: #000;
  box-shadow: 0 0 0 1px #1c2030, 0 24px 60px -24px #000;
  cursor: crosshair;
  touch-action: none;
}

.hint {
  margin-top: 10px;
  font-size: 12px;
  color: #5c6478;
}

.panel {
  margin: 26px auto 0;
  max-width: 620px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px 22px;
}

.presets, .actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

button {
  background: #151926;
  color: #cfd5e3;
  border: 1px solid #262c3f;
  border-radius: 7px;
  padding: 7px 14px;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
}

button:hover { background: #1d2231; }
.preset.on { border-color: #5f7cff; color: #b9c6ff; }

label {
  display: block;
  font-size: 12px;
  color: #8891a6;
}

output {
  float: right;
  color: #cfd5e3;
  font-variant-numeric: tabular-nums;
}

input[type=range] {
  width: 100%;
  margin-top: 8px;
  accent-color: #5f7cff;
}

select {
  width: 100%;
  margin-top: 8px;
  background: #151926;
  color: #cfd5e3;
  border: 1px solid #262c3f;
  border-radius: 7px;
  padding: 6px 8px;
  font-family: inherit;
  font-size: 13px;
}

.stat {
  grid-column: 1 / -1;
  font-size: 12px;
  color: #5c6478;
  font-variant-numeric: tabular-nums;
}
