*{box-sizing:border-box}body{margin:0;background:#f6f8fb;color:#1d2d43;font:15px -apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif}.app{max-width:1480px;margin:18px auto;padding:0 16px}.toolbar,.notation{background:white;border:1px solid #dfe7f0;border-radius:12px}.toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:12px;margin-bottom:14px}.duration-group{display:flex;gap:5px}.duration{height:64px;min-width:58px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:26px;line-height:1.25}.duration small{font-size:11px;margin-top:1px}.toolbar button{cursor:pointer;border:1px solid #d6e1ee;border-radius:8px;background:white;color:#243a58}.toolbar button.active,.toolbar button[aria-pressed=true]{background:#dceafb;border-color:#377ac0;color:#145999}.toolbar button:hover{border-color:#4385c7}.toggle{min-height:48px;padding:6px 13px;font-size:20px;display:flex;gap:6px;align-items:center}.toggle span:not(.rest-glyph){font-size:14px}.rest-glyph{font-family:"Noto Music","DejaVu Sans",serif}.plain{min-height:42px;padding:8px 12px}.toolbar button:disabled{opacity:.4;cursor:default}.toolbar select{min-height:42px;padding:4px 8px;background:white;border:1px solid #d6e1ee;border-radius:8px;color:#243a58}.toolbar label{color:#586c83;font-size:13px}.separator{height:34px;width:1px;background:#dce5ef;margin:0 3px}.notation{padding:14px 16px}.score{display:flex;flex-direction:column;gap:10px}.system{width:100%;display:block;border:0;overflow:visible;touch-action:none}.system text{user-select:none}.note-hit{cursor:grab}.staff-click{cursor:crosshair}.below{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap;color:#68788c;font-size:12px;padding:8px 5px 2px}.settings[hidden]{display:none}@media(max-width:800px){.app{padding:0 6px}.toolbar{gap:6px;padding:8px}.duration{min-width:50px;height:56px}.notation{padding:6px}.system{min-width:680px}.score{overflow:auto}}
.config-header{display:flex;justify-content:flex-end;margin-bottom:7px}.settings-switch{border:1px solid #d6e1ee;border-radius:7px;background:white;color:#324d6c;padding:7px 12px;cursor:pointer;font:inherit;font-size:13px}.settings{display:grid;grid-template-columns:1fr 2fr 1fr .75fr;gap:10px;align-items:end;background:white;border:1px solid #dfe7f0;border-radius:10px;margin-bottom:10px;padding:12px}.settings label{display:flex;flex-direction:column;gap:5px;font-size:12px;font-weight:600;color:#586c83}.settings select{width:100%;min-width:0;min-height:37px;border:1px solid #d6e1ee;border-radius:7px;background:white;color:#243a58;padding:5px 7px}.settings[hidden]{display:none}@media(max-width:700px){.settings{grid-template-columns:1fr 1fr}}

.settings input{width:100%;min-height:37px;border:1px solid #d6e1ee;border-radius:7px;background:white;color:#243a58;padding:5px 7px;font:inherit}
.settings{grid-template-columns:1fr 2fr 1fr .75fr 1.25fr .8fr}
@media(max-width:800px){.settings{grid-template-columns:repeat(2,minmax(0,1fr))}}
.playing-note{stroke:#d97706;stroke-width:2.5;fill:rgba(245,158,11,.18)}

.vex-system{position:relative;max-width:100%;overflow:hidden}.vex-system>svg{width:100%;height:auto;display:block}.vex-system .note-hit{cursor:grab}.vex-system .staff-click{cursor:crosshair}.vex-system svg text{user-select:none}

/* Hide invisible hit areas explicitly. No debug glyph or measure frames. */
.vex-system svg rect.note-hit,.vex-system svg rect.staff-click{fill:transparent!important;stroke:none!important;stroke-width:0!important}
.vex-system{overflow-x:auto;overflow-y:hidden}

/* v0.7.4: preserve a full-size sixteenth-note slot grid. Rather than shrinking
   four crowded measures into the viewport, scroll the notation horizontally. */
.score{overflow-x:auto;overflow-y:hidden}
.system{width:auto;max-width:none;flex:none}

.accidental-actions{display:inline-flex;align-items:center;gap:4px}.accidental-actions button{font-size:23px;min-width:39px;padding:5px 8px}

.playback-sound{display:inline-flex;gap:6px;align-items:center;font-size:12px;color:#586c83}.playback-sound select{max-width:112px}.toggle-small[aria-pressed=true]{background:#dceafb;border-color:#377ac0;color:#145999}

/* Student demonstration embeds the existing notation engine without instructor settings. */
.student-editor body{background:white}.student-editor .app{margin:0;padding:7px;max-width:none}.student-editor .config-header,.student-editor .settings{display:none!important}.student-editor .toolbar{margin-bottom:5px;padding:5px;gap:5px;border-radius:6px}.student-editor .notation{padding:5px;border-radius:6px}.student-editor .below{display:none}.student-editor #instrument,.student-editor .playback-sound,.student-editor #metronomeBtn,.student-editor #tonicBtn,.student-editor #followBtn,.student-editor #playBtn,.student-editor #clearBtn,.student-editor #exportBtn{display:none!important}.answer-key .toolbar{display:none!important}.answer-key .notation{border:0}.answer-key .note-hit,.answer-key .staff-click{pointer-events:none!important}

/* v0.9.4: keep tools available when scrolling long student transcriptions. */
.answer-entry .toolbar{position:sticky;top:0;z-index:20;box-shadow:0 2px 9px rgba(32,48,73,.10);background:#fff}
#inputModeBtn[aria-pressed=true]{background:#dceafb;border-color:#377ac0;color:#145999}
.answer-entry .entry-caret{opacity:.95}
