@import url('./shared/scene.css');
:root{color-scheme:dark;--stage-red:#a9192e;--stage-deep:#6b1226;--stage-ink:#fff3df;--stage-muted:#f3c9ba;--stage-ease:cubic-bezier(.16,1,.3,1)}
*{box-sizing:border-box}body{margin:0;background:var(--stage-red);color:var(--stage-ink);font-family:'PingFang SC','Microsoft YaHei UI','Microsoft YaHei',sans-serif;overflow-x:clip}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;color:inherit;cursor:pointer}a{color:inherit;text-decoration:none}button:focus-visible,a:focus-visible{outline:3px solid #ffe4a0;outline-offset:7px}::selection{background:#ffdf9e;color:#611226}.skip-link{position:fixed;top:-100px;left:20px;z-index:40;background:#fff3df;color:#6b1226;padding:15px}.skip-link:focus{top:10px}.stage-header{height:90px;padding:20px 4.3%;display:flex;align-items:center;justify-content:space-between;position:relative;z-index:3}.stage-wordmark{font:bold 39px/1 Georgia,serif;letter-spacing:-2px}.stage-wordmark span{color:#ffba88}.stage-header button{border:0;background:transparent;min-height:44px;padding:10px 0;font-size:12px;color:var(--stage-muted)}
.stage{position:relative;min-height:710px;height:calc(100svh - 150px);max-height:1000px;isolation:isolate;perspective:1400px}.stage:before{content:'';position:absolute;inset:0;z-index:-1;background:radial-gradient(ellipse at 50% 45%,#d14749 0,transparent 60%);pointer-events:none}.interval-scene{position:absolute;top:3%;left:25%;right:25%;text-align:center}.interval-scene h1{font-weight:400;font-size:clamp(19px,2.3vw,30px);line-height:1.4;letter-spacing:.03em;margin:0 0 6px}.interval-pair{display:flex;align-items:center;justify-content:center;gap:26px;font:normal clamp(88px,10vw,144px)/1.15 Georgia,serif;letter-spacing:-.04em;position:relative}.interval-pair>span:last-child{min-width:1.2em;text-align:left}.interval-path{display:flex;align-items:center;width:140px;gap:10px;position:relative;height:20px}.interval-path:before{content:'';position:absolute;left:0;right:0;height:1px;background:#f5c5b570}.interval-path i{width:4px;height:4px;background:#ffd8ba;border-radius:100%;flex:none;position:relative}.interval-path:after{content:'';width:8px;height:8px;border-top:1px solid;border-right:1px solid;transform:rotate(45deg);margin-left:auto}.interval-meta{display:flex;align-items:center;justify-content:center;gap:20px;font-size:13px;line-height:1.5;color:var(--stage-muted)}.interval-meta>span+span{border-left:1px solid #f3c9ba55;padding-left:20px}.interval-meta b{font-weight:500;color:var(--stage-ink);font-variant-numeric:tabular-nums}.train-link{color:#671128;background:#fff0d9;border-radius:100px;padding:12px 18px;min-height:44px;white-space:nowrap;transition:background .2s,transform .2s}.train-link:hover{background:#fff9eb;transform:translateY(-2px)}.train-link span{margin-left:14px}
.stage-instrument{position:absolute;width:min(67%,1000px);left:50%;top:43%;transform:translateX(-50%) rotateX(16deg);transform-origin:50% 100%;padding:13px 13px 8px;background:#6b1024;box-shadow:0 32px 55px #1f091655,0 4px 4px #1f091622;border-radius:12px 12px 18px 18px}.instrument-rail{display:flex;justify-content:space-between;align-items:center;padding:0 8px 12px;color:#f6c7b5;font-size:12px}.stage-keyboard{height:190px;position:relative;display:flex;touch-action:pan-y}.stage-key{border:0;position:relative;cursor:pointer;padding:0;touch-action:pan-y;font-family:Georgia,serif;transition:background .08s,color .08s}.stage-key span{position:absolute;bottom:17px;left:0;right:0;pointer-events:none;font-size:14px}.stage-white{height:100%;flex:1;background:#fff5df;color:#867369;box-shadow:inset -1px 0 #a48e79,inset 0 -7px #dfccb0;border-radius:0 0 5px 5px}.stage-black{position:absolute;top:0;height:62%;width:4.4%;z-index:2;background:#231e23;color:#e3c6b7;box-shadow:inset -2px -5px #0e0e14,inset 1px 0 #5d4549;border-radius:0 0 5px 5px}.stage-black span{bottom:11px;font-size:10px}.stage-key.is-origin:after,.stage-key.is-selected:after{content:'';position:absolute;bottom:43px;left:50%;width:6px;height:6px;background:#ac2431;border-radius:100%;transform:translateX(-50%)}.stage-key.is-selected{background:#f2a299;color:#641c2b}.stage-black.is-selected{background:#96374a;color:#fff3df}.stage-key:active{box-shadow:inset 0 8px 13px #7d352b55;transform:translateY(3px)}#demo-status{margin:12px 8px 2px;font-size:11px;color:#f8ccba;text-align:center;min-height:17px}
.portal{position:absolute;border:0;background:transparent;text-align:center;padding:15px 14px;display:flex;flex-direction:column;align-items:center;gap:14px;min-width:140px;transition:filter .2s;transform-style:preserve-3d}.portal:hover .portal-object{transform:translateY(-7px) rotate(0)}.portal-caption{display:flex;flex-direction:column;gap:6px}.portal-caption b{font-weight:500;font-size:15px;letter-spacing:.07em}.portal-caption small{font-size:11px;color:var(--stage-muted)}.portal-atlas{left:3%;top:9%;transform:rotate(-7deg)}.portal-door{right:4%;top:9%;transform:rotate(5deg)}.portal-midi{right:8%;bottom:1%;transform:rotate(-5deg)}.portal-object{display:block;position:relative;transition:transform .5s var(--stage-ease);flex:none}.book-object{width:160px;height:120px;perspective:700px;transform:rotate(-8deg);filter:drop-shadow(5px 15px 9px #14070f40)}.book-back{position:absolute;inset:5px -5px -6px;background:#4d152a;border-radius:3px 8px 8px 3px}.book-page{position:absolute;top:0;width:50%;height:100%;background:#f8e8cc;display:flex;flex-direction:column;justify-content:center;gap:8px;padding:15px 8px;color:#862132}.page-left{left:0;border-radius:7px 0 0 3px;transform:skewY(-6deg);box-shadow:inset -9px 0 15px #c5a08355}.page-right{right:0;transform:skewY(6deg);border-radius:0 7px 3px 0;box-shadow:inset 9px 0 15px #c5a08355}.book-page i{height:1px;background:#b9977c}.book-page b{font:12px Georgia,serif;position:absolute;top:40%;left:10%;background:#f8e8cc;padding:3px 0}.book-leaf{position:absolute;left:50%;top:0;width:50%;height:100%;background:#fff3d9;transform-origin:left center;animation:book-turn 3.8s ease-in-out infinite;box-shadow:inset 1px 0 #b39b80;backface-visibility:visible}.leaf-two{animation-delay:1.9s;background:#e9d7b6}@keyframes book-turn{0%,12%{transform:rotateY(0) skewY(6deg)}65%,100%{transform:rotateY(-180deg) skewY(6deg)}}
.door-object{width:92px;height:155px;perspective:650px;filter:drop-shadow(4px 14px 10px #14070f44)}.door-interior{position:absolute;inset:0;background:#41142b;border:7px solid #ee8b96;border-bottom-width:4px;border-radius:7px 7px 0 0;box-shadow:inset 0 0 26px #00000022}.door-panel{position:absolute;inset:6px 6px 4px;background:#c55571;border:3px solid #dd8095;transform-origin:left;transform:rotateY(-58deg);animation:door-open 2s var(--stage-ease) both}.door-panel i{position:absolute;right:7px;top:51%;width:8px;height:8px;border-radius:50%;background:#f9d7ad}.door-object img{position:absolute;width:117px;height:132px;object-fit:contain;left:3px;bottom:-11px;animation:cat-welcome 2.1s var(--stage-ease) both;filter:drop-shadow(0 6px 5px #360d2722)}@keyframes door-open{from{transform:rotateY(0)}to{transform:rotateY(-58deg)}}@keyframes cat-welcome{0%,22%{opacity:0;transform:translate(-5px,-6px) scale(.56)}100%{opacity:1;transform:translate(13px,7px) scale(1)}}
.midi-object{width:210px;height:96px;background:#5d142b;overflow:hidden;border-radius:6px;box-shadow:0 15px 20px #14070f22;transform:rotate(3deg)}.midi-object:before{content:'';position:absolute;inset:0;background:repeating-linear-gradient(0deg,transparent 0 15px,#f5c5b51a 15px 16px),repeating-linear-gradient(90deg,transparent 0 51px,#f5c5b51a 51px 52px)}.midi-roll{display:block;position:absolute;inset:0;width:420px;animation:midi-flow 7s linear infinite}.midi-roll i{position:absolute;left:calc(var(--n)*34px);top:calc(12px + var(--pitch)*13px);width:28px;height:8px;background:#f7c0a4;border-radius:2px}.midi-roll i:nth-child(3n){background:#dd6c7f;width:42px}.midi-needle{position:absolute;top:0;bottom:0;left:45%;width:1px;background:#ffedcf;box-shadow:none}@keyframes midi-flow{to{transform:translateX(-210px)}}
.stage-footer{min-height:60px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px 4.3%;color:#edbbae;font-size:10px}.filings{display:flex;gap:20px;flex-wrap:wrap}.filings a{display:inline-flex;align-items:center;gap:5px;min-height:30px}.quiet-lab{font-size:10px;min-height:44px;display:flex;align-items:center}.stage-footer a:hover{text-decoration:underline;text-underline-offset:5px}
.portal-dialog{border:0;padding:0;width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;color:#fff3df;background:#8c182f;overflow:auto;overscroll-behavior:contain}.portal-dialog::backdrop{background:#681126}.portal-close{position:absolute;right:4.3%;top:25px;min-height:44px;border:0;background:transparent;padding:10px;font-size:13px;z-index:3}.portal-close span{margin-left:15px;font-size:22px}.portal-focus{width:min(48vw,520px);height:52vh;position:relative;margin:9vh auto 0;display:flex;align-items:center;justify-content:center;perspective:1400px}.portal-focus .portal-object{scale:2.6;animation:none}.portal-focus .door-object{scale:2.2}.portal-focus .midi-object{scale:2.1}.portal-description{text-align:center;padding:20px 20px 55px}.portal-description h2{font-size:34px;font-weight:500;letter-spacing:.05em;margin:0 0 12px}.portal-description p{font-size:14px;line-height:1.8;color:#f3c9ba;margin:0 0 22px}.portal-enter{display:inline-flex;align-items:center;justify-content:space-between;gap:45px;padding:16px 24px;background:#fff0d9;color:#671128;border-radius:100px;font-size:15px;min-height:52px}.portal-fallback{display:block;margin:22px auto 0;color:#f3c9ba;font-size:12px;min-height:44px;padding:10px}.portal-fallback[hidden]{display:none}body:has(.portal-dialog[open]){overflow:hidden}.portal-dialog[data-kind="atlas"]{background:#782034}.portal-dialog[data-kind="midi"]{background:#361d2b}.portal-focus .book-leaf{animation-duration:2.5s}
html[data-paused] .book-leaf,html[data-paused] .midi-roll,html[data-motion="reduced"] .book-leaf,html[data-motion="reduced"] .midi-roll{animation-play-state:paused}html[data-motion="reduced"] .door-panel{animation:none}html[data-motion="reduced"] .door-object img{animation:none;transform:translate(13px,7px)}
@media(min-width:1600px){.stage-instrument{top:44%}.portal-atlas{left:6%}.portal-door{right:8%}.portal-midi{right:12%}}
@media(max-width:900px){.stage{min-height:690px}.interval-scene{left:20%;right:20%}.interval-meta{gap:10px}.interval-meta>span+span{padding-left:10px}.portal-atlas{left:0;top:15%}.portal-door{right:1%;top:14%}.book-object{width:125px;height:95px}.portal{min-width:120px}.stage-instrument{width:81%;top:44%}.stage-keyboard{height:175px}.portal-midi{bottom:0;right:5%}.midi-object{width:175px;height:80px}}
@media(max-width:600px){.stage-header{height:66px;padding:10px 21px}.stage-wordmark{font-size:33px}.stage{height:auto;min-height:0;padding:16px 14px 20px;display:flex;flex-direction:column;gap:28px}.interval-scene{position:relative;inset:auto}.interval-scene h1{font-size:20px;line-height:1.5;letter-spacing:.03em}.interval-pair{font-size:96px;gap:14px;margin:7px 0 6px}.interval-path{width:100px;gap:8px}.interval-meta{font-size:12px;gap:10px;flex-wrap:wrap}.train-link{padding:12px 15px;margin-left:2px}.train-link span{margin-left:8px}.stage-instrument{position:relative;inset:auto;width:100%;transform:none;padding:10px 7px 6px;border-radius:10px;box-shadow:0 17px 30px #1f091633}.instrument-rail{font-size:11px;padding:0 4px 10px}.stage-keyboard{height:155px}.stage-key span{font-size:11px;bottom:12px}.stage-black span{font-size:8px;bottom:9px}.stage-black{width:4.5%}.stage-key.is-selected:after,.stage-key.is-origin:after{bottom:33px;width:4px;height:4px}#demo-status{font-size:10px;margin:10px 2px 1px}.object-entrances{display:flex;align-items:flex-end;justify-content:space-around;padding:9px 0 0;gap:4px;min-height:175px}.portal{position:relative;inset:auto;transform:none;padding:7px 2px;min-width:0;flex:1;gap:15px}.portal-caption b{font-size:13px}.portal-caption small{font-size:10px;line-height:1.5;max-width:94px}.book-object{width:94px;height:72px}.book-page{padding:8px 5px;gap:5px}.book-page b{font-size:9px}.door-object{width:60px;height:102px}.door-object img{width:78px;height:87px;left:0;bottom:-5px}.door-interior{border-width:5px}.door-panel{inset:5px 5px 2px;border-width:2px}.door-panel i{width:5px;height:5px}.midi-object{width:101px;height:62px}.midi-roll i{height:6px;top:calc(8px + var(--pitch)*9px)}.stage-footer{padding:5px 20px 14px;align-items:flex-end;font-size:9px;gap:10px}.filings{gap:0;flex-direction:column}.filings a{min-height:26px}.quiet-lab{font-size:9px;white-space:nowrap}.portal-focus{width:100%;height:42vh;margin-top:13vh}.portal-focus .book-object{scale:2.9}.portal-focus .door-object{scale:2.5}.portal-focus .midi-object{scale:2.8}.portal-description h2{font-size:28px}.portal-description p{max-width:28ch;margin-left:auto;margin-right:auto}.portal-close{right:14px;top:13px}}
@media(max-width:350px){.stage{padding-left:10px;padding-right:10px;gap:23px}.interval-pair{font-size:85px}.interval-meta{gap:7px}.train-link{padding:12px 10px}.train-link span{margin-left:3px}.book-object{width:82px;height:65px}.midi-object{width:86px}.portal-caption small{max-width:84px}.stage-footer{padding-left:14px;padding-right:14px}}
.portal-dialog::backdrop{background:transparent}
.book-leaf:after{content:"F G A B";position:absolute;left:12%;right:8%;top:44%;font:12px Georgia,serif;color:#862132;border-top:1px solid #b9977c;border-bottom:1px solid #b9977c;padding:7px 0}.stage-home:not(:has(.portal-dialog[open])) .door-panel{animation-delay:1s}.stage-home:not(:has(.portal-dialog[open])) .door-object img{animation-delay:1.15s}@media(max-width:600px){.book-leaf:after{font-size:9px;padding:4px 0}}

.stage-footer,.quiet-lab{font-size:11px}.portal-caption small{font-size:12px}@media(max-width:600px){.stage-footer,.quiet-lab{font-size:11px}.portal-caption small{font-size:11px}.portal-caption b{font-size:14px}}
.book-leaf{backface-visibility:hidden;-webkit-backface-visibility:hidden}.portal-object.is-offstage .book-leaf,.portal-object.is-offstage .midi-roll{animation-play-state:paused!important}body:has(.portal-dialog[open]) .object-entrances .book-leaf,body:has(.portal-dialog[open]) .object-entrances .midi-roll{animation-play-state:paused!important}.stage-footer .filings a{min-height:44px;min-width:44px}.stage-footer .filings{min-width:0}@media(max-width:350px){.stage-footer{display:block}.stage-footer .quiet-lab{justify-content:flex-end;min-height:44px}.stage-footer .filings a{min-height:44px}}
