:root {
  --bg: #000;
  --fg: #f3f3f3;
  --dim: rgba(243, 243, 243, 0.42);
  --faint: rgba(243, 243, 243, 0.18);
  --line: rgba(243, 243, 243, 0.14);
  --line-2: rgba(243, 243, 243, 0.28);
  --rail: 176px;
  --rail-min: 40px;
  --lab-side: 268px;
  --ui: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --data: "SFMono-Regular", "SF Mono", Menlo, Consolas, ui-monospace, monospace;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--ui);
  letter-spacing: 0.01em;
}

body {
  overflow: hidden;
}

button,
input,
label {
  font: inherit;
  color: inherit;
}

#splash {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #000;
  gap: 0;
}

#splash.is-gone {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
}

.splash-logo {
  width: min(42vh, 340px);
  height: auto;
  margin-bottom: 8px;
  filter: contrast(1.15);
}

.wordmark {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.62em;
  text-transform: uppercase;
  text-indent: 0.62em;
}

.splash-sub {
  margin: 14px 0 22px;
  font-family: var(--data);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.splash-bar {
  width: 220px;
  height: 1px;
  background: var(--faint);
  position: relative;
}

#splash-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  background: #fff;
  transition: width 0.12s linear;
}

#shell {
  height: 100%;
  display: grid;
  grid-template-columns: var(--rail) 1fr;
  grid-template-rows: 48px 1fr;
  grid-template-areas:
    "chrome chrome"
    "rail workspace";
  min-width: 0;
}

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

#shell.is-rail-min {
  grid-template-columns: var(--rail-min) 1fr;
}

#shell.is-catalog,
#shell.is-set,
#shell.is-test,
#shell.is-clip,
#shell.is-home {
  grid-template-columns: 1fr;
  grid-template-areas:
    "chrome"
    "workspace";
}

#shell.is-catalog.is-rail-min,
#shell.is-set.is-rail-min,
#shell.is-test.is-rail-min,
#shell.is-clip.is-rail-min,
#shell.is-home.is-rail-min {
  grid-template-columns: 1fr;
}

#shell.is-catalog .rail,
#shell.is-set .rail,
#shell.is-test .rail,
#shell.is-clip .rail,
#shell.is-home .rail {
  display: none;
}

.rail {
  grid-area: rail;
  height: 100%;
  min-width: 0;
  min-height: 0;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  background: #000;
  overflow: hidden;
  position: relative;
}

.rail-head {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 8px;
  border-bottom: 1px solid var(--line);
  flex: none;
  min-width: 0;
}

#rail-toggle {
  width: 24px;
  height: 24px;
  padding: 0;
  flex: none;
  display: grid;
  place-items: center;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--dim);
  cursor: pointer;
}

#rail-toggle svg {
  width: 14px;
  height: 14px;
  display: block;
}

#rail-toggle:hover {
  color: #fff;
  border-color: var(--line-2);
}

.rail-title {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--dim);
  overflow: hidden;
  white-space: nowrap;
}

.rail-count {
  margin-left: auto;
  font-family: var(--data);
  font-size: 10px;
  color: var(--faint);
}

.rail-clear {
  background: transparent;
  border: 0;
  padding: 0;
  font-size: 8px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  cursor: pointer;
}

.rail-clear:hover {
  color: #fff;
}

.rail-drop {
  padding: 12px 12px 14px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.rail-drop p {
  margin: 0;
  font-size: 11px;
  color: var(--dim);
  line-height: 1.45;
}

.rail-drop p + p {
  margin-top: 4px;
}

.rail-drop .drop-types {
  font-family: var(--data);
  font-size: 8px;
  letter-spacing: 0.02em;
  color: var(--faint);
}

.rail-drop label {
  color: #fff;
  text-decoration: underline;
  cursor: pointer;
}

.rail.is-drop-armed::after,
#app.is-drop-armed::after {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--line-2);
  pointer-events: none;
  z-index: 25;
}

.rail.is-over::after,
#app.is-over::after {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

#lib-files,
#lib-folder {
  display: none;
}

.rail-tree {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 6px 0 16px;
}

.rail-empty {
  margin: 18px 12px;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
  line-height: 1.5;
}

.rail-row {
  display: flex;
  align-items: stretch;
  min-width: 0;
}

.rail-folder,
.rail-file {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  margin: 0;
  padding: 5px 10px;
  border: 0;
  background: transparent;
  color: var(--dim);
  font: inherit;
  text-align: left;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
}

.rail-folder {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.rail-file {
  flex: 1;
  width: auto;
  min-width: 0;
  font-family: var(--data);
  font-size: 10px;
  text-overflow: ellipsis;
}

.rail-file:hover,
.rail-folder:hover,
.rail-row:hover .rail-file {
  color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

.rail-file.is-on {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.rail-remove {
  flex: none;
  width: 22px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--faint);
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
}

.rail-remove:hover {
  color: #fff;
}

.rail-caret {
  width: 10px;
  flex: none;
  font-size: 7px;
  color: var(--faint);
}

.rail-folder-name {
  overflow: hidden;
  text-overflow: ellipsis;
}

.rail-resizer {
  position: absolute;
  top: 0;
  right: 0;
  width: 7px;
  height: 100%;
  cursor: col-resize;
  z-index: 6;
}

.rail-resizer:hover,
body.is-rail-resize .rail-resizer {
  background: rgba(255, 255, 255, 0.22);
}

body.is-rail-resize {
  cursor: col-resize;
  user-select: none;
}

#shell.is-rail-min .rail-resizer {
  display: none;
}

#shell.is-rail-min .rail-title,
#shell.is-rail-min .rail-count,
#shell.is-rail-min .rail-clear,
#shell.is-rail-min .rail-drop,
#shell.is-rail-min .rail-tree {
  display: none;
}

#shell.is-rail-min .rail-head {
  flex-direction: column;
  justify-content: flex-start;
  height: 100%;
  padding: 10px 0 0;
  border-bottom: 0;
}

.workspace {
  grid-area: workspace;
  min-width: 0;
  min-height: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Keep the Waveform Laboratory focused on one manually selected song. */
#shell,
#shell.is-rail-min {
  grid-template-columns: 1fr;
  grid-template-areas:
    "chrome"
    "workspace";
}

.rail {
  display: none !important;
}

.chrome {
  grid-area: chrome;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  height: 48px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.chrome .brand {
  display: flex;
  align-items: center;
  align-self: stretch;
  gap: 12px;
  min-width: 0;
  height: 48px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid transparent;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.chrome .brand:hover,
.chrome .brand.is-on {
  border-bottom-color: #fff;
}

.chrome .brand-logo {
  height: 28px;
}

.chrome .brand-text h1 {
  font-size: 11px;
  letter-spacing: 0.4em;
}

.nav {
  display: flex;
  align-items: stretch;
  gap: 2px;
  min-width: 0;
  overflow-x: auto;
  height: 48px;
}

.nav-toggle {
  display: none;
  width: 34px;
  height: 30px;
  padding: 7px;
  background: transparent;
  border: 1px solid #444;
  color: #fff;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 1px;
  margin: 3px 0;
  background: currentColor;
}

.nav button {
  flex: none;
  height: 48px;
  padding: 0 12px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid transparent;
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
  cursor: pointer;
  white-space: nowrap;
}

.nav button:hover {
  color: #fff;
}

.nav button.is-on {
  color: #fff;
  border-bottom-color: #fff;
}

.nav button:disabled {
  color: #555;
  cursor: not-allowed;
}

.load-status {
  font-family: var(--data);
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  min-width: 0;
}

#pages {
  flex: 1;
  min-height: 0;
  min-width: 0;
  position: relative;
}

.catalog-host,
.set-host {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.catalog-host iframe,
.set-host iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}

.set-host > :not(iframe) {
  display: none !important;
}

#pages > [hidden],
#app[hidden] {
  display: none !important;
}

