/* src/styles.css */
:root,
:root[data-theme=dark] {
  color-scheme: dark;
  --bg: #141414;
  --bg-bar: #0f0f0f;
  --surface: #262626;
  --surface-2: #1d1d1d;
  --line: #2a2a2a;
  --border-soft: #343434;
  --border: #4a4a4a;
  --text: #ece8df;
  --text-soft: #d6d3cc;
  --text-muted: #a8a49c;
  --text-dim: #8d8981;
  --text-strong: #f7f4ee;
  --cursor: #ece8df;
  --accent: #d9c9a3;
  --accent-soft: #ebdfc4;
  --accent-text: #d9c9a3;
  --on-accent: #141414;
  --btn-neutral: #333333;
  --on-neutral: #ece8df;
  --violet: #d9c9a3;
  --violet-hover: #ebdfc4;
  --danger: #ef4444;
  --danger-soft: #f87171;
  --danger-text: #fca5a5;
  --warn: #f59e0b;
  --ok: #4ade80;
  --ok-strong: #22c55e;
  --banner-warn: #7c2d12;
  --banner-error: #7f1d1d;
  --notice: #262626;
  --shadow: rgba(0, 0, 0, 0.65);
  --glow: #000000;
  --chord-other: #77746e;
  --chord-none: #b8a47a;
  --fn-t: #4ade80;
  --fn-s: #f59e0b;
  --fn-d: #f87171;
  --cadence-text: #d9c9a3;
  --modulation-text: #fbbf24;
  --modulation-border: #92400e;
  --velocity-bar: #d9c9a3;
  --section-intro: #7c3aed;
  --section-verse: #2563eb;
  --section-prechorus: #0891b2;
  --section-chorus: #16a34a;
  --section-bridge: #d97706;
  --section-outro: #6b7280;
  --section-custom: #4b5563;
  --cof-tonic: #d9c9a3;
  --cof-chord: #b8a47a;
  --cof-diatonic: #2e2e2e;
  --cof-diatonic-stroke: #5f5b54;
  --cof-segment: #1a1a1a;
  --cof-stroke: #383838;
  --cof-dim-diatonic: #2a2a2a;
  --cof-dim-diatonic-stroke: #6f6b63;
  --cof-dim: #171717;
  --cof-dim-stroke: #2e2e2e;
  --cof-label: #ece8df;
  --cof-label-on-mark: #141414;
  --cof-minor-label: #a8a49c;
  --cof-minor-diatonic-label: #d6d3cc;
  --cof-dim-label: #77746e;
  --cof-dim-diatonic-label: #b5b1a8;
  --cof-degree: #d9c9a3;
  --cof-degree-small: #c2b48f;
  --piano-white: #f2efe8;
  --piano-white-stroke: #8f8b83;
  --piano-black: #1a1a1a;
  --piano-black-stroke: #1a1a1a;
  --piano-label: #8f8b83;
  --piano-black-label: #55524c;
  --fret-text: #ece8df;
  --fret-label: #a8a49c;
  --fret-nut: #bdb9b0;
  --fret-string: #8f8b83;
  --fret-wire: #5f5b54;
  --fret-dot: #d9c9a3;
  --fret-dot-text: #141414;
  --neck-dot: #d9c9a3;
  --scale-dot: #8c8778;
  --piano-scale: #bdb6a6;
  --piano-scale-root: #a68c52;
  --iso-cell: #262626;
  --iso-label: #8d8981;
  --iso-off-label: #5c5a55;
  --iso-link: #f7f4ee;
  --iso-scale: #34322c;
  --iso-scale-label: #d6d3cc;
  --logo-bg: #141414;
  --logo-ink: #ece8df;
}
:root[data-theme=light] {
  color-scheme: light;
  --bg: #efeeeb;
  --bg-bar: #e6e4e0;
  --surface: #f5f4f1;
  --surface-2: #ffffff;
  --line: #dcd9d3;
  --border-soft: #d2cfc8;
  --border: #b3afa6;
  --text: #1f1d1a;
  --text-soft: #2f2c27;
  --text-muted: #55514a;
  --text-dim: #6a665e;
  --text-strong: #000000;
  --cursor: #1f1d1a;
  --accent: #6b5530;
  --accent-soft: #9a8256;
  --accent-text: #6b5530;
  --on-accent: #ffffff;
  --btn-neutral: #6a665e;
  --on-neutral: #ffffff;
  --violet: #6b5530;
  --violet-hover: #55431f;
  --danger: #dc2626;
  --danger-soft: #dc2626;
  --danger-text: #b91c1c;
  --warn: #d97706;
  --ok: #16a34a;
  --ok-strong: #16a34a;
  --banner-warn: #fde2c8;
  --banner-error: #fecaca;
  --notice: #e6e4e0;
  --shadow: rgba(0, 0, 0, 0.18);
  --glow: transparent;
  --chord-other: #9a968e;
  --chord-none: #8a7346;
  --fn-t: #15803d;
  --fn-s: #b45309;
  --fn-d: #dc2626;
  --cadence-text: #6b5530;
  --modulation-text: #b45309;
  --modulation-border: #f59e0b;
  --velocity-bar: #8a7346;
  --section-intro: #7c3aed;
  --section-verse: #2563eb;
  --section-prechorus: #0891b2;
  --section-chorus: #16a34a;
  --section-bridge: #d97706;
  --section-outro: #6b7280;
  --section-custom: #4b5563;
  --cof-tonic: #6b5530;
  --cof-chord: #8a7346;
  --cof-diatonic: #e4dfd4;
  --cof-diatonic-stroke: #a89d86;
  --cof-segment: #f5f4f1;
  --cof-stroke: #c9c5bd;
  --cof-dim-diatonic: #ddd6c6;
  --cof-dim-diatonic-stroke: #8f8169;
  --cof-dim: #efeeeb;
  --cof-dim-stroke: #d2cfc8;
  --cof-label: #1f1d1a;
  --cof-label-on-mark: #ffffff;
  --cof-minor-label: #55514a;
  --cof-minor-diatonic-label: #3b3428;
  --cof-dim-label: #6a665e;
  --cof-dim-diatonic-label: #4a4032;
  --cof-degree: #6b5530;
  --cof-degree-small: #7d6640;
  --piano-white: #ffffff;
  --piano-white-stroke: #9aa0ad;
  --piano-black: #222222;
  --piano-black-stroke: #222222;
  --piano-label: #6b7280;
  --piano-black-label: #555555;
  --fret-text: #1f2333;
  --fret-label: #4b5263;
  --fret-nut: #2f3445;
  --fret-string: #8a8f9c;
  --fret-wire: #b3b8c8;
  --fret-dot: #6b5530;
  --fret-dot-text: #ffffff;
  --neck-dot: #6b5530;
  --scale-dot: #8a8170;
  --piano-scale: #b9b2a3;
  --piano-scale-root: #6b5530;
  --iso-cell: #e4e1db;
  --iso-label: #6a665e;
  --iso-off-label: #a9a49a;
  --iso-link: #1f1d1a;
  --iso-scale: #d6ccb6;
  --iso-scale-label: #2f2c27;
  --logo-bg: #141414;
  --logo-ink: #ece8df;
}
:root[data-theme=contrast] {
  color-scheme: dark;
  --bg: #000000;
  --bg-bar: #0a0a0a;
  --surface: #161616;
  --surface-2: #0e0e0e;
  --line: #3a3a3a;
  --border-soft: #5a5a5a;
  --border: #8a8a8a;
  --text: #ffffff;
  --text-soft: #f2f2f2;
  --text-muted: #d4d4d4;
  --text-dim: #ababab;
  --text-strong: #ffffff;
  --cursor: #ffff00;
  --accent: #f0dca8;
  --accent-soft: #fff0cc;
  --accent-text: #f0dca8;
  --on-accent: #000000;
  --btn-neutral: #3a3a3a;
  --on-neutral: #ffffff;
  --violet: #f0dca8;
  --violet-hover: #fff0cc;
  --danger: #ff4d4d;
  --danger-soft: #ff7070;
  --danger-text: #ffb3b3;
  --warn: #ffb020;
  --ok: #5cff8a;
  --ok-strong: #2fd760;
  --banner-warn: #7a2e00;
  --banner-error: #8a0000;
  --notice: #1a1a1a;
  --shadow: rgba(0, 0, 0, 0.85);
  --glow: #000000;
  --chord-other: #9a9a9a;
  --chord-none: #e0c98a;
  --fn-t: #5cff8a;
  --fn-s: #ffc233;
  --fn-d: #ff6b6b;
  --cadence-text: #f0dca8;
  --modulation-text: #ffd24d;
  --modulation-border: #b07800;
  --velocity-bar: #f0dca8;
  --section-intro: #7c3aed;
  --section-verse: #2563eb;
  --section-prechorus: #0891b2;
  --section-chorus: #16a34a;
  --section-bridge: #d97706;
  --section-outro: #6b7280;
  --section-custom: #4b5563;
  --cof-tonic: #f0dca8;
  --cof-chord: #e0c98a;
  --cof-diatonic: #2a2a2a;
  --cof-diatonic-stroke: #bdbdbd;
  --cof-segment: #1a1a1a;
  --cof-stroke: #8a8a8a;
  --cof-dim-diatonic: #2a2a2a;
  --cof-dim-diatonic-stroke: #d4d4d4;
  --cof-dim: #0e0e0e;
  --cof-dim-stroke: #5a5a5a;
  --cof-label: #ffffff;
  --cof-label-on-mark: #000000;
  --cof-minor-label: #d4d4d4;
  --cof-minor-diatonic-label: #ffffff;
  --cof-dim-label: #ababab;
  --cof-dim-diatonic-label: #e6e6e6;
  --cof-degree: #f0dca8;
  --cof-degree-small: #e0c98a;
  --piano-white: #ffffff;
  --piano-white-stroke: #8a8a8a;
  --piano-black: #000000;
  --piano-black-stroke: #5a5a5a;
  --piano-label: #d4d4d4;
  --piano-black-label: #5a5a5a;
  --fret-text: #ffffff;
  --fret-label: #d4d4d4;
  --fret-nut: #ffffff;
  --fret-string: #c4c4c4;
  --fret-wire: #8a8a8a;
  --fret-dot: #f0dca8;
  --fret-dot-text: #000000;
  --neck-dot: #f0dca8;
  --scale-dot: #a3a3a3;
  --piano-scale: #9a9a9a;
  --piano-scale-root: #c9a23c;
  --iso-cell: #1f1f1f;
  --iso-label: #ababab;
  --iso-off-label: #6e6e6e;
  --iso-link: #ffffff;
  --iso-scale: #3d3d3d;
  --iso-scale-label: #ffffff;
  --logo-bg: #000000;
  --logo-ink: #ffffff;
}
:root[data-theme=paper] {
  color-scheme: light;
  --bg: #f6f1e7;
  --bg-bar: #ece4d4;
  --surface: #fffaf0;
  --surface-2: #efe7d8;
  --line: #ddd2bd;
  --border-soft: #d2c6ae;
  --border: #b8a98c;
  --text: #2b2418;
  --text-soft: #3b3224;
  --text-muted: #5a4e3c;
  --text-dim: #7a6d58;
  --text-strong: #000000;
  --cursor: #2b2418;
  --accent: #9a3b1b;
  --accent-soft: #c9773f;
  --accent-text: #9a3b1b;
  --on-accent: #ffffff;
  --btn-neutral: #7a6d58;
  --on-neutral: #ffffff;
  --violet: #9a3b1b;
  --violet-hover: #7a2d13;
  --danger: #b8321f;
  --danger-soft: #b8321f;
  --danger-text: #8f2414;
  --warn: #b06a0a;
  --ok: #2f7d4a;
  --ok-strong: #2f7d4a;
  --banner-warn: #f3d9b8;
  --banner-error: #f3c4b8;
  --notice: #ece4d4;
  --shadow: rgba(60, 40, 10, 0.18);
  --glow: transparent;
  --chord-other: #a8997c;
  --chord-none: #9a3b1b;
  --fn-t: #2f7d4a;
  --fn-s: #a8670a;
  --fn-d: #b8321f;
  --cadence-text: #9a3b1b;
  --modulation-text: #8f5a08;
  --modulation-border: #c27c0e;
  --velocity-bar: #9a3b1b;
  --section-intro: #7c3aed;
  --section-verse: #2563eb;
  --section-prechorus: #0891b2;
  --section-chorus: #16a34a;
  --section-bridge: #d97706;
  --section-outro: #6b7280;
  --section-custom: #4b5563;
  --cof-tonic: #9a3b1b;
  --cof-chord: #9a3b1b;
  --cof-diatonic: #efdcc4;
  --cof-diatonic-stroke: #b08d63;
  --cof-segment: #ece4d4;
  --cof-stroke: #b8a98c;
  --cof-dim-diatonic: #e6d0b4;
  --cof-dim-diatonic-stroke: #8f6a3f;
  --cof-dim: #efe7d8;
  --cof-dim-stroke: #d2c6ae;
  --cof-label: #2b2418;
  --cof-label-on-mark: #ffffff;
  --cof-minor-label: #5a4e3c;
  --cof-minor-diatonic-label: #7a3416;
  --cof-dim-label: #7a6d58;
  --cof-dim-diatonic-label: #7a3416;
  --cof-degree: #9a3b1b;
  --cof-degree-small: #b4532a;
  --piano-white: #fffaf0;
  --piano-white-stroke: #a8997c;
  --piano-black: #2b2418;
  --piano-black-stroke: #2b2418;
  --piano-label: #7a6d58;
  --piano-black-label: #5a4e3c;
  --fret-text: #2b2418;
  --fret-label: #5a4e3c;
  --fret-nut: #3b3224;
  --fret-string: #8f826b;
  --fret-wire: #b8a98c;
  --fret-dot: #9a3b1b;
  --fret-dot-text: #ffffff;
  --neck-dot: #9a3b1b;
  --scale-dot: #7d7466;
  --piano-scale: #c2b59a;
  --piano-scale-root: #9a3b1b;
  --iso-cell: #e3d8c3;
  --iso-label: #7a6d58;
  --iso-off-label: #b3a68e;
  --iso-link: #2a2118;
  --iso-scale: #d2c09c;
  --iso-scale-label: #2a2118;
  --logo-bg: #2b2418;
  --logo-ink: #f6f1e7;
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  background: var(--bg);
}
body {
  font-family: system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
}
#app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
#browser-warning {
  display: none;
  background: var(--banner-warn);
  padding: 8px 16px;
  text-align: center;
  font-size: 13px;
}
#cdn-error-banner {
  display: none;
  background: var(--banner-error);
  padding: 8px 16px;
  text-align: center;
  font-size: 13px;
}
#cdn-error-banner.visible {
  display: block;
}
#midi-banner {
  display: none;
  background: var(--banner-error);
  padding: 6px 12px;
  font-size: 12px;
}
.mode-btn {
  height: 30px;
  padding: 0 12px;
  border-radius: 6px;
  background: transparent;
  color: var(--text-soft);
  border: 1px solid var(--border-soft);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
}
.mode-btn:hover,
.ctrl-btn:hover,
.size-ctrl-btn:hover {
  border-color: var(--border);
  color: var(--text);
}
.ctrl-btn.active-mode,
.mode-btn.active-mode {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
  font-weight: 600;
}
.size-ctrl-btn {
  background: transparent;
  border: 1px solid var(--border-soft);
  color: var(--text-muted);
  border-radius: 5px;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  line-height: 1;
  padding: 4px 8px;
}
.size-ctrl-btn.active {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}
.size-ctrl-btn:disabled {
  cursor: default;
  opacity: .45;
}
.icon-btn {
  width: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.ctrl-btn.ghost,
.ghost {
  border-color: transparent;
  background: transparent;
  color: var(--text-muted);
}
.ctrl-btn.ghost:hover,
.ghost:hover {
  background: var(--surface);
  border-color: transparent;
  color: var(--text);
}
.ctrl-btn.ghost.active-mode,
.ghost.active-mode {
  background: var(--surface);
  color: var(--accent-text);
  border-color: transparent;
}
.help-q {
  font-size: 15px;
  font-weight: 600;
}
.icon {
  display: block;
  flex-shrink: 0;
}
.ctrl-select {
  height: 30px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  padding: 0 8px;
  font: inherit;
  font-size: 13px;
}
.ctrl-select:hover {
  border-color: var(--border);
}
.toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  min-height: 52px;
  padding: 8px 14px 8px 8px;
  background: var(--bg-bar);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  user-select: none;
}
.logo-mark {
  display: block;
  border-radius: 6px;
}
.brand-name {
  font-family:
    Georgia,
    "Times New Roman",
    serif;
  font-style: italic;
  font-weight: 600;
  font-size: 19px;
  color: var(--text-strong);
  letter-spacing: .02em;
}
.pop-anchor {
  position: relative;
}
.key-btn {
  display: flex;
  align-items: baseline;
  gap: 8px;
  height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-strong);
  font: inherit;
  cursor: pointer;
  white-space: nowrap;
}
.key-btn:hover,
.key-btn[aria-expanded=true] {
  background: var(--surface);
}
#key-btn-name {
  font-size: 16px;
  font-weight: 700;
}
.key-btn-auto {
  font-size: 12px;
  color: var(--text-dim);
}
.tb-search {
  flex: 0 1 460px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 10px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid transparent;
  color: var(--text-dim);
}
.tb-search:focus-within {
  border-color: var(--accent);
  background: var(--surface);
}
.tb-search:has(.invalid) {
  border-color: var(--danger);
}
.typed-chord {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
}
.typed-chord::placeholder {
  color: var(--text-dim);
}
.typed-chord.invalid {
  color: var(--danger-text);
}
.typed-chord:focus-visible {
  outline: none;
}
.sound-menu .audio-progress-fill {
  opacity: .3;
}
.tb-kbd {
  font: inherit;
  font-size: 11px;
  padding: 0 5px;
  border: 1px solid var(--border-soft);
  border-radius: 4px;
  color: var(--text-dim);
}
.tb-search:focus-within .tb-kbd {
  display: none;
}
.cmd-results {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  z-index: 40;
  max-height: calc(60vh / var(--zoom, 1));
  overflow: auto;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  box-shadow: 0 12px 32px var(--shadow);
}
.cmd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 0 10px;
  border-radius: 6px;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
}
.cmd-item[aria-selected=true] {
  background: var(--surface-2);
  color: var(--text-strong);
}
.cmd-hint {
  margin-left: auto;
  font-size: 12px;
  color: var(--text-dim);
  white-space: nowrap;
}
.cmd-none {
  padding: 8px 10px;
  color: var(--text-dim);
  font-size: 13px;
}
.tb-status {
  display: flex;
  align-items: center;
  gap: 2px;
}
.status-btn {
  display: flex;
  align-items: center;
  height: 32px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
}
.status-btn:hover,
.status-btn[aria-expanded=true] {
  background: var(--surface);
  color: var(--text);
}
.midi-status,
.sound-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 170px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.midi-status::before,
.sound-status::before {
  content: "";
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--dot, var(--text-dim));
}
.status-sub::before {
  content: "\b7";
  margin: 0 5px;
}
.status-act {
  display: inline-flex;
  margin-left: 6px;
  color: var(--accent-text);
}
.status-act[hidden] {
  display: none;
}
.status-act .icon {
  width: 15px;
  height: 15px;
}
.tb-sep {
  width: 1px;
  height: 20px;
  margin: 0 6px;
  background: var(--line);
}
@media (max-width: 1000px) {
  .brand-name,
  .status-sub,
  .tb-kbd {
    display: none;
  }
  .midi-status,
  .sound-status {
    max-width: 110px;
  }
  .tb-search {
    min-width: 0;
  }
}
.seg {
  display: flex;
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  overflow: hidden;
}
.seg .mode-btn {
  border: 0;
  border-radius: 0;
  height: 28px;
}
.seg .mode-btn + .mode-btn {
  border-left: 1px solid var(--border-soft);
}
.seg-full {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}
.auto-key-label {
  font-size: 12px;
  color: var(--text-muted);
}
.auto-key-label:empty {
  display: none;
}
.workspace {
  flex: 1;
  display: flex;
  align-items: stretch;
  min-height: 0;
}
.work-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.menu-store {
  display: contents;
}
.tabbar {
  display: none;
}
.pop-handle {
  display: none;
}
.pop-sheet .pop-handle {
  display: block;
}
.tab-btn {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}
.tab-btn .icon {
  width: 22px;
  height: 22px;
}
.tab-btn[aria-expanded=true],
.tab-btn.active-mode {
  color: var(--accent-text);
}
.tab-label {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.view-menu.pop-menu {
  width: 300px;
  box-sizing: border-box;
  padding: 12px;
  gap: 8px;
  z-index: 50;
  background: var(--surface);
  border-radius: 10px;
  box-shadow: 0 12px 32px var(--shadow);
  max-height: calc(100vh / var(--zoom, 1) - 80px);
  overflow: auto;
}
.pop-anchor > .pop-menu {
  left: 0;
  right: auto;
  top: calc(100% + 6px);
}
.pop-anchor.pop-end > .pop-menu {
  left: auto;
  right: 0;
}
.choice-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.choice-scroll {
  max-height: 280px;
  overflow: auto;
}
.choice-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  flex: none;
}
.choice-row .icon {
  color: var(--text-muted);
}
.choice-row:hover {
  background: var(--surface-2);
}
.choice-row:disabled {
  color: var(--text-dim);
  cursor: default;
  background: transparent;
}
.choice-row[aria-pressed=true] {
  background: var(--surface-2);
  color: var(--text-strong);
  font-weight: 600;
}
.choice-row[aria-pressed=true]::after {
  content: "\2713";
  margin-left: auto;
  color: var(--accent-text);
}
.choice-row.active-mode {
  background: var(--surface-2);
  color: var(--accent-text);
}
.choice-row.active-mode .icon {
  color: var(--accent-text);
}
.choice-hint {
  margin-left: auto;
  font-size: 12px;
  color: var(--text-dim);
  white-space: nowrap;
}
.choice-group {
  font-size: 11px;
  color: var(--text-dim);
  padding: 8px 10px 2px;
}
.sound-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.play-btn {
  flex: none;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.view-menu.key-menu {
  width: 340px;
}
.key-menu-top {
  display: flex;
  align-items: center;
  gap: 10px;
}
.key-pick-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
}
.choice-chip {
  height: 34px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.choice-chip:hover {
  border-color: var(--border);
}
.choice-chip.active-mode {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}
.audio-progress {
  position: relative;
  width: 100%;
  height: 18px;
  background: var(--surface);
  border-radius: 4px;
  overflow: hidden;
}
.audio-progress-fill {
  position: absolute;
  inset: 0;
  width: 0%;
  background: var(--warn);
  border-radius: 4px;
  transition: none;
  opacity: .55;
}
.audio-status {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 10px;
  color: var(--text);
  white-space: nowrap;
  pointer-events: none;
}
.ctrl-btn {
  min-height: 30px;
  background: transparent;
  color: var(--text-soft);
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  padding: 0 10px;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.ctrl-select.invalid {
  border-color: var(--danger);
}
.volume-slider {
  flex: 1;
  min-width: 0;
  height: 4px;
  accent-color: var(--accent);
  cursor: pointer;
  vertical-align: middle;
}
.grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-auto-rows: var(--row, 30px);
  gap: 10px;
  padding: 10px;
}
.module {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  position: relative;
  background: var(--surface-2);
  border-radius: 8px;
}
.module-hidden {
  display: none;
}
.module-moving {
  outline: 2px solid var(--accent);
  z-index: 2;
  box-shadow: 0 6px 20px var(--shadow);
}
.module-menu-open {
  z-index: 30;
}
.module-header {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 8px 2px 14px;
  flex-shrink: 0;
  min-height: 34px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-soft);
  cursor: grab;
  user-select: none;
  touch-action: none;
  border-radius: 8px 8px 0 0;
}
.module-moving .module-header {
  cursor: grabbing;
}
.module-title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1 1 auto;
  min-width: 0;
  align-self: stretch;
  display: flex;
  align-items: center;
}
.module-more,
.module-close {
  width: 28px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: none;
  border: 0;
  border-radius: 6px;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 17px;
  line-height: 1;
  padding: 0;
}
.module-more:hover,
.module-close:hover,
.module-more[aria-expanded=true] {
  color: var(--text);
  background: var(--surface);
}
.module-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 4px 14px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  container-type: size;
}
.module-resize {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 16px;
  height: 16px;
  cursor: nwse-resize;
  touch-action: none;
  opacity: 0;
  border-radius: 0 0 8px 0;
  transition: opacity .15s;
  background:
    linear-gradient(
      135deg,
      transparent 50%,
      var(--border) 50%,
      var(--border) 60%,
      transparent 60%,
      transparent 75%,
      var(--border) 75%,
      var(--border) 85%,
      transparent 85%);
}
.module:hover .module-resize,
.module-moving .module-resize,
.module-resize:focus-visible {
  opacity: 1;
}
.fit {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.fit > svg,
.fit > div {
  width: 100%;
  height: 100%;
}
#guitar-container {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.module-history .module-body,
.module-song .module-body {
  padding: 0 0 4px;
}
.module-menu {
  position: absolute;
  top: 36px;
  right: 8px;
  z-index: 5;
  min-width: 230px;
  max-width: min(360px, calc(100vw - 32px));
  max-height: 70vh;
  overflow-y: auto;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--bg-bar);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  box-shadow: 0 10px 28px var(--shadow);
  font-size: 13px;
  font-weight: 400;
  cursor: default;
}
.module-menu[hidden] {
  display: none;
}
.menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 32px;
  padding: 4px 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.menu-item:hover:not(:disabled) {
  background: var(--surface);
  color: var(--text);
}
.menu-item.menu-action {
  color: var(--accent-text);
}
.menu-item:disabled {
  cursor: default;
  opacity: .5;
}
.menu-check {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  border-radius: 4px;
  border: 1px solid var(--border);
  position: relative;
}
.menu-item.active .menu-check,
.menu-item[aria-pressed=true] .menu-check {
  background: var(--accent);
  border-color: var(--accent);
}
.menu-item.active .menu-check::after,
.menu-item[aria-pressed=true] .menu-check::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 4px;
  height: 9px;
  border: solid var(--on-accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.menu-cycle .menu-check {
  border-radius: 50%;
}
.menu-label {
  flex: 1;
  min-width: 0;
}
.menu-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 2px 6px 2px 10px;
  color: var(--text-soft);
}
.menu-step {
  width: 30px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 15px;
  cursor: pointer;
}
.menu-step:hover {
  border-color: var(--border);
}
.menu-value {
  min-width: 4.6em;
  text-align: center;
  font-size: 12px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.pref-items .menu-row .menu-label {
  flex: 1;
}
.menu-heading {
  padding: 8px 10px 2px;
  font-size: 12px;
  color: var(--text-muted);
}
.menu-sep {
  height: 1px;
  margin: 4px 6px;
  background: var(--line);
}
.menu-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
}
:is(.module-chord, .module-staff, .module-cof, .module-piano, .module-iso, .module-velocity) .module-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1;
  opacity: 0;
  transition: opacity .15s;
  background: var(--surface-2);
}
:is(.module-chord, .module-staff, .module-cof, .module-piano, .module-iso, .module-velocity):is(:hover, :focus-within, .module-moving, .module-menu-open) .module-header {
  opacity: 1;
}
.module-chord .module-body {
  justify-content: center;
  padding: 10px 24px;
}
.module-chord .chord-name-badge,
.module-chord .chord-head-name {
  font-size: clamp(26px, 52cqh, 40vh);
}
.module-chord .chord-notes {
  font-size: clamp(13px, 14cqh, 5vh);
}
@container (max-width: 700px) {
  .chord-head {
    gap: 4px 14px;
    align-content: center;
  }
  .chord-head-from {
    display: none;
  }
  .chord-head-alts {
    margin-left: 0;
  }
  .chord-roman {
    font-size: 20px;
  }
  .module-chord .chord-name-badge,
  .module-chord .chord-head-name {
    font-size: clamp(22px, 30cqh, 40vh);
  }
  .module-chord .chord-notes {
    font-size: 13px;
  }
  .module-chord .chord-card {
    font-size: 13px;
    line-height: 1.15;
    gap: 0 10px;
  }
}
@media (max-width: 720px) {
  .grid {
    display: flex;
    flex-direction: column;
  }
  .module {
    height: calc(var(--h) * 30px + (var(--h) - 1) * 10px);
    flex-shrink: 0;
  }
  .module-chord {
    height: auto;
    min-height: calc(var(--h) * 30px + (var(--h) - 1) * 10px);
  }
  .module-chord .module-body {
    container-type: inline-size;
  }
  .module-chord .chord-name-badge,
  .module-chord .chord-head-name {
    font-size: 44px;
  }
  .module-chord .chord-notes {
    font-size: 15px;
  }
  .grid .module-history .history-strip {
    font-size: 13px;
  }
  #key-container :is(.key-main, .key-parallel) {
    min-width: 0;
    max-width: 100%;
  }
  #key-container .key-grid {
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.2em;
  }
  #key-container .key-cell {
    min-width: 0;
  }
  #key-container .key-chord {
    padding: 0.3em 0.15em;
    font-size: 0.9em;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
  }
  #key-container {
    justify-content: stretch;
  }
  #key-container .key-main {
    width: 100%;
  }
  #key-container .key-mode-row {
    flex-wrap: wrap;
  }
  :is(.module-chord, .module-staff, .module-cof, .module-piano, .module-iso, .module-velocity) .module-header {
    opacity: 1;
    position: static;
  }
  .toolbar {
    padding: 8px 10px;
    flex-wrap: wrap;
    gap: 6px 8px;
  }
  .brand-name,
  .status-sub,
  .tb-kbd {
    display: none;
  }
  .tb-search {
    order: 10;
    flex: 1 1 100%;
    margin: 0;
  }
  .midi-status,
  .sound-status {
    max-width: 92px;
  }
  .tb-page {
    display: none !important;
  }
  .work-main {
    padding-bottom: calc(60px + env(safe-area-inset-bottom));
  }
  .tabbar {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 56;
    height: calc(60px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    box-sizing: border-box;
    background: var(--bg-bar);
    border-top: 1px solid var(--line);
  }
  .view-menu.pop-menu.pop-sheet {
    position: fixed;
    left: 0;
    right: 0;
    top: auto;
    bottom: calc(60px + env(safe-area-inset-bottom));
    z-index: 55;
    width: auto;
    max-height: 75vh;
    padding: 0 16px 16px;
    gap: 10px;
    border-radius: 16px 16px 0 0;
    background: var(--bg-bar);
    border: 0;
    box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .6);
    transition: transform .15s;
  }
  .pop-handle {
    flex: none;
    position: sticky;
    top: 0;
    z-index: 1;
    height: 22px;
    margin: 0 -16px;
    touch-action: none;
    background: var(--bg-bar);
    cursor: grab;
  }
  .pop-handle::after {
    content: "";
    display: block;
    width: 36px;
    height: 4px;
    margin: 9px auto 0;
    border-radius: 2px;
    background: var(--border);
  }
  .pop-sheet .view-menu-title {
    font-size: 13px;
    margin-top: 4px;
  }
  .pop-sheet .choice-row {
    min-height: 48px;
    font-size: 15px;
  }
  .pop-sheet .choice-scroll {
    max-height: 40vh;
  }
  .pop-sheet .mode-btn {
    height: 40px;
    font-size: 14px;
  }
  .pop-sheet .ctrl-btn {
    min-height: 40px;
    font-size: 14px;
  }
  .pop-sheet .view-menu-export {
    font-size: 15px;
    color: var(--text-soft);
  }
  .pop-sheet .view-menu-export .ctrl-btn {
    min-width: 64px;
  }
  .pop-sheet #menu-keyboard,
  .pop-sheet .view-menu-hint,
  .pop-sheet .layout-save-row {
    display: none;
  }
  .pop-sheet .layout-modules {
    grid-template-columns: 1fr;
    gap: 0;
    font-size: 15px;
    color: var(--text);
  }
  .pop-sheet .layout-module {
    flex-direction: row-reverse;
    justify-content: space-between;
    min-height: 46px;
    border-bottom: 1px solid var(--line);
  }
  .pop-sheet .layout-module input {
    appearance: none;
    -webkit-appearance: none;
    position: relative;
    width: 36px;
    height: 20px;
    margin: 0;
    flex-shrink: 0;
    border-radius: 10px;
    background: var(--border);
    cursor: pointer;
    transition: background .15s;
  }
  .pop-sheet .layout-module input::before {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--text-soft);
    transition: transform .15s;
  }
  .pop-sheet .layout-module input:checked {
    background: var(--accent);
  }
  .pop-sheet .layout-module input:checked::before {
    transform: translateX(16px);
    background: var(--on-accent);
  }
  :is(.module-analysis, .module-explain, .module-key, .module-progressions, .module-ear, .module-history, .module-song) .module-body {
    container-type: inline-size;
  }
  .module-header {
    cursor: default;
  }
  .module-resize {
    display: none;
  }
}
body.presenting {
  overflow: hidden;
}
body.presenting .toolbar,
body.presenting #midi-banner,
body.presenting .module-header,
body.presenting .module-resize,
body.presenting .module-menu,
body.presenting .guitar-chrome,
body.presenting .chord-head-alts {
  display: none !important;
}
body.presenting .grid {
  height: calc(100vh / var(--zoom, 1));
}
body.presenting.presenting-scroll {
  overflow: auto;
}
body.presenting.presenting-scroll .grid {
  height: auto;
}
html:has(> body.layout-window),
body.layout-window {
  background: var(--window-bg);
}
body.layout-window.panels-clear .module {
  background: transparent;
  text-shadow: 0 0 3px var(--glow);
}
body.layout-window.panels-clear .module svg {
  filter: drop-shadow(0 0 1px var(--glow));
}
#analysis-content {
  display: flex;
  flex-direction: column;
  gap: 0.45em;
  flex-shrink: 0;
}
#key-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.2em 2em;
  justify-content: center;
  align-items: flex-start;
}
.key-main {
  display: flex;
  flex-direction: column;
  gap: 0.35em;
}
.key-parallel {
  display: flex;
  flex-direction: column;
  gap: 0.35em;
}
.key-mode-grid {
  display: flex;
  flex-direction: column;
  gap: 0.3em;
}
.key-empty {
  color: var(--text-dim);
  font-size: 0.95em;
  max-width: 16em;
}
.key-title {
  font-size: 1.15em;
  font-weight: 600;
  color: var(--text);
}
.key-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(4.2em, 1fr));
  gap: 0.3em;
}
.key-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15em;
}
.key-roman {
  font-size: 0.85em;
  color: var(--text-muted);
  white-space: nowrap;
}
.key-chord {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-soft);
  border-bottom: 3px solid var(--border-soft);
  border-radius: 6px;
  padding: 0.2em 0.5em;
  font: inherit;
  font-size: 1em;
  cursor: pointer;
  white-space: nowrap;
}
.key-chord.key-fnb-T {
  border-bottom-color: var(--fn-t);
}
.key-chord.key-fnb-S {
  border-bottom-color: var(--fn-s);
}
.key-chord.key-fnb-D {
  border-bottom-color: var(--fn-d);
}
.key-chord:hover {
  border-top-color: var(--border);
  border-left-color: var(--border);
  border-right-color: var(--border);
}
.key-chord.active {
  outline: 2px solid var(--cursor);
  outline-offset: 1px;
}
.key-function {
  font-size: 0.8em;
  color: var(--text-dim);
}
.key-fn-T {
  color: var(--fn-t);
}
.key-fn-S {
  color: var(--fn-s);
}
.key-fn-D {
  color: var(--fn-d);
}
.key-section-label {
  font-size: 0.85em;
  color: var(--text-dim);
  margin-top: 0.3em;
}
.key-mode-row {
  display: flex;
  gap: 0.5em;
  align-items: flex-end;
}
.key-mode-name {
  font-size: 0.85em;
  color: var(--text-muted);
  min-width: 7.5em;
  flex-shrink: 0;
  padding-bottom: 0.25em;
}
.key-mode-chords {
  display: flex;
  gap: 0.3em;
}
.key-mode-chord {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1em;
}
.key-axis {
  font-size: 0.95em;
  color: var(--text);
}
@container (min-width: 820px) {
  #key-container {
    display: block;
    columns: 2;
    column-gap: 2.4em;
  }
  #key-container .key-main {
    break-inside: avoid;
    margin-bottom: 1.2em;
  }
  #key-container .key-parallel,
  #key-container .key-mode-grid {
    display: block;
  }
  #key-container .key-mode-row {
    break-inside: avoid;
    margin-bottom: 0.3em;
  }
}
.chord-head {
  display: flex;
  align-items: center;
  gap: 10px 28px;
  flex-wrap: wrap;
  min-height: 100%;
}
.chord-head-empty {
  color: var(--text-muted);
  font-size: 15px;
  justify-content: center;
}
.chord-head-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.chord-head-main {
  align-items: baseline;
  gap: 16px;
}
.chord-name-badge,
.chord-head-name {
  font-size: 64px;
  font-weight: 700;
  line-height: 1.05;
  color: var(--text-strong);
}
.chord-notes {
  font-size: 15px;
  color: var(--text-muted);
}
.chord-roman {
  font-size: 30px;
  font-weight: 700;
  color: var(--text);
}
.chord-head-label {
  font-size: 12px;
  color: var(--text-muted);
}
.chord-head-from {
  font-size: 14px;
  color: var(--text-soft);
  gap: 8px;
}
.chord-head-prev {
  font-weight: 600;
}
.chord-head-prev-roman {
  font-weight: 600;
}
.chord-head-alts {
  margin-left: auto;
  gap: 6px;
}
.chord-card {
  display: grid;
  grid-template-columns: max-content max-content;
  justify-content: start;
  gap: 2px 10px;
  align-items: baseline;
  font-size: 14px;
}
.chord-card-label {
  font-size: 12px;
  color: var(--text-muted);
}
.chord-card-value {
  color: var(--text);
  white-space: nowrap;
}
.fn-T {
  color: var(--fn-t);
}
.fn-S {
  color: var(--fn-s);
}
.fn-D {
  color: var(--fn-d);
}
.fn-pill {
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid currentColor;
  font-size: 13px;
  font-weight: 600;
}
.cadence-pill {
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px dashed var(--cadence-text);
  color: var(--cadence-text);
  font-size: 12px;
}
.alt-chord-btn {
  height: 30px;
  padding: 0 12px;
  border-radius: 6px;
  background: transparent;
  color: var(--text-soft);
  border: 1px solid var(--border-soft);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
}
.alt-chord-btn:hover {
  border-color: var(--border);
  color: var(--text);
}
.analysis-row {
  display: flex;
  gap: 0.5em;
  align-items: baseline;
}
.analysis-label {
  font-size: 0.86em;
  color: var(--text-muted);
  min-width: 6.5em;
  flex-shrink: 0;
}
.analysis-value {
  font-size: 1em;
  overflow-wrap: break-word;
  white-space: pre-line;
}
.strings-tabs {
  display: flex;
  gap: 2px;
  flex: none;
}
.strings-tab {
  height: 26px;
  padding: 0 9px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.strings-tab:hover {
  color: var(--text);
}
.strings-tab[aria-pressed=true] {
  background: var(--surface);
  color: var(--text-strong);
}
.strings-systems {
  margin-top: 2px;
}
.strings-systems .strings-tab {
  height: 22px;
  padding: 0 7px;
  font-size: 12px;
}
.strings-stage {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  gap: 4px;
}
.strings-drawing {
  flex: 1;
  min-width: 0;
  height: 100%;
}
.strings-drawing > svg,
.strings-drawing > div > svg {
  width: 100%;
  height: 100%;
}
.guitar-nav {
  flex: none;
  width: 36px;
  height: min(120px, 60%);
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 26px;
  cursor: pointer;
}
.guitar-nav:hover {
  background: var(--surface);
  color: var(--text);
}
@media (pointer: coarse) {
  .guitar-nav {
    background: var(--surface);
  }
}
.strings-foot {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding-top: 8px;
}
.strings-dots {
  display: flex;
  justify-content: center;
  gap: 5px;
}
.strings-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--border);
}
.strings-dot.on {
  background: var(--accent);
}
.strings-count {
  font-size: 12px;
  color: var(--text-muted);
}
.strings-caption {
  border: 0;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.strings-caption:hover {
  color: var(--text);
  background: var(--surface);
}
#guitar-container.strings-bare .guitar-chrome {
  display: none;
}
.guitar-placeholder {
  opacity: 0.35;
  height: 100%;
}
.no-voicing {
  flex: 1;
  font-size: 12px;
  color: var(--text-dim);
  text-align: center;
  padding: 16px;
}
.menu-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 2px 4px 4px;
}
.menu-chip {
  height: 28px;
  padding: 0 9px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.menu-chip:hover {
  border-color: var(--border);
}
.menu-chip[aria-pressed=true] {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}
.strings-inputs {
  display: grid;
  gap: 4px;
  padding: 2px 4px 4px;
}
.guitar-string-input,
.set-string {
  height: 28px;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
  text-align: center;
  font: inherit;
  font-size: 12px;
}
.guitar-string-input.invalid {
  border-color: var(--danger);
}
.history-wrap {
  display: flex;
  gap: 8px;
  align-items: center;
}
.history-rhythm {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  cursor: help;
}
.history-strip {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 8px 12px;
  align-items: center;
}
.history-chip,
.prog-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--surface);
  border: 1.5px solid var(--border-soft);
  cursor: pointer;
  min-width: 50px;
  user-select: none;
}
.history-chip-symbol,
.prog-chip-symbol {
  font-size: 12px;
  font-weight: 600;
}
.history-cadence {
  font-size: 10px;
  color: var(--cadence-text);
  white-space: nowrap;
  padding: 1px 5px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  margin: 0 -2px;
  flex-shrink: 0;
}
.history-modulation {
  font-size: 10px;
  font-weight: 600;
  color: var(--modulation-text);
  white-space: nowrap;
  padding: 1px 6px;
  border: 1px solid var(--modulation-border);
  border-radius: 3px;
  margin: 0 -2px;
  flex-shrink: 0;
}
.history-chip-roman,
.prog-chip-roman {
  font-size: 10px;
  color: var(--text-muted);
}
.module-history .history-strip {
  font-size: clamp(12px, min(19cqh, 3.2cqw), 6vh);
}
.module-history .history-chip-symbol {
  font-size: 1em;
}
.module-history :is(.history-chip-roman, .history-cadence, .history-modulation) {
  font-size: 0.8em;
}
.module-history .history-chip {
  min-width: 4.2em;
  padding: 0.33em 0.66em;
}
.history-clear-btn,
.history-send-btn {
  padding: 4px 10px;
  border-radius: 4px;
  background: var(--btn-neutral);
  color: var(--on-neutral);
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}
.song-root {
  padding: 4px 4px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.song-header {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.song-title-wrap {
  display: flex;
  align-items: center;
  gap: 2px;
}
.song-tabs {
  display: flex;
  gap: 2px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  scrollbar-width: thin;
}
.song-tab {
  flex: none;
  max-width: 16em;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px 6px 0 0;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}
.song-tab:hover {
  color: var(--text);
  background: var(--surface);
}
.song-tab[aria-selected=true] {
  color: var(--text-strong);
  background: var(--surface);
  border-bottom-color: var(--accent);
  font-weight: 600;
}
.song-tab-new {
  padding: 0 12px;
  font-size: 16px;
}
.song-title-input {
  font: inherit;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-strong);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 2px 6px;
  min-width: 6em;
  max-width: 22em;
  field-sizing: content;
}
.song-title-input:hover {
  border-color: var(--border-soft);
}
.song-title-input:focus {
  border-color: var(--accent);
  outline: none;
}
.song-more-btn {
  height: 32px;
  min-width: 32px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 16px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.song-more-btn:hover,
.song-more-btn[aria-expanded=true] {
  background: var(--surface);
  color: var(--text);
}
.song-form-info {
  font-size: 13px;
  color: var(--text-dim);
}
.song-gap {
  flex: 1;
}
.song-btn {
  height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.song-btn:hover,
.song-btn[aria-expanded=true] {
  background: var(--btn-neutral);
}
.song-btn-main {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}
.song-btn-main:hover {
  background: var(--accent-soft);
}
.view-menu.song-menu {
  width: 260px;
}
.song-menu .menu-chips {
  padding: 0;
}
.song-menu .menu-chip {
  background: var(--surface-2);
}
.song-danger {
  color: var(--danger-text);
}
.section-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex: none;
}
.song-empty {
  margin: 8px 0;
  color: var(--text-dim);
  font-size: 13px;
}
.paste-area {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}
.paste-area[hidden] {
  display: none;
}
.paste-textarea {
  width: 100%;
  box-sizing: border-box;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 8px 10px;
  font-family: ui-monospace, monospace;
  font-size: 14px;
  resize: vertical;
}
.paste-textarea:focus {
  border-color: var(--accent);
  outline: none;
}
.song-strip {
  display: flex;
  gap: 4px;
  height: 34px;
}
.strip-block {
  flex-basis: 0;
  min-width: 64px;
  display: flex;
  border-radius: 6px;
  background: var(--surface);
  border-top: 3px solid var(--border);
  cursor: grab;
  overflow: hidden;
}
.strip-block.in-play {
  outline: 2px solid var(--accent);
  outline-offset: -1px;
}
.strip-block.dragging {
  opacity: .4;
}
.strip-block.drop-before {
  box-shadow: inset 3px 0 0 var(--accent);
}
.strip-block.drop-after {
  box-shadow: inset -3px 0 0 var(--accent);
}
.strip-go {
  flex: 1;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  text-align: left;
  padding: 0 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.strip-go b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.strip-go span {
  font-size: 11px;
  color: var(--text-dim);
}
.strip-add {
  width: 34px;
  height: 100%;
  border: 1px dashed var(--border);
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
}
.strip-add:hover {
  color: var(--text);
  border-color: var(--text-dim);
}
.section-wrap {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  border-radius: 6px;
}
.section-wrap.section-flash {
  background: var(--surface);
  transition: background .3s;
}
.section-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 4px 0 4px 10px;
  border-left: 3px solid var(--border);
}
.section-name-row {
  display: flex;
  align-items: center;
  gap: 2px;
}
.section-toggle {
  border: 0;
  background: transparent;
  color: var(--text-dim);
  font-size: 12px;
  cursor: pointer;
  padding: 0 2px;
}
.section-name-input {
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  background: transparent;
  width: 100%;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 1px 4px;
}
.section-name-input:hover {
  border-color: var(--border-soft);
}
.section-name-input:focus {
  border-color: var(--accent);
  outline: none;
}
.section-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  opacity: .45;
  transition: opacity .15s;
}
.section-wrap:hover .section-tools,
.section-tools:focus-within {
  opacity: 1;
}
.section-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}
.section-repeat-badge {
  font: inherit;
  font-size: 11px;
  color: var(--text-muted);
  cursor: pointer;
  background: var(--surface-2);
  border: 0;
  border-radius: 4px;
  padding: 2px 6px;
}
.section-repeat-input {
  width: 42px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--accent);
  border-radius: 4px;
  padding: 1px 4px;
  font-size: 11px;
}
.song-btn-small {
  padding: 2px 6px;
  border-radius: 4px;
  background: transparent;
  color: var(--text-muted);
  border: 0;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
}
.song-btn-small:hover {
  background: var(--surface);
  color: var(--text);
}
.section-write {
  display: flex;
  width: fit-content;
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  overflow: hidden;
}
.section-write-btn {
  height: 24px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}
