:root {
  --bg: #08080a;
  --panel: #0e0e11;
  --panel-2: #131317;
  --panel-3: #17171c;
  --line: #232329;
  --line-soft: #1b1b20;
  --text: #ececf1;
  --muted: #83838e;
  --dim: #5a5a64;
  --orange: #ff5c1a;
  --orange-deep: #c8490f;
  --green: #3ddc84;
  --red: #ff3b3b;
  --blue: #4c8dff;
  --font: "Inter", "Helvetica Neue", Arial, system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --radius: 4px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 13px;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
[hidden] { display: none !important; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h2, h3, p, dl, dd, dt { margin: 0; }
b { font-weight: 600; }

.app {
  display: grid;
  grid-template-rows: 58px 46px minmax(0, 1fr) 124px;
  height: 100vh;
  min-height: 560px;
}

/* ------------------------------------------------------------------ topbar */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line-soft);
  background: #0a0a0c;
}
.brand { display: flex; align-items: center; gap: 11px; }
.mark {
  width: 22px; height: 22px;
  background: var(--orange);
  transform: rotate(45deg);
  border-radius: 3px;
  box-shadow: 0 0 18px rgba(255, 92, 26, 0.45);
}
.brand-name {
  font-weight: 800;
  letter-spacing: 0.14em;
  font-size: 15px;
}
.brand-name em {
  font-style: normal;
  font-weight: 400;
  color: var(--muted);
  margin-left: 4px;
  letter-spacing: 0.2em;
}
.topbar-right { display: flex; align-items: center; gap: 10px; }
.model-status {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.09em;
  color: var(--muted);
  margin-right: 8px;
  white-space: nowrap;
}
.model-status i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}
.chip-btn {
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: #d6d6de;
  padding: 8px 13px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  border-radius: 3px;
  text-transform: uppercase;
}
.chip-btn:hover { border-color: #3a3a44; color: #fff; }
.chip-btn.accent { background: var(--orange); border-color: var(--orange); color: #120801; font-weight: 700; }
.chip-btn.accent:hover { background: #ff7136; }
.avatar {
  width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center;
  background: #1d1d23;
  border: 1px solid #2c2c34;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  color: #c9c9d2;
}

/* -------------------------------------------------------------------- tabs */
.viewtabs {
  display: flex;
  align-items: stretch;
  gap: 2px;
  padding: 0 12px;
  border-bottom: 1px solid var(--line-soft);
  background: #0b0b0d;
  overflow-x: auto;
  scrollbar-width: none;
}
.viewtabs::-webkit-scrollbar { display: none; }
.viewtab {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0 18px;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
}
.viewtab:hover { color: #b9b9c3; }
.viewtab.is-active { color: var(--orange); border-bottom-color: var(--orange); }
.tab-ico { font-size: 12px; opacity: 0.75; }

/* --------------------------------------------------------------- workspace */
.workspace { position: relative; min-height: 0; background: var(--bg); }
.view { position: absolute; inset: 0; min-height: 0; }
.view.is-active { display: block; }

/* ------------------------------------------------------------- arrangement */
.arrange {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr) 296px;
  height: 100%;
}
.chain {
  border-right: 1px solid var(--line-soft);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--panel);
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #2c2c34 transparent;
}
.panel-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
  margin: 0 0 4px 3px;
}
.chain-mod {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 12px 11px;
  background: var(--panel-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  color: #b9b9c3;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: left;
}
.chain-mod:hover { border-color: #33333c; }
.chain-mod.is-on { border-color: rgba(255, 92, 26, 0.45); background: #191310; color: #f0e7e1; }
.chain-mod .led {
  width: 5px; height: 5px; border-radius: 50%;
  background: #3a3a42;
}
.chain-mod.is-on .led { background: var(--orange); box-shadow: 0 0 7px rgba(255, 92, 26, 0.9); }
.chain-name { flex: 1; }
.chain-ico { color: var(--dim); font-size: 12px; }
.chain-mod.is-on .chain-ico { color: var(--orange); }

.vocal {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--panel-2);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.vocal-head {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--dim);
}
.vocal-head b {
  font-size: 8px; letter-spacing: 0.12em; color: var(--orange);
  border: 1px solid rgba(255, 92, 26, 0.45); border-radius: 2px; padding: 2px 4px;
}
.vocal-meter { height: 6px; background: #14141a; border-radius: 3px; overflow: hidden; }
.vocal-meter i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #3ddc84, #ffd34d 70%, #ff5c1a); transition: width 0.06s linear; }
.vocal-buttons { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 4px; }
.vbtn {
  background: #15151b; border: 1px solid #2a2a33; border-radius: 3px;
  color: #b6b6c0; padding: 7px 2px;
  font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.08em;
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
}
.vbtn:hover { border-color: #45454f; color: #fff; }
.vbtn.rec i { width: 6px; height: 6px; border-radius: 50%; background: #ff5a5a; }
.vbtn.rec.is-recording { background: var(--red); border-color: var(--red); color: #fff; }
.vbtn.rec.is-recording i { background: #fff; }
.vbtn.is-playing { background: var(--orange); border-color: var(--orange); color: #170a02; }
.vocal-status { font-family: var(--mono); font-size: 8.5px; line-height: 1.6; letter-spacing: 0.03em; color: var(--dim); }

.sdr {
  margin-top: auto;
  padding: 12px 11px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--panel-2);
}
.sdr-head {
  display: flex; align-items: baseline; justify-content: space-between;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--dim);
}
.sdr-head b { color: var(--green); font-size: 11px; letter-spacing: 0.04em; }
.sdr-bar { height: 3px; background: #202027; margin-top: 9px; border-radius: 2px; overflow: hidden; }
.sdr-bar i { display: block; height: 100%; width: 72%; background: var(--green); }

.arrange-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}
.spectral {
  padding: 14px 18px 8px;
  border-bottom: 1px solid var(--line-soft);
}
.spectral-head { display: flex; align-items: flex-start; justify-content: space-between; }
.eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--orange);
}
.sub { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.14em; color: var(--dim); margin-top: 5px; }
.big-time {
  font-family: var(--mono);
  font-size: 30px;
  letter-spacing: 0.04em;
  color: #f3f3f6;
  line-height: 1;
}
#spectrum { width: 100%; height: 86px; display: block; margin-top: 6px; }

.tracklist-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 18px;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--dim);
}
.tracklist-actions { display: flex; gap: 6px; }
.mini-ghost {
  background: var(--panel-2);
  border: 1px solid var(--line);
  color: #b7b7c1;
  border-radius: 3px;
  padding: 6px 10px;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.mini-ghost:hover { border-color: #3c3c46; color: #fff; }
.mini-ghost.full { width: 100%; margin-top: 4px; }
.mini-ghost.danger { color: #ff8a8a; border-color: rgba(255, 59, 59, 0.35); }
.mini-ghost.danger:hover { background: rgba(255, 59, 59, 0.1); }

.tracklist {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 0 12px 14px;
  scrollbar-width: thin;
  scrollbar-color: #2c2c34 transparent;
}
.track {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 8px;
  border-left: 2px solid var(--track-color, var(--orange));
  background: var(--panel);
  border-radius: 3px;
  margin-bottom: 5px;
  padding: 7px 8px 4px 10px;
  transition: background 0.12s;
}
.track:hover { background: var(--panel-2); }
.track.is-selected { background: #16161b; box-shadow: inset 0 0 0 1px #2c2c35; }
.track.is-armed { box-shadow: inset 0 0 0 1px rgba(255, 59, 59, 0.5); }
.track.is-recording { animation: recpulse 1.2s ease-in-out infinite; }
@keyframes recpulse { 50% { background: rgba(255, 59, 59, 0.12); } }

.track-top { display: flex; align-items: center; gap: 8px; }
.track-no {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: #d0d0d8;
  min-width: 62px;
}
.track-name {
  flex: 1;
  min-width: 0;
  background: none;
  border: 0;
  padding: 1px 0;
  font-size: 11px;
  letter-spacing: 0.02em;
  color: #9d9da7;
  text-overflow: ellipsis;
}
.track-name:focus { outline: none; color: #fff; }
.track-btns { display: flex; gap: 3px; }
.tbtn-s {
  width: 21px; height: 19px;
  display: grid; place-items: center;
  background: #1a1a20;
  border: 1px solid #26262e;
  border-radius: 2px;
  color: #8d8d97;
  font-family: var(--mono);
  font-size: 9px;
  line-height: 1;
}
.tbtn-s:hover { color: #fff; border-color: #3a3a44; }
.tbtn-s.is-on { background: var(--orange); border-color: var(--orange); color: #160901; font-weight: 700; }
.tbtn-s.arm.is-on { background: var(--red); border-color: var(--red); color: #fff; }
.tbtn-s.solo.is-on { background: #ffd34d; border-color: #ffd34d; color: #1a1400; }

.track-meta {
  display: flex; align-items: center; gap: 10px;
  margin: 4px 0 2px;
  font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.12em;
  color: var(--dim); text-transform: uppercase;
}
.track-meta select {
  background: #17171d;
  border: 1px solid #232329;
  border-radius: 2px;
  color: #96969f;
  font-family: var(--mono);
  font-size: 8.5px;
  padding: 2px 4px;
}
.track-pan { flex: 1; display: flex; align-items: center; gap: 7px; }
.track-pan input { flex: 1; max-width: 150px; }
.track-pan b { color: #9a9aa4; font-weight: 500; min-width: 26px; text-align: right; }
.track-gain { color: #b9b9c3; }

.track-wave { grid-column: 1 / 2; width: 100%; height: 40px; display: block; }
.track-side {
  grid-column: 2 / 3;
  grid-row: 1 / 4;
  display: flex; flex-direction: column; align-items: stretch; justify-content: center; gap: 3px;
}
.track-side .meter { height: 26px; background: #17171c; border-radius: 2px; overflow: hidden; display: flex; align-items: flex-end; }
.track-side .meter i { display: block; width: 100%; height: 0; background: linear-gradient(0deg, #3ddc84, #ffd34d 72%, #ff5c1a); }
.track-side .db { font-family: var(--mono); font-size: 8px; color: var(--dim); text-align: right; }

/* ---------------------------------------------------------- precision console */
.console {
  border-left: 1px solid var(--line-soft);
  background: var(--panel);
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.console-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 10px;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--dim);
}
.console-mark { color: var(--orange); letter-spacing: 0.2em; }
.console-body { padding: 0 16px 16px; display: flex; flex-direction: column; gap: 12px; overflow-y: auto; }
.console-title { display: flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; }
.console-title .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--orange); }
.console-gain { margin-left: auto; color: var(--muted); font-size: 10px; }
#consoleWave { width: 100%; height: 118px; background: #101014; border: 1px solid var(--line-soft); border-radius: 3px; display: block; }
.console-actions { display: flex; align-items: center; gap: 7px; }
.level-meter {
  flex: 1; height: 28px; background: #101014; border: 1px solid var(--line-soft);
  border-radius: 2px; overflow: hidden; display: flex; align-items: center;
}
.level-meter i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, rgba(61, 220, 132, 0.75), rgba(255, 211, 77, 0.8) 70%, rgba(255, 92, 26, 0.9));
  transition: width 0.05s linear;
}
.square-btn {
  width: 30px; height: 28px;
  background: #1a1a20;
  border: 1px solid #26262e;
  border-radius: 2px;
  color: #a9a9b3;
  font-family: var(--mono); font-size: 10px;
}
.square-btn:hover { color: #fff; }
.square-btn.is-on { background: var(--orange); border-color: var(--orange); color: #170a02; }
.console-pan { display: flex; align-items: center; gap: 9px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.14em; color: var(--dim); }
.console-pan b { min-width: 26px; text-align: right; color: #b6b6c0; font-weight: 500; }
.console-route { display: flex; align-items: center; justify-content: space-between; font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; color: var(--dim); }
.console-route select { background: #17171d; border: 1px solid var(--line); color: #a6a6b0; border-radius: 2px; padding: 4px 6px; font-size: 9px; }
.console-hint { font-size: 11px; color: var(--dim); line-height: 1.5; border-top: 1px solid var(--line-soft); padding-top: 10px; }

/* ranges */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 3px;
  background: #26262e;
  border-radius: 2px;
  outline: none;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: #f3f3f6;
  border: 2px solid #111;
  box-shadow: 0 0 0 1px #44444f;
  cursor: pointer;
}
input[type="range"]::-moz-range-thumb {
  width: 10px; height: 10px; border-radius: 50%;
  background: #f3f3f6; border: 2px solid #111; cursor: pointer;
}

/* ------------------------------------------------------------------- mixer */
.mixer {
  display: flex;
  height: 100%;
  background: var(--panel);
  min-height: 0;
}
.strips {
  flex: 1;
  display: flex;
  gap: 1px;
  overflow-x: auto;
  padding: 12px 10px;
  scrollbar-width: thin;
  scrollbar-color: #2c2c34 transparent;
}
.strip {
  width: 54px;
  flex: 0 0 54px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 4px;
  background: #101014;
  border-top: 2px solid var(--strip-color, var(--orange));
  border-radius: 3px;
}
.strip.is-selected { background: #17171d; }
.strip-no { font-family: var(--mono); font-size: 9px; color: var(--dim); letter-spacing: 0.08em; }
.strip-label {
  width: 100%;
  text-align: center;
  font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.06em;
  color: #a9a9b3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.strip-meter { position: relative; width: 7px; height: 170px; background: #191920; border: 1px solid #26262e; border-radius: 2px; overflow: hidden; }
.strip-meter i { position: absolute; left: 0; right: 0; bottom: 0; height: 0; background: linear-gradient(0deg, #3ddc84, #ffd34d 70%, #ff5c1a); }
.strip-db { font-family: var(--mono); font-size: 8px; color: var(--muted); }
.fader {
  position: relative;
  width: 30px;
  height: 170px;
  flex: 0 0 170px;
  cursor: ns-resize;
  touch-action: none;
  outline: none;
}
.fader:focus-visible .fader-groove { border-color: var(--orange); }
.fader-groove {
  position: absolute;
  left: 50%;
  top: 4px;
  bottom: 4px;
  width: 5px;
  margin-left: -2.5px;
  background: #1c1c23;
  border: 1px solid #2c2c35;
  border-radius: 3px;
}
.fader-cap {
  position: absolute;
  left: 50%;
  width: 22px;
  height: 12px;
  margin-left: -11px;
  border-radius: 2px;
  background: linear-gradient(180deg, #f4f4f7, #c9c9d2);
  border: 1px solid #7c7c88;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.65);
  bottom: calc(4px + var(--v, 1) * (100% - 20px));
  pointer-events: none;
}
.fader:hover .fader-groove { border-color: #4a4a56; }
.strip-btns { display: flex; gap: 2px; padding-top: 4px; }
.strip-btns .tbtn-s { width: 16px; height: 16px; font-size: 8px; }
.master-strip {
  width: 84px;
  flex: 0 0 84px;
  border-left: 1px solid var(--line);
  padding: 16px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: #0c0c0f;
}
.strip-name { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.16em; color: var(--orange); }
.master-strip .strip-meter { height: 170px; width: 10px; }
.master-strip .fader { height: 170px; flex: 0 0 170px; }
.strip-leds { display: flex; gap: 4px; }
.strip-leds .led { width: 5px; height: 5px; border-radius: 50%; background: #2a2a32; }
.strip-leds .led.is-on { background: var(--orange); box-shadow: 0 0 6px rgba(255, 92, 26, 0.8); }

/* ----------------------------------------------------------------- splitter */
.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.85fr);
  gap: 14px;
  padding: 16px;
  height: 100%;
  overflow-y: auto;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 16px;
}
.panel-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 14px; }
.panel-head h2 { font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: #e6e6ec; font-weight: 600; }
.panel-head span { font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; color: var(--dim); }
.dropzone {
  border: 1px dashed #2e2e37;
  border-radius: var(--radius);
  padding: 40px 20px;
  text-align: center;
  background: radial-gradient(circle at 50% 0%, rgba(255, 92, 26, 0.08), transparent 62%), #0c0c0f;
  outline: none;
}
.dropzone:hover, .dropzone:focus-visible, .dropzone.is-drag { border-color: var(--orange); background: radial-gradient(circle at 50% 0%, rgba(255, 92, 26, 0.16), transparent 66%), #0c0c0f; }
.dz-icon { font-size: 24px; color: var(--orange); margin-bottom: 8px; }
.dropzone h3 { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.dropzone p { color: var(--dim); font-size: 11px; margin-top: 7px; }
.split-row { display: flex; align-items: baseline; justify-content: space-between; font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; color: var(--muted); margin-top: 16px; }
.split-row b { color: #d9d9e2; font-weight: 500; }
.bar { height: 3px; background: #1d1d24; border-radius: 2px; overflow: hidden; margin-top: 8px; }
.bar i { display: block; height: 100%; width: 0; background: var(--orange); transition: width 0.18s ease; }
.log { list-style: none; padding: 0; margin: 12px 0 0; max-height: 150px; overflow-y: auto; font-family: var(--mono); font-size: 10px; color: var(--dim); line-height: 1.7; }
.log li.ok { color: #a9e8c4; }
.log li.warn { color: #ffc98a; }
.stem-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.stem-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; background: #14141a; border: 1px solid var(--line); border-radius: 3px; font-family: var(--mono); font-size: 9.5px; color: #b9b9c3; }
.stem-chip i { width: 6px; height: 6px; border-radius: 50%; }

.seg { display: flex; border: 1px solid var(--line); border-radius: 3px; overflow: hidden; margin-bottom: 12px; }
.seg-btn {
  flex: 1; padding: 9px 6px; background: #101014; border: 0;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--dim);
}
.seg-btn + .seg-btn { border-left: 1px solid var(--line); }
.seg-btn.is-active { background: var(--orange); color: #170a02; }
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 10px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.field span { display: flex; justify-content: space-between; }
.field span b { color: var(--muted); font-weight: 400; }
.field input[type="url"], .field select, .field input[type="text"] {
  background: #101014; border: 1px solid var(--line); border-radius: 3px;
  padding: 7px 8px; font-family: var(--mono); font-size: 10.5px; color: #c7c7d1; letter-spacing: 0;
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.field.inline { flex-direction: row; align-items: center; gap: 10px; font-size: 9px; }
.field.inline input { width: 180px; }
.note { color: var(--dim); font-size: 11px; line-height: 1.55; margin-top: 10px; }
.status-line { font-family: var(--mono); font-size: 10px; color: var(--muted); margin-top: 8px; line-height: 1.6; word-break: break-word; }
.status-line.ok { color: #9fe2bb; }
.status-line.bad { color: #ff9c9c; }

/* ---------------------------------------------------------------- mastering */
.master-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
  padding: 16px;
}
.module {
  background: var(--panel);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.module header { display: flex; align-items: center; justify-content: space-between; }
.module h3 { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600; }
.module-desc { font-size: 11px; color: var(--dim); line-height: 1.5; min-height: 32px; }
.module input[type="range"] { width: 100%; }
.module-read { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; color: var(--dim); }
.module-read b { color: #cfcfd8; font-weight: 500; }
.toggle {
  width: 34px; height: 18px; border-radius: 10px; border: 1px solid #2c2c34;
  background: #1a1a20; position: relative; padding: 0;
}
.toggle::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 12px; height: 12px; border-radius: 50%; background: #55555f; transition: all 0.15s;
}
.toggle.is-on { background: rgba(255, 92, 26, 0.22); border-color: var(--orange); }
.toggle.is-on::after { left: 18px; background: var(--orange); }
.master-footer {
  display: flex; align-items: center; gap: 14px;
  padding: 4px 18px 18px;
}
.master-footer b { font-family: var(--mono); font-size: 10px; color: #cfcfd8; }
.master-footer .note { margin: 0 0 0 auto; }

/* -------------------------------------------------------------- preferences */
.pref-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  padding: 16px;
  align-content: start;
}
.inline-row { display: flex; gap: 8px; flex-wrap: wrap; }
.spec-list { display: flex; flex-direction: column; gap: 8px; margin: 4px 0 16px; }
.spec-list > div { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line-soft); padding-bottom: 7px; }
.spec-list dt { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.spec-list dd { font-family: var(--mono); font-size: 10.5px; color: #cfcfd8; }
code { font-family: var(--mono); font-size: 10.5px; background: #14141a; padding: 1px 4px; border-radius: 2px; }

/* ---------------------------------------------------------------- transport */
.transport {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 9px 18px 8px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, #121216, #0a0a0d);
}
.pt-main { display: flex; align-items: center; gap: 14px; min-width: 0; }
.pt-buttons { display: flex; align-items: center; gap: 6px; }
.pt-div { width: 1px; height: 26px; background: #2a2a33; margin: 0 4px; }
.pt-lcd {
  background: #05070a;
  border: 1px solid #25331b;
  border-radius: 3px;
  padding: 4px 12px 5px;
  min-width: 208px;
  box-shadow: inset 0 0 22px rgba(160, 240, 70, 0.07);
}
.lcd-bars {
  font-family: var(--mono);
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: 0.05em;
  color: #b6f04a;
  text-shadow: 0 0 9px rgba(182, 240, 74, 0.35);
}
.lcd-time { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.14em; color: #7fa63c; margin-top: 1px; }
.pt-fields { display: flex; gap: 12px; }
.pt-fields > div { display: flex; flex-direction: column; gap: 2px; }
.pt-fields span { font-family: var(--mono); font-size: 7.5px; letter-spacing: 0.14em; color: var(--dim); }
.pt-fields b { font-family: var(--mono); font-size: 10.5px; font-weight: 500; color: #c8d6a8; letter-spacing: 0.02em; }
.pt-opts { display: flex; gap: 10px; margin-left: auto; }
.pt-opts label { display: flex; flex-direction: column; gap: 3px; font-family: var(--mono); font-size: 7.5px; letter-spacing: 0.12em; color: var(--dim); }
.pt-opts select, .pt-opts input {
  background: #101014; border: 1px solid var(--line); border-radius: 2px;
  color: #c7c7d1; font-family: var(--mono); font-size: 9.5px; padding: 3px 5px;
}
.pt-opts input { width: 54px; }
.pt-bottom { display: flex; align-items: center; gap: 16px; }
.transport-buttons { display: flex; align-items: center; gap: 8px; }
.tbtn {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: #17171d;
  border: 1px solid #2a2a32;
  color: #c7c7d1;
  font-size: 11px;
}
.tbtn:hover { border-color: #45454f; color: #fff; }
.tbtn.play { width: 46px; height: 46px; font-size: 13px; }
.tbtn.play.is-playing { background: var(--orange); border-color: var(--orange); color: #150901; }
.tbtn.stop { font-size: 9px; }
.tbtn.rec { color: #ff5a5a; border-color: rgba(255, 59, 59, 0.35); }
.tbtn.rec.is-recording { background: var(--red); border-color: var(--red); color: #fff; animation: recpulse 1.1s infinite; }

.tbtn.loop {
  width: auto;
  min-width: 50px;
  height: 26px;
  border-radius: 3px;
  padding: 0 7px;
  font-family: var(--mono);
  font-size: 7.5px;
  letter-spacing: 0.12em;
}
.tbtn.loop.is-on { background: var(--orange); border-color: var(--orange); color: #150901; }
.tbtn.loop.rec { color: #ffb9a0; border-color: rgba(255, 106, 43, 0.35); }
.tbtn.loop.rec.is-on { background: var(--red); border-color: var(--red); color: #fff; }
.pt-opts label.is-loop span { color: var(--orange); }
.pt-opts label.is-loop input { border-color: rgba(255, 106, 43, 0.55); color: #ffd9c6; }

.seek {
  flex: 1;
  height: 22px;
  position: relative;
  cursor: pointer;
  min-width: 80px;
}
.seek::before {
  content: ""; position: absolute; left: 0; right: 0; top: 10px;
  height: 2px; background: #24242c; border-radius: 2px;
}
.seek i { position: absolute; left: 0; top: 10px; height: 2px; width: 0; background: var(--orange); border-radius: 2px; }
.seek .seek-loop {
  top: 5px; height: 12px; width: 0;
  background: rgba(255, 106, 43, 0.14);
  border-left: 1px solid rgba(255, 106, 43, 0.65);
  border-right: 1px solid rgba(255, 106, 43, 0.65);
  border-radius: 2px;
}
.seek b {
  position: absolute; top: 5px; left: 0;
  width: 11px; height: 11px; margin-left: -5px;
  border-radius: 50%; background: #f2f2f5; box-shadow: 0 0 0 1px #4a4a55;
}
.master-vol { display: flex; align-items: center; gap: 9px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; color: var(--dim); }
.master-vol input { width: 110px; }
.master-meter { width: 10px; height: 30px; background: #17171c; border-radius: 2px; display: flex; align-items: flex-end; overflow: hidden; }
.master-meter i { width: 100%; height: 0; background: linear-gradient(0deg, #3ddc84, #ffd34d 72%, #ff5c1a); }
.bitrate { display: flex; flex-direction: column; align-items: flex-end; font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.12em; color: var(--dim); }
.bitrate b { color: #b9b9c3; font-weight: 500; margin-top: 3px; }

.track-wave { touch-action: none; cursor: grab; }
.track-wave.is-dragging { cursor: grabbing; }

/* -------------------------------------------------------------- context menu */
.ctx-menu {
  position: fixed;
  z-index: 120;
  min-width: 196px;
  padding: 4px;
  background: linear-gradient(180deg, #17171d, #0f0f13);
  border: 1px solid #32323c;
  border-radius: 4px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.6);
}
.ctx-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 6px 9px;
  background: none;
  border: 0;
  border-radius: 3px;
  color: #c9c9d3;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-align: left;
  cursor: pointer;
}
.ctx-item:hover:not([disabled]),
.ctx-item:focus-visible {
  background: rgba(255, 106, 43, 0.16);
  color: #fff;
  outline: none;
}
.ctx-item b { font-size: 9px; font-weight: 500; letter-spacing: 0.04em; color: var(--dim); }
.ctx-item.danger { color: #ff9483; }
.ctx-item.danger:hover:not([disabled]) { background: rgba(255, 59, 59, 0.18); color: #ffd2c9; }
.ctx-item[disabled] { color: #4e4e59; cursor: default; }
.ctx-item[disabled] b { color: #3b3b45; }
.ctx-sep { height: 1px; margin: 4px 6px; background: #262630; }

/* --------------------------------------------------------------------- toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 94px;
  transform: translateX(-50%);
  background: #1b1b21;
  border: 1px solid #33333d;
  color: #eeeef3;
  padding: 9px 15px;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  z-index: 50;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
}

@media (max-width: 1180px) {
  .arrange { grid-template-columns: 210px minmax(0, 1fr); }
  .console { display: none; }
}
@media (max-width: 880px) {
  .arrange { grid-template-columns: minmax(0, 1fr); }
  .chain { display: none; }
  .model-status { display: none; }
  .master-vol { display: none; }
  .split-grid { grid-template-columns: minmax(0, 1fr); }
  .pt-fields { display: none; }
  .pt-opts { display: none; }
}
@media (max-width: 1300px) {
  .pt-fields { display: none; }
}

/* ------------------------------------------------------------------ zoom */
.zoom-tools { display: flex; align-items: center; gap: 4px; }
.mini-ghost.zoom { min-width: 22px; padding: 0 6px; font-size: 12px; line-height: 1; }
.zoom-label {
  min-width: 36px; text-align: center;
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.08em; color: var(--dim);
}
.track-wave.is-panning { cursor: grabbing; }

/* -------------------------------------------------------- waveform editor */
.wave-editor { display: flex; flex-direction: column; gap: 12px; padding: 16px 18px 18px; }
.wave-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.wave-title-block h2 { margin: 4px 0 2px; font-size: 18px; letter-spacing: 0.06em; }
.wave-zoom {
  display: flex; align-items: center; gap: 6px;
  font-family: var(--mono); font-size: 10px; color: var(--dim);
}
.wave-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.wave-btn {
  background: #15151a; border: 1px solid var(--line); border-radius: 3px;
  color: #c7c7d1; font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.08em;
  padding: 6px 9px; cursor: pointer; text-transform: uppercase;
}
.wave-btn:hover { border-color: #45454f; color: #fff; }
.wave-btn.audition { border-color: rgba(255, 106, 43, 0.45); color: #ffb28a; }
.wave-btn.audition.is-on { background: var(--orange); border-color: var(--orange); color: #150901; }
.wave-spacer { flex: 1; }
.wave-canvas-wrap {
  position: relative; height: clamp(240px, 48vh, 520px);
  background: #0b0b0f; border: 1px solid var(--line); border-radius: 4px; overflow: hidden;
}
#waveCanvas { display: block; width: 100%; height: 100%; cursor: crosshair; touch-action: none; }
.wave-empty {
  position: absolute; inset: 0; display: grid; place-items: center;
  color: var(--dim); font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em;
}
.wave-empty[hidden] { display: none; }
.wave-status { margin: 0; font-family: var(--mono); font-size: 10px; letter-spacing: 0.05em; color: var(--dim); }

/* ---------------------------------------------------------------- plug-ins */
.plugins {
  display: grid; grid-template-columns: minmax(330px, 440px) minmax(0, 1fr);
  gap: 14px; padding: 16px 18px 18px; align-items: start;
}
.rack { display: flex; flex-direction: column; gap: 10px; }
.rack-head { display: flex; align-items: center; gap: 12px; }
.rack-head h2 { margin: 2px 0 0; font-size: 16px; letter-spacing: 0.08em; }
.rack-track {
  display: flex; align-items: center; gap: 6px; margin-left: auto;
  font-family: var(--mono); font-size: 8px; letter-spacing: 0.1em; color: var(--dim);
}
.rack-track select {
  background: #101014; border: 1px solid var(--line); border-radius: 2px;
  color: #c7c7d1; font-family: var(--mono); font-size: 9.5px; padding: 4px 6px;
}
.rack-list { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow: auto; }
.rack-empty { margin: 0; color: var(--dim); font-family: var(--mono); font-size: 10px; }
.insert { border: 1px solid var(--line); border-radius: 4px; background: #101015; }
.insert.is-off { opacity: 0.5; }
.insert-head { display: flex; align-items: center; gap: 8px; padding: 6px 8px; }
.insert-no { font-family: var(--mono); font-size: 9px; color: var(--dim); }
.insert-name { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.05em; color: #dcdce6; }
.insert-kind {
  margin-left: auto; font-family: var(--mono); font-size: 7.5px;
  letter-spacing: 0.12em; color: var(--dim);
}
.insert-params {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(136px, 1fr));
  gap: 4px 12px; padding: 0 8px 8px;
}
.insert-params label {
  display: grid; grid-template-columns: 46px minmax(0, 1fr) 30px;
  align-items: center; gap: 6px;
  font-family: var(--mono); font-size: 8px; letter-spacing: 0.06em; color: var(--dim);
}
.insert-params label b { color: #b9b9c3; font-weight: 500; text-align: right; }
.insert-params input[type="range"] { width: 100%; }
.catalog { display: flex; flex-direction: column; gap: 12px; }
.catalog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(172px, 1fr)); gap: 8px; }
.catalog-card {
  text-align: left; background: #131318; border: 1px solid var(--line);
  border-radius: 4px; padding: 9px 10px; cursor: pointer;
}
.catalog-card:hover { border-color: rgba(255, 106, 43, 0.5); }
.catalog-card b {
  display: block; font-family: var(--mono); font-size: 10px;
  letter-spacing: 0.07em; color: #e3e3ea;
}
.catalog-card span { display: block; margin-top: 4px; font-size: 10px; line-height: 1.35; color: var(--dim); }
.external {
  display: flex; flex-direction: column; gap: 8px;
  border-top: 1px solid var(--line); padding-top: 12px;
}
.external h3 { margin: 0; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: #dcdce6; }

@media (max-width: 980px) {
  .plugins { grid-template-columns: minmax(0, 1fr); }
  .wave-canvas-wrap { height: 320px; }
}

/* ---------------------------------------------------- Pro Tools HD transport */
.pt-opts { flex-wrap: wrap; justify-content: flex-end; row-gap: 7px; }
.pt-opts label.inline-toggle { align-items: flex-start; }
.pt-opts .inline-toggle .toggle { margin-top: 2px; }
@media (max-width: 960px) {
  .pt-opts > label:nth-last-child(-n+2) { display: none; }
}

/* ----------------------------------------------------------- founders gate */
body.is-locked { overflow: hidden; }
.gate {
  position: fixed; inset: 0; z-index: 400;
  display: grid; place-items: center; padding: 24px;
  background:
    radial-gradient(1100px 420px at 50% -10%, rgba(255, 92, 26, 0.18), transparent 65%),
    #070709;
}
.gate::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: radial-gradient(60% 55% at 50% 42%, #000 15%, transparent 100%);
  mask-image: radial-gradient(60% 55% at 50% 42%, #000 15%, transparent 100%);
}
.gate-card {
  position: relative;
  width: min(420px, 100%);
  padding: 28px 30px 24px;
  border: 1px solid #26262e;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(23, 23, 28, 0.97), rgba(10, 10, 12, 0.99));
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.75);
}
.gate-brand { font-family: var(--mono); font-size: 12px; letter-spacing: 0.28em; color: #f2f2f6; }
.gate-brand span { color: var(--orange); margin-left: 3px; }
.gate-kicker {
  margin-top: 16px;
  font-family: var(--mono); font-size: 8px; letter-spacing: 0.22em; color: var(--orange);
}
.gate-card h1 { margin: 6px 0 0; font-size: 26px; letter-spacing: -0.02em; }
.gate-sub { margin-top: 8px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.gate-form { margin-top: 20px; display: grid; gap: 12px; }
.gate-form > label {
  display: grid; gap: 5px;
  font-family: var(--mono); font-size: 8px; letter-spacing: 0.16em; color: var(--dim);
}
.gate-form input[type="email"],
.gate-form input[type="password"] {
  background: #0a0a0d; border: 1px solid #292930; border-radius: 4px;
  padding: 10px 11px; color: #e8e8ee;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: 0.02em;
}
.gate-form input[type="email"]:focus,
.gate-form input[type="password"]:focus {
  outline: none; border-color: rgba(255, 92, 26, 0.62);
  box-shadow: 0 0 0 3px rgba(255, 92, 26, 0.12);
}
.gate-form label.gate-remember {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font); font-size: 11.5px; letter-spacing: 0; color: var(--muted);
}
.gate-remember input { accent-color: var(--orange); width: 13px; height: 13px; }
.gate-error { min-height: 14px; font-size: 11px; color: #ff8272; }
.gate-submit {
  height: 40px; border: 1px solid #ff7233; border-radius: 4px;
  background: linear-gradient(180deg, #ff6a2b, #d8460c);
  color: #140800; font-family: var(--mono); font-size: 10px; letter-spacing: 0.18em; font-weight: 700;
}
.gate-submit:hover:not(:disabled) { filter: brightness(1.07); }
.gate-submit:disabled { opacity: 0.55; cursor: progress; }
.gate-foot { margin-top: 16px; font-size: 10.5px; line-height: 1.6; color: var(--dim); }
.gate-card.is-shaking { animation: gate-shake 0.34s ease; }
@keyframes gate-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(2px); }
}
.avatar.is-founder { background: rgba(255, 92, 26, 0.18); border-color: rgba(255, 92, 26, 0.6); color: #ffd9c6; }