.home-page,
#home-page {
  height: 100%;
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 18px 56px;
  gap: 36px;
}

#home-page > * {
  flex-shrink: 0;
}

.home-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0;
}

.home-logo {
  width: min(22vh, 160px);
  height: auto;
  margin-bottom: 10px;
  filter: contrast(1.15);
}

.home-wordmark {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.62em;
  text-transform: uppercase;
  text-indent: 0.62em;
}

.home-lead {
  margin: 14px 0 0;
  max-width: 420px;
  font-size: 11px;
  line-height: 1.5;
  color: var(--dim);
}

.home-socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 18px;
  margin-top: 22px;
}

.home-socials a {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #fff;
  text-decoration: none;
}

.home-socials a:hover {
  text-decoration: underline;
}

.home-tools {
  width: min(1120px, 100%);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.home-tool {
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  align-content: start;
  gap: 8px;
  min-height: 0;
  padding: 0 0 16px;
  background: #000;
  border: 0;
  text-align: left;
  cursor: pointer;
}

.home-tool:hover {
  background: #0c0c0c;
}

.home-tool.is-unavailable {
  position: relative;
  color: inherit;
  cursor: not-allowed;
  opacity: 1;
}

.home-tool.is-unavailable::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.32);
  pointer-events: none;
}

.home-tool.is-unavailable .home-tool-shot,
.home-tool.is-unavailable .home-tool-k,
.home-tool.is-unavailable .home-tool-name,
.home-tool.is-unavailable .home-tool-copy {
  filter: grayscale(1);
  opacity: 0.5;
}

.home-tool-status {
  position: relative;
  z-index: 1;
  margin: 4px 14px 0;
  padding-top: 10px;
  border-top: 1px solid #303030;
  color: #8a8a8a;
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.home-tool-shot {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
  object-position: top center;
  background: #0a0a0a;
  pointer-events: none;
  border-bottom: 1px solid var(--line);
}

.home-tool-k {
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.16em;
  color: var(--dim);
  padding: 4px 14px 0;
}

.home-tool-name {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #fff;
  padding: 0 14px;
}

.home-tool-copy {
  font-size: 11px;
  line-height: 1.45;
  color: var(--dim);
  padding: 0 14px;
}

.home-donate {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  min-width: 260px;
  height: 48px;
  padding: 0 28px;
  background: #fff;
  color: #000;
  border: 1px solid #fff;
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.home-donate:hover {
  background: transparent;
  color: #fff;
}

.home-story {
  width: min(1120px, 100%);
  display: grid;
  gap: 28px 48px;
  padding: 36px 0 8px;
  border-top: 1px solid var(--line);
  align-items: start;
}

.home-efcnt {
  grid-template-columns: minmax(0, 0.55fr) minmax(320px, 1.45fr);
  align-items: start;
}

.home-story-copy {
  min-width: 0;
}

.home-story h3 {
  margin: 0 0 16px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.home-story p {
  margin: 0 0 12px;
  max-width: 52ch;
  font-size: 13px;
  line-height: 1.55;
  color: rgba(243, 243, 243, 0.78);
}

.home-story-lead {
  color: #fff;
}

.home-efcnt .home-story-copy p {
  margin: 0;
  max-width: 28ch;
  font-size: 11px;
  line-height: 1.5;
  letter-spacing: 0.04em;
}

.home-efcnt-media {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.home-yt {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #0a0a0a;
  overflow: hidden;
  color: #fff;
}

.home-yt iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.home-yt img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.home-yt-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 64px;
  height: 64px;
  margin: -32px 0 0 -32px;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  transition: transform 0.15s ease, background 0.15s ease;
}

.home-yt-play::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  margin: -8px 0 0 -5px;
  border-style: solid;
  border-width: 9px 0 9px 16px;
  border-color: transparent transparent transparent #fff;
}

.home-yt:hover .home-yt-play {
  transform: scale(1.06);
  background: rgba(0, 0, 0, 0.7);
}

.home-efcnt-icons {
  display: flex;
  align-items: center;
  gap: 16px;
}

.home-efcnt-icons a {
  color: #fff;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
}

.home-efcnt-icons svg {
  width: 22px;
  height: 22px;
  display: block;
}

.home-efcnt-icons a:hover {
  opacity: 0.55;
}

.home-credit {
  width: min(1120px, 100%);
  padding: 22px 0 8px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
}

.home-credit p {
  margin: 0;
}

.home-credit a {
  color: #fff;
  text-decoration: none;
}

.home-credit a:hover {
  text-decoration: underline;
}

.page-stub {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.stub-kicker {
  margin: 0;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--dim);
}

.stub-msg {
  margin: 0;
  font-family: var(--data);
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg);
}

#catalog {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.cat-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  padding: 16px 18px 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.cat-lead {
  margin: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #fff;
}

.cat-sub {
  margin: 8px 0 0;
  font-size: 11px;
  line-height: 1.45;
  color: var(--dim);
}

.cat-drop label,
.cat-actions label,
.cat-actions button {
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: none;
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 2px;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.cat-actions button {
  color: var(--dim);
  text-decoration: none;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 11px;
}

.cat-actions label {
  color: var(--dim);
  text-decoration: none;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cat-drop label:hover,
.cat-actions label:hover,
.cat-actions button:hover:not(:disabled) {
  color: #fff;
}

.cat-drop.is-over {
  outline: 1px solid #fff;
  outline-offset: 6px;
}

#cat-files,
#cat-folder,
#cat-csv {
  display: none;
}

.cat-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: none;
}

.cat-actions button:disabled {
  cursor: default;
  opacity: 0.35;
}

.cat-count {
  font-size: 11px;
  color: var(--dim);
  min-width: 1.5em;
  text-align: right;
}

.cat-status {
  margin: 0;
  padding: 8px 18px 10px;
  min-height: 22px;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
  flex: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 12px;
  row-gap: 6px;
  align-items: baseline;
}

#cat-status-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#cat-overall-pct {
  font-variant-numeric: tabular-nums;
  color: #fff;
}

.cat-overall-track {
  grid-column: 1 / -1;
  height: 1px;
  background: var(--faint);
}

.cat-overall-track i {
  display: block;
  height: 1px;
  width: 0%;
  background: #fff;
}

.cat-row-bar {
  display: block;
  height: 1px;
  margin-top: 5px;
  background: var(--faint);
}

.cat-row-bar i {
  display: block;
  height: 1px;
  width: 0%;
  background: #fff;
}

.cat-table tr.is-run .cat-file {
  color: #fff;
}

.cat-table-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 18px 24px;
}

.cat-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 11px;
}