.section-write-btn + .section-write-btn {
  border-left: 1px solid var(--border-soft);
}
.section-write-btn[aria-pressed=true] {
  background: var(--surface);
  color: var(--text-strong);
}
.section-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
}
.section-add-bar {
  height: 28px;
  padding: 0 10px;
  border: 1px dashed var(--border);
  border-radius: 6px;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.section-add-bar:hover {
  color: var(--text);
}
.measures-wrap {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: 100%;
  border-left: 1px solid var(--border);
}
@container (max-width: 640px) {
  .measures-wrap {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.measure-row {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 14px 8px 6px;
  border-right: 1px solid var(--border);
}
.measure-row.measure-last {
  border-right: 3px double var(--border);
}
.measure-num {
  position: absolute;
  left: 6px;
  top: 2px;
  font-size: 10px;
  color: var(--text-dim);
}
.measure-del {
  position: absolute;
  right: 2px;
  top: 0;
  opacity: 0;
  padding: 0 4px;
  font-size: 11px;
}
.measure-row:hover .measure-del,
.measure-del:focus-visible {
  opacity: 1;
}
.chords-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  min-width: 0;
}
.chords-row.drop-target {
  outline: 1px dashed var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
.chord-drop-indicator {
  width: 2px;
  min-height: 40px;
  background: var(--accent);
  border-radius: 2px;
  pointer-events: none;
  align-self: stretch;
  flex-shrink: 0;
}
.chord-add-btn {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  border: 1px dashed var(--border);
  cursor: pointer;
  font-size: 16px;
  opacity: 0;
  transition: opacity .15s;
}
.measure-row:hover .chord-add-btn,
.chord-add-btn:focus-visible,
.chords-row:not(:has(.chord-chip)) .chord-add-btn {
  opacity: 1;
}
@media (pointer: coarse) {
  .chord-add-btn {
    opacity: 1;
  }
}
.chord-chip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 44px;
  padding: 4px 10px;
  border-radius: 6px;
  background: var(--surface);
  cursor: pointer;
  border: 1px solid transparent;
  border-left: 3px solid var(--border);
}
.chord-chip:hover {
  border-top-color: var(--border);
  border-right-color: var(--border);
  border-bottom-color: var(--border);
}
.chord-chip.invalid {
  border-color: var(--danger);
}
.chord-chip.capture-target {
  border: 1px dashed var(--accent);
  border-left-width: 3px;
}
.chord-chip.active-cursor,
.history-chip.active-cursor {
  border-color: var(--cursor);
}
.chord-chip.playing {
  border-color: var(--cursor);
  background: var(--surface-2);
}
.song-tempo-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  white-space: nowrap;
}
.song-tempo-input {
  font: inherit;
  width: 4.5em;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  padding: 2px 6px;
}
.song-tempo-input:focus {
  border-color: var(--accent);
  outline: none;
}
.chord-chip-symbol {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}
.chord-chip-degree {
  font-size: 11px;
  color: var(--text-dim);
  margin-top: 1px;
}
.chord-chip-controls {
  display: none;
  position: absolute;
  top: -32px;
  left: 0;
  z-index: 5;
  gap: 2px;
  padding: 3px;
  background: var(--surface);
  border-radius: 6px;
  box-shadow: 0 6px 16px var(--shadow);
}
.chord-chip-controls .song-btn-small {
  width: 26px;
  height: 24px;
  padding: 0;
}
.chord-input {
  width: 56px;
  background: transparent;
  border: none;
  color: var(--text);
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  outline: none;
}
.section-text {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}
.section-text-input {
  height: 40px;
  padding: 0 12px;
  border-radius: 8px;
  background: var(--bg);
  border: 1px solid var(--border-soft);
  color: var(--text-strong);
  font-family: ui-monospace, monospace;
  font-size: 15px;
  letter-spacing: .02em;
}
.section-text-input:focus {
  border-color: var(--accent);
  outline: none;
}
.section-text-status {
  font-size: 12px;
  color: var(--fn-t);
  min-height: 1.2em;
}
.section-text-status.bad {
  color: var(--danger-text);
}
.section-text-hint {
  font-size: 12px;
  color: var(--text-dim);
}
@media (max-width: 720px) {
  .section-wrap {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
  }
  .song-strip {
    flex-wrap: wrap;
  }
}
.song-notice {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 12px;
  margin-bottom: 6px;
  color: var(--text);
  background: var(--notice);
}
.song-notice.warn {
  background: var(--banner-warn);
}
.song-notice-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 14px;
  margin-left: 8px;
  padding: 0;
}
.color-picker-popup {
  position: fixed;
  z-index: 1000;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px;
  display: flex;
  gap: 4px;
  box-shadow: 0 4px 12px var(--shadow);
}
.color-picker-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
}
.undo-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 1100;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px 8px 14px;
  font-size: 12px;
  color: var(--text);
  box-shadow: 0 6px 24px var(--shadow);
}
.undo-btn {
  background: var(--violet);
  border: 1px solid var(--violet);
  border-radius: 4px;
  color: var(--on-accent);
  cursor: pointer;
  font-size: 12px;
  padding: 3px 12px;
}
.undo-btn:hover {
  background: var(--violet-hover);
}
@keyframes audio-missed {
  0%, 100% {
    box-shadow: none;
  }
  50% {
    box-shadow: 0 0 0 2px var(--warn);
  }
}
.audio-progress.missed {
  animation: audio-missed 0.35s ease-in-out 2;
}
.shortcut-help-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1000;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  box-shadow: 0 6px 24px var(--shadow);
  min-width: 240px;
  max-width: min(560px, calc((100vw - 24px) / var(--zoom, 1)));
  max-height: calc((100vh - 32px) / var(--zoom, 1));
  overflow-y: auto;
}
.shortcut-help-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.shortcut-help-close {
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  padding: 0;
}
.shortcut-help-close:hover {
  color: var(--text);
}
.shortcut-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 3px 0;
}
.shortcut-key {
  font-family: monospace;
  font-size: 11px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1px 7px;
  min-width: 46px;
  text-align: center;
  flex-shrink: 0;
}
.shortcut-action {
  font-size: 11px;
  color: var(--text-muted);
}
.shortcut-section {
  margin: 12px 0 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.gesture-row {
  font-size: 11px;
  color: var(--text-muted);
  padding: 2px 0;
  max-width: 340px;
}
.help-setting {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: var(--text-soft);
  padding: 3px 0;
  max-width: 340px;
}
@media (max-width: 720px) {
  .shortcut-help-popup {
    inset: 0;
    transform: none;
    max-width: none;
    max-height: none;
    border: 0;
    border-radius: 0;
    padding: 0 20px 24px;
  }
  .shortcut-help-header {
    position: sticky;
    top: 0;
    z-index: 1;
    margin: 0 -20px 4px;
    padding: 14px 12px 14px 20px;
    background: var(--bg-bar);
    border-bottom: 1px solid var(--line);
    font-size: 17px;
    text-transform: none;
    letter-spacing: 0;
    color: var(--text-strong);
  }
  .shortcut-help-close {
    width: 40px;
    height: 40px;
    font-size: 22px;
  }
  .shortcut-section {
    margin: 20px 0 8px;
    font-size: 13px;
  }
  .gesture-row {
    font-size: 15px;
    line-height: 1.45;
    color: var(--text-soft);
    padding: 6px 0;
    max-width: none;
  }
  .help-setting {
    max-width: none;
    padding: 12px 0;
  }
}
@keyframes pulse-border {
  0%, 100% {
    border-color: var(--accent);
  }
  50% {
    border-color: var(--accent-soft);
  }
}
.capture-target {
  animation: pulse-border 0.8s infinite;
}
#piano-container circle,
#piano-container text {
  pointer-events: none;
}
#iso-container {
  overflow: hidden;
}
.view-menu-wrap {
  position: relative;
}
.view-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  z-index: 20;
  flex-direction: column;
  gap: 4px;
  padding: 8px;
  width: 220px;
  background: var(--bg-bar);
  border: 1px solid var(--border-soft);
  border-radius: 6px;
}
.view-menu.open {
  display: flex;
}
.view-menu-title {
  font-size: 11px;
  color: var(--text-muted);
}
.window-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.choice-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.choice-chip[aria-pressed=true] {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}
.menu-export {
  width: auto;
  padding: 0 8px;
  font-size: 12px;
}
.view-menu-hint {
  font-size: 10px;
  color: var(--text-dim);
  line-height: 1.4;
}
.view-menu-export {
  display: flex;
  gap: 4px;
  align-items: center;
  font-size: 11px;
  color: var(--text-muted);
}
.view-menu-export span {
  flex: 1;
}
.view-menu .ctrl-btn.invalid {
  border-color: var(--danger);
}
body.view-mode {
  overflow: hidden;
}
body.view-mode .guitar-chrome {
  display: none;
}
#view-content {
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3vmin;
}
#view-content > * {
  max-width: 100%;
  max-height: 100%;
}
.view-chord {
  flex-direction: column;
  gap: 2vmin;
  font-family: system-ui, sans-serif;
  text-align: center;
}
.view-chord-name {
  font-size: 34vmin;
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 0 1.2vmin var(--glow);
}
.view-chord-detail {
  font-size: 10vmin;
  color: var(--text);
  text-shadow: 0 0 1vmin var(--glow);
}
.view-guitar > :not(.strings-stage) {
  display: none !important;
}
.view-guitar > .strings-stage {
  width: 100%;
  height: 100%;
}
.view-staff > div {
  width: 100%;
  height: 100%;
}
#velocity-container {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-height: 40px;
}
.vel-row {
  display: grid;
  grid-template-columns: 34px 1fr 26px;
  gap: 6px;
  align-items: center;
  font-size: 11px;
  color: var(--text-muted);
}
.vel-note {
  color: var(--text-soft);
}
.vel-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.vel-bar {
  height: 8px;
  background: var(--surface);
  border-radius: 2px;
  overflow: hidden;
}
.vel-bar > span {
  display: block;
  height: 100%;
  background: var(--velocity-bar);
}
.vel-empty {
  font-size: 10px;
  color: var(--text-dim);
  line-height: 1.4;
}
.key-chord.key-alt {
  font-size: .85em;
  opacity: .85;
  margin-top: 2px;
}
.key-chord.key-characteristic {
  font-weight: 700;
  color: var(--text-strong);
}
.layout-presets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}
.layout-saved-row {
  display: flex;
  gap: 4px;
}
.layout-saved-row > :first-child {
  flex: 1;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.layout-save-row {
  display: flex;
  gap: 4px;
}
.layout-save-row input {
  flex: 1;
  min-width: 0;
}
.layout-save-row input.invalid {
  border-color: var(--danger);
}
.layout-modules {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 8px;
  font-size: 11px;
  color: var(--text-soft);
}
.layout-module {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}
.staff-prev {
  opacity: .4;
}
#explain-container {
  font-size: 14px;
  line-height: 1.5;
  overflow-y: auto;
}
.explain-list {
  margin: 0;
}
.explain-list dt {
  font-weight: 600;
  color: var(--accent-text);
  margin-top: .7em;
}
.explain-list dt:first-child {
  margin-top: 0;
}
.explain-list dd {
  margin: .1em 0 0;
  color: var(--text-soft);
}
.explain-empty {
  color: var(--text-muted);
  margin: 0;
}
.next-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.next-row {
  display: grid;
  grid-template-columns: auto 3.5em 1fr;
  gap: 8px;
  align-items: baseline;
}
.next-why {
  display: flex;
  flex-direction: column;
  color: var(--text-soft);
}
.next-reason[title] {
  cursor: help;
}
.next-empty {
  color: var(--text-muted);
  margin: 0;
}
.next-alts {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px;
}
.next-alt {
  padding: 0.1em 0.4em;
  font-size: 0.9em;
}
.next-heading {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
  margin: 12px 0 6px;
}
#progressions-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 0;
}
.prog-head {
  display: flex;
  gap: 8px 10px;
  align-items: center;
  flex-wrap: wrap;
}
.prog-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.prog-picks .menu-chip:not([aria-pressed=true]) {
  background: var(--surface);
}
.prog-key {
  font-size: 12px;
  color: var(--text-muted);
}
.prog-about {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: var(--text-soft);
}
.prog-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  padding: 4px 0;
}
.prog-chip {
  font: inherit;
  color: inherit;
}
.prog-chip.playing {
  border-color: var(--cursor);
  background: var(--surface-2);
}
.prog-bar {
  color: var(--text-dim);
  font-size: 14px;
}
#ear-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
}
.ear-head {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-wrap: wrap;
}
.ear-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}
.ear-new {
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: var(--on-accent);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.ear-new:hover {
  background: var(--accent-soft);
}
.ear-score {
  margin-left: auto;
  font-size: 12px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
.ear-prompt {
  margin: 0;
  color: var(--text-soft);
}
.ear-answers {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.ear-answer {
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  cursor: pointer;
}
.ear-answer:hover:not(:disabled) {
  border-color: var(--border);
}
.ear-answer:disabled {
  cursor: default;
  opacity: .5;
}
.ear-answer.ear-correct {
  border-color: var(--fn-t);
  opacity: 1;
}
.ear-answer.ear-missed {
  border-color: var(--fn-d);
  opacity: 1;
}
.ear-feedback {
  margin: 0;
  min-height: 1.4em;
  font-weight: 600;
}
.ear-feedback.ear-right {
  color: var(--fn-t);
}
.ear-feedback.ear-wrong {
  color: var(--fn-d);
}
#player-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
  font-size: 12px;
}
.player-head {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
}
.player-open {
  cursor: pointer;
}
.player-name {
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.player-reading {
  color: var(--text-muted);
  font-size: 12px;
  white-space: nowrap;
}
#metronome-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 0;
}
.metro-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.metro-tempo {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.metro-now {
  color: var(--text-muted);
  font-size: 12px;
}
.metro-label {
  color: var(--text-muted);
  font-size: 12px;
}
.metro-num,
.metro-meter {
  font: inherit;
  width: 4em;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  padding: 2px 6px;
}
.metro-meter {
  width: 7em;
}
.metro-meter.invalid {
  border-color: var(--danger);
}
.metro-num:focus,
.metro-meter:focus {
  border-color: var(--accent);
  outline: none;
}
.metro-trainer-row {
  gap: 6px;
}
.view-menu.metro-pop {
  width: min(460px, 86vw);
  gap: 8px;
}
.metro-recent {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-soft);
}
.metro-pop-cols {
  display: grid;
  grid-template-columns: 9.5em 1fr;
  gap: 8px;
  min-height: 0;
}
.metro-kinds {
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-right: 1px solid var(--border-soft);
  padding-right: 8px;
}
.metro-options {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 300px;
  overflow-y: auto;
}
.metro-options .metro-meter {
  width: 100%;
}
.metro-draft {
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  padding: 4px 0;
}
.metro-stepper {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.metro-step-value {
  min-width: 1.8em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}
.view-menu.metro-sub-pop {
  width: auto;
}
.metro-sub-pop .menu-chips {
  flex-wrap: nowrap;
}
.metro-mode {
  white-space: nowrap;
}
.metro-views {
  margin-left: auto;
}
.metro-viz {
  flex: 1;
  min-height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  transition: background-color 160ms ease-out;
  container-type: size;
}
.metro-viz.flash-strong {
  background: color-mix(in srgb, var(--accent) 28%, transparent);
  transition: none;
}
.metro-viz.flash-accent {
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  transition: none;
}
.metro-necklace {
  width: 100%;
  height: 100%;
  max-height: 100%;
}
.metro-halo {
  fill: none;
  stroke: transparent;
  stroke-width: 4;
}
.flash-strong .metro-halo {
  stroke: var(--accent);
}
.metro-big {
  fill: var(--text-strong);
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: central;
  font-variant-numeric: tabular-nums;
}
.metro-big.accent {
  fill: var(--accent);
}
.metro-pulses {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.metro-big-html {
  font-size: clamp(32px, 38cqh, 140px);
  font-weight: 700;
  line-height: 1;
  color: var(--text-strong);
  font-variant-numeric: tabular-nums;
}
.metro-big-html.accent {
  color: var(--accent);
}
.metro-row {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 14px;
  width: 100%;
  height: clamp(28px, 22cqh, 90px);
}
.metro-group {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 100%;
  flex: 0 1 auto;
}
.metro-block {
  width: clamp(10px, 4cqw, 34px);
  height: 50%;
  border-radius: 4px;
  background: var(--text-dim);
  transition: background-color 60ms;
}
.metro-block.metro-strong {
  height: 100%;
  background: var(--accent);
}
.metro-block.metro-accent {
  height: 78%;
  background: var(--text);
}
.metro-block.metro-khali {
  height: 40%;
  background: none;
  border: 2px solid var(--text-dim);
}
.metro-block.metro-poly {
  height: 70%;
  background: var(--fn-s);
}
.metro-block.metro-rest {
  height: 18%;
  background: var(--border);
}
.metro-viz.running :is(.metro-dot, .metro-block) {
  opacity: .35;
  transition: opacity 80ms;
}
.metro-viz.running :is(.metro-dot, .metro-block).lit {
  opacity: 1;
  transition: none;
}
.metro-dot.lit {
  transform-box: fill-box;
  transform-origin: center;
  transform: scale(1.6);
}
.metro-block.lit {
  background: var(--cursor);
  border-color: var(--cursor);
  transform: scaleY(1.12);
  transform-origin: bottom;
}
.metro-arc {
  fill: none;
  stroke: var(--border);
  stroke-width: 3;
  stroke-linecap: round;
}
.metro-dot {
  fill: var(--text-dim);
  transition: fill 60ms;
}
.metro-strong {
  fill: var(--accent);
}
.metro-accent {
  fill: var(--text);
}
.metro-khali {
  fill: none;
  stroke: var(--text-dim);
  stroke-width: 1.5;
}
.metro-poly {
  fill: var(--fn-s);
}
.metro-rest {
  fill: var(--border);
}
.metro-dot.lit {
  fill: var(--cursor);
  stroke: var(--cursor);
}
.metro-count {
  fill: var(--text-muted);
  font-size: 9px;
  text-anchor: middle;
  dominant-baseline: central;
}
.player-wave {
  width: 100%;
  flex: 1;
  min-height: 40px;
  background: var(--surface);
  border-radius: 4px;
  cursor: pointer;
}
.player-ctrl {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-wrap: wrap;
}
.player-time {
  color: var(--text-soft);
  font-variant-numeric: tabular-nums;
  min-width: 6.5em;
  text-align: center;
}
.player-speed {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.player-speed-value {
  min-width: 3.4em;
  text-align: center;
  font-size: 12px;
  color: var(--text-soft);
  font-variant-numeric: tabular-nums;
}
#tuner-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: stretch;
  font-size: 12px;
}
.tuner-head {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  align-items: center;
}
.tuner-note {
  font-size: 2.4em;
  font-weight: 700;
  text-align: center;
  color: var(--text-strong);
  line-height: 1.1;
}
.tuner-meter {
  position: relative;
  height: 10px;
  border-radius: 5px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
}
.tuner-zero {
  position: absolute;
  left: 50%;
  top: -3px;
  bottom: -3px;
  width: 1px;
  background: var(--text-muted);
}
.tuner-needle {
  position: absolute;
  left: 50%;
  top: -2px;
  width: 4px;
  height: 14px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--fn-s);
  transition: left .08s linear;
}
.tuner-needle.in-tune {
  background: var(--fn-t);
}
.tuner-needle.off {
  background: var(--fn-d);
}
.tuner-detail {
  text-align: center;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
:where(button, select, input, [role=button], .module-header, [tabindex]):focus-visible {
  outline: 2px solid var(--cursor);
  outline-offset: 1px;
}
path[role=button]:focus-visible {
  outline: none;
  stroke: var(--cursor);
  stroke-width: 3px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
body {
  touch-action: manipulation;
}
#piano-container svg,
#iso-container svg {
  touch-action: none;
}
@media (pointer: coarse) {
  .ctrl-btn,
  .mode-btn,
  .size-ctrl-btn,
  .guitar-nav,
  .ear-answer,
  .ctrl-select,
  .module-close,
  .module-more,
  .menu-step {
    min-height: 36px;
    min-width: 36px;
  }
  .menu-item {
    min-height: 40px;
  }
  .module-resize {
    width: 24px;
    height: 24px;
    opacity: 1;
  }
  :is(.module-chord, .module-staff, .module-cof, .module-piano, .module-iso, .module-velocity) .module-header {
    opacity: 1;
  }
  .history-chip,
  .prog-chip {
    min-height: 40px;
  }
}
#tour {
  position: fixed;
  inset: 0;
  z-index: 1000;
}
.tour-dim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .55);
}
.tour-spot {
  position: absolute;
  border-radius: 6px;
  border: 2px solid var(--accent-soft);
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, .55);
  pointer-events: none;
  transition: all .2s ease;
}
.tour-card {
  position: absolute;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  box-shadow: 0 8px 28px var(--shadow);
  font-size: 13px;
  line-height: 1.45;
}
.tour-count {
  font-size: 11px;
  color: var(--text-muted);
}
.tour-title {
  margin: 2px 0 6px;
  font-size: 16px;
  color: var(--text-strong);
}
.tour-text {
  margin: 0 0 12px;
  color: var(--text-soft);
}
.tour-buttons {
  display: flex;
  gap: 6px;
  align-items: center;
}
.tour-gap {
  flex: 1;
}
.tour-next {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}
.set-backdrop {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(0, 0, 0, .55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.set-backdrop[hidden] {
  display: none;
}
.set-dialog {
  width: min(920px, 100%);
  height: min(680px, calc((100vh - 32px) / var(--zoom, 1)));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 12px 40px var(--shadow);
}
.set-dialog {
  position: relative;
}
.set-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  background: var(--bg-bar);
  border-bottom: 1px solid var(--line);
}
.set-title {
  margin: 0;
  font-size: 17px;
  color: var(--text-strong);
}
.set-search {
  flex: 1;
  max-width: 340px;
  margin-left: 12px;
  height: 30px;
  box-sizing: border-box;
  padding: 0 10px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
}
.set-gap {
  flex: 1;
}
.set-close {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
  background: transparent;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
}
.set-main {
  display: flex;
  flex: 1;
  min-height: 0;
}
.set-nav {
  width: 210px;
  flex-shrink: 0;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--surface-2);
  border-right: 1px solid var(--line);
  overflow-y: auto;
}
.set-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  padding: 8px 12px;
  border-radius: 6px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.set-nav-item:hover {
  background: var(--surface);
}
.set-nav-item[aria-current=true] {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}
.set-nav-icon {
  display: inline-flex;
  flex-shrink: 0;
  opacity: .85;
}
.set-nav-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.set-nav-sum {
  display: none;
}
.set-content {
  flex: 1;
  overflow-y: auto;
  padding: 18px 26px;
}
.set-section-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 4px;
}
.set-section-head > .set-hint {
  flex-basis: 100%;
}
.set-section-title {
  margin: 0;
  font-size: 15px;
  color: var(--text-strong);
}
.set-back {
  display: none;
}
.set-searching .set-section + .set-section {
  margin-top: 22px;
}
.set-more-wrap {
  position: relative;
}
.set-more,
.set-back {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 18px;
  cursor: pointer;
}
.set-more:hover,
.set-back:hover {
  background: var(--surface);
}
.set-more-menu {
  position: absolute;
  right: 0;
  top: 100%;
  z-index: 5;
  min-width: 220px;
  padding: 6px;
  background: var(--bg-bar);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  box-shadow: 0 10px 28px var(--shadow);
}
.set-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.set-row[hidden] {
  display: none;
}
.set-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.set-pick {
  padding: 4px 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.set-pick:hover .set-label {
  color: var(--text-strong);
}
.set-label {
  font-size: 13px;
  font-weight: 600;
}
.set-value {
  font-size: 12px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.set-row > .set-hint {
  flex-basis: 100%;
  font-size: 12px;
  color: var(--text-muted);
  padding-bottom: 2px;
}
.set-section-head > .set-hint {
  font-size: 12px;
  color: var(--text-muted);
}
.set-info {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 0;
  background: transparent;
  color: var(--text-dim);
  font-size: 15px;
  cursor: help;
}
.set-info:hover,
.set-info[aria-expanded=true] {
  color: var(--accent-text);
}
.set-control {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.set-range {
  width: 180px;
  accent-color: var(--accent);
}
.set-group {
  margin: 20px 0 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-text);
}
[data-mirror-of] > .set-group:first-child {
  margin-top: 8px;
}
.set-searching .set-group {
  display: none;
}
.set-strings {
  display: flex;
  gap: 4px;
}
.set-strings .set-string {
  width: 38px;
}
.set-check,
.set-switch {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  width: 36px;
  height: 20px;
  margin: 0;
  flex-shrink: 0;
  border-radius: 10px;
  border: 0;
  background: var(--border);
  cursor: pointer;
  transition: background .15s;
}
.set-check::before,
.set-switch::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--text-soft);
  transition: transform .15s, background .15s;
}
.set-check:checked,
.set-switch[aria-checked=true] {
  background: var(--accent);
}
.set-check:checked::before,
.set-switch[aria-checked=true]::before {
  transform: translateX(16px);
  background: var(--on-accent);
}
.set-check:disabled {
  opacity: .4;
  cursor: default;
}
.set-pick-layer {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, .45);
}
.set-pick-layer[hidden] {
  display: none;
}
.set-pick-card {
  width: min(360px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-bar);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  box-shadow: 0 12px 40px var(--shadow);
}
.set-pick-title {
  margin: 0;
  padding: 16px 20px 8px;
  font-size: 15px;
  color: var(--text-strong);
}
.set-pick-list {
  overflow-y: auto;
  padding: 0 8px 8px;
  display: flex;
  flex-direction: column;
}
.set-pick-option {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}
.set-pick-option:hover {
  background: var(--surface);
}
.set-pick-option:disabled {
  color: var(--text-dim);
  cursor: default;
}
.set-pick-option input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--accent);
}
.set-radio {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  box-sizing: border-box;
  border-radius: 50%;
  border: 2px solid var(--text-muted);
}
.set-pick-option[aria-checked=true] .set-radio {
  border: 5px solid var(--accent);
}
.set-pick-foot {
  display: flex;
  justify-content: flex-end;
  padding: 8px 16px 14px;
}
.set-pick-foot[hidden] {
  display: none;
}
.set-nothing {
  color: var(--text-muted);
  font-size: 13px;
}
.set-file {
  cursor: pointer;
}
.set-danger {
  border-color: var(--danger);
  color: var(--danger-text);
}
.set-primary {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}
.set-error {
  color: var(--danger-text);
  font-size: 13px;
}
.set-keys {
  flex-wrap: wrap;
  min-width: 200px;
}
.set-key-buttons {
  display: flex;
  gap: 6px;
  width: 170px;
  justify-content: flex-end;
}
.set-kbd-wrap {
  display: inline-flex;
  align-items: center;
}
.set-kbd {
  padding: 3px 9px;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-family: ui-monospace, monospace;
  font-size: 12px;
}
.set-kbd-custom {
  color: var(--accent-text);
  border-color: var(--accent-text);
}
.set-kbd-wait {
  border: 2px solid var(--cursor);
  background: var(--accent);
  color: var(--on-accent);
}
.set-kbd-x {
  border: 0;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 14px;
  padding: 0 4px;
}
.set-key-waiting {
  background: var(--surface-2);
}
.set-key-row {
  position: relative;
}
.set-conflict {
  position: absolute;
  top: calc(100% - 6px);
  right: 0;
  z-index: 2;
  width: min(560px, 100%);
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--modulation-border);
  background: var(--surface);
  color: var(--modulation-text);
  font-size: 13px;
  box-shadow: 0 6px 20px var(--shadow);
}
.set-conflict span {
  flex: 1;
}
@media (max-width: 720px) {
  .set-backdrop {
    padding: 0;
  }
  .set-dialog {
    width: 100%;
    height: calc(100vh / var(--zoom, 1));
    border: 0;
    border-radius: 0;
  }
  .set-header {
    flex-wrap: wrap;
    padding: 10px 16px;
  }
  .set-search {
    order: 1;
    flex-basis: 100%;
    max-width: none;
    margin: 0;
    height: 40px;
    font-size: 15px;
    border-radius: 20px;
    padding: 0 16px;
  }
  .set-main {
    flex-direction: column;
  }
  .set-nav {
    width: auto;
    flex: 1;
    padding: 4px 0;
    border: 0;
    background: transparent;
  }
  .set-nav-item {
    gap: 18px;
    padding: 12px 20px;
    border-radius: 0;
    font-size: 15px;
  }
  .set-nav-item[aria-current=true] {
    background: transparent;
    color: var(--text-soft);
    font-weight: normal;
  }
  .set-nav-name {
    color: var(--text);
  }
  .set-nav-sum {
    display: block;
    font-size: 13px;
    color: var(--text-muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .set-nav-icon .icon {
    width: 22px;
    height: 22px;
  }
  .set-content {
    display: none;
    padding: 0 16px 24px;
  }
  .set-paged .set-header,
  .set-paged .set-nav,
  .set-searching .set-nav {
    display: none;
  }
  .set-paged .set-content,
  .set-searching .set-content {
    display: block;
  }
  .set-searching.set-paged .set-header {
    display: flex;
  }
  .set-section-head {
    position: sticky;
    top: 0;
    z-index: 3;
    margin: 0 -16px 4px;
    padding: 8px 8px 8px 4px;
    background: var(--bg-bar);
    border-bottom: 1px solid var(--line);
  }
  .set-section-head > .set-hint {
    padding: 0 12px 4px;
  }
  .set-section-title {
    font-size: 18px;
  }
  .set-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
  .set-searching .set-back {
    display: none;
  }
  .set-searching .set-section-title {
    padding-left: 12px;
  }
  .set-more {
    width: 40px;
    height: 40px;
  }
  .set-row {
    padding: 12px 0;
  }
  .set-label {
    font-size: 15px;
    font-weight: 500;
  }
  .set-value {
    font-size: 13px;
    white-space: normal;
  }
  .set-range {
    width: 100%;
  }
  .set-control:has(.set-range) {
    flex-basis: 100%;
  }
  .set-pick-layer {
    position: fixed;
  }
}
#tuner-mic {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
/*# sourceMappingURL=app.css.map */
