:root {
  color-scheme: dark;
  --bg: #0b0a14;
  --text: #f6f4ff;
  --dim: #a7a2cb;
  --glass: rgba(255, 255, 255, .055);
  --glass2: rgba(255, 255, 255, .1);
  --stroke: rgba(255, 255, 255, .11);
  --accent: #8b6cff;
  --accent2: #ff5c9a;
  --grad: linear-gradient(135deg, #8b6cff, #ff5c9a);
  --xr: 139, 108, 255; --x: rgb(139, 108, 255);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --radius: 20px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  touch-action: manipulation; overscroll-behavior: none;
  min-height: 100vh; min-height: 100dvh;
}
/* 오로라 배경 */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 40% at 8% 0%, rgba(139, 108, 255, .32), transparent 70%),
    radial-gradient(55% 40% at 100% 38%, rgba(255, 92, 154, .16), transparent 70%),
    radial-gradient(70% 45% at 30% 100%, rgba(52, 211, 160, .12), transparent 70%),
    var(--bg);
}
button, select { font: inherit; color: inherit; touch-action: manipulation; }
button { cursor: pointer; border: 0; }
button:focus-visible, select:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ---------- 레이아웃: 화면 하나에 다 들어오게 (스크롤 없음) ---------- */
html, body { height: 100%; overflow: hidden; }
.app { height: 100vh; height: 100dvh; max-width: 560px; margin: 0 auto; display: flex; flex-direction: column; }
.top {
  flex: none; z-index: 5;
  padding: calc(var(--safe-t) + 8px) 14px 8px;
  background: rgba(11, 10, 20, .68);
  -webkit-backdrop-filter: blur(20px) saturate(1.5); backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid var(--stroke);
}
.topbar { display: flex; align-items: center; gap: 8px; }
.logo { width: 30px; height: 30px; border-radius: 9px; box-shadow: 0 4px 14px -4px rgba(139, 108, 255, .8); flex: none; }
h1 {
  margin: 0; font-size: 20px; font-weight: 800; letter-spacing: -.03em; white-space: nowrap;
  background: linear-gradient(90deg, #fff, #d4c8ff 60%, #ffb3d1); -webkit-background-clip: text; background-clip: text; color: transparent;
}
@media (max-width: 440px) { h1 { display: none; } .topbar { gap: 6px; } }
.grow { flex: 1; }
select {
  background: var(--glass); border: 1px solid var(--stroke); border-radius: 12px;
  padding: 7px 8px; font-size: 16px; font-weight: 700;
}
.seg { display: inline-flex; background: var(--glass); border: 1px solid var(--stroke); border-radius: 14px; padding: 3px; gap: 2px; }
.seg button { background: transparent; color: var(--dim); padding: 6px 12px; border-radius: 11px; font-size: 14px; font-weight: 600; transition: background .15s, color .15s; }
.seg button.on { background: var(--grad); color: #fff; box-shadow: 0 4px 14px -4px rgba(139, 108, 255, .9); }
.tog { background: var(--glass); color: var(--dim); padding: 8px 12px; border-radius: 14px; font-size: 14px; font-weight: 700; border: 1px solid var(--stroke); transition: background .15s; }
.tog[aria-pressed="true"] { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 4px 14px -4px rgba(139, 108, 255, .9); }

main { flex: 1; min-height: 0; padding: 10px 14px 8px; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.tab { display: none; }
.tab.active { display: flex; flex-direction: column; gap: 10px; min-height: 100%; animation: rise .28s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.hint { color: var(--dim); font-size: 12px; line-height: 1.5; margin: 12px 2px; opacity: .85; }

/* 설정 타일 */
.tiles { display: grid; gap: 8px; flex: none; }
.tiles.two { grid-template-columns: 1fr 1fr; }
.tiles.three { grid-template-columns: repeat(3, 1fr); }
.tiles.gen { grid-template-columns: 1fr 1.1fr; }
.tile {
  display: flex; flex-direction: column; justify-content: center; gap: 2px; min-height: 54px; min-width: 0;
  padding: 8px 12px; text-align: left; border-radius: 16px; color: var(--text);
  background: var(--glass); border: 1px solid var(--stroke); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
  transition: background .15s, transform .08s, border-color .15s;
}
.tile small { color: var(--dim); font-size: 11px; font-weight: 700; }
.tile b { font-size: 15px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile:active { transform: scale(.97); background: var(--glass2); }
.tile.on { background: linear-gradient(160deg, rgba(139, 108, 255, .34), rgba(255, 92, 154, .14)); border-color: rgba(139, 108, 255, .65); }
.tile.ld b::after { content: " …"; opacity: .7; }
.volrow { display: flex; align-items: center; gap: 10px; flex: none; padding: 6px 4px; }
.volrow small { color: var(--dim); font-size: 11px; font-weight: 700; }
.volrow input { flex: 1; }
.actions { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; flex: none; }
.actions .ghost { padding: 11px 0; font-size: 12.5px; border-radius: 13px; text-align: center; }
.credit { color: var(--dim); font-size: 11px; line-height: 1.6; opacity: .7; margin: 6px 2px 0; }

/* ---------- 패드 ---------- */
.t { --xr: 91, 140, 255; --x: rgb(91, 140, 255); }
.s { --xr: 52, 211, 160; --x: rgb(52, 211, 160); }
.d { --xr: 255, 154, 77; --x: rgb(255, 154, 77); }
.pad { flex: 1; min-height: 250px; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: repeat(4, minmax(0, 1fr)); gap: 10px; }
.pad button {
  position: relative; overflow: hidden; min-height: 0; border-radius: 22px; color: var(--text);
  background: linear-gradient(160deg, rgba(var(--xr), .32), rgba(var(--xr), .08) 62%, rgba(255, 255, 255, .03));
  border: 1px solid rgba(var(--xr), .4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 12px 24px -14px rgba(var(--xr), .85);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  transition: transform .08s, box-shadow .18s, background .18s;
}
.pad button::after {
  content: ""; position: absolute; left: 22%; right: 22%; bottom: 0; height: 3px; border-radius: 3px 3px 0 0;
  background: var(--x); box-shadow: 0 0 16px 3px rgba(var(--xr), .75);
}
.pad button .nm { font-size: clamp(22px, 4vh, 31px); font-weight: 800; letter-spacing: -.03em; text-shadow: 0 2px 12px rgba(0, 0, 0, .35); }
.pad button .nm.long { font-size: 22px; }
.pad button .rn {
  position: absolute; top: 10px; left: 12px; font-size: 11px; font-weight: 700; color: rgba(255, 255, 255, .8);
  background: rgba(0, 0, 0, .28); padding: 2px 8px; border-radius: 999px;
}
.pad button .kk { position: absolute; top: 10px; right: 12px; font-size: 11px; font-weight: 700; color: var(--dim); opacity: .7; }
@media (hover: none) { .pad button .kk { display: none; } }
.pad button.hit, .pad button:active {
  transform: scale(.955);
  background: linear-gradient(160deg, rgba(var(--xr), .8), rgba(var(--xr), .38));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 0 34px 2px rgba(var(--xr), .7);
}
.pad button.rand { --xr: 255, 92, 154; --x: rgb(255, 92, 154); }
.pad button.rand .nm { font-size: clamp(26px, 4.6vh, 34px); }

/* ---------- 칩 / 버튼 ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button {
  background: var(--glass); padding: 10px 16px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--dim);
  border: 1px solid var(--stroke); transition: background .15s, color .15s, transform .08s;
}
.chips button:active { transform: scale(.96); }
.chips button.on { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 6px 16px -6px rgba(139, 108, 255, .9); }

.big {
  position: relative; overflow: hidden; width: 100%; margin: 0; padding: 14px; border-radius: 18px; flex: none;
  font-size: 17px; font-weight: 800; letter-spacing: -.01em; color: #fff;
  background: var(--grad); box-shadow: 0 14px 30px -12px rgba(255, 92, 154, .75), inset 0 1px 0 rgba(255, 255, 255, .35);
  transition: transform .1s, box-shadow .2s;
}
.big::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .28) 50%, transparent 70%); transform: translateX(-120%); }
.big:active { transform: scale(.98); }
.big:active::after { transform: translateX(120%); transition: transform .5s; }

.row { display: flex; flex-wrap: wrap; align-items: center; margin-top: 14px; gap: 8px; }
.grow { flex: 1; }
.ghost { background: var(--glass); border: 1px solid var(--stroke); padding: 10px 16px; border-radius: 14px; font-size: 14px; font-weight: 600; transition: background .15s, transform .08s; }
.ghost:active { background: var(--glass2); transform: scale(.97); }
.ghost.sm { padding: 6px 11px; font-size: 12px; border-radius: 11px; }
.ghost:disabled, .tog:disabled { opacity: .35; }

/* ---------- 진행 카드 ---------- */
.cards { flex: 1; min-height: 96px; max-height: 340px; display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 1fr; gap: 8px; }
.tiles.gen .big { height: auto; }
.card {
  position: relative; overflow: hidden; text-align: center; padding: 6px 4px 8px; border-radius: 18px; display: flex; flex-direction: column; justify-content: center;
  background: linear-gradient(170deg, rgba(var(--xr), .22), rgba(255, 255, 255, .04));
  border: 1px solid rgba(var(--xr), .32);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12);
  transition: transform .15s, box-shadow .2s, background .2s;
}
.card::after { content: ""; position: absolute; left: 25%; right: 25%; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--x); box-shadow: 0 0 12px 2px rgba(var(--xr), .7); }
.card .nm { font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.card .nm.long { font-size: 15px; }
.card .rn { font-size: 11px; font-weight: 600; color: var(--dim); margin-top: 3px; }
.card.cur {
  background: var(--grad); border-color: transparent; transform: translateY(-4px) scale(1.03);
  box-shadow: 0 16px 28px -10px rgba(255, 92, 154, .8), inset 0 1px 0 rgba(255, 255, 255, .4);
}
.card.cur .rn { color: #fff; opacity: .85; }
.card.cur::after { display: none; }
.card.hit { transform: scale(.95); }
.card.sel { box-shadow: 0 0 0 2px #fff, 0 10px 24px -10px rgba(var(--xr), .9); }
.card .lk { display: none; position: absolute; top: 4px; right: 5px; font-size: 10px; }
.card.lock .lk { display: inline; }

.saved { display: grid; gap: 8px; }
.saved .item { display: flex; align-items: center; gap: 8px; background: var(--glass); border: 1px solid var(--stroke); border-radius: 16px; padding: 4px 4px 4px 16px; }
.saved .item .ld { flex: 1; text-align: left; background: transparent; padding: 10px 0; font-size: 15px; font-weight: 700; }
.saved .item .ld small { display: block; color: var(--dim); font-size: 11px; font-weight: 500; margin-top: 3px; }
.saved .item .rm { background: transparent; color: var(--dim); padding: 12px 14px; font-size: 16px; }
.saved .empty { color: var(--dim); font-size: 13px; padding: 4px 2px; }

input[type=range] { width: 100%; accent-color: var(--accent); height: 32px; }

/* ---------- 재생바 / 탭바 (아래 고정, 떠 있는 유리 카드) ---------- */
.dock { flex: none; padding: 0 12px calc(8px + var(--safe-b)); display: flex; flex-direction: column; gap: 8px; z-index: 10; }
.transport, .tabbar {
  background: rgba(24, 21, 40, .72); border: 1px solid var(--stroke);
  -webkit-backdrop-filter: blur(24px) saturate(1.6); backdrop-filter: blur(24px) saturate(1.6);
  box-shadow: 0 18px 40px -16px rgba(0, 0, 0, .8), inset 0 1px 0 rgba(255, 255, 255, .08);
}
.transport { border-radius: 24px; display: flex; align-items: center; gap: 12px; padding: 8px 12px 8px 8px; }
.play {
  position: relative; width: 52px; height: 52px; border-radius: 50%; font-size: 20px; flex: none; color: #fff;
  background: var(--grad); box-shadow: 0 8px 22px -6px rgba(255, 92, 154, .85), inset 0 1px 0 rgba(255, 255, 255, .4);
  transition: transform .1s;
}
.play:active { transform: scale(.94); }
.transport.on .play::before {
  content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid rgba(255, 92, 154, .7);
  animation: pulse 1.2s ease-out infinite;
}
@keyframes pulse { from { transform: scale(.9); opacity: 1; } to { transform: scale(1.25); opacity: 0; } }
.now { flex: 1; min-width: 0; }
#nowName { font-size: 24px; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
#nowRn { font-size: 12px; font-weight: 600; color: var(--dim); min-height: 15px; margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bpm { display: flex; align-items: center; gap: 2px; }
.bpm button { width: 36px; height: 36px; border-radius: 12px; background: var(--glass); border: 1px solid var(--stroke); font-size: 20px; }
.bpm button:active { background: var(--glass2); }
.bpm div { text-align: center; min-width: 40px; }
.bpm b { display: block; font-size: 18px; font-weight: 800; }
.bpm small { color: var(--dim); font-size: 9px; font-weight: 700; letter-spacing: .08em; }

.tabbar { height: 56px; border-radius: 24px; display: flex; padding: 5px; gap: 4px; }
.tabbar button {
  position: relative; flex: 1; background: transparent; color: var(--dim); border-radius: 19px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  transition: color .2s, background .2s;
}
.tabbar svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tabbar svg .fill { fill: currentColor; stroke: none; }
.tabbar button span { font-size: 11px; font-weight: 700; }
.tabbar button.on { color: #fff; background: linear-gradient(160deg, rgba(139, 108, 255, .42), rgba(255, 92, 154, .22)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18); }

/* 코드 편집 패널 (재생바 위에 떠서, 위쪽 카드는 그대로 보임) */
.editor {
  position: fixed; left: 50%; transform: translateX(-50%); width: calc(100% - 24px); max-width: 536px;
  bottom: calc(var(--dock-h, 150px) + 6px); z-index: 20; padding: 10px 12px; border-radius: 22px;
  background: rgba(26, 22, 44, .96); border: 1px solid var(--stroke);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
  box-shadow: 0 -10px 40px -10px rgba(0, 0, 0, .7);
}
.editor[hidden] { display: none; }
.edhead { display: flex; align-items: center; gap: 6px; }
.edhead b { font-size: 14px; }
.edpick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; }
.edpick button { background: var(--glass); border-radius: 13px; padding: 8px 4px; border: 1px solid transparent; transition: background .15s; }
.edpick button:active { background: var(--glass2); }
.edpick button.on { border-color: var(--accent); background: rgba(139, 108, 255, .28); }
.edpick button.rec .nm { color: #ffd77a; }
.edpick .nm { display: block; font-size: 16px; font-weight: 800; }
.edpick .rn { display: block; font-size: 11px; color: var(--dim); margin-top: 1px; }
.editor .hint { margin: 8px 2px 0; font-size: 11px; }
@media (max-height: 720px) { .editor .hint { display: none; } }

/* 시트 (고르기 팝업) */
.sheet { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.sheet[hidden] { display: none; }
.sheet-bg { position: absolute; inset: 0; background: rgba(5, 4, 12, .55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sheet-panel {
  position: relative; width: 100%; max-width: 560px; max-height: 80dvh; overflow-y: auto;
  padding: 14px 14px calc(16px + var(--safe-b)); border-radius: 26px 26px 0 0;
  background: rgba(26, 22, 44, .97); border: 1px solid var(--stroke); box-shadow: 0 -20px 50px -10px rgba(0, 0, 0, .7);
  animation: sheetUp .22s ease-out;
}
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.sheet-head b { font-size: 14px; }
.sheet-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.sheet-grid button { padding: 14px 6px; border-radius: 15px; background: var(--glass); border: 1px solid var(--stroke); font-weight: 700; font-size: 14px; color: var(--text); transition: transform .08s; }
.sheet-grid button:active { transform: scale(.96); }
.sheet-grid button.on { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 6px 16px -6px rgba(139, 108, 255, .9); }
.sheet-grid button.ld::after { content: " …"; opacity: .7; }

/* ---------- 건반 / 기타 ---------- */
.viz { flex: none; }
.kbd {
  position: relative; height: 72px; border-radius: 16px; overflow: hidden; background: #05040b;
  box-shadow: inset 0 0 0 1px var(--stroke), 0 16px 30px -16px rgba(139, 108, 255, .55);
}
.kbd .k { position: absolute; top: 0; }
.kbd .w { height: 100%; background: linear-gradient(#fff, #d6d1ec); border-right: 1px solid #1a1730; transition: background .12s; border-radius: 0 0 5px 5px; }
.kbd .b { height: 60%; z-index: 2; background: linear-gradient(#2d2948, #0c0a17); border-radius: 0 0 4px 4px; box-shadow: 0 3px 6px rgba(0, 0, 0, .6); transition: background .12s; }
.kbd .w.on { background: linear-gradient(#cdbdff, #8b6cff); box-shadow: inset 0 -10px 18px rgba(139, 108, 255, .6); }
.kbd .b.on { background: linear-gradient(#ff8ab8, #ff5c9a); }
.kbd .w.nx { background: linear-gradient(#ffd0e4, #f4a3c9); }
.kbd .b.nx { background: linear-gradient(#d4609a, #c2457f); }
.kbd .k.sc::after { content: ""; position: absolute; left: 50%; bottom: 7px; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: var(--accent); }
.kbd .b.sc::after { background: #cbbcff; bottom: 8px; }
.kbd .w.on.sc::after { background: #fff; }
.kbd .k.tn::after { width: 9px; height: 9px; margin-left: -4.5px; background: var(--accent2) !important; box-shadow: 0 0 8px var(--accent2); }

.viz .gbox { display: none; }
.viz.mode-g .kbd { display: none; }
.viz.mode-g .gbox { display: flex; }
.gbox {
  gap: 4px; justify-content: center; padding: 10px 6px 6px; border-radius: 18px;
  background: var(--glass); border: 1px solid var(--stroke);
}
.gbox .g { flex: 1 1 0; min-width: 0; max-width: 270px; }
.gbox svg { width: 100%; height: auto; display: block; }
.gbox .nxt { opacity: .62; }
.gbox .nxt .ti { fill: var(--accent2); }
.gbox .ln { stroke: #7a74a6; stroke-width: 1.2; }
.gbox .nut { stroke: #efeaff; stroke-width: 4; }
.gbox .dot { fill: #efeaff; }
.gbox .dot.root { fill: var(--accent2); stroke: #fff; stroke-width: 1.2; }
.gbox .op.root { stroke: var(--accent2); stroke-width: 2.4; }
.gbox .op { fill: none; stroke: #efeaff; stroke-width: 1.5; }
.gbox text { fill: var(--dim); font-size: 11px; text-anchor: middle; font-family: inherit; }
.gbox .ti { fill: var(--text); font-size: 15px; font-weight: 800; }
.gbox .mk { font-size: 13px; }
.gbox .fr { font-size: 10px; }

/* ---------- 연습 ---------- */
.prbox {
  position: relative; overflow: hidden; flex: 1; min-height: 190px; display: flex; flex-direction: column; justify-content: center; padding: 14px 12px; text-align: center; border-radius: 28px;
  background: linear-gradient(160deg, rgba(139, 108, 255, .22), rgba(255, 92, 154, .08) 60%, rgba(255, 255, 255, .03));
  border: 1px solid var(--stroke); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 24px 40px -24px rgba(139, 108, 255, .7);
}
.prrn { color: var(--dim); font-size: 13px; font-weight: 700; min-height: 16px; }
.prnow {
  font-size: clamp(56px, 11vh, 84px); font-weight: 800; line-height: 1.08; letter-spacing: -.04em;
  background: linear-gradient(135deg, #fff, #cdbdff 55%, #ff9ec9); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.prnext { font-size: clamp(18px, 2.6vh, 22px); color: #ff8ab8; margin-top: 6px; font-weight: 700; }
.beats { display: flex; gap: 10px; justify-content: center; margin-top: 18px; }
.beats i { width: 16px; height: 16px; border-radius: 50%; background: var(--glass2); transition: background .06s, box-shadow .06s, transform .06s; }
.beats i:first-child { width: 20px; height: 20px; margin-top: -2px; }
.beats i.on { background: var(--accent2); box-shadow: 0 0 14px 2px rgba(255, 92, 154, .8); transform: scale(1.1); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.chips button.ld::after { content: " …"; opacity: .7; }
.credit { color: var(--dim); font-size: 11px; line-height: 1.5; opacity: .7; margin-top: 28px; }

#tab-rhythm .tile b { font-size: 16px; }
.volrow input { min-width: 0; }
.volrow .ghost { flex: none; }

/* 리듬 탭 */
.tiles.rhythm { grid-template-columns: repeat(6, 1fr); flex: 1; grid-auto-rows: minmax(48px, 1fr); max-height: 380px; }
.tile.s2 { grid-column: span 2; } .tile.s3 { grid-column: span 3; }
.tiles.rhythm .tile b { font-size: 15px; }
.tiles.rhythm .tile { padding: 6px 10px; }
#tab-rhythm .tiles { max-height: 380px; }
.mix { display: grid; gap: 10px; }
.mix label { display: grid; grid-template-columns: 64px 1fr; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; color: var(--dim); }
.mix .hint, .sheet-panel .hint { margin: 14px 2px 0; }

/* 박자 LED */
.leds { display: flex; gap: 5px; margin-top: 4px; height: 7px; }
.leds i { width: 7px; height: 7px; border-radius: 50%; background: var(--glass2); transition: background .06s, box-shadow .06s; }
.leds i:first-child { width: 9px; margin-top: -1px; height: 9px; }
.leds i.on { background: var(--accent2); box-shadow: 0 0 8px 1px rgba(255, 92, 154, .9); }

/* BPM 직접 입력 */
.bpmval {
  width: 52px; text-align: center; padding: 0; font: inherit; font-size: 18px; font-weight: 800; color: var(--text);
  background: transparent; border: 0; border-bottom: 1px dashed rgba(255, 255, 255, .25); border-radius: 0; outline: none;
  -webkit-user-select: text; user-select: text;
}
.bpmval:focus { border-bottom: 1px solid var(--accent2); background: rgba(255, 255, 255, .06); }
.bpmval::placeholder { color: var(--dim); opacity: .8; }
.bpm > div { display: flex; flex-direction: column; align-items: center; }

/* 모든 탭에서 보이는 빠른 설정 줄 */
.strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 8px; }
.tile.chip { min-height: 38px; padding: 3px 10px; border-radius: 13px; gap: 0; }
.tile.chip small { font-size: 10px; line-height: 1.2; }
.tile.chip b { font-size: 13px; line-height: 1.25; }
.top { padding-bottom: 7px; }
.pad { min-height: 220px; }
.tiles.two .tile { min-height: 46px; }
