:root{--bg:#0b1020;--surface:#121a2e;--surface-2:#18233b;--text:#f7f4ea;--muted:#99a5b8;--line:#293550;--accent:#ffb454;--accent-2:#63dec6;--danger:#ff7587;--shadow:0 18px 60px rgba(0,0,0,.28);--sheet-size:18px;--radius:18px}
[data-theme="light"]{--bg:#f4f1e8;--surface:#fffdf8;--surface-2:#ebe7dc;--text:#172033;--muted:#677184;--line:#d8d4c9;--shadow:0 18px 50px rgba(23,32,51,.12)}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:var(--bg);color:var(--text);font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;min-width:320px}button,input,textarea,select{font:inherit}button{color:inherit}button:focus-visible,input:focus-visible,textarea:focus-visible{outline:3px solid color-mix(in srgb,var(--accent) 65%,transparent);outline-offset:2px}button{cursor:pointer}.app-shell{min-height:100vh}.topbar{position:sticky;top:0;z-index:50;height:72px;padding:0 clamp(18px,4vw,58px);display:grid;grid-template-columns:auto minmax(260px,620px) auto;gap:30px;align-items:center;background:color-mix(in srgb,var(--bg) 88%,transparent);backdrop-filter:blur(18px);border-bottom:1px solid var(--line)}.brand{border:0;background:none;display:flex;align-items:center;gap:11px;font-size:18px;font-weight:800}.brand-mark{display:grid;place-items:center;width:36px;height:36px;border-radius:11px;background:var(--accent);color:#101625;letter-spacing:-4px;padding-right:3px}.brand-mark span{color:#735112}.global-search{position:relative;display:flex;align-items:center}.global-search input{width:100%;height:44px;border-radius:13px;border:1px solid var(--line);background:var(--surface);color:var(--text);padding:0 48px 0 44px;font-size:15px}.search-icon{position:absolute;left:16px;font-size:23px;color:var(--muted)}kbd{border:1px solid var(--line);border-bottom-width:2px;border-radius:5px;padding:2px 6px;background:var(--surface-2);font-size:11px}.global-search>kbd{position:absolute;right:13px}.search-results{position:absolute;top:51px;left:0;right:0;background:var(--surface);border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow);padding:8px;max-height:400px;overflow:auto}.search-result{width:100%;border:0;background:transparent;text-align:left;display:flex;justify-content:space-between;padding:12px;border-radius:9px}.search-result:hover{background:var(--surface-2)}.search-result span{color:var(--muted)}.nav-actions{display:flex;align-items:center;gap:8px}.ghost,.button,.icon-button,.player-toolbar button,.filter,.library-tabs button{border:0;background:transparent;padding:10px 13px;border-radius:10px}.ghost:hover,.icon-button:hover{background:var(--surface-2)}.button{background:var(--accent);color:#172033;font-weight:800}.button:hover{filter:brightness(1.07);transform:translateY(-1px)}.button.compact{white-space:nowrap}.view{animation:fade .24s ease}.view[hidden]{display:none!important}@keyframes fade{from{opacity:0;transform:translateY(5px)}}.home-view{overflow:hidden}.hero{position:relative;max-width:1200px;margin:auto;padding:clamp(70px,10vw,138px) 32px 90px}.hero:after{content:"";position:absolute;width:520px;height:520px;right:-120px;top:-80px;border:1px solid var(--line);border-radius:50%;box-shadow:0 0 0 70px color-mix(in srgb,var(--surface) 55%,transparent),0 0 0 140px color-mix(in srgb,var(--surface) 35%,transparent);z-index:-1}.eyebrow{margin:0 0 12px;color:var(--accent-2);font-size:12px;font-weight:900;letter-spacing:.17em;text-transform:uppercase}.hero h1,.page-head h1,.song-heading h1{margin:0;line-height:.96;letter-spacing:-.055em}.hero h1{max-width:790px;font-size:clamp(52px,8vw,100px)}.hero h1 em{color:var(--accent);font-style:normal}.hero>p:not(.eyebrow){max-width:570px;color:var(--muted);font-size:19px;line-height:1.6}.hero-button{margin-top:18px;padding:15px 20px}.hero-button span{margin-left:16px}.hero-chords{position:absolute;right:60px;bottom:50px;display:flex;gap:10px;transform:rotate(-5deg)}.hero-chords span{width:70px;height:86px;display:grid;place-items:center;background:var(--surface);border:1px solid var(--line);border-radius:15px;font:800 28px ui-monospace,monospace;box-shadow:var(--shadow)}.hero-chords span:nth-child(2){transform:translateY(-16px);color:var(--accent)}.hero-chords span:nth-child(3){transform:translateY(8px);color:var(--accent-2)}.section-wrap,.page-view{max-width:1200px;margin:auto;padding:40px 32px 80px}.section-heading,.page-head{display:flex;justify-content:space-between;align-items:end;gap:20px;margin-bottom:24px}.section-heading h2,.page-head h1{margin:0;font-size:clamp(32px,4vw,52px)}.text-button{border:0;background:none;color:var(--accent);font-weight:800}.song-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}.song-card{position:relative;border:1px solid var(--line);background:var(--surface);border-radius:var(--radius);padding:24px;text-align:left;min-height:200px;overflow:hidden}.song-card:hover{border-color:var(--accent);transform:translateY(-3px);box-shadow:var(--shadow)}.song-card .number{position:absolute;right:18px;top:8px;font-size:72px;font-weight:900;color:color-mix(in srgb,var(--text) 5%,transparent);letter-spacing:-.08em}.song-card .genre{color:var(--accent-2);font-size:12px;font-weight:800;text-transform:uppercase}.song-card h3{font-size:24px;margin:37px 0 5px}.song-card p{margin:0;color:var(--muted)}.song-card footer{display:flex;justify-content:space-between;margin-top:25px;color:var(--muted);font-size:13px}.feature-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:1px;background:var(--line);border-block:1px solid var(--line)}.feature-strip article{display:flex;gap:18px;padding:36px max(24px,calc((100vw - 1160px)/6));background:var(--bg)}.feature-strip article>span{color:var(--accent);font-size:28px}.feature-strip h3{margin:0 0 8px}.feature-strip p{margin:0;color:var(--muted);line-height:1.5}.page-view{padding-top:70px}.page-head>p{color:var(--muted)}.filter-row{display:flex;gap:8px;margin-bottom:24px}.filter{border:1px solid var(--line);color:var(--muted)}.filter.active{background:var(--text);color:var(--bg);border-color:var(--text)}.browse-list{border-top:1px solid var(--line)}.browse-row{display:grid;grid-template-columns:46px 1fr 1fr 130px 100px;align-items:center;padding:18px 10px;border-bottom:1px solid var(--line);cursor:pointer}.browse-row:hover{background:var(--surface)}.browse-row strong{font-size:17px}.browse-row span{color:var(--muted)}.difficulty-pill{justify-self:start;padding:5px 9px;border-radius:99px;background:var(--surface-2);font-size:12px}.library-tabs{display:flex;gap:8px;border-bottom:1px solid var(--line);margin-bottom:26px}.library-tabs button{border-radius:0;color:var(--muted);border-bottom:2px solid transparent}.library-tabs button.active{color:var(--text);border-color:var(--accent)}.empty-state{padding:70px 20px;text-align:center;border:1px dashed var(--line);border-radius:var(--radius)}.empty-state span{font-size:40px;color:var(--accent)}.empty-state p{color:var(--muted)}.setlist-card{display:flex;align-items:center;justify-content:space-between;border:1px solid var(--line);background:var(--surface);border-radius:14px;padding:18px;margin-bottom:10px}.song-view{max-width:1500px;margin:auto;padding:30px clamp(16px,4vw,52px) 100px}.song-heading{display:grid;grid-template-columns:auto 1fr auto;gap:18px;align-items:center;margin-bottom:24px}.song-heading h1{font-size:clamp(38px,6vw,72px)}.song-heading p:not(.eyebrow){margin:8px 0 0;color:var(--muted);font-size:19px}.song-heading-actions{display:flex;gap:8px}.icon-button{border:1px solid var(--line);background:var(--surface)}.icon-button.wide{display:flex;gap:7px}.player-toolbar{position:sticky;top:83px;z-index:40;display:flex;align-items:stretch;gap:5px;padding:8px;border:1px solid var(--line);border-radius:16px;background:color-mix(in srgb,var(--surface) 94%,transparent);backdrop-filter:blur(18px);box-shadow:var(--shadow);overflow-x:auto}.player-toolbar button{min-width:42px}.player-toolbar button:hover,.player-toolbar button.active{background:var(--surface-2)}.tool-group{display:flex;align-items:center;border-right:1px solid var(--line);padding-right:7px;white-space:nowrap}.tool-group strong{min-width:32px;text-align:center;color:var(--accent)}.tool-label{font-size:11px;color:var(--muted);text-transform:uppercase;margin:0 5px}.tool-toggle{display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:64px!important}.tool-toggle span{font-size:17px}.tool-toggle small{font-size:10px;color:var(--muted)}.speed-control{display:flex;flex-direction:column;justify-content:center;padding:0 10px;min-width:105px}.speed-control span{font-size:10px;color:var(--muted);text-transform:uppercase}.speed-control input{width:90px;accent-color:var(--accent)}.chord-tray{position:sticky;top:165px;z-index:35;margin-top:10px;display:flex;align-items:center;gap:16px;padding:12px 14px;border:1px solid color-mix(in srgb,var(--accent-2) 42%,var(--line));border-radius:16px;background:color-mix(in srgb,var(--surface) 96%,transparent);box-shadow:var(--shadow);backdrop-filter:blur(18px)}.chord-tray.collapsed{display:none}.tray-intro{display:flex;align-items:center;gap:9px;min-width:120px}.tray-intro small{display:block;color:var(--muted);font-size:9px;letter-spacing:.12em}.live-dot{width:8px;height:8px;border-radius:50%;background:var(--accent-2);box-shadow:0 0 12px var(--accent-2)}.tray-chords{display:flex;gap:8px;overflow-x:auto;flex:1;padding:2px}.chord-chip{display:flex;align-items:center;gap:10px;min-width:112px;padding:8px 12px;border:1px solid var(--line);border-radius:11px;background:var(--bg)}.chord-chip>strong{font:800 18px ui-monospace,monospace;color:var(--accent)}.mini-diagram{display:grid;grid-template-columns:repeat(6,4px);gap:2px;padding:4px;border-left:1px solid var(--line)}.mini-diagram i{display:block;width:4px;height:4px;border-radius:50%;background:var(--muted);opacity:.25}.mini-diagram i.on{opacity:1;background:var(--accent-2)}.mirror-btn{border:0;background:none;white-space:nowrap;color:var(--muted)}.song-stage{display:grid;grid-template-columns:minmax(0,1fr) 210px;gap:46px;margin-top:35px}.chord-sheet{font-family:"SFMono-Regular",Consolas,"Liberation Mono",monospace;font-size:var(--sheet-size);line-height:1.7;min-width:0;column-count:var(--columns,1);column-gap:60px}.song-section{break-inside:avoid;margin-bottom:38px;padding-top:4px}.section-label{font-family:Inter,sans-serif;color:var(--accent-2);font-weight:900;font-size:12px;letter-spacing:.15em;text-transform:uppercase;border-bottom:1px solid var(--line);padding-bottom:8px;margin-bottom:17px}.song-line{min-height:2.2em;white-space:pre-wrap}.lyric-token{position:relative;display:inline-block;padding-top:1.05em}.inline-chord{position:absolute;top:-.25em;left:0;color:var(--accent);font-weight:800;cursor:pointer;white-space:nowrap}.tab-block{white-space:pre;overflow-x:auto;color:var(--muted);background:var(--surface);border:1px solid var(--line);padding:16px;border-radius:12px}.song-notes{align-self:start;position:sticky;top:245px;border-left:1px solid var(--line);padding-left:22px}.song-notes>div{margin-bottom:25px}.song-notes small{display:block;color:var(--muted);font-size:10px;letter-spacing:.12em}.song-notes strong{display:block;margin-top:4px}.song-notes p{font-size:12px;line-height:1.8;color:var(--muted)}.modal{position:fixed;inset:0;z-index:100}.modal[hidden]{display:none}.modal-backdrop{position:absolute;inset:0;background:rgba(3,6,14,.76);backdrop-filter:blur(5px)}.modal-card{position:relative;width:min(680px,calc(100% - 30px));max-height:90vh;overflow:auto;margin:5vh auto;background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:28px;box-shadow:var(--shadow)}.modal-close{position:absolute;right:14px;top:14px;border:0;background:var(--surface-2);border-radius:50%;width:34px;height:34px;font-size:22px}.modal-card h2{margin:0 0 8px;font-size:30px}.modal-card>div>p{color:var(--muted)}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.field{display:flex;flex-direction:column;gap:6px}.field.full{grid-column:1/-1}.field label{font-size:12px;color:var(--muted);font-weight:700}.field input,.field textarea,.field select{width:100%;border:1px solid var(--line);background:var(--bg);color:var(--text);border-radius:10px;padding:11px}.field textarea{min-height:250px;font-family:ui-monospace,monospace;line-height:1.5}.modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:18px}.choice-list{display:flex;flex-direction:column;gap:8px}.choice{display:flex;justify-content:space-between;align-items:center;border:1px solid var(--line);background:var(--bg);padding:14px;border-radius:11px}.toast{position:fixed;left:50%;bottom:25px;z-index:120;transform:translate(-50%,25px);opacity:0;pointer-events:none;background:var(--text);color:var(--bg);padding:11px 17px;border-radius:99px;font-weight:800;transition:.25s}.toast.show{opacity:1;transform:translate(-50%,0)}body.performance .topbar,body.performance .song-heading .no-print,body.performance .song-notes{display:none}body.performance .song-view{padding-top:18px}body.performance .player-toolbar{top:10px}body.performance .chord-tray{top:93px}body.performance .song-stage{grid-template-columns:1fr}body.performance .song-heading{grid-template-columns:1fr}body.performance .song-heading h1{font-size:32px}
@media(max-width:900px){.topbar{grid-template-columns:auto 1fr;height:auto;padding:10px 16px;gap:12px}.nav-actions{grid-column:1/-1;justify-content:flex-end}.hero-chords{opacity:.25;right:-30px}.song-grid,.feature-strip{grid-template-columns:1fr}.song-stage{grid-template-columns:1fr}.song-notes{display:none}.browse-row{grid-template-columns:34px 1fr 110px}.browse-row .hide-mobile{display:none}.player-toolbar{top:116px}.chord-tray{top:198px}.chord-sheet{column-count:1!important}.song-heading{grid-template-columns:auto 1fr}.song-heading-actions{grid-column:2}.feature-strip article{padding:28px 24px}}
@media(max-width:600px){.topbar{grid-template-columns:1fr auto}.brand>span:last-child{display:none}.global-search{grid-column:1/-1;grid-row:2}.nav-actions{grid-column:2;grid-row:1}.nav-actions .ghost{display:none}.hero{padding:55px 20px 75px}.hero h1{font-size:50px}.hero-chords{display:none}.section-wrap,.page-view{padding-inline:18px}.song-grid{grid-template-columns:1fr}.song-view{padding-inline:12px}.song-heading{gap:10px}.song-heading h1{font-size:39px}.song-heading-actions span{display:none}.player-toolbar{top:118px;border-radius:12px}.chord-tray{top:200px;margin-inline:0;gap:8px}.tray-intro{min-width:86px}.tray-intro strong{font-size:12px}.mirror-btn span{display:none}.chord-chip{min-width:92px}.chord-sheet{font-size:var(--sheet-size);padding:0 7px}.form-grid{grid-template-columns:1fr}.field.full{grid-column:auto}.page-head{align-items:start;flex-direction:column}.browse-row{grid-template-columns:30px 1fr 90px;padding-inline:0}.browse-row .difficulty-pill{font-size:10px}}
@media print{.no-print,.topbar,.song-heading-actions,.song-notes,.chord-tray{display:none!important}body{background:white;color:black}.view:not(#songView){display:none!important}.song-view{display:block!important;padding:0}.song-heading{display:block;margin-bottom:25px}.song-heading h1{font-size:32px}.chord-sheet{font-size:12pt;column-count:2;column-gap:36px}.section-label,.inline-chord{color:#000}.song-section{margin-bottom:22px}}
/* Dashboard shell: the player scrolls only inside the sheet. */
@media screen {
html,body{height:100%;overflow:hidden}
.app-shell{height:100vh;height:var(--app-height,100vh);height:100dvh;min-height:0;display:flex;flex-direction:column}
.topbar{position:relative;flex-shrink:0}
main{flex:1;min-height:0;overflow:hidden;display:flex;flex-direction:column}
.view{min-height:0;width:100%;flex:1}
.home-view{display:flex;flex-direction:column;padding:24px clamp(18px,4vw,58px);gap:20px}
.hero{width:100%;max-width:1200px;padding:16px 0;margin:0 auto;flex-shrink:0}
.hero h1{font-size:clamp(30px,4.2vw,58px)}
.hero>p:not(.eyebrow){font-size:15px;max-width:560px;margin:12px 0}
.hero-button{margin-top:0;padding:11px 16px}
.hero-chords{right:35px;bottom:28px}
.home-view .section-wrap{width:100%;padding:0;min-height:0;flex:1;display:flex;flex-direction:column}
.home-view .section-heading{margin-bottom:12px;flex-shrink:0}
.home-view .section-heading h2{font-size:26px}
.home-view .section-heading .eyebrow{display:none}
.song-grid{min-height:0;overflow:auto;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:3px}
.song-card{min-height:145px;padding:16px}
.song-card h3{font-size:21px;margin:18px 0 5px}
.song-card footer{margin-top:14px}
.feature-strip{display:none}
.page-view{display:flex;flex-direction:column;padding-block:24px;width:100%}
.browse-list,#libraryContent{overflow:auto;min-height:0}
.song-view{display:flex;flex-direction:column;padding:18px clamp(12px,3vw,40px);gap:16px;margin:0 auto}
.song-heading{flex-shrink:0;margin:0}
.song-heading h1{font-size:clamp(28px,3.6vw,46px)}
.song-heading .eyebrow{margin-bottom:6px}
.song-heading p:not(.eyebrow){font-size:15px;margin-top:5px}
.player-toolbar{position:relative;top:auto!important;flex-shrink:0;box-shadow:none;min-height:66px}
.song-stage,body.performance .song-stage{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1fr) 260px;gap:20px;margin:0}
.sheet-viewport{min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable;border:1px solid var(--line);background:var(--surface);border-radius:16px;padding:26px;scroll-behavior:auto}
.chord-sheet{column-count:1;column-width:auto}
.chord-sheet[style*="--columns: 2"],.chord-sheet[style*="--columns: 3"]{display:grid;grid-template-columns:repeat(var(--columns),minmax(0,1fr));gap:24px;align-items:start}
.song-line{white-space:pre;min-height:3em;line-height:1.7;padding-top:.3em}
.lyric-token{display:inline-block;vertical-align:baseline;padding-top:1.2em;min-width:var(--chord-width,0)}
.inline-chord{font:inherit;font-weight:800;border:0;background:none;padding:0;margin:0;line-height:1;top:0;left:0;border-radius:0}
.song-line:has(.lyric-token)>.lyric-token:has(>span:empty){min-width:2ch}
.player-sidebar{min-height:0;display:flex;flex-direction:column;gap:16px;overflow:auto}
.chord-tray{position:static;top:auto!important;margin:0;display:flex;flex-direction:column;align-items:stretch;gap:18px;padding:18px;box-shadow:none;flex-shrink:0}
.chord-tray.collapsed{display:none}
.tray-intro{min-width:0}
.tray-intro strong{font-size:18px}
.tray-chords{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;overflow:visible;flex:none}
.chord-chip{min-width:0;flex-direction:column;gap:5px;padding:10px 6px}
.chord-chip>strong{font-size:21px}
.fretboard{width:88px;max-width:100%;height:auto;display:block}
.fretboard path{stroke:var(--muted);stroke-width:1;fill:none}
.fretboard circle{fill:var(--accent-2)}
.fretboard text{fill:var(--muted);font:11px sans-serif;text-anchor:middle}
.diagram-unavailable{font-size:10px;color:var(--muted);padding:18px 0}
.song-notes{position:static;border:1px solid var(--line);border-radius:16px;padding:18px;display:grid;grid-template-columns:1fr 1fr;gap:16px}
.song-notes>div{margin:0}.song-notes .shortcut-note{grid-column:1/-1}
body.performance .song-view{padding-top:12px}
body.performance .song-heading{grid-template-columns:1fr}
@media(max-width:900px){
.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 200px;gap:12px}
.song-notes{display:none}.tray-chords{gap:6px}.chord-tray{padding:12px}.sheet-viewport{padding:18px}
.song-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.hero-chords{display:none}
.chord-sheet[style]{display:block!important}
}
@media(max-width:600px){
.home-view{padding:12px 16px;gap:12px}.hero{padding:8px 0}.hero h1{font-size:32px}.hero>p:not(.eyebrow){font-size:13px}.hero .eyebrow{font-size:10px;margin-bottom:8px}
.song-grid{grid-template-columns:1fr}.song-card{min-height:110px}.song-card h3{margin-top:10px}
.song-view{gap:10px;padding:12px}.song-heading{grid-template-columns:auto 1fr auto}.song-heading-actions{grid-column:auto}.song-heading-actions .wide{padding:8px}.song-heading .eyebrow{font-size:9px}.song-heading h1{font-size:28px}
.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 112px;gap:8px}
.sheet-viewport{padding:12px 8px}.chord-sheet{padding:0}.chord-tray{padding:10px 6px;gap:10px;border-radius:12px}.tray-chords{grid-template-columns:1fr}.tray-intro{gap:5px}.tray-intro small{font-size:8px}.tray-intro strong{font-size:12px}.live-dot{width:5px;height:5px;flex-shrink:0}.mirror-btn{font-size:12px;padding:4px}.mirror-btn span{display:inline}
}
@media(max-height:650px){.home-view{gap:10px;padding-block:10px}.hero{padding:0}.hero h1{font-size:30px}.hero h1 br{display:none}.hero>p:not(.eyebrow){margin:6px 0}.hero .eyebrow{display:none}.song-view{gap:8px;padding-block:8px}.song-heading .eyebrow{display:none}.song-heading h1{font-size:26px}.song-heading p:not(.eyebrow){font-size:13px}}
}
@media print{.player-sidebar{display:none!important}.sheet-viewport{overflow:visible;padding:0;border:0}.song-stage{display:block}.inline-chord{border:0;background:none;padding:0;font:inherit;font-weight:bold;line-height:1;top:0}.lyric-token{padding-top:1.2em}.fretboard{width:106px}}

@media screen and (max-width:600px){.player-toolbar{min-height:66px;max-height:76px}.chord-tray .fretboard{width:58px}.chord-chip{padding:5px 3px;gap:1px}.chord-chip>strong{font-size:17px}.chord-tray{gap:8px}.tray-chords{gap:5px}}
/* Solid floating controls; scrolling stays available without visible tracks. */
@media screen {
.topbar{background:var(--bg);backdrop-filter:none}
.player-toolbar,.chord-tray{background:var(--surface);backdrop-filter:none}
.sheet-viewport,.player-sidebar,.tray-chords,.player-toolbar,.song-grid,.browse-list,#libraryContent{scrollbar-width:none;scrollbar-gutter:auto}
.sheet-viewport::-webkit-scrollbar,.player-sidebar::-webkit-scrollbar,.tray-chords::-webkit-scrollbar,.player-toolbar::-webkit-scrollbar,.song-grid::-webkit-scrollbar,.browse-list::-webkit-scrollbar,#libraryContent::-webkit-scrollbar{display:none;width:0;height:0}
.song-stage{isolation:isolate}
.player-sidebar{position:relative;z-index:2;overflow:hidden;padding:2px 2px 8px;gap:12px}
.chord-tray{flex:1;min-height:0;overflow:hidden;border:1px solid var(--line);border-top-color:var(--accent-2);border-radius:20px;box-shadow:0 8px 24px rgba(0,0,0,.2);gap:12px;padding:16px}
.tray-intro,.mirror-btn{flex-shrink:0}
.tray-intro strong{font-size:15px}
.tray-chords{flex:1;min-height:0;grid-auto-rows:minmax(0,1fr);align-items:stretch;overflow:auto;gap:8px}
.chord-chip{min-height:0;overflow:hidden;justify-content:center;background:var(--bg);padding:8px 5px;gap:3px}
.chord-full-name{display:block;font-size:11px;line-height:1.2;color:var(--muted);font-weight:500}
.chord-tray .fretboard{width:clamp(50px,9vh,88px);min-height:0;flex:0 1 auto}
.mirror-btn{padding:6px;font-size:12px}
.song-notes{flex-shrink:0;background:var(--surface);padding:14px;gap:10px}
.song-notes .shortcut-note{display:none}
.tool-label{font-size:11px;letter-spacing:.03em;text-transform:none}
#capoValue{min-width:55px;font-size:14px;white-space:nowrap}
.modal-card .fretboard{width:190px;max-width:100%;margin:auto}
@media(max-width:900px){.song-notes{display:grid}.song-notes>div:last-of-type{display:none}.chord-tray{padding:10px}.chord-full-name{font-size:10px}}
@media(max-width:600px){
.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 120px}
.chord-tray{padding:8px 5px;gap:6px;border-radius:14px}.chord-tray .fretboard{width:clamp(32px,7vh,58px)}
.tray-intro strong{font-size:11px}.tray-chords{gap:5px}.chord-chip{padding:4px 2px;gap:1px}.chord-full-name{font-size:9px}.mirror-btn{font-size:10px;padding:4px 0}
.song-notes{grid-template-columns:1fr;padding:8px;gap:6px}.song-notes small{font-size:8px}.song-notes strong{font-size:12px}.song-notes>div:nth-child(2){display:none}
}
@media(max-height:600px){.song-notes{display:none}.chord-tray{gap:6px;padding:8px}.chord-full-name{font-size:9px}.chord-tray .fretboard{width:52px}.mirror-btn{padding:2px}}
}
/* Crisp, scalable guitar diagrams shared by hover cards and the chord dock. */
.fretboard .neck-body{fill:#263144;stroke:#526078;stroke-width:1}
.fretboard .fret-wire{stroke:#8995a7;stroke-width:1.6;fill:none}
.fretboard .guitar-string{stroke:#d5dce7;fill:none}
.fretboard .guitar-nut{stroke:#fff5d9;stroke-width:6;fill:none}
.fretboard .finger-shadow{fill:#09121c;opacity:.65}
.fretboard .finger-dot{fill:#70efd5;stroke:#c6fff2;stroke-width:1.4}
.fretboard .finger-barre{stroke:#70efd5;stroke-width:17;stroke-linecap:round;fill:none}
.fretboard .muted-string{stroke:var(--muted);stroke-width:2;fill:none}
.fretboard .open-string{stroke:var(--accent-2);stroke-width:2;fill:none}
.fretboard .string-label{font:600 12px ui-sans-serif,system-ui;fill:var(--muted);text-anchor:middle}
.fretboard .fret-number{font:11px ui-sans-serif,system-ui;fill:var(--muted);text-anchor:middle}
.chord-preview{position:fixed;z-index:90;width:286px;max-width:calc(100vw - 24px);max-height:calc(100dvh - 24px);overflow:auto;pointer-events:none;padding:20px;background:var(--surface);border:1px solid var(--line);border-top:2px solid var(--accent-2);border-radius:20px;box-shadow:0 20px 65px #0008;animation:chord-appear .14s ease-out}
.chord-preview[hidden]{display:none}
.diagram-heading{display:flex;align-items:center;gap:14px;text-align:left}
.diagram-symbol{font:800 36px ui-sans-serif,system-ui;color:var(--accent);letter-spacing:-.04em}
.diagram-heading strong{display:block;font-size:15px;color:var(--text)}
.diagram-heading small{display:block;margin-top:4px;font-size:10px;color:var(--muted)}
.chord-preview .fretboard{width:204px;max-width:100%;height:auto;margin:14px auto 10px}
.diagram-legend{display:flex;justify-content:center;gap:12px;padding-top:12px;border-top:1px solid var(--line);font-size:11px;color:var(--muted)}
.diagram-legend span{display:flex;gap:5px;align-items:center}
.diagram-legend i{width:8px;height:8px;background:var(--accent-2);border-radius:50%}
.diagram-capo{font-size:11px;line-height:1.6;color:var(--muted);text-align:center;margin:12px 0 0}
.chord-detail{max-width:350px;margin:auto;padding:10px}
.modal-card .chord-detail .fretboard{width:260px;margin:20px auto}
.chord-detail .diagram-symbol{font-size:48px}
.inline-chord:hover,.inline-chord:focus-visible{color:var(--accent-2);text-shadow:0 0 14px #63dec640}
.chord-chip:hover,.chord-chip:focus-visible{border-color:var(--accent-2);background:var(--surface-2)}
@keyframes chord-appear{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}
@media(prefers-reduced-motion:reduce){.chord-preview{animation:none}}

/* Compact hover preview; the click-to-open diagram keeps its detailed size. */
.chord-preview{width:108px;padding:7px;border-radius:11px;box-shadow:0 8px 24px #0006;overflow:hidden}
.chord-preview .diagram-heading{justify-content:center;gap:0}
.chord-preview .diagram-symbol{font-size:19px;line-height:1.1}
.chord-preview .diagram-heading>div,.chord-preview .diagram-legend,.chord-preview .diagram-capo{display:none}
.chord-preview .fretboard{width:86px;margin:4px auto 0}
/* The playing dock preserves diagram size; extra chords use explicit pages. */
@media screen{
.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 300px}
.player-sidebar{padding:0 2px 6px}
.player-sidebar .song-notes{display:none}
.chord-tray{flex:1;padding:14px;gap:10px;min-height:0}
.tray-chords{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:190px;align-content:start;align-items:stretch;gap:10px;overflow:hidden;flex:1;min-height:0}
.chord-tray .chord-chip{height:190px;min-height:190px;flex-shrink:0;padding:7px 4px;gap:3px;justify-content:center;overflow:visible}
.chord-tray .chord-chip>strong{font-size:22px;line-height:1.1;flex-shrink:0}
.chord-tray .chord-full-name{font-size:11px;line-height:1.1;flex-shrink:0}
.chord-tray .chord-chip .fretboard{width:106px;height:135px;min-height:135px;max-width:100%;flex:none;margin:0}
.tray-scope{display:flex;flex-shrink:0;gap:4px;background:var(--bg);padding:4px;border-radius:9px}
.tray-scope button{flex:1;border:0;background:none;color:var(--muted);font-size:11px;padding:7px 3px;border-radius:6px}
.tray-scope button.active{background:var(--surface-2);color:var(--accent-2)}
.tray-pager{display:flex;align-items:center;justify-content:space-between;gap:5px;flex-shrink:0;font-size:11px;color:var(--muted)}
.tray-pager button{border:1px solid var(--line);background:var(--bg);border-radius:7px;color:var(--text);width:30px;height:28px}
.tray-pager button:disabled{opacity:.25;cursor:default}
.tray-empty{grid-column:1/-1;font-size:12px;color:var(--muted)}
.chord-tray .mirror-btn{padding:3px;font-size:11px}
@media(max-width:900px){.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 260px}}
@media(max-width:600px){.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 132px}.chord-tray{padding:8px 5px;gap:7px}.tray-chords{grid-template-columns:1fr}.tray-scope{flex-direction:column;padding:2px}.tray-scope button{padding:4px;font-size:10px}.tray-pager{font-size:9px;flex-wrap:wrap;justify-content:center}.tray-pager span{order:-1;width:100%;text-align:center}.tray-pager button{width:30px;height:24px}}
@media(max-height:480px){.chord-tray{overflow:auto;scrollbar-width:none}.tray-chords{flex:none;min-height:190px}.chord-tray::-webkit-scrollbar{display:none}}
}
/* Adjustable playing dock: width and diagram zoom determine grid capacity. */
@media screen{
.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 16px minmax(0,min(var(--chord-panel-width,460px),70%));gap:0}
.panel-divider{display:flex;align-items:center;justify-content:center;cursor:col-resize;touch-action:none;color:var(--muted);outline-offset:-3px}
.panel-divider span{display:grid;place-items:center;width:8px;height:48px;border-radius:8px;background:var(--surface-2);font-size:17px;transition:background .15s}
.panel-divider:hover span,.panel-divider:focus-visible span{background:var(--accent-2);color:var(--bg)}
.resizing-panel,.resizing-panel *{cursor:col-resize!important;user-select:none!important}
.chord-tray{padding:12px;gap:9px}
.tray-intro strong{font-size:13px}.tray-intro small{font-size:9px}
.tray-scope{flex-direction:row;padding:3px}.tray-scope button{padding:5px;font-size:11px}
.diagram-zoom{display:flex;gap:8px;align-items:center;flex-shrink:0;font-size:11px;color:var(--muted)}
.diagram-zoom>span{margin-right:auto}
.diagram-zoom button{width:26px;height:26px;border:1px solid var(--line);border-radius:7px;background:var(--bg);color:var(--text);font-size:17px}
.diagram-zoom button:disabled{opacity:.3;cursor:default}.diagram-zoom output{min-width:32px;text-align:center;font-size:10px;font-variant-numeric:tabular-nums}
.chord-tray .tray-chords{grid-auto-rows:var(--diagram-row,138px);gap:8px;min-height:0;flex:1;overflow:hidden}
.chord-tray .chord-chip{height:var(--diagram-row,138px);min-height:var(--diagram-row,138px);padding:4px;gap:1px;justify-content:center}
.chord-tray .chord-chip>strong{font-size:14px;line-height:18px}
.chord-tray .chord-chip .chord-full-name{display:none}
.chord-tray .chord-chip .fretboard{width:var(--diagram-size,85px);height:auto;min-height:0;max-width:100%;flex:none}
.tray-pager{flex-wrap:nowrap;font-size:10px}.tray-pager span{order:0;width:auto}.tray-pager button{height:24px;width:28px}
@media(max-width:600px){.song-stage,body.performance .song-stage{grid-template-columns:minmax(0,1fr) 12px minmax(0,min(var(--chord-panel-width,160px),65%))}.chord-tray{padding:7px;gap:6px}.diagram-zoom{gap:4px}.diagram-zoom>span{display:none}.diagram-zoom{justify-content:center}.tray-scope button{font-size:9px;padding:4px}.tray-intro strong{font-size:11px}}
@media(max-height:480px){.chord-tray{overflow:hidden}.chord-tray .tray-chords{flex:1;min-height:0}}
}
@media print{.panel-divider{display:none}}
/* Compact dock chrome: one header, one footer, maximum room for diagrams. */
@media screen{
.chord-tray{padding:9px;gap:7px}
.dock-header{display:flex;align-items:center;gap:8px;flex-shrink:0;min-height:28px;flex-wrap:wrap}
.dock-section{font-size:11px;line-height:1.2;color:var(--text);flex:1;min-width:35px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.dock-header .tray-scope{padding:2px;gap:1px;flex-shrink:0}
.dock-header .tray-scope button{padding:4px 6px;font-size:10px;flex:none;line-height:16px}
.dock-header .diagram-zoom{gap:3px;justify-content:flex-end;margin-left:auto}
.dock-header .diagram-zoom button{width:24px;height:24px;font-size:16px;border-radius:6px;line-height:1;padding:0}
.dock-header .diagram-zoom output{font-size:9px;min-width:27px}
.dock-header .diagram-zoom #diagramFit{width:29px;font-size:10px}
#diagramFit.active{color:var(--accent-2);border-color:var(--accent-2)}
.dock-footer{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:25px;flex-shrink:0;border-top:1px solid var(--line);padding-top:5px}
.dock-footer .tray-pager{display:flex;gap:5px;font-size:10px;flex-wrap:nowrap}
.dock-footer .tray-pager button{width:23px;height:23px;padding:0}
.dock-footer .tray-pager button[hidden]{display:none}
.dock-footer .mirror-btn{font-size:10px;padding:2px 4px;white-space:nowrap}
.chord-tray .chord-chip{padding:3px;gap:0}
.chord-tray .chord-chip>strong{font-size:13px;line-height:17px}
@media(max-width:600px){.dock-header{gap:4px}.dock-section{flex-basis:100%}.dock-header .diagram-zoom{margin-left:0}.dock-footer{gap:3px;flex-wrap:wrap}.dock-footer .mirror-btn{font-size:9px}.chord-tray{padding:5px;gap:5px}}
}
/* Release 0.5: shared top edge for the compact toolbar and chord dock. */
.version-badge{font-size:10px;font-weight:700;border:1px solid var(--line);border-radius:7px;color:var(--accent-2);background:var(--surface);padding:4px 6px;white-space:nowrap}
.version-entry{margin-top:22px;padding:18px;border:1px solid var(--line);border-radius:12px}
.version-entry p{color:var(--muted);font-size:14px;line-height:1.7}
@media screen{
.topbar{grid-template-columns:auto auto minmax(180px,620px) auto;gap:18px}
.song-stage,body.performance .song-stage{grid-template-rows:auto minmax(0,1fr);row-gap:12px}
.song-stage>.player-toolbar{grid-column:1;grid-row:1;display:flex;flex-wrap:wrap;align-content:center;align-items:center;gap:4px;padding:7px;min-height:64px;max-height:none;overflow:visible;z-index:5}
.song-stage>.sheet-viewport{grid-column:1;grid-row:2}
.song-stage>.panel-divider{grid-column:2;grid-row:1 / 3}
.song-stage>.player-sidebar{grid-column:3;grid-row:1 / 3}
.player-toolbar .tool-group{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;padding:0 7px 0 0;min-height:48px}
.player-toolbar .tool-label{margin:0;font-size:9px;line-height:12px;white-space:nowrap}
.tool-values{display:flex;align-items:center;gap:1px}
.player-toolbar .tool-values button{min-width:25px;width:25px;height:27px;padding:2px;font-size:16px}
.player-toolbar .tool-values strong{min-width:26px;font-size:14px}
.player-toolbar #capoValue{min-width:48px;font-size:12px}
.player-toolbar button:disabled{opacity:.3;cursor:default}
.player-toolbar .tool-toggle{min-width:46px!important;padding:5px;gap:2px}
.player-toolbar .tool-toggle small{font-size:9px}
.player-toolbar .speed-control{min-width:72px;padding:0 5px}.player-toolbar .speed-control input{width:64px}
.player-toolbar .tool-group:has(#fontDown){flex-direction:row;border:0;gap:0;padding:0}.player-toolbar #fontDown,.player-toolbar #fontUp{min-width:29px;padding:5px}
.chord-sheet[data-columns="1"]{display:block!important}
.chord-sheet[data-columns="2"],.chord-sheet[data-columns="3"]{display:grid!important;grid-template-columns:repeat(var(--columns),minmax(0,1fr));gap:24px;align-items:start}
@media(max-width:900px){.topbar{grid-template-columns:auto auto 1fr;gap:10px}.nav-actions{grid-column:1/-1}.global-search{grid-column:3;grid-row:1}}
@media(max-width:600px){.topbar{grid-template-columns:auto auto 1fr}.topbar .version-badge{grid-column:2;grid-row:1;justify-self:start}.topbar .global-search{grid-column:1/-1;grid-row:2}.topbar .nav-actions{grid-column:3;grid-row:1}.song-stage>.player-toolbar{gap:2px;padding:5px}.player-toolbar .tool-group{padding-right:3px}.player-toolbar .tool-toggle{min-width:39px!important}.player-toolbar .tool-toggle small{font-size:8px}.song-stage,body.performance .song-stage{row-gap:8px}}
}
.about-view{max-width:1120px}
.about-scroll{min-height:0;overflow:auto;overscroll-behavior:contain;padding:2px 8px 30px 2px;scrollbar-width:none}
.about-scroll::-webkit-scrollbar{display:none}
.about-view .page-head{flex-shrink:0;align-items:center}
.about-view .page-head h1{font-size:clamp(28px,4vw,44px)}
.release-pill{border:1px solid var(--line);border-radius:99px;padding:8px 13px;font-size:12px;color:var(--accent-2);background:var(--surface);white-space:nowrap}
.about-intro{display:flex;gap:26px;align-items:flex-start;padding:30px;border:1px solid var(--line);border-radius:20px;background:var(--surface)}
.about-mark{display:grid;place-items:center;flex-shrink:0;width:62px;height:62px;border-radius:18px;background:var(--accent);color:var(--bg);font-weight:900;font-size:25px;letter-spacing:-3px}
.about-intro h2{font-size:27px;letter-spacing:-.035em;margin:0 0 14px}
.about-intro p{font-size:15px;line-height:1.8;color:var(--muted);margin:8px 0;max-width:740px}
.about-features{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-top:18px}
.about-features article{padding:22px;border:1px solid var(--line);border-radius:16px;background:var(--surface)}
.about-features h3{margin:0 0 10px;font-size:15px;color:var(--accent-2)}
.about-features p{margin:0;font-size:13px;line-height:1.8;color:var(--muted)}
.release-heading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin:40px 0 20px}
.release-heading .eyebrow{margin-bottom:8px}.release-heading h2{margin:0;font-size:28px;letter-spacing:-.035em}
.release-heading>p{font-size:12px;line-height:1.8;color:var(--muted)}
.release-entry{display:grid;grid-template-columns:155px minmax(0,1fr);gap:24px;padding:26px 0;border-top:1px solid var(--line)}
.release-meta{display:flex;align-items:flex-start;flex-wrap:wrap;gap:8px;align-content:flex-start}
.release-meta>strong{font-size:22px;color:var(--accent);letter-spacing:-.025em}
.release-current{font-size:9px;color:var(--accent-2);border:1px solid var(--line);padding:4px 6px;border-radius:6px;margin-top:3px}
.release-meta time{width:100%;font-size:11px;color:var(--muted);margin-top:3px}
.release-content h3{margin:0 0 12px;font-size:18px}.release-content ul{margin:0;padding-left:18px;color:var(--muted);font-size:13px;line-height:1.8}.release-content li+li{margin-top:6px}
.about-storage-note{font-size:11px;color:var(--muted);line-height:1.7;border-top:1px solid var(--line);padding-top:18px}
@media(max-width:700px){.about-features{grid-template-columns:1fr;gap:10px}.about-intro{padding:20px;gap:14px}.about-mark{width:40px;height:40px;font-size:20px;border-radius:12px}.about-intro h2{font-size:22px}.about-intro p{font-size:13px}.release-entry{grid-template-columns:1fr;gap:14px}.release-meta time{width:auto;margin-left:auto;align-self:center}.release-heading{align-items:flex-start;flex-direction:column;gap:5px}.release-heading>p{margin:0}.nav-actions #aboutBtn{display:inline-flex;padding:8px;font-size:12px}.about-view .page-head{flex-direction:row;align-items:center}}
.language-switch{display:flex;align-items:center;gap:2px;padding:3px;border:1px solid var(--line);border-radius:9px;background:var(--surface);flex-shrink:0}
.language-switch button{display:inline-flex;align-items:center;justify-content:center;gap:4px;border:0;border-radius:6px;background:none;color:var(--muted);padding:6px;font-size:10px;font-weight:700;white-space:nowrap}
.language-flag{display:block;width:18px;height:13px;object-fit:cover;border-radius:2px;flex-shrink:0}
.language-switch button.active{color:var(--accent-2);background:var(--surface-2)}
@media screen{.topbar{gap:12px;grid-template-columns:auto auto minmax(150px,1fr) auto}.nav-actions{gap:3px}.nav-actions .ghost{padding:9px;font-size:13px}.nav-actions .button.compact{font-size:13px;padding:10px}.topbar .brand{gap:7px}
@media(max-width:1100px){.topbar{grid-template-columns:auto auto 1fr;height:auto;min-height:72px;padding:10px 16px;gap:8px}.topbar .global-search{grid-column:3;grid-row:1}.topbar .nav-actions{grid-column:1/-1;justify-content:flex-end}}
@media(max-width:600px){.topbar{grid-template-columns:auto auto 1fr}.topbar .global-search{grid-column:1/-1;grid-row:2}.topbar .nav-actions{grid-column:3;grid-row:1;gap:5px}.language-switch button{padding:5px 3px;font-size:9px}.nav-actions .button.compact{font-size:11px;padding:8px}.nav-actions #aboutBtn{font-size:11px;padding:5px}}
}

.song-version-badge{display:inline-block;margin:4px 8px;padding:2px 8px;border:1px solid currentColor;border-radius:12px;font-size:11px;color:var(--accent,#7acfa4)}
#songVersionControl{font-size:12px} #songVersion{max-width:180px;padding:8px;border-radius:8px;background:var(--panel,#20262d);color:inherit} #songVersionControl[hidden]{display:none}

/* Mobile playing workspace: chord dock above an independently scrolling sheet. */
@media screen {
  .song-stage,body.performance .song-stage{grid-template-rows:auto minmax(0,1fr) auto}
  .song-stage>.panel-divider,.song-stage>.player-sidebar{grid-row:1 / 4}
  .player-playback{grid-column:1;grid-row:3;display:flex;align-items:center;gap:12px;padding:6px 10px;border:1px solid var(--line);border-radius:12px;background:var(--surface);min-width:0}
  #scrollBtn{display:flex;align-items:center;justify-content:center;gap:9px;min-height:44px;flex-shrink:0;border:1px solid var(--line);border-radius:10px;padding:8px 12px;background:var(--surface-2);color:var(--text)}
  #scrollBtn.active{background:var(--accent);color:var(--bg)}
  .player-playback .speed-control{display:flex;align-items:center;gap:8px;min-width:0;flex:1;font-size:12px}
  .player-playback .speed-control[hidden]{display:none}
  #speedRange{width:100%;min-width:45px;height:44px;accent-color:var(--accent);cursor:pointer}
  #speedValue{min-width:16px;font-variant-numeric:tabular-nums}
  .chord-tray .tray-chords.show-all{overflow:auto;overscroll-behavior:contain;align-content:start}
  .song-stage.tray-hidden{grid-template-columns:minmax(0,1fr)}
  .song-stage.tray-hidden>.player-sidebar,.song-stage.tray-hidden>.panel-divider{display:none}
}
@media screen and (max-width:1100px) {
  .song-view,body.performance .song-view{padding:8px 12px max(8px,env(safe-area-inset-bottom));gap:8px}
  .song-heading,body.performance .song-heading{display:flex;align-items:center;gap:10px}
  .song-heading>div:nth-child(2){flex:1;min-width:0}
  .song-heading h1,body.performance .song-heading h1{font-size:clamp(20px,3.5vw,30px);line-height:1.08;letter-spacing:-.03em}
  .song-heading p:not(.eyebrow){font-size:12px;margin:4px 0 0}
  .song-heading .eyebrow{display:none}
  .song-heading-actions{flex-wrap:wrap;gap:2px;max-width:170px;justify-content:flex-end}
  .song-heading-actions .wide{min-width:40px;min-height:40px;padding:8px}
  .song-heading-actions .wide span{display:none}
  #songVersionControl{font-size:0;width:100%;text-align:right}
  #songVersion{font-size:12px;min-height:40px;max-width:160px}
  .song-stage,body.performance .song-stage{
    grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,var(--chord-panel-height,230px)) 22px auto minmax(0,1fr) auto;gap:0;min-width:0
  }
  .song-stage>.player-sidebar{grid-column:1;grid-row:1;padding:0;min-width:0}
  .song-stage>.panel-divider{grid-column:1;grid-row:2;cursor:row-resize;min-height:22px;z-index:6}
  .panel-divider span{width:64px;height:5px;font-size:0;border-radius:8px;background:var(--muted)}
  .resizing-panel,.resizing-panel *{cursor:row-resize!important}
  .song-stage>.player-toolbar{grid-column:1;grid-row:3;flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;min-height:48px;max-height:58px;gap:8px;padding:3px 6px;margin-bottom:6px;border-radius:10px}
  .player-toolbar>*{flex-shrink:0}
  .player-toolbar .tool-group{min-height:44px;gap:0}
  .player-toolbar .tool-values button{min-width:34px;height:32px}
  .player-toolbar .tool-toggle{min-height:44px;min-width:44px!important}
  .player-toolbar #fontDown,.player-toolbar #fontUp{min-width:40px;min-height:44px}
  .player-toolbar .column-controls,.player-toolbar #printBtn{display:none}
  .song-stage>.sheet-viewport{grid-column:1;grid-row:4;padding:14px 12px;min-width:0;touch-action:pan-y;overflow-x:hidden}
  .song-stage>.player-playback{grid-column:1;grid-row:5;margin-top:6px;padding:3px 7px;gap:8px}
  .chord-sheet[data-columns]{display:block!important;column-count:1!important}
  .song-line{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.65;min-height:2.6em}
  .lyric-token{max-width:100%;white-space:pre-wrap;overflow-wrap:anywhere}
  .chord-tray{padding:8px 10px;gap:6px;border-radius:12px}
  .dock-header{flex-wrap:nowrap;gap:6px;min-height:40px}
  .dock-section{flex:1;min-width:0;font-size:11px}
  .dock-header .tray-scope button{min-height:36px;padding:6px 10px;font-size:12px}
  .dock-header .diagram-zoom{margin-left:auto;gap:3px}
  .dock-header .diagram-zoom button{width:34px;height:36px}
  .dock-header .diagram-zoom #diagramFit{width:40px}
  .dock-header .diagram-zoom output{display:none}
  .dock-footer{flex-wrap:nowrap;min-height:26px;padding-top:2px}
  .dock-footer .mirror-btn{font-size:11px;min-height:28px;padding:3px 6px}
  .dock-footer .tray-pager{font-size:11px}
  .song-stage.tray-hidden{grid-template-columns:minmax(0,1fr);grid-template-rows:0 0 auto minmax(0,1fr) auto}
  .topbar .version-badge{display:none}
}
@media screen and (max-width:600px) {
  .topbar{padding:6px 12px;gap:6px;min-height:0}
  .topbar .global-search input{height:38px;font-size:14px}
  .topbar .brand-mark{width:30px;height:30px}
  .song-view{padding-inline:8px}
  .song-heading-actions{max-width:140px}
  .song-heading-actions .wide{min-height:36px;padding:6px}
  .dock-header .diagram-zoom #diagramZoomOut,.dock-header .diagram-zoom #diagramZoomIn{display:none}
  .dock-header .dock-section{flex-basis:auto}
  .dock-header .diagram-zoom{margin-left:auto}
  .dock-footer .mirror-btn span{display:none}
  .song-line{font-size:var(--sheet-size);line-height:1.7}
  .player-playback .speed-control>span{display:none}
  #scrollBtn{font-size:12px;padding-inline:10px}
}
@media screen and (max-height:500px) and (max-width:1100px){
  .topbar{display:none}.song-heading h1{font-size:18px}.song-heading p:not(.eyebrow){display:none}
  .song-view{gap:3px}.song-stage>.player-toolbar{max-height:46px;min-height:42px}
}

@media screen and (max-height:500px) and (max-width:1100px){
 .dock-footer{display:none}.dock-header{min-height:30px}.dock-header .tray-scope button{min-height:30px;padding-block:3px}
 .dock-header .diagram-zoom button{height:30px}.chord-tray{padding:4px 8px;gap:3px}
}

/* Fit diagrams evenly across the available chord panel. */
@media screen {
 .chord-tray .tray-chords.balanced{align-content:stretch;align-items:stretch}
 .chord-tray .tray-chords.balanced .chord-chip{height:var(--diagram-row);min-height:var(--diagram-row);width:100%;padding:3px;justify-content:center}
 .chord-tray .tray-chords.balanced .chord-chip>strong{font-size:16px;line-height:20px}
}

/* Compact dock controls; zoom remains available on touch screens. */
@media screen {
 .chord-tray{gap:4px;padding-block:6px}
 .dock-footer{min-height:20px;height:20px;flex:0 0 20px;padding-top:0;gap:4px;align-items:center}
 .dock-footer .tray-pager{line-height:14px;font-size:10px}
 .dock-footer .tray-pager button{height:18px;min-height:18px}
 .dock-footer .mirror-btn{height:20px;min-height:20px;padding:0 4px;font-size:10px;line-height:18px}
 .dock-header .diagram-zoom #diagramFit{width:auto;min-width:62px;padding:0 7px;font-size:11px}
 .dock-header .diagram-zoom output{display:block;min-width:32px}
 .dock-header .diagram-zoom #diagramZoomOut,.dock-header .diagram-zoom #diagramZoomIn{display:inline-flex;align-items:center;justify-content:center;width:34px;height:36px}
}
@media screen and (max-width:600px){
 .dock-header{gap:4px;min-height:38px}
 .dock-header .dock-section{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
 .dock-header .tray-scope button{padding:5px 7px;font-size:11px}
 .dock-header .diagram-zoom{margin-left:auto;gap:3px}
 .dock-header .diagram-zoom output{font-size:10px}
 .chord-tray{padding:5px 8px;gap:3px}
}
@media screen and (max-width:360px){.dock-header .diagram-zoom output{display:none}}
@media screen and (max-height:500px) and (max-width:1100px){.dock-footer{display:none}}

/* Choose where the chord dock sits; share one compact control bar. */
@media screen {
 .song-stage[data-panel-position],body.performance .song-stage[data-panel-position]{gap:0;row-gap:0}
 .song-stage[data-panel-position]>.player-toolbar{grid-area:tools;margin:0;min-width:0;max-height:62px;min-height:54px;overflow:auto;flex-wrap:nowrap;gap:8px;padding:4px 6px}
 .song-stage[data-panel-position]>.player-sidebar{grid-area:chords;min-width:0;padding:0}
 .song-stage[data-panel-position]>.sheet-viewport{grid-area:lyrics;min-width:0}
 .song-stage[data-panel-position]>.panel-divider{grid-area:divider}
 .song-stage[data-panel-position="top"]{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,var(--chord-panel-height,260px)) 18px auto minmax(0,1fr);grid-template-areas:"chords" "divider" "tools" "lyrics"}
 .song-stage[data-panel-position="bottom"]{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto 18px minmax(0,var(--chord-panel-height,260px));grid-template-areas:"lyrics" "tools" "divider" "chords"}
 .song-stage[data-panel-position="left"]{grid-template-columns:minmax(0,var(--chord-panel-width,320px)) 18px minmax(0,1fr);grid-template-rows:auto minmax(0,1fr);grid-template-areas:"tools tools tools" "chords divider lyrics"}
 .song-stage[data-panel-position="right"]{grid-template-columns:minmax(0,1fr) 18px minmax(0,var(--chord-panel-width,320px));grid-template-rows:auto minmax(0,1fr);grid-template-areas:"tools tools tools" "lyrics divider chords"}
 .song-stage[data-panel-position].tray-hidden{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr);grid-template-areas:"tools" "lyrics"}
 .song-stage[data-panel-position] .player-playback{display:flex;align-items:center;gap:6px;padding:0;border:0;margin:0;background:none;flex:0 0 auto}
 .player-toolbar .player-playback #scrollBtn{width:40px;height:42px;min-height:42px;padding:0}
 .player-toolbar .player-playback #scrollBtn>span:last-child{display:none}
 .player-toolbar .player-playback .speed-control{gap:4px;flex:none}
 .player-playback .speed-control>span{display:none}
 .player-playback #speedRange{width:80px;min-width:60px;height:40px}
 .panel-position-control{display:flex;flex-direction:column;gap:2px;flex:none;font-size:9px;color:var(--muted)}
 #panelPosition{max-width:112px;min-height:30px;padding:3px 5px;border:1px solid var(--line);border-radius:7px;background:var(--surface);color:var(--text);font-size:12px}
 .song-stage[data-panel-position="left"] .dock-header,.song-stage[data-panel-position="right"] .dock-header{flex-wrap:wrap}
 .song-stage[data-panel-position="left"] .dock-section,.song-stage[data-panel-position="right"] .dock-section{flex-basis:100%}
 .song-stage[data-panel-position="left"] .diagram-zoom,.song-stage[data-panel-position="right"] .diagram-zoom{flex-wrap:wrap;justify-content:center;margin:auto}
 .song-stage[data-panel-position="left"] .tray-scope,.song-stage[data-panel-position="right"] .tray-scope{margin:auto}
 .song-stage[data-panel-position="top"]>.panel-divider,.song-stage[data-panel-position="bottom"]>.panel-divider{cursor:row-resize;min-height:18px}
 .song-stage[data-panel-position="top"]>.panel-divider span,.song-stage[data-panel-position="bottom"]>.panel-divider span{width:64px;height:5px;font-size:0}
 .song-stage[data-panel-position="left"]>.panel-divider,.song-stage[data-panel-position="right"]>.panel-divider{cursor:col-resize;min-height:0}
 .song-stage[data-panel-position="left"]>.panel-divider span,.song-stage[data-panel-position="right"]>.panel-divider span{width:5px;height:64px;font-size:0}
 body.resizing-panel,body.resizing-panel *{cursor:col-resize!important}
 body.resizing-panel.horizontal-panel,body.resizing-panel.horizontal-panel *{cursor:row-resize!important}
}

@media screen {
 .song-stage[data-panel-position="left"] .dock-header,.song-stage[data-panel-position="right"] .dock-header{min-width:0;justify-content:center}
 .song-stage[data-panel-position="left"] .diagram-zoom,.song-stage[data-panel-position="right"] .diagram-zoom{width:100%;min-width:0;max-width:100%;flex-shrink:1}
 .song-stage[data-panel-position="left"] .tray-scope,.song-stage[data-panel-position="right"] .tray-scope{max-width:100%;flex-shrink:1}
 .song-stage[data-panel-position="left"] .dock-header .diagram-zoom output,.song-stage[data-panel-position="right"] .dock-header .diagram-zoom output{display:none}
 .song-stage[data-panel-position="left"] .dock-section,.song-stage[data-panel-position="right"] .dock-section{display:none}
}

/* 0.8.56: the app shell (html, body, main) never scrolls; every view is its own scroll area. Home, Browse, Library, About
   and the player scroll an inner region; Tools and the setlist page have none, so the view itself is the scroll area. */
#toolsView,#setlistView{overflow-y:auto;overflow-x:hidden;min-height:0;-webkit-overflow-scrolling:touch;overscroll-behavior-y:contain;scrollbar-width:thin}