.cat-table th,
.cat-table td {
  padding: 7px 10px 7px 0;
  text-align: left;
  white-space: nowrap;
  vertical-align: middle;
}

.cat-check {
  width: 22px;
  padding-right: 10px;
  cursor: default;
}

.cat-head .cat-check {
  background: #000;
  box-shadow: 0 1px 0 var(--line);
  padding-top: 10px;
  padding-bottom: 8px;
}

.cat-check input {
  appearance: none;
  width: 11px;
  height: 11px;
  margin: 0;
  border: 1px solid var(--line-2);
  background: transparent;
  display: block;
  cursor: pointer;
}

.cat-check input:checked {
  background: #fff;
  border-color: #fff;
}

.cat-check input:indeterminate {
  background: var(--dim);
  border-color: var(--dim);
}

.cat-table tr.is-pick td,
.cat-table tr.is-focus td {
  color: #fff;
}

.cat-table td {
  border-bottom: 1px solid var(--line);
}

.cat-head {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #000;
}

.cat-th {
  background: #000;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  cursor: pointer;
  user-select: none;
  padding-top: 10px;
  padding-bottom: 8px;
  box-shadow: 0 1px 0 var(--line);
}

.cat-th.is-on {
  color: #fff;
}

.cat-th.is-on::after {
  content: " ↑";
}

.cat-th.is-on.is-desc::after {
  content: " ↓";
}

.cat-file {
  max-width: 42vw;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #fff;
}

.cat-table td {
  font-family: var(--data);
  font-size: 11px;
  color: var(--dim);
}

.cat-table .cat-file {
  font-family: var(--ui);
  font-size: 11px;
}

.cat-st {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 9px;
}

.cat-events {
  font-variant-numeric: tabular-nums;
}

.cat-table tr.is-fail td {
  color: var(--faint);
}

.cat-table tr.is-queued td {
  color: var(--faint);
}

.cat-empty td {
  font-family: var(--ui);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
  padding: 28px 0;
  border-bottom: 0;
}

#set-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: auto;
}

.set-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  padding: 16px 18px 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.set-actions {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  flex: none;
}

#set-page > .set-actions {
  padding: 4px 18px 12px;
  border-bottom: 1px solid var(--line);
  align-items: stretch;
}

.set-name-field {
  display: grid;
  gap: 6px;
  align-content: end;
}

.set-eq {
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  flex: 1 1 280px;
  min-width: 240px;
  max-width: 560px;
  min-height: 102px;
  margin-left: 8px;
  border-left: 1px solid var(--line);
  border-right: 0;
}

.set-eq .eq-lane {
  padding: 3px 12px;
}

.set-eq .eq-solo,
.set-eq .eq-mute {
  height: 22px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line-2);
  color: var(--dim);
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.set-eq .eq-solo:hover,
.set-eq .eq-mute:hover {
  color: #fff;
}

.set-eq .eq-solo.is-on,
.set-eq .eq-solo.is-on:hover {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.set-eq .eq-mute.is-on,
.set-eq .eq-mute.is-on:hover {
  background: rgba(243, 243, 243, 0.12);
  color: #fff;
  border-color: rgba(243, 243, 243, 0.55);
}

.set-name-field .set-k {
  margin: 0;
}

#set-page > .set-actions .cat-count {
  margin-left: auto;
  padding-bottom: 2px;
  align-self: flex-end;
}

#set-page > .set-actions .set-name-field,
#set-page > .set-actions #set-build,
#set-page > .set-actions #set-export {
  align-self: flex-end;
  padding-bottom: 2px;
}

.set-actions button,
.set-actions label {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim);
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.set-actions button:hover:not(:disabled) {
  color: #fff;
}

.set-actions button:disabled {
  cursor: default;
  opacity: 0.35;
}

#set-build,
#set-export {
  color: #fff;
}

#set-name {
  width: 108px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: #fff;
  font-family: var(--data);
  font-size: 11px;
  padding: 2px 0;
  outline: none;
}

#set-name:focus {
  border-bottom-color: #fff;
}

.set-controls {
  padding: 14px 18px 8px;
  display: grid;
  gap: 12px;
  flex: none;
}

.set-field {
  min-width: 0;
}

.set-field-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.set-k {
  display: block;
  margin-bottom: 8px;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
}

.set-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.set-chip {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--dim);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 8px;
  cursor: pointer;
}

.set-chip span {
  font-family: var(--data);
  letter-spacing: 0;
  color: var(--faint);
  margin-left: 4px;
}

.set-chip:hover,
.set-chip.is-on {
  color: #fff;
  border-color: var(--line-2);
}

.set-chip.is-on {
  border-color: #fff;
}

.set-shape {
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
  gap: 5px;
  min-width: 76px;
  padding: 6px 8px;
}

.set-shape-mini {
  display: block;
  width: 100%;
  height: 18px;
}

.set-shape-edit {
  margin-top: 10px;
  height: 72px;
  border: 1px solid var(--line);
}

.set-shape-edit[hidden] {
  display: none;
}

.set-shape-svg {
  display: block;
  width: 100%;
  height: 72px;
  touch-action: none;
  cursor: ns-resize;
}

.set-shape-fill {
  fill: rgba(255, 255, 255, 0.12);
}

.set-shape-line {
  stroke: #fff;
  stroke-width: 1.4;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.set-shape-svg ellipse {
  fill: #fff;
  cursor: grab;
}

.set-shape-svg ellipse:active {
  cursor: grabbing;
}

.set-bpm-head {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
}

.set-bpm-head .set-k {
  margin: 0;
}

.set-range-reset {
  background: none;
  border: 0;
  padding: 0;
  color: var(--faint);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
}

.set-range-reset:hover {
  color: #fff;
}

.set-bpm-readout {
  justify-self: end;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
}

.set-bpm-plot {
  position: relative;
  min-height: 48px;
  user-select: none;
  touch-action: none;
  cursor: ew-resize;
}

.set-bpm-plot canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.set-bpm-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 12px;
  margin-left: -6px;
  cursor: ew-resize;
  z-index: 2;
}

.set-bpm-handle::after {
  content: "";
  position: absolute;
  top: 6px;
  bottom: 6px;
  left: 5px;
  width: 2px;
  background: #fff;
}

.set-length {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: var(--dim);
}

.set-length input,
.set-seed-pos {
  width: 48px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: #fff;
  font-family: var(--data);
  font-size: 11px;
  padding: 2px 0;
  outline: none;
}

.set-length input:focus,
.set-seed-pos:focus {
  border-bottom-color: #fff;
}

.set-dim {
  color: var(--faint);
}

.set-seed-wrap {
  position: relative;
  max-width: 720px;
}

#set-seed-search {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: #fff;
  font-size: 11px;
  padding: 4px 0;
  outline: none;
}

#set-seed-search:focus {
  border-bottom-color: #fff;
}

.set-hits {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 4;
  background: #000;
  border: 1px solid var(--line);
  max-height: 220px;
  overflow: auto;
}

.set-hit,
.set-hit-empty {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  width: 100%;
  margin: 0;
  padding: 8px 10px;
  border: 0;
  background: transparent;
  color: var(--dim);
  font: inherit;
  font-size: 11px;
  text-align: left;
  cursor: pointer;
}

.set-hit-name {
  min-width: 0;
  flex: 1;
  white-space: normal;
  overflow-wrap: break-word;
}

