/* Audio tools (MERGE, SPLIT for audio, ST SPLIT and ST MERGE between stereo
   and mono): the MIDI tools' box (midi-tools.css), with a signal LED on every
   jack, LEVEL knobs and mute buttons under them. */

.mt-audio-merge { --tool: #e8c547; }
.mt-audio-split { --tool: #e07a5f; }
.mt-stereo-split { --tool: #7fc8a9; }
.mt-stereo-merge { --tool: #8fa8e8; }

.mt-audio-merge .mt-jack,
.mt-audio-split .mt-jack,
.mt-stereo-split .mt-jack,
.mt-stereo-merge .mt-jack { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.mt-audio-merge .mt-jack[hidden],
.mt-audio-split .mt-jack[hidden] { display: none; }
.mt-audio-merge ws-knob,
.mt-stereo-merge ws-knob { --k: 42px; width: 46px; }
.mt-audio-merge ws-knob .knob-body .pointer,
.mt-stereo-merge ws-knob .knob-body .pointer { stroke: var(--tool); }
.mt-audio-merge .mt-arrow,
.mt-audio-split .mt-arrow,
.mt-stereo-split .mt-arrow,
.mt-stereo-merge .mt-arrow { margin-top: 0; }
.mt-stereo-split .mt-controls:empty,
.mt-stereo-merge .mt-controls:empty { display: none; }

/* Signal LED: lights with the level at the jack. */
.at-led {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #0d240f;
  box-shadow: 0 0 0 1px #000;
}
.at-led::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #4dff8a;
  box-shadow: 0 0 6px 1px rgba(77, 255, 138, 0.8);
  opacity: var(--level, 0);
}

.at-mute {
  width: 26px;
  height: 16px;
  border: 0;
  border-radius: 3px;
  background: linear-gradient(180deg, #45494d, #2a2c30);
  box-shadow: 0 2px 0 #0b0c0d, inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #c9ccd0;
  font: 700 9px var(--mono);
  cursor: pointer;
}
.at-mute:active { transform: translateY(1px); box-shadow: 0 1px 0 #0b0c0d; }
.at-mute:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.at-mute[aria-pressed="true"] { background: linear-gradient(180deg, #ff6a55, #c4321f); color: #fff; box-shadow: 0 2px 0 #0b0c0d, 0 0 10px rgba(255, 90, 60, 0.6); }
.mt-jack:has(.at-mute[aria-pressed="true"]) ws-knob { opacity: 0.4; }
