:root { color-scheme: light; --paper: #eae8df; --panel: #f5f3eb; --ink: #303b34; --muted: #6f756a; --line: #cfcec2; --orange: #a34f34; --green: #79856a; --mono: 'SFMono-Regular', Consolas, 'Liberation Mono', monospace; font-family: Arial, Helvetica, sans-serif; color: var(--ink); background: var(--paper); }
* { box-sizing: border-box; }
body { margin: 0; min-width: 340px; }
button, input, select { font: inherit; color: inherit; }
button, select { cursor: pointer; }
button { -webkit-tap-highlight-color: transparent; }
button { border: 0; background: none; }
button:disabled { cursor: wait; opacity: .45; }
button:hover:not(:disabled) { color: var(--orange); }
button:focus-visible, select:focus-visible, input:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--orange); outline-offset: 5px; }
[hidden] { display: none !important; }
select { border: 0; border-radius: 0; background: transparent; padding: 7px 24px 7px 0; }
.instrument { width: min(1140px, calc(100% - 88px)); margin: clamp(30px, 7vh, 80px) auto 25px; }
.masthead { display: flex; justify-content: space-between; align-items: center; margin-bottom: 35px; }
.brand { display: flex; align-items: center; gap: 16px; }
.brand svg { width: 42px; height: 42px; fill: none; stroke: var(--ink); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
h1 { margin: 0; font-family: Georgia, 'Times New Roman', serif; font-weight: 400; font-size: 46px; letter-spacing: -2px; line-height: .85; }
h1 span { display: block; font-family: var(--mono); font-size: 9px; letter-spacing: 2.1px; text-transform: uppercase; margin-top: 14px; }
.master { display: flex; align-items: center; gap: 15px; }
.master label { font-size: 11px; }
.master input { width: 75px; }
.level-meter { display: flex; gap: 3px; height: 18px; align-items: center; margin-right: 8px; }
.level-meter i { width: 3px; height: 12px; background: #d0d0c4; transition: background .07s; }
.level-meter i.lit { background: #768068; }
.level-meter i:last-child.lit { background: var(--orange); }
.icon-button { width: 28px; height: 28px; border: 1px solid var(--line); border-radius: 50%; font-family: var(--mono); font-size: 12px; }
.master .icon-button { margin-left: 9px; }
.panel { background: var(--panel); border: 1px solid #c3c5b7; border-radius: 9px; box-shadow: 0 3px 3px #3b453309, 0 20px 45px #333d3110; overflow: hidden; }
.topbar { height: 63px; padding: 0 27px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); }
.preset-wrap { display: flex; align-items: center; gap: 13px; }
.preset-mark { color: var(--orange); font-size: 22px; }
.preset-wrap select { font-size: 13px; min-width: 150px; }
.text-button { font-size: 12px; padding: 8px 0; }
.text-button span { font-size: 18px; margin-right: 5px; }
.sound-area { display: grid; grid-template-columns: 1fr 290px; min-height: 338px; }
.landscape { position: relative; overflow: hidden; cursor: crosshair; touch-action: none; min-height: 338px; background: #222f2b; }
#landscape-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.landscape-top, .landscape-bottom { position: absolute; left: 25px; right: 25px; display: flex; justify-content: space-between; align-items: center; color: #c0c6b6; pointer-events: none; font: 10px var(--mono); }
.landscape-top { top: 22px; }
.landscape-bottom { bottom: 20px; }
.state { display: flex; align-items: center; gap: 8px; letter-spacing: .4px; }
.state i { width: 5px; height: 5px; background: #7d8878; border-radius: 50%; }
.state i.active { background: #d0dcae; box-shadow: 0 0 10px #c6d3a766; }
.memory-symbol { font-size: 23px; opacity: .6; }
.coordinates { color: #9ca790; letter-spacing: 4px; }
#hold-indicator { color: #e5cfaa; letter-spacing: 2px; }
.sources { display: grid; grid-template-rows: repeat(3, 1fr); }
.source { padding: 16px 20px 12px; border-bottom: 1px solid var(--line); position: relative; min-width: 0; --source-color: #7a8667; }
.source:last-child { border-bottom: 0; }
.source:nth-child(2) { --source-color: #b0805d; }
.source:nth-child(3) { --source-color: #859995; }
.source.dragging { background: #dadfce; }
.source.muted .waveform, .source.muted .source-name { opacity: .32; }
.source-top { display: flex; align-items: center; gap: 10px; }
.source-mute { font: 11px var(--mono); padding: 3px 0; color: var(--source-color); min-width: 17px; text-align: left; }
.source-mute[aria-pressed=true] { text-decoration: line-through; }
.source-name { font-size: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; padding: 3px 0; text-align: left; flex: 1; }
.source-upload { font-size: 17px; padding: 0 2px; color: var(--muted); }
.waveform { height: 37px; position: relative; cursor: crosshair; margin: 4px 0 5px; touch-action: none; }
.waveform canvas { width: 100%; height: 100%; position: absolute; }
.source-bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.source-duration { font: 9px var(--mono); color: var(--muted); }
.source-bottom input { width: 76px; accent-color: var(--source-color); }
input[type=range] { appearance: none; -webkit-appearance: none; height: 18px; background: transparent; margin: 0; cursor: pointer; }
input[type=range]::-webkit-slider-runnable-track { height: 2px; background: #c5c8bc; }
input[type=range]::-moz-range-track { height: 2px; background: #c5c8bc; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; height: 8px; width: 8px; margin-top: -3px; border-radius: 50%; background: #737d66; }
input[type=range]::-moz-range-thumb { height: 8px; width: 8px; border: 0; border-radius: 50%; background: #737d66; }
.macros { display: grid; grid-template-columns: repeat(6, 1fr); padding: 30px 24px 26px; border-top: 1px solid var(--line); }
.macro { text-align: center; position: relative; }
.macro:nth-child(5)::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 1px; background: var(--line); }
.macro label { font-size: 12px; letter-spacing: .1px; }
.knob { width: 95px; height: 95px; margin: 10px auto 0; position: relative; touch-action: none; }
.knob svg { width: 100%; height: 100%; position: absolute; inset: 0; transform: rotate(135deg); fill: none; stroke-width: 1.5; }
.knob .track { stroke: #d0d1c5; }
.knob .arc { stroke: var(--green); }
.macro:nth-child(n+5) .arc { stroke: #b47d5c; }
.knob-body { position: absolute; inset: 17px; border-radius: 50%; border: 1px solid #c8c9bc; background: linear-gradient(150deg, #fcfbf5, #e1e1d6); box-shadow: 0 3px 4px #343d3424, inset 0 1px 1px #fff; transform: rotate(var(--angle)); }
.knob-body::after { content: ''; position: absolute; top: 8px; left: calc(50% - 1px); width: 2px; height: 11px; background: var(--ink); border-radius: 2px; }
.knob input[type=range] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; touch-action: none; }
.knob:focus-within { outline: 1px solid var(--orange); outline-offset: -5px; border-radius: 50%; }
.macro output { display: block; font: 10px var(--mono); color: var(--muted); margin-top: 0; }
.transport { display: flex; align-items: center; gap: 22px; padding: 22px 27px; border-top: 1px solid var(--line); }
.play-group, .output-actions, .tuning { display: flex; align-items: center; }
.play-group { gap: 15px; }
.play-button { min-width: 97px; background: var(--ink); color: #f3f1e7; padding: 15px 18px; border-radius: 4px; display: flex; gap: 13px; align-items: center; font-size: 12px; }
.play-button:hover:not(:disabled) { color: #fff; background: #455348; }
#play-icon { font-size: 10px; width: 10px; }
.hold-button { font-size: 12px; padding: 12px 7px; border-radius: 3px; }
.hold-button span { padding-right: 5px; font-size: 15px; }
.hold-button[aria-pressed=true] { background: #dfdfcd; color: #4c5944; }
.tuning { border-left: 1px solid var(--line); padding-left: 24px; gap: 24px; }
.select-control { display: flex; flex-direction: column; }
.select-control > span { color: var(--muted); font-size: 9px; margin-bottom: 1px; }
.select-control select { font-size: 12px; padding-top: 4px; padding-bottom: 2px; }
.output-actions { margin-left: auto; gap: 23px; }
.record-button { font-size: 12px; display: flex; align-items: center; gap: 8px; padding: 12px 0; min-width: 73px; }
.record-dot { width: 7px; height: 7px; border: 1px solid #a45b47; border-radius: 50%; }
.record-button.recording { color: #a34f34; }
.recording .record-dot { background: #a34f34; animation: pulse 1s infinite alternate; }
.export-button { border: 1px solid #bfc2b2; padding: 13px 17px; font-size: 12px; border-radius: 4px; white-space: nowrap; }
.export-button span { margin-left: 11px; font-size: 17px; }
footer { display: flex; justify-content: space-between; padding: 20px 1px; font-size: 11px; color: var(--muted); }
footer > span:first-child { font-family: Georgia, serif; font-style: italic; font-size: 13px; }
.edition { font: 9px var(--mono); letter-spacing: 2px; }
#notice { position: fixed; z-index: 10; left: 50%; bottom: 25px; transform: translateX(-50%); max-width: calc(100% - 32px); background: #303b34; color: #f5f3eb; border-radius: 5px; padding: 14px 22px; box-shadow: 0 6px 30px #0002; font-size: 13px; }
dialog { color: var(--ink); width: min(450px, calc(100% - 32px)); background: var(--panel); border: 1px solid #bfc2b2; border-radius: 9px; padding: 30px; box-shadow: 0 25px 120px #10201a40; }
dialog::backdrop { background: #1b292958; backdrop-filter: blur(5px); }
.dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 14px; }
h2 { font-family: Georgia, serif; font-weight: 400; letter-spacing: -.8px; margin: 0; font-size: 28px; }
.format { font: 10px var(--mono); color: var(--muted); margin-bottom: 29px; }
.duration-label { display: flex; justify-content: space-between; font-size: 12px; }
.duration-label span { color: var(--muted); }
#duration { width: 100%; padding: 12px; margin: 10px 0 20px; background: transparent; border: 1px solid var(--line); border-radius: 3px; font: 24px var(--mono); }
.check-label { display: flex; gap: 9px; align-items: center; font-size: 12px; margin-bottom: 25px; }
input[type=checkbox] { accent-color: #576b50; }
.primary { background: var(--ink); color: var(--panel); border-radius: 3px; padding: 15px; width: 100%; font-size: 13px; display: flex; justify-content: space-between; }
.primary:hover:not(:disabled) { background: #455348; color: #fff; }
.render-progress { margin-bottom: 18px; font: 11px var(--mono); }
progress { width: 100%; height: 4px; accent-color: var(--green); margin-bottom: 10px; }
#cancel-render { width: 100%; margin-top: 8px; }
#help-dialog { width: min(800px, calc(100% - 32px)); height: min(720px, calc(100dvh - 48px)); max-height: calc(100dvh - 48px); padding: 28px; overflow: hidden; }
#help-dialog[open] { display: flex; flex-direction: column; }
#help-dialog .dialog-heading { flex: 0 0 auto; }
#help-dialog .icon-button { flex-shrink: 0; }
#help-dialog p, #help-dialog dl { font-size: 13px; line-height: 1.7; }
#help-dialog p { margin: 0 0 15px; }
#help-dialog dl { margin: 0 0 20px; }
#help-dialog dt { font-weight: bold; margin-top: 10px; }
#help-dialog dt:first-child { margin-top: 0; }
#help-dialog dd { margin: 0; color: var(--muted); }
.guide-entry { display: flex; align-items: center; gap: 20px; flex: 0 0 auto; margin: 7px 0 23px; }
.guide-entry .primary { width: auto; min-width: 190px; justify-content: center; padding: 12px 18px; }
.reference-layout { display: grid; grid-template-columns: 175px minmax(0, 1fr); gap: 25px; flex: 1; min-height: 0; overflow: hidden; border-top: 1px solid var(--line); }
#reference-nav { display: flex; flex-direction: column; gap: 3px; padding: 20px 14px 10px 0; border-right: 1px solid var(--line); overflow-y: auto; }
#reference-nav button { padding: 8px 10px; text-align: left; font-size: 12px; line-height: 1.3; border-radius: 3px; }
#reference-nav button[aria-current] { background: #e4e7da; color: #35452f; }
#reference-article { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 21px 9px 7px 0; scrollbar-width: thin; }
#reference-title { font: 26px/1.2 Georgia, serif; letter-spacing: -.7px; margin: 0 0 18px; }
#reference-title:focus, #tutorial-title:focus { outline: 0; }
#reference-select { display: none; }
.inline-guide-link { padding: 0; text-decoration: underline; text-underline-offset: 3px; font-size: inherit; }
.signal-diagram { width: 100%; height: auto; display: block; margin: 4px 0 20px; }
.signal-diagram rect { fill: #e6e9dc; stroke: #bac3ad; }
.signal-diagram path { fill: none; stroke: #7f8f70; stroke-width: 1.4; }
.signal-diagram .flow-line { marker-end: url(#flow-arrow); }
.signal-diagram text { text-anchor: middle; fill: var(--ink); font: 13px Arial, sans-serif; }
.signal-diagram .flow-small { font-size: 10px; fill: var(--muted); }
#reference-content table { width: 100%; border-collapse: collapse; font-size: 11px; line-height: 1.5; margin: 20px 0; }
#reference-content caption { text-align: left; font-weight: bold; margin-bottom: 8px; }
#reference-content th, #reference-content td { padding: 9px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
#reference-content thead th { color: var(--muted); font-weight: normal; }
#reference-content td:last-child { min-width: 87px; }
kbd { font: 11px var(--mono); background: #e8e9df; padding: 2px 4px; border: 1px solid var(--line); border-radius: 3px; }
body.tutorial-open { padding-bottom: var(--tutorial-space, 420px); }
#tutorial { position: fixed; z-index: 8; bottom: 24px; right: 24px; width: 370px; max-height: calc(100dvh - 48px); overflow-y: auto; background: var(--panel); border: 1px solid #a7ae99; border-radius: 8px; padding: 21px; box-shadow: 0 10px 45px #1d2d292a; }
.tutorial-header { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
#tutorial-step { font: 10px var(--mono); color: var(--muted); white-space: nowrap; }
#tutorial-select { min-width: 0; width: 100%; font-size: 11px; padding: 5px 0; }
#tutorial-close { flex-shrink: 0; }
#tutorial h2 { font-size: 25px; line-height: 1.15; margin: 0 0 13px; }
#tutorial p { font-size: 12px; line-height: 1.65; margin: 0 0 13px; }
#tutorial-try { border-left: 2px solid #ad7c58; padding-left: 12px; color: #5c6456; }
.tutorial-tools, .tutorial-navigation { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.tutorial-tools { margin: 0 0 12px; }
.tutorial-tools .text-button { font-size: 11px; }
.tutorial-navigation { border-top: 1px solid var(--line); padding-top: 14px; }
.tutorial-navigation .primary { width: auto; min-width: 94px; padding: 11px 16px; justify-content: center; }
.tutorial-highlight { outline: 2px solid var(--orange); outline-offset: -2px; box-shadow: inset 0 0 0 4px #c2a58333; }
#tutorial-back:disabled { cursor: default; }
@media (max-width: 760px) {
  #help-dialog { height: calc(100dvh - 24px); max-height: calc(100dvh - 24px); padding: 21px; }
  #help-dialog h2 { font-size: 26px; }
  .guide-entry { margin-bottom: 16px; gap: 14px; }
  .guide-entry .primary { min-width: 0; font-size: 12px; }
  #reference-select { display: block; flex: 0 0 auto; width: 100%; font-size: 13px; padding: 11px 8px; border: 1px solid var(--line); border-radius: 3px; margin-bottom: 5px; }
  .reference-layout { grid-template-columns: minmax(0, 1fr); border: 0; }
  #reference-nav { display: none; }
  #reference-article { padding-right: 5px; }
  #reference-title { font-size: 24px; }
  #tutorial { bottom: 12px; right: 12px; width: min(370px, calc(100% - 24px)); padding: 17px; max-height: calc(70dvh - 24px); }
  .tutorial-header { margin-bottom: 12px; }
  #tutorial h2 { font-size: 23px; }
  #tutorial p { line-height: 1.5; }
  .tutorial-tools { margin-bottom: 7px; }
  .tutorial-navigation { padding-top: 10px; }
}
@keyframes pulse { to { opacity: .35; } }
@media (min-width: 1450px) { .instrument { margin-top: 11vh; } .sound-area, .landscape { min-height: 390px; } .macros { padding-top: 35px; padding-bottom: 32px; } }
@media (max-width: 1000px) { .instrument { width: calc(100% - 42px); } .sound-area { grid-template-columns: 1fr 245px; } .transport { padding: 19px; gap: 14px; } .tuning { padding-left: 16px; gap: 12px; } .output-actions { gap: 12px; } .play-group { gap: 9px; } }
@media (max-width: 760px) { .instrument { margin-top: 27px; width: calc(100% - 30px); } .masthead { margin-bottom: 26px; } h1 { font-size: 37px; } h1 span { font-size: 8px; letter-spacing: 1.4px; } .brand { gap: 9px; } .brand svg { width: 31px; } .master { gap: 9px; } .master label, .level-meter { display: none; } .master input { width: 54px; } .master .icon-button { margin-left: 1px; } .topbar { padding: 0 17px; height: 56px; } .sound-area { display: flex; flex-direction: column; } .landscape { min-height: 260px; } .sources { grid-template-columns: repeat(3, 1fr); grid-template-rows: 1fr; } .source { padding: 13px 12px 9px; border-bottom: 0; border-right: 1px solid var(--line); } .source:last-child { border-right: 0; } .source-top { gap: 4px; } .source-name { font-size: 10px; } .source-mute { font-size: 10px; min-width: 12px; } .source-upload { font-size: 13px; } .source-duration { font-size: 8px; } .source-bottom { gap: 5px; } .source-bottom input { width: 42px; } .macros { padding: 23px 7px; } .knob { width: 78px; height: 78px; } .knob-body { inset: 15px; } .knob-body::after { top: 6px; height: 9px; } .transport { flex-wrap: wrap; justify-content: space-between; gap: 18px; padding: 19px 17px; } .output-actions { width: 100%; justify-content: space-between; margin: 0; border-top: 1px solid var(--line); padding-top: 16px; } .export-button { min-width: 125px; } .tuning { padding-left: 18px; gap: 17px; } }
@media (max-width: 480px) { .macros { grid-template-columns: repeat(3, 1fr); gap: 22px 0; padding: 23px 12px; } .knob { width: 92px; height: 92px; margin-top: 5px; } .knob-body { inset: 17px; } .macro:nth-child(5)::before { display: none; } .landscape { min-height: 225px; } .transport { gap: 12px; } .play-group { gap: 5px; } .play-button { min-width: 80px; padding: 13px; gap: 9px; } .hold-button { font-size: 11px; padding: 9px 4px; } .hold-button span { padding-right: 1px; } .tuning { padding-left: 12px; gap: 8px; } .select-control select { font-size: 11px; padding-right: 5px; } .source { padding-left: 9px; padding-right: 9px; } .source-bottom input { width: 33px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