.set-hit-bpm {
  flex: none;
  font-family: var(--data);
  color: var(--faint);
  letter-spacing: 0;
}

.set-hit:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

.set-hit-empty {
  cursor: default;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 9px;
  color: var(--faint);
}

.set-seeds {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.set-seed {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  padding: 4px 8px;
}

.set-seed-name {
  font-size: 11px;
  color: #fff;
  max-width: 420px;
  line-height: 1.3;
}

.set-seed-bpm {
  font-family: var(--data);
  font-size: 11px;
  color: var(--dim);
  flex: none;
}

.set-seed-x {
  background: transparent;
  border: 0;
  color: var(--dim);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.set-seed-x:hover {
  color: #fff;
}

.set-status {
  margin: 0;
  padding: 6px 18px 10px;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
  flex: none;
}

.set-curve {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 36px;
  padding: 0 18px 8px;
  flex: none;
}

.set-curve-bar {
  flex: 1;
  min-width: 4px;
  height: 100%;
  display: flex;
  align-items: flex-end;
  background: rgba(255, 255, 255, 0.06);
}

.set-curve-bar i {
  display: block;
  width: 100%;
  background: #fff;
}

.set-list-wrap {
  flex: none;
  padding: 0 18px 8px;
}

.set-list-head,
.set-row {
  display: grid;
  grid-template-columns: 54px 28px minmax(96px, 0.68fr) 84px 40px minmax(96px, 1.4fr) 52px 64px 100px 42px;
  gap: 12px;
  align-items: center;
}

.set-list-head {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #000;
  padding: 8px 0;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  box-shadow: 0 1px 0 var(--line);
}

.set-row {
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  color: var(--dim);
}

.set-acts {
  display: flex;
  align-items: center;
  gap: 2px;
}

.set-act {
  display: grid;
  place-items: center;
  width: 16px;
  height: 16px;
  padding: 0;
  background: transparent;
  border: 0;
  color: var(--dim);
  cursor: pointer;
}

.set-act svg {
  display: block;
  width: 12px;
  height: 12px;
}

.set-act:hover,
.set-act:focus-visible {
  color: #fff;
}

.set-act-del:hover,
.set-act-del:focus-visible {
  color: #fff;
}

.set-play {
  justify-self: start;
  width: 40px;
  padding: 0;
  background: transparent;
  border: 0;
  color: var(--dim);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: left;
  cursor: pointer;
}

.set-play:hover,
.set-row.is-playing .set-play {
  color: #fff;
}

.set-row.is-selected {
  box-shadow: inset 2px 0 0 #fff;
}

.set-bar-wave {
  display: block;
  width: 84px;
  height: 28px;
  justify-self: start;
  cursor: pointer;
}

.set-wave {
  display: block;
  width: 100%;
  height: 28px;
  cursor: pointer;
}

.set-n,
.set-meta {
  font-family: var(--data);
}

.set-title {
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.set-genre {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.set-empty {
  margin: 28px 0;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}

.set-stats {
  margin: 0;
  padding: 8px 18px 16px;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
  flex: none;
}

.set-confirm {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.78);
}

.set-confirm[hidden] {
  display: none;
}

.set-confirm-box {
  width: min(440px, calc(100vw - 48px));
  padding: 22px 24px 18px;
  border: 1px solid #fff;
  background: #000;
}

.set-confirm-k {
  margin: 0 0 10px;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
}

.set-confirm-copy {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.4;
  color: #fff;
}

.set-confirm-name {
  margin: 0;
  color: #fff;
  font-size: 12px;
}

.set-confirm-path {
  margin: 6px 0 18px;
  font-family: var(--data);
  font-size: 10px;
  color: var(--dim);
  word-break: break-all;
}

.set-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.set-confirm-actions button {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--dim);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 7px 12px;
  cursor: pointer;
}

.set-confirm-actions button:hover {
  color: #fff;
  border-color: #fff;
}

.set-confirm-actions .is-danger {
  color: #fff;
  border-color: #fff;
}

#test-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: auto;
}

.tester-sets {
  display: flex;
  align-items: baseline;
  gap: 28px;
  padding-top: 8px;
  padding-bottom: 4px;
}

.tester-set-field {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex: 1;
  min-width: 0;
  max-width: 560px;
}

.tester-set-field .set-k,
.tester-bpm-field .set-k {
  margin-bottom: 0;
}

.tester-bpm-field {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex: none;
}

#test-sets {
  flex: 1;
  min-width: 0;
  appearance: none;
  color-scheme: dark;
  background-color: transparent;
  background-image: linear-gradient(45deg, transparent 50%, #fff 50%),
    linear-gradient(135deg, #fff 50%, transparent 50%);
  background-position: right 10px center, right 5px center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  color: #fff;
  font-family: var(--ui);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 22px 4px 0;
  outline: none;
  cursor: pointer;
}

#test-sets:focus {
  border-bottom-color: #fff;
}

#test-sets:disabled {
  color: var(--dim);
  cursor: default;
}

#test-sets option {
  background: #000;
  color: #fff;
}

.tester-stage {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.tester-stage[hidden] {
  display: none;
}

.tester-actions {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 0;
  padding: 0;
  border-bottom: 1px solid var(--line);
}

.tester-transport {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  padding: 0 18px;
}

#test-play {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--line-2);
  color: #fff;
  letter-spacing: 0;
  display: grid;
  place-items: center;
  flex: none;
}

#test-play svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
  display: block;
}

#test-play .is-pause {
  display: none;
}

#test-play.is-on .is-play {
  display: none;
}

#test-play.is-on .is-pause {
  display: block;
}

#test-play:hover,
#test-play.is-on {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.tester-clock {
  font-family: var(--data);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--dim);
  min-width: 108px;
}

.tester-loop {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  padding: 8px 18px;
}

.tester-loop .set-k {
  margin-bottom: 0;
}

