/* Wendle's rhythm board: a dark night sky with glowing pads */
body {
  margin: 0;
  min-height: 100vh;
  background: #1d1535;
  color: #f3e9ff;
  font-family: system-ui, sans-serif;
  text-align: center;
}
main { padding: 10px 16px 16px; width: 100%; max-width: 560px; margin: 0 auto; box-sizing: border-box; }
h1 { font-size: 1.4rem; margin: 0 0 2px; }
.hint { margin: 0 0 10px; opacity: 0.7; font-size: 0.9rem; }
.board { display: flex; gap: 8px; }
.pad {
  flex: 1;
  height: 64px;
  border: none;
  border-radius: 12px;
  background: var(--c);
  color: #1d1535;
  font-weight: bold;
  font-size: 1.1rem;
  opacity: 0.75;
  box-shadow: 0 5px 0 rgba(0,0,0,0.35);
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.08s, opacity 0.08s, box-shadow 0.08s;
}
.pad.hit {
  transform: translateY(4px);
  opacity: 1;
  box-shadow: 0 1px 0 rgba(0,0,0,0.35), 0 0 24px var(--c);
}
.pad:focus-visible, .cell:focus-visible, .play:focus-visible { outline: 3px solid #fff; }
.grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 4px;
  margin-top: 14px;
}
.cell {
  height: 30px;
  border: 2px solid var(--c);
  border-radius: 7px;
  background: transparent;
  opacity: 0.5;
  padding: 0;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.cell.on { background: var(--c); opacity: 0.9; }
.cell.now { opacity: 1; box-shadow: 0 0 0 2px #fff; }
.cell.now:not(.on) { background: rgba(255,255,255,0.18); }
.dots { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; margin-top: 8px; }
.dots span { height: 8px; border-radius: 4px; background: #3b2f63; }
.dots span.now { background: #fff; box-shadow: 0 0 10px #fff; }
.controls { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: center; }
.play {
  padding: 10px 24px;
  font-size: 1.05rem;
  border: none;
  border-radius: 999px;
  background: #b197fc;
  color: #1d1535;
  font-weight: bold;
  cursor: pointer;
}
.play.alt { background: #ffa94d; }
.play.alt.on { background: #ffe066; box-shadow: 0 0 14px #ffe066; }
.speed { display: flex; align-items: center; gap: 8px; font-size: 0.95rem; }
.speed input { width: 130px; accent-color: #b197fc; }
#bpmout { min-width: 64px; text-align: left; }
