@font-face{font-family:LocalSerif;src:local('Noto Serif SC'),local('SimSun')}*{box-sizing:border-box} :root{color-scheme:light;--ink:#51445c;--muted:#8b7b89;--gold:#b28e5c;--line:#dac8b6;--paper:#fffaf1;--rose:#b66585;--serif:LocalSerif,'Songti SC','STSong',Georgia,serif}body{margin:0;background:#f2e8df;color:var(--ink);font-family:'Microsoft YaHei',system-ui,sans-serif}button{font:inherit;cursor:pointer;border:0;transition:transform .2s,background .2s,box-shadow .2s}button:hover:not(:disabled){transform:translateY(-2px)}button:active:not(:disabled){transform:translateY(1px)}button:focus-visible{outline:3px solid #8e609d;outline-offset:5px}button:disabled{cursor:default;opacity:.5}[hidden]{display:none!important}.screen{position:relative}.home-screen{isolation:isolate;min-height:100svh;overflow:hidden;padding:30px clamp(24px,5.3vw,88px) 20px}.home-backdrop{position:absolute;inset:0;z-index:-3;background:#eae4e2 url('assets/courtyard.png') center/cover no-repeat}.home-screen:before{content:'';position:absolute;inset:0;z-index:-2;background:linear-gradient(90deg,rgba(255,247,235,.9),rgba(255,247,235,.6) 40%,rgba(255,247,235,.04) 72%),linear-gradient(0deg,rgba(250,240,225,.97),transparent 42%)}.masthead{display:flex;justify-content:space-between;align-items:center;gap:20px}.brand-mark{font-size:26px;color:#9d7e5d;display:flex;align-items:center;gap:12px}.brand-mark span{font-size:14px;letter-spacing:.22em;color:#74616e}.masthead>div{display:flex;gap:18px;align-items:center}.quiet{background:transparent;color:var(--ink);font-size:13px;padding:12px}.round{border:1px solid #c6b399;background:#fff9ecd9;border-radius:50%;height:42px;width:42px;color:#7d625e;font-size:20px}.home-content{display:grid;grid-template-columns:1fr 1fr;align-items:center;max-width:1420px;margin:auto;min-height:490px;height:59vh;max-height:680px}.intro{padding:36px 0}.eyebrow{font-size:10px;letter-spacing:.27em;color:#a47b67;line-height:1.8}h1{font-family:var(--serif);font-size:clamp(65px,7.4vw,116px);font-weight:500;letter-spacing:.05em;line-height:1.13;margin:24px 0 12px;position:relative;width:max-content;color:#67536f;text-shadow:0 2px 0 #fff7ee}h1 span{display:block;margin-left:.65em}h1 i{font-size:.34em;position:absolute;right:-.8em;top:.22em;font-style:normal;color:#ad8a55}.subtitle{font-family:var(--serif);font-size:20px;letter-spacing:.36em;color:#957e80;margin:12px 0 22px}.intro-copy{font-size:13px;line-height:2.15;color:#8b777e}.start-group{display:flex;gap:14px;margin-top:26px;align-items:center}.primary{padding:16px 32px;background:linear-gradient(135deg,#b96d88,#965f7b);color:#fff7f2;border:1px solid #aa6f83;border-radius:5px 20px 5px 20px;box-shadow:0 8px 25px #97658124;letter-spacing:.09em;font-size:14px}.primary:hover{box-shadow:0 10px 28px #97658144}.secondary{background:#fff9edc9;color:#816b73;border:1px solid #cfb9a5;padding:15px 22px;border-radius:5px 18px 5px 18px;font-size:13px}.secondary span{margin-left:20px}.small-note{font-size:10px;color:#9b8988;letter-spacing:.04em;margin-top:17px}.character-stage{height:100%;position:relative;display:flex;align-items:center;justify-content:center;min-height:460px}.featured{width:80%;height:75%;object-fit:contain;position:absolute;bottom:17%;filter:drop-shadow(0 20px 12px #6857752b);animation:float 5s ease-in-out infinite;transform-origin:bottom center}.featured.arrive{animation:arrive .8s cubic-bezier(.2,.8,.3,1),float 5s .8s ease-in-out infinite}.stage-orbit{position:absolute;width:80%;height:18%;border:1px solid #dcc6a890;border-radius:50%;bottom:17%;background:radial-gradient(ellipse,#fff6e6b0,transparent 70%);box-shadow:0 0 50px #fff7e9}.character-caption{position:absolute;bottom:1%;text-align:center}.character-caption>span{font-family:Georgia,serif;font-size:10px;letter-spacing:.25em;color:#967963}.character-caption h2{font-family:var(--serif);font-weight:500;font-size:28px;letter-spacing:.2em;margin:9px 0}.character-caption p{font-size:12px;color:#8c7484}.stage-spark{position:absolute;color:#fffdf4;text-shadow:0 0 15px #edc178;font-size:45px;animation:twinkle 3s infinite}.s1{left:12%;top:20%}.s2{right:5%;top:52%;font-size:25px;animation-delay:1s}.roster-wrap{max-width:930px;margin:18px auto 0;position:relative}.roster-heading{display:flex;justify-content:space-between;align-items:center;font-size:12px;letter-spacing:.14em;margin:0 2px 13px}.roster-heading small{font-size:10px;color:#998888;letter-spacing:.04em}.hero-picker{display:grid;grid-template-columns:repeat(5,1fr);gap:12px}.hero-card{background:#fffaf1b8;border:1px solid #fffaf3;border-radius:10px;min-height:118px;display:grid;grid-template-columns:1fr;justify-items:center;position:relative;padding:5px 5px 12px;box-shadow:0 4px 18px #775b6710;color:#796774;animation:card-in .8s both;animation-delay:calc(var(--i)*.12s)}.hero-card img{width:100%;height:82px;object-fit:contain;transition:transform .25s;filter:drop-shadow(0 4px 4px #73546a18)}.hero-card:hover img{transform:translateY(-4px)}.hero-card strong{font-weight:400;font-size:12px;letter-spacing:.16em}.hero-card small{position:absolute;left:10px;top:10px;font-family:Georgia,serif;font-size:9px;color:#b49b80}.hero-card[aria-pressed=true]{border-color:#b78292;background:#fff9f1e8;box-shadow:0 5px 24px #b17e9626}.hero-card[aria-pressed=true]:after{content:'✦';position:absolute;right:10px;top:8px;color:#bc8c66}.home-footer{display:flex;justify-content:space-between;max-width:1420px;margin:27px auto 0;font-size:9px;letter-spacing:.14em;color:#a5918e}.sparkles{position:absolute;inset:0;z-index:-1;pointer-events:none;background-image:radial-gradient(circle,#fffbee 1px,transparent 2px),radial-gradient(circle,#fffbee 1px,transparent 3px);background-size:137px 173px,239px 277px;animation:drift 28s linear infinite;opacity:.65}.play-screen{height:100svh;background:#e8ddec;overflow:hidden;display:grid;place-items:center}#game{display:block;width:100%;height:100%;object-fit:contain;outline:none;touch-action:none}.hud{position:absolute;top:max(18px,env(safe-area-inset-top));left:25px;right:25px;display:flex;justify-content:space-between;align-items:flex-start;pointer-events:none;gap:10px}.hud button{pointer-events:auto}.health-panel{display:flex;gap:12px;padding:10px 16px 10px 8px;align-items:center;background:#fffaf0e8;backdrop-filter:blur(14px);border:1px solid #e3cfae;border-radius:12px;min-width:245px;box-shadow:0 4px 22px #77525e15}.health-panel img{height:48px;width:45px;object-fit:contain}.health-panel>div{flex:1}.health-title{display:flex;justify-content:space-between;gap:22px;font-size:11px}.health-title b{font-weight:400;color:#ad7780}.health-track{height:8px;border-radius:10px;background:#eadbdc;margin:8px 0 5px;overflow:hidden}.health-track span{height:100%;display:block;width:100%;background:linear-gradient(90deg,#d17592,#eda6b2);transition:width .15s}.health-panel small{font-size:9px;color:#9f8594}.hud-middle{text-align:center;text-shadow:0 1px 8px #fff,0 0 18px #fff;background:#fff7eea3;border:1px solid #fff2df;border-radius:10px;padding:9px 23px}.hud-middle span{display:block;font-size:11px;letter-spacing:.1em}.hud-middle strong{display:block;font-size:25px;letter-spacing:.12em;font-family:Georgia,serif;font-weight:400;margin:4px}.hud-middle small{font-size:9px;color:#947c81}.hud-right{display:flex;align-items:center;gap:15px}.gem-count{background:#fffaf0e8;border:1px solid #e3cfae;border-radius:24px;padding:11px 18px;color:#aa779c;font-size:17px}.gem-count b{font-size:14px;font-weight:400}.game-hint{position:absolute;bottom:25px;left:50%;transform:translateX(-50%);background:#fff8ebdc;color:#8e7481;padding:11px 22px;font-size:11px;border-radius:25px;white-space:nowrap;border:1px solid #ddcbb6}.touch-controls{display:none;position:absolute;bottom:max(20px,env(safe-area-inset-bottom));left:20px;right:20px;justify-content:space-between;pointer-events:none}.touch-controls>div{display:flex;gap:10px;align-items:end}.touch-controls button{pointer-events:auto;touch-action:none;user-select:none;width:54px;height:54px;border-radius:50%;background:#fff6e4dd;border:1px solid #bc9baa;color:#84677e;font-size:23px;box-shadow:0 3px 12px #6f52692b}.touch-controls .touch-jump{width:68px;height:68px;background:#eab8cadd}.touch-controls .touch-attack{background:#c0dde6dd}dialog{border:1px solid #d5bea3;border-radius:18px;background:linear-gradient(145deg,#fffaf2,#f7eced);padding:40px;color:var(--ink);width:min(900px,calc(100% - 32px));max-height:90svh;overflow:auto;box-shadow:0 30px 130px #33213544}dialog::backdrop{background:#39233f55;backdrop-filter:blur(8px)}dialog h2{font:500 30px/1.5 var(--serif);margin:12px 0}.dialog-lead{font-size:13px;line-height:1.9;color:#9b7f8a}.close{position:absolute;right:18px;top:14px;background:transparent;font-size:26px;color:#a48894}.level-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px;margin-top:26px}.level-card{border:1px solid #dfcdbc;background:#fff9f0;border-radius:12px;padding:0;overflow:hidden;text-align:left;color:var(--ink)}.level-art{height:105px;background-image:url('assets/worlds.png');background-size:100% 300%;position:relative}.level-art span{position:absolute;top:10px;left:12px;background:#fff8e9d9;border-radius:12px;padding:4px 8px;font-size:10px}.level-detail{padding:13px 15px}.level-detail strong{font-family:var(--serif);font-weight:500;font-size:18px}.level-detail p{font-size:10px;color:#9c8691}.level-detail .stars{color:#bb9456;letter-spacing:.2em;font-size:18px}.level-card:disabled{filter:grayscale(.7)}.help-grid{display:grid;grid-template-columns:1fr 1fr;gap:15px 30px}.help-grid p{display:grid;grid-template-columns:94px 1fr;gap:7px 14px;align-items:center;font-size:13px}.help-grid kbd{grid-row:span 2;background:#f0e4dd;border:1px solid #d9c7b5;border-radius:8px;padding:13px 7px;text-align:center;font-family:inherit;font-size:12px}.help-grid b{font-weight:500}.help-grid span{font-size:11px;color:#9a8390;line-height:1.7}.help-note{font-size:12px;line-height:1.9;color:#987f8d;border-top:1px solid #e4d4c5;padding-top:18px;margin:20px 0}.dialog-actions{display:flex;gap:14px;justify-content:center;flex-wrap:wrap;margin-top:25px}#pause-dialog,#result-dialog{max-width:560px;text-align:center;padding:45px 32px}.result-stars{font-size:45px;letter-spacing:.15em;color:#c39b59;margin-top:10px;text-shadow:0 3px 15px #d4b67833}.result-stats{display:flex;justify-content:center;gap:35px;margin:22px 0}.result-stats span{font-size:11px;color:#9a8190}.result-stats b{display:block;font:400 27px Georgia,serif;color:#796171;margin-bottom:7px}#toast{position:fixed;bottom:35px;left:50%;transform:translate(-50%,20px);background:#5d4564ec;color:#fff6ef;border:1px solid #bea0ba;border-radius:30px;padding:13px 25px;opacity:0;pointer-events:none;z-index:20;transition:.3s;font-size:12px}#toast.show{opacity:1;transform:translate(-50%,0)}@keyframes float{0%,100%{transform:translateY(0) rotate(-1deg)}50%{transform:translateY(-12px) rotate(1deg)}}@keyframes arrive{from{transform:translateY(-90px) scale(.8);opacity:0}65%{transform:translateY(8px) scale(1.04)}to{transform:translateY(0) scale(1);opacity:1}}@keyframes card-in{from{opacity:0;transform:translateY(35px)}to{opacity:1;transform:translateY(0)}}@keyframes twinkle{50%{opacity:.25;transform:scale(.65)}}@keyframes drift{to{background-position:80px -173px,-40px -277px}}@media(pointer:coarse){.touch-controls{display:flex}.game-hint{bottom:105px;font-size:10px}}@media(max-width:750px){.home-screen{padding:18px 20px}.home-content{min-height:0;height:auto;grid-template-columns:1fr 1fr}.intro{padding:26px 0 12px}.eyebrow{font-size:8px;letter-spacing:.16em}h1{font-size:60px;margin:16px 0}.subtitle{font-size:13px;letter-spacing:.15em}.intro-copy{font-size:11px;line-height:1.9}.start-group{flex-direction:column;align-items:stretch;gap:9px}.primary,.secondary{padding:13px 15px}.small-note{font-size:9px;line-height:1.6}.character-stage{min-height:400px}.featured{width:130%;height:66%;bottom:25%;right:-12%}.character-caption{bottom:5%;width:120%}.character-caption h2{font-size:23px}.character-caption p{font-size:10px;max-width:165px;margin:10px auto}.s1{left:4%}.hero-picker{gap:6px}.hero-card{min-height:98px;padding:3px 2px 10px}.hero-card img{height:67px}.hero-card small{font-size:8px;left:5px;top:5px}.hero-card strong{font-size:11px}.roster-heading{font-size:11px}.roster-heading small{font-size:9px}.home-footer{font-size:7px;gap:15px}.masthead .quiet{font-size:11px;padding:7px}.brand-mark span{font-size:12px}.round{width:36px;height:36px}.masthead>div{gap:8px}.hud{left:10px;right:10px;top:10px}.health-panel{min-width:170px;padding:7px;gap:6px}.health-panel img{height:36px;width:30px}.health-title{font-size:9px;gap:10px}.health-panel small{font-size:8px}.hud-middle{padding:7px 10px}.hud-middle span{font-size:9px}.hud-middle strong{font-size:20px}.hud-middle small{font-size:8px}.hud-right{gap:7px}.gem-count{font-size:12px;padding:8px 10px}.gem-count b{font-size:11px}.game-hint{font-size:9px;padding:9px 12px}.level-grid{grid-template-columns:1fr 1fr;gap:12px}dialog{padding:28px 20px}dialog h2{font-size:23px}.help-grid{grid-template-columns:1fr;gap:0}.level-art{height:85px}}@media(max-height:550px) and (orientation:landscape){.home-screen{padding:15px 35px}.home-content{min-height:300px;height:340px}.intro{padding:5px 0}h1{font-size:54px;margin:10px 0}h1 span{display:inline;margin-left:0}.subtitle{font-size:14px}.intro-copy{font-size:11px}.character-stage{min-height:280px}.featured{height:77%}.roster-wrap{margin-top:0}.hero-card{min-height:85px}.hero-card img{height:60px}.home-footer{margin-top:15px}.hud-middle{padding:6px 16px}.health-panel{padding:5px 10px}.game-hint{bottom:12px}.touch-controls{bottom:12px}.touch-controls button{height:45px;width:45px}.touch-controls .touch-jump{height:55px;width:55px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important}}