.tester-loop-beats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tester-loop-btn {
  min-width: 28px;
  height: 22px;
  padding: 0 8px;
  background: transparent;
  border: 1px solid var(--line-2);
  color: var(--dim);
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.tester-loop-btn:hover {
  color: #fff;
}

.tester-loop-btn.is-on,
.tester-loop-btn.is-on:hover {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.tester-loop .hint {
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
}

.tester-eq {
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  width: var(--lab-side);
  flex: none;
  min-height: 168px;
  border-right: 0;
  border-left: 1px solid var(--line);
  min-width: 0;
}

.tester-eq .eq-lane {
  padding-right: 18px;
}

.tester-eq .eq-solo,
.tester-eq .eq-mute {
  color: var(--dim);
}

.tester-eq .eq-solo:hover,
.tester-eq .eq-mute:hover {
  color: #fff;
}

.tester-eq .eq-solo.is-on,
.tester-eq .eq-solo.is-on:hover {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.tester-eq .eq-mute.is-on,
.tester-eq .eq-mute.is-on:hover {
  background: rgba(243, 243, 243, 0.12);
  color: #fff;
  border-color: rgba(243, 243, 243, 0.55);
}

.tester-mix {
  flex: none;
  border-bottom: 1px solid var(--line);
}

.tester-mix-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 6px 18px 4px;
}

.tester-mix-head span:first-child {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.tester-mix-row {
  display: grid;
  grid-template-columns: 188px 1fr;
  height: 64px;
  min-height: 64px;
  border-top: 1px solid var(--line);
}

.tester-mix-row.tester-mix-in {
  grid-template-rows: 64px 16px;
  height: 80px;
  min-height: 80px;
}

.tester-mix-name {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 6px 10px;
  border-right: 1px solid var(--line);
  min-width: 0;
  overflow: hidden;
}

.tester-mix-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  color: #fff;
  min-width: 0;
}

.tester-mix-deck {
  display: grid;
  grid-template-columns: 34px 34px minmax(0, 1fr) 22px;
  column-gap: 4px;
  align-items: center;
}

.tester-mix-deck .eq-solo,
.tester-mix-deck .eq-mute {
  height: 18px;
  font-size: 7px;
}

.tester-mix-name.is-off {
  opacity: 0.38;
}

.tester-mix-name.is-solo {
  box-shadow: inset 2px 0 0 #fff;
}

.tester-mix-row:has(.tester-mix-name.is-off) canvas {
  opacity: 0.38;
}

.tester-mix-in .tester-mix-name {
  grid-row: 1 / 3;
}

.tester-mix-row canvas {
  display: block;
  width: 100%;
  height: 64px;
  min-height: 0;
  cursor: grab;
  touch-action: none;
}

.tester-mix-row canvas.is-drag {
  cursor: grabbing;
}

.tester-mix-trim {
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px 0 6px;
  border-top: 1px solid var(--line);
  min-width: 0;
}

.tester-mix-trim input[type="range"] {
  flex: 1;
  min-width: 0;
  height: 11px;
  margin: 0;
  padding: 0;
  accent-color: #fff;
  background: transparent;
}

.tester-mix-trim span {
  flex: none;
  width: 36px;
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--dim);
  text-align: right;
}

.tester-overview {
  height: 72px;
  flex: none;
  border-bottom: 1px solid var(--line);
}

.tester-overview canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: pointer;
  touch-action: none;
}

.tester-board {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.tester-ruler {
  display: grid;
  grid-template-columns: 188px 1fr;
  height: 22px;
  flex: none;
  border-bottom: 1px solid var(--line);
}

.tester-ruler-gap {
  border-right: 1px solid var(--line);
}

.tester-ruler canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}

.tester-gantt {
  flex: 1;
  min-height: 0;
  max-height: calc(15 * 36px);
  overflow-x: hidden;
  overflow-y: auto;
  user-select: none;
}

.tester-hscroll {
  flex: none;
  height: 12px;
  margin-left: 188px;
  overflow-x: scroll;
  overflow-y: hidden;
}

.tester-mix-hscroll {
  border-top: 1px solid var(--line);
}

.tester-hscroll::-webkit-scrollbar {
  height: 8px;
}

.tester-hscroll::-webkit-scrollbar-track {
  background: rgba(243, 243, 243, 0.06);
}

.tester-hscroll::-webkit-scrollbar-thumb {
  background: rgba(243, 243, 243, 0.32);
}

.tester-spacer {
  height: 1px;
}

.tester-row {
  display: grid;
  grid-template-columns: 188px 1fr;
  height: 36px;
  min-height: 36px;
  max-height: 36px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.tester-name {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  border-right: 1px solid var(--line);
  min-width: 0;
}

.tester-num {
  flex: none;
  font-family: var(--data);
  font-size: 10px;
  color: var(--faint);
  width: 18px;
}

.tester-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: #fff;
}

.tester-bpm {
  flex: none;
  font-family: var(--data);
  font-size: 10px;
  color: var(--dim);
}

.tester-row canvas {
  display: block;
  width: 100%;
  height: 28px;
  min-height: 0;
  max-height: 28px;
  align-self: center;
  cursor: grab;
  touch-action: none;
}

.tester-row canvas.is-drag {
  cursor: ew-resize;
}

#clip-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

#clip-page.is-over {
  outline: 1px solid #fff;
  outline-offset: -8px;
}

.clip-drop {
  padding: 16px 18px 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.clip-drop.is-loaded .cat-lead {
  display: none;
}

.clip-drop.is-loaded {
  padding: 10px 18px;
}

.clip-drop label {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

#clip-file {
  display: none;
}

.clip-stage {
  position: relative;
  display: grid;
  grid-template-columns: minmax(220px, 340px) minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: end;
  gap: 8px 16px;
  padding: 14px 18px 8px;
  flex: none;
  min-height: 0;
}

.clip-stage[hidden] {
  display: none;
}

#clip-load {
  position: absolute;
  inset: 0;
  z-index: 4;
  grid-column: 1 / -1;
  grid-row: 1 / -1;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.72);
}

#clip-load[hidden] {
  display: none !important;
}

.clip-stage.is-export #clip-video,
.clip-stage.is-export #clip-wave,
.clip-stage.is-export .clip-prio {
  filter: grayscale(1);
  opacity: 0.32;
  pointer-events: none;
}

.clip-stage.is-export #clip-load {
  background: rgba(0, 0, 0, 0.22);
}

.lab-load-count {
  margin: -8px 0 14px;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
}

#clip-video {
  grid-column: 1;
  grid-row: 2;
  width: 100%;
  height: 180px;
  object-fit: contain;
  background: #000;
  border: 1px solid var(--line);
}

.clip-prio {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 28px;
}

.clip-prio-k {
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
}

.clip-prio .set-length {
  gap: 8px;
}

#clip-wave {
  grid-column: 2;
  grid-row: 2;
  width: 100%;
  height: 180px;
  display: block;
  cursor: pointer;
  border: 1px solid var(--line);
}

.clip-list-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 18px 8px;
}

.clip-list-head,
.clip-row {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 64px 56px;
  gap: 12px;
  align-items: baseline;
}

.clip-list-head {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #000;
  padding: 8px 0;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  box-shadow: 0 1px 0 var(--line);
}

.clip-row {
  width: 100%;
  margin: 0;
  padding: 8px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--dim);
  font: inherit;
  font-size: 11px;
  text-align: left;
  cursor: pointer;
}

.clip-row:hover,
.clip-row.is-on {
  color: #fff;
}

.clip-range {
  font-family: var(--data);
}

#app {
  height: 100%;
  position: relative;
  display: grid;
  grid-template-columns: var(--lab-side) 1fr;
  grid-template-rows: auto auto 1fr auto auto 28px;
  grid-template-areas:
    "bar bar"
    "drop top"
    "side lab"
    "eq eq"
    "live live"
    "foot foot";
}

.lab-bar {
  grid-area: bar;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  padding: 16px 18px 18px;
  border-bottom: 1px solid var(--line);
}

.lab-bar-lead {
  margin: 0 0 7px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.lab-bar-sub {
  margin: 0;
  color: var(--dim);
  font-size: 11px;
  line-height: 1.4;
}

.lab-empty-logo,
.lab-empty-k,
.lab-empty-title,
.lab-empty-copy,
.lab-empty-choose {
  display: none;
}

#app:not(.has-track) {
  grid-template-columns: 1fr;
  grid-template-rows: auto minmax(0, 1fr);
  grid-template-areas:
    "bar"
    "drop";
}

#app:not(.has-track) > :not(.lab-bar):not(#drop):not(#lab-load):not(#lab-alert) {
  display: none !important;
}

