:root {
  color-scheme: dark;
  --bg: #070a0f;
  --bg-soft: #0b1119;
  --panel: #101720;
  --panel-2: #0d131b;
  --panel-3: #141d28;
  --line: rgba(255, 255, 255, 0.095);
  --line-strong: rgba(255, 255, 255, 0.18);
  --text: #f3f7fb;
  --muted: #8d99a7;
  --blue: #2f9bff;
  --blue-soft: rgba(47, 155, 255, 0.18);
  --orange: #ff8c15;
  --orange-soft: rgba(255, 140, 21, 0.18);
  --green: #63d454;
  --green-soft: rgba(99, 212, 84, 0.18);
  --red: #ff4354;
  --red-soft: rgba(255, 67, 84, 0.18);
  --yellow: #ffd54e;
  --shadow: 0 18px 70px rgba(0, 0, 0, 0.46);
  --radius-lg: 16px;
  --radius-md: 10px;
  --radius-sm: 7px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: radial-gradient(circle at top left, #16202b 0, var(--bg) 43%, #040507 100%);
  color: var(--text);
  font-family: var(--font);
}

body {
  overflow-x: hidden;
}

button, input, select, textarea {
  font: inherit;
}

button {
  color: var(--text);
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015));
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: transform 100ms ease, border-color 120ms ease, background 120ms ease, box-shadow 120ms ease;
}

button:hover {
  border-color: rgba(255, 255, 255, 0.32);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.025));
}

button:active {
  transform: translateY(1px);
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

input[type="range"] {
  accent-color: var(--blue);
  width: 100%;
}

.app-shell {
  min-height: 100vh;
  padding: 18px;
}

.topbar {
  min-height: 70px;
  display: grid;
  grid-template-columns: auto minmax(210px, 310px) 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 12px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(15, 23, 32, 0.96), rgba(8, 12, 18, 0.96));
  box-shadow: var(--shadow);
  position: sticky;
  top: 12px;
  z-index: 20;
  backdrop-filter: blur(22px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.brand-mark span {
  width: 4px;
  border-radius: 999px;
  background: var(--blue);
  box-shadow: 0 0 18px var(--blue);
}
.brand-mark span:nth-child(1) { height: 16px; opacity: 0.55; }
.brand-mark span:nth-child(2) { height: 28px; }
.brand-mark span:nth-child(3) { height: 20px; opacity: 0.75; }
.brand-mark span:nth-child(4) { height: 24px; opacity: 0.9; }

.brand-copy {
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.brand-copy strong { font-size: 18px; letter-spacing: 0.01em; }
.brand-copy small { color: var(--muted); font-size: 12px; }

.session-select {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  border-radius: 8px;
  min-height: 42px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #dce6f0;
  font-weight: 700;
  font-size: 14px;
}

.status-strip {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.icon-status,
.record-pill,
.ghost-icon {
  min-height: 42px;
  padding: 0 12px;
}

.icon-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}
.icon-status.active { color: var(--text); }
.icon-status i {
  width: 8px;
  height: 8px;
  display: inline-block;
  border-radius: 99px;
  background: var(--green);
  box-shadow: 0 0 12px var(--green);
}

.record-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border-color: rgba(255, 67, 84, 0.24);
}
.record-pill span {
  width: 13px;
  height: 13px;
  border-radius: 99px;
  background: var(--red);
  box-shadow: 0 0 16px var(--red);
  opacity: 0.85;
}
.record-pill:not(.recording) span { opacity: 0.38; box-shadow: none; }
.record-pill b { color: var(--red); letter-spacing: 0.06em; }
.record-pill em { color: #8fd6ff; font-style: normal; font-size: 13px; }
.record-pill time { color: #d7e0eb; min-width: 74px; text-align: right; font-variant-numeric: tabular-nums; }

.top-actions {
  display: flex;
  gap: 8px;
}
.ghost-icon {
  min-width: 45px;
  font-size: 19px;
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(250px, 310px) minmax(360px, 1fr);
  gap: 14px;
  margin-top: 14px;
  align-items: stretch;
}

.deck,
.mixer,
.app-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015)),
    rgba(9, 14, 20, 0.92);
  box-shadow: 0 12px 38px rgba(0, 0, 0, 0.24);
}

.deck {
  padding: 14px;
  min-height: 510px;
  position: relative;
  overflow: hidden;
}
.deck::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.45;
  background: radial-gradient(circle at 44% 55%, var(--blue-soft), transparent 33%);
}
.deck-b::before { background: radial-gradient(circle at 44% 55%, var(--orange-soft), transparent 33%); }
.deck > * { position: relative; z-index: 1; }

.deck-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
}

.deck-badge {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  font-size: 22px;
  font-weight: 800;
  border-radius: 6px;
  color: white;
  background: linear-gradient(180deg, #238bff, #0d5bb6);
  box-shadow: 0 0 22px rgba(47, 155, 255, 0.36);
}
.deck-b .deck-badge { background: linear-gradient(180deg, #ff9e22, #bf5c06); box-shadow: 0 0 22px rgba(255, 140, 21, 0.34); }

.track-title-block h2 {
  font-size: 20px;
  line-height: 1.1;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.track-title-block p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 14px;
}
.deck-meta {
  display: grid;
  grid-template-columns: auto auto;
  gap: 1px 8px;
  align-items: baseline;
  text-align: right;
}
.deck-meta strong { font-size: 19px; font-variant-numeric: tabular-nums; }
.deck-meta span { font-size: 13px; color: var(--muted); }
.deck-meta em { grid-column: 2; font-style: normal; color: var(--blue); font-size: 18px; font-weight: 800; }
.deck-b .deck-meta em { color: var(--orange); }

.wave-wrap {
  height: 86px;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(0,0,0,.08));
  position: relative;
  overflow: hidden;
}
.waveform {
  width: 100%;
  height: 100%;
  display: block;
}
.playhead-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  background: var(--red);
  box-shadow: 0 0 8px var(--red);
}
.time-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  margin: 8px 0 10px;
  color: #e8f0fa;
  font-variant-numeric: tabular-nums;
}
.time-row time { font-size: 14px; }
.progress-rail {
  height: 9px;
  border-radius: 99px;
  background: #05080d;
  border: 1px solid var(--line);
  position: relative;
  cursor: pointer;
}
.progress-rail span {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  border-radius: inherit;
  background: var(--blue);
}
.deck-b .progress-rail span { background: var(--orange); }

.deck-body {
  display: grid;
  grid-template-columns: 84px 1fr 130px;
  gap: 14px;
  align-items: stretch;
}

.tempo-column {
  display: grid;
  grid-template-rows: 38px auto auto 32px 1fr;
  align-items: center;
  justify-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 8px;
  background: rgba(4, 7, 10, 0.4);
}
.sync-button {
  width: 100%;
  color: #8fd0ff;
  border-color: rgba(47,155,255,.42);
  font-weight: 800;
  letter-spacing: 0.07em;
}
.deck-b .sync-button { color: #ffc07c; border-color: rgba(255,140,21,.45); }
.tempo-column strong { font-size: 14px; font-variant-numeric: tabular-nums; }
.tempo-column span { font-size: 12px; color: var(--muted); }
.range-button { width: 54px; height: 30px; }
.vertical-slider {
  height: 150px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  place-items: center;
  color: var(--muted);
}
.vertical-slider input {
  width: 140px;
  transform: rotate(-90deg);
}

.platter-zone {
  display: grid;
  place-items: center;
  gap: 14px;
}
.platter {
  width: min(255px, 44vw);
  aspect-ratio: 1;
  border-radius: 50%;
  position: relative;
  display: grid;
  place-items: center;
  cursor: grab;
  background:
    repeating-radial-gradient(circle, rgba(255,255,255,.18) 0 1px, rgba(0,0,0,0) 1px 5px),
    radial-gradient(circle at 50% 50%, #333b44 0 6%, #06090d 7% 60%, #0f1620 63%, #05070a 72%);
  border: 1px solid var(--line-strong);
  box-shadow: inset 0 0 0 8px rgba(0, 0, 0, 0.34), 0 0 0 2px rgba(47,155,255,.18), 0 0 25px rgba(47,155,255,.2);
  touch-action: none;
}
.deck-b .platter { box-shadow: inset 0 0 0 8px rgba(0, 0, 0, 0.34), 0 0 0 2px rgba(255,140,21,.22), 0 0 25px rgba(255,140,21,.22); }
.platter:active { cursor: grabbing; }
.platter-ring {
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  border: 2px solid var(--blue);
  opacity: 0.85;
}
.deck-b .platter-ring { border-color: var(--orange); }
.platter-core {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: radial-gradient(circle, #eef4fa 0 7%, #222a33 8% 20%, #bfc9d2 21% 28%, #0a0f15 29% 100%);
  border: 1px solid rgba(255,255,255,.22);
  box-shadow: 0 0 18px rgba(255,255,255,.18);
}
.transport-row {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr 54px;
  gap: 8px;
}
.transport-row button {
  height: 54px;
  font-weight: 900;
  font-size: 17px;
}
.play-button {
  background: linear-gradient(180deg, rgba(91, 213, 73, 0.72), rgba(34, 120, 29, 0.82));
  border-color: rgba(99, 212, 84, 0.72);
  box-shadow: 0 0 22px rgba(99,212,84,.16);
}
.play-button.playing { background: linear-gradient(180deg, rgba(99,212,84,.92), rgba(43,147,38,.9)); }
.cue-button { font-size: 16px; }
.set-button { font-size: 13px !important; color: var(--muted); }

.deck-tools {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 16px;
}
.loop-box,
.hotcue-box {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px;
  background: rgba(5, 8, 12, 0.42);
}
.loop-box label,
.hotcue-box label {
  display: block;
  text-align: center;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--muted);
  margin-bottom: 8px;
}
.loop-size,
.loop-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 5px;
  align-items: center;
  text-align: center;
}
.loop-row { grid-template-columns: 1fr 1fr; margin-top: 7px; }
.loop-size button,
.loop-row button,
.loop-toggle { height: 35px; }
.loop-toggle { margin-top: 7px; width: 100%; color: var(--yellow); }
.loop-toggle.active { border-color: var(--yellow); background: rgba(255,213,78,.12); }
.hotcue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.hotcue-grid button {
  height: 48px;
  color: #8fd0ff;
  border-color: rgba(47,155,255,.48);
  font-size: 18px;
  font-weight: 800;
}
.deck-b .hotcue-grid button { color: #ffc07c; border-color: rgba(255,140,21,.48); }
.hotcue-grid button.set { background: var(--blue-soft); box-shadow: inset 0 0 0 1px rgba(47,155,255,.32); }
.deck-b .hotcue-grid button.set { background: var(--orange-soft); box-shadow: inset 0 0 0 1px rgba(255,140,21,.32); }

.mixer {
  padding: 12px;
  display: grid;
  grid-template-columns: 1fr 1.08fr 1fr;
  gap: 10px;
  min-height: 510px;
}
.channel-strip,
.master-strip {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(4, 7, 11, 0.48);
  padding: 10px;
  display: grid;
  gap: 9px;
  align-content: start;
}
.channel-strip h3,
.master-strip h3 {
  margin: 0 0 4px;
  text-align: center;
  font-size: 14px;
  letter-spacing: .05em;
}
.channel-strip label,
.master-strip label {
  display: grid;
  gap: 2px;
  font-size: 10px;
  color: var(--muted);
  text-align: center;
  letter-spacing: .06em;
}
.channel-strip input[type="range"] {
  height: 16px;
}
.channel-cue {
  height: 34px;
  font-weight: 900;
}
.deck-a-accent { color: #8fd0ff; border-color: rgba(47,155,255,.42); }
.deck-b-accent { color: #ffc07c; border-color: rgba(255,140,21,.42); }
.channel-cue.active.deck-a-accent { background: var(--blue-soft); box-shadow: 0 0 18px rgba(47,155,255,.18); }
.channel-cue.active.deck-b-accent { background: var(--orange-soft); box-shadow: 0 0 18px rgba(255,140,21,.16); }
.channel-fader {
  margin-top: 4px;
}
.channel-fader input {
  writing-mode: bt-lr;
  appearance: slider-vertical;
  height: 90px;
  margin: 4px auto 0;
}
.master-knob { margin-top: 4px; }
.meter-shell {
  height: 245px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: radial-gradient(circle at center, rgba(255,255,255,.05), rgba(0,0,0,.23));
  border: 1px solid var(--line);
}
#masterMeter {
  height: 220px;
  width: 64px;
}
.cue-mix-control { margin-top: 5px; }
.headphone-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #d7e7dc;
  font-size: 11px;
  letter-spacing: .08em;
}
.headphone-status span {
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: var(--green);
  box-shadow: 0 0 12px var(--green);
}
.crossfader {
  margin-top: 4px;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  color: var(--blue) !important;
}
.crossfader b { color: var(--orange); }
.crossfader input { grid-column: 1 / -1; }

.app-panel {
  min-height: 220px;
  padding: 12px;
}
.library-panel {
  grid-column: 1 / span 2;
  display: grid;
  grid-template-columns: 150px 1fr;
  padding: 0;
  overflow: hidden;
}
.side-nav {
  border-right: 1px solid var(--line);
  padding: 12px;
  display: grid;
  align-content: start;
  gap: 8px;
  background: rgba(0, 0, 0, 0.12);
}
.side-nav button {
  text-align: left;
  height: 39px;
  border: none;
  background: transparent;
  color: var(--muted);
}
.side-nav button.active {
  color: #8fd0ff;
  background: rgba(47,155,255,.1);
}
.library-main {
  min-width: 0;
  display: grid;
  grid-template-rows: auto 1fr;
}
.panel-header {
  display: grid;
  grid-template-columns: minmax(150px, auto) auto minmax(180px, 300px) auto auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}
.panel-header strong { font-size: 18px; margin-right: 12px; }
.panel-header span { color: var(--muted); font-size: 14px; }
.panel-header em { color: var(--muted); font-style: normal; text-align: right; }
.import-button {
  display: inline-flex;
  height: 37px;
  padding: 0 14px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(47,155,255,.12);
  color: #9bd5ff;
  border: 1px solid rgba(47,155,255,.26);
  font-weight: 800;
  cursor: pointer;
}
.search {
  width: 100%;
  height: 38px;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0,0,0,.22);
  padding: 0 12px;
  outline: none;
}
.danger-small {
  height: 37px;
  color: #ff94a0;
  border-color: rgba(255,67,84,.26);
}
.table-wrap {
  max-height: 225px;
  overflow: auto;
}
.track-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.track-table th,
.track-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255,255,255,.055);
  white-space: nowrap;
}
.track-table th {
  position: sticky;
  top: 0;
  background: #0d141c;
  color: var(--muted);
  text-align: left;
  z-index: 2;
}
.track-table tr:hover,
.track-table tr.selected {
  background: rgba(47,155,255,.13);
}
.load-cell {
  display: flex;
  gap: 6px;
}
.load-cell button {
  min-width: 38px;
  height: 30px;
}
.load-cell button[data-load="A"] { color: #8fd0ff; }
.load-cell button[data-load="B"] { color: #ffc07c; }

.panel-title {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  font-size: 14px;
}
.panel-title span {
  width: 12px;
  height: 12px;
  border-radius: 99px;
}
.panel-title.red { color: var(--red); }
.panel-title.red span { background: var(--red); box-shadow: 0 0 14px var(--red); }
.panel-title.green { color: #bff5b8; }
.panel-title.green span { background: var(--green); box-shadow: 0 0 14px var(--green); }
.recording-panel h3,
.cue-panel h3 { margin: 11px 0 4px; font-size: 16px; }
.recording-panel p,
.cue-panel p { margin: 0 0 12px; color: var(--muted); font-size: 13px; line-height: 1.35; }
.recording-panel canvas {
  width: 100%;
  height: 76px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0,0,0,.24);
}
.record-controls {
  display: grid;
  grid-template-columns: 76px 1fr 48px;
  gap: 12px;
  align-items: center;
  margin-top: 10px;
}
.big-rec {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  border-color: rgba(255,67,84,.5);
  background: radial-gradient(circle, rgba(255,67,84,.95) 0 18%, rgba(255,67,84,.24) 19% 55%, rgba(0,0,0,.2) 56% 100%);
  box-shadow: 0 0 28px rgba(255,67,84,.22);
}
.big-rec.recording { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 34px rgba(255,67,84,.5); } }
.record-controls time { display: block; font-size: 18px; font-variant-numeric: tabular-nums; }
.record-controls small { color: var(--muted); }
.stop-button { height: 48px; }
.recordings-list {
  display: grid;
  gap: 6px;
  margin-top: 10px;
  max-height: 95px;
  overflow: auto;
}
.recording-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0,0,0,.17);
}
.recording-item a { color: #9bd5ff; text-decoration: none; }

.cue-diagram {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
  background: rgba(0,0,0,.2);
  display: grid;
  gap: 10px;
}
.diagram-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}
.diagram-row i { font-style: normal; font-size: 24px; }
.blue { color: var(--blue); }
.orange { color: var(--orange); }
.red-text { color: var(--red); }
.diagram-divider {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.hint-box {
  display: grid;
  gap: 3px;
  margin-top: 12px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(99,212,84,.08);
  border: 1px solid rgba(99,212,84,.18);
}
.hint-box strong { font-size: 13px; }
.hint-box span { font-size: 12px; color: var(--muted); }

.mobile-tabs {
  display: none;
}
.toast-region {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 99;
  display: grid;
  gap: 8px;
}
.toast {
  max-width: 360px;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(12, 19, 27, 0.96);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  color: #dbe8f4;
}

@media (max-width: 1180px) {
  .topbar {
    grid-template-columns: 1fr auto auto;
  }
  .session-select { display: none; }
  .main-grid {
    grid-template-columns: 1fr;
  }
  .mixer { order: 2; min-height: auto; }
  .deck-a { order: 1; }
  .deck-b { order: 3; }
  .library-panel { grid-column: auto; order: 4; }
  .recording-panel { order: 5; }
  .cue-panel { order: 6; }
}

@media (max-width: 760px) {
  .app-shell {
    padding: 10px 10px 88px;
  }
  .topbar {
    min-height: 58px;
    grid-template-columns: 1fr auto;
    gap: 8px;
    padding: 10px 12px;
    top: 6px;
  }
  .brand { min-width: 0; }
  .brand-mark { width: 25px; }
  .brand-copy strong { font-size: 15px; }
  .brand-copy small { display: none; }
  .top-actions { display: none; }
  .record-pill { min-width: 42px; padding: 0 12px; }
  .main-grid {
    gap: 10px;
    margin-top: 10px;
  }
  .deck {
    min-height: auto;
    padding: 10px;
  }
  .deck-header { gap: 9px; }
  .deck-badge { width: 40px; height: 34px; font-size: 16px; }
  .track-title-block h2 { font-size: 15px; }
  .track-title-block p { font-size: 12px; }
  .deck-meta strong { font-size: 15px; }
  .wave-wrap { height: 76px; }
  .deck-body {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .tempo-column {
    grid-template-columns: 80px 70px 55px 1fr;
    grid-template-rows: auto;
  }
  .range-button { display: none; }
  .vertical-slider {
    height: auto;
    grid-template-columns: auto 1fr auto;
    grid-template-rows: auto;
    width: 100%;
  }
  .vertical-slider input {
    transform: none;
    width: 100%;
  }
  .platter {
    display: none;
  }
  .transport-row { grid-template-columns: 1fr 1.3fr 0.8fr; }
  .deck-tools {
    grid-template-columns: 1fr;
  }
  .hotcue-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .mixer {
    grid-template-columns: 1fr;
  }
  .channel-strip {
    grid-template-columns: repeat(4, 1fr);
  }
  .channel-strip h3 { grid-column: 1 / -1; }
  .channel-strip .channel-cue,
  .channel-strip .channel-fader { grid-column: span 2; }
  .channel-fader input {
    appearance: auto;
    writing-mode: horizontal-tb;
    height: auto;
    width: 100%;
  }
  .master-strip {
    grid-template-columns: 1fr 1fr;
  }
  .master-strip h3,
  .meter-shell,
  .crossfader { grid-column: 1 / -1; }
  .meter-shell { height: 90px; }
  #masterMeter { width: 100%; height: 70px; }
  .library-panel {
    grid-template-columns: 1fr;
  }
  .side-nav { display: none; }
  .panel-header {
    grid-template-columns: 1fr auto;
  }
  .panel-header .search,
  .panel-header em,
  .danger-small { grid-column: 1 / -1; }
  .table-wrap { max-height: 280px; }
  .track-table th:nth-child(3),
  .track-table th:nth-child(5),
  .track-table th:nth-child(6),
  .track-table td:nth-child(3),
  .track-table td:nth-child(5),
  .track-table td:nth-child(6) { display: none; }
  .mobile-tabs {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    padding: 8px;
    border: 1px solid var(--line-strong);
    border-radius: 16px;
    background: rgba(8, 12, 18, 0.94);
    backdrop-filter: blur(20px);
    z-index: 80;
    box-shadow: var(--shadow);
  }
  .mobile-tabs button {
    height: 44px;
    font-weight: 900;
  }
  .mobile-tabs button.active:first-child,
  .mobile-tabs button[data-mobile-tab="A"] { color: #9bd5ff; }
  .mobile-tabs button[data-mobile-tab="B"] { color: #ffc07c; }
  .mobile-focus-a .deck-b,
  .mobile-focus-a .mixer,
  .mobile-focus-b .deck-a,
  .mobile-focus-b .mixer,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b {
    display: none;
  }
}

/* v1.1 spec pass additions */
.deck { min-height: 590px; }
.deck-body { grid-template-columns: 84px 1fr 158px; }
.deck-tools { grid-template-rows: auto auto auto auto; gap: 8px; }
.loop-extra-row,
.memory-row,
.grid-row,
.deck-options {
  display: grid;
  gap: 5px;
}
.loop-extra-row { grid-template-columns: repeat(3, 1fr); margin-top: 6px; }
.loop-extra-row:last-child { grid-template-columns: 1fr 1fr; }
.loop-extra-row button,
.memory-row button,
.deck-options button,
.grid-row button {
  min-height: 28px;
  font-size: 10px;
  font-weight: 800;
  padding: 0 4px;
}
.hotcue-grid { grid-template-columns: repeat(4, 1fr); gap: 5px; }
.hotcue-grid button {
  height: 34px;
  font-size: 14px;
  border-color: color-mix(in srgb, var(--hotcue-color, currentColor) 60%, rgba(255,255,255,.22));
}
.hotcue-grid button.set {
  background: color-mix(in srgb, var(--hotcue-color, var(--blue)) 22%, rgba(0,0,0,.15));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--hotcue-color, var(--blue)) 55%, transparent);
}
.deck-options {
  grid-template-columns: repeat(3, 1fr);
}
.deck-options button.active {
  border-color: var(--green);
  background: var(--green-soft);
  color: #c9ffc3;
}
.deck.slip-active::after {
  content: "SLIP";
  position: absolute;
  right: 14px;
  top: 14px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--yellow);
  color: #141000;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  z-index: 3;
}
.memory-row { grid-template-columns: repeat(4, 1fr); }
.grid-row { grid-template-columns: 1fr 1fr 44px; }
.grid-row input {
  min-width: 0;
  height: 30px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0,0,0,.26);
  color: var(--text);
  padding: 0 6px;
  font-size: 11px;
}
.channel-meter,
.cue-meter {
  width: 100%;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #05080d;
}
.channel-meter { height: 26px; }
.storage-dashboard {
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  background: rgba(99,212,84,.045);
}
.track-table th:last-child,
.track-table td:last-child { text-align: center; }
.recording-item {
  grid-template-columns: minmax(120px, 1fr) minmax(120px, 220px) auto;
}
.recording-item div {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.recording-item span {
  color: var(--muted);
}
.recording-item audio {
  width: 100%;
  height: 32px;
}
.recording-item button {
  height: 30px;
  color: #ff94a0;
  border-color: rgba(255,67,84,.28);
}
.cue-meter {
  height: 36px;
  margin-bottom: 10px;
}
.keylock-note {
  background: rgba(255,213,78,.07);
  border-color: rgba(255,213,78,.18);
}

@media (max-width: 1180px) {
  .deck { min-height: auto; }
  .deck-body { grid-template-columns: 84px 1fr 185px; }
}

@media (max-width: 760px) {
  .deck-body { grid-template-columns: 1fr; }
  .hotcue-grid { grid-template-columns: repeat(4, 1fr); }
  .deck-tools { grid-template-columns: 1fr; }
  .channel-meter { grid-column: span 2; }
  .grid-row { grid-template-columns: 1fr 1fr auto; }
  .recording-item { grid-template-columns: 1fr; }
  .recording-item audio { width: 100%; }
  .track-table th:nth-child(8),
  .track-table th:nth-child(9),
  .track-table td:nth-child(8),
  .track-table td:nth-child(9) { display: none; }
}

/* v1.2 audit additions */
.zoom-waveform {
  display: block;
  width: 100%;
  height: 42px;
  margin: 6px 0 2px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: #05090e;
}
.library-main.drag-over {
  outline: 2px solid rgba(92, 200, 255, 0.8);
  outline-offset: -6px;
  background: linear-gradient(180deg, rgba(47, 155, 255, 0.12), rgba(5, 8, 13, 0.08));
}
.drop-hint {
  margin: 8px 0 10px;
  padding: 8px 10px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  color: rgba(235, 243, 255, 0.66);
  font-size: 12px;
}
.xfade-assign,
.cue-level-control {
  display: grid;
  gap: 5px;
  font-size: 10px;
  letter-spacing: 0.06em;
  color: rgba(235, 243, 255, 0.66);
}
.xfade-assign select {
  width: 100%;
  min-height: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 7px;
  color: #eef6ff;
  background: #0b1119;
}
#recordClipCount {
  display: block;
  margin-top: 3px;
  color: rgba(255, 213, 78, 0.86);
}
.recording-item button {
  min-width: 46px;
}
@media (max-width: 760px) {
  .zoom-waveform {
    height: 36px;
  }
  .drop-hint {
    display: none;
  }
  .xfade-assign select {
    min-height: 36px;
  }
}
.deck-options [data-action="master-tempo"].active {
  color: #35d660;
  border-color: rgba(53, 214, 96, .8);
  box-shadow: 0 0 16px rgba(53, 214, 96, .18);
}
.deck-options [data-action="master-tempo"].pending {
  color: #ffd54e;
  border-color: rgba(255, 213, 78, .8);
}
.xfade-curve select,
.shortcut-editor input {
  min-height: 28px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  background: #070c13;
  color: #e9f2ff;
  padding: 4px 8px;
}
.shortcut-editor {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  background: rgba(255,255,255,.025);
}
.shortcut-editor > strong {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  letter-spacing: .08em;
  color: #e9f2ff;
}
.shortcut-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
@media (max-width: 760px) {
  .shortcut-grid { grid-template-columns: 1fr; }
}

.text-icon {
  width: auto;
  min-width: 64px;
  padding: 0 10px;
  font-size: 11px;
  letter-spacing: .08em;
}

.small-action,
.label-action {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  border-radius: 10px;
  padding: 9px 11px;
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
}

.label-action {
  display: inline-flex;
  align-items: center;
}

.shortcut-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 8px 0 10px;
}

.shortcut-actions button,
.shortcut-actions label,
.diagnostics-box button {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  border-radius: 9px;
  padding: 7px 10px;
  font-size: 12px;
  cursor: pointer;
}

.diagnostics-box {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.035);
  border-radius: 14px;
  padding: 12px;
  margin-top: 12px;
}

.diagnostics-box pre {
  margin: 10px 0 0;
  white-space: pre-wrap;
  color: var(--muted);
  font: 11px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.hotcue-hint {
  display: block;
  margin-top: 6px;
}

/* v1.6 layout pass: match the desktop and phone mockups more closely. */
:root {
  --chrome: #080d13;
  --panel-glass: rgba(10, 15, 22, 0.96);
  --panel-dark: rgba(6, 10, 15, 0.94);
}

body {
  background:
    radial-gradient(circle at 15% 0%, rgba(47,155,255,.12), transparent 28%),
    radial-gradient(circle at 82% 8%, rgba(255,140,21,.08), transparent 25%),
    linear-gradient(180deg, #111820 0%, #06090e 58%, #030507 100%);
}

.app-shell {
  width: min(100%, 1780px);
  margin: 0 auto;
  padding: 14px;
}

.topbar {
  min-height: 54px;
  grid-template-columns: minmax(215px, 265px) minmax(210px, 285px) 1fr auto;
  gap: 12px;
  padding: 8px 14px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(13, 20, 29, 0.98), rgba(7, 11, 17, 0.98));
  box-shadow: 0 12px 42px rgba(0,0,0,.36);
  top: 8px;
}

.brand-mark { width: 26px; height: 28px; }
.brand-copy strong { font-size: 15px; }
.brand-copy small { font-size: 10px; }
.session-select,
.icon-status,
.record-pill,
.ghost-icon { min-height: 34px; }
.session-select { font-size: 12px; }
.record-pill { gap: 8px; }
.record-pill b { font-size: 12px; }
.record-pill em,
.record-pill time { font-size: 11px; }
.text-icon { min-width: 54px; font-size: 10px; }
.ghost-icon { min-width: 36px; font-size: 15px; }

.main-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
  align-items: start;
}

.deck-a { grid-column: 1 / span 5; grid-row: 1; }
.mixer { grid-column: 6 / span 2; grid-row: 1; }
.deck-b { grid-column: 8 / span 5; grid-row: 1; }
.library-panel { grid-column: 1 / span 7; grid-row: 2; }
.recording-panel { grid-column: 8 / span 2; grid-row: 2; }
.cue-panel { grid-column: 10 / span 3; grid-row: 2; }

.deck,
.mixer,
.app-panel {
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.012)), var(--panel-glass);
  box-shadow: 0 10px 28px rgba(0,0,0,.28);
}

.deck {
  min-height: 0 !important;
  height: 620px;
  padding: 12px;
}
.deck-header { gap: 12px; }
.deck-badge { width: 38px; height: 38px; font-size: 17px; border-radius: 5px; }
.track-title-block h2 { font-size: 16px; }
.track-title-block p { font-size: 12px; }
.deck-meta strong { font-size: 16px; }
.deck-meta span { font-size: 11px; }
.deck-meta em { font-size: 15px; }
.wave-wrap { height: 72px; margin-top: 10px; border-radius: 6px; }
.zoom-waveform { display: none; }
.time-row { margin: 7px 0 9px; gap: 8px; }
.time-row time { font-size: 12px; }
.progress-rail { height: 7px; }

.deck-body {
  grid-template-columns: 76px minmax(220px, 1fr) 142px !important;
  gap: 12px;
  height: 455px;
  min-height: 0;
  align-items: stretch;
}
.tempo-column {
  min-height: 100%;
  grid-template-rows: 32px auto auto 26px 1fr;
  gap: 6px;
  padding: 8px 7px;
  border-radius: 8px;
}
.sync-button { height: 31px; font-size: 12px; }
.tempo-column strong { font-size: 12px; }
.tempo-column span { font-size: 10px; }
.range-button { width: 48px; height: 25px; font-size: 11px; }
.vertical-slider { height: 122px; align-self: end; margin-bottom: 12px; }
.vertical-slider input { width: 120px; }

.platter-zone { align-content: center; gap: 18px; }
.platter {
  width: clamp(230px, 20vw, 285px);
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.38),
    0 0 0 2px rgba(47,155,255,.2),
    0 0 36px rgba(47,155,255,.18),
    0 22px 46px rgba(0,0,0,.32);
}
.deck-b .platter {
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.38),
    0 0 0 2px rgba(255,140,21,.22),
    0 0 36px rgba(255,140,21,.16),
    0 22px 46px rgba(0,0,0,.32);
}
.platter-ring { inset: 11px; }
.platter-core { width: 44px; height: 44px; }
.transport-row { grid-template-columns: 1fr 1fr 42px; gap: 7px; }
.transport-row button { height: 48px; font-size: 14px; }
.set-button { font-size: 10px !important; }

.deck-tools {
  min-height: 0;
  max-height: 100%;
  grid-template-rows: auto auto auto auto;
  gap: 8px;
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-width: thin;
}
.loop-box label,
.hotcue-box label { font-size: 10px; margin-bottom: 6px; }
.loop-size button,
.loop-row button,
.loop-toggle { height: 29px; font-size: 11px; }
.loop-extra-row { grid-template-columns: repeat(3, 1fr); }
.loop-extra-row button { min-height: 23px; font-size: 8px; }
.hotcue-grid { grid-template-columns: repeat(2, 1fr); gap: 6px; }
.hotcue-grid button { height: 35px; font-size: 13px; }
.deck-options { grid-template-columns: repeat(4, 1fr); gap: 5px; }
.deck-options button { min-height: 29px; font-size: 9px; }
.hotcue-hint { display: none; }

.mixer {
  height: 620px;
  min-height: 0;
  padding: 10px;
  gap: 8px;
  grid-template-columns: 1fr 1.08fr 1fr;
}
.channel-strip,
.master-strip { padding: 9px 7px; gap: 7px; border-radius: 8px; }
.channel-strip h3,
.master-strip h3 { font-size: 12px; margin-bottom: 2px; }
.channel-strip label,
.master-strip label { font-size: 9px; }
.channel-strip input[type="range"] { height: 14px; }
.channel-cue { height: 30px; font-size: 11px; }
.channel-meter { height: 22px; }
.channel-fader input { height: 82px; }
.meter-shell { height: 178px; }
#masterMeter { height: 164px; width: 52px; }
.headphone-status { font-size: 9px; }
.xfade-assign select,
.xfade-curve select { min-height: 24px; font-size: 10px; }

.app-panel { min-height: 0; padding: 10px; }
.library-panel {
  height: 260px;
  grid-template-columns: 135px 1fr;
  padding: 0;
}
.side-nav { padding: 10px; gap: 5px; }
.side-nav button { height: 33px; font-size: 12px; }
.panel-header {
  grid-template-columns: minmax(120px, auto) auto auto auto minmax(170px, 280px) auto auto;
  gap: 8px;
  padding: 10px;
}
.panel-header strong { font-size: 15px; }
.panel-header span { font-size: 12px; }
.panel-header em { font-size: 12px; }
.import-button,
.small-action,
.label-action,
.danger-small { height: 31px; padding: 0 10px; font-size: 11px; }
.search { height: 31px; font-size: 12px; }
.storage-dashboard { padding: 7px 10px; font-size: 10px; }
.drop-hint { margin: 7px 10px; padding: 7px 9px; font-size: 10px; }
.table-wrap { max-height: 125px; }
.track-table { font-size: 12px; }
.track-table th,
.track-table td { padding: 7px 9px; }

.recording-panel,
.cue-panel { height: 260px; overflow: hidden; }
.recording-panel .panel-title,
.cue-panel .panel-title { font-size: 12px; }
.recording-panel h3,
.cue-panel h3 { margin: 8px 0 3px; font-size: 13px; }
.recording-panel p,
.cue-panel p { font-size: 11px; margin-bottom: 8px; }
.recording-panel canvas { height: 58px; }
.record-controls { grid-template-columns: 55px 1fr 38px; gap: 8px; margin-top: 8px; }
.big-rec { width: 50px; height: 50px; }
.record-controls time { font-size: 14px; }
.record-controls small { font-size: 10px; }
.stop-button { height: 38px; }
.recordings-list { max-height: 50px; margin-top: 8px; }
.recording-item { grid-template-columns: 1fr auto; font-size: 10px; }
.recording-item audio { display: none; }
.cue-meter { height: 28px; margin-bottom: 7px; }
.cue-diagram { padding: 10px; gap: 7px; }
.diagram-row { gap: 8px; font-size: 12px; }
.diagram-row i { font-size: 20px; }
.diagram-divider { font-size: 10px; }
.hint-box { margin-top: 8px; padding: 8px; }
.hint-box strong { font-size: 11px; }
.hint-box span { font-size: 10px; }
.shortcut-editor,
.diagnostics-box { display: none; }

@media (max-width: 1450px) {
  .main-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .deck { height: 600px; }
  .mixer { height: 600px; }
  .deck-body { grid-template-columns: 68px minmax(190px, 1fr) 130px !important; height: 438px; }
  .platter { width: clamp(205px, 18vw, 250px); }
  .transport-row button { height: 44px; }
  .hotcue-grid button { height: 31px; }
  .deck-tools { gap: 6px; }
}

@media (max-width: 1180px) {
  .topbar { grid-template-columns: 1fr auto auto; }
  .main-grid { grid-template-columns: 1fr; }
  .deck-a,
  .mixer,
  .deck-b,
  .library-panel,
  .recording-panel,
  .cue-panel { grid-column: auto; grid-row: auto; }
  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel { height: auto; }
  .deck-body { grid-template-columns: 84px 1fr 178px !important; height: auto; }
  .deck-tools { max-height: none; overflow: visible; }
  .platter { width: min(300px, 44vw); }
  .shortcut-editor,
  .diagnostics-box { display: block; }
}

@media (max-width: 760px) {
  .app-shell {
    width: 100%;
    padding: 8px 8px 82px;
    max-width: 430px;
  }
  .topbar {
    position: sticky;
    min-height: 50px;
    border-radius: 14px;
    grid-template-columns: 1fr auto;
    padding: 8px 10px;
  }
  .brand-mark { width: 22px; height: 24px; }
  .brand-copy strong { font-size: 14px; }
  .record-pill { min-width: 36px; min-height: 34px; }
  .record-pill b { display: none; }
  .main-grid { margin-top: 8px; gap: 8px; }
  .deck {
    height: auto;
    min-height: 0 !important;
    padding: 9px;
    border-radius: 13px;
  }
  .deck-header { grid-template-columns: 42px 1fr auto; }
  .deck-badge { width: 40px; height: 32px; }
  .wave-wrap { height: 64px; }
  .time-row { margin-bottom: 8px; }
  .deck-body {
    grid-template-columns: 1fr !important;
    height: auto;
    gap: 8px;
  }
  .tempo-column {
    grid-template-columns: 1fr 72px 1fr;
    grid-template-rows: auto auto;
    gap: 7px 10px;
    min-height: 0;
    padding: 9px;
  }
  .tempo-column .sync-button { grid-column: 3; grid-row: 1; }
  .tempo-column strong { grid-column: 1; grid-row: 1; justify-self: start; }
  .tempo-column span { grid-column: 2; grid-row: 1; }
  .range-button { display: none; }
  .vertical-slider {
    grid-column: 1 / -1;
    grid-row: 2;
    display: grid;
    grid-template-columns: auto 1fr auto;
    height: auto;
    width: 100%;
    margin: 0;
  }
  .vertical-slider input { transform: none; width: 100%; }
  .platter-zone { display: contents; }
  .platter { display: none; }
  .transport-row {
    order: -1;
    grid-template-columns: 1fr 1.35fr 48px;
    gap: 8px;
  }
  .transport-row button { height: 45px; }
  .deck-tools {
    grid-template-columns: 1fr;
    overflow: visible;
    max-height: none;
  }
  .loop-box { display: none; }
  .hotcue-grid { grid-template-columns: repeat(4, 1fr); }
  .hotcue-grid button { height: 44px; }
  .mixer {
    height: auto;
    padding: 9px;
    border-radius: 13px;
    grid-template-columns: 1fr;
  }
  .channel-strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }
  .channel-fader input { height: auto; }
  .master-strip { grid-template-columns: 1fr 1fr; }
  .meter-shell { height: 72px; }
  #masterMeter { width: 100%; height: 58px; }
  .library-panel,
  .recording-panel,
  .cue-panel { display: none; }
  .mobile-tabs {
    left: 8px;
    right: 8px;
    bottom: max(8px, env(safe-area-inset-bottom));
    grid-template-columns: 1fr 1fr 1fr;
    border-radius: 14px;
  }
  .mobile-tabs button { height: 42px; }
}

/* v1.7 functional-control pass */
.bpm-edit-button {
  display: grid;
  grid-template-columns: auto auto;
  gap: 1px 8px;
  align-items: baseline;
  justify-content: end;
  text-align: right;
  padding: 4px 6px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}
.bpm-edit-button:hover,
.bpm-edit-button:focus-visible {
  border-color: rgba(143, 208, 255, .45);
  background: rgba(47,155,255,.08);
}
.deck-b .bpm-edit-button:hover,
.deck-b .bpm-edit-button:focus-visible {
  border-color: rgba(255, 140, 21, .45);
  background: rgba(255,140,21,.08);
}
.bpm-edit-button strong { font-size: 16px; font-variant-numeric: tabular-nums; }
.bpm-edit-button span { font-size: 11px; color: var(--muted); }
.bpm-edit-button + em { grid-column: 2; }
.deck.loading::after {
  content: attr(data-loading-label);
  position: absolute;
  inset: 0;
  z-index: 9;
  display: grid;
  place-items: center;
  background: rgba(3, 6, 10, .76);
  color: #eaf5ff;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  backdrop-filter: blur(5px);
}
.deck.loading .wave-wrap,
.deck.loading .platter,
.deck.loading .transport-row,
.deck.loading .deck-tools,
.deck.loading .tempo-column { opacity: .48; }
.track-table tr.loading-target {
  outline: 1px solid rgba(255, 213, 78, .65);
  background: rgba(255, 213, 78, .07);
}
.track-table button.busy {
  color: #141000;
  background: var(--yellow);
  border-color: var(--yellow);
}
.wave-wrap,
.zoom-waveform,
.progress-rail {
  cursor: crosshair;
  touch-action: none;
}
.wave-wrap:hover,
.zoom-waveform:hover,
.progress-rail:hover {
  border-color: rgba(143, 208, 255, .42);
}
.deck-b .wave-wrap:hover,
.deck-b .zoom-waveform:hover,
.deck-b .progress-rail:hover {
  border-color: rgba(255, 140, 21, .42);
}
.platter.jog-active {
  transform: scale(.992);
  outline: 2px solid rgba(255,255,255,.18);
}
.platter::after {
  content: "drag / wheel";
  position: absolute;
  bottom: -24px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(235, 243, 255, .45);
  font-size: 10px;
  letter-spacing: .08em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 120ms ease;
}
.platter:hover::after { opacity: 1; }
body.show-settings .shortcut-editor,
body.show-settings .diagnostics-box {
  display: block;
}
.deck-tools {
  padding-bottom: 6px;
}
button.reset-flash,
input.reset-flash,
select.reset-flash {
  box-shadow: 0 0 0 2px rgba(99, 212, 84, .35), 0 0 16px rgba(99, 212, 84, .25) !important;
}
.load-cell button[aria-busy="true"]::after {
  content: "...";
}
.control-hint {
  color: rgba(235, 243, 255, .58);
  font-size: 10px;
}
@media (max-width: 1450px) {
  .deck { height: 630px; }
  .mixer { height: 630px; }
  .deck-body { height: 468px; }
}
@media (max-width: 760px) {
  .bpm-edit-button strong { font-size: 14px; }
  .bpm-edit-button span { font-size: 10px; }
  .platter::after { display: none; }
}

/* v1.9 functional usability pass */
.deck-body {
  grid-template-columns: 76px minmax(250px, 1fr) 168px !important;
}
.deck-tools {
  overflow-y: visible;
  max-height: none;
}
.deck { height: 660px; }
.mixer { height: 660px; }
.bpm-edit-button::after {
  content: "EDIT";
  grid-column: 1 / -1;
  justify-self: end;
  color: rgba(143, 208, 255, .7);
  font-size: 9px;
  letter-spacing: .08em;
}
.deck-b .bpm-edit-button::after { color: rgba(255, 192, 124, .78); }
.wave-wrap::after {
  content: "click or drag waveform to seek";
  position: absolute;
  right: 8px;
  bottom: 5px;
  color: rgba(235, 243, 255, .46);
  font-size: 10px;
  letter-spacing: .04em;
  opacity: 0;
  transition: opacity 120ms ease;
  pointer-events: none;
}
.wave-wrap:hover::after { opacity: 1; }
.deck.loading::after {
  font-size: 15px;
}
.deck.loading::before {
  content: "";
  position: absolute;
  left: 18%;
  right: 18%;
  top: 55%;
  height: 4px;
  z-index: 10;
  border-radius: 99px;
  background: linear-gradient(90deg, transparent, rgba(143,208,255,.9), transparent);
  animation: loadingSweep 900ms linear infinite;
}
@keyframes loadingSweep {
  from { transform: translateX(-18%); opacity: .25; }
  50% { opacity: 1; }
  to { transform: translateX(18%); opacity: .25; }
}
@media (max-width: 1450px) {
  .deck { height: 650px; }
  .mixer { height: 650px; }
  .deck-body { grid-template-columns: 68px minmax(190px, 1fr) 158px !important; height: 500px; }
}
@media (max-width: 1180px) {
  .deck { height: auto; }
  .mixer { height: auto; }
  .deck-body { grid-template-columns: 84px minmax(260px, 1fr) 185px !important; height: auto; }
}
@media (max-width: 760px) {
  .deck-body { grid-template-columns: 1fr !important; }
  .deck-tools { overflow: visible; }
  .bpm-edit-button::after { display: none; }
}

/* v1.10 usability, sync, and file-manager pass */
.app-shell {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 12px;
}
.main-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}
.deck-a { grid-column: 1 / span 5; grid-row: 1; }
.mixer { grid-column: 6 / span 2; grid-row: 1; }
.deck-b { grid-column: 8 / span 5; grid-row: 1; }
.library-panel {
  grid-column: 1 / span 9;
  grid-row: 2 / span 2;
  height: 390px;
  min-width: 0;
}
.recording-panel {
  grid-column: 10 / span 3;
  grid-row: 2;
  height: 188px;
}
.cue-panel {
  grid-column: 10 / span 3;
  grid-row: 3;
  height: 188px;
}
.table-wrap {
  max-height: 246px;
  overflow: auto;
}
.track-table {
  min-width: 1040px;
}
.panel-header {
  grid-template-columns: minmax(140px, auto) auto auto auto minmax(260px, 1fr) auto auto;
}
.search { min-width: 240px; }
.deck {
  height: 690px;
}
.mixer {
  height: 690px;
}
.deck-body {
  grid-template-columns: 78px minmax(255px, 1fr) 188px !important;
  height: 520px;
}
.deck-tools {
  overflow: visible;
  max-height: none;
  padding-right: 0;
}
.tempo-column {
  position: relative;
  grid-template-rows: 33px 24px auto auto 1fr;
}
.sync-status {
  display: grid;
  place-items: center;
  min-height: 22px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  color: rgba(226,237,250,.72);
  background: rgba(255,255,255,.035);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.15;
}
.deck.sync-locked .sync-status {
  color: #082018;
  background: linear-gradient(180deg, rgba(99,212,84,.95), rgba(44,160,86,.9));
  border-color: rgba(99,212,84,.8);
  box-shadow: 0 0 18px rgba(99,212,84,.22);
}
.sync-button.sync-warning:not(.active) {
  color: var(--yellow);
  border-color: rgba(255,213,78,.42);
}
.deck.sync-locked .tempo-slider input:disabled {
  opacity: .55;
  cursor: not-allowed;
}
.deck.sync-locked .tempo-column::after {
  content: "pitch locked";
  align-self: end;
  justify-self: center;
  color: rgba(99,212,84,.8);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  position: absolute;
  right: 3px;
  bottom: 35px;
}
.deck-feedback {
  height: 22px;
  display: grid;
  place-items: center;
  margin-top: 8px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 8px;
  color: rgba(224,236,248,.56);
  background: rgba(255,255,255,.025);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
  transition: background 120ms ease, color 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}
.deck.has-feedback .deck-feedback {
  color: #041018;
  background: linear-gradient(180deg, rgba(143,208,255,.96), rgba(47,155,255,.9));
  border-color: rgba(143,208,255,.9);
  box-shadow: 0 0 18px rgba(47,155,255,.26);
}
.deck-b.has-feedback .deck-feedback {
  background: linear-gradient(180deg, rgba(255,192,124,.98), rgba(255,140,21,.9));
  border-color: rgba(255,192,124,.88);
  box-shadow: 0 0 18px rgba(255,140,21,.22);
}
.deck-feedback[data-kind="sync"] {
  background: linear-gradient(180deg, rgba(99,212,84,.96), rgba(44,160,86,.9)) !important;
  border-color: rgba(99,212,84,.82) !important;
  color: #06130b !important;
}
.deck-feedback[data-kind="loop"] {
  background: linear-gradient(180deg, rgba(255,213,78,.98), rgba(206,151,34,.92)) !important;
  border-color: rgba(255,213,78,.86) !important;
  color: #130d02 !important;
}
.deck-feedback[data-kind="cue"] {
  background: linear-gradient(180deg, rgba(178,107,255,.96), rgba(99,72,220,.9)) !important;
  border-color: rgba(178,107,255,.82) !important;
  color: #fff !important;
}
.deck.seeking .wave-wrap::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--seek-pct, 0%);
  width: 2px;
  z-index: 4;
  background: rgba(255,255,255,.92);
  box-shadow: 0 0 14px rgba(255,255,255,.8);
  pointer-events: none;
}
.deck.seeking .progress-rail {
  box-shadow: 0 0 0 2px rgba(143,208,255,.24);
}
.deck-b.seeking .progress-rail {
  box-shadow: 0 0 0 2px rgba(255,140,21,.24);
}
.platter.jog-worked {
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.32),
    0 0 0 3px rgba(255,255,255,.32),
    0 0 32px rgba(143,208,255,.42),
    0 18px 42px rgba(0,0,0,.35) !important;
}
.deck-b .platter.jog-worked {
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.32),
    0 0 0 3px rgba(255,255,255,.3),
    0 0 32px rgba(255,140,21,.42),
    0 18px 42px rgba(0,0,0,.35) !important;
}
.worked-flash {
  box-shadow: 0 0 0 2px rgba(143,208,255,.36), 0 0 20px rgba(143,208,255,.24) !important;
}
.loop-toggle.active {
  color: #130d02;
  background: linear-gradient(180deg, rgba(255,213,78,.98), rgba(206,151,34,.94));
  border-color: rgba(255,213,78,.9);
}
.recording-panel .record-controls {
  grid-template-columns: 52px 1fr 38px;
}
.recordings-list { max-height: 32px; }
.cue-panel .hint-box,
.cue-panel .diagnostics-box,
.cue-panel .shortcut-editor {
  display: none;
}
.cue-diagram { margin-top: 6px; }

@media (min-width: 1800px) {
  .deck-body { grid-template-columns: 82px minmax(330px, 1fr) 210px !important; }
  .platter { width: clamp(260px, 20vw, 340px); }
  .library-panel { height: 430px; }
  .table-wrap { max-height: 286px; }
}

@media (max-width: 1450px) {
  .deck { height: 700px; }
  .mixer { height: 700px; }
  .deck-body { grid-template-columns: 70px minmax(205px, 1fr) 178px !important; height: 530px; }
  .library-panel { grid-column: 1 / span 8; height: 390px; }
  .recording-panel,
  .cue-panel { grid-column: 9 / span 4; }
}

@media (max-width: 1180px) {
  .deck-a,
  .mixer,
  .deck-b,
  .library-panel,
  .recording-panel,
  .cue-panel { grid-column: auto; grid-row: auto; }
  .library-panel { height: auto; }
  .table-wrap { max-height: 320px; }
  .track-table { min-width: 940px; }
  .recording-panel,
  .cue-panel { height: auto; }
  .cue-panel .hint-box { display: block; }
}

@media (max-width: 760px) {
  .app-shell { max-width: 460px; margin: 0 auto; padding: 8px 8px 82px; }
  .deck { height: auto; }
  .deck-feedback { margin-top: 6px; height: 20px; }
  .sync-status { min-height: 26px; }
  .tempo-column { grid-template-rows: auto auto; }
  .tempo-column .sync-status { grid-column: 3; grid-row: 2; }
  .library-panel,
  .recording-panel,
  .cue-panel { display: none; }
}

/* v1.11 UI polish and CDJ-style sync clarity pass */
:root {
  --panel-edge: rgba(255,255,255,.115);
  --panel-fill: rgba(8, 13, 19, .96);
}

.app-shell {
  padding: 10px 12px 18px;
}

.topbar {
  border-radius: 12px;
  border-color: var(--panel-edge);
}

.main-grid {
  gap: 10px;
}

.deck,
.mixer,
.app-panel {
  border-color: var(--panel-edge);
}

.deck {
  height: auto;
  min-height: 690px;
  overflow: hidden;
  padding: 12px;
}

.deck-header {
  min-height: 44px;
}

.track-title-block {
  min-width: 0;
}

.deck-meta {
  min-width: 82px;
}

.bpm-edit-button {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 5px;
  align-items: baseline;
  justify-items: end;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
}

.bpm-edit-button:hover {
  color: #fff;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.bpm-edit-button span {
  align-self: end;
}

.deck-feedback {
  letter-spacing: .11em;
}

.wave-wrap {
  cursor: ew-resize;
}

.zoom-waveform {
  display: block;
  width: 100%;
  height: 38px;
  margin-top: 5px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 6px;
  background: rgba(0,0,0,.16);
  cursor: ew-resize;
}

.deck-body {
  height: auto !important;
  min-height: 510px;
  grid-template-columns: 78px minmax(280px, 1fr) minmax(172px, 205px) !important;
  align-items: stretch;
}

.tempo-column {
  grid-template-rows: 33px 23px 25px auto auto 1fr;
}

.sync-primer {
  display: grid;
  place-items: center;
  min-height: 24px;
  padding: 2px 4px;
  border-radius: 7px;
  background: rgba(255,255,255,.025);
  color: rgba(220,232,245,.58);
  font-size: 8.5px;
  line-height: 1.15;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: .045em;
}

.deck.sync-locked .sync-primer {
  color: rgba(196, 255, 203, .88);
  background: rgba(99,212,84,.08);
  border: 1px solid rgba(99,212,84,.18);
}

.platter-zone {
  min-width: 0;
  align-content: center;
}

.platter {
  width: clamp(250px, 18.7vw, 330px);
}

.deck-tools {
  display: grid;
  grid-template-rows: auto auto auto auto;
  gap: 7px;
  overflow: visible;
}

.loop-size button,
.loop-row button,
.loop-toggle {
  height: 27px;
}

.loop-extra-row button {
  min-height: 22px;
}

.hotcue-grid {
  gap: 5px;
}

.hotcue-grid button {
  height: 32px;
}

.deck-options button {
  min-height: 28px;
}

.grid-row {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 42px;
}

.mixer {
  height: auto;
  min-height: 690px;
}

.master-strip,
.channel-strip {
  border-color: rgba(255,255,255,.105);
}

.master-strip {
  align-content: start;
}

.meter-shell {
  height: 210px;
}

#masterMeter {
  height: 196px;
}

.library-panel {
  height: clamp(390px, 38vh, 520px);
}

.library-main {
  grid-template-rows: auto auto auto minmax(0, 1fr);
}

.panel-header {
  grid-template-columns: minmax(130px, auto) auto auto auto minmax(280px, 1fr) auto auto;
  align-items: center;
}

.table-wrap {
  max-height: none;
  min-height: 0;
}

.track-table th,
.track-table td {
  padding: 8px 10px;
}

.recording-panel,
.cue-panel {
  height: clamp(190px, 18vh, 250px);
}

.recordings-list {
  max-height: 58px;
}

.cue-panel .hint-box.keylock-note {
  display: none;
}

.sync-button.active {
  color: #071409;
  background: linear-gradient(180deg, rgba(99,212,84,.98), rgba(45,164,75,.9));
  border-color: rgba(99,212,84,.95);
}

.sync-button.active:hover {
  color: #071409;
}

.platter.jog-active::before,
.platter.jog-worked::before {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.18);
  pointer-events: none;
  animation: jogPulse 420ms ease-out;
}

@keyframes jogPulse {
  from { transform: scale(.96); opacity: .9; }
  to { transform: scale(1.04); opacity: 0; }
}

.deck.seeking .wave-wrap,
.deck.seeking .zoom-waveform {
  border-color: rgba(255,255,255,.32);
}

button[aria-pressed="true"],
button.active {
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.13), 0 0 18px rgba(99,212,84,.10);
}

@media (min-width: 1800px) {
  .deck-body { grid-template-columns: 82px minmax(360px, 1fr) 218px !important; }
  .platter { width: clamp(285px, 18.5vw, 360px); }
  .library-panel { height: 480px; }
  .recording-panel,
  .cue-panel { height: 235px; }
}

@media (max-width: 1500px) {
  .deck { min-height: 690px; }
  .mixer { min-height: 690px; }
  .deck-body { grid-template-columns: 70px minmax(220px, 1fr) 172px !important; }
  .platter { width: clamp(220px, 17vw, 285px); }
  .zoom-waveform { height: 32px; }
  .hotcue-grid button { height: 30px; }
}

@media (max-width: 1180px) {
  .deck,
  .mixer { min-height: 0; }
  .deck-body { grid-template-columns: 84px minmax(260px, 1fr) 190px !important; }
  .library-panel { height: auto; }
  .cue-panel .hint-box.keylock-note { display: grid; }
}

@media (max-width: 760px) {
  .zoom-waveform { display: none; }
  .deck-body { min-height: 0; }
  .sync-primer { grid-column: 1 / -1; min-height: 22px; }
  .panel-header { grid-template-columns: 1fr auto; }
}

/* v1.12 finishing pass: compact decks, cleaner panel boundaries, and no half-finished overflow edges */
:root {
  --finished-panel: rgba(8, 13, 19, 0.97);
  --finished-panel-soft: rgba(12, 18, 26, 0.96);
  --finished-line: rgba(220, 235, 255, 0.12);
  --finished-line-soft: rgba(220, 235, 255, 0.075);
}

html, body {
  background:
    radial-gradient(circle at 10% 0%, rgba(47,155,255,.10), transparent 26%),
    radial-gradient(circle at 88% 10%, rgba(255,140,21,.08), transparent 26%),
    linear-gradient(180deg, #0a1018 0%, #05080d 100%);
}

.app-shell {
  padding: 10px 12px 16px !important;
  background: transparent;
}

.topbar {
  min-height: 54px !important;
  padding: 9px 14px !important;
  border-radius: 12px !important;
  background: linear-gradient(180deg, rgba(13, 20, 29, .985), rgba(7, 11, 17, .985)) !important;
  border: 1px solid var(--finished-line) !important;
  box-shadow: 0 12px 32px rgba(0,0,0,.35) !important;
}

.brand-copy strong { font-size: 14px !important; }
.brand-copy small { font-size: 10px !important; }
.session-select { min-height: 34px !important; }
.status-strip { gap: 8px !important; }
.icon-status,
.record-pill,
.ghost-icon { min-height: 34px !important; }

.main-grid {
  width: 100% !important;
  max-width: none !important;
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr)) !important;
  gap: 10px !important;
  align-items: start !important;
  margin-top: 10px !important;
}

.deck-a { grid-column: 1 / span 5 !important; grid-row: 1 !important; }
.mixer { grid-column: 6 / span 2 !important; grid-row: 1 !important; }
.deck-b { grid-column: 8 / span 5 !important; grid-row: 1 !important; }
.library-panel { grid-column: 1 / span 9 !important; grid-row: 2 / span 2 !important; }
.recording-panel { grid-column: 10 / span 3 !important; grid-row: 2 !important; }
.cue-panel { grid-column: 10 / span 3 !important; grid-row: 3 !important; }

.deck,
.mixer,
.app-panel {
  border: 1px solid var(--finished-line) !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.028), rgba(255,255,255,.010)),
    var(--finished-panel) !important;
  box-shadow: 0 10px 26px rgba(0,0,0,.30) !important;
  border-radius: 11px !important;
  overflow: hidden !important;
}

.deck {
  height: 535px !important;
  min-height: 0 !important;
  padding: 10px !important;
}

.deck::before {
  opacity: .25 !important;
  background: radial-gradient(circle at 42% 54%, var(--blue-soft), transparent 32%) !important;
}
.deck-b::before {
  background: radial-gradient(circle at 42% 54%, var(--orange-soft), transparent 32%) !important;
}

.deck-header {
  min-height: 38px !important;
  gap: 10px !important;
}
.deck-badge {
  width: 34px !important;
  height: 34px !important;
  font-size: 15px !important;
}
.track-title-block h2 {
  font-size: 15px !important;
  max-width: 100% !important;
}
.track-title-block p { font-size: 11px !important; }
.deck-meta { min-width: 74px !important; }
.deck-meta strong { font-size: 14px !important; }
.deck-meta span { font-size: 10px !important; }
.deck-meta em { font-size: 13px !important; }
.bpm-edit-button::after {
  content: "EDIT";
  grid-column: 1 / -1;
  justify-self: end;
  font-size: 8px;
  color: rgba(143,208,255,.72);
  letter-spacing: .08em;
}
.deck-b .bpm-edit-button::after { color: rgba(255,192,124,.72); }

.deck-feedback {
  height: 18px !important;
  margin-top: 6px !important;
  border-radius: 6px !important;
  font-size: 8.5px !important;
}

.wave-wrap {
  height: 58px !important;
  margin-top: 8px !important;
  border-radius: 7px !important;
  background: rgba(3, 7, 11, .78) !important;
}
.zoom-waveform {
  display: block !important;
  height: 28px !important;
  margin-top: 4px !important;
  border-color: var(--finished-line-soft) !important;
  background: rgba(3, 7, 11, .62) !important;
}
.time-row {
  margin: 5px 0 7px !important;
  gap: 8px !important;
}
.time-row time { font-size: 11px !important; }
.progress-rail { height: 6px !important; }

.deck-body {
  height: 373px !important;
  min-height: 0 !important;
  grid-template-columns: 68px minmax(190px, 1fr) 145px !important;
  gap: 9px !important;
}

.tempo-column {
  min-height: 0 !important;
  grid-template-rows: 29px 20px 20px 22px 1fr !important;
  gap: 4px !important;
  padding: 7px 6px !important;
  border-color: var(--finished-line-soft) !important;
  background: rgba(3, 7, 11, .45) !important;
}
.sync-button { height: 28px !important; font-size: 10.5px !important; }
.sync-status { min-height: 19px !important; font-size: 8px !important; }
.sync-primer { display: none !important; }
.tempo-column strong { font-size: 11px !important; }
.tempo-column span { font-size: 9px !important; }
.range-button { width: 42px !important; height: 23px !important; font-size: 10px !important; }
.vertical-slider { height: 104px !important; margin-bottom: 8px !important; }
.vertical-slider input { width: 105px !important; }

.platter-zone {
  min-height: 0 !important;
  gap: 11px !important;
  align-content: center !important;
}
.platter {
  width: clamp(190px, 14.8vw, 245px) !important;
  box-shadow:
    inset 0 0 0 7px rgba(0,0,0,.38),
    0 0 0 1px rgba(47,155,255,.28),
    0 0 22px rgba(47,155,255,.17) !important;
}
.deck-b .platter {
  box-shadow:
    inset 0 0 0 7px rgba(0,0,0,.38),
    0 0 0 1px rgba(255,140,21,.30),
    0 0 22px rgba(255,140,21,.16) !important;
}
.platter-ring { inset: 10px !important; }
.platter-core { width: 38px !important; height: 38px !important; }
.transport-row { grid-template-columns: 1fr 1fr 40px !important; gap: 7px !important; }
.transport-row button { height: 42px !important; font-size: 13px !important; }
.set-button { font-size: 10px !important; }

.deck-tools {
  display: grid !important;
  grid-template-rows: auto auto auto auto !important;
  gap: 6px !important;
  max-height: none !important;
  overflow: visible !important;
  padding-right: 0 !important;
}
.loop-box label,
.hotcue-box label { font-size: 9px !important; margin-bottom: 5px !important; }
.loop-size button,
.loop-row button,
.loop-toggle { height: 24px !important; font-size: 10px !important; }
.loop-size strong { font-size: 13px !important; }
.loop-extra-row { gap: 4px !important; margin-top: 5px !important; }
.loop-extra-row button { min-height: 20px !important; font-size: 7.5px !important; padding: 0 3px !important; }
.hotcue-grid { gap: 5px !important; }
.hotcue-grid button { height: 29px !important; font-size: 12px !important; }
.deck-options { grid-template-columns: repeat(4, 1fr) !important; gap: 4px !important; }
.deck-options button { min-height: 25px !important; font-size: 8px !important; padding: 0 !important; }
.hotcue-hint { display: none !important; }

.mixer {
  height: 535px !important;
  min-height: 0 !important;
  padding: 9px !important;
  grid-template-columns: 1fr 1.04fr 1fr !important;
  gap: 7px !important;
}
.channel-strip,
.master-strip {
  min-height: 0 !important;
  padding: 8px 6px !important;
  gap: 6px !important;
  border-color: var(--finished-line-soft) !important;
  background: rgba(3, 7, 11, .45) !important;
}
.channel-strip h3,
.master-strip h3 { font-size: 11px !important; margin: 0 !important; }
.channel-strip label,
.master-strip label { font-size: 8.5px !important; }
.channel-strip input[type="range"] { height: 12px !important; }
.channel-cue { height: 27px !important; font-size: 10px !important; }
.channel-meter { height: 20px !important; }
.channel-fader input { height: 70px !important; }
.meter-shell { height: 150px !important; }
#masterMeter { height: 138px !important; width: 48px !important; }
.cue-mix-control,
.cue-level-control { margin-top: 0 !important; }
.headphone-status { font-size: 8.5px !important; }
.crossfader { gap: 5px !important; }
.xfade-assign select,
.xfade-curve select { min-height: 22px !important; font-size: 9px !important; }

.library-panel {
  height: 360px !important;
  min-height: 0 !important;
  grid-template-columns: 130px minmax(0, 1fr) !important;
  padding: 0 !important;
}
.side-nav {
  padding: 9px !important;
  gap: 4px !important;
  background: rgba(0,0,0,.14) !important;
}
.side-nav button { height: 30px !important; font-size: 11px !important; }
.library-main { grid-template-rows: auto auto auto minmax(0,1fr) !important; }
.panel-header {
  grid-template-columns: minmax(120px, auto) auto auto auto minmax(340px, 1fr) auto auto !important;
  gap: 7px !important;
  padding: 9px !important;
  border-bottom-color: var(--finished-line-soft) !important;
}
.panel-header strong { font-size: 14px !important; }
.panel-header span,
.panel-header em { font-size: 11px !important; }
.import-button,
.small-action,
.label-action,
.danger-small { height: 29px !important; font-size: 10px !important; }
.search { height: 29px !important; font-size: 11px !important; min-width: 280px !important; }
.storage-dashboard { padding: 6px 9px !important; font-size: 9.5px !important; }
.drop-hint { margin: 6px 9px !important; padding: 7px 8px !important; font-size: 10px !important; }
.table-wrap { max-height: none !important; min-height: 0 !important; overflow: auto !important; }
.track-table { min-width: 1080px !important; font-size: 11.5px !important; }
.track-table th,
.track-table td { padding: 7px 9px !important; }

.recording-panel,
.cue-panel {
  height: 175px !important;
  min-height: 0 !important;
  overflow: auto !important;
  padding: 9px !important;
}
.recording-panel .panel-title,
.cue-panel .panel-title { font-size: 10.5px !important; }
.recording-panel h3,
.cue-panel h3 { margin: 6px 0 2px !important; font-size: 12px !important; }
.recording-panel p,
.cue-panel p { font-size: 10px !important; margin-bottom: 6px !important; }
.recording-panel canvas { height: 46px !important; }
.record-controls { grid-template-columns: 44px 1fr 34px !important; gap: 7px !important; margin-top: 6px !important; }
.big-rec { width: 42px !important; height: 42px !important; }
.record-controls time { font-size: 13px !important; }
.record-controls small { font-size: 9px !important; }
.stop-button { height: 34px !important; }
.recordings-list { max-height: 48px !important; }
.cue-meter { height: 24px !important; }
.cue-diagram { padding: 8px !important; gap: 5px !important; }
.diagram-row { gap: 7px !important; font-size: 10px !important; }
.diagram-row i { font-size: 17px !important; }
.diagram-divider { font-size: 8.5px !important; }
.cue-panel .hint-box,
.cue-panel .diagnostics-box,
.cue-panel .shortcut-editor { display: none !important; }

.deck.seeking .wave-wrap::before,
.deck.seeking .zoom-waveform::before {
  content: "";
  position: absolute;
  inset-block: 0;
  left: var(--seek-pct, 0%);
  width: 2px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 0 12px rgba(255,255,255,.70);
  z-index: 5;
  pointer-events: none;
}
.deck.seeking .wave-wrap,
.deck.seeking .zoom-waveform { border-color: rgba(255,255,255,.32) !important; }

@media (min-width: 1800px) {
  .deck { height: 550px !important; }
  .mixer { height: 550px !important; }
  .deck-body { height: 388px !important; grid-template-columns: 72px minmax(220px, 1fr) 154px !important; }
  .platter { width: clamp(210px, 14.5vw, 275px) !important; }
  .library-panel { height: 380px !important; }
  .recording-panel,
  .cue-panel { height: 185px !important; }
}

@media (max-width: 1500px) {
  .deck { height: 515px !important; }
  .mixer { height: 515px !important; }
  .deck-body { height: 356px !important; grid-template-columns: 62px minmax(170px, 1fr) 132px !important; }
  .platter { width: clamp(175px, 13.5vw, 220px) !important; }
  .deck-tools { gap: 5px !important; }
  .hotcue-grid button { height: 26px !important; }
  .loop-size button,
  .loop-row button,
  .loop-toggle { height: 22px !important; }
  .mixer { gap: 6px !important; }
  .library-panel { grid-column: 1 / span 8 !important; height: 350px !important; }
  .recording-panel,
  .cue-panel { grid-column: 9 / span 4 !important; height: 170px !important; }
}

@media (max-width: 1180px) {
  .main-grid { grid-template-columns: 1fr !important; }
  .deck-a,
  .mixer,
  .deck-b,
  .library-panel,
  .recording-panel,
  .cue-panel { grid-column: auto !important; grid-row: auto !important; }
  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel { height: auto !important; }
  .deck-body { height: auto !important; grid-template-columns: 76px minmax(240px,1fr) 170px !important; }
  .deck-tools { overflow: visible !important; }
  .platter { width: min(250px, 38vw) !important; }
  .library-panel { min-height: 330px !important; }
  .recording-panel,
  .cue-panel { min-height: 180px !important; }
}

@media (max-width: 760px) {
  .app-shell { max-width: 460px !important; margin: 0 auto !important; padding: 8px 8px 82px !important; }
  .topbar { min-height: 50px !important; }
  .deck { padding: 9px !important; }
  .deck-body { grid-template-columns: 1fr !important; gap: 8px !important; }
  .tempo-column { grid-template-columns: 82px 64px 1fr !important; grid-template-rows: auto auto !important; }
  .sync-status { grid-column: 2 !important; }
  .vertical-slider { height: auto !important; margin: 0 !important; }
  .vertical-slider input { transform: none !important; width: 100% !important; }
  .platter { display: none !important; }
  .transport-row button { height: 40px !important; }
  .library-panel,
  .recording-panel,
  .cue-panel { display: none !important; }
  .bpm-edit-button::after { display: none !important; }
}

.deck-tools {
  position: relative !important;
  grid-template-rows: auto auto auto 24px !important;
  isolation: isolate;
}

.tempo-column {
  grid-template-rows: 29px 20px 24px 15px 25px minmax(112px, 1fr) !important;
  gap: 5px !important;
  padding: 7px 7px 9px !important;
  background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.008)), var(--tempo-panel) !important;
  border-color: var(--tempo-line) !important;
  overflow: hidden;
}

.tempo-column .sync-button {
  grid-row: 1 !important;
  align-self: stretch;
  width: 100%;
}

.tempo-column .sync-status {
  grid-row: 2 !important;
  min-height: 19px !important;
  height: 19px !important;
  padding: 0 3px;
  font-size: 7.5px !important;
  letter-spacing: .055em;
  border-radius: 6px;
}

.tempo-column .sync-primer {
  display: none !important;
}

.tempo-column > strong[data-role="tempo-bpm"] {
  grid-row: 3 !important;
  display: grid;
  place-items: end center;
  height: 24px;
  color: #f4f8ff;
  font-size: 12px !important;
  line-height: 1;
}

.tempo-column > span[data-role="tempo-pct"] {
  grid-row: 4 !important;
  display: grid;
  place-items: center;
  height: 15px;
  color: rgba(225, 236, 249, .66);
  font-size: 9px !important;
  line-height: 1;
}

.tempo-column .range-button {
  grid-row: 5 !important;
  place-self: center;
  width: 45px !important;
  height: 24px !important;
}

.tempo-column .vertical-slider {
  grid-row: 6 !important;
  align-self: stretch !important;
  justify-self: center !important;
  height: auto !important;
  min-height: 112px;
  margin: 0 !important;
  padding: 2px 0 0;
}

.tempo-column .vertical-slider input {
  width: 108px !important;
}

.deck.sync-locked .tempo-column {
  border-color: rgba(99, 212, 84, .28) !important;
  box-shadow: inset 0 0 0 1px rgba(99, 212, 84, .09), 0 0 22px rgba(99, 212, 84, .06);
}

.deck.sync-locked .tempo-column::after {
  display: none !important;
}

.deck-feedback {
  background: rgba(3, 7, 11, .52) !important;
}

.deck.has-feedback .deck-feedback {
  background: linear-gradient(180deg, rgba(142, 209, 255, .96), rgba(47, 155, 255, .90)) !important;
}

.deck-b.has-feedback .deck-feedback {
  background: linear-gradient(180deg, rgba(255, 192, 124, .96), rgba(255, 140, 21, .90)) !important;
}

.wave-wrap,
.zoom-waveform,
.progress-rail,
.platter,
.transport-row button,
.loop-box,
.hotcue-box,
.tempo-column,
.channel-strip,
.master-strip {
  backface-visibility: hidden;
}

@media (max-width: 1500px) {
  .tempo-column {
    grid-template-rows: 28px 19px 22px 14px 24px minmax(100px, 1fr) !important;
  }
  .tempo-column .vertical-slider input { width: 98px !important; }
}

@media (max-width: 760px) {
  .tempo-column {
    grid-template-columns: 84px 64px 1fr !important;
    grid-template-rows: auto auto auto !important;
    align-items: center;
  }
  .tempo-column .sync-button { grid-column: 3 !important; grid-row: 1 !important; }
  .tempo-column .sync-status { grid-column: 3 !important; grid-row: 2 !important; }
  .tempo-column > strong[data-role="tempo-bpm"] { grid-column: 1 !important; grid-row: 1 !important; justify-self: start; }
  .tempo-column > span[data-role="tempo-pct"] { grid-column: 2 !important; grid-row: 1 !important; }
  .tempo-column .vertical-slider { grid-column: 1 / -1 !important; grid-row: 3 !important; min-height: 0; width: 100%; }
  .tempo-column .vertical-slider input { width: 100% !important; }
}

/* v1.14 visual/UX north-star pass
   Scope: visual layout only. Restores a compact, stable two-deck + center-mixer desktop surface
   that tracks the mockup more closely, without touching audio or control logic. */
:root {
  --v114-bg: #070b10;
  --v114-top: #0d141d;
  --v114-card: #0a1017;
  --v114-card-2: #080d13;
  --v114-card-3: #0f1721;
  --v114-stroke: rgba(218, 234, 255, .115);
  --v114-stroke-soft: rgba(218, 234, 255, .075);
  --v114-glow-blue: rgba(47,155,255,.18);
  --v114-glow-orange: rgba(255,140,21,.17);
}

html, body {
  min-width: 1280px;
  background:
    radial-gradient(circle at 14% 0%, rgba(47,155,255,.10), transparent 30%),
    radial-gradient(circle at 83% 3%, rgba(255,140,21,.08), transparent 28%),
    linear-gradient(180deg, #111820 0%, #06090e 68%, #030507 100%) !important;
}

.app-shell {
  width: min(100%, 1900px) !important;
  max-width: 1900px !important;
  margin: 0 auto !important;
  padding: 14px !important;
}

.topbar {
  position: sticky !important;
  top: 8px !important;
  z-index: 50 !important;
  min-height: 54px !important;
  height: 54px !important;
  padding: 8px 14px !important;
  grid-template-columns: 245px minmax(230px, 300px) 1fr auto !important;
  gap: 14px !important;
  border-radius: 12px !important;
  border: 1px solid var(--v114-stroke) !important;
  background: linear-gradient(180deg, rgba(14, 21, 31, .985), rgba(7, 11, 17, .985)) !important;
  box-shadow: 0 14px 40px rgba(0,0,0,.36) !important;
}
.brand { min-width: 0 !important; }
.brand-mark { width: 28px !important; height: 28px !important; }
.brand-copy strong { font-size: 14px !important; letter-spacing: .02em !important; }
.brand-copy small { font-size: 10px !important; }
.session-select,
.icon-status,
.record-pill,
.ghost-icon { min-height: 34px !important; height: 34px !important; }
.status-strip { gap: 8px !important; }
.record-pill { min-width: 250px !important; justify-content: center !important; }
.text-icon { min-width: 62px !important; }
.ghost-icon { min-width: 38px !important; }

.main-grid {
  display: grid !important;
  width: 100% !important;
  grid-template-columns: minmax(0, 5fr) minmax(235px, 300px) minmax(0, 5fr) !important;
  grid-template-areas:
    "deckA mixer deckB"
    "library library rightTop"
    "library library rightBottom" !important;
  grid-template-rows: 520px 178px 178px !important;
  gap: 12px !important;
  margin-top: 12px !important;
  align-items: stretch !important;
}
.deck-a { grid-area: deckA !important; grid-column: auto !important; grid-row: auto !important; }
.mixer { grid-area: mixer !important; grid-column: auto !important; grid-row: auto !important; }
.deck-b { grid-area: deckB !important; grid-column: auto !important; grid-row: auto !important; }
.library-panel { grid-area: library !important; grid-column: auto !important; grid-row: auto !important; }
.recording-panel { grid-area: rightTop !important; grid-column: auto !important; grid-row: auto !important; }
.cue-panel { grid-area: rightBottom !important; grid-column: auto !important; grid-row: auto !important; }

.deck,
.mixer,
.app-panel {
  height: auto !important;
  min-height: 0 !important;
  border: 1px solid var(--v114-stroke) !important;
  border-radius: 12px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.032), rgba(255,255,255,.010)),
    var(--v114-card) !important;
  box-shadow: 0 12px 34px rgba(0,0,0,.31) !important;
  overflow: hidden !important;
}

.deck {
  padding: 12px !important;
  position: relative !important;
  display: grid !important;
  grid-template-rows: 42px 72px 24px minmax(0, 1fr) !important;
  gap: 8px !important;
}
.deck::before {
  opacity: .34 !important;
  background: radial-gradient(circle at 44% 57%, var(--v114-glow-blue), transparent 32%) !important;
}
.deck-b::before {
  background: radial-gradient(circle at 44% 57%, var(--v114-glow-orange), transparent 32%) !important;
}
.deck > * { min-width: 0 !important; }

.deck-header {
  min-height: 0 !important;
  height: 42px !important;
  display: grid !important;
  grid-template-columns: 38px minmax(0, 1fr) 86px !important;
  gap: 12px !important;
  align-items: center !important;
}
.deck-badge {
  width: 38px !important;
  height: 38px !important;
  border-radius: 7px !important;
  font-size: 16px !important;
}
.track-title-block h2 {
  font-size: 16px !important;
  line-height: 1.05 !important;
  letter-spacing: .01em !important;
}
.track-title-block p {
  margin-top: 4px !important;
  font-size: 11px !important;
}
.deck-meta { min-width: 0 !important; justify-items: end !important; }
.bpm-edit-button {
  padding: 0 !important;
  min-height: 0 !important;
  height: 24px !important;
}
.bpm-edit-button strong { font-size: 15px !important; }
.bpm-edit-button span { font-size: 9px !important; }
.bpm-edit-button::after { content: none !important; }
.deck-meta em { font-size: 14px !important; }

/* Feedback should not consume vertical space. It becomes a small status pill over the waveform. */
.deck-feedback {
  position: absolute !important;
  top: 58px !important;
  left: 72px !important;
  right: 72px !important;
  z-index: 6 !important;
  height: 16px !important;
  min-height: 0 !important;
  margin: 0 !important;
  border-radius: 999px !important;
  border-color: rgba(255,255,255,.065) !important;
  background: rgba(4, 8, 13, .62) !important;
  color: rgba(230,240,252,.58) !important;
  font-size: 8px !important;
  letter-spacing: .14em !important;
  pointer-events: none !important;
  backdrop-filter: blur(8px) !important;
}
.deck.has-feedback .deck-feedback {
  color: #06111c !important;
  background: linear-gradient(180deg, rgba(143,208,255,.96), rgba(47,155,255,.88)) !important;
}
.deck-b.has-feedback .deck-feedback {
  color: #160c02 !important;
  background: linear-gradient(180deg, rgba(255,192,124,.96), rgba(255,140,21,.88)) !important;
}

.wave-wrap {
  grid-row: 2 !important;
  height: 72px !important;
  margin: 0 !important;
  border-radius: 8px !important;
  border-color: var(--v114-stroke-soft) !important;
  background: linear-gradient(180deg, rgba(0,0,0,.34), rgba(0,0,0,.20)) !important;
}
.wave-wrap::after { display: none !important; }
.zoom-waveform { display: none !important; }
.time-row {
  grid-row: 3 !important;
  height: 24px !important;
  min-height: 0 !important;
  margin: 0 !important;
  gap: 8px !important;
  align-items: center !important;
}
.time-row time { font-size: 11px !important; color: rgba(236,244,255,.84) !important; }
.progress-rail { height: 6px !important; border-color: var(--v114-stroke-soft) !important; }

.deck-body {
  grid-row: 4 !important;
  min-height: 0 !important;
  height: 100% !important;
  display: grid !important;
  grid-template-columns: 76px minmax(250px, 1fr) 148px !important;
  gap: 10px !important;
  align-items: stretch !important;
}

.tempo-column {
  min-height: 0 !important;
  height: 100% !important;
  display: grid !important;
  grid-template-columns: 1fr !important;
  grid-template-rows: 30px 20px 22px 14px 24px minmax(0, 1fr) !important;
  gap: 5px !important;
  align-items: center !important;
  justify-items: center !important;
  padding: 7px 7px 9px !important;
  border: 1px solid var(--v114-stroke-soft) !important;
  border-radius: 9px !important;
  background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.006)), rgba(2, 6, 10, .60) !important;
  overflow: hidden !important;
}
.tempo-column .sync-button {
  grid-row: 1 !important;
  width: 100% !important;
  height: 30px !important;
  min-height: 30px !important;
  font-size: 10.5px !important;
  letter-spacing: .10em !important;
}
.tempo-column .sync-status {
  grid-row: 2 !important;
  height: 20px !important;
  min-height: 20px !important;
  width: 100% !important;
  font-size: 7.5px !important;
  line-height: 1 !important;
  border-radius: 6px !important;
  padding: 0 3px !important;
}
.tempo-column .sync-primer { display: none !important; }
.tempo-column > strong[data-role="tempo-bpm"] {
  grid-row: 3 !important;
  font-size: 12px !important;
  line-height: 1 !important;
  height: 22px !important;
  display: grid !important;
  place-items: end center !important;
}
.tempo-column > span[data-role="tempo-pct"] {
  grid-row: 4 !important;
  font-size: 9px !important;
  line-height: 1 !important;
  height: 14px !important;
  display: grid !important;
  place-items: center !important;
  color: rgba(222,234,247,.62) !important;
}
.tempo-column .range-button {
  grid-row: 5 !important;
  width: 45px !important;
  height: 24px !important;
  min-height: 24px !important;
  font-size: 10px !important;
}
.tempo-column .vertical-slider {
  grid-row: 6 !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 92px !important;
  margin: 0 !important;
  padding: 3px 0 0 !important;
  display: grid !important;
  grid-template-rows: 10px 1fr 10px !important;
  place-items: center !important;
}
.tempo-column .vertical-slider span {
  font-size: 9px !important;
  color: rgba(230,240,252,.44) !important;
  line-height: 1 !important;
}
.tempo-column .vertical-slider input {
  width: 112px !important;
  transform: rotate(-90deg) !important;
}

.platter-zone {
  min-height: 0 !important;
  display: grid !important;
  grid-template-rows: minmax(0, 1fr) 44px !important;
  gap: 10px !important;
  align-items: center !important;
  justify-items: center !important;
}
.platter {
  width: clamp(220px, 17.2vw, 300px) !important;
  max-height: 100% !important;
  align-self: center !important;
  border-color: rgba(230,242,255,.16) !important;
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.38),
    0 0 0 1px rgba(47,155,255,.27),
    0 0 28px rgba(47,155,255,.17),
    0 18px 34px rgba(0,0,0,.34) !important;
}
.deck-b .platter {
  box-shadow:
    inset 0 0 0 8px rgba(0,0,0,.38),
    0 0 0 1px rgba(255,140,21,.29),
    0 0 28px rgba(255,140,21,.16),
    0 18px 34px rgba(0,0,0,.34) !important;
}
.platter::after { display: none !important; }
.platter-ring { inset: 11px !important; }
.platter-core { width: 40px !important; height: 40px !important; }
.transport-row {
  width: 100% !important;
  height: 44px !important;
  display: grid !important;
  grid-template-columns: 1fr 1fr 38px !important;
  gap: 8px !important;
}
.transport-row button {
  height: 44px !important;
  min-height: 44px !important;
  font-size: 13px !important;
  border-radius: 8px !important;
}
.set-button { font-size: 9px !important; }

.deck-tools {
  min-height: 0 !important;
  height: 100% !important;
  display: grid !important;
  grid-template-rows: auto auto auto 24px !important;
  gap: 7px !important;
  overflow: visible !important;
  position: relative !important;
}
.loop-box,
.hotcue-box { padding: 7px !important; }
.loop-box label,
.hotcue-box label {
  margin-bottom: 6px !important;
  font-size: 9px !important;
  letter-spacing: .13em !important;
}
.loop-size,
.loop-row { gap: 5px !important; }
.loop-size button,
.loop-row button,
.loop-toggle {
  height: 25px !important;
  min-height: 25px !important;
  font-size: 10px !important;
}
.loop-size strong { font-size: 13px !important; }
.loop-extra-row { margin-top: 5px !important; gap: 4px !important; }
.loop-extra-row button {
  min-height: 21px !important;
  height: 21px !important;
  font-size: 7.5px !important;
  padding: 0 3px !important;
}
.hotcue-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 5px !important; }
.hotcue-grid button {
  height: 30px !important;
  min-height: 30px !important;
  font-size: 12px !important;
  border-radius: 7px !important;
}
.hotcue-hint { display: none !important; }
.deck-options {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 5px !important;
}
.deck-options button {
  height: 25px !important;
  min-height: 25px !important;
  padding: 0 !important;
  font-size: 8px !important;
  border-radius: 7px !important;
}

.mixer {
  padding: 10px !important;
  display: grid !important;
  grid-template-columns: 1fr 1.06fr 1fr !important;
  gap: 8px !important;
}
.channel-strip,
.master-strip {
  min-height: 0 !important;
  border: 1px solid var(--v114-stroke-soft) !important;
  border-radius: 9px !important;
  background: rgba(3, 7, 11, .48) !important;
  padding: 8px 7px !important;
  gap: 6px !important;
}
.channel-strip h3,
.master-strip h3 { font-size: 11px !important; margin: 0 !important; }
.channel-strip label,
.master-strip label { font-size: 8.5px !important; }
.channel-strip input[type="range"] { height: 12px !important; }
.channel-cue { height: 27px !important; min-height: 27px !important; font-size: 10px !important; }
.channel-meter { height: 20px !important; }
.channel-fader input { height: 76px !important; }
.meter-shell { height: 156px !important; }
#masterMeter { height: 144px !important; width: 48px !important; }
.headphone-status { font-size: 8.5px !important; }
.xfade-assign select,
.xfade-curve select { min-height: 24px !important; font-size: 9px !important; }
.crossfader { gap: 5px !important; }

.library-panel {
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: 136px minmax(0, 1fr) !important;
  height: auto !important;
}
.side-nav {
  padding: 10px !important;
  gap: 6px !important;
  border-right: 1px solid var(--v114-stroke-soft) !important;
  background: rgba(2, 6, 10, .26) !important;
}
.side-nav button {
  height: 33px !important;
  font-size: 11px !important;
  border-radius: 7px !important;
}
.library-main {
  min-height: 0 !important;
  display: grid !important;
  grid-template-rows: 46px 30px 31px minmax(0, 1fr) !important;
}
.panel-header {
  display: grid !important;
  grid-template-columns: minmax(135px, 180px) 112px 128px 128px minmax(220px, 1fr) 56px 62px !important;
  gap: 8px !important;
  align-items: center !important;
  padding: 8px 10px !important;
  border-bottom: 1px solid var(--v114-stroke-soft) !important;
}
.panel-header strong { font-size: 15px !important; }
.panel-header span { font-size: 11px !important; }
.panel-header em { font-size: 11px !important; }
.import-button,
.small-action,
.label-action,
.danger-small {
  height: 30px !important;
  min-height: 30px !important;
  padding: 0 9px !important;
  font-size: 10.5px !important;
  border-radius: 7px !important;
}
.search { height: 30px !important; min-width: 0 !important; font-size: 11px !important; }
.storage-dashboard { padding: 7px 10px !important; font-size: 10px !important; border-bottom: 1px solid var(--v114-stroke-soft) !important; }
.drop-hint { margin: 6px 10px !important; padding: 6px 8px !important; font-size: 10px !important; }
.table-wrap { max-height: none !important; min-height: 0 !important; overflow: auto !important; }
.track-table { min-width: 1020px !important; font-size: 11px !important; }
.track-table th,
.track-table td { padding: 7px 9px !important; }
.track-table th { background: #0b121a !important; }

.recording-panel,
.cue-panel {
  height: auto !important;
  padding: 10px !important;
  overflow: hidden !important;
}
.recording-panel .panel-title,
.cue-panel .panel-title { font-size: 11px !important; }
.recording-panel h3,
.cue-panel h3 { margin: 7px 0 2px !important; font-size: 13px !important; }
.recording-panel p,
.cue-panel p { font-size: 10.5px !important; margin-bottom: 7px !important; line-height: 1.25 !important; }
.recording-panel canvas { height: 48px !important; }
.record-controls { grid-template-columns: 46px 1fr 34px !important; gap: 8px !important; margin-top: 6px !important; }
.big-rec { width: 44px !important; height: 44px !important; }
.record-controls time { font-size: 13px !important; }
.record-controls small { font-size: 9px !important; }
.stop-button { height: 34px !important; }
.recordings-list { max-height: 42px !important; }
.cue-meter { height: 24px !important; margin-bottom: 7px !important; }
.cue-diagram { padding: 9px !important; gap: 6px !important; }
.diagram-row { gap: 7px !important; font-size: 10.5px !important; }
.diagram-row i { font-size: 18px !important; }
.diagram-divider { font-size: 8.5px !important; }
.cue-panel .hint-box,
.cue-panel .diagnostics-box,
.cue-panel .shortcut-editor { display: none !important; }

/* Mid-width desktop: keep composition intact and compact, rather than spilling down the page. */
@media (max-width: 1500px) {
  .app-shell { padding: 10px !important; }
  .topbar { grid-template-columns: 210px 230px 1fr auto !important; }
  .main-grid {
    grid-template-columns: minmax(0, 5fr) minmax(220px, 280px) minmax(0, 5fr) !important;
    grid-template-rows: 500px 170px 170px !important;
    gap: 10px !important;
  }
  .deck { grid-template-rows: 40px 64px 22px minmax(0, 1fr) !important; gap: 7px !important; padding: 10px !important; }
  .deck-body { grid-template-columns: 66px minmax(185px, 1fr) 132px !important; gap: 8px !important; }
  .track-title-block h2 { font-size: 14px !important; }
  .wave-wrap { height: 64px !important; }
  .deck-feedback { top: 52px !important; left: 66px !important; right: 66px !important; height: 15px !important; }
  .platter { width: clamp(185px, 14.3vw, 238px) !important; }
  .transport-row { height: 40px !important; grid-template-columns: 1fr 1fr 36px !important; }
  .transport-row button { height: 40px !important; min-height: 40px !important; }
  .tempo-column { grid-template-rows: 28px 18px 20px 13px 22px minmax(0, 1fr) !important; gap: 4px !important; }
  .tempo-column .vertical-slider input { width: 96px !important; }
  .hotcue-grid button { height: 26px !important; }
  .loop-size button,
  .loop-row button,
  .loop-toggle { height: 22px !important; }
  .loop-extra-row button { min-height: 19px !important; height: 19px !important; }
  .deck-options button { height: 23px !important; min-height: 23px !important; }
  .mixer { padding: 8px !important; }
  .meter-shell { height: 135px !important; }
  #masterMeter { height: 124px !important; }
  .channel-fader input { height: 62px !important; }
  .panel-header { grid-template-columns: minmax(115px, 155px) 102px 116px 116px minmax(180px, 1fr) 50px 56px !important; }
  .recording-panel h3,
  .cue-panel h3 { font-size: 12px !important; }
}

@media (max-width: 1180px) {
  html, body { min-width: 0 !important; }
  .main-grid {
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
  }
  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel { height: auto !important; min-height: 0 !important; }
  .deck { grid-template-rows: 42px 72px 24px auto !important; }
  .deck-body { grid-template-columns: 78px minmax(260px,1fr) 170px !important; height: auto !important; min-height: 430px !important; }
  .platter { width: min(280px, 36vw) !important; }
  .library-panel { min-height: 350px !important; }
  .recording-panel,
  .cue-panel { min-height: 175px !important; }
}

@media (max-width: 760px) {
  .app-shell { max-width: 460px !important; padding: 8px 8px 82px !important; }
  .topbar { grid-template-columns: 1fr auto !important; height: 50px !important; min-height: 50px !important; }
  .deck { grid-template-rows: 38px 64px 22px auto !important; }
  .deck-feedback { display: none !important; }
  .deck-body { grid-template-columns: 1fr !important; min-height: 0 !important; }
  .tempo-column { grid-template-columns: 82px 64px 1fr !important; grid-template-rows: auto auto auto !important; }
  .tempo-column .sync-button { grid-column: 3 !important; grid-row: 1 !important; }
  .tempo-column .sync-status { grid-column: 3 !important; grid-row: 2 !important; }
  .tempo-column > strong[data-role="tempo-bpm"] { grid-column: 1 !important; grid-row: 1 !important; justify-self: start !important; }
  .tempo-column > span[data-role="tempo-pct"] { grid-column: 2 !important; grid-row: 1 !important; }
  .tempo-column .range-button { display: none !important; }
  .tempo-column .vertical-slider { grid-column: 1 / -1 !important; grid-row: 3 !important; min-height: 0 !important; }
  .tempo-column .vertical-slider input { transform: none !important; width: 100% !important; }
  .platter { display: none !important; }
  .deck-tools { grid-template-rows: auto auto auto !important; }
  .loop-box { display: none !important; }
  .hotcue-grid { grid-template-columns: repeat(4, 1fr) !important; }
  .library-panel,
  .recording-panel,
  .cue-panel { display: none !important; }
}

/* v1.15 visual/UX repair pass
   Scope: layout only. Fixes broken sync/pitch column and gives the library enough
   full-width room to be usable, even when that requires page scrolling. */
:root {
  --v115-panel: #0a1017;
  --v115-panel-strong: #0d141e;
  --v115-panel-soft: #070c12;
  --v115-line: rgba(218, 234, 255, .12);
  --v115-line-soft: rgba(218, 234, 255, .075);
}

html,
body {
  min-width: 1240px !important;
  overflow-x: auto !important;
}

.app-shell {
  width: min(100%, 1920px) !important;
  max-width: 1920px !important;
  padding: 14px 16px 28px !important;
}

.main-grid {
  grid-template-columns: minmax(0, 5fr) minmax(248px, 304px) minmax(0, 5fr) !important;
  grid-template-areas:
    "deckA mixer deckB"
    "library library library"
    "rightTop rightTop rightBottom" !important;
  grid-template-rows: 505px minmax(520px, 58vh) 225px !important;
  gap: 12px !important;
  align-items: stretch !important;
}

.deck-a { grid-area: deckA !important; }
.deck-b { grid-area: deckB !important; }
.mixer { grid-area: mixer !important; }
.library-panel { grid-area: library !important; }
.recording-panel { grid-area: rightTop !important; }
.cue-panel { grid-area: rightBottom !important; }

.deck,
.mixer,
.library-panel,
.recording-panel,
.cue-panel {
  border-color: var(--v115-line) !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.030), rgba(255,255,255,.008)),
    var(--v115-panel) !important;
  box-shadow: 0 12px 30px rgba(0,0,0,.28) !important;
}

.deck {
  grid-template-rows: 42px 68px 24px minmax(0, 1fr) !important;
  padding: 12px !important;
}

.deck-header {
  grid-template-columns: 38px minmax(0, 1fr) 92px !important;
}

.wave-wrap {
  height: 68px !important;
}

.deck-feedback {
  top: 56px !important;
  left: 82px !important;
  right: 82px !important;
}

.deck-body {
  grid-template-columns: 92px minmax(250px, 1fr) 154px !important;
  gap: 11px !important;
  min-height: 0 !important;
  height: 100% !important;
}

.tempo-column {
  width: 100% !important;
  min-width: 0 !important;
  grid-template-rows: 32px 21px 24px 15px 26px minmax(0, 1fr) !important;
  gap: 6px !important;
  padding: 8px 8px 10px !important;
  border-radius: 10px !important;
  overflow: hidden !important;
}

.tempo-column .sync-button {
  width: 100% !important;
  height: 32px !important;
  min-height: 32px !important;
  padding: 0 8px !important;
  display: grid !important;
  place-items: center !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: clip !important;
  font-size: 11px !important;
  letter-spacing: .10em !important;
}

.tempo-column .sync-status {
  width: 100% !important;
  height: 21px !important;
  min-height: 21px !important;
  display: grid !important;
  place-items: center !important;
  padding: 0 5px !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
  font-size: 8px !important;
  letter-spacing: .055em !important;
  line-height: 1 !important;
}

.tempo-column > strong[data-role="tempo-bpm"] {
  height: 24px !important;
  font-size: 13px !important;
  line-height: 1 !important;
  display: grid !important;
  place-items: end center !important;
  white-space: nowrap !important;
}

.tempo-column > span[data-role="tempo-pct"] {
  height: 15px !important;
  font-size: 9.5px !important;
  white-space: nowrap !important;
}

.tempo-column .range-button {
  width: 50px !important;
  height: 26px !important;
  min-height: 26px !important;
}

.tempo-column .vertical-slider {
  min-height: 128px !important;
  padding: 2px 0 0 !important;
}

.tempo-column .vertical-slider input {
  width: 126px !important;
}

.platter-zone {
  grid-template-rows: minmax(0, 1fr) 44px !important;
  gap: 10px !important;
}

.platter {
  width: clamp(215px, 16.4vw, 292px) !important;
}

.deck-tools {
  grid-template-rows: auto auto auto 24px !important;
  gap: 7px !important;
}

.loop-box,
.hotcue-box {
  padding: 7px !important;
}

.hotcue-grid button {
  height: 29px !important;
}

.mixer {
  min-width: 248px !important;
}

.library-panel {
  min-height: 520px !important;
  height: auto !important;
  display: grid !important;
  grid-template-columns: 142px minmax(0, 1fr) !important;
  overflow: hidden !important;
}

.library-main {
  grid-template-rows: 52px 34px 38px minmax(0, 1fr) !important;
  min-width: 0 !important;
}

.panel-header {
  grid-template-columns: minmax(150px, 210px) 118px 134px 134px minmax(360px, 1fr) 64px 72px !important;
  gap: 10px !important;
  padding: 10px 12px !important;
  min-width: 0 !important;
}

.panel-header strong {
  font-size: 16px !important;
}

.search {
  min-width: 340px !important;
}

.storage-dashboard {
  padding: 8px 12px !important;
  font-size: 10.5px !important;
}

.drop-hint {
  margin: 7px 12px !important;
  padding: 8px 10px !important;
  font-size: 10.5px !important;
}

.table-wrap {
  overflow: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  border-top: 1px solid var(--v115-line-soft) !important;
}

.track-table {
  width: 100% !important;
  min-width: 1320px !important;
  table-layout: fixed !important;
  font-size: 12px !important;
}

.track-table th,
.track-table td {
  padding: 9px 11px !important;
  white-space: nowrap !important;
}

.track-table th:nth-child(1),
.track-table td:nth-child(1) { width: 42px !important; }
.track-table th:nth-child(2),
.track-table td:nth-child(2) { width: 320px !important; }
.track-table th:nth-child(3),
.track-table td:nth-child(3) { width: 210px !important; }
.track-table th:nth-child(4),
.track-table td:nth-child(4) { width: 80px !important; }
.track-table th:nth-child(5),
.track-table td:nth-child(5) { width: 80px !important; }
.track-table th:nth-child(6),
.track-table td:nth-child(6) { width: 82px !important; }
.track-table th:nth-child(7),
.track-table td:nth-child(7) { width: 110px !important; }
.track-table th:nth-child(8),
.track-table td:nth-child(8) { width: 110px !important; }
.track-table th:nth-child(9),
.track-table td:nth-child(9) { width: 190px !important; }

.track-table thead th {
  position: sticky !important;
  top: 0 !important;
  z-index: 5 !important;
}

.side-nav {
  padding: 11px !important;
}

.side-nav button {
  height: 34px !important;
}

.recording-panel,
.cue-panel {
  height: auto !important;
  min-height: 225px !important;
  overflow: hidden !important;
}

.recording-panel canvas {
  height: 64px !important;
}

.cue-meter {
  height: 34px !important;
}

@media (max-width: 1500px) {
  .app-shell { padding: 10px !important; }
  .main-grid {
    grid-template-columns: minmax(0, 5fr) minmax(232px, 276px) minmax(0, 5fr) !important;
    grid-template-rows: 500px minmax(500px, 58vh) 220px !important;
  }
  .deck-body { grid-template-columns: 86px minmax(190px, 1fr) 138px !important; }
  .tempo-column { grid-template-rows: 30px 20px 22px 14px 24px minmax(0, 1fr) !important; gap: 5px !important; }
  .tempo-column .sync-button { height: 30px !important; min-height: 30px !important; font-size: 10px !important; }
  .tempo-column .vertical-slider input { width: 112px !important; }
  .platter { width: clamp(185px, 13.5vw, 235px) !important; }
  .panel-header { grid-template-columns: minmax(135px, 180px) 108px 120px 120px minmax(280px, 1fr) 60px 68px !important; }
  .search { min-width: 270px !important; }
  .track-table { min-width: 1260px !important; }
}

@media (max-width: 1180px) {
  html, body { min-width: 0 !important; }
  .main-grid {
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
  }
  .deck-body { grid-template-columns: 88px minmax(240px,1fr) 170px !important; min-height: 430px !important; }
  .library-panel { min-height: 520px !important; }
}

/*
  v1.16 visual UX repair
  Scope: no audio/control logic changes. This pass fixes the deck tempo strip
  and gives the deck row enough height for all normal controls to sit cleanly.
*/
:root {
  --v116-deck-h: 570px;
  --v116-deck-h-mid: 545px;
  --v116-panel-bg: #0a1017;
  --v116-panel-border: rgba(126, 155, 190, .19);
  --v116-soft-line: rgba(146, 170, 205, .12);
}

.app-shell {
  max-width: 1980px !important;
}

.main-grid {
  grid-template-columns: minmax(0, 5.15fr) minmax(250px, 292px) minmax(0, 5.15fr) !important;
  grid-template-rows: var(--v116-deck-h) minmax(540px, 58vh) 225px !important;
  gap: 14px !important;
  align-items: stretch !important;
}

.deck {
  grid-template-rows: 44px 70px 24px minmax(0, 1fr) !important;
  gap: 8px !important;
  padding: 12px 13px !important;
  overflow: hidden !important;
  background:
    radial-gradient(circle at 38% 42%, rgba(47,155,255,.09), transparent 32%),
    linear-gradient(180deg, rgba(17,24,33,.95), rgba(7,12,18,.98)) !important;
  border-color: var(--v116-panel-border) !important;
}
.deck.deck-b {
  background:
    radial-gradient(circle at 58% 42%, rgba(255,140,21,.10), transparent 32%),
    linear-gradient(180deg, rgba(17,24,33,.95), rgba(7,12,18,.98)) !important;
}

.deck::before { opacity: .55 !important; }
.deck-header { grid-template-columns: 40px minmax(0, 1fr) 92px !important; gap: 10px !important; }
.deck-title h2 { font-size: 17px !important; }
.deck-title p { font-size: 11px !important; }
.deck-meta strong { font-size: 15px !important; }
.deck-meta em { font-size: 14px !important; }
.wave-wrap { height: 70px !important; }
.zoom-waveform { display: none !important; }
.time-row { height: 24px !important; }

.deck-body {
  grid-template-columns: 98px minmax(285px, 1fr) 170px !important;
  gap: 13px !important;
  min-height: 0 !important;
  height: 100% !important;
  align-items: stretch !important;
}

/* Tempo strip: remove the dead card look. Keep only intentional controls. */
.tempo-column {
  width: 98px !important;
  min-width: 98px !important;
  align-self: stretch !important;
  display: grid !important;
  grid-template-rows: 34px 20px 26px 16px 28px minmax(178px, 1fr) !important;
  gap: 5px !important;
  justify-items: center !important;
  align-items: center !important;
  padding: 2px 3px 4px !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  overflow: visible !important;
  position: relative !important;
}

.tempo-column::before {
  content: "";
  position: absolute;
  inset: 45px 13px 4px 13px;
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.008)),
    rgba(3, 7, 12, .36);
  border-left: 1px solid rgba(255,255,255,.05);
  border-right: 1px solid rgba(255,255,255,.05);
  pointer-events: none;
  z-index: 0;
}

.tempo-column > * {
  position: relative !important;
  z-index: 1 !important;
}

.tempo-column .sync-button {
  width: 96px !important;
  height: 34px !important;
  min-height: 34px !important;
  padding: 0 10px !important;
  border-radius: 7px !important;
  overflow: visible !important;
  white-space: nowrap !important;
  font-size: 11px !important;
  letter-spacing: .12em !important;
  background: linear-gradient(180deg, rgba(12,20,30,.96), rgba(8,13,20,.96)) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 5px 14px rgba(0,0,0,.18) !important;
}

.tempo-column .sync-status {
  width: 76px !important;
  height: 17px !important;
  min-height: 17px !important;
  padding: 0 5px !important;
  display: grid !important;
  place-items: center !important;
  border-radius: 5px !important;
  background: rgba(160,176,199,.095) !important;
  color: #aebaca !important;
  border: 0 !important;
  font-size: 8px !important;
  line-height: 1 !important;
  letter-spacing: .07em !important;
  text-transform: uppercase !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
}

.tempo-column .sync-primer {
  display: none !important;
}

.tempo-column > strong[data-role="tempo-bpm"] {
  width: 86px !important;
  height: 26px !important;
  display: grid !important;
  place-items: end center !important;
  font-size: 13px !important;
  line-height: 1 !important;
  font-variant-numeric: tabular-nums !important;
  white-space: nowrap !important;
  color: #f5f8fc !important;
  text-shadow: 0 0 9px rgba(255,255,255,.08) !important;
}

.tempo-column > span[data-role="tempo-pct"] {
  width: 86px !important;
  height: 16px !important;
  display: grid !important;
  place-items: center !important;
  font-size: 10px !important;
  color: #8794a6 !important;
  font-variant-numeric: tabular-nums !important;
}

.tempo-column .range-button {
  width: 54px !important;
  height: 26px !important;
  min-height: 26px !important;
  padding: 0 !important;
  border-radius: 7px !important;
  font-size: 11px !important;
  color: #d5dde8 !important;
  background: rgba(10,16,24,.82) !important;
  border-color: rgba(196,215,242,.18) !important;
}

.tempo-column .vertical-slider {
  width: 100% !important;
  min-height: 178px !important;
  height: 100% !important;
  display: grid !important;
  grid-template-rows: 12px minmax(150px, 1fr) 12px !important;
  place-items: center !important;
  padding: 0 !important;
  color: #6d7989 !important;
  overflow: visible !important;
}

.tempo-column .vertical-slider span {
  height: 12px !important;
  font-size: 9px !important;
  line-height: 12px !important;
  opacity: .75 !important;
}

.tempo-column .vertical-slider input {
  width: 174px !important;
  height: 22px !important;
  transform: rotate(-90deg) !important;
  transform-origin: center !important;
  margin: 0 !important;
  accent-color: var(--blue) !important;
}
.deck-b .tempo-column .vertical-slider input { accent-color: var(--orange) !important; }

.deck.sync-locked .tempo-column::after {
  right: 4px !important;
  bottom: 8px !important;
  border-radius: 4px !important;
  font-size: 8px !important;
  letter-spacing: .06em !important;
}

.platter-zone {
  grid-template-rows: minmax(0, 1fr) 48px !important;
  gap: 10px !important;
  min-width: 0 !important;
  align-content: center !important;
  justify-items: stretch !important;
}

.platter {
  width: clamp(255px, 17vw, 330px) !important;
  justify-self: center !important;
}

.transport-row {
  grid-template-columns: minmax(120px, 1fr) minmax(130px, 1fr) 44px !important;
  gap: 9px !important;
  align-self: end !important;
}
.transport-row button { height: 48px !important; font-size: 14px !important; }
.transport-row .set-button { font-size: 10px !important; }

.deck-tools {
  min-width: 0 !important;
  display: grid !important;
  grid-template-rows: auto auto auto 24px !important;
  gap: 8px !important;
  align-content: start !important;
  overflow: visible !important;
}

.loop-box,
.hotcue-box {
  padding: 8px !important;
  border-radius: 9px !important;
  background: rgba(3,7,11,.36) !important;
}
.loop-box label,
.hotcue-box label { font-size: 10px !important; letter-spacing: .09em !important; }
.loop-size { grid-template-columns: 38px 1fr 38px !important; }
.loop-size button,
.loop-row button,
.loop-extra-row button { height: 26px !important; }
.loop-toggle { height: 28px !important; }
.hotcue-grid { gap: 6px !important; }
.hotcue-grid button { height: 32px !important; min-height: 32px !important; }
.hotcue-hint { display: none !important; }
.deck-options { gap: 6px !important; }
.deck-options button { height: 27px !important; min-height: 27px !important; font-size: 9px !important; }

.library-panel {
  min-height: 540px !important;
}

@media (max-width: 1500px) {
  .main-grid {
    grid-template-columns: minmax(0, 5.1fr) minmax(236px, 276px) minmax(0, 5.1fr) !important;
    grid-template-rows: var(--v116-deck-h-mid) minmax(520px, 58vh) 220px !important;
    gap: 11px !important;
  }
  .deck { padding: 10px !important; }
  .deck-body { grid-template-columns: 94px minmax(220px, 1fr) 158px !important; gap: 9px !important; }
  .tempo-column { width: 94px !important; min-width: 94px !important; }
  .tempo-column .sync-button { width: 92px !important; font-size: 10px !important; letter-spacing: .10em !important; }
  .tempo-column .vertical-slider input { width: 158px !important; }
  .platter { width: clamp(230px, 15.2vw, 285px) !important; }
  .deck-tools { gap: 7px !important; }
  .hotcue-grid button { height: 29px !important; }
  .transport-row { grid-template-columns: minmax(100px, 1fr) minmax(110px, 1fr) 40px !important; }
}

@media (max-width: 1180px) {
  .main-grid {
    grid-template-columns: 1fr !important;
    grid-template-rows: none !important;
  }
  .deck { min-height: 0 !important; }
  .deck-body {
    grid-template-columns: 98px minmax(260px, 1fr) 170px !important;
    height: auto !important;
    min-height: 480px !important;
  }
}

@media (max-width: 760px) {
  .deck-body {
    grid-template-columns: 1fr !important;
    min-height: 0 !important;
  }
  .tempo-column {
    width: 100% !important;
    min-width: 0 !important;
    grid-template-columns: 88px 72px 1fr !important;
    grid-template-rows: auto auto auto !important;
    gap: 8px !important;
    padding: 0 !important;
  }
  .tempo-column::before { display: none !important; }
  .tempo-column .sync-button { grid-column: 3 !important; grid-row: 1 !important; width: 100% !important; }
  .tempo-column .sync-status { grid-column: 3 !important; grid-row: 2 !important; width: 100% !important; }
  .tempo-column > strong[data-role="tempo-bpm"] { grid-column: 1 !important; grid-row: 1 !important; width: auto !important; justify-self: start !important; }
  .tempo-column > span[data-role="tempo-pct"] { grid-column: 2 !important; grid-row: 1 !important; width: auto !important; }
  .tempo-column .range-button { display: none !important; }
  .tempo-column .vertical-slider { grid-column: 1 / -1 !important; grid-row: 3 !important; min-height: 0 !important; }
  .tempo-column .vertical-slider input { width: 100% !important; transform: none !important; }
}

/*
  v1.17 target UX pass
  Purpose: restore the useful beat-grid strip, remove top-bar practice selector,
  keep bottom-right deck mode buttons visible, and fix active sync contrast.
*/
.topbar {
  grid-template-columns: minmax(210px, auto) 1fr auto auto !important;
  min-height: 62px !important;
  padding: 10px 16px !important;
}
.session-select { display: none !important; }
.status-strip { justify-content: flex-end !important; }

.main-grid {
  grid-template-rows: 635px minmax(540px, 58vh) 225px !important;
}

.deck {
  height: auto !important;
  min-height: 0 !important;
  display: grid !important;
  grid-template-rows: 42px 72px 36px 24px minmax(0, 1fr) !important;
  gap: 8px !important;
  padding: 12px 13px !important;
  overflow: hidden !important;
}
.deck-header { grid-row: 1 !important; }
.wave-wrap { grid-row: 2 !important; height: 72px !important; margin: 0 !important; }
.zoom-waveform {
  grid-row: 3 !important;
  display: block !important;
  width: 100% !important;
  height: 36px !important;
  margin: 0 !important;
  border: 1px solid rgba(122,151,184,.18) !important;
  border-radius: 8px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.025), rgba(0,0,0,.10)),
    rgba(3, 7, 12, .60) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.035) !important;
  cursor: ew-resize !important;
}
.time-row { grid-row: 4 !important; height: 24px !important; margin: 0 !important; }
.deck-body {
  grid-row: 5 !important;
  grid-template-columns: 98px minmax(285px, 1fr) 170px !important;
  gap: 13px !important;
  height: 100% !important;
  min-height: 0 !important;
}

/* Make the sync/pitch lane intentional rather than a visual dead zone. */
.tempo-column {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 0 3px 2px !important;
  width: 98px !important;
  min-width: 98px !important;
  grid-template-rows: 34px 18px 26px 16px 28px minmax(182px, 1fr) !important;
  gap: 6px !important;
  overflow: visible !important;
}
.tempo-column::before {
  inset: 44px 16px 0 16px !important;
  border-radius: 999px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.030), rgba(255,255,255,.006)),
    rgba(4, 8, 14, .32) !important;
  border: 1px solid rgba(138,160,190,.065) !important;
  border-top-color: rgba(138,160,190,.10) !important;
  border-bottom-color: rgba(138,160,190,.035) !important;
}
.tempo-column .sync-button {
  width: 96px !important;
  height: 34px !important;
  min-height: 34px !important;
  display: grid !important;
  place-items: center !important;
  overflow: visible !important;
  white-space: nowrap !important;
  text-overflow: unset !important;
  padding: 0 8px !important;
  color: #9bd8ff !important;
  background: linear-gradient(180deg, rgba(11,19,29,.98), rgba(7,12,19,.98)) !important;
  border-color: rgba(47,155,255,.52) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 5px 15px rgba(0,0,0,.22) !important;
  text-shadow: none !important;
}
.deck-b .tempo-column .sync-button {
  color: #ffc37f !important;
  border-color: rgba(255,140,21,.52) !important;
}
.tempo-column .sync-button.active,
.sync-button.active {
  color: #ecfff0 !important;
  background: linear-gradient(180deg, rgba(45,132,49,.96), rgba(16,83,29,.96)) !important;
  border-color: rgba(99,212,84,.92) !important;
  box-shadow: 0 0 0 1px rgba(99,212,84,.18), 0 0 18px rgba(99,212,84,.28), inset 0 1px 0 rgba(255,255,255,.16) !important;
  text-shadow: 0 1px 1px rgba(0,0,0,.55) !important;
}
.tempo-column .sync-button.active:hover,
.sync-button.active:hover { color: #fff !important; }
.tempo-column .sync-status {
  width: 76px !important;
  color: #b9c7d8 !important;
  background: rgba(137,157,187,.105) !important;
  border: 0 !important;
  opacity: 1 !important;
}
.tempo-column > strong[data-role="tempo-bpm"] { color: #f4f8fe !important; }
.tempo-column .range-button { width: 54px !important; }
.tempo-column .vertical-slider { min-height: 184px !important; }
.tempo-column .vertical-slider input { width: 176px !important; }

/* Keep the normal mode buttons visible on the deck surface. */
.deck-options {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 6px !important;
  min-height: 30px !important;
}
.deck-options button {
  height: 30px !important;
  min-height: 30px !important;
  padding: 0 4px !important;
  font-size: 9.5px !important;
  letter-spacing: .04em !important;
  font-weight: 900 !important;
}
.deck-tools {
  grid-template-rows: auto auto 30px 26px !important;
  gap: 8px !important;
  overflow: visible !important;
}

@media (max-width: 1500px) {
  .main-grid { grid-template-rows: 600px minmax(520px, 58vh) 220px !important; }
  .deck { grid-template-rows: 40px 68px 32px 22px minmax(0, 1fr) !important; gap: 7px !important; }
  .wave-wrap { height: 68px !important; }
  .zoom-waveform { height: 32px !important; }
  .deck-body { grid-template-columns: 94px minmax(230px, 1fr) 158px !important; gap: 10px !important; }
  .tempo-column { width: 94px !important; min-width: 94px !important; }
  .tempo-column .sync-button { width: 92px !important; }
  .tempo-column .vertical-slider input { width: 160px !important; }
}

@media (max-width: 760px) {
  .topbar { grid-template-columns: 1fr auto !important; }
  .deck { grid-template-rows: 38px 64px 30px 22px auto !important; }
  .zoom-waveform { display: block !important; height: 30px !important; }
  .deck-body { grid-template-columns: 1fr !important; }
  .tempo-column {
    width: 100% !important;
    min-width: 0 !important;
    grid-template-columns: 88px 72px 1fr !important;
    grid-template-rows: auto auto auto !important;
    padding: 0 !important;
  }
  .tempo-column::before { display: none !important; }
  .tempo-column .sync-button { grid-column: 3 !important; grid-row: 1 !important; width: 100% !important; }
  .tempo-column .sync-status { grid-column: 3 !important; grid-row: 2 !important; width: 100% !important; }
  .tempo-column .vertical-slider input { width: 100% !important; transform: none !important; }
}

/*
  v1.18 emergency visual repair
  Scope: fix the v1.17 platter overlap/regression and clean the tempo lane.
  This block intentionally overrides the accumulated historical layout tweaks above.
*/
:root {
  --v118-top-row: 620px;
  --v118-deck-header: 44px;
  --v118-wave: 68px;
  --v118-grid: 30px;
  --v118-time: 22px;
  --v118-body: 430px;
  --v118-gap: 8px;
}

.topbar {
  grid-template-columns: minmax(210px, auto) 1fr auto auto !important;
  min-height: 58px !important;
  padding: 10px 16px !important;
}
.session-select { display: none !important; }
.status-strip { justify-content: flex-end !important; }

.main-grid {
  display: grid !important;
  width: 100% !important;
  max-width: none !important;
  grid-template-columns: minmax(0, 5.05fr) minmax(245px, 292px) minmax(0, 5.05fr) !important;
  grid-template-areas:
    "deckA mixer deckB"
    "library library library"
    "rightTop rightTop rightBottom" !important;
  grid-template-rows: var(--v118-top-row) minmax(540px, 60vh) 230px !important;
  gap: 14px !important;
  align-items: stretch !important;
}

.deck-a { grid-area: deckA !important; }
.mixer { grid-area: mixer !important; }
.deck-b { grid-area: deckB !important; }
.library-panel { grid-area: library !important; }
.recording-panel { grid-area: rightTop !important; }
.cue-panel { grid-area: rightBottom !important; }

.deck {
  height: var(--v118-top-row) !important;
  min-height: var(--v118-top-row) !important;
  max-height: var(--v118-top-row) !important;
  display: grid !important;
  grid-template-rows: var(--v118-deck-header) var(--v118-wave) var(--v118-grid) var(--v118-time) minmax(0, 1fr) !important;
  gap: var(--v118-gap) !important;
  padding: 12px 14px !important;
  overflow: hidden !important;
  isolation: isolate !important;
}
.deck-header {
  grid-row: 1 !important;
  min-height: 0 !important;
  grid-template-columns: 42px minmax(0,1fr) 96px !important;
  gap: 12px !important;
}
.deck-badge { width: 38px !important; height: 38px !important; font-size: 18px !important; }
.track-title-block h2 { font-size: 18px !important; line-height: 1.05 !important; }
.track-title-block p { font-size: 12px !important; }
.deck-meta strong { font-size: 15px !important; }
.deck-meta span { font-size: 9px !important; }
.deck-meta em { font-size: 14px !important; }

.deck-feedback {
  position: absolute !important;
  top: 62px !important;
  left: 82px !important;
  right: 82px !important;
  z-index: 5 !important;
  height: 16px !important;
  min-height: 0 !important;
  margin: 0 !important;
  pointer-events: none !important;
  border-radius: 999px !important;
  background: rgba(3,7,11,.78) !important;
  border: 1px solid rgba(180,205,235,.08) !important;
  color: rgba(230,242,255,.62) !important;
  font-size: 8px !important;
  letter-spacing: .14em !important;
}

.wave-wrap {
  grid-row: 2 !important;
  height: var(--v118-wave) !important;
  min-height: var(--v118-wave) !important;
  margin: 0 !important;
  border-radius: 8px !important;
  overflow: hidden !important;
  z-index: 2 !important;
}
.zoom-waveform {
  grid-row: 3 !important;
  display: block !important;
  width: 100% !important;
  height: var(--v118-grid) !important;
  min-height: var(--v118-grid) !important;
  margin: 0 !important;
  border-radius: 7px !important;
  border: 1px solid rgba(120,150,185,.16) !important;
  background: rgba(2,6,11,.68) !important;
  cursor: ew-resize !important;
  z-index: 2 !important;
}
.time-row {
  grid-row: 4 !important;
  height: var(--v118-time) !important;
  min-height: var(--v118-time) !important;
  margin: 0 !important;
  align-items: center !important;
  z-index: 2 !important;
}
.time-row time { font-size: 12px !important; }
.progress-rail { height: 6px !important; }

.deck-body {
  grid-row: 5 !important;
  display: grid !important;
  grid-template-columns: 92px minmax(260px, 1fr) 168px !important;
  gap: 12px !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: hidden !important;
  align-items: stretch !important;
  z-index: 1 !important;
}

/* Clean tempo strip: no fake card, no ghost background. */
.tempo-column {
  position: relative !important;
  display: grid !important;
  width: 92px !important;
  min-width: 92px !important;
  height: 100% !important;
  min-height: 0 !important;
  grid-template-rows: 32px 18px 20px 14px 24px minmax(0,1fr) !important;
  gap: 6px !important;
  align-items: center !important;
  justify-items: center !important;
  padding: 0 2px !important;
  overflow: hidden !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}
.tempo-column::before,
.tempo-column::after { display: none !important; content: none !important; }
.tempo-column .sync-button {
  width: 88px !important;
  height: 32px !important;
  min-height: 32px !important;
  padding: 0 8px !important;
  display: grid !important;
  place-items: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: clip !important;
  font-size: 10px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
  letter-spacing: .10em !important;
  color: #9bd8ff !important;
  background: linear-gradient(180deg, rgba(9,17,27,.95), rgba(5,10,17,.95)) !important;
  border: 1px solid rgba(47,155,255,.52) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055) !important;
}
.deck-b .tempo-column .sync-button {
  color: #ffc37f !important;
  border-color: rgba(255,140,21,.54) !important;
}
.tempo-column .sync-button.active,
.sync-button.active {
  color: #f7fff6 !important;
  background: linear-gradient(180deg, rgba(42,147,54,.98), rgba(18,91,35,.98)) !important;
  border-color: rgba(108,231,98,.92) !important;
  text-shadow: 0 1px 1px rgba(0,0,0,.65) !important;
  box-shadow: 0 0 0 1px rgba(108,231,98,.18), 0 0 18px rgba(108,231,98,.23), inset 0 1px 0 rgba(255,255,255,.16) !important;
}
.tempo-column .sync-status {
  width: 76px !important;
  max-width: 76px !important;
  height: 18px !important;
  min-height: 18px !important;
  display: grid !important;
  place-items: center !important;
  color: rgba(218,228,240,.76) !important;
  background: rgba(120,144,172,.11) !important;
  border: 0 !important;
  border-radius: 999px !important;
  font-size: 8px !important;
  line-height: 1 !important;
  letter-spacing: .08em !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  opacity: 1 !important;
}
.tempo-column .sync-primer { display: none !important; }
.tempo-column > strong[data-role="tempo-bpm"] {
  height: 20px !important;
  font-size: 13px !important;
  line-height: 20px !important;
  color: #f4f8fe !important;
  font-variant-numeric: tabular-nums !important;
}
.tempo-column > span[data-role="tempo-pct"] {
  height: 14px !important;
  font-size: 10px !important;
  line-height: 14px !important;
  color: rgba(210,222,236,.68) !important;
}
.tempo-column .range-button {
  width: 52px !important;
  height: 24px !important;
  min-height: 24px !important;
  padding: 0 !important;
  font-size: 10px !important;
  border-radius: 7px !important;
}
.tempo-column .vertical-slider {
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  display: grid !important;
  grid-template-rows: 12px minmax(0,1fr) 12px !important;
  place-items: center !important;
  overflow: hidden !important;
  color: rgba(210,222,236,.55) !important;
}
.tempo-column .vertical-slider span {
  height: 12px !important;
  font-size: 9px !important;
  line-height: 12px !important;
}
.tempo-column .vertical-slider input {
  width: 178px !important;
  max-width: 178px !important;
  transform: rotate(-90deg) !important;
  accent-color: var(--blue) !important;
}
.deck-b .tempo-column .vertical-slider input { accent-color: var(--orange) !important; }

.platter-zone {
  display: grid !important;
  grid-template-rows: minmax(0, 1fr) 48px !important;
  gap: 10px !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: hidden !important;
  align-items: center !important;
  justify-items: stretch !important;
}
.platter {
  width: clamp(235px, 15.5vw, 300px) !important;
  max-width: calc(100% - 8px) !important;
  max-height: calc(100% - 8px) !important;
  align-self: center !important;
  justify-self: center !important;
  z-index: 1 !important;
}
.transport-row {
  width: 100% !important;
  min-height: 48px !important;
  height: 48px !important;
  display: grid !important;
  grid-template-columns: minmax(105px, 1fr) minmax(135px, 1fr) 42px !important;
  gap: 8px !important;
  z-index: 2 !important;
}
.transport-row button { height: 48px !important; min-height: 48px !important; font-size: 14px !important; }
.set-button { font-size: 10px !important; }

.deck-tools {
  display: grid !important;
  grid-template-rows: auto auto 30px 26px !important;
  gap: 8px !important;
  min-height: 0 !important;
  overflow: hidden !important;
}
.loop-box,
.hotcue-box {
  padding: 8px !important;
  border-radius: 9px !important;
  background: rgba(3,7,11,.36) !important;
}
.loop-box label,
.hotcue-box label { font-size: 10px !important; margin-bottom: 6px !important; }
.loop-size { grid-template-columns: 36px 1fr 36px !important; }
.loop-size button,
.loop-row button,
.loop-extra-row button { height: 25px !important; min-height: 25px !important; font-size: 9px !important; }
.loop-toggle { height: 27px !important; min-height: 27px !important; }
.hotcue-grid { gap: 6px !important; }
.hotcue-grid button { height: 31px !important; min-height: 31px !important; }
.deck-options {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0,1fr)) !important;
  gap: 6px !important;
  min-height: 30px !important;
}
.deck-options button { height: 30px !important; min-height: 30px !important; font-size: 9px !important; padding: 0 3px !important; }

.mixer {
  height: var(--v118-top-row) !important;
  min-height: var(--v118-top-row) !important;
  max-height: var(--v118-top-row) !important;
  padding: 12px !important;
  overflow: hidden !important;
}

.library-panel { min-height: 540px !important; }

@media (max-width: 1500px) {
  :root {
    --v118-top-row: 590px;
    --v118-wave: 64px;
    --v118-grid: 28px;
  }
  .main-grid {
    grid-template-columns: minmax(0, 5fr) minmax(230px, 275px) minmax(0, 5fr) !important;
    gap: 11px !important;
  }
  .deck { padding: 10px !important; }
  .deck-body { grid-template-columns: 88px minmax(220px, 1fr) 156px !important; gap: 9px !important; }
  .tempo-column { width: 88px !important; min-width: 88px !important; }
  .tempo-column .sync-button { width: 86px !important; font-size: 9.5px !important; letter-spacing: .08em !important; }
  .tempo-column .vertical-slider input { width: 164px !important; }
  .platter { width: clamp(210px, 14.8vw, 270px) !important; }
  .deck-tools { gap: 7px !important; }
  .hotcue-grid button { height: 29px !important; min-height: 29px !important; }
  .transport-row { grid-template-columns: minmax(95px, 1fr) minmax(120px, 1fr) 40px !important; }
}

@media (max-width: 1180px) {
  .main-grid {
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
  }
  .deck, .mixer {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }
  .deck-body {
    grid-template-columns: 92px minmax(260px, 1fr) 168px !important;
    height: 430px !important;
  }
  .platter { width: min(285px, 40vw) !important; }
}

@media (max-width: 760px) {
  .topbar { grid-template-columns: 1fr auto !important; }
  .deck {
    grid-template-rows: 38px 62px 28px 22px auto !important;
  }
  .deck-body {
    grid-template-columns: 1fr !important;
    height: auto !important;
    overflow: visible !important;
  }
  .tempo-column {
    width: 100% !important;
    min-width: 0 !important;
    grid-template-columns: 82px 64px 1fr !important;
    grid-template-rows: auto auto auto !important;
    gap: 7px !important;
    padding: 0 !important;
    overflow: visible !important;
  }
  .tempo-column .sync-button { grid-column: 3 !important; grid-row: 1 !important; width: 100% !important; }
  .tempo-column .sync-status { grid-column: 3 !important; grid-row: 2 !important; width: 100% !important; max-width: none !important; }
  .tempo-column > strong[data-role="tempo-bpm"] { grid-column: 1 !important; grid-row: 1 !important; }
  .tempo-column > span[data-role="tempo-pct"] { grid-column: 2 !important; grid-row: 1 !important; }
  .tempo-column .range-button { display: none !important; }
  .tempo-column .vertical-slider { grid-column: 1 / -1 !important; grid-row: 3 !important; }
  .tempo-column .vertical-slider input { width: 100% !important; max-width: none !important; transform: none !important; }
  .platter { display: none !important; }
  .platter-zone { overflow: visible !important; }
}

/* v1.19 final deck-area fix
   Scope: deck visual layout only. Align the tempo fader with the sync/BPM stack,
   remove the last visible hot-cue row, and make room for the normal deck controls.
*/
:root {
  --v119-top-row: 625px;
  --v119-deck-tool-col: 168px;
  --v119-tempo-col: 104px;
}

.main-grid {
  grid-template-rows: var(--v119-top-row) auto auto !important;
}
.deck {
  height: var(--v119-top-row) !important;
  min-height: var(--v119-top-row) !important;
  max-height: var(--v119-top-row) !important;
  overflow: hidden !important;
}
.mixer {
  height: var(--v119-top-row) !important;
  min-height: var(--v119-top-row) !important;
  max-height: var(--v119-top-row) !important;
}
.deck-body {
  grid-template-columns: var(--v119-tempo-col) minmax(270px, 1fr) var(--v119-deck-tool-col) !important;
  gap: 12px !important;
  overflow: hidden !important;
}

.tempo-column {
  width: var(--v119-tempo-col) !important;
  min-width: var(--v119-tempo-col) !important;
  padding: 0 !important;
  overflow: visible !important;
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
  isolation: isolate !important;
}
.tempo-column::before,
.tempo-column::after { display: none !important; content: none !important; }
.tempo-column .sync-button {
  width: 96px !important;
  max-width: 96px !important;
  justify-self: center !important;
}
.tempo-column .sync-status {
  width: 84px !important;
  max-width: 84px !important;
  justify-self: center !important;
}
.tempo-column > strong[data-role="tempo-bpm"],
.tempo-column > span[data-role="tempo-pct"],
.tempo-column .range-button {
  justify-self: center !important;
}
.tempo-column .vertical-slider {
  overflow: visible !important;
  justify-self: center !important;
  width: 74px !important;
  max-width: 74px !important;
  transform: translateX(-12px) !important;
}
.tempo-column .vertical-slider input {
  width: 188px !important;
  max-width: 188px !important;
  transform: rotate(-90deg) !important;
  transform-origin: center center !important;
}
.tempo-column .vertical-slider span {
  width: 100% !important;
  text-align: center !important;
}

.deck-tools {
  grid-template-rows: auto auto 32px 26px !important;
  gap: 7px !important;
  overflow: hidden !important;
}
.hotcue-box {
  padding: 8px !important;
}
.hotcue-grid {
  grid-template-columns: repeat(2, minmax(0,1fr)) !important;
  grid-template-rows: repeat(3, 31px) !important;
  gap: 6px !important;
}
.hotcue-grid button {
  height: 31px !important;
  min-height: 31px !important;
}
.hotcue-grid [data-hotcue="6"],
.hotcue-grid [data-hotcue="7"] {
  display: none !important;
}
.hotcue-hint {
  display: none !important;
}
.deck-options {
  min-height: 32px !important;
  height: 32px !important;
  align-self: end !important;
}
.deck-options button {
  height: 32px !important;
  min-height: 32px !important;
}

.platter-zone {
  grid-template-rows: minmax(0, 1fr) 50px !important;
  gap: 10px !important;
}
.transport-row {
  height: 50px !important;
  min-height: 50px !important;
}
.transport-row button {
  height: 50px !important;
  min-height: 50px !important;
}
.platter {
  width: clamp(245px, 15.5vw, 310px) !important;
}

@media (max-width: 1500px) {
  :root {
    --v119-top-row: 610px;
    --v119-tempo-col: 100px;
    --v119-deck-tool-col: 158px;
  }
  .deck-body {
    grid-template-columns: var(--v119-tempo-col) minmax(235px, 1fr) var(--v119-deck-tool-col) !important;
    gap: 10px !important;
  }
  .tempo-column .sync-button { width: 92px !important; max-width: 92px !important; }
  .tempo-column .vertical-slider { transform: translateX(-10px) !important; }
  .tempo-column .vertical-slider input { width: 178px !important; max-width: 178px !important; }
  .platter { width: clamp(220px, 14.5vw, 285px) !important; }
}

@media (max-width: 1180px) {
  .deck,
  .mixer {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }
  .deck-body {
    grid-template-columns: 100px minmax(260px, 1fr) 168px !important;
    height: 455px !important;
  }
}

@media (max-width: 760px) {
  .deck-body {
    grid-template-columns: 1fr !important;
    height: auto !important;
    overflow: visible !important;
  }
  .tempo-column {
    width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
  }
  .tempo-column .vertical-slider {
    width: 100% !important;
    max-width: none !important;
    transform: none !important;
  }
  .tempo-column .vertical-slider input {
    width: 100% !important;
    max-width: none !important;
    transform: none !important;
  }
}

/* v1.20 targeted pitch-lane alignment
   Scope: deck visual layout only. The previous rotated range input was visually
   drifting toward the platter side of the tempo lane. This makes the fader rail
   explicitly centered in the tempo column so it lines up with SYNC, state, BPM,
   percent, and range controls without clipping against the platter area.
*/
.tempo-column .vertical-slider {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  min-height: 190px !important;
  height: 190px !important;
  justify-self: stretch !important;
  align-self: stretch !important;
  transform: none !important;
  overflow: visible !important;
}
.tempo-column .vertical-slider input[type="range"] {
  position: absolute !important;
  left: 48% !important;
  top: 50% !important;
  width: 178px !important;
  max-width: 178px !important;
  transform: translate(-50%, -50%) rotate(-90deg) !important;
  transform-origin: center center !important;
  margin: 0 !important;
}
.tempo-column .vertical-slider span {
  position: absolute !important;
  left: 48% !important;
  width: 18px !important;
  transform: translateX(-50%) !important;
  text-align: center !important;
  pointer-events: none !important;
}
.tempo-column .vertical-slider span:first-child { top: 0 !important; }
.tempo-column .vertical-slider span:last-child { bottom: 0 !important; }

@media (max-width: 1500px) {
  .tempo-column .vertical-slider { min-height: 182px !important; height: 182px !important; }
  .tempo-column .vertical-slider input[type="range"] { width: 170px !important; max-width: 170px !important; left: 48% !important; }
  .tempo-column .vertical-slider span { left: 48% !important; }
}

/* v1.21 CDJ-standard key/phase/cue-prep pass
   Scope: UI support for standard CDJ behaviors: MT, Key Shift, Key Sync,
   phase awareness, and paused frame search. */
.tempo-column {
  grid-template-rows: 38px auto auto 16px 32px auto 1fr !important;
  gap: 6px !important;
}
.phase-meter {
  width: 82px;
  height: 12px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 99px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(90deg, rgba(255,255,255,.04), rgba(255,255,255,.08), rgba(255,255,255,.04));
}
.phase-meter span {
  position: absolute;
  top: 1px;
  bottom: 1px;
  left: 50%;
  width: 1px;
  background: rgba(255,255,255,.42);
}
.phase-meter i {
  --phase-offset: 0px;
  position: absolute;
  top: 2px;
  left: calc(50% + var(--phase-offset));
  width: 8px;
  height: 8px;
  border-radius: 50%;
  transform: translateX(-50%);
  background: var(--blue);
  box-shadow: 0 0 10px rgba(47,155,255,.7);
}
.deck-b .phase-meter i {
  background: var(--orange);
  box-shadow: 0 0 10px rgba(255,140,21,.7);
}
.deck:not(.sync-locked) .phase-meter { opacity: .42; }
.platter-zone {
  grid-template-rows: minmax(0, 1fr) 50px 28px !important;
  align-content: stretch;
}
@media (max-width: 1500px) {
  .phase-meter { width: 78px; }
}
@media (max-width: 760px) {
  .phase-meter { display: none; }
}
.memory-row { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.grid-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 48px !important;
  gap: 7px !important;
  align-items: center !important;
}

/* Channel cue buttons need a club-mixer-style lamp state. Off is deliberately
   subdued; on is filled and readable so the cue send cannot be mistaken. */
.channel-cue {
  position: relative !important;
  color: rgba(168,181,197,.72) !important;
  border-color: rgba(168,181,197,.22) !important;
  background: rgba(2,6,10,.55) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.035) !important;
  opacity: .72 !important;
}
.channel-cue::after {
  content: "";
  position: absolute;
  right: 7px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  transform: translateY(-50%);
  background: rgba(118,130,146,.45);
  box-shadow: none;
}
.channel-cue.active,
.channel-cue[aria-pressed="true"] {
  color: #f6fbff !important;
  border-color: rgba(99,212,84,.78) !important;
  background: linear-gradient(180deg, rgba(54,151,61,.95), rgba(18,86,30,.96)) !important;
  box-shadow: 0 0 20px rgba(99,212,84,.25), inset 0 1px 0 rgba(255,255,255,.16) !important;
  opacity: 1 !important;
}
.channel-cue.active::after,
.channel-cue[aria-pressed="true"]::after {
  background: #63d454;
  box-shadow: 0 0 10px rgba(99,212,84,.85);
}
.deck-a-accent.channel-cue.active,
.deck-a-accent.channel-cue[aria-pressed="true"] {
  border-color: rgba(47,155,255,.86) !important;
  background: linear-gradient(180deg, rgba(47,155,255,.82), rgba(20,83,145,.9)) !important;
  box-shadow: 0 0 20px rgba(47,155,255,.26), inset 0 1px 0 rgba(255,255,255,.16) !important;
}
.deck-b-accent.channel-cue.active,
.deck-b-accent.channel-cue[aria-pressed="true"] {
  border-color: rgba(255,140,21,.88) !important;
  background: linear-gradient(180deg, rgba(255,140,21,.86), rgba(143,67,8,.94)) !important;
  box-shadow: 0 0 20px rgba(255,140,21,.26), inset 0 1px 0 rgba(255,255,255,.16) !important;
}

@media (max-width: 760px) {
  #settingsButton { display: none !important; }
}

/* v1.30 library bulk actions and import progress */
.library-main {
  grid-template-rows: auto auto auto auto minmax(0, 1fr) !important;
}

.panel-header {
  grid-template-columns: minmax(140px, 190px) 116px 132px 130px minmax(260px, 1fr) 150px 72px minmax(76px, auto) !important;
  align-items: center !important;
}

#importProgress.import-progress {
  margin: 7px 12px 0 !important;
  padding: 8px 10px !important;
  border: 1px solid rgba(143, 208, 255, .22) !important;
  border-radius: 10px !important;
  background: rgba(47, 155, 255, .075) !important;
}

#importProgress[hidden] {
  display: none !important;
}

.import-progress-copy {
  display: flex !important;
  justify-content: space-between !important;
  gap: 12px !important;
  color: rgba(235, 243, 255, .82) !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
}

.import-progress-copy strong {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.import-progress-copy span {
  color: rgba(143, 208, 255, .86) !important;
  font-variant-numeric: tabular-nums !important;
}

.import-progress-rail {
  height: 7px !important;
  margin-top: 7px !important;
  overflow: hidden !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, .08) !important;
}

.import-progress-rail span {
  display: block !important;
  width: 0%;
  height: 100% !important;
  border-radius: inherit !important;
  background: linear-gradient(90deg, rgba(47, 155, 255, .88), rgba(99, 212, 84, .9)) !important;
  transition: width 140ms linear !important;
}

#bulkRemoveTracks[disabled] {
  opacity: .45 !important;
  cursor: not-allowed !important;
}

.track-table {
  min-width: 1440px !important;
}

.track-table th:nth-child(1),
.track-table td:nth-child(1) { width: 44px !important; text-align: center !important; }
.track-table th:nth-child(2),
.track-table td:nth-child(2) { width: 48px !important; }
.track-table th:nth-child(3),
.track-table td:nth-child(3) { width: 330px !important; }
.track-table th:nth-child(4),
.track-table td:nth-child(4) { width: 210px !important; }
.track-table th:nth-child(5),
.track-table td:nth-child(5) { width: 82px !important; }
.track-table th:nth-child(6),
.track-table td:nth-child(6) { width: 80px !important; }
.track-table th:nth-child(7),
.track-table td:nth-child(7) { width: 88px !important; }
.track-table th:nth-child(8),
.track-table td:nth-child(8) { width: 112px !important; }
.track-table th:nth-child(9),
.track-table td:nth-child(9) { width: 112px !important; }
.track-table th:nth-child(10),
.track-table td:nth-child(10) { width: 198px !important; }

.select-cell input,
#selectAllTracks {
  width: 16px !important;
  height: 16px !important;
  accent-color: #8fd0ff !important;
  cursor: pointer !important;
}

.track-table tr.bulk-selected {
  background: rgba(99, 212, 84, .105) !important;
}

.track-table tr.selected.bulk-selected {
  background: linear-gradient(90deg, rgba(47, 155, 255, .14), rgba(99, 212, 84, .11)) !important;
}

@media (max-width: 1500px) {
  .panel-header {
    grid-template-columns: minmax(125px, 172px) 106px 118px 118px minmax(230px, 1fr) 136px 66px minmax(70px, auto) !important;
    gap: 8px !important;
  }
  .search { min-width: 235px !important; }
  .track-table { min-width: 1380px !important; }
}

@media (max-width: 1180px) {
  .panel-header {
    grid-template-columns: 1fr 1fr !important;
  }
  .panel-header .search,
  .panel-header #trackCount {
    grid-column: 1 / -1 !important;
  }
}

/* v1.33 focused CDJ-style control pass and editable library metadata */
.master-button {
  width: 100% !important;
  min-height: 28px !important;
  border: 1px solid rgba(255, 213, 78, .28) !important;
  border-radius: 7px !important;
  color: rgba(255, 213, 78, .78) !important;
  background: rgba(255, 213, 78, .055) !important;
  font-size: 10px !important;
  letter-spacing: .08em !important;
}

.master-button.active {
  color: #ffd54e !important;
  border-color: rgba(255, 213, 78, .82) !important;
  box-shadow: 0 0 16px rgba(255, 213, 78, .16) !important;
}

.deck-stepper .stepper-row {
  grid-template-columns: 32px minmax(80px, 1fr) 32px !important;
  align-items: center !important;
}

.track-table [contenteditable="true"] {
  min-width: 90px !important;
  cursor: text !important;
  border-radius: 7px !important;
  outline: 1px solid transparent !important;
  outline-offset: -2px !important;
}

.track-table [contenteditable="true"]:hover {
  background: rgba(255,255,255,.045) !important;
}

.track-table [contenteditable="true"]:focus {
  background: rgba(143,208,255,.09) !important;
  outline-color: rgba(143,208,255,.34) !important;
  color: #f4f9ff !important;
}

.track-table td[data-cell="note"] {
  color: rgba(225,236,248,.74) !important;
  max-width: 260px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.track-table td[data-cell="note"]:empty::before {
  content: "add note";
  color: rgba(154,176,197,.46);
}

.track-table { min-width: 1640px !important; }
.track-table th:nth-child(5),
.track-table td:nth-child(5) { width: 260px !important; }
.track-table th:nth-child(6),
.track-table td:nth-child(6) { width: 82px !important; }
.track-table th:nth-child(7),
.track-table td:nth-child(7) { width: 80px !important; }
.track-table th:nth-child(8),
.track-table td:nth-child(8) { width: 88px !important; }
.track-table th:nth-child(9),
.track-table td:nth-child(9) { width: 112px !important; }
.track-table th:nth-child(10),
.track-table td:nth-child(10) { width: 112px !important; }
.track-table th:nth-child(11),
.track-table td:nth-child(11) { width: 198px !important; }

.grid-panel {
  display: grid;
  grid-template-columns: minmax(96px, 0.78fr) 2.2fr;
  gap: 8px;
  align-items: stretch;
  margin-top: 8px;
  padding: 7px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 9px;
  background: rgba(255,255,255,.026);
}
.grid-readout {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 0;
  padding: 5px 7px;
  border-radius: 7px;
  background: rgba(0,0,0,.20);
  border: 1px solid rgba(255,255,255,.06);
}
.grid-readout strong {
  color: #f4f8fe;
  font-size: 10px;
  letter-spacing: .09em;
  text-transform: uppercase;
  white-space: nowrap;
}
.grid-readout span {
  color: rgba(224,236,248,.62);
  font-size: 9px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.grid-actions {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 4px;
}
.grid-actions button {
  min-width: 0;
  min-height: 25px;
  padding: 0 4px;
  border-radius: 7px;
  border: 1px solid rgba(255,255,255,.11);
  background: rgba(255,255,255,.04);
  color: rgba(231,239,250,.86);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .03em;
  cursor: pointer;
}
.grid-actions button:hover,
.grid-actions button:focus-visible {
  border-color: rgba(143,208,255,.54);
  color: #fff;
  background: rgba(47,155,255,.14);
}
.deck-b .grid-actions button:hover,
.deck-b .grid-actions button:focus-visible {
  border-color: rgba(255,192,124,.54);
  background: rgba(255,140,21,.14);
}
.deck.grid-review .grid-readout {
  border-color: rgba(255,213,78,.35);
  box-shadow: 0 0 14px rgba(255,213,78,.08);
}
.deck.grid-weak .grid-readout {
  border-color: rgba(255,67,84,.42);
  box-shadow: 0 0 14px rgba(255,67,84,.10);
}
.deck.grid-locked .grid-readout {
  border-color: rgba(99,212,84,.42);
  box-shadow: 0 0 14px rgba(99,212,84,.10);
}
.deck.grid-review .grid-readout strong { color: var(--yellow); }
.deck.grid-weak .grid-readout strong { color: #ff8d98; }
.deck.grid-locked .grid-readout strong { color: #9ff08d; }

@media (max-width: 1180px) {
  .grid-panel { grid-template-columns: 1fr; }
  .grid-actions { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .grid-panel { display: none; }
}

/* v1.37 pro-grid performance and deck layout pass */
.prep-small {
  min-height: 30px !important;
  padding: 0 11px !important;
  border-radius: 8px !important;
  border: 1px solid rgba(143,208,255,.22) !important;
  background: rgba(47,155,255,.075) !important;
  color: rgba(223,239,255,.86) !important;
  font-size: 11px !important;
  font-weight: 850 !important;
  letter-spacing: .035em !important;
  cursor: pointer !important;
  white-space: nowrap !important;
}

.prep-small:hover,
.prep-small:focus-visible {
  border-color: rgba(143,208,255,.54) !important;
  background: rgba(47,155,255,.16) !important;
  color: #fff !important;
}

.prep-small[disabled] {
  opacity: .45 !important;
  cursor: not-allowed !important;
}

.grid-actions {
  grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
}

.deck {
  min-height: 650px !important;
  height: auto !important;
}

.deck-body {
  min-height: 450px !important;
  height: auto !important;
  align-items: stretch !important;
}

.platter-zone {
  min-height: 318px !important;
  align-content: center !important;
  overflow: visible !important;
}

.platter {
  width: clamp(250px, 17.5vw, 345px) !important;
  aspect-ratio: 1 / 1 !important;
  height: auto !important;
  min-height: 250px !important;
  max-height: 345px !important;
  flex: 0 0 auto !important;
}

.deck-tools {
  align-content: start !important;
}

@media (min-width: 1800px) {
  .deck { min-height: 690px !important; height: auto !important; }
  .deck-body { min-height: 490px !important; height: auto !important; }
  .platter-zone { min-height: 360px !important; }
  .platter { width: clamp(285px, 18vw, 380px) !important; min-height: 285px !important; max-height: 380px !important; }
}

@media (max-width: 1500px) {
  .deck { min-height: 610px !important; height: auto !important; }
  .deck-body { min-height: 420px !important; height: auto !important; }
  .platter-zone { min-height: 292px !important; }
  .platter { width: clamp(225px, 18vw, 300px) !important; min-height: 225px !important; max-height: 300px !important; }
  .grid-actions { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
}

@media (max-width: 1180px) {
  .deck { min-height: 0 !important; }
  .deck-body { min-height: 0 !important; }
  .platter-zone { min-height: 0 !important; }
  .platter { min-height: 0 !important; }
}

.panel-header {
  grid-template-columns: minmax(140px, 190px) 116px minmax(260px, 1fr) 126px 150px minmax(76px, auto) !important;
  align-items: center !important;
}

@media (max-width: 1500px) {
  .panel-header {
    grid-template-columns: minmax(125px, 172px) 106px minmax(230px, 1fr) 122px 136px minmax(66px, auto) !important;
  }
}

@media (max-width: 1180px) {
  .panel-header { grid-template-columns: 1fr 1fr !important; }
  .panel-header .search,
  .panel-header #trackCount { grid-column: 1 / -1 !important; }
}

/* v1.38 deck grid-row layout repair
   Scope: give the beatgrid prep strip its own deck row and let the library row flow below the taller decks. */
:root {
  --v138-top-row: 720px;
  --v138-deck-header: 44px;
  --v138-grid-panel: 50px;
  --v138-wave: 68px;
  --v138-zoom: 30px;
  --v138-time: 22px;
  --v138-gap: 8px;
}

@media (min-width: 1181px) {
  .main-grid {
    grid-template-columns: minmax(0, 5.05fr) minmax(245px, 292px) minmax(0, 5.05fr) !important;
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: auto minmax(540px, 60vh) 230px !important;
    align-items: stretch !important;
  }

  .deck,
  .mixer {
    height: var(--v138-top-row) !important;
    min-height: var(--v138-top-row) !important;
    max-height: var(--v138-top-row) !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: var(--v138-deck-header) var(--v138-grid-panel) var(--v138-wave) var(--v138-zoom) var(--v138-time) minmax(0, 1fr) !important;
    gap: var(--v138-gap) !important;
    overflow: hidden !important;
  }

  .deck-header { grid-row: 1 !important; }
  .grid-panel {
    grid-row: 2 !important;
    min-height: 0 !important;
    margin: 0 !important;
    align-self: stretch !important;
  }
  .wave-wrap {
    grid-row: 3 !important;
    height: var(--v138-wave) !important;
    min-height: var(--v138-wave) !important;
    margin: 0 !important;
  }
  .zoom-waveform {
    grid-row: 4 !important;
    height: var(--v138-zoom) !important;
    min-height: var(--v138-zoom) !important;
    margin: 0 !important;
  }
  .time-row {
    grid-row: 5 !important;
    height: var(--v138-time) !important;
    min-height: var(--v138-time) !important;
    margin: 0 !important;
  }
  .deck-body {
    grid-row: 6 !important;
    min-height: 0 !important;
    height: auto !important;
    overflow: hidden !important;
  }

  .platter-zone {
    min-height: 0 !important;
    overflow: visible !important;
  }
  .platter {
    width: clamp(245px, 16.5vw, 330px) !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
  }
}

@media (min-width: 1800px) {
  :root { --v138-top-row: 760px; --v138-grid-panel: 50px; }
  .platter { width: clamp(285px, 17.5vw, 370px) !important; }
}

@media (max-width: 1500px) and (min-width: 1181px) {
  :root { --v138-top-row: 705px; --v138-grid-panel: 82px; --v138-wave: 64px; --v138-zoom: 28px; }
  .grid-panel {
    grid-template-columns: 1fr !important;
    gap: 6px !important;
  }
  .grid-actions { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
  .grid-actions button { min-height: 24px !important; }
  .deck-body { grid-template-columns: 88px minmax(220px, 1fr) 156px !important; }
  .platter { width: clamp(215px, 15vw, 285px) !important; }
}

@media (max-width: 1180px) {
  .main-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    align-items: stretch !important;
  }

  .deck,
  .mixer {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: auto auto auto auto auto auto !important;
    gap: 8px !important;
    overflow: hidden !important;
  }

  .deck-header { grid-row: 1 !important; }
  .grid-panel {
    grid-row: 2 !important;
    margin: 0 !important;
    grid-template-columns: 1fr !important;
  }
  .grid-actions { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
  .wave-wrap { grid-row: 3 !important; margin: 0 !important; }
  .zoom-waveform { grid-row: 4 !important; margin: 0 !important; }
  .time-row { grid-row: 5 !important; margin: 0 !important; }
  .deck-body {
    grid-row: 6 !important;
    height: auto !important;
    min-height: 430px !important;
    overflow: hidden !important;
  }
  .library-panel { min-height: 420px !important; }
}

@media (max-width: 760px) {
  .grid-panel { display: none !important; }
  .deck {
    grid-template-rows: auto auto auto auto auto !important;
  }
  .wave-wrap { grid-row: 2 !important; }
  .zoom-waveform { grid-row: 3 !important; }
  .time-row { grid-row: 4 !important; }
  .deck-body {
    grid-row: 5 !important;
    min-height: 0 !important;
  }
  .library-panel { min-height: 320px !important; }
}

/* v1.39 pro scan queue and WASM analyzer controls */
.cancel-scan {
  border-color: rgba(255, 113, 113, .28) !important;
  color: rgba(255, 180, 180, .9) !important;
  background: rgba(255, 67, 84, .08) !important;
}

.cancel-scan[hidden] {
  display: none !important;
}

/* v1.44 premium CDJ redesign and UX repair */
:root {
  --club-bg: #03060a;
  --club-panel: #080e15;
  --club-panel-lift: #0d151f;
  --club-panel-deep: #05090f;
  --club-line: rgba(188, 214, 244, 0.16);
  --club-line-soft: rgba(188, 214, 244, 0.09);
  --club-text: #f5f8fc;
  --club-muted: #8f9bab;
  --club-blue: #35a8ff;
  --club-blue-soft: rgba(53, 168, 255, 0.18);
  --club-orange: #ff941f;
  --club-orange-soft: rgba(255, 148, 31, 0.18);
  --club-green: #61e25a;
  --club-red: #ff4354;
  --club-button: linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.018));
  --club-button-pressed: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.075));
}

html,
body {
  background:
    radial-gradient(circle at 18% 3%, rgba(53,168,255,.16), transparent 28%),
    radial-gradient(circle at 82% 4%, rgba(255,148,31,.13), transparent 28%),
    linear-gradient(180deg, #0a1017 0%, var(--club-bg) 42%, #010205 100%) !important;
  color: var(--club-text) !important;
}

.app-shell {
  max-width: 1960px !important;
  padding: 14px 16px 36px !important;
}

.topbar {
  grid-template-columns: minmax(280px, 1fr) auto !important;
  height: 58px !important;
  min-height: 58px !important;
  padding: 8px 14px !important;
  border: 1px solid var(--club-line) !important;
  border-radius: 13px !important;
  background:
    linear-gradient(180deg, rgba(20, 30, 42, .96), rgba(5, 9, 14, .97)),
    var(--club-panel) !important;
  box-shadow: 0 18px 48px rgba(0,0,0,.40), inset 0 1px 0 rgba(255,255,255,.055) !important;
}

.brand {
  gap: 11px !important;
}

.brand-mark {
  width: 38px !important;
  height: 38px !important;
  display: grid !important;
  place-items: center !important;
  filter: drop-shadow(0 0 14px rgba(53,168,255,.25)) !important;
}

.brand-mark svg {
  width: 38px !important;
  height: 38px !important;
  display: block !important;
}

.brand-copy strong {
  font-size: 15px !important;
  letter-spacing: .035em !important;
  color: #ffffff !important;
}

.brand-copy small {
  color: rgba(201, 216, 233, .72) !important;
  letter-spacing: .02em !important;
}

.status-strip {
  justify-self: end !important;
  gap: 10px !important;
}

.icon-status,
.record-pill {
  height: 36px !important;
  min-height: 36px !important;
  border-radius: 9px !important;
  border-color: var(--club-line) !important;
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.015)) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 8px 20px rgba(0,0,0,.22) !important;
}

.icon-status {
  min-width: 118px !important;
  justify-content: center !important;
  color: #a5b2c1 !important;
}

.icon-status i {
  width: 9px !important;
  height: 9px !important;
  background: #4a5564 !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18) !important;
  opacity: .85 !important;
}

.icon-status.active {
  color: #f2fff0 !important;
  border-color: rgba(97,226,90,.36) !important;
  background: linear-gradient(180deg, rgba(97,226,90,.12), rgba(255,255,255,.018)) !important;
}

.icon-status.active i {
  background: var(--club-green) !important;
  box-shadow: 0 0 12px rgba(97,226,90,.72), 0 0 0 2px rgba(97,226,90,.13) !important;
  opacity: 1 !important;
}

.record-pill {
  min-width: 272px !important;
  border-color: rgba(255,67,84,.26) !important;
}

.record-pill b {
  color: #ff5a68 !important;
}

.record-pill em {
  color: rgba(196, 219, 240, .86) !important;
}

button,
.import-button,
.shortcut-actions label {
  border-color: var(--club-line) !important;
  background: var(--club-button) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 6px 16px rgba(0,0,0,.18) !important;
}

button:hover,
.import-button:hover,
.shortcut-actions label:hover {
  border-color: rgba(222, 237, 255, .30) !important;
  background: linear-gradient(180deg, rgba(255,255,255,.105), rgba(255,255,255,.024)) !important;
}

button:focus-visible,
.import-button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid rgba(111, 212, 255, .75) !important;
  outline-offset: 2px !important;
}

.deck,
.mixer,
.app-panel {
  border-color: var(--club-line) !important;
  border-radius: 14px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.042), rgba(255,255,255,.012)),
    radial-gradient(circle at 50% 0%, rgba(255,255,255,.035), transparent 42%),
    var(--club-panel) !important;
  box-shadow: 0 16px 44px rgba(0,0,0,.34), inset 0 1px 0 rgba(255,255,255,.045) !important;
}

.deck::before {
  opacity: .48 !important;
  background: radial-gradient(circle at 48% 57%, var(--club-blue-soft), transparent 38%) !important;
}

.deck-b::before {
  background: radial-gradient(circle at 48% 57%, var(--club-orange-soft), transparent 38%) !important;
}

.deck-header,
.grid-panel,
.loop-box,
.hotcue-box,
.tempo-column,
.channel-strip,
.master-strip,
.meter-shell,
.cue-diagram,
.hint-box,
.diagnostics-box,
.shortcut-editor {
  border-color: var(--club-line-soft) !important;
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.009)), rgba(1, 5, 9, .58) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.035) !important;
}

.deck-header {
  padding: 0 !important;
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

.deck-badge {
  border-radius: 9px !important;
  background: linear-gradient(180deg, #44b7ff, #0969c9) !important;
  box-shadow: 0 0 0 1px rgba(145,218,255,.22), 0 0 22px rgba(53,168,255,.34) !important;
}

.deck-b .deck-badge {
  background: linear-gradient(180deg, #ffad3f, #bc5e05) !important;
  box-shadow: 0 0 0 1px rgba(255,208,137,.20), 0 0 22px rgba(255,148,31,.31) !important;
}

.track-title-block h2 {
  color: #f9fbff !important;
  letter-spacing: .035em !important;
  text-shadow: 0 1px 0 rgba(0,0,0,.65) !important;
}

.track-title-block p,
.deck-meta span,
.grid-readout span,
.panel-header span,
.storage-dashboard,
.drop-hint,
.recording-panel p,
.cue-panel p {
  color: rgba(205, 219, 235, .68) !important;
}

.bpm-edit-button {
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.deck-meta em {
  color: var(--club-blue) !important;
  font-style: normal !important;
  text-shadow: 0 0 12px rgba(53,168,255,.34) !important;
}

.deck-b .deck-meta em {
  color: var(--club-orange) !important;
  text-shadow: 0 0 12px rgba(255,148,31,.34) !important;
}

.grid-panel {
  border-radius: 9px !important;
  padding: 6px !important;
}

.grid-readout {
  border-radius: 7px !important;
  border: 1px solid rgba(97,226,90,.25) !important;
  background: rgba(4, 14, 11, .62) !important;
}

.grid-readout strong {
  color: #7dff74 !important;
}

.wave-wrap,
.zoom-waveform {
  border-color: var(--club-line-soft) !important;
  background:
    linear-gradient(180deg, rgba(0,0,0,.45), rgba(0,0,0,.18)),
    repeating-linear-gradient(90deg, rgba(255,255,255,.025) 0 1px, transparent 1px 42px) !important;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.45), inset 0 0 32px rgba(0,0,0,.42) !important;
}

.playhead-line {
  background: linear-gradient(180deg, transparent, rgba(255,67,84,.92), transparent) !important;
  box-shadow: 0 0 13px rgba(255,67,84,.62) !important;
}

.progress-rail,
.phase-meter {
  background: rgba(0,0,0,.42) !important;
  border-color: var(--club-line-soft) !important;
}

.sync-button,
.cue-button,
.play-button,
.set-button,
.master-button,
.range-button,
.loop-toggle,
.deck-options button,
.hotcue-grid button,
.channel-cue {
  border-radius: 8px !important;
  text-transform: uppercase !important;
  letter-spacing: .07em !important;
}

.sync-button {
  border-color: rgba(53,168,255,.45) !important;
  color: #aee2ff !important;
  background: linear-gradient(180deg, rgba(53,168,255,.12), rgba(53,168,255,.025)) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 0 20px rgba(53,168,255,.13) !important;
}

.deck-b .sync-button {
  border-color: rgba(255,148,31,.48) !important;
  color: #ffd6a2 !important;
  background: linear-gradient(180deg, rgba(255,148,31,.12), rgba(255,148,31,.025)) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 0 20px rgba(255,148,31,.12) !important;
}

.play-button {
  border-color: rgba(97,226,90,.42) !important;
  background: linear-gradient(180deg, rgba(73, 205, 59, .86), rgba(30, 124, 23, .92)) !important;
  color: #f7fff5 !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 0 24px rgba(97,226,90,.18) !important;
}

.cue-button {
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.015)), rgba(2, 6, 10, .86) !important;
  color: #f7fbff !important;
}

.master-button.active,
.channel-cue.active,
.deck-options button.active,
.loop-toggle.active {
  color: #06100a !important;
  border-color: rgba(97,226,90,.68) !important;
  background: linear-gradient(180deg, #8afc7f, #38b82f) !important;
  box-shadow: 0 0 18px rgba(97,226,90,.28), inset 0 1px 0 rgba(255,255,255,.32) !important;
}

.platter {
  background:
    radial-gradient(circle, rgba(255,255,255,.10) 0 2px, transparent 3px),
    repeating-radial-gradient(circle, rgba(211,226,244,.09) 0 1px, transparent 1px 6px),
    radial-gradient(circle at 50% 44%, #101822 0%, #05080d 62%, #010204 100%) !important;
  border: 1px solid rgba(189, 221, 255, .19) !important;
  box-shadow:
    inset 0 0 0 7px rgba(0,0,0,.42),
    inset 0 0 34px rgba(0,0,0,.62),
    0 0 0 1px rgba(53,168,255,.31),
    0 0 34px rgba(53,168,255,.20),
    0 20px 38px rgba(0,0,0,.40) !important;
}

.deck-b .platter {
  box-shadow:
    inset 0 0 0 7px rgba(0,0,0,.42),
    inset 0 0 34px rgba(0,0,0,.62),
    0 0 0 1px rgba(255,148,31,.32),
    0 0 34px rgba(255,148,31,.19),
    0 20px 38px rgba(0,0,0,.40) !important;
}

.platter-ring {
  border-color: rgba(229, 241, 255, .11) !important;
  box-shadow: inset 0 0 18px rgba(0,0,0,.56) !important;
}

.platter-core {
  border-color: rgba(232, 244, 255, .62) !important;
  background: radial-gradient(circle, #f2f8ff 0 10%, #182434 13% 36%, #05090f 40% 100%) !important;
  box-shadow: 0 0 18px rgba(235,245,255,.18) !important;
}

input[type="range"] {
  accent-color: var(--club-blue) !important;
}

.deck-b input[type="range"],
.channel-strip[data-channel="B"] input[type="range"] {
  accent-color: var(--club-orange) !important;
}

.master-strip input[type="range"] {
  accent-color: #dfe9f5 !important;
}

.library-panel {
  border-radius: 14px !important;
  overflow: hidden !important;
}

.panel-header {
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.010)), rgba(2,6,10,.56) !important;
  border-bottom-color: var(--club-line-soft) !important;
}

.import-button {
  color: #bde6ff !important;
  border-color: rgba(53,168,255,.34) !important;
}

.danger-small {
  color: #ffabb4 !important;
  border-color: rgba(255,67,84,.28) !important;
}

.search {
  color: #e8f1fb !important;
  border-color: var(--club-line) !important;
  background: rgba(0,0,0,.32) !important;
}

.table-wrap {
  scrollbar-color: rgba(121, 151, 185, .42) rgba(0,0,0,.18) !important;
}

.track-table {
  min-width: 1180px !important;
}

.track-table th,
.track-table td {
  border-bottom-color: rgba(188, 214, 244, .075) !important;
}

.track-table th {
  color: rgba(225, 238, 252, .72) !important;
  background: linear-gradient(180deg, #101822, #080e15) !important;
}

.track-table th:nth-child(1),
.track-table td:nth-child(1) { width: 42px !important; }
.track-table th:nth-child(2),
.track-table td:nth-child(2) { width: 64px !important; }
.track-table th:nth-child(3),
.track-table td:nth-child(3) { width: 320px !important; }
.track-table th:nth-child(4),
.track-table td:nth-child(4) { width: 220px !important; }
.track-table th:nth-child(5),
.track-table td:nth-child(5) { width: 240px !important; }
.track-table th:nth-child(6),
.track-table td:nth-child(6) { width: 92px !important; }
.track-table th:nth-child(7),
.track-table td:nth-child(7) { width: 92px !important; }
.track-table th:nth-child(8),
.track-table td:nth-child(8) { width: 100px !important; }
.track-table th:nth-child(9),
.track-table td:nth-child(9) { width: 130px !important; }

.sort-header {
  width: 100% !important;
  min-height: 24px !important;
  height: 24px !important;
  padding: 0 6px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 8px !important;
  border: 0 !important;
  border-radius: 6px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
  font-size: inherit !important;
  font-weight: 800 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;
}

.sort-header::after {
  content: "↕" !important;
  color: rgba(198, 216, 236, .36) !important;
  font-size: 10px !important;
  line-height: 1 !important;
}

.sort-header:hover {
  background: rgba(255,255,255,.055) !important;
  color: #ffffff !important;
}

.sort-header.active-sort {
  color: #eaf7ff !important;
  background: rgba(53,168,255,.10) !important;
}

.sort-header.active-sort[data-direction="asc"]::after {
  content: "▲" !important;
  color: var(--club-blue) !important;
}

.sort-header.active-sort[data-direction="desc"]::after {
  content: "▼" !important;
  color: var(--club-blue) !important;
}

.track-table tr:hover,
.track-table tr.selected,
.track-table tr.bulk-selected {
  background: rgba(53,168,255,.08) !important;
}

.recording-panel,
.cue-panel {
  min-height: 360px !important;
  height: auto !important;
  overflow: visible !important;
  align-content: start !important;
}

.recording-panel {
  display: grid !important;
  grid-template-rows: auto auto auto auto auto minmax(92px, auto) !important;
  gap: 9px !important;
}

.cue-panel {
  display: grid !important;
  grid-template-rows: auto auto auto auto auto auto auto !important;
  gap: 10px !important;
}

.recording-panel canvas {
  height: 78px !important;
}

.record-controls {
  margin-top: 0 !important;
}

.recordings-list {
  max-height: none !important;
  min-height: 90px !important;
  overflow: visible !important;
}

.cue-meter {
  height: 42px !important;
  margin-bottom: 0 !important;
}

.cue-diagram {
  padding: 12px !important;
  border-radius: 10px !important;
}

.diagram-row {
  font-size: 12px !important;
  letter-spacing: .04em !important;
}

.diagram-divider {
  color: rgba(218, 232, 247, .62) !important;
}

.cue-panel .hint-box {
  display: grid !important;
  gap: 5px !important;
  padding: 10px !important;
  border-radius: 10px !important;
}

.cue-panel .shortcut-editor,
.cue-panel .diagnostics-box {
  display: none !important;
}

.panel-title {
  letter-spacing: .10em !important;
  color: rgba(235, 244, 255, .82) !important;
}

.panel-title.green span,
.headphone-status span {
  background: var(--club-green) !important;
  box-shadow: 0 0 12px rgba(97,226,90,.70) !important;
}

.panel-title.red span {
  background: var(--club-red) !important;
  box-shadow: 0 0 12px rgba(255,67,84,.65) !important;
}

@media (min-width: 1181px) {
  .main-grid {
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: 540px minmax(560px, auto) auto !important;
  }
}

@media (max-width: 1500px) and (min-width: 1181px) {
  .topbar {
    grid-template-columns: minmax(230px, 1fr) auto !important;
  }
  .main-grid {
    grid-template-rows: 520px minmax(520px, auto) auto !important;
  }
  .recording-panel,
  .cue-panel {
    min-height: 330px !important;
  }
}

@media (max-width: 1180px) {
  .topbar {
    grid-template-columns: 1fr !important;
    height: auto !important;
    min-height: 58px !important;
  }
  .status-strip {
    justify-self: start !important;
    flex-wrap: wrap !important;
  }
  .recording-panel,
  .cue-panel {
    min-height: 300px !important;
  }
}

@media (max-width: 760px) {
  .brand-mark,
  .brand-mark svg {
    width: 34px !important;
    height: 34px !important;
  }
  .record-pill {
    min-width: 220px !important;
  }
}

/* v1.45 layout repair: prevent deck overflow from covering the library and let lower cards breathe. */
@media (min-width: 1181px) {
  .main-grid {
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: auto minmax(640px, auto) auto !important;
    align-items: start !important;
  }

  .deck,
  .mixer {
    align-self: start !important;
    min-height: 690px !important;
    height: auto !important;
    max-height: none !important;
  }

  .deck {
    grid-template-rows: 44px 68px 30px 22px minmax(500px, auto) !important;
    overflow: hidden !important;
  }

  .deck-body {
    min-height: 500px !important;
    height: auto !important;
    overflow: visible !important;
    grid-template-columns: 96px minmax(260px, 1fr) 170px !important;
  }

  .platter-zone {
    min-height: 360px !important;
    overflow: visible !important;
  }

  .deck-tools {
    overflow: visible !important;
  }

  .library-panel {
    min-height: 640px !important;
    height: auto !important;
    overflow: hidden !important;
    align-self: start !important;
  }

  .library-main {
    min-height: 640px !important;
  }

  .recording-panel,
  .cue-panel {
    min-height: 420px !important;
    height: auto !important;
    overflow: visible !important;
    align-self: start !important;
  }
}

@media (min-width: 1501px) and (max-width: 1799px) {
  .deck,
  .mixer {
    min-height: 670px !important;
  }

  .deck {
    grid-template-rows: 44px 68px 30px 22px minmax(480px, auto) !important;
  }

  .deck-body {
    min-height: 480px !important;
    grid-template-columns: 92px minmax(240px, 1fr) 164px !important;
  }

  .platter-zone {
    min-height: 340px !important;
  }
}

@media (max-width: 1500px) and (min-width: 1181px) {
  .main-grid {
    grid-template-rows: auto minmax(600px, auto) auto !important;
  }

  .deck,
  .mixer {
    min-height: 650px !important;
    height: auto !important;
    max-height: none !important;
  }

  .deck {
    grid-template-rows: 42px 64px 28px 22px minmax(470px, auto) !important;
  }

  .deck-body {
    min-height: 470px !important;
    grid-template-columns: 88px minmax(215px, 1fr) 154px !important;
    gap: 9px !important;
  }

  .platter-zone {
    min-height: 330px !important;
  }

  .library-panel,
  .library-main {
    min-height: 600px !important;
  }

  .recording-panel,
  .cue-panel {
    min-height: 390px !important;
  }
}

@media (max-width: 1180px) {
  .main-grid {
    grid-template-rows: none !important;
  }

  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel {
    min-height: 0 !important;
    height: auto !important;
    max-height: none !important;
  }

  .deck {
    overflow: hidden !important;
  }

  .library-panel {
    min-height: 520px !important;
  }

  .recording-panel,
  .cue-panel {
    min-height: 320px !important;
  }
}


/* v1.46 mobile concept implementation: phone-native active deck, mixer strip, and library sheet. Desktop rules above are untouched. */
@media (max-width: 760px) {
  html,
  body {
    min-height: 100% !important;
    background:
      radial-gradient(circle at 12% 0%, rgba(53, 168, 255, .18), transparent 30%),
      radial-gradient(circle at 88% 7%, rgba(255, 142, 18, .14), transparent 28%),
      linear-gradient(180deg, #08101a 0%, #03060a 100%) !important;
  }

  body {
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 460px !important;
    margin: 0 auto !important;
    padding: max(8px, env(safe-area-inset-top)) 10px 24px !important;
  }

  .topbar {
    position: sticky !important;
    top: max(8px, env(safe-area-inset-top)) !important;
    z-index: 60 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 8px !important;
    min-height: 58px !important;
    height: auto !important;
    padding: 9px 10px !important;
    border-radius: 18px !important;
    border-color: rgba(154, 196, 238, .18) !important;
    background:
      linear-gradient(180deg, rgba(19, 30, 42, .96), rgba(7, 12, 18, .96)),
      rgba(5, 8, 12, .94) !important;
    box-shadow: 0 18px 46px rgba(0, 0, 0, .42) !important;
    backdrop-filter: blur(18px) !important;
  }

  .brand {
    min-width: 0 !important;
    gap: 9px !important;
  }

  .brand-mark,
  .brand-mark svg {
    width: 32px !important;
    height: 32px !important;
    flex: 0 0 32px !important;
  }

  .brand-copy {
    min-width: 0 !important;
    gap: 7px !important;
  }

  .brand-copy strong {
    font-size: 15px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  .brand-copy small {
    display: inline !important;
    font-size: 10px !important;
    color: rgba(218, 231, 246, .62) !important;
  }

  .status-strip {
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 6px !important;
    min-width: 0 !important;
    flex-wrap: nowrap !important;
  }

  .icon-status,
  .record-pill {
    min-height: 38px !important;
    height: 38px !important;
    padding: 0 9px !important;
    border-radius: 9px !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, .055), rgba(255, 255, 255, .015)) !important;
  }

  .icon-status {
    min-width: 84px !important;
    color: #e8f3ff !important;
    border-color: rgba(99, 212, 84, .34) !important;
  }

  .icon-status:not(.active) {
    color: rgba(214, 226, 239, .58) !important;
    border-color: rgba(220, 235, 255, .13) !important;
  }

  .icon-status i {
    background: var(--green) !important;
    opacity: 1 !important;
  }

  .icon-status:not(.active) i {
    background: rgba(150, 164, 179, .55) !important;
    box-shadow: none !important;
  }

  .record-pill {
    min-width: 100px !important;
    max-width: 106px !important;
    gap: 6px !important;
  }

  .record-pill span {
    width: 12px !important;
    height: 12px !important;
    flex: 0 0 12px !important;
  }

  .record-pill b {
    display: inline !important;
    font-size: 11px !important;
    line-height: 1 !important;
  }

  .record-pill em {
    display: none !important;
  }

  .record-pill time {
    min-width: 42px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    text-align: left !important;
  }

  .mobile-tabs {
    position: sticky !important;
    top: calc(max(8px, env(safe-area-inset-top)) + 66px) !important;
    z-index: 55 !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 48px minmax(0, 1fr) !important;
    gap: 8px !important;
    margin: 10px 0 8px !important;
    padding: 8px !important;
    border: 1px solid rgba(154, 196, 238, .18) !important;
    border-radius: 18px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .010)),
      rgba(6, 10, 15, .94) !important;
    box-shadow: 0 14px 32px rgba(0, 0, 0, .34) !important;
    backdrop-filter: blur(16px) !important;
  }

  .mobile-tabs button {
    height: 44px !important;
    min-height: 44px !important;
    padding: 0 10px !important;
    border-radius: 12px !important;
    font-weight: 850 !important;
    letter-spacing: .02em !important;
    color: rgba(226, 238, 250, .78) !important;
  }

  .mobile-deck-tab {
    display: grid !important;
    grid-template-columns: auto 1fr !important;
    gap: 9px !important;
    align-items: center !important;
  }

  .mobile-deck-tab-b {
    grid-template-columns: 1fr auto !important;
  }

  .mobile-deck-tab b {
    font-size: 14px !important;
    font-weight: 850 !important;
  }

  .deck-tab-badge {
    width: 34px !important;
    height: 34px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 9px !important;
    color: #fff !important;
    font-size: 17px !important;
    font-weight: 900 !important;
  }

  .mobile-deck-tab-a .deck-tab-badge {
    background: linear-gradient(180deg, #2da7ff, #0f66ca) !important;
    box-shadow: 0 0 22px rgba(53, 168, 255, .36) !important;
  }

  .mobile-deck-tab-b .deck-tab-badge {
    background: linear-gradient(180deg, #ffab2d, #c96205) !important;
    box-shadow: 0 0 22px rgba(255, 142, 18, .34) !important;
  }

  .mobile-tabs [data-mobile-tab="A"].active {
    color: #91d6ff !important;
    border-color: rgba(53, 168, 255, .46) !important;
    background: linear-gradient(180deg, rgba(53, 168, 255, .16), rgba(53, 168, 255, .035)) !important;
  }

  .mobile-tabs [data-mobile-tab="B"].active {
    color: #ffc778 !important;
    border-color: rgba(255, 142, 18, .48) !important;
    background: linear-gradient(180deg, rgba(255, 142, 18, .16), rgba(255, 142, 18, .035)) !important;
  }

  .mobile-swap-tab {
    padding: 0 !important;
    font-size: 22px !important;
    color: rgba(232, 241, 252, .82) !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
    margin-top: 0 !important;
    align-items: start !important;
  }

  .deck-a,
  .deck-b,
  .mixer,
  .library-panel {
    grid-column: 1 !important;
  }

  .deck-a,
  .deck-b {
    grid-row: 1 !important;
  }

  .mixer {
    grid-row: 2 !important;
  }

  .library-panel {
    grid-row: 3 !important;
  }

  .mobile-focus-a .deck-a,
  .mobile-focus-b .deck-b {
    display: grid !important;
  }

  .mobile-focus-a .deck-b,
  .mobile-focus-b .deck-a,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b,
  .recording-panel,
  .cue-panel {
    display: none !important;
  }

  .mobile-focus-a .mixer,
  .mobile-focus-b .mixer,
  .mobile-focus-a .library-panel,
  .mobile-focus-b .library-panel {
    display: grid !important;
  }

  .deck {
    min-height: 0 !important;
    height: auto !important;
    grid-template-rows: auto auto auto auto auto !important;
    gap: 8px !important;
    padding: 12px !important;
    border-radius: 18px !important;
    border-color: rgba(154, 196, 238, .16) !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .012)),
      rgba(7, 12, 18, .97) !important;
    box-shadow: 0 18px 46px rgba(0, 0, 0, .38) !important;
    overflow: hidden !important;
  }

  .deck::before {
    opacity: .42 !important;
    background: radial-gradient(circle at 52% 55%, rgba(53, 168, 255, .18), transparent 40%) !important;
  }

  .deck-b::before {
    background: radial-gradient(circle at 52% 55%, rgba(255, 142, 18, .18), transparent 40%) !important;
  }

  .deck-header {
    grid-row: 1 !important;
    height: auto !important;
    min-height: 46px !important;
    grid-template-columns: 42px minmax(0, 1fr) auto !important;
    gap: 10px !important;
  }

  .deck-badge {
    width: 40px !important;
    height: 40px !important;
    border-radius: 10px !important;
    font-size: 18px !important;
  }

  .track-title-block h2 {
    font-size: 17px !important;
    line-height: 1.08 !important;
    letter-spacing: .02em !important;
  }

  .track-title-block p {
    margin-top: 4px !important;
    font-size: 12px !important;
    color: rgba(218, 230, 244, .68) !important;
  }

  .deck-meta {
    min-width: 84px !important;
  }

  .bpm-edit-button {
    height: auto !important;
    min-height: 30px !important;
  }

  .bpm-edit-button strong {
    font-size: 20px !important;
    letter-spacing: .01em !important;
  }

  .bpm-edit-button span {
    font-size: 10px !important;
  }

  .deck-meta em {
    font-size: 16px !important;
  }

  .deck-feedback {
    position: absolute !important;
    top: 72px !important;
    left: 18px !important;
    right: auto !important;
    width: 136px !important;
    height: 20px !important;
    border-radius: 7px !important;
    font-size: 9px !important;
    letter-spacing: .13em !important;
    text-align: left !important;
    padding: 4px 7px !important;
  }

  .grid-panel {
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: minmax(118px, 1.12fr) repeat(8, minmax(38px, 1fr)) !important;
    gap: 2px !important;
    min-width: 0 !important;
    overflow: hidden !important;
    border-radius: 9px !important;
  }

  .grid-readout {
    min-height: 48px !important;
    padding: 8px 9px !important;
    border-radius: 8px !important;
  }

  .grid-readout strong {
    font-size: 10px !important;
  }

  .grid-readout span {
    font-size: 9px !important;
  }

  .grid-actions {
    display: contents !important;
  }

  .grid-actions button {
    min-width: 0 !important;
    height: 48px !important;
    padding: 0 4px !important;
    border-radius: 8px !important;
    font-size: 9px !important;
  }

  .wave-wrap {
    grid-row: 3 !important;
    height: 78px !important;
    margin: 0 !important;
    border-radius: 11px !important;
    border-color: rgba(154, 196, 238, .12) !important;
    background: rgba(2, 6, 10, .76) !important;
  }

  .zoom-waveform {
    display: block !important;
    grid-row: 4 !important;
    height: 30px !important;
    margin: -2px 0 0 !important;
    border-radius: 9px !important;
  }

  .time-row {
    grid-row: 5 !important;
    height: 24px !important;
    margin: 0 !important;
    gap: 8px !important;
  }

  .time-row time {
    font-size: 12px !important;
  }

  .progress-rail {
    height: 6px !important;
  }

  .deck-body {
    grid-row: 6 !important;
    display: grid !important;
    grid-template-columns: 68px minmax(0, 1fr) 106px !important;
    grid-template-rows: auto auto auto !important;
    gap: 10px !important;
    min-height: 0 !important;
    height: auto !important;
    align-items: stretch !important;
  }

  .tempo-column {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    height: auto !important;
    min-height: 254px !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 40px 24px 22px 24px 1fr !important;
    gap: 7px !important;
    padding: 8px 7px !important;
    border-radius: 12px !important;
    border-color: rgba(154, 196, 238, .12) !important;
    background: rgba(2, 6, 10, .44) !important;
  }

  .tempo-column .sync-button {
    grid-row: 1 !important;
    height: 38px !important;
    font-size: 12px !important;
  }

  .master-button {
    grid-row: 2 !important;
    height: 22px !important;
    min-height: 22px !important;
    font-size: 8px !important;
    border-radius: 999px !important;
    opacity: .86 !important;
  }

  .sync-status,
  .sync-primer,
  .phase-meter {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-row: 3 !important;
    font-size: 15px !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-row: 4 !important;
    font-size: 11px !important;
  }

  .range-button {
    display: none !important;
  }

  .tempo-column .vertical-slider {
    grid-row: 5 !important;
    height: 150px !important;
    min-height: 150px !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: auto 1fr auto !important;
    margin: 0 !important;
  }

  .tempo-column .vertical-slider input {
    width: 138px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-column: 2 !important;
    grid-row: 1 !important;
    display: grid !important;
    width: min(100%, 210px, 52vw) !important;
    align-self: center !important;
    justify-self: center !important;
    border-color: rgba(221, 238, 255, .16) !important;
  }

  .platter-ring {
    inset: 11px !important;
  }

  .platter-core {
    width: 40px !important;
    height: 40px !important;
  }

  .transport-row {
    grid-column: 2 / 4 !important;
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr 1.12fr 62px !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .transport-row button {
    height: 52px !important;
    border-radius: 10px !important;
    font-size: 14px !important;
  }

  .cue-button {
    color: #91d6ff !important;
    font-size: 15px !important;
    letter-spacing: .12em !important;
  }

  .play-button {
    font-size: 18px !important;
  }

  .set-button {
    font-size: 10px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-column: 3 !important;
    grid-row: 1 !important;
    display: grid !important;
    gap: 6px !important;
    align-content: center !important;
    padding: 9px 8px !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .40) !important;
  }

  .loop-box label,
  .hotcue-box label {
    font-size: 10px !important;
    margin-bottom: 2px !important;
  }

  .loop-size,
  .loop-row,
  .loop-extra-row {
    gap: 4px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    min-height: 34px !important;
    height: 34px !important;
    font-size: 11px !important;
    border-radius: 8px !important;
  }

  .loop-extra-row {
    margin-top: 0 !important;
  }

  .loop-extra-row:last-child {
    grid-template-columns: 1fr 1fr !important;
  }

  .hotcue-box {
    grid-column: 1 / 3 !important;
    grid-row: 3 !important;
    padding: 10px !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .38) !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 7px !important;
  }

  .hotcue-grid button {
    height: 40px !important;
    font-size: 15px !important;
    border-radius: 9px !important;
  }

  .deck-options {
    grid-column: 3 !important;
    grid-row: 3 !important;
    align-self: stretch !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 6px !important;
  }

  .deck-options button {
    min-height: 40px !important;
    height: auto !important;
    border-radius: 9px !important;
    font-size: 9px !important;
  }

  .mixer {
    height: auto !important;
    min-height: 0 !important;
    padding: 10px !important;
    border-radius: 18px !important;
    grid-template-columns: minmax(0, 1fr) 96px minmax(0, 1fr) !important;
    gap: 8px !important;
    border-color: rgba(154, 196, 238, .15) !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .010)),
      rgba(7, 12, 18, .97) !important;
  }

  .channel-strip,
  .master-strip {
    min-height: 0 !important;
    height: auto !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .40) !important;
    border-color: rgba(154, 196, 238, .11) !important;
  }

  .channel-strip {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    grid-auto-rows: auto !important;
    gap: 7px !important;
    padding: 9px 8px !important;
  }

  .channel-strip h3,
  .channel-strip label:has([data-role="gain"]),
  .channel-strip label:has([data-role="filter"]),
  .channel-strip .channel-cue,
  .channel-strip .channel-meter,
  .channel-strip .xfade-assign {
    display: none !important;
  }

  .channel-strip label {
    display: grid !important;
    gap: 5px !important;
    font-size: 9px !important;
    text-align: center !important;
  }

  .channel-strip label:has([data-role="fader"]) {
    grid-column: 1 / -1 !important;
    grid-row: 1 !important;
  }

  .channel-strip label:has([data-role="eq-low"]) { grid-column: 1 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-mid"]) { grid-column: 2 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-high"]) { grid-column: 3 !important; grid-row: 2 !important; }

  .channel-strip input[type="range"] {
    width: 100% !important;
    height: 20px !important;
  }

  .channel-fader input {
    writing-mode: horizontal-tb !important;
    appearance: auto !important;
    height: 22px !important;
  }

  .master-strip {
    grid-column: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 7px !important;
    padding: 9px 8px !important;
  }

  .master-strip h3,
  .master-knob,
  .meter-shell,
  .cue-mix-control,
  .cue-level-control,
  .xfade-curve {
    display: none !important;
  }

  .headphone-status {
    display: grid !important;
    justify-items: center !important;
    gap: 5px !important;
    font-size: 9px !important;
  }

  .crossfader {
    display: grid !important;
    grid-template-columns: auto 1fr auto !important;
    gap: 5px !important;
    align-items: center !important;
    font-size: 10px !important;
  }

  .crossfader input {
    width: 100% !important;
  }

  .library-panel {
    min-height: 320px !important;
    height: auto !important;
    grid-template-columns: 1fr !important;
    border-radius: 20px 20px 16px 16px !important;
    border-color: rgba(154, 196, 238, .16) !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .012)),
      rgba(7, 12, 18, .98) !important;
    box-shadow: 0 -10px 34px rgba(0, 0, 0, .28) !important;
    overflow: hidden !important;
  }

  .library-panel::before {
    content: "" !important;
    width: 52px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(220, 235, 255, .28) !important;
    justify-self: center !important;
    margin-top: 10px !important;
  }

  .side-nav {
    display: none !important;
  }

  .library-main {
    min-height: 0 !important;
    display: grid !important;
    grid-template-rows: auto auto auto minmax(0, 1fr) !important;
  }

  .panel-header {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    gap: 9px !important;
    padding: 12px 12px 10px !important;
    background: transparent !important;
  }

  .panel-header > div {
    grid-column: 1 / -1 !important;
    display: flex !important;
    align-items: baseline !important;
    gap: 10px !important;
  }

  .panel-header strong {
    font-size: 20px !important;
  }

  .panel-header span {
    font-size: 11px !important;
  }

  .import-button {
    grid-column: 1 !important;
    height: 40px !important;
    justify-content: center !important;
  }

  .search {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    min-width: 0 !important;
    width: 100% !important;
    height: 42px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
  }

  .danger-small {
    grid-column: 2 !important;
    grid-row: 2 !important;
    height: 40px !important;
    padding: 0 12px !important;
  }

  .panel-header em {
    grid-column: 1 / -1 !important;
    grid-row: 4 !important;
    justify-self: start !important;
    font-size: 11px !important;
  }

  .storage-dashboard,
  .drop-hint,
  .import-progress {
    display: none !important;
  }

  .table-wrap {
    min-height: 0 !important;
    max-height: 420px !important;
    overflow: auto !important;
    padding: 0 10px 12px !important;
  }

  .track-table,
  .track-table thead,
  .track-table tbody,
  .track-table tr,
  .track-table th,
  .track-table td {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .track-table {
    border-collapse: separate !important;
    border-spacing: 0 !important;
    min-width: 0 !important;
    font-size: 13px !important;
  }

  .track-table thead {
    position: sticky !important;
    top: 0 !important;
    z-index: 2 !important;
    padding: 0 0 8px !important;
    background: rgba(7, 12, 18, .98) !important;
  }

  .track-table thead tr {
    display: grid !important;
    grid-template-columns: 34px 44px repeat(6, minmax(58px, 1fr)) 54px !important;
    gap: 4px !important;
    align-items: center !important;
  }

  .track-table th {
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  .track-table th:first-child input {
    width: 20px !important;
    height: 20px !important;
    margin: 8px auto !important;
    display: block !important;
  }

  .sort-header {
    min-height: 34px !important;
    height: 34px !important;
    padding: 0 8px !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, .035) !important;
    font-size: 10px !important;
    letter-spacing: .06em !important;
    justify-content: center !important;
  }

  .sort-header::after {
    margin-left: 5px !important;
  }

  .track-table th:nth-child(4),
  .track-table th:nth-child(5),
  .track-table th:nth-child(8),
  .track-table td:nth-child(4),
  .track-table td:nth-child(5),
  .track-table td:nth-child(8) {
    display: none !important;
  }

  .track-table thead tr {
    grid-template-columns: 28px 42px 1.4fr 70px 64px 58px !important;
  }

  .track-table tbody {
    display: grid !important;
    gap: 8px !important;
  }

  .track-table tbody tr {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 38px minmax(0, 1fr) 64px 48px 60px !important;
    grid-template-rows: auto auto !important;
    gap: 3px 10px !important;
    align-items: center !important;
    min-height: 68px !important;
    padding: 10px !important;
    border: 1px solid rgba(154, 196, 238, .13) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .38) !important;
  }

  .track-table tbody tr.selected,
  .track-table tbody tr.bulk-selected {
    border-color: rgba(53, 168, 255, .46) !important;
    background: rgba(53, 168, 255, .08) !important;
  }

  .track-table td {
    padding: 0 !important;
    border: 0 !important;
    min-width: 0 !important;
  }

  .track-table td:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    place-items: center !important;
  }

  .track-table td:nth-child(2) {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    place-items: center !important;
    width: 34px !important;
    height: 34px !important;
    margin-left: 2px !important;
    border-radius: 9px !important;
    color: rgba(232, 241, 252, .72) !important;
    background: rgba(255, 255, 255, .035) !important;
    font-weight: 800 !important;
  }

  .track-table td:nth-child(1):has(input:checked) + td:nth-child(2) {
    color: #91d6ff !important;
    background: rgba(53, 168, 255, .14) !important;
  }

  .track-table td:nth-child(1) input {
    opacity: 0 !important;
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    cursor: pointer !important;
  }

  .track-table td:nth-child(3) {
    grid-column: 2 !important;
    grid-row: 1 !important;
    color: #edf6ff !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .track-table td:nth-child(6) {
    grid-column: 3 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    font-variant-numeric: tabular-nums !important;
    text-align: right !important;
  }

  .track-table td:nth-child(7) {
    grid-column: 4 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    text-align: center !important;
  }

  .track-table td:nth-child(9) {
    grid-column: 5 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 4px !important;
  }

  .track-table .load-cell button {
    height: 28px !important;
    min-height: 28px !important;
    border-radius: 8px !important;
    font-size: 11px !important;
  }

  .track-table .load-cell button[data-load="A"] {
    color: #91d6ff !important;
    border-color: rgba(53, 168, 255, .42) !important;
  }

  .track-table .load-cell button[data-load="B"] {
    color: #ffc778 !important;
    border-color: rgba(255, 142, 18, .42) !important;
  }

  .toast-region {
    left: 10px !important;
    right: 10px !important;
    bottom: max(10px, env(safe-area-inset-bottom)) !important;
  }
}

@media (max-width: 390px) {
  .app-shell {
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  .brand-copy small,
  .record-pill time {
    display: none !important;
  }

  .record-pill {
    min-width: 66px !important;
  }

  .grid-panel {
    grid-template-columns: minmax(108px, 1.3fr) repeat(4, minmax(38px, 1fr)) !important;
  }

  .grid-actions button:nth-child(n+5) {
    display: none !important;
  }

  .deck-body {
    grid-template-columns: 62px minmax(0, 1fr) 94px !important;
    gap: 8px !important;
  }

  .platter {
    width: min(100%, 190px, 50vw) !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    min-height: 31px !important;
    height: 31px !important;
    font-size: 10px !important;
  }

  .mixer {
    grid-template-columns: minmax(0, 1fr) 86px minmax(0, 1fr) !important;
  }

  .track-table thead tr {
    grid-template-columns: 28px 38px 1fr 60px 54px 52px !important;
  }

  .track-table tbody tr {
    grid-template-columns: 34px minmax(0, 1fr) 58px 42px 54px !important;
  }
}


/* DJ Mixer Practice SEO layer: compact above the app, deeper content below it. */
.seo-hero,
.seo-content {
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.018)),
    rgba(7, 11, 17, 0.88);
  border-radius: var(--radius-lg);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
}

.seo-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 14px;
  padding: 14px 18px;
}

.seo-eyebrow {
  margin: 0 0 6px;
  color: #91d6ff;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.seo-hero h1,
.seo-section-heading h2,
.seo-faq h2 {
  margin: 0;
  letter-spacing: -0.03em;
}

.seo-hero h1 {
  font-size: clamp(24px, 3vw, 42px);
  line-height: 0.98;
}

.seo-hero p:last-child {
  max-width: 820px;
  margin: 8px 0 0;
  color: #b8c5d2;
  line-height: 1.45;
}

.seo-hero-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  max-width: 520px;
}

.seo-hero-links a,
.seo-footer nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: #eaf6ff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
  font-size: 13px;
  font-weight: 800;
}

.seo-hero-links a:hover,
.seo-footer nav a:hover {
  border-color: rgba(143, 214, 255, 0.52);
  background: rgba(47, 155, 255, 0.14);
}

.seo-content {
  width: 100%;
  max-width: none;
  margin: 22px 0 0;
  padding: clamp(16px, 2.2vw, 28px);
}

.seo-section-heading {
  max-width: 820px;
}

.seo-section-heading h2,
.seo-faq h2 {
  font-size: clamp(21px, 2vw, 30px);
  line-height: 1.08;
}

.seo-feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.seo-feature-grid article,
.seo-faq details,
.seo-long-copy,
.seo-footer {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.seo-feature-grid article {
  padding: 16px;
}

.seo-feature-grid h3 {
  margin: 0 0 8px;
  font-size: 16px;
}

.seo-feature-grid p,
.seo-long-copy p,
.seo-faq p,
.seo-footer p {
  color: #b8c5d2;
  line-height: 1.62;
}

.seo-feature-grid p {
  margin: 0;
  font-size: 14px;
}

.seo-long-copy {
  margin-top: 14px;
  padding: 18px;
}

.seo-long-copy p {
  margin: 0 0 14px;
}

.seo-long-copy p:last-child {
  margin-bottom: 0;
}

.seo-faq {
  margin-top: 26px;
}

.faq-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.seo-faq details {
  padding: 14px 16px;
}

.seo-faq summary {
  cursor: pointer;
  color: #edf6ff;
  font-weight: 850;
}

.seo-faq p {
  margin: 10px 0 0;
}

.seo-footer {
  margin-top: 18px;
  padding: 16px;
}

.seo-footer p {
  margin: 0 0 12px;
}

.seo-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

@media (max-width: 1180px) {
  .seo-hero {
    grid-template-columns: 1fr;
  }
  .seo-hero-links {
    justify-content: flex-start;
  }
  .seo-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .seo-hero {
    margin-top: 8px;
    padding: 12px;
  }
  .seo-hero h1 {
    font-size: 24px;
  }
  .seo-hero p:last-child {
    font-size: 13px;
  }
  .seo-hero-links a {
    min-height: 30px;
    font-size: 12px;
    padding: 0 10px;
  }
  .seo-content {
    margin-top: 14px;
    padding: 14px;
  }
  .seo-feature-grid,
  .faq-list {
    grid-template-columns: 1fr;
  }
}


/* v1.47 app-first responsive layout recovery
   Scope: fixes the SEO placement, desktop whitespace regressions, mobile deck composition,
   and beat-grid status/button overlap introduced during the v1.46 mobile refactor. */
.seo-hero-below-app {
  margin: 22px auto 0 !important;
  max-width: 1180px !important;
}

@media (min-width: 1181px) {
  html,
  body {
    min-width: 1180px !important;
    overflow-x: auto !important;
  }

  .app-shell {
    width: min(100%, 1920px) !important;
    max-width: 1920px !important;
    padding: 12px 14px 32px !important;
  }

  .topbar {
    position: sticky !important;
    top: 8px !important;
    z-index: 60 !important;
    grid-template-columns: minmax(260px, 1fr) auto !important;
    height: 58px !important;
    min-height: 58px !important;
    padding: 8px 14px !important;
    margin: 0 !important;
  }

  .brand-copy small {
    display: inline !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 5.1fr) minmax(248px, 292px) minmax(0, 5.1fr) !important;
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: 604px minmax(520px, auto) auto !important;
    gap: 12px !important;
    align-items: start !important;
    margin-top: 12px !important;
    width: 100% !important;
  }

  .deck-a { grid-area: deckA !important; }
  .deck-b { grid-area: deckB !important; }
  .mixer { grid-area: mixer !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer {
    height: 604px !important;
    min-height: 604px !important;
    max-height: 604px !important;
    align-self: start !important;
    overflow: hidden !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: 42px 46px 66px 28px 22px minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 12px !important;
  }

  .deck-header {
    grid-row: 1 !important;
    height: 42px !important;
    min-height: 42px !important;
    grid-template-columns: 40px minmax(0, 1fr) 92px !important;
    gap: 11px !important;
  }

  .deck-badge {
    width: 38px !important;
    height: 38px !important;
    font-size: 17px !important;
  }

  .track-title-block h2 {
    font-size: 16px !important;
    line-height: 1.05 !important;
  }

  .track-title-block p {
    font-size: 11px !important;
    margin-top: 4px !important;
  }

  .deck-meta {
    min-width: 0 !important;
  }

  .deck-meta strong,
  .bpm-edit-button strong {
    font-size: 15px !important;
  }

  .deck-meta span,
  .bpm-edit-button span {
    font-size: 9px !important;
  }

  .deck-meta em {
    font-size: 13px !important;
  }

  .deck-feedback {
    position: absolute !important;
    top: 58px !important;
    left: 72px !important;
    right: 72px !important;
    z-index: 7 !important;
    width: auto !important;
    height: 16px !important;
    min-height: 16px !important;
    margin: 0 !important;
    padding: 0 8px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    pointer-events: none !important;
    font-size: 8px !important;
    letter-spacing: .13em !important;
    opacity: .88 !important;
  }

  .grid-panel {
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: minmax(128px, 168px) minmax(0, 1fr) !important;
    gap: 7px !important;
    align-items: stretch !important;
    min-height: 46px !important;
    height: 46px !important;
    margin: 0 !important;
    padding: 6px !important;
    overflow: hidden !important;
  }

  .grid-readout {
    min-width: 0 !important;
    height: 100% !important;
    padding: 4px 8px !important;
    overflow: hidden !important;
  }

  .grid-readout strong,
  .grid-readout span {
    display: block !important;
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .grid-readout strong { font-size: 10px !important; }
  .grid-readout span { font-size: 8.5px !important; }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  .grid-actions button {
    min-width: 0 !important;
    width: 100% !important;
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 3px !important;
    font-size: 8.5px !important;
    letter-spacing: .02em !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .wave-wrap {
    grid-row: 3 !important;
    height: 66px !important;
    min-height: 66px !important;
    margin: 0 !important;
  }

  .zoom-waveform {
    grid-row: 4 !important;
    display: block !important;
    height: 28px !important;
    min-height: 28px !important;
    margin: 0 !important;
  }

  .time-row {
    grid-row: 5 !important;
    height: 22px !important;
    min-height: 22px !important;
    margin: 0 !important;
  }

  .time-row time {
    font-size: 11px !important;
  }

  .deck-body {
    grid-row: 6 !important;
    display: grid !important;
    grid-template-columns: 90px minmax(235px, 1fr) 160px !important;
    gap: 10px !important;
    min-height: 0 !important;
    height: 100% !important;
    overflow: hidden !important;
    align-items: stretch !important;
  }

  .tempo-column {
    width: 90px !important;
    min-width: 90px !important;
    height: 100% !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 32px 22px 18px 22px 14px 24px minmax(0, 1fr) !important;
    gap: 5px !important;
    padding: 0 2px !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
    justify-items: center !important;
    align-items: center !important;
  }

  .tempo-column::before,
  .tempo-column::after {
    display: none !important;
    content: none !important;
  }

  .tempo-column .sync-button {
    grid-row: 1 !important;
    width: 86px !important;
    height: 32px !important;
    min-height: 32px !important;
    font-size: 10px !important;
  }

  .tempo-column .master-button {
    grid-row: 2 !important;
    width: 74px !important;
    height: 22px !important;
    min-height: 22px !important;
    border-radius: 999px !important;
    font-size: 8px !important;
  }

  .tempo-column .sync-status {
    grid-row: 3 !important;
    width: 74px !important;
    max-width: 74px !important;
    height: 18px !important;
    min-height: 18px !important;
    font-size: 7.5px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-row: 4 !important;
    height: 22px !important;
    font-size: 13px !important;
    line-height: 1 !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-row: 5 !important;
    height: 14px !important;
    font-size: 9px !important;
  }

  .tempo-column .range-button {
    grid-row: 6 !important;
    width: 50px !important;
    height: 24px !important;
    min-height: 24px !important;
    font-size: 10px !important;
  }

  .tempo-column .vertical-slider {
    grid-row: 7 !important;
    width: 72px !important;
    height: 100% !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-rows: 12px minmax(0, 1fr) 12px !important;
    place-items: center !important;
    overflow: visible !important;
    margin: 0 !important;
  }

  .tempo-column .vertical-slider input {
    width: 168px !important;
    max-width: 168px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: grid !important;
    grid-template-rows: minmax(0, 1fr) 46px !important;
    gap: 10px !important;
    min-height: 0 !important;
    height: 100% !important;
    overflow: hidden !important;
    align-items: center !important;
    justify-items: stretch !important;
  }

  .platter {
    width: clamp(245px, 17vw, 325px) !important;
    min-height: 0 !important;
    max-width: calc(100% - 8px) !important;
    max-height: calc(100% - 8px) !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .transport-row {
    height: 46px !important;
    min-height: 46px !important;
    grid-template-columns: minmax(95px, 1fr) minmax(120px, 1fr) 42px !important;
    gap: 8px !important;
  }

  .transport-row button {
    height: 46px !important;
    min-height: 46px !important;
    font-size: 13px !important;
  }

  .deck-tools {
    display: grid !important;
    grid-template-rows: auto auto 30px !important;
    gap: 7px !important;
    min-height: 0 !important;
    height: 100% !important;
    overflow: hidden !important;
    align-content: start !important;
  }

  .loop-box,
  .hotcue-box {
    padding: 7px !important;
  }

  .loop-box label,
  .hotcue-box label {
    margin-bottom: 5px !important;
    font-size: 9px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 24px !important;
    min-height: 24px !important;
    font-size: 8.5px !important;
  }

  .loop-toggle {
    margin-top: 6px !important;
  }

  .loop-extra-row {
    margin-top: 5px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(3, 30px) !important;
    gap: 5px !important;
  }

  .hotcue-grid button {
    height: 30px !important;
    min-height: 30px !important;
    font-size: 12px !important;
  }

  .deck-options {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
    min-height: 30px !important;
  }

  .deck-options button {
    height: 30px !important;
    min-height: 30px !important;
    font-size: 8.5px !important;
    padding: 0 2px !important;
  }

  .mixer {
    display: grid !important;
    grid-template-columns: 1fr 1.06fr 1fr !important;
    gap: 8px !important;
    padding: 10px !important;
  }

  .channel-strip,
  .master-strip {
    min-height: 0 !important;
    padding: 8px 7px !important;
    gap: 6px !important;
    overflow: hidden !important;
  }

  .channel-strip h3,
  .master-strip h3 {
    font-size: 11px !important;
  }

  .channel-strip label,
  .master-strip label {
    font-size: 8.5px !important;
  }

  .channel-cue {
    height: 27px !important;
    min-height: 27px !important;
  }

  .channel-meter {
    height: 20px !important;
  }

  .channel-fader input {
    height: 72px !important;
  }

  .meter-shell {
    height: 150px !important;
  }

  #masterMeter {
    height: 138px !important;
    width: 50px !important;
  }

  .library-panel {
    min-height: 520px !important;
    height: auto !important;
    display: grid !important;
    grid-template-columns: 140px minmax(0, 1fr) !important;
    overflow: hidden !important;
  }

  .library-main {
    min-height: 520px !important;
    grid-template-rows: 50px 32px 36px minmax(0, 1fr) !important;
  }

  .panel-header {
    grid-template-columns: minmax(140px, 190px) 116px minmax(260px, 1fr) 126px 150px minmax(76px, auto) !important;
    gap: 10px !important;
    padding: 9px 12px !important;
  }

  .search {
    min-width: 260px !important;
  }

  .table-wrap {
    max-height: none !important;
    min-height: 0 !important;
    overflow: auto !important;
  }

  .track-table {
    width: 100% !important;
    min-width: 1180px !important;
    table-layout: fixed !important;
  }

  .recording-panel,
  .cue-panel {
    min-height: 330px !important;
    height: auto !important;
    overflow: visible !important;
  }

  .seo-hero,
  .seo-content {
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

@media (max-width: 1500px) and (min-width: 1181px) {
  .main-grid {
    grid-template-columns: minmax(0, 5fr) minmax(232px, 272px) minmax(0, 5fr) !important;
    grid-template-rows: 584px minmax(500px, auto) auto !important;
    gap: 10px !important;
  }

  .deck,
  .mixer {
    height: 584px !important;
    min-height: 584px !important;
    max-height: 584px !important;
  }

  .deck {
    grid-template-rows: 40px 72px 62px 26px 22px minmax(0, 1fr) !important;
    padding: 10px !important;
  }

  .grid-panel {
    height: 72px !important;
    min-height: 72px !important;
    grid-template-columns: minmax(110px, 1fr) !important;
    gap: 5px !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .grid-actions button {
    height: 22px !important;
    min-height: 22px !important;
    font-size: 8px !important;
  }

  .deck-body {
    grid-template-columns: 86px minmax(200px, 1fr) 148px !important;
    gap: 8px !important;
  }

  .tempo-column {
    width: 86px !important;
    min-width: 86px !important;
  }

  .tempo-column .sync-button {
    width: 82px !important;
    font-size: 9px !important;
  }

  .tempo-column .vertical-slider input {
    width: 152px !important;
  }

  .platter {
    width: clamp(205px, 15vw, 268px) !important;
  }

  .hotcue-grid button {
    height: 28px !important;
    min-height: 28px !important;
  }

  .panel-header {
    grid-template-columns: minmax(120px, 160px) 108px minmax(230px, 1fr) 118px 130px minmax(66px, auto) !important;
  }

  .search {
    min-width: 220px !important;
  }
}

@media (max-width: 1180px) and (min-width: 761px) {
  html,
  body {
    min-width: 0 !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    max-width: 980px !important;
    padding: 10px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
  }

  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .deck {
    grid-template-rows: auto auto auto auto auto auto !important;
  }

  .grid-panel {
    grid-template-columns: minmax(140px, 180px) minmax(0, 1fr) !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .deck-body {
    grid-template-columns: 90px minmax(250px, 1fr) 170px !important;
    min-height: 420px !important;
  }

  .library-panel {
    min-height: 520px !important;
  }
}

@media (max-width: 760px) {
  html,
  body {
    min-width: 0 !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 430px !important;
    margin: 0 auto !important;
    padding: max(8px, env(safe-area-inset-top)) 8px 24px !important;
  }

  .topbar {
    position: sticky !important;
    top: max(8px, env(safe-area-inset-top)) !important;
    z-index: 70 !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 8px !important;
    min-height: 54px !important;
    height: auto !important;
    padding: 8px 9px !important;
    border-radius: 16px !important;
  }

  .brand {
    min-width: 0 !important;
    gap: 8px !important;
  }

  .brand-mark,
  .brand-mark svg {
    width: 30px !important;
    height: 30px !important;
    flex: 0 0 30px !important;
  }

  .brand-copy {
    min-width: 0 !important;
    gap: 6px !important;
  }

  .brand-copy strong {
    font-size: 13px !important;
    white-space: nowrap !important;
  }

  .brand-copy small {
    display: inline !important;
    font-size: 9px !important;
  }

  .status-strip {
    gap: 5px !important;
    justify-self: end !important;
    flex-wrap: nowrap !important;
  }

  .icon-status,
  .record-pill {
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 8px !important;
    border-radius: 9px !important;
  }

  .icon-status {
    min-width: 78px !important;
    gap: 5px !important;
  }

  .icon-status i {
    background: #4a5564 !important;
    box-shadow: none !important;
  }

  .icon-status.active i {
    background: var(--club-green) !important;
    box-shadow: 0 0 12px rgba(97,226,90,.72) !important;
  }

  .record-pill {
    min-width: 82px !important;
    max-width: 86px !important;
    gap: 5px !important;
  }

  .record-pill em {
    display: none !important;
  }

  .record-pill b {
    display: inline !important;
    font-size: 10px !important;
  }

  .record-pill time {
    display: none !important;
  }

  .mobile-tabs {
    position: sticky !important;
    top: calc(max(8px, env(safe-area-inset-top)) + 62px) !important;
    z-index: 65 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 44px minmax(0, 1fr) !important;
    gap: 7px !important;
    margin: 9px 0 8px !important;
    padding: 7px !important;
    border-radius: 16px !important;
  }

  .mobile-tabs button {
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 11px !important;
    padding: 0 8px !important;
  }

  .deck-tab-badge {
    width: 32px !important;
    height: 32px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "library" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
    margin-top: 0 !important;
    align-items: start !important;
  }

  .deck-a,
  .deck-b {
    grid-area: deckA !important;
    grid-column: 1 !important;
    grid-row: 1 !important;
  }

  .mixer {
    grid-area: mixer !important;
    grid-column: 1 !important;
    grid-row: 2 !important;
  }

  .library-panel {
    grid-area: library !important;
    grid-column: 1 !important;
    grid-row: 3 !important;
  }

  .mobile-focus-a .deck-a,
  .mobile-focus-b .deck-b {
    display: grid !important;
  }

  .mobile-focus-a .deck-b,
  .mobile-focus-b .deck-a,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b,
  .recording-panel,
  .cue-panel {
    display: none !important;
  }

  .mobile-focus-a .mixer,
  .mobile-focus-b .mixer,
  .mobile-focus-a .library-panel,
  .mobile-focus-b .library-panel {
    display: grid !important;
  }

  .deck {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-rows: auto auto 76px 30px 22px auto !important;
    gap: 8px !important;
    padding: 10px !important;
    border-radius: 18px !important;
    overflow: hidden !important;
  }

  .deck-header {
    grid-row: 1 !important;
    grid-template-columns: 40px minmax(0, 1fr) auto !important;
    min-height: 42px !important;
    height: auto !important;
    gap: 9px !important;
  }

  .deck-badge {
    width: 38px !important;
    height: 38px !important;
    font-size: 17px !important;
  }

  .track-title-block h2 {
    font-size: 16px !important;
    line-height: 1.08 !important;
  }

  .track-title-block p {
    font-size: 11px !important;
  }

  .deck-meta {
    min-width: 76px !important;
  }

  .bpm-edit-button strong {
    font-size: 17px !important;
  }

  .deck-meta em {
    font-size: 14px !important;
  }

  .deck-feedback {
    display: none !important;
  }

  .grid-panel {
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 6px !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 7px !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  .grid-readout {
    min-height: 36px !important;
    padding: 6px 8px !important;
  }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .grid-actions button {
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 3px !important;
    font-size: 9px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .wave-wrap {
    grid-row: 3 !important;
    height: 76px !important;
    min-height: 76px !important;
    margin: 0 !important;
    border-radius: 11px !important;
  }

  .zoom-waveform {
    grid-row: 4 !important;
    display: block !important;
    height: 30px !important;
    min-height: 30px !important;
    margin: 0 !important;
    border-radius: 9px !important;
  }

  .time-row {
    grid-row: 5 !important;
    height: 22px !important;
    min-height: 22px !important;
    margin: 0 !important;
  }

  .deck-body {
    grid-row: 6 !important;
    display: grid !important;
    grid-template-columns: 66px minmax(0, 1fr) 102px !important;
    grid-template-rows: auto auto auto !important;
    gap: 9px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  .tempo-column {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    width: 66px !important;
    min-width: 66px !important;
    min-height: 250px !important;
    height: auto !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 36px 22px 22px 20px minmax(135px, 1fr) !important;
    gap: 7px !important;
    padding: 8px 6px !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .44) !important;
  }

  .tempo-column .sync-button {
    grid-row: 1 !important;
    width: 100% !important;
    height: 36px !important;
    min-height: 36px !important;
    font-size: 10px !important;
    padding: 0 3px !important;
  }

  .tempo-column .master-button {
    grid-row: 2 !important;
    height: 22px !important;
    min-height: 22px !important;
    border-radius: 999px !important;
    font-size: 7.5px !important;
    padding: 0 2px !important;
  }

  .sync-status,
  .sync-primer,
  .phase-meter,
  .tempo-column .range-button {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-row: 3 !important;
    font-size: 13px !important;
    line-height: 1 !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-row: 4 !important;
    font-size: 10px !important;
  }

  .tempo-column .vertical-slider {
    grid-row: 5 !important;
    height: 140px !important;
    min-height: 140px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .tempo-column .vertical-slider input {
    width: 130px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-column: 2 !important;
    grid-row: 1 !important;
    display: grid !important;
    width: min(100%, 200px, 51vw) !important;
    min-height: 0 !important;
    align-self: center !important;
    justify-self: center !important;
  }

  .transport-row {
    grid-column: 2 / 4 !important;
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr 1.1fr 54px !important;
    gap: 8px !important;
    width: 100% !important;
    height: 50px !important;
    min-height: 50px !important;
  }

  .transport-row button {
    height: 50px !important;
    min-height: 50px !important;
    border-radius: 10px !important;
    font-size: 13px !important;
  }

  .play-button {
    font-size: 17px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-column: 3 !important;
    grid-row: 1 !important;
    display: grid !important;
    gap: 5px !important;
    padding: 8px 7px !important;
    align-content: center !important;
    border-radius: 12px !important;
  }

  .loop-box label,
  .hotcue-box label {
    font-size: 9px !important;
    margin-bottom: 1px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 31px !important;
    min-height: 31px !important;
    font-size: 9.5px !important;
  }

  .loop-extra-row {
    margin-top: 0 !important;
  }

  .hotcue-box {
    grid-column: 1 / 3 !important;
    grid-row: 3 !important;
    padding: 9px !important;
    border-radius: 12px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .hotcue-grid button {
    height: 38px !important;
    min-height: 38px !important;
    font-size: 14px !important;
  }

  .deck-options {
    grid-column: 3 !important;
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 5px !important;
  }

  .deck-options button {
    min-height: 38px !important;
    height: auto !important;
    font-size: 8.5px !important;
    border-radius: 9px !important;
    padding: 0 2px !important;
  }

  .mixer {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 88px minmax(0, 1fr) !important;
    gap: 7px !important;
    padding: 9px !important;
    border-radius: 18px !important;
  }

  .channel-strip,
  .master-strip {
    min-height: 0 !important;
    height: auto !important;
    border-radius: 12px !important;
    padding: 8px 7px !important;
    background: rgba(2, 6, 10, .40) !important;
  }

  .channel-strip {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .channel-strip h3,
  .channel-strip label:has([data-role="gain"]),
  .channel-strip label:has([data-role="filter"]),
  .channel-strip .channel-cue,
  .channel-strip .channel-meter,
  .channel-strip .xfade-assign {
    display: none !important;
  }

  .channel-strip label {
    display: grid !important;
    gap: 4px !important;
    font-size: 8.5px !important;
    text-align: center !important;
  }

  .channel-strip label:has([data-role="fader"]) {
    grid-column: 1 / -1 !important;
    grid-row: 1 !important;
  }

  .channel-strip label:has([data-role="eq-low"]) { grid-column: 1 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-mid"]) { grid-column: 2 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-high"]) { grid-column: 3 !important; grid-row: 2 !important; }

  .channel-strip input[type="range"],
  .channel-fader input {
    writing-mode: horizontal-tb !important;
    appearance: auto !important;
    width: 100% !important;
    height: 20px !important;
  }

  .master-strip {
    grid-column: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 6px !important;
  }

  .master-strip h3,
  .master-knob,
  .meter-shell,
  .cue-mix-control,
  .cue-level-control,
  .xfade-curve {
    display: none !important;
  }

  .headphone-status {
    display: grid !important;
    justify-items: center !important;
    gap: 4px !important;
    font-size: 8.5px !important;
  }

  .crossfader {
    display: grid !important;
    grid-template-columns: auto 1fr auto !important;
    gap: 4px !important;
    font-size: 9px !important;
  }

  .library-panel {
    display: grid !important;
    grid-template-columns: 1fr !important;
    min-height: 320px !important;
    height: auto !important;
    border-radius: 20px 20px 16px 16px !important;
    overflow: hidden !important;
  }

  .library-panel::before {
    content: "" !important;
    width: 52px !important;
    height: 5px !important;
    border-radius: 999px !important;
    background: rgba(220, 235, 255, .28) !important;
    justify-self: center !important;
    margin-top: 9px !important;
  }

  .side-nav,
  .storage-dashboard,
  .drop-hint,
  .import-progress {
    display: none !important;
  }

  .library-main {
    min-height: 0 !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) !important;
  }

  .panel-header {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    gap: 8px !important;
    padding: 11px 11px 9px !important;
    background: transparent !important;
  }

  .panel-header > div {
    grid-column: 1 / -1 !important;
    display: flex !important;
    align-items: baseline !important;
    gap: 9px !important;
  }

  .panel-header strong {
    font-size: 18px !important;
  }

  .panel-header span {
    font-size: 11px !important;
  }

  .import-button {
    grid-column: 1 !important;
    grid-row: 2 !important;
    height: 38px !important;
    justify-content: center !important;
  }

  .danger-small {
    grid-column: 2 !important;
    grid-row: 2 !important;
    height: 38px !important;
    padding: 0 10px !important;
  }

  .search {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    min-width: 0 !important;
    width: 100% !important;
    height: 40px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
  }

  .panel-header em {
    grid-column: 1 / -1 !important;
    grid-row: 4 !important;
    justify-self: start !important;
    font-size: 11px !important;
  }

  .table-wrap {
    max-height: 420px !important;
    min-height: 0 !important;
    overflow: auto !important;
    padding: 0 9px 12px !important;
  }

  .track-table,
  .track-table thead,
  .track-table tbody,
  .track-table tr,
  .track-table th,
  .track-table td {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .track-table thead {
    position: sticky !important;
    top: 0 !important;
    z-index: 2 !important;
    padding: 0 0 8px !important;
    background: rgba(7, 12, 18, .98) !important;
  }

  .track-table thead tr {
    display: grid !important;
    grid-template-columns: 28px 40px 1fr 62px 56px 52px !important;
    gap: 4px !important;
    align-items: center !important;
  }

  .track-table th {
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  .track-table th:nth-child(4),
  .track-table th:nth-child(5),
  .track-table th:nth-child(8),
  .track-table td:nth-child(4),
  .track-table td:nth-child(5),
  .track-table td:nth-child(8) {
    display: none !important;
  }

  .sort-header {
    min-height: 32px !important;
    height: 32px !important;
    padding: 0 6px !important;
    justify-content: center !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 9px !important;
    background: rgba(255, 255, 255, .035) !important;
    font-size: 9px !important;
  }

  .track-table tbody {
    display: grid !important;
    gap: 8px !important;
  }

  .track-table tbody tr {
    position: relative !important;
    display: grid !important;
    grid-template-columns: 36px minmax(0, 1fr) 60px 44px 56px !important;
    grid-template-rows: auto auto !important;
    gap: 3px 9px !important;
    align-items: center !important;
    min-height: 66px !important;
    padding: 10px !important;
    border: 1px solid rgba(154, 196, 238, .13) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .38) !important;
  }

  .track-table td {
    padding: 0 !important;
    border: 0 !important;
    min-width: 0 !important;
  }

  .track-table td:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    place-items: center !important;
  }

  .track-table td:nth-child(1) input {
    opacity: 0 !important;
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    cursor: pointer !important;
  }

  .track-table td:nth-child(2) {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    place-items: center !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 9px !important;
    background: rgba(255, 255, 255, .035) !important;
    font-weight: 800 !important;
  }

  .track-table td:nth-child(3) {
    grid-column: 2 !important;
    grid-row: 1 !important;
    color: #edf6ff !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .track-table td:nth-child(6) {
    grid-column: 3 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    text-align: right !important;
  }

  .track-table td:nth-child(7) {
    grid-column: 4 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    text-align: center !important;
  }

  .track-table td:nth-child(9) {
    grid-column: 5 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 4px !important;
  }

  .track-table .load-cell button {
    height: 27px !important;
    min-height: 27px !important;
    border-radius: 8px !important;
    font-size: 10px !important;
  }

  .seo-hero-below-app {
    margin-top: 18px !important;
  }

  .seo-hero {
    padding: 13px !important;
    border-radius: 16px !important;
  }

  .seo-content {
    margin-top: 12px !important;
    padding: 14px !important;
    border-radius: 16px !important;
  }
}

@media (max-width: 390px) {
  .app-shell {
    max-width: 390px !important;
  }

  .brand-copy small {
    display: none !important;
  }

  .record-pill {
    min-width: 62px !important;
  }

  .deck-body {
    grid-template-columns: 60px minmax(0, 1fr) 90px !important;
    gap: 8px !important;
  }

  .tempo-column {
    width: 60px !important;
    min-width: 60px !important;
  }

  .platter {
    width: min(100%, 178px, 50vw) !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 29px !important;
    min-height: 29px !important;
    font-size: 8.5px !important;
  }

  .mixer {
    grid-template-columns: minmax(0, 1fr) 82px minmax(0, 1fr) !important;
  }

  .track-table thead tr {
    grid-template-columns: 26px 36px 1fr 56px 50px 48px !important;
  }

  .track-table tbody tr {
    grid-template-columns: 32px minmax(0, 1fr) 56px 40px 52px !important;
  }
}

/* v1.48 responsive repair: restore a real center mixer on desktop, make phone controls fit, and keep deck status out of the beatgrid buttons. */
@media (min-width: 1261px) {
  html,
  body {
    min-width: 1260px !important;
    overflow-x: auto !important;
  }

  .app-shell {
    width: min(100%, 1920px) !important;
    max-width: 1920px !important;
    padding: 12px 14px 34px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) clamp(318px, 17.5vw, 376px) minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: 650px minmax(350px, auto) auto !important;
    gap: 12px !important;
    align-items: start !important;
    width: 100% !important;
    margin-top: 12px !important;
  }

  .deck-a { grid-area: deckA !important; }
  .deck-b { grid-area: deckB !important; }
  .mixer { grid-area: mixer !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer {
    height: 650px !important;
    min-height: 650px !important;
    max-height: 650px !important;
    overflow: hidden !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: 42px 18px 46px 68px 28px 22px minmax(0, 1fr) !important;
    gap: 7px !important;
    padding: 12px !important;
  }

  .deck-feedback {
    position: static !important;
    grid-row: 2 !important;
    width: 100% !important;
    height: 18px !important;
    min-height: 18px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    pointer-events: none !important;
    font-size: 8.5px !important;
    line-height: 1 !important;
    letter-spacing: .14em !important;
    opacity: .78 !important;
    transform: none !important;
    z-index: 1 !important;
  }

  .deck.has-feedback .deck-feedback {
    opacity: .96 !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: minmax(132px, 172px) minmax(0, 1fr) !important;
    gap: 7px !important;
    height: 46px !important;
    min-height: 46px !important;
    margin: 0 !important;
    padding: 6px !important;
    overflow: hidden !important;
  }

  .grid-readout {
    min-width: 0 !important;
    height: 100% !important;
    padding: 4px 8px !important;
    overflow: hidden !important;
  }

  .grid-readout strong,
  .grid-readout span {
    display: block !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  .grid-actions button {
    width: 100% !important;
    min-width: 0 !important;
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 3px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    font-size: 8.5px !important;
  }

  .wave-wrap { grid-row: 4 !important; height: 68px !important; min-height: 68px !important; margin: 0 !important; }
  .zoom-waveform { grid-row: 5 !important; display: block !important; height: 28px !important; min-height: 28px !important; margin: 0 !important; }
  .time-row { grid-row: 6 !important; height: 22px !important; min-height: 22px !important; margin: 0 !important; }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: 92px minmax(250px, 1fr) 172px !important;
    gap: 10px !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  .tempo-column {
    width: 92px !important;
    min-width: 92px !important;
    height: 100% !important;
    padding: 0 2px !important;
    gap: 5px !important;
    grid-template-rows: 32px 22px 18px 22px 14px 24px minmax(0, 1fr) !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .platter-zone {
    display: grid !important;
    grid-template-rows: minmax(0, 1fr) 48px !important;
    gap: 10px !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  .platter {
    width: clamp(275px, 16.5vw, 340px) !important;
    max-width: calc(100% - 10px) !important;
    max-height: calc(100% - 10px) !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .transport-row {
    height: 48px !important;
    min-height: 48px !important;
    grid-template-columns: minmax(110px, 1fr) minmax(132px, 1fr) 44px !important;
    gap: 8px !important;
  }

  .transport-row button {
    height: 48px !important;
    min-height: 48px !important;
  }

  .deck-tools {
    display: grid !important;
    grid-template-rows: auto auto 32px !important;
    gap: 8px !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: hidden !important;
    align-content: start !important;
  }

  .loop-box,
  .hotcue-box {
    padding: 8px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 25px !important;
    min-height: 25px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(3, 31px) !important;
    gap: 5px !important;
  }

  .deck-options {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .deck-options button {
    min-height: 32px !important;
    height: 32px !important;
  }

  .mixer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(92px, 1.08fr) minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 10px !important;
  }

  .channel-strip,
  .master-strip {
    min-height: 0 !important;
    padding: 8px 7px !important;
    gap: 6px !important;
    overflow: hidden !important;
  }

  .meter-shell {
    height: 162px !important;
  }

  #masterMeter {
    width: 56px !important;
    height: 150px !important;
  }

  .channel-fader input {
    height: 86px !important;
  }

  .library-panel {
    display: grid !important;
    grid-template-columns: 140px minmax(0, 1fr) !important;
    min-height: 360px !important;
    height: auto !important;
    overflow: hidden !important;
  }

  .library-main {
    min-height: 360px !important;
    grid-template-rows: 50px 32px 36px minmax(0, 1fr) !important;
  }

  .table-wrap {
    overflow: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .track-table {
    min-width: 1180px !important;
    table-layout: fixed !important;
  }

  .recording-panel,
  .cue-panel {
    min-height: 300px !important;
    height: auto !important;
    overflow: visible !important;
  }

  .seo-hero-below-app {
    margin-top: 22px !important;
  }
}

@media (max-width: 1560px) and (min-width: 1261px) {
  .main-grid {
    grid-template-columns: minmax(0, 1fr) clamp(304px, 18vw, 342px) minmax(0, 1fr) !important;
    grid-template-rows: 632px minmax(340px, auto) auto !important;
  }

  .deck,
  .mixer {
    height: 632px !important;
    min-height: 632px !important;
    max-height: 632px !important;
  }

  .deck-body {
    grid-template-columns: 86px minmax(215px, 1fr) 154px !important;
    gap: 8px !important;
  }

  .tempo-column {
    width: 86px !important;
    min-width: 86px !important;
  }

  .platter {
    width: clamp(235px, 16vw, 300px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(94px, 1fr) minmax(116px, 1fr) 42px !important;
    gap: 7px !important;
  }

  .grid-panel {
    grid-template-columns: 1fr !important;
    height: 72px !important;
    min-height: 72px !important;
    gap: 5px !important;
  }

  .deck {
    grid-template-rows: 42px 18px 72px 62px 26px 22px minmax(0, 1fr) !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .grid-actions button {
    height: 22px !important;
    min-height: 22px !important;
    font-size: 8px !important;
  }

  .wave-wrap { height: 62px !important; min-height: 62px !important; }
  .zoom-waveform { height: 26px !important; min-height: 26px !important; }
}

@media (max-width: 1260px) and (min-width: 761px) {
  html,
  body {
    min-width: 0 !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    max-width: 980px !important;
    width: 100% !important;
    padding: 10px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
  }

  .deck-a { grid-area: deckA !important; }
  .mixer { grid-area: mixer !important; }
  .deck-b { grid-area: deckB !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer,
  .library-panel,
  .recording-panel,
  .cue-panel {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: auto 18px auto auto auto auto auto !important;
    gap: 8px !important;
  }

  .deck-feedback {
    position: static !important;
    grid-row: 2 !important;
    height: 18px !important;
    min-height: 18px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    display: grid !important;
    place-items: center !important;
    font-size: 8.5px !important;
    border-radius: 999px !important;
    transform: none !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    grid-template-columns: minmax(150px, 190px) minmax(0, 1fr) !important;
    height: auto !important;
    min-height: 48px !important;
    overflow: visible !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .deck-body {
    grid-template-columns: 90px minmax(260px, 1fr) 180px !important;
    min-height: 430px !important;
    height: auto !important;
    overflow: visible !important;
  }

  .mixer {
    grid-template-columns: minmax(0, 1fr) minmax(130px, .8fr) minmax(0, 1fr) !important;
  }

  .library-panel {
    min-height: 360px !important;
  }
}

@media (max-width: 760px) {
  html,
  body {
    min-width: 0 !important;
    width: 100% !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 440px !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    padding: max(8px, env(safe-area-inset-top)) 6px 24px !important;
  }

  .topbar {
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 6px !important;
    min-width: 0 !important;
    padding: 8px !important;
    border-radius: 15px !important;
  }

  .brand {
    min-width: 0 !important;
  }

  .brand-mark,
  .brand-mark svg {
    width: 28px !important;
    height: 28px !important;
    flex: 0 0 28px !important;
  }

  .brand-copy {
    min-width: 0 !important;
    gap: 5px !important;
  }

  .brand-copy strong {
    min-width: 0 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    font-size: 12px !important;
  }

  .brand-copy small {
    font-size: 8.5px !important;
  }

  .status-strip {
    gap: 4px !important;
    min-width: 0 !important;
  }

  .icon-status,
  .record-pill {
    height: 32px !important;
    min-height: 32px !important;
    padding: 0 7px !important;
    border-radius: 9px !important;
  }

  .icon-status {
    min-width: 68px !important;
    gap: 4px !important;
  }

  .icon-status [data-status-label] {
    font-size: 11px !important;
    white-space: nowrap !important;
  }

  .record-pill {
    min-width: 58px !important;
    max-width: 64px !important;
    gap: 4px !important;
  }

  .record-pill em,
  .record-pill time {
    display: none !important;
  }

  .record-pill span {
    width: 10px !important;
    height: 10px !important;
  }

  .record-pill b {
    font-size: 9px !important;
  }

  .mobile-tabs {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 38px minmax(0, 1fr) !important;
    gap: 6px !important;
    margin: 8px 0 !important;
    padding: 6px !important;
    border-radius: 15px !important;
    min-width: 0 !important;
  }

  .mobile-tabs button {
    min-width: 0 !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 6px !important;
  }

  .mobile-deck-tab b {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    font-size: 12px !important;
  }

  .deck-tab-badge {
    width: 30px !important;
    height: 30px !important;
    flex: 0 0 30px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA"
      "mixer"
      "library" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    gap: 9px !important;
    min-width: 0 !important;
    width: 100% !important;
    margin-top: 0 !important;
  }

  .deck-a,
  .deck-b {
    grid-area: deckA !important;
    grid-column: 1 !important;
    grid-row: 1 !important;
    min-width: 0 !important;
  }

  .mixer {
    grid-area: mixer !important;
    grid-column: 1 !important;
    grid-row: 2 !important;
    min-width: 0 !important;
  }

  .library-panel {
    grid-area: library !important;
    grid-column: 1 !important;
    grid-row: 3 !important;
    min-width: 0 !important;
  }

  .mobile-focus-a .deck-a,
  .mobile-focus-b .deck-b {
    display: grid !important;
  }

  .mobile-focus-a .deck-b,
  .mobile-focus-b .deck-a,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b,
  .recording-panel,
  .cue-panel {
    display: none !important;
  }

  .mobile-focus-a .mixer,
  .mobile-focus-b .mixer,
  .mobile-focus-a .library-panel,
  .mobile-focus-b .library-panel {
    display: grid !important;
  }

  .deck {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-rows: auto 18px auto 72px 28px 22px auto !important;
    gap: 7px !important;
    padding: 9px !important;
    border-radius: 17px !important;
    overflow: hidden !important;
  }

  .deck-header {
    grid-row: 1 !important;
    grid-template-columns: 36px minmax(0, 1fr) minmax(54px, 68px) !important;
    gap: 7px !important;
    min-width: 0 !important;
    min-height: 38px !important;
  }

  .deck-badge {
    width: 34px !important;
    height: 34px !important;
    font-size: 15px !important;
  }

  .track-title-block {
    min-width: 0 !important;
  }

  .track-title-block h2 {
    font-size: 14px !important;
    line-height: 1.08 !important;
  }

  .track-title-block p {
    font-size: 10px !important;
    margin-top: 3px !important;
  }

  .deck-meta {
    min-width: 0 !important;
    gap: 0 4px !important;
  }

  .bpm-edit-button,
  .deck-meta button {
    min-width: 0 !important;
  }

  .bpm-edit-button strong,
  .deck-meta strong {
    font-size: 13px !important;
  }

  .bpm-edit-button span,
  .deck-meta span {
    font-size: 8px !important;
  }

  .deck-meta em {
    font-size: 11px !important;
  }

  .deck-feedback {
    position: static !important;
    grid-row: 2 !important;
    display: grid !important;
    width: 100% !important;
    height: 18px !important;
    min-height: 18px !important;
    margin: 0 !important;
    padding: 0 8px !important;
    place-items: center !important;
    border-radius: 999px !important;
    pointer-events: none !important;
    font-size: 8px !important;
    line-height: 1 !important;
    letter-spacing: .12em !important;
    opacity: .75 !important;
    transform: none !important;
    z-index: 1 !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 5px !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 6px !important;
    overflow: visible !important;
  }

  .grid-readout {
    min-width: 0 !important;
    height: 32px !important;
    min-height: 32px !important;
    padding: 5px 8px !important;
  }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 4px !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .grid-actions button {
    min-width: 0 !important;
    width: 100% !important;
    height: 31px !important;
    min-height: 31px !important;
    padding: 0 2px !important;
    font-size: 8px !important;
    line-height: 1 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .wave-wrap {
    grid-row: 4 !important;
    height: 72px !important;
    min-height: 72px !important;
    margin: 0 !important;
    border-radius: 10px !important;
  }

  .zoom-waveform {
    grid-row: 5 !important;
    display: block !important;
    height: 28px !important;
    min-height: 28px !important;
    margin: 0 !important;
  }

  .time-row {
    grid-row: 6 !important;
    height: 22px !important;
    min-height: 22px !important;
    margin: 0 !important;
    gap: 6px !important;
  }

  .time-row time {
    font-size: 10px !important;
  }

  .deck-body {
    grid-row: 7 !important;
    width: 100% !important;
    max-width: 100% !important;
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) 94px !important;
    grid-template-rows: auto auto auto !important;
    gap: 7px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-items: start !important;
  }

  .tempo-column {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    width: 58px !important;
    min-width: 58px !important;
    min-height: 236px !important;
    height: auto !important;
    grid-template-rows: 32px 20px 20px 18px minmax(126px, 1fr) !important;
    gap: 6px !important;
    padding: 7px 5px !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .44) !important;
  }

  .tempo-column .sync-button {
    width: 100% !important;
    height: 32px !important;
    min-height: 32px !important;
    font-size: 8.5px !important;
    padding: 0 2px !important;
  }

  .tempo-column .master-button {
    height: 20px !important;
    min-height: 20px !important;
    font-size: 7px !important;
    padding: 0 2px !important;
  }

  .sync-status,
  .sync-primer,
  .phase-meter,
  .tempo-column .range-button {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    font-size: 12px !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    font-size: 9px !important;
  }

  .tempo-column .vertical-slider {
    height: 130px !important;
    min-height: 130px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .tempo-column .vertical-slider input {
    width: 122px !important;
    max-width: 122px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-column: 2 !important;
    grid-row: 1 !important;
    width: min(100%, 176px, 45vw) !important;
    min-width: 0 !important;
    align-self: center !important;
    justify-self: center !important;
  }

  .transport-row {
    grid-column: 2 / 4 !important;
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr) 42px !important;
    gap: 6px !important;
    width: 100% !important;
    height: 46px !important;
    min-height: 46px !important;
  }

  .transport-row button {
    height: 46px !important;
    min-height: 46px !important;
    border-radius: 10px !important;
    font-size: 12px !important;
    padding: 0 4px !important;
  }

  .play-button {
    font-size: 16px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-column: 3 !important;
    grid-row: 1 !important;
    display: grid !important;
    gap: 4px !important;
    padding: 7px 6px !important;
    align-content: center !important;
    border-radius: 12px !important;
    min-width: 0 !important;
  }

  .loop-box label,
  .hotcue-box label {
    font-size: 8px !important;
    margin-bottom: 1px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 28px !important;
    min-height: 28px !important;
    font-size: 8px !important;
    padding: 0 2px !important;
  }

  .loop-extra-row {
    margin-top: 0 !important;
  }

  .hotcue-box {
    grid-column: 1 / 3 !important;
    grid-row: 3 !important;
    padding: 8px !important;
    border-radius: 12px !important;
    min-width: 0 !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .hotcue-grid button {
    height: 34px !important;
    min-height: 34px !important;
    font-size: 12px !important;
  }

  .hotcue-hint {
    display: none !important;
  }

  .deck-options {
    grid-column: 3 !important;
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  .deck-options button {
    min-height: 34px !important;
    height: auto !important;
    font-size: 7.5px !important;
    border-radius: 8px !important;
    padding: 0 2px !important;
  }

  .mixer {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 74px minmax(0, 1fr) !important;
    gap: 6px !important;
    padding: 8px !important;
    border-radius: 17px !important;
    overflow: hidden !important;
  }

  .channel-strip,
  .master-strip {
    min-width: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    border-radius: 11px !important;
    padding: 7px 5px !important;
    background: rgba(2, 6, 10, .40) !important;
  }

  .channel-strip {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .channel-strip h3,
  .channel-strip label:has([data-role="gain"]),
  .channel-strip label:has([data-role="filter"]),
  .channel-strip .channel-cue,
  .channel-strip .channel-meter,
  .channel-strip .xfade-assign {
    display: none !important;
  }

  .channel-strip label {
    display: grid !important;
    gap: 3px !important;
    font-size: 7.5px !important;
    text-align: center !important;
    min-width: 0 !important;
  }

  .channel-strip label:has([data-role="fader"]) {
    grid-column: 1 / -1 !important;
    grid-row: 1 !important;
  }

  .channel-strip label:has([data-role="eq-low"]) { grid-column: 1 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-mid"]) { grid-column: 2 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-high"]) { grid-column: 3 !important; grid-row: 2 !important; }

  .channel-strip input[type="range"],
  .channel-fader input {
    width: 100% !important;
    height: 18px !important;
    min-width: 0 !important;
    writing-mode: horizontal-tb !important;
    appearance: auto !important;
  }

  .master-strip {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 5px !important;
  }

  .master-strip h3,
  .master-knob,
  .meter-shell,
  .cue-mix-control,
  .cue-level-control,
  .xfade-curve {
    display: none !important;
  }

  .headphone-status {
    display: grid !important;
    justify-items: center !important;
    gap: 3px !important;
    font-size: 7.5px !important;
  }

  .crossfader {
    display: grid !important;
    grid-template-columns: auto 1fr auto !important;
    gap: 3px !important;
    font-size: 8px !important;
  }

  .library-panel {
    width: 100% !important;
    max-width: 100% !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    min-height: 320px !important;
    height: auto !important;
    border-radius: 19px 19px 16px 16px !important;
    overflow: hidden !important;
  }

  .library-main {
    min-width: 0 !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) !important;
  }

  .panel-header {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 7px !important;
    padding: 11px 9px 8px !important;
    min-width: 0 !important;
  }

  .panel-header > div,
  .search,
  .panel-header em {
    grid-column: 1 / -1 !important;
  }

  .panel-header > div {
    min-width: 0 !important;
    display: flex !important;
    align-items: baseline !important;
    gap: 8px !important;
  }

  .panel-header strong {
    font-size: 17px !important;
  }

  .panel-header span,
  .panel-header em {
    font-size: 10px !important;
  }

  .import-button,
  .danger-small {
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 8px !important;
    font-size: 10px !important;
  }

  .search {
    width: 100% !important;
    min-width: 0 !important;
    height: 38px !important;
  }

  .table-wrap {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    max-height: 420px !important;
    overflow: auto !important;
    padding: 0 8px 12px !important;
  }

  .track-table,
  .track-table thead,
  .track-table tbody,
  .track-table tr,
  .track-table th,
  .track-table td {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .track-table thead {
    position: sticky !important;
    top: 0 !important;
    z-index: 2 !important;
    padding: 0 0 7px !important;
    background: rgba(7, 12, 18, .98) !important;
  }

  .track-table thead tr {
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) 54px 40px 48px !important;
    gap: 4px !important;
    align-items: center !important;
  }

  .track-table th,
  .track-table td {
    padding: 0 !important;
    border: 0 !important;
  }

  .track-table th:nth-child(1),
  .track-table th:nth-child(4),
  .track-table th:nth-child(5),
  .track-table th:nth-child(8),
  .track-table td:nth-child(1),
  .track-table td:nth-child(5),
  .track-table td:nth-child(8) {
    display: none !important;
  }

  .track-table th:nth-child(2) { grid-column: 1 !important; }
  .track-table th:nth-child(3) { grid-column: 2 !important; }
  .track-table th:nth-child(6) { grid-column: 3 !important; }
  .track-table th:nth-child(7) { grid-column: 4 !important; }
  .track-table th:nth-child(9) { grid-column: 5 !important; }

  .sort-header {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 30px !important;
    height: 30px !important;
    padding: 0 4px !important;
    justify-content: center !important;
    border-radius: 8px !important;
    font-size: 8px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .track-table tbody {
    display: grid !important;
    gap: 7px !important;
  }

  .track-table tbody tr {
    display: grid !important;
    grid-template-columns: 34px minmax(0, 1fr) 54px 40px 48px !important;
    grid-template-rows: auto auto !important;
    gap: 3px 7px !important;
    align-items: center !important;
    min-height: 66px !important;
    padding: 9px !important;
    border: 1px solid rgba(154, 196, 238, .13) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .38) !important;
  }

  .track-table td:nth-child(2) {
    grid-column: 1 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    place-items: center !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 8px !important;
    background: rgba(255, 255, 255, .035) !important;
    font-weight: 800 !important;
  }

  .track-table td:nth-child(3) {
    grid-column: 2 !important;
    grid-row: 1 !important;
    color: #edf6ff !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .track-table td:nth-child(4) {
    grid-column: 2 !important;
    grid-row: 2 !important;
    display: block !important;
    color: rgba(220, 235, 255, .64) !important;
    font-size: 11px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .track-table td:nth-child(6) {
    grid-column: 3 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    text-align: right !important;
    font-size: 11px !important;
  }

  .track-table td:nth-child(7) {
    grid-column: 4 !important;
    grid-row: 1 !important;
    color: #91d6ff !important;
    text-align: center !important;
    font-size: 11px !important;
  }

  .track-table td:nth-child(9) {
    grid-column: 5 !important;
    grid-row: 1 / span 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 4px !important;
  }

  .track-table .load-cell button {
    height: 27px !important;
    min-height: 27px !important;
    border-radius: 8px !important;
    font-size: 10px !important;
    padding: 0 !important;
  }

  .seo-hero-below-app {
    margin-top: 18px !important;
  }
}

@media (max-width: 374px) {
  .app-shell {
    padding-left: 5px !important;
    padding-right: 5px !important;
  }

  .brand-copy small {
    display: none !important;
  }

  .icon-status {
    min-width: 62px !important;
  }

  .icon-status [data-status-label] {
    font-size: 10px !important;
  }

  .deck-body {
    grid-template-columns: 54px minmax(0, 1fr) 86px !important;
    gap: 6px !important;
  }

  .tempo-column {
    width: 54px !important;
    min-width: 54px !important;
  }

  .platter {
    width: min(100%, 154px, 43vw) !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 26px !important;
    min-height: 26px !important;
    font-size: 7.5px !important;
  }

  .mixer {
    grid-template-columns: minmax(0, 1fr) 66px minmax(0, 1fr) !important;
  }

  .track-table thead tr,
  .track-table tbody tr {
    grid-template-columns: 30px minmax(0, 1fr) 48px 36px 44px !important;
    gap: 3px 5px !important;
  }
}

/* v1.49 layout fit pass: circular desktop platters, full desktop mixer width, phone mixer-first flow, and no cramped mobile deck controls. */
@media (min-width: 1181px) {
  html,
  body {
    min-width: 1180px !important;
    overflow-x: auto !important;
  }

  .app-shell {
    width: min(100%, 1960px) !important;
    max-width: 1960px !important;
    padding: 12px 14px 34px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) clamp(350px, 20vw, 420px) minmax(0, 1fr) !important;
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: 690px minmax(420px, auto) auto !important;
    gap: 12px !important;
    align-items: start !important;
    width: 100% !important;
    margin-top: 12px !important;
  }

  .deck-a { grid-area: deckA !important; }
  .deck-b { grid-area: deckB !important; }
  .mixer { grid-area: mixer !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer {
    height: 690px !important;
    min-height: 690px !important;
    max-height: 690px !important;
    overflow: hidden !important;
    align-self: start !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: 44px 18px 48px 70px 30px 22px minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 12px !important;
  }

  .deck-header {
    grid-row: 1 !important;
    height: 44px !important;
    min-height: 44px !important;
    grid-template-columns: 42px minmax(0, 1fr) 96px !important;
    gap: 11px !important;
  }

  .deck-feedback {
    grid-row: 2 !important;
    position: static !important;
    width: 100% !important;
    height: 18px !important;
    min-height: 18px !important;
    margin: 0 !important;
    padding: 0 10px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 999px !important;
    pointer-events: none !important;
    font-size: 8.5px !important;
    line-height: 1 !important;
    letter-spacing: .14em !important;
    transform: none !important;
    z-index: 1 !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: minmax(132px, 176px) minmax(0, 1fr) !important;
    gap: 7px !important;
    width: 100% !important;
    height: 48px !important;
    min-height: 48px !important;
    margin: 0 !important;
    padding: 6px !important;
    overflow: hidden !important;
  }

  .grid-readout {
    min-width: 0 !important;
    height: 100% !important;
    padding: 4px 8px !important;
    overflow: hidden !important;
  }

  .grid-readout strong,
  .grid-readout span {
    display: block !important;
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    gap: 4px !important;
    min-width: 0 !important;
  }

  .grid-actions button {
    width: 100% !important;
    min-width: 0 !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 3px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    font-size: 8.5px !important;
  }

  .wave-wrap {
    grid-row: 4 !important;
    height: 70px !important;
    min-height: 70px !important;
    margin: 0 !important;
  }

  .zoom-waveform {
    grid-row: 5 !important;
    display: block !important;
    height: 30px !important;
    min-height: 30px !important;
    margin: 0 !important;
  }

  .time-row {
    grid-row: 6 !important;
    height: 22px !important;
    min-height: 22px !important;
    margin: 0 !important;
  }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: 96px minmax(260px, 1fr) 176px !important;
    gap: 12px !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-items: stretch !important;
  }

  .tempo-column {
    width: 96px !important;
    min-width: 96px !important;
    height: 100% !important;
    min-height: 0 !important;
    padding: 0 2px !important;
    gap: 5px !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 32px 22px 18px 22px 14px 24px minmax(0, 1fr) !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
    justify-items: center !important;
  }

  .tempo-column .sync-button { width: 90px !important; }
  .tempo-column .master-button { width: 78px !important; }
  .tempo-column .sync-status { width: 78px !important; max-width: 78px !important; }
  .tempo-column .vertical-slider { width: 78px !important; overflow: visible !important; }
  .tempo-column .vertical-slider input { width: 176px !important; max-width: 176px !important; transform: rotate(-90deg) !important; }

  .platter-zone {
    display: grid !important;
    grid-template-rows: minmax(0, 1fr) 52px !important;
    gap: 12px !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-items: center !important;
    justify-items: stretch !important;
  }

  .platter {
    --platter-size: clamp(270px, 16vw, 340px);
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    max-height: none !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
    flex: 0 0 auto !important;
  }

  .transport-row {
    width: 100% !important;
    height: 52px !important;
    min-height: 52px !important;
    display: grid !important;
    grid-template-columns: minmax(116px, 1fr) minmax(138px, 1fr) 46px !important;
    gap: 8px !important;
  }

  .transport-row button {
    height: 52px !important;
    min-height: 52px !important;
  }

  .deck-tools {
    display: grid !important;
    grid-template-rows: auto auto 34px !important;
    gap: 8px !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-content: start !important;
  }

  .loop-box,
  .hotcue-box {
    padding: 8px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 26px !important;
    min-height: 26px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(3, 32px) !important;
    gap: 6px !important;
  }

  .hotcue-grid button {
    height: 32px !important;
    min-height: 32px !important;
  }

  .deck-options {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
    min-height: 34px !important;
    height: 34px !important;
  }

  .deck-options button {
    min-height: 34px !important;
    height: 34px !important;
    padding: 0 2px !important;
  }

  .mixer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(108px, 1.05fr) minmax(0, 1fr) !important;
    gap: 10px !important;
    padding: 12px !important;
  }

  .channel-strip,
  .master-strip {
    min-height: 0 !important;
    padding: 9px 8px !important;
    gap: 7px !important;
    overflow: hidden !important;
  }

  .channel-strip h3,
  .master-strip h3 {
    font-size: 12px !important;
  }

  .channel-cue {
    height: 30px !important;
    min-height: 30px !important;
  }

  .channel-meter {
    height: 22px !important;
  }

  .channel-fader input {
    height: 96px !important;
  }

  .meter-shell {
    height: 182px !important;
  }

  #masterMeter {
    width: 62px !important;
    height: 168px !important;
  }

  .library-panel {
    min-height: 420px !important;
    height: auto !important;
  }

  .library-main {
    min-height: 420px !important;
  }
}

@media (max-width: 1560px) and (min-width: 1181px) {
  .main-grid {
    grid-template-columns: minmax(0, 1fr) clamp(330px, 20vw, 370px) minmax(0, 1fr) !important;
    grid-template-rows: 700px minmax(400px, auto) auto !important;
    gap: 10px !important;
  }

  .deck,
  .mixer {
    height: 700px !important;
    min-height: 700px !important;
    max-height: 700px !important;
  }

  .deck {
    grid-template-rows: 42px 18px 72px 62px 26px 22px minmax(0, 1fr) !important;
    padding: 10px !important;
  }

  .grid-panel {
    height: 72px !important;
    min-height: 72px !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 5px !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .grid-actions button {
    height: 24px !important;
    min-height: 24px !important;
    font-size: 8px !important;
  }

  .deck-body {
    grid-template-columns: 88px minmax(210px, 1fr) 158px !important;
    gap: 9px !important;
  }

  .tempo-column {
    width: 88px !important;
    min-width: 88px !important;
  }

  .tempo-column .sync-button { width: 84px !important; font-size: 9.5px !important; }
  .tempo-column .vertical-slider { width: 72px !important; }
  .tempo-column .vertical-slider input { width: 164px !important; max-width: 164px !important; }

  .platter {
    --platter-size: clamp(225px, 15vw, 292px);
  }

  .transport-row {
    grid-template-columns: minmax(100px, 1fr) minmax(120px, 1fr) 42px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 25px !important;
    min-height: 25px !important;
  }

  .hotcue-grid button {
    height: 31px !important;
    min-height: 31px !important;
  }
}

@media (max-width: 760px) {
  html,
  body {
    min-width: 0 !important;
    width: 100% !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 440px !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    padding: max(8px, env(safe-area-inset-top)) 8px 24px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "mixer"
      "deckA"
      "library" !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
    width: 100% !important;
    min-width: 0 !important;
    margin-top: 0 !important;
  }

  .mixer {
    grid-area: mixer !important;
    grid-column: 1 !important;
    grid-row: 1 !important;
  }

  .deck-a,
  .deck-b {
    grid-area: deckA !important;
    grid-column: 1 !important;
    grid-row: 2 !important;
    min-width: 0 !important;
  }

  .library-panel {
    grid-area: library !important;
    grid-column: 1 !important;
    grid-row: 3 !important;
    min-width: 0 !important;
  }

  .mobile-focus-a .deck-a,
  .mobile-focus-b .deck-b {
    display: grid !important;
  }

  .mobile-focus-a .deck-b,
  .mobile-focus-b .deck-a,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b,
  .recording-panel,
  .cue-panel {
    display: none !important;
  }

  .mobile-focus-a .mixer,
  .mobile-focus-b .mixer,
  .mobile-focus-a .library-panel,
  .mobile-focus-b .library-panel,
  .mobile-focus-mixer .mixer,
  .mobile-focus-mixer .library-panel {
    display: grid !important;
  }

  .mixer {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(74px, 84px) minmax(0, 1fr) !important;
    gap: 6px !important;
    padding: 8px !important;
    border-radius: 17px !important;
    overflow: hidden !important;
  }

  .channel-strip,
  .master-strip {
    min-width: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    border-radius: 11px !important;
    padding: 7px 5px !important;
    background: rgba(2, 6, 10, .40) !important;
  }

  .channel-strip {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .channel-strip h3,
  .channel-strip label:has([data-role="gain"]),
  .channel-strip label:has([data-role="filter"]),
  .channel-strip .channel-cue,
  .channel-strip .channel-meter,
  .channel-strip .xfade-assign {
    display: none !important;
  }

  .channel-strip label {
    display: grid !important;
    gap: 3px !important;
    font-size: 7.5px !important;
    text-align: center !important;
    min-width: 0 !important;
  }

  .channel-strip label:has([data-role="fader"]) {
    grid-column: 1 / -1 !important;
    grid-row: 1 !important;
  }

  .channel-strip label:has([data-role="eq-low"]) { grid-column: 1 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-mid"]) { grid-column: 2 !important; grid-row: 2 !important; }
  .channel-strip label:has([data-role="eq-high"]) { grid-column: 3 !important; grid-row: 2 !important; }

  .channel-strip input[type="range"],
  .channel-fader input {
    width: 100% !important;
    min-width: 0 !important;
    height: 18px !important;
    writing-mode: horizontal-tb !important;
    appearance: auto !important;
  }

  .master-strip {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 5px !important;
  }

  .master-strip h3,
  .master-knob,
  .meter-shell,
  .cue-mix-control,
  .cue-level-control,
  .xfade-curve {
    display: none !important;
  }

  .headphone-status {
    display: grid !important;
    justify-items: center !important;
    gap: 3px !important;
    font-size: 7.5px !important;
  }

  .crossfader {
    display: grid !important;
    grid-template-columns: auto 1fr auto !important;
    gap: 3px !important;
    font-size: 8px !important;
  }

  .deck {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-rows: auto 18px auto 72px 28px 22px auto !important;
    gap: 7px !important;
    padding: 9px !important;
    border-radius: 17px !important;
    overflow: hidden !important;
  }

  .deck-body {
    grid-row: 7 !important;
    width: 100% !important;
    max-width: 100% !important;
    display: grid !important;
    grid-template-columns: 64px minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo platter"
      "tempo transport"
      "loop loop"
      "hot hot"
      "opts opts" !important;
    grid-template-rows: auto auto auto auto auto !important;
    gap: 8px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-items: start !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    width: 64px !important;
    min-width: 64px !important;
    min-height: 248px !important;
    height: 100% !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 34px 20px 20px 18px minmax(134px, 1fr) !important;
    gap: 6px !important;
    padding: 7px 5px !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 12px !important;
    background: rgba(2, 6, 10, .44) !important;
  }

  .tempo-column .sync-button {
    width: 100% !important;
    height: 34px !important;
    min-height: 34px !important;
    font-size: 9px !important;
    padding: 0 2px !important;
  }

  .tempo-column .master-button {
    height: 20px !important;
    min-height: 20px !important;
    font-size: 7px !important;
    padding: 0 2px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] { font-size: 12px !important; }
  .tempo-column > span[data-role="tempo-pct"] { font-size: 9px !important; }

  .tempo-column .vertical-slider {
    height: 136px !important;
    min-height: 136px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .tempo-column .vertical-slider input {
    width: 128px !important;
    max-width: 128px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-area: platter !important;
    display: grid !important;
    --platter-size: min(214px, 58vw);
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    align-self: center !important;
    justify-self: center !important;
  }

  .transport-row {
    grid-area: transport !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) 46px !important;
    gap: 6px !important;
    width: 100% !important;
    height: 46px !important;
    min-height: 46px !important;
  }

  .transport-row button {
    height: 46px !important;
    min-height: 46px !important;
    border-radius: 10px !important;
    font-size: 12px !important;
    padding: 0 4px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 6px !important;
    padding: 8px !important;
    border-radius: 12px !important;
    min-width: 0 !important;
  }

  .loop-box label {
    grid-column: 1 / -1 !important;
    margin: 0 !important;
    font-size: 9px !important;
  }

  .loop-size,
  .loop-row,
  .loop-extra-row {
    gap: 5px !important;
  }

  .loop-size { grid-column: 1 !important; }
  .loop-row { grid-column: 2 !important; margin-top: 0 !important; }
  .loop-toggle { grid-column: 1 / -1 !important; margin-top: 0 !important; }
  .loop-extra-row { grid-column: 1 / -1 !important; margin-top: 0 !important; }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 34px !important;
    min-height: 34px !important;
    font-size: 10px !important;
    padding: 0 3px !important;
    border-radius: 9px !important;
  }

  .hotcue-box {
    grid-area: hot !important;
    padding: 9px !important;
    border-radius: 12px !important;
    min-width: 0 !important;
  }

  .hotcue-box label {
    font-size: 9px !important;
    margin-bottom: 6px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .hotcue-grid button {
    height: 38px !important;
    min-height: 38px !important;
    font-size: 13px !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
    min-width: 0 !important;
  }

  .deck-options button {
    min-height: 38px !important;
    height: 38px !important;
    font-size: 8.5px !important;
    border-radius: 9px !important;
    padding: 0 2px !important;
  }
}

@media (max-width: 374px) {
  .app-shell {
    padding-left: 6px !important;
    padding-right: 6px !important;
  }

  .deck-body {
    grid-template-columns: 58px minmax(0, 1fr) !important;
    gap: 6px !important;
  }

  .tempo-column {
    width: 58px !important;
    min-width: 58px !important;
  }

  .platter {
    --platter-size: min(188px, 56vw);
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 32px !important;
    min-height: 32px !important;
    font-size: 9px !important;
  }
}

/* v1.49 final fit corrections: avoid the desktop three-column layout on tablet widths, keep platters round, and make the library table fit available desktop space. */
@media (max-width: 1260px) and (min-width: 761px) {
  html,
  body {
    min-width: 0 !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 100% !important;
    padding: 10px 12px 28px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "mixer"
      "deckA"
      "deckB"
      "library"
      "rightTop"
      "rightBottom" !important;
    grid-template-rows: auto !important;
    gap: 12px !important;
    align-items: start !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
  }

  .deck-a { grid-area: deckA !important; }
  .deck-b { grid-area: deckB !important; }
  .mixer { grid-area: mixer !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: hidden !important;
  }

  .mixer {
    min-height: 430px !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(220px, .8fr) minmax(0, 1fr) !important;
    gap: 12px !important;
    padding: 14px !important;
  }

  .mixer-channel,
  .master-strip {
    min-width: 0 !important;
    height: 100% !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: auto 18px auto 80px 32px 22px auto !important;
    gap: 8px !important;
    padding: 12px !important;
  }

  .deck-feedback {
    position: static !important;
    grid-row: 2 !important;
    height: 18px !important;
    min-height: 18px !important;
    width: 100% !important;
    transform: none !important;
    margin: 0 !important;
    z-index: 1 !important;
    pointer-events: none !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: minmax(120px, 1.6fr) repeat(4, minmax(64px, 1fr)) !important;
    grid-template-areas:
      "status tap minus plus prev"
      "status play set half double" !important;
    gap: 6px !important;
    height: auto !important;
    min-height: 78px !important;
    overflow: visible !important;
  }

  .grid-status { grid-area: status !important; }
  .grid-panel [data-action="tap"] { grid-area: tap !important; }
  .grid-panel [data-action="bpm-down"] { grid-area: minus !important; }
  .grid-panel [data-action="bpm-up"] { grid-area: plus !important; }
  .grid-panel [data-action="nudge-back"] { grid-area: prev !important; }
  .grid-panel [data-action="nudge-forward"] { grid-area: play !important; }
  .grid-panel [data-action="set-grid"] { grid-area: set !important; }
  .grid-panel [data-action="halve-grid"] { grid-area: half !important; }
  .grid-panel [data-action="double-grid"] { grid-area: double !important; }

  .grid-panel button,
  .grid-status {
    height: 36px !important;
    min-height: 36px !important;
  }

  .waveform-main {
    grid-row: 4 !important;
    height: 80px !important;
  }

  .waveform-zoom {
    grid-row: 5 !important;
    height: 32px !important;
  }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: 92px minmax(260px, 1fr) 176px !important;
    grid-template-areas:
      "tempo platter loop"
      "tempo transport hot"
      "tempo transport opts" !important;
    grid-template-rows: auto auto auto !important;
    gap: 10px !important;
    height: auto !important;
    min-height: 410px !important;
    overflow: visible !important;
    align-items: start !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    width: 92px !important;
    min-width: 92px !important;
    height: 100% !important;
    min-height: 410px !important;
  }

  .platter-zone {
    grid-area: platter !important;
    display: grid !important;
    min-width: 0 !important;
    place-items: center !important;
  }

  .platter {
    --platter-size: clamp(250px, 34vw, 330px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: calc(100% - 8px) !important;
    max-height: calc(100% - 8px) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-area: loop !important;
    width: 176px !important;
    min-width: 176px !important;
    max-width: 176px !important;
  }

  .hotcue-box {
    grid-area: hot !important;
    width: 176px !important;
    min-width: 176px !important;
    max-width: 176px !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
    width: 176px !important;
    min-width: 176px !important;
    max-width: 176px !important;
  }

  .transport-row {
    grid-area: transport !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 48px !important;
    gap: 8px !important;
    align-self: end !important;
    height: 52px !important;
    min-height: 52px !important;
  }

  .transport-row button {
    height: 52px !important;
    min-height: 52px !important;
  }

  .panel-header {
    grid-template-columns: minmax(120px, auto) auto minmax(180px, 1fr) auto auto !important;
    gap: 8px !important;
  }

  .search {
    min-width: 0 !important;
  }

  .track-table {
    min-width: 980px !important;
  }
}

@media (max-width: 1560px) and (min-width: 1261px) {
  .platter {
    --platter-size: clamp(170px, 16vw, 265px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
  }

  .track-table {
    min-width: min(1180px, 100%) !important;
  }
}

@media (max-width: 760px) {
  .mixer {
    margin-bottom: 2px !important;
  }

  .deck-body {
    grid-template-columns: 62px minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo platter"
      "tempo transport"
      "loop loop"
      "hot hot"
      "opts opts" !important;
    gap: 8px !important;
  }

  .platter {
    --platter-size: min(200px, calc(100vw - 178px)) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
  }

  .loop-box,
  .hotcue-box,
  .deck-options,
  .transport-row {
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .loop-box {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .loop-box label,
  .loop-toggle,
  .loop-extra-row {
    grid-column: 1 / -1 !important;
  }

  .loop-size,
  .loop-row {
    grid-column: auto !important;
  }

  .loop-extra-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .library-panel {
    overflow: hidden !important;
  }

  .library-panel .table-wrap {
    overflow-x: auto !important;
  }
}

@media (max-width: 374px) {
  .platter {
    --platter-size: min(184px, calc(100vw - 162px)) !important;
  }

  .deck-body {
    grid-template-columns: 58px minmax(0, 1fr) !important;
  }
}

/* v1.49 guard rails for mid-size screens and library columns. */
@media (max-width: 1500px) and (min-width: 761px) {
  .track-table {
    width: 100% !important;
    min-width: 0 !important;
    table-layout: fixed !important;
  }

  .track-table th,
  .track-table td {
    padding: 8px 9px !important;
  }

  .track-table th:nth-child(1),
  .track-table td:nth-child(1) { width: 40px !important; }
  .track-table th:nth-child(2),
  .track-table td:nth-child(2) { width: 54px !important; }
  .track-table th:nth-child(3),
  .track-table td:nth-child(3) { width: 24% !important; }
  .track-table th:nth-child(4),
  .track-table td:nth-child(4) { width: 16% !important; }
  .track-table th:nth-child(5),
  .track-table td:nth-child(5) { width: 18% !important; }
  .track-table th:nth-child(6),
  .track-table td:nth-child(6) { width: 72px !important; }
  .track-table th:nth-child(7),
  .track-table td:nth-child(7) { width: 60px !important; }
  .track-table th:nth-child(8),
  .track-table td:nth-child(8) { width: 76px !important; }
  .track-table th:nth-child(9),
  .track-table td:nth-child(9) { width: 94px !important; }
}

@media (max-width: 1260px) and (min-width: 901px) {
  .platter {
    height: var(--platter-size) !important;
    max-height: none !important;
  }

  .deck-body {
    grid-template-rows: minmax(338px, auto) 52px 34px !important;
  }
}

@media (max-width: 900px) and (min-width: 761px) {
  .deck {
    height: auto !important;
    max-height: none !important;
    overflow: hidden !important;
  }

  .deck-body {
    display: grid !important;
    grid-template-columns: 82px minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo platter"
      "tempo transport"
      "loop loop"
      "hot hot"
      "opts opts" !important;
    grid-template-rows: auto auto auto auto auto !important;
    gap: 10px !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    width: 82px !important;
    min-width: 82px !important;
    min-height: 390px !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-area: platter !important;
    --platter-size: clamp(260px, 44vw, 330px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: none !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .transport-row {
    grid-area: transport !important;
    width: 100% !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) 54px !important;
    height: 54px !important;
    min-height: 54px !important;
  }

  .transport-row button {
    height: 54px !important;
    min-height: 54px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box,
  .hotcue-box,
  .deck-options {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .loop-box label,
  .loop-toggle,
  .loop-extra-row {
    grid-column: 1 / -1 !important;
  }

  .loop-size,
  .loop-row {
    grid-column: auto !important;
  }

  .loop-extra-row {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .hotcue-box {
    grid-area: hot !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .library-shell {
    grid-template-columns: 120px minmax(0, 1fr) !important;
  }

  .panel-header {
    grid-template-columns: minmax(130px, auto) auto minmax(180px, 1fr) auto auto !important;
  }
}

/* v1.49 beat-grid readout and compact desktop deck corrections. */
@media (min-width: 1261px) {
  .grid-panel {
    display: grid !important;
    align-items: stretch !important;
    overflow: visible !important;
  }

  .grid-readout {
    display: grid !important;
    align-content: center !important;
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
  }

  .grid-actions {
    min-width: 0 !important;
    display: grid !important;
    gap: 6px !important;
  }

  .grid-actions button {
    min-width: 0 !important;
    width: 100% !important;
  }
}

@media (min-width: 1561px) {
  .grid-panel {
    grid-template-columns: minmax(178px, .9fr) minmax(0, 2.7fr) !important;
    grid-template-rows: 1fr !important;
    gap: 8px !important;
  }

  .grid-readout {
    grid-column: 1 !important;
    grid-row: 1 !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 6px 10px !important;
  }

  .grid-actions {
    grid-column: 2 !important;
    grid-row: 1 !important;
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
  }

  .grid-actions button {
    height: 40px !important;
    min-height: 40px !important;
  }
}

@media (max-width: 1560px) and (min-width: 1261px) {
  .grid-panel {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 24px 42px !important;
    height: 72px !important;
    min-height: 72px !important;
    gap: 5px !important;
  }

  .grid-readout {
    grid-column: 1 !important;
    grid-row: 1 !important;
    height: 24px !important;
    min-height: 24px !important;
    padding: 3px 8px !important;
    border-radius: 8px !important;
  }

  .grid-actions {
    grid-column: 1 !important;
    grid-row: 2 !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    grid-auto-rows: 20px !important;
    gap: 4px !important;
  }

  .grid-actions button {
    height: 20px !important;
    min-height: 20px !important;
    font-size: 7.4px !important;
    padding: 0 2px !important;
  }

  .deck-body {
    grid-template-columns: 82px minmax(172px, 1fr) 154px !important;
    gap: 8px !important;
  }

  .tempo-column {
    width: 82px !important;
    min-width: 82px !important;
  }

  .platter {
    --platter-size: clamp(165px, 13vw, 220px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: none !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
  }

  .loop-box,
  .hotcue-box,
  .deck-options {
    width: 154px !important;
    min-width: 154px !important;
    max-width: 154px !important;
  }
}

@media (max-width: 1260px) and (min-width: 761px) {
  .grid-panel {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 28px auto !important;
    grid-template-areas: none !important;
    height: auto !important;
    min-height: 82px !important;
    gap: 6px !important;
  }

  .grid-readout {
    grid-column: 1 !important;
    grid-row: 1 !important;
    height: 28px !important;
    min-height: 28px !important;
    padding: 4px 8px !important;
    overflow: hidden !important;
  }

  .grid-actions {
    grid-column: 1 !important;
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
  }

  .grid-actions button {
    height: 30px !important;
    min-height: 30px !important;
  }
}

@media (max-width: 900px) and (min-width: 761px) {
  .platter {
    --platter-size: clamp(244px, 32vw, 290px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: none !important;
  }
}

/* v1.49 compact desktop transport fit. */
@media (max-width: 1560px) and (min-width: 1261px) {
  .transport-row {
    grid-template-columns: minmax(70px, 1fr) minmax(82px, 1.08fr) 36px !important;
    gap: 5px !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .transport-row button {
    min-width: 0 !important;
    padding: 0 3px !important;
  }
}


/* v1.50 production layout repair: non-squashed desktop mixer, circular platters, unclipped deck tools, and a cleaned-up mobile control stack. */
@media (min-width: 1261px) {
  body {
    min-width: 1180px !important;
    overflow-x: auto !important;
  }

  .app-shell {
    width: min(100%, 1960px) !important;
    max-width: 1960px !important;
    margin: 0 auto !important;
    padding: 14px 16px 36px !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(500px, 1fr) clamp(360px, 20vw, 430px) minmax(500px, 1fr) !important;
    grid-template-areas:
      "deckA mixer deckB"
      "library library library"
      "rightTop rightTop rightBottom" !important;
    grid-template-rows: 740px minmax(430px, auto) auto !important;
    gap: 12px !important;
    align-items: start !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
  }

  .deck-a { grid-area: deckA !important; }
  .deck-b { grid-area: deckB !important; }
  .mixer { grid-area: mixer !important; }
  .library-panel { grid-area: library !important; }
  .recording-panel { grid-area: rightTop !important; }
  .cue-panel { grid-area: rightBottom !important; }

  .deck,
  .mixer {
    height: 740px !important;
    min-height: 740px !important;
    max-height: 740px !important;
    min-width: 0 !important;
    align-self: start !important;
    overflow: hidden !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: 44px 18px 54px 72px 30px 22px minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 12px !important;
  }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: 92px minmax(260px, 1fr) 176px !important;
    gap: 12px !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    align-items: stretch !important;
    overflow: visible !important;
  }

  .tempo-column {
    width: 92px !important;
    min-width: 92px !important;
    height: 100% !important;
    min-height: 0 !important;
    grid-template-rows: 32px 22px 18px 22px 14px 26px minmax(0, 1fr) !important;
    gap: 5px !important;
    padding: 8px 7px 10px !important;
    overflow: hidden !important;
  }

  .tempo-column .sync-button {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 32px !important;
    min-height: 32px !important;
  }

  .tempo-column .master-button,
  .tempo-column .sync-status,
  .tempo-column .range-button {
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .tempo-column .vertical-slider {
    width: 100% !important;
    min-height: 132px !important;
    height: 100% !important;
    overflow: visible !important;
  }

  .tempo-column .vertical-slider input {
    width: 150px !important;
    max-width: 150px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: grid !important;
    grid-template-rows: minmax(0, 1fr) 52px !important;
    gap: 12px !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    align-items: center !important;
    justify-items: stretch !important;
    overflow: visible !important;
  }

  .platter {
    --platter-size: clamp(265px, 17vw, 345px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: min(100%, var(--platter-size)) !important;
    max-height: var(--platter-size) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    flex: 0 0 auto !important;
    align-self: center !important;
    justify-self: center !important;
  }

  .platter-ring,
  .platter-core {
    border-radius: 50% !important;
  }

  .transport-row {
    width: 100% !important;
    height: 52px !important;
    min-height: 52px !important;
    display: grid !important;
    grid-template-columns: minmax(112px, 1fr) minmax(132px, 1.05fr) 48px !important;
    gap: 8px !important;
    min-width: 0 !important;
    overflow: visible !important;
  }

  .transport-row button {
    height: 52px !important;
    min-height: 52px !important;
    min-width: 0 !important;
  }

  .deck-tools {
    display: grid !important;
    grid-template-rows: auto auto 36px !important;
    gap: 8px !important;
    height: 100% !important;
    min-height: 0 !important;
    width: 176px !important;
    min-width: 176px !important;
    max-width: 176px !important;
    align-content: start !important;
    overflow: visible !important;
  }

  .loop-box,
  .hotcue-box {
    padding: 8px !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 28px !important;
    min-height: 28px !important;
    min-width: 0 !important;
  }

  .hotcue-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(3, 34px) !important;
    gap: 6px !important;
  }

  .hotcue-grid button {
    height: 34px !important;
    min-height: 34px !important;
  }

  .deck-options {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 5px !important;
    width: 100% !important;
    min-height: 36px !important;
    height: 36px !important;
  }

  .deck-options button {
    height: 36px !important;
    min-height: 36px !important;
    min-width: 0 !important;
    padding: 0 2px !important;
  }

  .mixer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(112px, .9fr) minmax(0, 1fr) !important;
    gap: 10px !important;
    padding: 12px !important;
    min-width: 360px !important;
  }

  .channel-strip,
  .master-strip {
    min-width: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  .meter-shell {
    min-height: 184px !important;
  }
}

@media (max-width: 1560px) and (min-width: 1261px) {
  .main-grid {
    grid-template-columns: minmax(410px, 1fr) clamp(330px, 25vw, 380px) minmax(410px, 1fr) !important;
    grid-template-rows: 760px minmax(430px, auto) auto !important;
  }

  .deck,
  .mixer {
    height: 760px !important;
    min-height: 760px !important;
    max-height: 760px !important;
  }

  .deck {
    grid-template-rows: 42px 18px 78px 62px 28px 22px minmax(0, 1fr) !important;
    gap: 7px !important;
    padding: 10px !important;
  }

  .grid-panel {
    height: 78px !important;
    min-height: 78px !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 27px 44px !important;
    gap: 5px !important;
    overflow: hidden !important;
  }

  .grid-readout {
    height: 27px !important;
    min-height: 27px !important;
    padding: 4px 8px !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    grid-auto-rows: 20px !important;
    gap: 4px !important;
  }

  .grid-actions button {
    height: 20px !important;
    min-height: 20px !important;
    font-size: 7.8px !important;
    padding: 0 2px !important;
  }

  .deck-body {
    grid-template-columns: 84px minmax(210px, 1fr) 158px !important;
    gap: 9px !important;
  }

  .tempo-column {
    width: 84px !important;
    min-width: 84px !important;
  }

  .tempo-column .vertical-slider input {
    width: 136px !important;
    max-width: 136px !important;
  }

  .platter {
    --platter-size: clamp(220px, 17.5vw, 290px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(92px, 1fr) minmax(112px, 1fr) 42px !important;
    gap: 6px !important;
  }

  .deck-tools {
    width: 158px !important;
    min-width: 158px !important;
    max-width: 158px !important;
    gap: 7px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    height: 27px !important;
    min-height: 27px !important;
  }

  .hotcue-grid {
    grid-template-rows: repeat(3, 32px) !important;
  }

  .hotcue-grid button {
    height: 32px !important;
    min-height: 32px !important;
  }

  .mixer {
    min-width: 340px !important;
    padding: 10px !important;
    gap: 8px !important;
  }
}

@media (max-width: 760px) {
  html,
  body {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 430px !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    padding: max(8px, env(safe-area-inset-top)) 8px 24px !important;
    overflow-x: hidden !important;
  }

  .main-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "mixer"
      "deckA"
      "library"
      "seo" !important;
    grid-template-rows: auto auto auto auto !important;
    grid-auto-rows: auto !important;
    gap: 10px !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin-top: 0 !important;
    overflow: visible !important;
  }

  .mixer {
    grid-area: mixer !important;
    grid-row: 1 !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(72px, 84px) minmax(0, 1fr) !important;
    gap: 6px !important;
    padding: 8px !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    order: 0 !important;
  }

  .deck-a,
  .deck-b {
    grid-area: deckA !important;
    grid-row: 2 !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    order: 1 !important;
  }

  .library-panel {
    grid-area: library !important;
    grid-row: 3 !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    order: 2 !important;
  }

  .mobile-focus-a .deck-a,
  .mobile-focus-b .deck-b,
  .mobile-focus-a .mixer,
  .mobile-focus-b .mixer,
  .mobile-focus-a .library-panel,
  .mobile-focus-b .library-panel {
    display: grid !important;
  }

  .mobile-focus-a .deck-b,
  .mobile-focus-b .deck-a,
  .mobile-focus-mixer .deck-a,
  .mobile-focus-mixer .deck-b,
  .recording-panel,
  .cue-panel {
    display: none !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: auto 16px auto 64px 26px 20px auto !important;
    gap: 7px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    padding: 9px !important;
    border-radius: 16px !important;
    overflow: hidden !important;
  }

  .deck-header {
    grid-template-columns: 40px minmax(0, 1fr) minmax(58px, auto) !important;
    gap: 8px !important;
    min-width: 0 !important;
  }

  .deck-feedback {
    grid-row: 2 !important;
    position: static !important;
    width: 100% !important;
    height: 16px !important;
    min-height: 16px !important;
    transform: none !important;
    margin: 0 !important;
    padding: 0 8px !important;
    display: grid !important;
    place-items: center !important;
    overflow: hidden !important;
  }

  .grid-panel {
    grid-row: 3 !important;
    display: grid !important;
    grid-template-columns: minmax(94px, 118px) minmax(0, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 5px !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 46px !important;
    min-height: 46px !important;
    padding: 5px !important;
    overflow: hidden !important;
  }

  .grid-readout {
    min-width: 0 !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 4px 7px !important;
    overflow: hidden !important;
  }

  .grid-readout strong,
  .grid-readout span {
    display: block !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .grid-actions {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    grid-auto-rows: 17px !important;
    gap: 3px !important;
    min-width: 0 !important;
  }

  .grid-actions button {
    width: 100% !important;
    min-width: 0 !important;
    height: 17px !important;
    min-height: 17px !important;
    padding: 0 1px !important;
    font-size: 7px !important;
    line-height: 1 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .wave-wrap {
    grid-row: 4 !important;
    height: 64px !important;
    min-height: 64px !important;
    margin: 0 !important;
  }

  .zoom-waveform {
    grid-row: 5 !important;
    height: 26px !important;
    min-height: 26px !important;
    margin: 0 !important;
  }

  .time-row {
    grid-row: 6 !important;
    height: 20px !important;
    min-height: 20px !important;
    margin: 0 !important;
    gap: 6px !important;
  }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: 72px minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo platter"
      "tempo transport"
      "loop loop"
      "hot hot"
      "opts opts" !important;
    grid-template-rows: auto 50px auto auto auto !important;
    gap: 9px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    align-items: start !important;
    overflow: visible !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    min-height: 292px !important;
    height: 100% !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 36px 22px 18px 16px 24px minmax(132px, 1fr) !important;
    gap: 6px !important;
    padding: 7px 5px !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 13px !important;
    background: rgba(2, 6, 10, .48) !important;
    overflow: hidden !important;
    align-items: center !important;
    justify-items: center !important;
  }

  .tempo-column .sync-button {
    grid-row: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 2px !important;
    font-size: 9px !important;
    letter-spacing: .09em !important;
  }

  .tempo-column .master-button {
    grid-row: 2 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 22px !important;
    min-height: 22px !important;
    padding: 0 2px !important;
    font-size: 7px !important;
  }

  .tempo-column .sync-status {
    grid-row: 3 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 18px !important;
    min-height: 18px !important;
    padding: 0 2px !important;
    font-size: 7px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-row: 4 !important;
    font-size: 10px !important;
    line-height: 1 !important;
    width: 100% !important;
    text-align: center !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    display: none !important;
  }

  .tempo-column .range-button {
    grid-row: 5 !important;
    width: 48px !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 24px !important;
    min-height: 24px !important;
    padding: 0 2px !important;
    font-size: 9px !important;
  }

  .tempo-column .vertical-slider {
    grid-row: 6 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 132px !important;
    margin: 0 !important;
    padding: 2px 0 !important;
    display: grid !important;
    grid-template-rows: 10px minmax(0, 1fr) 10px !important;
    place-items: center !important;
    overflow: visible !important;
  }

  .tempo-column .vertical-slider span {
    font-size: 8px !important;
    line-height: 1 !important;
    color: rgba(230,240,252,.45) !important;
  }

  .tempo-column .vertical-slider input {
    width: 136px !important;
    max-width: 136px !important;
    min-width: 136px !important;
    transform: rotate(-90deg) !important;
  }

  .platter-zone {
    display: contents !important;
  }

  .platter {
    grid-area: platter !important;
    display: grid !important;
    --platter-size: clamp(172px, 56vw, 222px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: min(100%, var(--platter-size)) !important;
    max-height: var(--platter-size) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    align-self: center !important;
    justify-self: center !important;
    overflow: hidden !important;
  }

  .platter-ring,
  .platter-core {
    border-radius: 50% !important;
  }

  .transport-row {
    grid-area: transport !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) 46px !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 50px !important;
    min-height: 50px !important;
    overflow: visible !important;
  }

  .transport-row button {
    height: 50px !important;
    min-height: 50px !important;
    min-width: 0 !important;
    max-width: 100% !important;
    border-radius: 10px !important;
    padding: 0 4px !important;
    font-size: 11px !important;
  }

  .deck-tools {
    display: contents !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    grid-template-areas:
      "label label"
      "size inout"
      "auto auto"
      "jump jump"
      "move move" !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 9px !important;
    border-radius: 13px !important;
    overflow: hidden !important;
  }

  .loop-box label {
    grid-area: label !important;
    margin: 0 !important;
    height: 14px !important;
    line-height: 14px !important;
    font-size: 9px !important;
    letter-spacing: .13em !important;
    text-align: center !important;
  }

  .loop-size {
    grid-area: size !important;
    display: grid !important;
    grid-template-columns: 36px minmax(0, 1fr) 36px !important;
    gap: 5px !important;
    min-width: 0 !important;
  }

  .loop-row {
    grid-area: inout !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 5px !important;
    min-width: 0 !important;
    margin: 0 !important;
  }

  .loop-toggle {
    grid-area: auto !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .loop-extra-row {
    display: grid !important;
    gap: 5px !important;
    min-width: 0 !important;
    margin: 0 !important;
  }

  .loop-box .loop-extra-row:nth-of-type(3) {
    grid-area: jump !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .loop-box .loop-extra-row:nth-of-type(4) {
    grid-area: move !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 38px !important;
    min-height: 38px !important;
    padding: 0 3px !important;
    border-radius: 9px !important;
    font-size: 10px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .loop-size strong {
    display: grid !important;
    place-items: center !important;
    min-width: 0 !important;
    height: 38px !important;
    border-radius: 9px !important;
    background: rgba(0, 0, 0, .22) !important;
  }

  .hotcue-box {
    grid-area: hot !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 9px !important;
    border-radius: 13px !important;
    overflow: hidden !important;
  }

  .hotcue-box label {
    margin: 0 0 7px !important;
    font-size: 9px !important;
    letter-spacing: .13em !important;
    text-align: center !important;
  }

  .hotcue-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .hotcue-grid button {
    width: 100% !important;
    min-width: 0 !important;
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 9px !important;
    font-size: 13px !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .deck-options button {
    width: 100% !important;
    min-width: 0 !important;
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 9px !important;
    padding: 0 2px !important;
    font-size: 8.5px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .library-shell,
  .library-main,
  .library-table-wrap,
  .library-table,
  .seo-content,
  .seo-hero {
    max-width: 100% !important;
    min-width: 0 !important;
  }
}

@media (max-width: 374px) {
  .deck-body {
    grid-template-columns: 64px minmax(0, 1fr) !important;
    gap: 7px !important;
  }

  .tempo-column {
    width: 64px !important;
    min-width: 64px !important;
    max-width: 64px !important;
  }

  .tempo-column .sync-button { font-size: 8px !important; }
  .tempo-column .master-button { font-size: 6.5px !important; }
  .tempo-column .vertical-slider input {
    width: 128px !important;
    min-width: 128px !important;
    max-width: 128px !important;
  }

  .platter {
    --platter-size: clamp(160px, 54vw, 196px) !important;
  }

  .loop-size {
    grid-template-columns: 32px minmax(0, 1fr) 32px !important;
  }

  .loop-size button,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button,
  .loop-size strong {
    height: 36px !important;
    min-height: 36px !important;
    font-size: 9px !important;
  }
}

/* v1.51 mobile pitch-lane and desktop sync-edge repair.
   Scope: layout CSS only. Keeps the mobile mixer above the decks, makes the mobile
   left deck controls readable, and stops the desktop SYNC button edge from being clipped. */
@media (min-width: 1261px) {
  .deck-body,
  .tempo-column {
    overflow: visible !important;
  }

  .tempo-column .sync-button {
    width: calc(100% - 2px) !important;
    max-width: calc(100% - 2px) !important;
    justify-self: center !important;
    margin-inline: 1px !important;
    padding-inline: 4px !important;
    overflow: visible !important;
  }

  .tempo-column .master-button,
  .tempo-column .sync-status,
  .tempo-column .range-button {
    width: calc(100% - 8px) !important;
    max-width: calc(100% - 8px) !important;
    justify-self: center !important;
    overflow: hidden !important;
  }

  .platter {
    aspect-ratio: 1 / 1 !important;
    height: var(--platter-size) !important;
    border-radius: 50% !important;
  }
}

@media (max-width: 760px) {
  .deck-body {
    grid-template-columns: 88px minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo platter"
      "tempo transport"
      "loop loop"
      "hot hot"
      "opts opts" !important;
    gap: 10px !important;
    align-items: start !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    width: 88px !important;
    min-width: 88px !important;
    max-width: 88px !important;
    min-height: 316px !important;
    height: 100% !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 40px 24px 22px 24px 16px 28px minmax(142px, 1fr) !important;
    gap: 6px !important;
    padding: 9px 8px !important;
    align-items: center !important;
    justify-items: center !important;
    overflow: visible !important;
    border: 1px solid rgba(154, 196, 238, .14) !important;
    border-radius: 14px !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.032), rgba(255,255,255,.008)),
      rgba(2, 6, 10, .50) !important;
  }

  .tempo-column .sync-button {
    grid-row: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 4px !important;
    overflow: visible !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    letter-spacing: .08em !important;
    text-align: center !important;
  }

  .tempo-column .master-button {
    grid-row: 2 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 24px !important;
    min-height: 24px !important;
    padding: 0 4px !important;
    border-radius: 999px !important;
    font-size: 7.5px !important;
    letter-spacing: .06em !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: clip !important;
  }

  .tempo-column .sync-status {
    grid-row: 3 !important;
    display: grid !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 22px !important;
    min-height: 22px !important;
    padding: 0 4px !important;
    place-items: center !important;
    border-radius: 999px !important;
    background: rgba(120, 144, 172, .11) !important;
    color: rgba(218, 228, 240, .76) !important;
    border: 0 !important;
    font-size: 7.5px !important;
    line-height: 1 !important;
    letter-spacing: .07em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-row: 4 !important;
    width: 100% !important;
    height: 24px !important;
    display: grid !important;
    place-items: end center !important;
    font-size: 13px !important;
    line-height: 1 !important;
    font-variant-numeric: tabular-nums !important;
    color: #f4f8fe !important;
    white-space: nowrap !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-row: 5 !important;
    display: grid !important;
    width: 100% !important;
    height: 16px !important;
    place-items: center !important;
    font-size: 9px !important;
    line-height: 1 !important;
    color: rgba(210,222,236,.68) !important;
    white-space: nowrap !important;
  }

  .tempo-column .range-button {
    grid-row: 6 !important;
    display: grid !important;
    width: 54px !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 28px !important;
    min-height: 28px !important;
    padding: 0 3px !important;
    border-radius: 8px !important;
    font-size: 10px !important;
  }

  .tempo-column .vertical-slider {
    grid-row: 7 !important;
    position: relative !important;
    display: grid !important;
    grid-template-rows: 10px minmax(0, 1fr) 10px !important;
    place-items: center !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 150px !important;
    min-height: 150px !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  .tempo-column .vertical-slider span {
    position: static !important;
    width: auto !important;
    transform: none !important;
    font-size: 8px !important;
    line-height: 1 !important;
    color: rgba(230,240,252,.45) !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    position: static !important;
    width: 146px !important;
    min-width: 146px !important;
    max-width: 146px !important;
    height: 18px !important;
    transform: rotate(-90deg) !important;
    transform-origin: center !important;
    margin: 0 !important;
  }

  .platter {
    grid-area: platter !important;
    --platter-size: clamp(178px, calc(100vw - 176px), 218px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: var(--platter-size) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .transport-row {
    grid-area: transport !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.06fr) 48px !important;
    gap: 7px !important;
    height: 52px !important;
    min-height: 52px !important;
  }

  .transport-row button {
    height: 52px !important;
    min-height: 52px !important;
  }

  .loop-box {
    margin-top: 2px !important;
  }
}

@media (max-width: 390px) {
  .deck-body {
    grid-template-columns: 82px minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .tempo-column {
    width: 82px !important;
    min-width: 82px !important;
    max-width: 82px !important;
    min-height: 302px !important;
    padding: 8px 7px !important;
  }

  .tempo-column .sync-button {
    font-size: 9px !important;
    letter-spacing: .07em !important;
  }

  .tempo-column .master-button,
  .tempo-column .sync-status {
    font-size: 7px !important;
  }

  .tempo-column .vertical-slider {
    height: 142px !important;
    min-height: 142px !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    width: 138px !important;
    min-width: 138px !important;
    max-width: 138px !important;
  }

  .platter {
    --platter-size: clamp(164px, calc(100vw - 166px), 204px) !important;
  }
}

@media (max-width: 360px) {
  .deck-body {
    grid-template-columns: 76px minmax(0, 1fr) !important;
    gap: 7px !important;
  }

  .tempo-column {
    width: 76px !important;
    min-width: 76px !important;
    max-width: 76px !important;
  }

  .platter {
    --platter-size: clamp(150px, calc(100vw - 156px), 190px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.04fr) 42px !important;
    gap: 6px !important;
  }
}


/* v1.52 mobile deck control reset and desktop sync clipping repair.
   The prior mobile pass inherited several desktop/tablet placement rules, which let
   the tempo controls escape their lane. This final override makes the phone deck a
   one-column touch layout: tempo strip, jog/transport, deck tools. */
@media (min-width: 761px) {
  .deck-body,
  .tempo-column {
    overflow: visible !important;
  }

  .tempo-column .sync-button {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    box-sizing: border-box !important;
    width: calc(100% - 2px) !important;
    max-width: calc(100% - 2px) !important;
    min-width: 0 !important;
    justify-self: center !important;
    margin-inline: 1px !important;
    padding-inline: 2px !important;
    letter-spacing: .055em !important;
    white-space: nowrap !important;
    overflow: visible !important;
  }
}

@media (max-width: 760px) {
  .deck-body {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo"
      "platter"
      "tools" !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    align-items: stretch !important;
    overflow: visible !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    position: relative !important;
    inset: auto !important;
    transform: none !important;
    display: grid !important;
    grid-template-columns: minmax(66px, .8fr) minmax(0, 1fr) minmax(54px, .62fr) !important;
    grid-template-areas:
      "sync master range"
      "bpm status pct"
      "slider slider slider" !important;
    grid-template-rows: 36px 24px 38px !important;
    gap: 7px 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 10px !important;
    align-items: center !important;
    justify-items: stretch !important;
    overflow: hidden !important;
    border-radius: 14px !important;
    border: 1px solid rgba(154, 196, 238, .14) !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.008)),
      rgba(2, 6, 10, .58) !important;
  }

  .tempo-column > *,
  .tempo-column button,
  .tempo-column small,
  .tempo-column strong,
  .tempo-column span,
  .tempo-column label,
  .tempo-column input {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    float: none !important;
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column .sync-button {
    grid-area: sync !important;
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 6px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    letter-spacing: .075em !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .tempo-column .master-button {
    grid-area: master !important;
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    height: 24px !important;
    min-height: 24px !important;
    padding: 0 6px !important;
    border-radius: 999px !important;
    font-size: 8px !important;
    line-height: 1 !important;
    letter-spacing: .06em !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .tempo-column .sync-status {
    grid-area: status !important;
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    height: 22px !important;
    min-height: 22px !important;
    padding: 0 6px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: rgba(120, 144, 172, .12) !important;
    color: rgba(218, 228, 240, .78) !important;
    font-size: 8px !important;
    line-height: 1 !important;
    letter-spacing: .07em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-area: bpm !important;
    display: grid !important;
    place-items: center start !important;
    width: 100% !important;
    height: 22px !important;
    color: #f4f8fe !important;
    font-size: 13px !important;
    line-height: 1 !important;
    font-variant-numeric: tabular-nums !important;
    white-space: nowrap !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-area: pct !important;
    display: grid !important;
    place-items: center end !important;
    width: 100% !important;
    height: 22px !important;
    color: rgba(210,222,236,.72) !important;
    font-size: 10px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  .tempo-column .range-button {
    grid-area: range !important;
    display: grid !important;
    place-items: center !important;
    justify-self: stretch !important;
    width: 100% !important;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 4px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
  }

  .tempo-column .vertical-slider {
    grid-area: slider !important;
    display: grid !important;
    grid-template-columns: 14px minmax(0, 1fr) 14px !important;
    grid-template-rows: 1fr !important;
    gap: 8px !important;
    place-items: center !important;
    width: 100% !important;
    height: 38px !important;
    min-height: 38px !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  .tempo-column .vertical-slider span {
    display: grid !important;
    place-items: center !important;
    width: 14px !important;
    height: 18px !important;
    color: rgba(230,240,252,.42) !important;
    font-size: 9px !important;
    line-height: 1 !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 22px !important;
    transform: none !important;
    transform-origin: center !important;
  }

  .platter-zone {
    grid-area: platter !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    place-items: center !important;
    overflow: visible !important;
  }

  .platter {
    display: grid !important;
    --platter-size: clamp(216px, calc(100vw - 48px), 294px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: var(--platter-size) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .transport-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.18fr) 54px !important;
    gap: 8px !important;
    width: min(100%, 342px) !important;
    max-width: 100% !important;
    height: 52px !important;
    min-height: 52px !important;
    margin: 0 auto !important;
  }

  .transport-row button {
    width: 100% !important;
    height: 52px !important;
    min-height: 52px !important;
    border-radius: 10px !important;
  }

  .deck-tools {
    grid-area: tools !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "loop"
      "hot"
      "opts" !important;
    grid-template-rows: auto auto auto !important;
    gap: 9px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 7px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 10px !important;
    border-radius: 13px !important;
  }

  .loop-box label {
    margin: 0 !important;
    font-size: 9px !important;
    line-height: 1 !important;
    letter-spacing: .13em !important;
  }

  .loop-size,
  .loop-row,
  .loop-extra-row {
    display: grid !important;
    width: 100% !important;
    gap: 7px !important;
    min-width: 0 !important;
  }

  .loop-size { grid-template-columns: 42px minmax(0, 1fr) 42px !important; }
  .loop-row { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; margin: 0 !important; }
  .loop-extra-row { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
  .loop-extra-row:last-child { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }

  .loop-size button,
  .loop-size strong,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 38px !important;
    min-height: 38px !important;
    margin: 0 !important;
    padding: 0 4px !important;
    border-radius: 9px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .hotcue-box {
    grid-area: hot !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 10px !important;
    border-radius: 13px !important;
  }

  .hotcue-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 7px !important;
    width: 100% !important;
  }

  .hotcue-grid button {
    width: 100% !important;
    min-width: 0 !important;
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 9px !important;
    font-size: 13px !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 7px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .deck-options button {
    width: 100% !important;
    min-width: 0 !important;
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 9px !important;
    padding: 0 3px !important;
    font-size: 8.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }
}

@media (max-width: 390px) {
  .tempo-column {
    grid-template-columns: 62px minmax(0, 1fr) 50px !important;
    gap: 7px 6px !important;
    padding: 9px !important;
  }

  .tempo-column .sync-button,
  .tempo-column .range-button {
    font-size: 9px !important;
    padding-inline: 3px !important;
  }

  .tempo-column .master-button,
  .tempo-column .sync-status {
    font-size: 7px !important;
    padding-inline: 3px !important;
  }

  .platter {
    --platter-size: clamp(200px, calc(100vw - 46px), 274px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) 48px !important;
  }
}

@media (max-width: 340px) {
  .tempo-column {
    grid-template-columns: 58px minmax(0, 1fr) 46px !important;
  }

  .platter {
    --platter-size: clamp(188px, calc(100vw - 42px), 254px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr) 44px !important;
    gap: 6px !important;
  }
}

/* v1.53 mobile deck structure pass: make the phone deck a deliberate card stack.
   Tempo controls, jog/transport, and deck tools each get their own flow area so no
   controls can overlap the platter or bleed into the next section. */
@media (min-width: 761px) {
  .tempo-column,
  .tempo-column .sync-button {
    overflow: visible !important;
  }

  .tempo-column .sync-button {
    box-sizing: border-box !important;
    width: calc(100% - 8px) !important;
    max-width: calc(100% - 8px) !important;
    justify-self: center !important;
    margin-inline: 4px !important;
    padding-inline: 4px !important;
    border-radius: 9px !important;
    white-space: nowrap !important;
  }
}

@media (max-width: 760px) {
  .deck {
    overflow: visible !important;
    grid-template-rows: auto 16px auto 64px 26px 20px auto !important;
  }

  .deck-body {
    grid-row: 7 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo"
      "platter"
      "tools" !important;
    grid-template-rows: auto auto auto !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    align-items: stretch !important;
    justify-items: stretch !important;
    overflow: visible !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    position: relative !important;
    display: grid !important;
    grid-template-columns: minmax(74px, .92fr) minmax(0, 1fr) minmax(58px, .72fr) !important;
    grid-template-areas:
      "sync master range"
      "bpm status pct"
      "slider slider slider" !important;
    grid-template-rows: 38px 26px 42px !important;
    gap: 8px !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    min-height: 0 !important;
    height: auto !important;
    padding: 10px !important;
    align-items: center !important;
    justify-items: stretch !important;
    overflow: hidden !important;
    border: 1px solid rgba(154, 196, 238, .15) !important;
    border-radius: 14px !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.010)),
      rgba(2, 6, 10, .58) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04) !important;
  }

  .tempo-column > *,
  .tempo-column button,
  .tempo-column small,
  .tempo-column strong,
  .tempo-column span,
  .tempo-column label,
  .tempo-column input {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    float: none !important;
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column .sync-button {
    grid-area: sync !important;
    width: 100% !important;
    height: 38px !important;
    min-height: 38px !important;
    display: grid !important;
    place-items: center !important;
    padding: 0 6px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    letter-spacing: .075em !important;
    overflow: hidden !important;
    white-space: nowrap !important;
  }

  .tempo-column .master-button {
    grid-area: master !important;
    width: 100% !important;
    height: 24px !important;
    min-height: 24px !important;
    display: grid !important;
    place-items: center !important;
    padding: 0 8px !important;
    border-radius: 999px !important;
    font-size: 8px !important;
    line-height: 1 !important;
    letter-spacing: .065em !important;
    overflow: hidden !important;
    white-space: nowrap !important;
  }

  .tempo-column .range-button {
    grid-area: range !important;
    width: 100% !important;
    height: 38px !important;
    min-height: 38px !important;
    display: grid !important;
    place-items: center !important;
    padding: 0 5px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-area: bpm !important;
    display: grid !important;
    place-items: center start !important;
    width: 100% !important;
    height: 24px !important;
    color: #f4f8fe !important;
    font-size: 13px !important;
    line-height: 1 !important;
    font-variant-numeric: tabular-nums !important;
    white-space: nowrap !important;
  }

  .tempo-column .sync-status {
    grid-area: status !important;
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    height: 22px !important;
    min-height: 22px !important;
    padding: 0 6px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: rgba(120, 144, 172, .12) !important;
    color: rgba(218, 228, 240, .78) !important;
    font-size: 8px !important;
    line-height: 1 !important;
    letter-spacing: .07em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-area: pct !important;
    display: grid !important;
    place-items: center end !important;
    width: 100% !important;
    height: 24px !important;
    color: rgba(210,222,236,.72) !important;
    font-size: 10px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  .tempo-column .vertical-slider {
    grid-area: slider !important;
    display: grid !important;
    grid-template-columns: 14px minmax(0, 1fr) 14px !important;
    grid-template-rows: 1fr !important;
    gap: 8px !important;
    place-items: center !important;
    width: 100% !important;
    height: 42px !important;
    min-height: 42px !important;
    padding: 0 !important;
    overflow: visible !important;
  }

  .tempo-column .vertical-slider span {
    display: grid !important;
    place-items: center !important;
    width: 14px !important;
    height: 18px !important;
    color: rgba(230,240,252,.42) !important;
    font-size: 9px !important;
    line-height: 1 !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 22px !important;
    transform: none !important;
    transform-origin: center !important;
  }

  .platter-zone {
    grid-area: platter !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto 54px !important;
    gap: 14px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 12px !important;
    place-items: center !important;
    overflow: visible !important;
    border: 1px solid rgba(154, 196, 238, .12) !important;
    border-radius: 15px !important;
    background:
      radial-gradient(circle at 50% 38%, rgba(53,168,255,.10), transparent 58%),
      rgba(2, 6, 10, .42) !important;
  }

  .deck-b .platter-zone {
    background:
      radial-gradient(circle at 50% 38%, rgba(255,148,31,.10), transparent 58%),
      rgba(2, 6, 10, .42) !important;
  }

  .platter {
    display: grid !important;
    --platter-size: clamp(208px, 61vw, 256px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: 100% !important;
    max-height: var(--platter-size) !important;
    min-width: 0 !important;
    min-height: 0 !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: center !important;
    overflow: hidden !important;
  }

  .platter-ring,
  .platter-core {
    border-radius: 50% !important;
  }

  .transport-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.16fr) 52px !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 54px !important;
    min-height: 54px !important;
    margin: 0 !important;
    overflow: visible !important;
  }

  .transport-row button {
    width: 100% !important;
    height: 54px !important;
    min-height: 54px !important;
    min-width: 0 !important;
    border-radius: 11px !important;
    padding: 0 4px !important;
  }

  .deck-tools {
    grid-area: tools !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "loop"
      "hot"
      "opts" !important;
    grid-template-rows: auto auto auto !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  .loop-box,
  .hotcue-box {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 10px !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    background: rgba(2, 6, 10, .42) !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    grid-template-areas:
      "label label"
      "size inout"
      "auto auto"
      "jump jump"
      "move move" !important;
    gap: 7px !important;
  }

  .loop-box label {
    grid-area: label !important;
    margin: 0 !important;
    height: 14px !important;
    line-height: 14px !important;
    font-size: 9px !important;
    letter-spacing: .14em !important;
    text-align: center !important;
  }

  .loop-size {
    grid-area: size !important;
    display: grid !important;
    grid-template-columns: 40px minmax(0, 1fr) 40px !important;
    gap: 6px !important;
    min-width: 0 !important;
  }

  .loop-row {
    grid-area: inout !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
    margin: 0 !important;
    min-width: 0 !important;
  }

  .loop-toggle {
    grid-area: auto !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .loop-extra-row {
    display: grid !important;
    gap: 6px !important;
    margin: 0 !important;
    min-width: 0 !important;
  }

  .loop-box .loop-extra-row:nth-of-type(3) {
    grid-area: jump !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .loop-box .loop-extra-row:nth-of-type(4) {
    grid-area: move !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .loop-size button,
  .loop-size strong,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: 38px !important;
    min-height: 38px !important;
    margin: 0 !important;
    padding: 0 4px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .loop-size strong {
    background: rgba(0,0,0,.22) !important;
    border: 1px solid rgba(154,196,238,.10) !important;
  }

  .hotcue-box {
    grid-area: hot !important;
  }

  .hotcue-box label {
    display: block !important;
    margin: 0 0 8px !important;
    font-size: 9px !important;
    letter-spacing: .14em !important;
    text-align: center !important;
  }

  .hotcue-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 7px !important;
    width: 100% !important;
  }

  .hotcue-grid button {
    width: 100% !important;
    min-width: 0 !important;
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 10px !important;
    font-size: 13px !important;
  }

  .hotcue-hint {
    display: none !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 7px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .deck-options button {
    width: 100% !important;
    min-width: 0 !important;
    height: 40px !important;
    min-height: 40px !important;
    border-radius: 10px !important;
    padding: 0 4px !important;
    font-size: 8.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

@media (max-width: 390px) {
  .tempo-column {
    grid-template-columns: minmax(66px, .9fr) minmax(0, 1fr) minmax(50px, .66fr) !important;
    gap: 7px 6px !important;
    padding: 9px !important;
  }

  .tempo-column .sync-button,
  .tempo-column .range-button {
    font-size: 9px !important;
    padding-inline: 3px !important;
  }

  .tempo-column .master-button,
  .tempo-column .sync-status {
    font-size: 7px !important;
    padding-inline: 3px !important;
  }

  .platter-zone {
    padding: 10px !important;
    gap: 12px !important;
  }

  .platter {
    --platter-size: clamp(198px, 60vw, 238px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr) 48px !important;
    gap: 7px !important;
  }

  .loop-box {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "label"
      "size"
      "inout"
      "auto"
      "jump"
      "move" !important;
  }

  .loop-size,
  .loop-row,
  .loop-toggle,
  .loop-box .loop-extra-row:nth-of-type(3),
  .loop-box .loop-extra-row:nth-of-type(4) {
    grid-column: 1 !important;
  }
}

@media (max-width: 340px) {
  .tempo-column {
    grid-template-columns: minmax(60px, .9fr) minmax(0, 1fr) 46px !important;
  }

  .platter {
    --platter-size: clamp(184px, 58vw, 220px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr) 44px !important;
    gap: 6px !important;
  }
}

/* v1.54 mobile deck north-star pass.
   The phone deck is rebuilt as a clear stack of cards: header and waveform,
   tempo controls, platter and transport, loop controls, and hot cues/options.
   Desktop rules are untouched except for the existing sync-button guard. */
@media (max-width: 760px) {
  html,
  body {
    min-width: 0 !important;
    width: 100% !important;
    overflow-x: hidden !important;
  }

  .app-shell {
    width: 100% !important;
    max-width: 470px !important;
    padding-inline: 8px !important;
  }

  .main-grid,
  .deck,
  .deck-body,
  .tempo-column,
  .platter-zone,
  .deck-tools,
  .loop-box,
  .hotcue-box,
  .deck-options {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .deck {
    display: grid !important;
    grid-template-rows: auto 16px auto auto auto auto !important;
    gap: 8px !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 12px !important;
    overflow: visible !important;
    border-radius: 18px !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.012)),
      rgba(8, 13, 19, .96) !important;
  }

  .deck-header {
    height: auto !important;
    min-height: 46px !important;
    grid-template-columns: 44px minmax(0, 1fr) minmax(74px, auto) !important;
    gap: 10px !important;
  }

  .deck-badge {
    width: 44px !important;
    height: 44px !important;
    border-radius: 10px !important;
    font-size: 18px !important;
  }

  .track-title-block h2 {
    font-size: 16px !important;
    line-height: 1.12 !important;
  }

  .track-title-block p {
    font-size: 11px !important;
  }

  .deck-meta {
    min-width: 70px !important;
    gap: 2px !important;
  }

  .bpm-edit-button strong {
    font-size: 14px !important;
  }

  .grid-panel {
    grid-template-columns: minmax(118px, .95fr) minmax(0, 2fr) !important;
    gap: 8px !important;
    align-items: stretch !important;
  }

  .grid-readout {
    min-height: 48px !important;
    padding: 8px 10px !important;
    border-radius: 10px !important;
  }

  .grid-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .grid-actions button {
    height: 23px !important;
    min-height: 23px !important;
    padding: 0 3px !important;
    border-radius: 8px !important;
    font-size: 8px !important;
  }

  .wave-wrap {
    height: 64px !important;
    border-radius: 11px !important;
  }

  .zoom-waveform {
    display: block !important;
    height: 36px !important;
    border-radius: 10px !important;
  }

  .time-row {
    margin: 0 !important;
    gap: 7px !important;
  }

  .time-row time {
    font-size: 11px !important;
  }

  .deck-body {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "tempo"
      "platter"
      "tools" !important;
    grid-template-rows: auto auto auto !important;
    gap: 14px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    align-items: stretch !important;
  }

  .tempo-column {
    grid-area: tempo !important;
    display: grid !important;
    grid-template-columns: minmax(86px, 1fr) minmax(104px, 1.15fr) minmax(76px, .86fr) !important;
    grid-template-areas:
      "sync master range"
      "bpm pitch status"
      "slider slider slider" !important;
    grid-template-rows: 46px 52px 48px !important;
    gap: 10px !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 12px !important;
    overflow: hidden !important;
    border-radius: 16px !important;
    border: 1px solid rgba(154,196,238,.16) !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.012)),
      rgba(3, 8, 13, .62) !important;
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,.045),
      0 10px 26px rgba(0,0,0,.22) !important;
  }

  .tempo-column > *,
  .tempo-column button,
  .tempo-column label,
  .tempo-column input,
  .tempo-column span,
  .tempo-column strong,
  .tempo-column small {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    float: none !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
  }

  .tempo-column .sync-primer,
  .tempo-column .phase-meter {
    display: none !important;
  }

  .tempo-column .sync-button,
  .tempo-column .master-button,
  .tempo-column .range-button {
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 46px !important;
    min-height: 46px !important;
    padding: 0 7px !important;
    border-radius: 12px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    line-height: 1 !important;
  }

  .tempo-column .sync-button {
    grid-area: sync !important;
    color: #9bd7ff !important;
    border-color: rgba(47,155,255,.52) !important;
    font-size: 11px !important;
    letter-spacing: .09em !important;
  }

  .tempo-column .master-button {
    grid-area: master !important;
    color: #10210d !important;
    border-color: rgba(99,212,84,.72) !important;
    background: linear-gradient(180deg, rgba(126,237,109,.95), rgba(55,169,46,.90)) !important;
    box-shadow: 0 0 20px rgba(99,212,84,.18), inset 0 1px 0 rgba(255,255,255,.30) !important;
    font-size: 11px !important;
    letter-spacing: .07em !important;
  }

  .tempo-column .range-button {
    grid-area: range !important;
    display: grid !important;
    grid-template-rows: 1fr auto !important;
    color: #eaf3ff !important;
    font-size: 11px !important;
  }

  .tempo-column .range-button::after {
    content: "PITCH RANGE";
    display: block;
    margin-top: 2px;
    color: rgba(205,218,233,.68);
    font-size: 7px;
    letter-spacing: .08em;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"],
  .tempo-column .sync-status {
    height: 52px !important;
    min-height: 52px !important;
    width: 100% !important;
    padding: 8px 6px !important;
    display: grid !important;
    place-items: center !important;
    border-left: 1px solid rgba(154,196,238,.10) !important;
    color: #f5f9ff !important;
    background: transparent !important;
    border-radius: 0 !important;
    line-height: 1.05 !important;
    font-variant-numeric: tabular-nums !important;
    text-align: center !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"] {
    grid-area: bpm !important;
    border-left: 0 !important;
    font-size: 18px !important;
    font-weight: 900 !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"]::after {
    content: "BPM";
    display: block;
    margin-top: 5px;
    color: rgba(205,218,233,.68);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .08em;
  }

  .tempo-column > span[data-role="tempo-pct"] {
    grid-area: pitch !important;
    color: #f5f9ff !important;
    font-size: 18px !important;
    font-weight: 900 !important;
  }

  .tempo-column > span[data-role="tempo-pct"]::after {
    content: "PITCH";
    display: block;
    margin-top: 5px;
    color: rgba(205,218,233,.68);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .08em;
  }

  .tempo-column .sync-status {
    grid-area: status !important;
    grid-template-columns: 20px 1fr 8px !important;
    gap: 5px !important;
    justify-items: center !important;
    color: rgba(226,236,248,.88) !important;
    font-size: 9px !important;
    letter-spacing: .08em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .tempo-column .sync-status::before {
    content: "";
    width: 18px;
    height: 18px;
    border: 2px solid rgba(232,242,255,.86);
    border-radius: 999px;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.40);
  }

  .tempo-column .sync-status::after {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: var(--green);
    box-shadow: 0 0 10px rgba(99,212,84,.72);
  }

  .tempo-column .vertical-slider {
    grid-area: slider !important;
    display: grid !important;
    grid-template-columns: 18px minmax(0, 1fr) 18px !important;
    grid-template-rows: 1fr !important;
    gap: 10px !important;
    place-items: center !important;
    width: 100% !important;
    height: 48px !important;
    min-height: 48px !important;
    padding: 8px 10px !important;
    overflow: visible !important;
    border-top: 1px solid rgba(154,196,238,.10) !important;
  }

  .tempo-column .vertical-slider span {
    display: grid !important;
    place-items: center !important;
    width: 18px !important;
    height: 18px !important;
    color: rgba(230,240,252,.72) !important;
    font-size: 18px !important;
    line-height: 1 !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    display: block !important;
    width: 100% !important;
    height: 24px !important;
    min-width: 0 !important;
    max-width: 100% !important;
    transform: none !important;
    touch-action: pan-x !important;
  }

  .platter-zone {
    grid-area: platter !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: minmax(238px, auto) 56px !important;
    gap: 16px !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 18px 14px 14px !important;
    overflow: hidden !important;
    place-items: center !important;
    border-radius: 18px !important;
    border: 1px solid rgba(154,196,238,.15) !important;
    background:
      radial-gradient(circle at 50% 42%, rgba(53,168,255,.12), transparent 60%),
      linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.010)),
      rgba(3, 8, 13, .58) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04), 0 12px 28px rgba(0,0,0,.22) !important;
  }

  .deck-b .platter-zone {
    background:
      radial-gradient(circle at 50% 42%, rgba(255,148,31,.13), transparent 60%),
      linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.010)),
      rgba(3, 8, 13, .58) !important;
  }

  .platter {
    display: grid !important;
    --platter-size: clamp(218px, 64vw, 282px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: calc(100vw - 72px) !important;
    max-height: var(--platter-size) !important;
    min-width: 0 !important;
    min-height: 0 !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    justify-self: center !important;
    align-self: end !important;
    margin: 0 !important;
    overflow: hidden !important;
    position: relative !important;
    z-index: 1 !important;
  }

  .transport-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, .96fr) minmax(54px, .78fr) !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 56px !important;
    min-height: 56px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 2 !important;
    overflow: visible !important;
  }

  .transport-row button {
    width: 100% !important;
    height: 56px !important;
    min-height: 56px !important;
    min-width: 0 !important;
    border-radius: 13px !important;
    padding: 0 6px !important;
    font-size: 12px !important;
    letter-spacing: .09em !important;
  }

  .transport-row .play-button {
    font-size: 18px !important;
  }

  .deck-tools {
    grid-area: tools !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "loop"
      "hot"
      "opts" !important;
    grid-template-rows: auto auto auto !important;
    gap: 12px !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
  }

  .loop-box,
  .hotcue-box {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    padding: 12px !important;
    border-radius: 16px !important;
    border: 1px solid rgba(154,196,238,.14) !important;
    background:
      linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.010)),
      rgba(3, 8, 13, .54) !important;
    overflow: hidden !important;
  }

  .loop-box {
    grid-area: loop !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    grid-template-areas:
      "label label"
      "inout jumps"
      "auto auto"
      "size size"
      "move move" !important;
    grid-template-rows: 14px auto auto auto auto !important;
    gap: 8px !important;
  }

  .loop-box label,
  .hotcue-box label {
    margin: 0 !important;
    height: 14px !important;
    color: rgba(215,227,243,.76) !important;
    font-size: 10px !important;
    line-height: 14px !important;
    letter-spacing: .18em !important;
    text-align: center !important;
  }

  .loop-box label { grid-area: label !important; }

  .loop-row {
    grid-area: inout !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    margin: 0 !important;
  }

  .loop-box .loop-extra-row:nth-of-type(3) {
    grid-area: jumps !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 7px !important;
    margin: 0 !important;
  }

  .loop-toggle {
    grid-area: auto !important;
    width: 100% !important;
    margin: 0 !important;
    color: var(--yellow) !important;
  }

  .loop-size {
    grid-area: size !important;
    display: grid !important;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.65fr) minmax(0, .9fr) !important;
    gap: 8px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  .loop-size strong::after {
    content: " BEATS";
  }

  .loop-box .loop-extra-row:nth-of-type(4) {
    grid-area: move !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    margin: 0 !important;
  }

  .loop-size button,
  .loop-size strong,
  .loop-row button,
  .loop-toggle,
  .loop-extra-row button {
    display: grid !important;
    place-items: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 44px !important;
    min-height: 44px !important;
    margin: 0 !important;
    padding: 0 5px !important;
    border-radius: 12px !important;
    font-size: 11px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .loop-size strong {
    border: 1px solid rgba(154,196,238,.12) !important;
    background: rgba(0,0,0,.22) !important;
    color: #f6fbff !important;
    font-size: 12px !important;
    letter-spacing: .08em !important;
  }

  .hotcue-box {
    grid-area: hot !important;
  }

  .hotcue-box label {
    display: block !important;
    margin-bottom: 10px !important;
  }

  .hotcue-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .hotcue-grid button {
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    border-radius: 12px !important;
    font-size: 14px !important;
  }

  .deck-options {
    grid-area: opts !important;
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .deck-options button {
    width: 100% !important;
    height: 42px !important;
    min-height: 42px !important;
    border-radius: 12px !important;
    padding: 0 4px !important;
    font-size: 9px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

@media (max-width: 390px) {
  .tempo-column {
    grid-template-columns: minmax(78px, 1fr) minmax(88px, 1.05fr) minmax(64px, .82fr) !important;
    gap: 8px !important;
    padding: 10px !important;
  }

  .tempo-column .sync-button,
  .tempo-column .master-button,
  .tempo-column .range-button {
    height: 42px !important;
    min-height: 42px !important;
    font-size: 9.5px !important;
    padding-inline: 5px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"],
  .tempo-column .sync-status {
    height: 48px !important;
    min-height: 48px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"] {
    font-size: 15px !important;
  }

  .tempo-column .sync-status {
    grid-template-columns: 16px 1fr 7px !important;
    font-size: 7.5px !important;
  }

  .tempo-column .sync-status::before {
    width: 15px;
    height: 15px;
  }

  .platter {
    --platter-size: clamp(208px, 62vw, 258px) !important;
  }

  .platter-zone {
    grid-template-rows: minmax(226px, auto) 54px !important;
    padding: 14px 12px 12px !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, .9fr) 50px !important;
    gap: 8px !important;
  }

  .loop-box {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "label"
      "inout"
      "jumps"
      "auto"
      "size"
      "move" !important;
  }

  .loop-size,
  .loop-row,
  .loop-box .loop-extra-row:nth-of-type(3),
  .loop-box .loop-extra-row:nth-of-type(4) {
    grid-column: 1 !important;
  }
}

@media (max-width: 340px) {
  .tempo-column {
    grid-template-columns: minmax(70px, 1fr) minmax(76px, 1fr) minmax(56px, .75fr) !important;
  }

  .platter {
    --platter-size: clamp(192px, 60vw, 238px) !important;
  }

  .transport-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, .88fr) 44px !important;
    gap: 7px !important;
  }
}


/* v1.55 mobile deck fit pass.
   Tighten the phone deck composition so the beat-grid row never clips, the
   tempo strip reads like a real control bar, the pitch slider spans the full
   card width, and the platter card hugs the jog/transport instead of leaving
   a giant empty stage. Desktop remains unchanged. */
@media (max-width: 760px) {
  .grid-panel {
    align-items: start !important;
    gap: 8px !important;
    padding-bottom: 3px !important;
  }

  .grid-readout {
    min-height: 52px !important;
    padding-block: 9px !important;
  }

  .grid-actions {
    align-content: start !important;
    gap: 6px !important;
    padding-bottom: 2px !important;
  }

  .grid-actions button {
    height: 26px !important;
    min-height: 26px !important;
    line-height: 1 !important;
  }

  .tempo-column {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    grid-template-areas:
      "sync master range"
      "bpm pitch status"
      "slider slider slider" !important;
    grid-template-rows: 44px 50px 56px !important;
    gap: 8px !important;
    padding: 12px !important;
    border-radius: 16px !important;
  }

  .tempo-column .sync-button,
  .tempo-column .master-button,
  .tempo-column .range-button {
    height: 44px !important;
    min-height: 44px !important;
    font-size: 11px !important;
    border-radius: 12px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"],
  .tempo-column .sync-status {
    height: 50px !important;
    min-height: 50px !important;
    padding: 6px 4px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"] {
    font-size: 17px !important;
  }

  .tempo-column .sync-status {
    grid-template-columns: 18px 1fr 8px !important;
    gap: 4px !important;
    font-size: 8.5px !important;
  }

  .tempo-column .vertical-slider {
    grid-template-columns: 18px minmax(0, 1fr) 18px !important;
    grid-template-areas: "minus range plus" !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 10px 6px 0 !important;
    gap: 8px !important;
  }

  .tempo-column .vertical-slider span:first-child {
    grid-area: plus !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .tempo-column .vertical-slider span:last-child {
    grid-area: minus !important;
    justify-self: center !important;
    align-self: center !important;
  }

  .tempo-column .vertical-slider input[type="range"] {
    grid-area: range !important;
    width: 100% !important;
    margin: 0 !important;
    align-self: center !important;
  }

  .platter-zone {
    grid-template-rows: auto auto !important;
    gap: 12px !important;
    padding: 14px 12px 12px !important;
    min-height: 0 !important;
    align-items: center !important;
    justify-items: center !important;
  }

  .platter {
    --platter-size: clamp(206px, 58vw, 246px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: calc(100vw - 86px) !important;
    align-self: center !important;
    justify-self: center !important;
  }

  .transport-row {
    width: min(100%, 292px) !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr) 56px !important;
    justify-self: center !important;
    align-self: center !important;
    gap: 10px !important;
    margin-inline: auto !important;
  }
}

@media (max-width: 390px) {
  .grid-actions button {
    height: 25px !important;
    min-height: 25px !important;
    font-size: 7.6px !important;
    padding-inline: 2px !important;
  }

  .tempo-column {
    grid-template-rows: 42px 46px 54px !important;
    gap: 7px !important;
    padding: 10px !important;
  }

  .tempo-column .sync-button,
  .tempo-column .master-button,
  .tempo-column .range-button {
    height: 42px !important;
    min-height: 42px !important;
    font-size: 10px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"],
  .tempo-column .sync-status {
    height: 46px !important;
    min-height: 46px !important;
  }

  .tempo-column > strong[data-role="tempo-bpm"],
  .tempo-column > span[data-role="tempo-pct"] {
    font-size: 16px !important;
  }

  .tempo-column .sync-status {
    font-size: 7.6px !important;
  }

  .tempo-column .vertical-slider {
    height: 54px !important;
    min-height: 54px !important;
  }

  .platter {
    --platter-size: clamp(194px, 56vw, 228px) !important;
  }

  .transport-row {
    width: min(100%, 276px) !important;
    gap: 8px !important;
  }
}


/* v1.56 mobile refinement pass.
   Fix the clipped second row of beat-grid buttons and reposition the mobile
   platter so the jog sits higher with transport clearly below it. */
@media (max-width: 760px) {
  .grid-panel {
    min-height: 70px !important;
    overflow: visible !important;
    align-items: start !important;
    padding-bottom: 4px !important;
  }

  .grid-actions {
    align-content: start !important;
    grid-auto-rows: 26px !important;
    gap: 6px !important;
    overflow: visible !important;
    padding-bottom: 2px !important;
  }

  .grid-actions button {
    height: 26px !important;
    min-height: 26px !important;
    line-height: 1 !important;
    padding-block: 0 !important;
  }

  .platter-zone {
    min-height: 356px !important;
    grid-template-rows: auto 56px !important;
    align-content: start !important;
    justify-items: center !important;
    gap: 14px !important;
    padding: 16px 12px 14px !important;
  }

  .platter {
    align-self: start !important;
    justify-self: center !important;
    margin-top: 2px !important;
  }

  .transport-row {
    align-self: start !important;
    justify-self: center !important;
    margin: 0 auto !important;
  }
}

@media (max-width: 390px) {
  .grid-panel {
    min-height: 72px !important;
  }

  .grid-actions {
    grid-auto-rows: 25px !important;
  }

  .grid-actions button {
    height: 25px !important;
    min-height: 25px !important;
  }

  .platter-zone {
    min-height: 342px !important;
    gap: 12px !important;
    padding: 14px 12px 12px !important;
  }
}


/* v1.57 focused mobile platter-card pass.
   Nail the phone jog card: platter sits higher, transport lives cleanly below,
   and the whole card reads as one balanced control surface. */
@media (max-width: 760px) {
  .platter-zone {
    min-height: 338px !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: minmax(218px, auto) 58px !important;
    align-content: start !important;
    justify-items: center !important;
    gap: 14px !important;
    padding: 18px 14px 16px !important;
    overflow: hidden !important;
  }

  .platter {
    --platter-size: clamp(196px, 56vw, 236px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: calc(100vw - 108px) !important;
    align-self: start !important;
    justify-self: center !important;
    margin: 0 !important;
  }

  .transport-row {
    width: min(100%, 286px) !important;
    height: 58px !important;
    min-height: 58px !important;
    grid-template-columns: minmax(86px, 1fr) minmax(106px, 1.08fr) 60px !important;
    gap: 10px !important;
    align-self: end !important;
    justify-self: center !important;
    margin: 0 auto !important;
    position: static !important;
    z-index: 1 !important;
  }

  .transport-row button {
    height: 58px !important;
    min-height: 58px !important;
    border-radius: 14px !important;
  }
}

@media (max-width: 390px) {
  .platter-zone {
    min-height: 324px !important;
    grid-template-rows: minmax(204px, auto) 56px !important;
    gap: 12px !important;
    padding: 16px 12px 14px !important;
  }

  .platter {
    --platter-size: clamp(188px, 54vw, 224px) !important;
    max-width: calc(100vw - 96px) !important;
  }

  .transport-row {
    width: min(100%, 270px) !important;
    height: 56px !important;
    min-height: 56px !important;
    grid-template-columns: minmax(82px, 1fr) minmax(100px, 1.05fr) 56px !important;
    gap: 8px !important;
  }

  .transport-row button {
    height: 56px !important;
    min-height: 56px !important;
  }
}


/* v1.58 focused mobile jog card pass.
   Keep the jog card only as tall as needed and enforce a strict two-row
   composition: wheel on top, transport row below, with no overlap. */
@media (max-width: 760px) {
  .platter-zone {
    min-height: 0 !important;
    height: auto !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    align-content: start !important;
    align-items: start !important;
    justify-items: center !important;
    gap: 14px !important;
    padding: 14px 12px 12px !important;
    overflow: hidden !important;
  }

  .platter {
    grid-row: 1 !important;
    --platter-size: clamp(194px, 54vw, 224px) !important;
    width: var(--platter-size) !important;
    height: var(--platter-size) !important;
    max-width: calc(100vw - 112px) !important;
    align-self: start !important;
    justify-self: center !important;
    margin: 0 !important;
  }

  .transport-row {
    grid-row: 2 !important;
    width: min(100%, 280px) !important;
    height: 54px !important;
    min-height: 54px !important;
    grid-template-columns: minmax(88px, 1fr) minmax(112px, 1.08fr) 56px !important;
    gap: 10px !important;
    align-self: start !important;
    justify-self: center !important;
    margin: 0 auto !important;
    position: static !important;
    inset: auto !important;
    transform: none !important;
    z-index: 1 !important;
  }

  .transport-row button {
    height: 54px !important;
    min-height: 54px !important;
    border-radius: 14px !important;
  }
}

@media (max-width: 390px) {
  .platter-zone {
    gap: 12px !important;
    padding: 12px 10px 10px !important;
  }

  .platter {
    --platter-size: clamp(186px, 53vw, 214px) !important;
    max-width: calc(100vw - 100px) !important;
  }

  .transport-row {
    width: min(100%, 266px) !important;
    height: 52px !important;
    min-height: 52px !important;
    grid-template-columns: minmax(82px, 1fr) minmax(104px, 1.06fr) 52px !important;
    gap: 8px !important;
  }

  .transport-row button {
    height: 52px !important;
    min-height: 52px !important;
  }
}


/* v1.59 mobile jog-card centering pass.
   Make left/right breathing room visually equal and keep both the jog and
   transport row centered as one balanced composition. */
@media (max-width: 760px) {
  .platter-zone {
    justify-items: center !important;
    align-items: start !important;
    padding-inline: 12px !important;
  }

  .platter {
    justify-self: center !important;
    margin-inline: auto !important;
  }

  .transport-row {
    width: min(100%, 292px) !important;
    grid-template-columns: minmax(80px, .95fr) minmax(108px, 1.12fr) minmax(80px, .95fr) !important;
    justify-self: center !important;
    margin-inline: auto !important;
  }

  .cue-button,
  .set-button {
    width: 100% !important;
    justify-self: stretch !important;
  }

  .play-button {
    width: 100% !important;
    justify-self: stretch !important;
  }
}

@media (max-width: 390px) {
  .platter-zone {
    padding-inline: 10px !important;
  }

  .transport-row {
    width: min(100%, 276px) !important;
    grid-template-columns: minmax(76px, .94fr) minmax(102px, 1.1fr) minmax(76px, .94fr) !important;
  }
}

/* v1.60 content layer: app-first, SVG-only, no card soup, no decorative glow. */
.seo-content-v2 {
  --content-bg: #060b11;
  --content-panel: #0a1119;
  --content-panel-2: #0c141e;
  --content-line: rgba(169, 190, 211, 0.16);
  --content-line-strong: rgba(169, 190, 211, 0.25);
  --content-text: #f1f5f9;
  --content-muted: #aab6c4;
  --content-soft: #7f8d9d;
  --content-blue: #5aa8ff;
  --content-blue-strong: #2f8cff;
  width: 100% !important;
  max-width: none !important;
  margin: 24px 0 0 !important;
  padding: 0 !important;
  border: 1px solid var(--content-line) !important;
  border-radius: 18px !important;
  background: var(--content-bg) !important;
  box-shadow: none !important;
  overflow: hidden;
}

.seo-content-v2 *,
.seo-content-v2 *::before,
.seo-content-v2 *::after { box-sizing: border-box; }

.seo-content-v2 h1,
.seo-content-v2 h2,
.seo-content-v2 h3,
.seo-content-v2 p,
.seo-content-v2 ul { margin-top: 0; }

.seo-content-v2 h1,
.seo-content-v2 h2,
.seo-content-v2 h3 {
  color: var(--content-text);
  letter-spacing: -0.035em;
}

.seo-content-v2 p,
.seo-content-v2 li,
.seo-content-v2 small {
  color: var(--content-muted);
  line-height: 1.55;
}

.seo-content-v2 a { color: inherit; text-decoration: none; }

.seo-content-v2 svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.seo-icon {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: var(--content-blue);
  flex: 0 0 auto;
}

.seo-icon-large { width: 40px; height: 40px; }

.seo-trust-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--content-line);
  background: #081018;
}

.seo-trust-item {
  display: flex;
  gap: 14px;
  align-items: center;
  min-height: 70px;
  padding: 14px 22px;
  border-right: 1px solid var(--content-line);
}

.seo-trust-item:last-child { border-right: 0; }

.seo-trust-item strong,
.seo-trust-item small {
  display: block;
}

.seo-trust-item strong {
  color: var(--content-text);
  font-size: 14px;
  letter-spacing: -0.01em;
}

.seo-trust-item small {
  margin-top: 3px;
  font-size: 12px;
}

.seo-intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(420px, 0.95fr);
  gap: 0;
  border-bottom: 1px solid var(--content-line);
}

.seo-intro-copy {
  padding: clamp(24px, 3.2vw, 40px) clamp(22px, 3.2vw, 40px);
}

.seo-content-v2 .seo-eyebrow,
.seo-kicker {
  color: var(--content-blue);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.seo-content-v2 .seo-eyebrow { margin-bottom: 14px; }

.seo-kicker { margin-bottom: 8px; }

.seo-intro-copy h1 {
  max-width: 720px;
  margin-bottom: 20px;
  font-size: clamp(32px, 3.8vw, 52px);
  line-height: 1.0;
}

.seo-intro-copy p {
  max-width: 620px;
  margin-bottom: 16px;
  font-size: clamp(14px, 1vw, 16px);
}

.seo-intro-copy p:last-child { margin-bottom: 0; }

.seo-benefit-rows {
  display: grid;
  align-content: center;
  border-left: 1px solid var(--content-line);
}

.seo-benefit-rows article {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 20px clamp(22px, 3vw, 36px);
  border-bottom: 1px solid var(--content-line);
}

.seo-benefit-rows article:last-child { border-bottom: 0; }

.seo-benefit-rows h2,
.seo-proof-list h3 {
  margin-bottom: 4px;
  font-size: 17px;
  line-height: 1.18;
}

.seo-benefit-rows p,
.seo-proof-list p { margin: 0; font-size: 13px; }

.seo-feature-matrix {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--content-line);
}

.seo-feature-matrix article {
  padding: 26px clamp(20px, 3vw, 36px);
  border-right: 1px solid var(--content-line);
  background: transparent;
}

.seo-feature-matrix article:last-child { border-right: 0; }

.seo-feature-matrix h2 {
  margin: 20px 0 14px;
  font-size: 18px;
  line-height: 1.18;
}

.seo-feature-matrix ul,
.seo-check-list {
  display: grid;
  gap: 10px;
  margin-bottom: 0;
  padding-left: 0;
  list-style: none;
}

.seo-feature-matrix li {
  position: relative;
  padding-left: 18px;
  font-size: 14px;
}

.seo-feature-matrix li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--content-blue);
}

.seo-practice-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--content-line);
}

.seo-practice-split > section {
  padding: 26px clamp(20px, 3vw, 36px);
}

.seo-practice-split > section:first-child { border-right: 1px solid var(--content-line); }

.seo-practice-split h2,
.seo-learn-strip h2,
.seo-faq-v2 h2 {
  margin-bottom: 18px;
  font-size: clamp(20px, 1.8vw, 26px);
  line-height: 1.12;
}

.seo-check-list { gap: 0; }

.seo-check-list li {
  position: relative;
  padding: 9px 0 9px 32px;
  border-bottom: 1px solid rgba(169, 190, 211, 0.1);
  font-size: 14px;
  color: var(--content-text);
}

.seo-check-list li:last-child { border-bottom: 0; }

.seo-check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 13px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid rgba(90, 168, 255, 0.7);
  background: linear-gradient(180deg, rgba(90, 168, 255, 0.18), rgba(90, 168, 255, 0.05));
}

.seo-check-list li::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 19px;
  width: 6px;
  height: 3px;
  border-left: 1.5px solid var(--content-blue);
  border-bottom: 1.5px solid var(--content-blue);
  transform: rotate(-45deg);
}

.seo-proof-list {
  display: grid;
  gap: 0;
  border: 1px solid var(--content-line);
}

.seo-proof-list article {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 16px;
  padding: 18px;
  border-bottom: 1px solid var(--content-line);
}

.seo-proof-list article:last-child { border-bottom: 0; }

.seo-learn-strip {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  border-bottom: 1px solid var(--content-line);
}

.seo-strip-heading {
  padding: 22px;
  border-right: 1px solid var(--content-line);
}

.seo-strip-heading h2 { font-size: 18px; }

.seo-guide-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.seo-guide-links .seo-link {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 14px;
  row-gap: 2px;
  align-items: center;
  min-height: 112px;
  padding: 18px 18px;
  border: 0 !important;
  border-right: 1px solid var(--content-line) !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: inherit !important;
  font-size: 14px !important;
  font-weight: 700 !important;
}

.seo-guide-links .seo-link:last-child { border-right: 0 !important; }
.seo-guide-links .seo-icon { grid-row: 1 / span 2; }
.seo-guide-links strong { color: var(--content-text); font-size: 14px; line-height: 1.15; }
.seo-guide-links small { font-size: 12px; line-height: 1.35; font-weight: 500; }
.seo-guide-links b { grid-row: 1 / span 2; color: var(--content-blue); font-size: 22px; font-weight: 500; }

.seo-guide-links .seo-link:hover,
.seo-guide-links .seo-link:focus-visible {
  background: rgba(90, 168, 255, 0.055) !important;
  outline: none;
}

.seo-faq-v2 {
  padding: 24px clamp(20px, 3vw, 36px);
  border-bottom: 1px solid var(--content-line);
}

.faq-list-v2 {
  border: 1px solid var(--content-line);
}

.faq-list-v2 details {
  border: 0 !important;
  border-bottom: 1px solid var(--content-line) !important;
  border-radius: 0 !important;
  background: transparent !important;
  padding: 0 !important;
}

.faq-list-v2 details:last-child { border-bottom: 0 !important; }

.faq-list-v2 summary {
  position: relative;
  display: block;
  padding: 14px 52px 14px 18px;
  color: var(--content-text) !important;
  cursor: pointer;
  font-size: 15px;
  font-weight: 750 !important;
  list-style: none;
}

.faq-list-v2 summary::-webkit-details-marker { display: none; }

.faq-list-v2 summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--content-text);
  font-size: 20px;
  font-weight: 400;
}

.faq-list-v2 details[open] summary::after { content: "-"; }

.faq-list-v2 p {
  margin: -4px 52px 16px 18px !important;
  font-size: 14px;
}

.seo-bottom-cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 18px clamp(20px, 3vw, 36px);
  border-bottom: 1px solid var(--content-line);
  background: #081018;
}

.seo-bottom-cta p {
  margin: 0;
  color: var(--content-text);
  font-size: clamp(16px, 1.6vw, 20px);
  font-weight: 760;
  letter-spacing: -0.03em;
}

.seo-bottom-cta div {
  display: flex;
  align-items: center;
  gap: 18px;
}

.seo-bottom-cta .seo-cta-primary,
.seo-bottom-cta .seo-cta-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  border: 1px solid var(--content-line-strong) !important;
  border-radius: 7px !important;
  background: transparent !important;
  font-size: 14px !important;
  font-weight: 760 !important;
}

.seo-bottom-cta .seo-cta-primary {
  min-width: 190px;
  border-color: rgba(90, 168, 255, 0.55) !important;
  background: #1467d8 !important;
  color: #fff !important;
}

.seo-bottom-cta .seo-cta-secondary {
  border-color: transparent !important;
  color: #92caff !important;
}

.seo-bottom-cta a span { margin-left: 12px; }

.seo-footer-v2 {
  padding: 18px clamp(24px, 4vw, 46px) 24px;
  background: #05090e;
  text-align: center;
}

.seo-footer-v2 p {
  max-width: 760px;
  margin: 0 auto 12px;
  color: var(--content-soft);
  font-size: 12px;
}

.seo-footer-v2 nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.seo-footer-v2 nav a {
  color: var(--content-muted);
  font-size: 12px;
  text-decoration: none;
}

.seo-footer-v2 nav a:hover { color: var(--content-text); }

@media (max-width: 980px) {
  .seo-content-v2 { margin-top: 18px !important; border-radius: 14px !important; }
  .seo-trust-strip,
  .seo-intro-grid,
  .seo-feature-matrix,
  .seo-practice-split,
  .seo-learn-strip,
  .seo-bottom-cta { grid-template-columns: 1fr; }
  .seo-trust-item,
  .seo-feature-matrix article,
  .seo-practice-split > section:first-child,
  .seo-strip-heading,
  .seo-guide-links .seo-link { border-right: 0 !important; }
  .seo-trust-item,
  .seo-feature-matrix article,
  .seo-strip-heading { border-bottom: 1px solid var(--content-line); }
  .seo-benefit-rows { border-left: 0; border-top: 1px solid var(--content-line); }
  .seo-guide-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .seo-guide-links .seo-link:nth-child(odd) { border-right: 1px solid var(--content-line) !important; }
  .seo-bottom-cta div { justify-content: flex-start; flex-wrap: wrap; }
}

@media (max-width: 640px) {
  .seo-content-v2 { margin-left: 0 !important; margin-right: 0 !important; }
  .seo-trust-item { min-height: 70px; padding: 14px 18px; }
  .seo-intro-copy,
  .seo-practice-split > section,
  .seo-faq-v2,
  .seo-bottom-cta { padding: 24px 18px; }
  .seo-intro-copy h1 { font-size: 30px; }
  .seo-benefit-rows article { grid-template-columns: 32px minmax(0, 1fr); padding: 20px 18px; }
  .seo-feature-matrix article { padding: 24px 18px; }
  .seo-guide-links { grid-template-columns: 1fr; }
  .seo-guide-links .seo-link:nth-child(odd),
  .seo-guide-links .seo-link { border-right: 0 !important; border-bottom: 1px solid var(--content-line) !important; }
  .seo-guide-links .seo-link:last-child { border-bottom: 0 !important; }
  .seo-bottom-cta .seo-cta-primary { width: 100%; }
  .seo-footer-v2 { padding-inline: 18px; }
}

.audio-quality {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--muted);
}
.audio-quality-good { color: #89d98f; }
.audio-quality-warning { color: #ffd35b; }
.audio-quality-poor { color: #ff7d86; }
.audio-quality-unknown { color: var(--muted); }
