:root {
  --body-hi: #f7f4ed;
  --body: #ebe7de;
  --body-lo: #ddd7cb;
  --edge: #a9a192;
  --ink: #24221e;
  --ink-2: #5f5a50;
  --ink-3: #8f897c;
  --orange: #ff5a1f;
  --key-hi: #fcfbf7;
  --key-lo: #e6e1d7;
  --key-edge: #b7af9f;
  --font: 'Space Grotesk', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(900px 520px at 50% 42%, rgba(255, 170, 110, .10), transparent 70%),
    radial-gradient(1400px 900px at 50% 30%, #34343b 0%, #1d1d22 55%, #111114 100%);
  background-color: #151518;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
button { font-family: inherit; color: inherit; }
button:focus { outline: none; }
:focus-visible { outline: 2px solid #2f7bff; outline-offset: 3px; }

.stage {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 26px 18px 18px;
  gap: 18px;
}
.caption {
  margin: 0;
  color: rgba(255, 255, 255, .42);
  font-size: 12px;
  letter-spacing: .02em;
  text-align: center;
  max-width: 760px;
}

/* ================================================================ device */
.device {
  position: relative;
  width: min(1160px, 100%);
  padding: 24px 28px 16px;
  border-radius: 26px;
  background: linear-gradient(180deg, var(--body-hi) 0%, var(--body) 24%, #e6e1d7 100%);
  box-shadow:
    inset 0 1.5px 0 rgba(255, 255, 255, .95),
    inset 0 -2px 0 rgba(0, 0, 0, .06),
    0 0 0 1px rgba(0, 0, 0, .28),
    0 9px 0 -1px var(--edge),
    0 9px 0 0 rgba(0, 0, 0, .35),
    0 30px 50px -8px rgba(0, 0, 0, .55),
    0 70px 120px -30px rgba(0, 0, 0, .7);
  user-select: none;
  -webkit-user-select: none;
  animation: rise .9s cubic-bezier(.2, .8, .2, 1) both;
}
.device::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: .55;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.4  0 0 0 0 0.35  0 0 0 0 0.3  0 0 0 .09 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
@keyframes rise {
  from { opacity: 0; transform: translateY(24px) scale(.985); }
  to { opacity: 1; transform: none; }
}

.screw {
  position: absolute;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #c9c3b6 60%, #9c9586);
  box-shadow: inset 0 0 0 .5px rgba(0, 0, 0, .35), 0 1px 0 rgba(255, 255, 255, .8);
}
.screw::after {
  content: '';
  position: absolute;
  left: 2px; right: 2px; top: 50%;
  height: 1.6px;
  margin-top: -.8px;
  background: rgba(60, 55, 45, .55);
  transform: rotate(var(--r, 35deg));
}
.screw.tl { left: 11px; top: 11px; }
.screw.tr { right: 11px; top: 11px; --r: -20deg; }
.screw.bl { left: 11px; bottom: 11px; --r: 70deg; }
.screw.br { right: 11px; bottom: 11px; --r: 10deg; }

/* ================================================================ top */
.top {
  display: grid;
  grid-template-columns: 210px 1fr 150px;
  gap: 22px;
  align-items: stretch;
}
.brand {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding-left: 6px;
}
.logo {
  font-family: 'Unbounded', var(--font);
  font-weight: 900;
  font-size: 40px;
  line-height: .95;
  letter-spacing: -.035em;
  color: var(--ink);
}
.logo span { color: var(--orange); }
.sub {
  font-weight: 700;
  font-size: 11.5px;
  letter-spacing: .26em;
  color: var(--ink);
  margin-top: 4px;
}
.spec {
  font-weight: 500;
  font-size: 10px;
  letter-spacing: .14em;
  color: var(--ink-3);
}
.pwr {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 12px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .2em;
  color: var(--ink-2);
}

.led {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #8f8a80, #5e5a52);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, .4), 0 1px 0 rgba(255, 255, 255, .7);
  flex: none;
  transition: background .08s, box-shadow .08s;
}
.led.on {
  background: radial-gradient(circle at 35% 35%, #fff2c8, #ffb020 45%, #ff6a00);
  box-shadow: 0 0 6px 1px rgba(255, 140, 20, .75), 0 0 14px rgba(255, 120, 0, .45);
}

.screen-wrap {
  padding: 10px;
  border-radius: 16px;
  background: linear-gradient(180deg, #1b1a18, #0f0e0d);
  box-shadow:
    inset 0 2px 6px rgba(0, 0, 0, .7),
    0 1.5px 0 rgba(255, 255, 255, .95),
    0 -1px 0 rgba(0, 0, 0, .15);
  min-width: 0;
}
.screen {
  position: relative;
  height: 158px;
  border-radius: 7px;
  overflow: hidden;
  background: #070503;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .04);
}
.screen canvas { display: block; width: 100%; height: 100%; }
.glass {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(158deg, rgba(255, 255, 255, .09) 0%, rgba(255, 255, 255, .02) 32%, transparent 33%),
    repeating-linear-gradient(0deg, rgba(0, 0, 0, .22) 0 1px, transparent 1px 3px),
    radial-gradient(120% 140% at 50% 50%, transparent 60%, rgba(0, 0, 0, .55));
}

.speaker {
  align-self: center;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  padding: 8px;
  background: linear-gradient(180deg, #d6d0c4, #efebe3);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, .22), 0 1.5px 0 rgba(255, 255, 255, .95);
}
.grille {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background:
    radial-gradient(circle, #2a2723 1.7px, transparent 2.3px) 0 0 / 9px 9px,
    radial-gradient(circle at 50% 38%, #e9e5dc, #d3cdbf);
  box-shadow: inset 0 3px 8px rgba(0, 0, 0, .2);
  -webkit-mask: radial-gradient(circle, #000 69%, transparent 70%);
  mask: radial-gradient(circle, #000 69%, transparent 70%);
}

/* ================================================================ controls */
.controls {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px 26px;
  margin-top: 20px;
  padding: 14px 20px 12px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(0, 0, 0, .045), rgba(0, 0, 0, .025));
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1), 0 1px 0 rgba(255, 255, 255, .8);
}
.gknobs { display: flex; gap: 6px; }

.transport {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* ---------------------------------------------------------------- knobs */
.knob-unit {
  --ks: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  width: 64px;
}
.knob-unit.small { --ks: 34px; width: 50px; gap: 7px; }
.knob {
  position: relative;
  width: var(--ks);
  height: var(--ks);
  margin-top: 6px;
  border-radius: 50%;
  touch-action: none;
  cursor: grab;
  --kc: var(--c, var(--orange));
}
.knob-unit.active .knob { cursor: grabbing; }
.knob svg {
  position: absolute;
  inset: -7px;
  width: calc(100% + 14px);
  height: calc(100% + 14px);
  transform: rotate(135deg);
  overflow: visible;
  pointer-events: none;
}
.knob-unit.small .knob svg { inset: -6px; width: calc(100% + 12px); height: calc(100% + 12px); }
.knob circle { fill: none; stroke-width: 5; stroke-linecap: round; }
.arc-bg { stroke: rgba(40, 35, 25, .13); }
.arc { stroke: var(--kc); transition: stroke-dasharray .05s; }
.cap {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 20deg, #f4f3ef, #b8b4ab 10%, #f7f6f2 22%, #a9a59c 36%, #eeede8 50%, #bdb9b0 63%, #fbfaf6 76%, #a8a49b 89%, #f4f3ef);
  box-shadow:
    0 5px 9px -2px rgba(0, 0, 0, .38),
    0 1.5px 2px rgba(0, 0, 0, .35),
    inset 0 -1.5px 2px rgba(0, 0, 0, .22),
    inset 0 1px 1px rgba(255, 255, 255, .9);
}
.cap::before {
  content: '';
  position: absolute;
  inset: 13%;
  border-radius: 50%;
  background: radial-gradient(circle at 42% 30%, #ffffff, #ebe8e1 55%, #d2cec5);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .07), 0 1px 2px rgba(0, 0, 0, .12);
}
.ind {
  position: absolute;
  inset: 0;
  transform: rotate(var(--rot, 0deg));
}
.ind::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 9%;
  width: 3px;
  height: 32%;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--ink);
}
.knob:focus-visible { outline-offset: 9px; border-radius: 50%; }
.klabel {
  position: relative;
  height: 12px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  line-height: 12px;
  color: var(--ink-2);
  white-space: nowrap;
  text-align: center;
}
.knob-unit.small .klabel { font-size: 9px; letter-spacing: .1em; }
.kval {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  opacity: 0;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.knob-unit.active .kname, .knob-unit:focus-within .kname { opacity: 0; }
.knob-unit.active .kval, .knob-unit:focus-within .kval { opacity: 1; }

/* ---------------------------------------------------------------- keys */
.key {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 62px;
  height: 58px;
  padding: 6px 10px 5px;
  border: 0;
  border-radius: 11px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  background: linear-gradient(180deg, var(--key-hi), var(--key-lo));
  box-shadow:
    inset 0 1px 0 #fff,
    inset 0 -2px 0 rgba(0, 0, 0, .06),
    0 4px 0 var(--key-edge),
    0 5px 1px rgba(0, 0, 0, .25),
    0 9px 14px -4px rgba(0, 0, 0, .3);
  transform: translateY(0);
  transition: transform .07s, box-shadow .07s, background .2s;
  cursor: pointer;
  touch-action: manipulation;
}
.key .ico { width: 18px; height: 18px; fill: currentColor; }
.key:active {
  transform: translateY(3px);
  box-shadow: inset 0 1px 0 #fff, 0 1px 0 var(--key-edge), 0 2px 3px rgba(0, 0, 0, .25);
}
.key-play {
  min-width: 86px;
  color: #fff;
  background: linear-gradient(180deg, #ff7b45, #f2521a);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .5),
    inset 0 -2px 0 rgba(0, 0, 0, .1),
    0 4px 0 #b83708,
    0 5px 1px rgba(0, 0, 0, .25),
    0 9px 16px -4px rgba(242, 82, 26, .55);
  text-shadow: 0 1px 0 rgba(0, 0, 0, .15);
}
.key-play:active { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), 0 1px 0 #b83708, 0 2px 3px rgba(0, 0, 0, .25); }
.key-play .led { position: absolute; top: 8px; right: 9px; width: 6px; height: 6px; background: rgba(90, 20, 0, .45); box-shadow: inset 0 1px 1px rgba(0, 0, 0, .35); }
.key-play.playing .led { background: radial-gradient(circle at 35% 35%, #fff, #fff4d0); box-shadow: 0 0 6px 2px rgba(255, 255, 220, .8); }
.key-play.playing.beat .led { box-shadow: 0 0 10px 4px rgba(255, 255, 220, .95); }
.key-play .i-stop { display: none; }
.key-play.playing .i-stop { display: block; }
.key-play.playing .i-play { display: none; }
.key-dark {
  color: #f3efe6;
  background: linear-gradient(180deg, #3a3833, #24221e);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .18),
    0 4px 0 #0d0c0b,
    0 5px 1px rgba(0, 0, 0, .3),
    0 9px 14px -4px rgba(0, 0, 0, .4);
}
.key-dark:active { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), 0 1px 0 #0d0c0b, 0 2px 3px rgba(0, 0, 0, .3); }
.key-dark .ico { fill: #ffb347; color: #ffb347; }

.grooves { display: flex; flex-direction: column; align-items: flex-start; gap: 7px; }
.glabel { font-size: 9.5px; font-weight: 700; letter-spacing: .22em; color: var(--ink-3); padding-left: 2px; }
.gbtns { display: grid; grid-template-columns: repeat(2, auto); gap: 7px; }
.gbtn {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 25px;
  padding: 0 10px 0 8px;
  border: 0;
  border-radius: 7px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--ink-2);
  background: linear-gradient(180deg, var(--key-hi), var(--key-lo));
  box-shadow: inset 0 1px 0 #fff, 0 2px 0 var(--key-edge), 0 3px 5px -1px rgba(0, 0, 0, .25);
  cursor: pointer;
  transition: transform .06s, box-shadow .06s;
  touch-action: manipulation;
}
.gbtn b { color: var(--ink); font-size: 11px; }
.gbtn .led { width: 5px; height: 5px; }
.gbtn.sel .led { background: radial-gradient(circle at 35% 35%, #fff2c8, #ffb020 45%, #ff6a00); box-shadow: 0 0 5px 1px rgba(255, 140, 20, .75); }
.gbtn:active { transform: translateY(2px); box-shadow: inset 0 1px 0 #fff, 0 0 0 var(--key-edge), 0 1px 2px rgba(0, 0, 0, .25); }

/* ================================================================ sequencer */
.ruler, .track {
  display: grid;
  grid-template-columns: 262px 1fr;
  column-gap: 16px;
}
.ruler { margin-top: 16px; }
.rgrid, .pads { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.rgrp { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 0 5px; }
.rgrp span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}
.rgrp i { width: 5px; height: 5px; border-radius: 50%; background: #b8b1a3; box-shadow: inset 0 1px 1px rgba(0, 0, 0, .25); }
.rgrp span.on { color: var(--ink); }
.rgrp span.on i { background: #ff4a10; box-shadow: 0 0 6px 1px rgba(255, 74, 16, .8); }

.tracks { display: grid; gap: 9px; margin-top: 6px; }
.track { align-items: center; transition: opacity .2s; }
.thead {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 4px 0;
}
.tname {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .18em;
  min-width: 0;
}
.tname i {
  width: 8px;
  height: 30px;
  border-radius: 3px;
  background: var(--c);
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .15), 0 0 12px -2px var(--c);
}
.tknobs { display: flex; gap: 2px; }
.mute {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 46px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--ink-2);
  background: linear-gradient(180deg, var(--key-hi), var(--key-lo));
  box-shadow: inset 0 1px 0 #fff, 0 3px 0 var(--key-edge), 0 4px 6px -1px rgba(0, 0, 0, .25);
  cursor: pointer;
  transition: transform .06s, box-shadow .06s;
  touch-action: manipulation;
}
.mute .led { width: 6px; height: 6px; }
.mute:active { transform: translateY(2px); box-shadow: inset 0 1px 0 #fff, 0 1px 0 var(--key-edge), 0 1px 2px rgba(0, 0, 0, .25); }
.track.muted .mute .led { background: radial-gradient(circle at 35% 35%, #ffd6c8, #ff3d1f 50%, #c21800); box-shadow: 0 0 6px 1px rgba(255, 50, 20, .7); }
.track.muted .mute { color: var(--ink); }
.track.muted .pads { opacity: .38; filter: saturate(.3); }
.track.muted .tname { opacity: .5; }

.grp {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  padding: 5px;
  border-radius: 11px;
  background: rgba(0, 0, 0, .05);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1), 0 1px 0 rgba(255, 255, 255, .7);
}
.grp:nth-child(even) { background: rgba(0, 0, 0, .085); }

.pad {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  min-height: 34px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(180deg, #fbfaf6, #e4dfd5);
  box-shadow:
    inset 0 1px 0 #fff,
    inset 0 -1.5px 0 rgba(0, 0, 0, .05),
    0 3px 0 #bdb5a6,
    0 4px 5px -1px rgba(0, 0, 0, .28);
  cursor: pointer;
  touch-action: pan-y;
  transition: transform .06s, box-shadow .06s, background-color .1s;
  -webkit-touch-callout: none;
}
.pad::before { /* LED window */
  content: '';
  position: absolute;
  top: 16%;
  left: 50%;
  width: 26%;
  height: 7%;
  min-height: 3px;
  margin-left: -13%;
  border-radius: 3px;
  background: rgba(60, 50, 35, .16);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, .2);
}
.pad:active { transform: translateY(2px); box-shadow: inset 0 1px 0 #fff, 0 1px 0 #bdb5a6, 0 1px 2px rgba(0, 0, 0, .25); }
.pad.on {
  background: linear-gradient(180deg, color-mix(in srgb, var(--c) 72%, #fff), var(--c) 70%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .55),
    inset 0 -2px 0 rgba(0, 0, 0, .08),
    0 3px 0 color-mix(in srgb, var(--c) 62%, #3a2a10),
    0 4px 6px -1px rgba(0, 0, 0, .3),
    0 0 16px -3px var(--c);
}
.pad.on::before { background: #fff; box-shadow: 0 0 6px 1px rgba(255, 255, 255, .9); }
.pad.on[data-v="1"] {
  background: linear-gradient(180deg, color-mix(in srgb, var(--c) 30%, #fff), color-mix(in srgb, var(--c) 48%, #efe9dd));
  box-shadow: inset 0 1px 0 #fff, 0 3px 0 color-mix(in srgb, var(--c) 45%, #9c937f), 0 4px 5px -1px rgba(0, 0, 0, .26);
}
.pad.on[data-v="1"]::before { background: rgba(255, 255, 255, .85); box-shadow: none; }
.pad .mark {
  position: absolute;
  left: 50%;
  bottom: 17%;
  width: 30%;
  aspect-ratio: 1;
  transform: translateX(-50%);
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .95);
  opacity: 0;
}
.pad.on[data-v="3"] .mark { opacity: 1; }
.pad[data-t="kick"] .mark, .pad[data-t="snare"] .mark { width: 20%; border: 0; background: #fff; box-shadow: 0 0 6px rgba(255, 255, 255, .8); }
.pad.on[data-v="3"] { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 3px 0 color-mix(in srgb, var(--c) 55%, #3a2a10), 0 4px 6px -1px rgba(0, 0, 0, .3), 0 0 22px -1px var(--c); }
.pad.on:active { transform: translateY(2px); }
.pad.ph { transform: translateY(1px); }
.pad.ph:not(.on) { background: linear-gradient(180deg, #efe9dd, #d9d2c4); }
.pad.ph::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 10px;
  border: 2px solid rgba(36, 34, 30, .6);
  pointer-events: none;
}
.pad.editing { transform: translateY(2px) scale(.97); }

/* bass: note + pitch contour */
.pad .note {
  position: absolute;
  left: 0;
  right: 0;
  top: 11%;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .02em;
  color: rgba(255, 255, 255, .95);
  text-shadow: 0 1px 0 rgba(0, 0, 0, .15);
  text-align: center;
  pointer-events: none;
}
.pad .pitch {
  position: absolute;
  left: 22%;
  right: 22%;
  height: 3px;
  border-radius: 2px;
  top: calc(80% - var(--p, 0) * 36%);
  background: rgba(255, 255, 255, .8);
  opacity: 0;
  pointer-events: none;
}
.pad.on .pitch { opacity: 1; }
.is-bass .pad.on::before { opacity: 0; }

/* ================================================================ footer */
.foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px 22px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding: 10px 6px 0;
  border-top: 1px solid rgba(0, 0, 0, .07);
  font-size: 10.5px;
  color: var(--ink-3);
  letter-spacing: .02em;
}
.foot p { margin: 0; }
.foot b { color: var(--ink-2); font-weight: 700; letter-spacing: .06em; font-size: 9.5px; }
.foot .keys { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
kbd {
  display: inline-block;
  padding: 2px 5px;
  margin-left: 4px;
  border-radius: 4px;
  font-family: inherit;
  font-size: 9px;
  font-weight: 700;
  color: var(--ink-2);
  background: linear-gradient(180deg, #fff, #ebe6dc);
  box-shadow: 0 1px 0 #b7af9f, 0 0 0 .5px rgba(0, 0, 0, .12);
}
.foot .keys kbd:first-child { margin-left: 0; }

/* ================================================================ picker */
.picker {
  position: absolute;
  z-index: 20;
  padding: 10px;
  border-radius: 14px;
  background: #1c1b19;
  color: #efe9dd;
  box-shadow: 0 18px 40px -8px rgba(0, 0, 0, .6), 0 0 0 1px rgba(255, 255, 255, .06);
  animation: pop .14s ease-out;
}
@keyframes pop { from { opacity: 0; transform: translateY(4px) scale(.97); } }
.ptitle { display: flex; align-items: center; gap: 7px; font-size: 10px; font-weight: 700; letter-spacing: .16em; color: #a9a293; margin: 2px 2px 9px; }
.ptitle i { width: 8px; height: 8px; border-radius: 2px; }
.picker button {
  border: 0;
  border-radius: 7px;
  background: #2d2b28;
  color: #efe9dd;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  cursor: pointer;
  box-shadow: 0 2px 0 #0e0d0c;
}
.picker button:hover { background: #3a3834; }
.picker button.sel { background: var(--c); color: #fff; }
.pnotes { display: grid; grid-template-columns: repeat(5, 44px); gap: 6px; }
.pnotes button { height: 34px; }
.pnotes button.root:not(.sel) { color: #ffb347; }
.poff { width: 100%; height: 30px; margin-top: 8px; }
.plevels { display: grid; grid-template-columns: repeat(4, auto); gap: 6px; }
.plevels button { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 8px 10px 7px; font-size: 9.5px; }
.plevels i { width: 18px; height: 18px; border-radius: 5px; background: #45423d; }
.plevels i[data-v="1"] { background: color-mix(in srgb, var(--c) 45%, #ddd); }
.plevels i[data-v="2"] { background: var(--c); }
.plevels i[data-v="3"] { background: var(--c); box-shadow: inset 0 0 0 2.5px #fff, 0 0 0 1px var(--c); }

/* ================================================================ boot sweep */
.device.booting .pad { animation: bootpad .75s both; animation-delay: calc(var(--col) * 45ms + var(--row) * 70ms + 250ms); }
@keyframes bootpad {
  0% { background: #fbfaf6; }
  35% { background: var(--c); box-shadow: 0 0 22px -2px var(--c), 0 3px 0 #bdb5a6; transform: translateY(-1px); }
  100% { }
}

/* ================================================================ responsive */
@media (max-width: 1120px) {
  .ruler, .track { grid-template-columns: 236px 1fr; }
  .knob-unit.small { width: 44px; --ks: 30px; }
  .gknobs { gap: 2px; }
  .knob-unit { width: 58px; --ks: 46px; }
  .key { min-width: 58px; padding: 6px 6px 5px; }
  .key-play { min-width: 76px; }
}

@media (max-width: 980px) {
  .device { padding: 20px 20px 14px; }
  .top { grid-template-columns: 170px 1fr 110px; gap: 16px; }
  .logo { font-size: 32px; }
  .controls { grid-template-columns: 1fr auto; }
  .gknobs { grid-column: 1 / -1; justify-content: space-around; }
  .transport { justify-content: flex-start; }
  .ruler { display: none; }
  .track { grid-template-columns: 1fr; row-gap: 6px; }
  .thead { grid-template-columns: auto auto 1fr; justify-content: start; padding: 0; }
  .tknobs { justify-content: flex-end; }
  .tracks { gap: 14px; margin-top: 16px; }
}

@media (max-width: 640px) {
  .stage { padding: 10px 8px 16px; justify-content: flex-start; }
  .device { padding: 14px 12px 12px; border-radius: 22px; }
  .screw { display: none; }
  .top { grid-template-columns: 1fr 58px; grid-template-areas: 'brand spk' 'screen screen'; gap: 10px; }
  .brand { grid-area: brand; padding-left: 4px; gap: 2px; }
  .logo { font-size: 26px; }
  .sub { font-size: 9.5px; margin-top: 2px; }
  .spec, .pwr { display: none; }
  .speaker { grid-area: spk; padding: 5px; }
  .grille { background-size: 6px 6px, auto; background-image: radial-gradient(circle, #2a2723 1.2px, transparent 1.7px), radial-gradient(circle at 50% 38%, #e9e5dc, #d3cdbf); }
  .screen-wrap { grid-area: screen; padding: 7px; border-radius: 13px; }
  .screen { height: 128px; }
  .controls { grid-template-columns: 1fr; gap: 12px; margin-top: 12px; padding: 12px 8px 10px; }
  .transport { order: -2; justify-content: space-between; gap: 6px; flex-wrap: nowrap; }
  .key { flex: 1 1 0; min-width: 0; height: 52px; padding: 5px 2px 4px; font-size: 8.5px; letter-spacing: .08em; border-radius: 10px; }
  .key-play { flex: 1.35 1 0; min-width: 0; }
  .key .ico { width: 16px; height: 16px; }
  .gknobs { order: -1; justify-content: space-between; gap: 0; }
  .knob-unit { width: 16.66%; --ks: 38px; gap: 8px; }
  .klabel { font-size: 8.5px; letter-spacing: .08em; }
  .grooves { flex-direction: row; align-items: center; gap: 8px; }
  .glabel { display: none; }
  .gbtns { grid-template-columns: repeat(4, 1fr); width: 100%; gap: 6px; }
  .gbtn { justify-content: center; padding: 0 4px; gap: 5px; height: 28px; font-size: 8.5px; letter-spacing: .04em; }
  .tracks { gap: 12px; margin-top: 12px; }
  .thead { grid-template-columns: 1fr auto auto; gap: 6px; }
  .tname { font-size: 11px; letter-spacing: .14em; }
  .tname i { height: 22px; width: 7px; }
  .knob-unit.small { width: 42px; --ks: 26px; gap: 6px; }
  .knob-unit.small .klabel { font-size: 8px; letter-spacing: .06em; }
  .knob-unit.small .knob svg { inset: -5px; width: calc(100% + 10px); height: calc(100% + 10px); }
  .knob circle { stroke-width: 6; }
  .mute { width: 44px; height: 32px; }
  .pads { grid-template-columns: repeat(2, 1fr); gap: 7px; }
  .grp { gap: 5px; padding: 4px; border-radius: 10px; }
  .pad { border-radius: 7px; min-height: 0; }
  .pad .note { font-size: 9px; }
  .foot { font-size: 10px; margin-top: 12px; }
  .foot .keys { display: none; }
  .caption { font-size: 11px; padding: 0 12px; }
}

@media (max-width: 360px) {
  .knob-unit { --ks: 32px; }
  .key span { font-size: 7.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .device { animation: none; }
  .device.booting .pad { animation: none; }
}