#app:not(.has-track) #drop {
  display: flex;
  min-height: min(620px, calc(100vh - 154px));
  margin: 18px;
  padding: 48px 24px;
  border: 1px solid var(--line-2);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  background: #000;
}

#app:not(.has-track) #drop.is-over {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.035);
}

#app:not(.has-track) .lab-empty-logo {
  display: block;
  width: 104px;
  height: 104px;
  object-fit: contain;
  margin-bottom: 26px;
}

#app:not(.has-track) .lab-empty-k {
  display: block;
  margin: 0 0 10px;
  color: var(--dim);
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

#app:not(.has-track) .drop .lab-empty-title {
  display: block;
  margin: 0 0 12px;
  color: #fff;
  font-size: clamp(22px, 3vw, 42px);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#app:not(.has-track) .drop .lab-empty-copy {
  display: block;
  max-width: 570px;
  margin: 0 0 28px;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.6;
}

#app:not(.has-track) .lab-empty-choose {
  display: block;
  min-width: 250px;
  padding: 13px 20px;
  border: 1px solid #fff;
  color: #000;
  background: #fff;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-decoration: none;
  text-transform: uppercase;
}

#app:not(.has-track) .lab-empty-choose:hover {
  color: #fff;
  background: #000;
}

#app:not(.has-track) .lab-compact-copy {
  display: none;
}

#app:not(.has-track) .drop p.drop-types {
  grid-column: auto;
  grid-row: auto;
  margin-top: 22px;
  text-align: center;
}

.top {
  grid-area: top;
  display: grid;
  grid-template-columns: minmax(360px, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
}

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

.brand-logo {
  height: 48px;
  width: auto;
}

.brand-text h1 {
  margin: 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.48em;
  text-transform: uppercase;
  text-indent: 0.12em;
}

.brand-text p {
  margin: 3px 0 0;
  font-size: 9px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--dim);
}

.transport {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

#btn-play {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 82px;
  min-width: 82px;
  height: 38px;
  padding: 0 14px;
  background: transparent;
  border: 1px solid var(--line-2);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 10px;
  cursor: pointer;
  touch-action: manipulation;
}

#btn-play > span {
  pointer-events: none;
}

.play-hint {
  color: #777;
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

#btn-play:hover,
#btn-play.is-on {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.clock {
  font-family: var(--data);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.clock-div {
  color: var(--dim);
  margin: 0 6px;
}

#seek {
  flex: 1;
  min-width: 80px;
  appearance: none;
  height: 1px;
  background: var(--line-2);
  outline: none;
}

#seek::-webkit-slider-thumb {
  appearance: none;
  width: 9px;
  height: 9px;
  background: #fff;
  border-radius: 0;
  cursor: pointer;
}

.bpm-box {
  display: flex;
  align-items: center;
  gap: 14px;
}

.bpm-readout {
  text-align: right;
}

.grid-edit {
  display: grid;
  grid-template-columns: repeat(4, 34px);
  grid-template-rows: 28px 28px;
  gap: 4px;
  flex: none;
}

.grid-edit button {
  height: 28px;
  min-width: 0;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--dim);
  font-family: var(--data);
  font-size: 11px;
  letter-spacing: 0.08em;
  cursor: pointer;
}

#grid-reset {
  grid-column: span 2;
}

.grid-edit button:hover {
  color: #fff;
  border-color: var(--line-2);
}

.top-right {
  display: flex;
  align-items: center;
  gap: 20px;
  justify-self: end;
}

.bpm-box .k {
  display: block;
  font-size: 9px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--dim);
}

.bpm-box .v {
  display: block;
  font-family: var(--data);
  font-size: 22px;
  line-height: 1.1;
  margin: 2px 0;
}

.side {
  grid-area: side;
  border-right: 1px solid var(--line);
  overflow: auto;
  padding: 8px 0 24px;
  position: relative;
}

.side-resizer {
  position: absolute;
  top: 0;
  right: 0;
  width: 7px;
  height: 100%;
  cursor: col-resize;
  z-index: 6;
}

.side-resizer:hover,
body.is-side-resize .side-resizer {
  background: rgba(255, 255, 255, 0.22);
}

body.is-side-resize {
  cursor: col-resize;
  user-select: none;
}

.panel {
  padding: 14px 18px 16px;
  border-bottom: 1px solid var(--line);
}

.panel h2 {
  margin: 0 0 10px;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--dim);
}

.panel-fold {
  padding-top: 12px;
  padding-bottom: 12px;
}

.panel-fold summary {
  cursor: pointer;
  list-style: none;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--dim);
}

.panel-fold summary::-webkit-details-marker {
  display: none;
}

.panel-fold summary::after {
  content: "+";
  float: right;
  font-family: var(--data);
  color: var(--faint);
}

.panel-fold[open] summary {
  margin-bottom: 10px;
}

.panel-fold[open] summary::after {
  content: "–";
}

.panel dl {
  margin: 0;
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 5px 8px;
}

.panel dt {
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  padding-top: 2px;
}

.panel dd {
  margin: 0;
  font-family: var(--data);
  font-size: 11px;
  line-height: 1.35;
  word-break: break-word;
}

.event-list {
  display: flex;
  flex-direction: column;
  max-height: 240px;
  overflow: auto;
  margin: -4px -8px 0;
}

.event-empty {
  margin: 0;
  padding: 4px 8px;
  font-size: 10px;
  color: var(--dim);
}

.event-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  grid-template-rows: auto auto;
  gap: 0 10px;
  width: 100%;
  padding: 6px 8px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.event-row:hover,
.event-row.is-on {
  background: rgba(255, 255, 255, 0.06);
}

.event-type {
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.event-time,
.event-conf {
  font-family: var(--data);
  font-size: 10px;
  color: var(--muted, #a3a3a3);
}

.event-conf {
  color: var(--dim);
}

.event-detail {
  grid-column: 1 / -1;
  font-family: var(--data);
  font-size: 9px;
  color: var(--dim);
  letter-spacing: 0.02em;
}

.track-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
}

.track-name {
  margin: 0;
  font-family: var(--data);
  font-size: 11px;
  line-height: 1.35;
  word-break: break-word;
}

.track-artist {
  margin: 4px 0 0;
  font-size: 11px;
  line-height: 1.3;
  color: #fff;
  word-break: break-word;
}

.track-extra {
  margin: 3px 0 0;
  font-family: var(--data);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
  word-break: break-word;
}

#cover-wrap {
  flex: none;
}

#cover-wrap[hidden] {
  display: none !important;
}

#cover-wrap img {
  width: 72px;
  height: 72px;
  display: block;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  filter: grayscale(1) contrast(1.05);
}

#cover-wrap.is-brand img {
  filter: none;
}

.track-meta {
  min-width: 0;
  flex: 1;
}

.track-meta h2 {
  margin: 0 0 6px;
}

.panel.drop {
  grid-area: drop;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 118px;
  column-gap: 10px;
  row-gap: 2px;
  padding: 8px 14px;
  align-content: center;
  align-items: start;
  min-width: 0;
  border-right: 1px solid var(--line);
}

.drop h2 {
  margin: 0;
}

.drop p {
  margin: 0;
  font-size: 11px;
  color: var(--dim);
  line-height: 1.35;
}

