
:root{--ink:#213d38;--green:#315c4e;--muted:#69756d;--line:#dcded3;--paper:#fffefb;--gold:#a98a4f}
*{box-sizing:border-box}[hidden]{display:none!important}.practice-page{margin:0;background:#f4f3ed;color:var(--ink);font:16px/1.5 system-ui,sans-serif}.practice-page a{color:var(--green)}.practice-page button,.practice-page select,.practice-page input{font:inherit}.practice-page button,.practice-page select{border:1px solid #c8cec2;background:var(--paper);border-radius:8px;color:var(--ink);padding:9px 12px}.practice-page button{cursor:pointer}.practice-page button:hover:not(:disabled){background:#edf1e8}.practice-page button:disabled{cursor:default;opacity:.55}.practice-page :focus-visible{outline:3px solid #997335;outline-offset:3px}.skip-link{position:absolute;top:-100px}.skip-link:focus{top:8px;background:white;padding:12px;z-index:20}
.site-header{background:var(--paper);border-bottom:1px solid var(--line);padding:18px max(24px,calc((100vw - 1120px)/2));display:flex;align-items:center;justify-content:space-between;gap:20px}.brand{display:flex;align-items:center;gap:12px;text-decoration:none;font:26px Georgia,serif;white-space:nowrap}.brand svg{color:var(--gold)}.brand-domain{font-size:16px;color:var(--muted)}.header-actions{display:flex;align-items:center;gap:12px}.account-link{padding:9px 17px;border:1px solid var(--line);border-radius:8px;text-decoration:none;min-height:44px;display:flex;align-items:center}#languageSwitch{max-width:140px;min-height:44px}
.practice-page .practice-shell{max-width:1120px;padding:26px 24px 48px;margin:auto}.breadcrumb{display:flex;justify-content:space-between;gap:16px;font-size:14px;margin-bottom:24px}.breadcrumb a{text-decoration:none;min-height:44px;display:flex;align-items:center}.practice-head{display:flex;justify-content:space-between;align-items:center;gap:18px;flex-wrap:nowrap;margin-bottom:24px}.eyebrow{font-size:11px;font-weight:650;letter-spacing:.18em;color:var(--muted);margin:0 0 6px}.practice-head h1{font:38px/1.15 Georgia,serif;margin:0;overflow-wrap:anywhere}.share-wrap{position:relative;flex-shrink:0}#shareSelection{display:flex;align-items:center;gap:9px;background:var(--green);color:white;border-color:var(--green);padding:10px 17px}#shareSelection:hover:not(:disabled){background:#234638}#shareStatus{position:absolute;right:0;top:calc(100% + 8px);background:var(--ink);color:white;padding:9px 12px;border-radius:8px;width:max-content;max-width:260px;z-index:8;font-size:14px}#shareFallback{position:absolute;right:0;top:100%;max-width:75vw;width:300px;z-index:9}
.practice-card{background:var(--paper);border:1px solid var(--line);border-radius:14px;overflow:hidden;box-shadow:0 5px 24px #20392d05}.practice-page .practice-controls{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:20px;background:transparent;padding:20px 24px;border-bottom:1px solid var(--line);border-radius:0}.practice-controls label{min-width:0!important;display:flex;flex-direction:column;gap:7px;font-size:13px;font-weight:600}.practice-controls select{min-width:0;width:100%;font-size:14px;font-weight:400;background:#f8f8f3;text-overflow:ellipsis}.status{margin:0;padding:0 24px;font-size:14px}.status:not(:empty){padding:12px 24px}.score-toolbar{display:flex;align-items:center;justify-content:space-between;padding:10px 20px;color:var(--muted);font-size:12px}.score-toolbar button{display:flex;align-items:center;gap:8px;font-size:12px;padding:5px 10px;min-height:44px;border:0;background:transparent}.score-toolbar button span:first-child{font-size:23px}.score-surface{position:relative;background:#e9e9e2;margin:0 20px;overflow:hidden;border:1px solid var(--line);border-radius:4px}.practice-page .score-frame{display:block;width:100%;height:clamp(360px,52dvh,650px);min-height:0;border:0;background:white}.score-frame img{width:100%;height:auto;display:block}.score-surface iframe{pointer-events:none}.score-surface #scorePages{overflow:hidden}.preview-trigger{position:absolute;inset:0;width:100%;height:100%;border:0!important;background:transparent!important;border-radius:0!important;display:flex;justify-content:center;align-items:flex-end;padding:12px!important}.preview-trigger span{background:#fffefbf2;color:var(--green);padding:7px 15px;border:1px solid var(--line);border-radius:24px;font-size:12px;box-shadow:0 2px 10px #0001}.media-state{font-size:13px;color:var(--muted);margin:8px 20px}.media-state:empty{display:none}#scoreRecovery,#retryScore{margin:8px 20px;display:inline-block;font-size:13px}.practice-page .player-bar{position:static;display:flex;align-items:center;gap:16px;flex-wrap:wrap;box-shadow:none;border-top:1px solid var(--line);background:transparent;padding:18px 24px;margin-top:18px}.player-caption{font-size:13px;font-weight:600;width:100%}.player-bar audio{min-width:0!important;flex:1 1 300px;height:44px}.player-bar label{display:flex;align-items:center;gap:9px;font-size:13px}.player-bar select{font-size:14px}.loop-label{min-height:44px}.loop-label input{min-height:0;width:18px;height:18px;accent-color:var(--green)}.player-bar #video{width:100%;max-width:560px;aspect-ratio:16/9;border:0}.player-bar .media-state,.player-bar .practice-note{width:100%;margin:0}.info-panel{margin-top:20px;background:#eeeee5;border:1px solid var(--line);border-radius:10px}.info-panel summary{padding:14px 20px;cursor:pointer;font-size:14px;font-weight:600}.info-content{padding:0 20px 20px}.info-content h2{font-size:15px}.info-content ul{padding-left:20px;font-size:13px}.info-content #songInfo{font-size:14px}.practice-note{color:var(--muted);font-size:13px}.info-content button{font-size:14px}#recommendationPanel{margin-top:20px}#recommendationPanel label{display:flex;flex-direction:column;margin-bottom:12px}
#scoreDialog{width:calc(100vw - 32px);max-width:1440px;height:calc(100dvh - 32px);max-height:none;padding:0;border:1px solid var(--line);border-radius:12px;background:var(--paper);color:var(--ink)}#scoreDialog::backdrop{background:#10251fbb}.dialog-toolbar{display:flex;justify-content:space-between;align-items:center;padding:10px 20px;gap:12px;border-bottom:1px solid var(--line)}.dialog-toolbar h2{font:22px Georgia,serif;margin:0}#dialogContent{height:calc(100% - 66px);overflow:auto}#dialogContent .score-frame{height:100%;width:100%;border:0;min-height:0}#dialogContent img{max-width:100%;display:block;margin:auto}body:has(dialog[open]){overflow:hidden}
@media(max-width:639px){.site-header{padding:12px 16px;gap:10px;flex-wrap:wrap}.brand{font-size:22px;gap:8px}.brand-domain{display:none}.brand svg{width:24px;height:36px}.header-actions{gap:7px;flex-wrap:wrap}#languageSwitch{font-size:12px;max-width:112px;padding:8px}.account-link{font-size:12px;padding:8px 10px}.practice-page .practice-shell{padding:12px 14px 30px}.breadcrumb{font-size:12px;margin-bottom:14px}.practice-head{margin-bottom:20px;gap:12px}.practice-head h1{font-size:30px}.eyebrow{font-size:9px;letter-spacing:.12em}#shareSelection{padding:9px 12px;font-size:13px;gap:7px}.practice-page .practice-controls{grid-template-columns:minmax(0,1fr);padding:16px;gap:14px}.score-toolbar{padding:5px 12px}.score-surface{margin:0 10px}.practice-page .score-frame{height:390px}.practice-page .player-bar{padding:16px;gap:10px;margin-top:12px}.player-bar audio{width:100%;flex-basis:100%}.tempo-label{flex:1}.info-panel{margin-top:14px}#scoreDialog{width:100vw;height:100dvh;max-width:none;margin:0;border-radius:0}.dialog-toolbar{padding:10px 14px}}
@media(prefers-reduced-motion:no-preference){button,a{transition:background-color .15s}}

#dialogContent .score-surface{height:100%;margin:0;border:0;overflow:auto}#dialogContent .score-frame{min-height:100%}#scoreCanvas{display:block;width:100%;height:auto}#dialogContent #scoreCanvas{width:100%;height:auto}.score-surface:has(#scoreCanvas:not([hidden])){max-height:650px}#dialogContent .score-surface{max-height:none}.score-surface canvas{background:white}

.score-surface:has(#scoreCanvas:not([hidden])){height:clamp(360px,52dvh,650px)}.score-surface #scoreCanvas{height:100%;object-fit:contain}#dialogContent .score-surface{height:100%;max-height:none}#dialogContent canvas{height:auto!important;object-fit:initial}#dialogContent #scorePages{height:auto;overflow:visible}@media(max-width:639px){.score-surface:has(#scoreCanvas:not([hidden])){height:390px}}

#scoreViewer #scorePages.score-excerpt img:first-child {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
#scoreViewer #scorePages.score-excerpt img:not(:first-child) {
    display: none;
}
#dialogContent #scorePages.score-excerpt img {
    width: min(100%, 1100px);
    margin: 0 auto 12px;
}

#songMeaning { margin: 0.35rem 0 0; color: var(--muted, #49665a); font-size: 0.92rem; }