.drop p.drop-types {
  grid-column: 2;
  grid-row: 1 / span 2;
  margin: 0;
  text-align: right;
  line-height: 1.3;
}

.drop label {
  color: #fff;
  text-decoration: underline;
  cursor: pointer;
}

.drop.is-over {
  background: rgba(255, 255, 255, 0.08);
}

#lab-load {
  position: absolute;
  inset: 0;
  z-index: 28;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.72);
}

#lab-load[hidden] {
  display: none !important;
}

.lab-load-card {
  width: min(280px, calc(100% - 40px));
  padding: 22px 24px 20px;
  border: 1px solid #fff;
  background: #000;
  text-align: center;
}

.lab-load-kicker {
  margin: 0;
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.lab-load-msg {
  margin: 12px 0 16px;
  font-family: var(--data);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
}

.lab-load-bar {
  height: 1px;
  background: var(--faint);
}

.lab-load-bar i {
  display: block;
  height: 1px;
  width: 0%;
  background: #fff;
}

#app.is-loading > *:not(#lab-load) {
  filter: grayscale(1);
  opacity: 0.28;
  pointer-events: none;
}

#lab-alert {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.62);
}

#lab-alert[hidden] {
  display: none !important;
}

.lab-alert-card {
  width: min(360px, calc(100% - 40px));
  padding: 22px 24px 18px;
  border: 1px solid #fff;
  background: #000;
  text-align: center;
}

.lab-alert-kicker {
  margin: 0;
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.lab-alert-msg {
  margin: 12px 0 8px;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--dim);
  line-height: 1.5;
}

.lab-alert-hint {
  margin: 0 0 18px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--dim);
  line-height: 1.45;
}

#lab-alert-ok {
  height: 28px;
  padding: 0 16px;
  background: transparent;
  border: 1px solid var(--line-2);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  cursor: pointer;
}

#lab-alert-ok:hover {
  background: #fff;
  color: #000;
  border-color: #fff;
}

#file-input {
  display: none;
}

#drop-veil {
  display: none;
  position: fixed;
  inset: 10px;
  z-index: 40;
  pointer-events: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 8px;
  background: rgba(0, 0, 0, 0.78);
  border: 1px solid #fff;
}

#drop-veil p {
  margin: 0;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-size: 11px;
}

#drop-veil p + p {
  letter-spacing: 0.14em;
  font-size: 9px;
  font-family: var(--data);
  color: var(--dim);
}

body.is-drop #drop-veil {
  display: none;
}

body.is-drop.is-splash #drop-veil {
  display: flex;
}

.feedback-trigger {
  position: static;
  justify-self: end;
  min-height: 30px;
  padding: 0 12px;
  background: #fff;
  border: 1px solid #fff;
  color: #000;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.feedback-trigger:hover,
.feedback-trigger:focus-visible {
  background: #d9d9d9;
  border-color: #d9d9d9;
  color: #000;
}

.feedback-dialog {
  width: min(430px, calc(100vw - 28px));
  max-height: calc(100vh - 28px);
  margin: auto;
  padding: 0;
  overflow: auto;
  background: #080808;
  border: 1px solid #666;
  color: #f3f3f3;
}

.feedback-dialog::backdrop {
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(3px);
}

.feedback-dialog form {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.feedback-head,
.feedback-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.feedback-kicker,
.feedback-intro {
  margin: 0;
  color: #777;
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.feedback-head h2 {
  margin: 5px 0 0;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.feedback-close {
  width: 34px;
  height: 34px;
  padding: 0;
  background: transparent;
  border: 1px solid #333;
  color: #aaa;
  font-size: 19px;
  cursor: pointer;
}

.feedback-field {
  display: grid;
  gap: 7px;
  color: #bbb;
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.feedback-field i {
  color: #666;
  font-style: normal;
}

.feedback-field input,
.feedback-field textarea {
  width: 100%;
  padding: 10px;
  resize: vertical;
  background: #000;
  border: 1px solid #333;
  border-radius: 0;
  color: #fff;
  font: 12px/1.45 var(--sans);
}

.feedback-field input:focus,
.feedback-field textarea:focus {
  border-color: #aaa;
  outline: none;
}

.feedback-honey {
  position: absolute;
  left: -10000px;
}

.feedback-status {
  color: #999;
  font-size: 9px;
  line-height: 1.35;
}

.feedback-send {
  flex: none;
  min-height: 36px;
  padding: 0 15px;
  background: #fff;
  border: 1px solid #fff;
  color: #000;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.feedback-send:disabled {
  opacity: 0.5;
  cursor: wait;
}

@media (max-width: 720px) {
  .play-hint {
    display: none;
  }

  .feedback-trigger {
    min-height: 28px;
    padding: 0 9px;
  }
}

#band-balance {
  margin-top: 0;
  display: grid;
  gap: 5px;
}

.band-row {
  display: grid;
  grid-template-columns: 72px 1fr 48px;
  gap: 8px;
  align-items: center;
  font-size: 9px;
  cursor: pointer;
}

.band-row.is-muted {
  opacity: 0.28;
}

.band-row.is-solo span:first-child {
  color: #fff;
}

.band-row span:first-child {
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim);
}

.band-row span:last-child {
  font-family: var(--data);
  text-align: right;
}

.band-track {
  height: 2px;
  background: var(--faint);
}

.band-track i {
  display: block;
  height: 100%;
  width: 0;
}

.lab {
  grid-area: lab;
  overflow: hidden;
  display: grid;
  grid-template-rows:
    auto minmax(48px, 9.2fr)
    auto minmax(40px, 8.3fr)
    auto minmax(36px, 7.2fr)
    auto minmax(16px, 2.4fr)
    auto minmax(20px, 3.6fr)
    auto minmax(40px, 9.5fr);
  min-width: 0;
  min-height: 0;
}

.lab > .viz {
  display: grid;
  grid-template-rows: subgrid;
  grid-row: span 2;
  min-height: 0;
}

.viz,
.live-col {
  border-bottom: 1px solid var(--line);
}

.viz-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 8px 14px 0;
}

.viz-head h2 {
  margin: 0;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.hint {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim);
}

.lab > .viz canvas {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: block;
}

#c-roll {
  touch-action: none;
  cursor: grab;
}

#c-roll.is-grabbing {
  cursor: grabbing;
}

#c-struct,
#c-mix {
  cursor: pointer;
}

.viz-struct .viz-head,
.viz-mix .viz-head {
  padding-top: 6px;
  padding-bottom: 2px;
}

.viz-eq {
  grid-area: eq;
  border-top: 1px solid var(--line);
  min-width: 0;
}

.viz-eq .viz-head {
  display: grid;
  grid-template-columns: var(--lab-side) 1fr;
  padding: 8px 0 0;
}

.viz-eq .viz-head h2 {
  padding-left: 14px;
}

.viz-eq .viz-head .hint {
  padding-right: 14px;
  text-align: right;
}

.eq-deck {
  display: grid;
  grid-template-columns: var(--lab-side) 1fr;
  height: 186px;
  min-width: 0;
}

.eq-ctrls {
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  border-right: 1px solid var(--line);
}

.eq-lane {
  display: grid;
  grid-template-columns: 40px 40px 1fr 28px;
  grid-template-rows: auto auto;
  column-gap: 6px;
  row-gap: 4px;
  align-content: center;
  padding: 0 10px;
  border-bottom: 1px solid var(--line);
}

.eq-lane:last-child {
  border-bottom: 0;
}

.eq-lane.is-off {
  opacity: 0.38;
}

.eq-lane.is-solo {
  box-shadow: inset 2px 0 0 #fff;
}

.eq-name {
  grid-column: 1 / 3;
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.eq-hz {
  grid-column: 3 / -1;
  font-family: var(--data);
  font-size: 9px;
  color: var(--dim);
  text-align: right;
}

.eq-solo,
.eq-mute {
  grid-row: 2;
  height: 22px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--line-2);
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.eq-solo {
  grid-column: 1;
}

.eq-mute {
  grid-column: 2;
}

.eq-solo.is-on {
  background: #fff;
  color: #000;
  border-color: #fff;
}

.eq-mute.is-on {
  background: rgba(243, 243, 243, 0.12);
  color: #fff;
  border-color: rgba(243, 243, 243, 0.55);
}

.eq-fader {
  grid-column: 3;
  grid-row: 2;
  appearance: none;
  width: 100%;
  height: 1px;
  background: var(--line-2);
  outline: none;
  cursor: pointer;
}

.eq-fader::-webkit-slider-thumb {
  appearance: none;
  width: 8px;
  height: 8px;
  background: #fff;
  border: 0;
  border-radius: 0;
  cursor: pointer;
}

.eq-fader::-moz-range-thumb {
  width: 8px;
  height: 8px;
  background: #fff;
  border: 0;
  border-radius: 0;
  cursor: pointer;
}

.eq-val {
  grid-column: 4;
  grid-row: 2;
  font-family: var(--data);
  font-size: 10px;
  text-align: right;
}

.lab .viz-context {
  transition: opacity 0.12s ease;
}

.lab.is-isolating .viz-context {
  opacity: 0.28;
}

#c-bands {
  width: 100%;
  height: 186px;
  display: block;
  min-width: 0;
}

.live {
  grid-area: live;
  display: grid;
  grid-template-columns: 1.2fr 1.4fr 1fr;
  min-width: 0;
  border-top: 1px solid var(--line);
}

.live-col {
  min-width: 0;
  display: flex;
  flex-direction: column;
  border-bottom: 0;
  border-right: 1px solid var(--line);
}

.live-col:last-child {
  border-right: 0;
}

.live canvas {
  width: 100%;
  height: 48px;
  min-height: 0;
  flex: none;
  display: block;
}

.foot {
  grid-area: foot;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 18px;
  border-top: 1px solid var(--line);
  font-size: 9px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--dim);
}

canvas {
  cursor: crosshair;
}

#c-scope,
#c-fft,
#c-meters {
  cursor: default;
}

@media (max-width: 980px) {
  body {
    overflow: auto;
  }

  #shell,
  #shell.is-rail-min {
    height: auto;
    min-height: 100%;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto 1fr;
    grid-template-areas:
      "chrome"
      "rail"
      "workspace";
  }

  #shell.is-catalog,
  #shell.is-catalog.is-rail-min,
  #shell.is-set,
  #shell.is-set.is-rail-min,
  #shell.is-test,
  #shell.is-test.is-rail-min,
  #shell.is-clip,
  #shell.is-clip.is-rail-min,
  #shell.is-home,
  #shell.is-home.is-rail-min {
    grid-template-rows: auto 1fr;
    grid-template-areas:
      "chrome"
      "workspace";
  }

  .rail {
    height: 220px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  #shell.is-rail-min .rail {
    height: 48px;
  }

  #shell.is-rail-min .rail-head {
    flex-direction: row;
    align-items: center;
    height: 48px;
    padding: 0 8px;
    border-bottom: 1px solid var(--line);
  }

  .chrome {
    position: relative;
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    height: 48px;
    padding: 0 10px;
    gap: 8px;
  }

  .nav {
    position: absolute;
    top: 47px;
    right: 10px;
    z-index: 30;
    display: none;
    width: min(310px, calc(100vw - 20px));
    height: auto;
    overflow: hidden;
    flex-direction: column;
    gap: 0;
    background: #050505;
    border: 1px solid #444;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.72);
  }

  .nav.is-open {
    display: flex;
  }

  .nav button {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border-bottom: 1px solid #252525;
    text-align: left;
  }

  .nav button:last-child {
    border-bottom: 0;
  }

  .nav-toggle {
    display: block;
    grid-column: 3;
    justify-self: end;
  }

  .load-status {
    display: none;
  }

  .feedback-trigger {
    grid-column: 4;
  }

  .workspace {
    height: auto;
  }

  #pages {
    height: auto;
  }

  .home-tools {
    grid-template-columns: 1fr;
  }

  .home-tool {
    grid-template-columns: 112px 34px minmax(0, 1fr);
    grid-template-rows: auto auto 1fr auto;
    gap: 5px 0;
    min-height: 112px;
    padding: 0 14px 0 0;
  }

  .home-tool-shot {
    grid-column: 1;
    grid-row: 1 / -1;
    width: 112px;
    height: 100%;
    min-height: 112px;
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }

  .home-tool-k {
    grid-column: 2;
    grid-row: 1 / span 3;
    padding: 16px 8px 0 12px;
  }

  .home-tool-name {
    grid-column: 3;
    padding: 16px 0 0;
  }

  .home-tool-copy {
    grid-column: 3;
    padding: 0;
  }

  .home-tool-status {
    grid-column: 3;
    margin: 3px 0 12px;
  }

  .home-efcnt {
    grid-template-columns: 1fr;
  }

  .page-stub {
    min-height: 40vh;
  }

  .cat-bar {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 12px 14px;
  }

  .cat-file {
    max-width: 56vw;
  }

  #app {
    height: auto;
    min-height: 100%;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto auto auto auto auto auto;
    grid-template-areas:
      "bar"
      "drop"
      "top"
      "lab"
      "side"
      "eq"
      "live"
      "foot";
  }

  .top {
    grid-template-columns: 1fr;
    padding: 10px 14px;
    gap: 10px;
  }

  .lab {
    display: flex;
    flex-direction: column;
    overflow: visible;
    height: auto;
  }

  .lab > .viz {
    display: flex;
    flex-direction: column;
    grid-row: auto;
  }

  .lab > .viz canvas {
    height: auto;
    flex: none;
  }

  #c-roll {
    height: 92px;
  }

  #c-overview {
    height: 83px;
  }

  #c-rms {
    height: 72px;
  }

  #c-struct {
    height: 24px;
  }

  #c-mix {
    height: 36px;
  }

  #c-spec {
    height: 95px;
  }

  .live {
    grid-template-columns: 1fr;
  }

  .live-col {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    min-height: 0;
  }
}

@media (max-width: 560px) {
  .chrome .brand-text {
    display: none;
  }

  .home-tool {
    grid-template-columns: 34px minmax(0, 1fr);
    min-height: 92px;
    padding-left: 0;
  }

  .home-tool-shot {
    display: none;
  }

  .home-tool-k {
    grid-column: 1;
    padding-left: 12px;
  }

  .home-tool-name,
  .home-tool-copy,
  .home-tool-status {
    grid-column: 2;
  }
}
