@font-face{font-family:Jua;src:url('assets/fonts/Jua-Regular.woff') format('woff');font-weight:400;font-display:swap}
:root{--ink:#504164;--gold:#ffe6af;--lavender:#cfb7ea;--edge:#b8a5ce}html,body,button{font-family:Jua,'Gowun Dodum',sans-serif}button{font-size:16px}#world{image-rendering:auto}.screen{color:#eee4ff}.screen p{font-size:18px;line-height:1.65}
#title{transition:opacity 2.2s ease,transform 2.2s ease;background-color:#080e21}#title.departing{opacity:0;transform:scale(1.035);pointer-events:none}.titleLogo{top:5%;left:50%;width:min(630px,65vw);transform:translateX(-50%)}.titleLogo img{width:100%;max-height:250px;object-fit:contain;filter:drop-shadow(0 5px 12px #182342aa)}#title nav{top:45%;gap:10px}#title nav button{background:url('assets/ui-button.webp') center/100% 100% no-repeat;border:0;border-radius:0;box-shadow:none;color:#f0e9ff;font-size:22px;height:58px;padding:0 40px;text-shadow:0 2px 4px #4b4160}#title nav button:disabled{opacity:.5}.titleFoot{font-size:15px;line-height:1.7}
.playerHud{left:22px;top:20px;width:370px;height:142px;display:flex;align-items:center;gap:9px;padding:0;background:none;border:0;box-shadow:none;overflow:visible}.playerHud:after{display:none}.portrait{position:relative;flex:0 0 134px;height:134px}.playerHud .portrait>img{position:absolute;width:115px;height:120px;left:10px;top:5px;object-fit:contain;object-position:center;clip-path:ellipse(47% 48% at 50% 52%);border:0;border-radius:0;background:none}.portrait i{position:absolute;inset:-8px;background:url('assets/upgrade/portrait-frame.webp') center/contain no-repeat;pointer-events:none}.statusBody{width:220px;padding:7px 4px 8px;border:0;background:#1721429c;border-radius:15px;box-shadow:0 0 18px #12213e50}.playerName{font-size:24px;color:#fff4ee;text-shadow:0 2px 3px #292240}.playerName b{font-size:16px;margin-left:12px;color:#eee0ff;font-weight:400}.playerHud .bar{width:215px;height:24px;margin:7px 0;background:#454057dd;border:2px solid #ddd1ed;border-radius:15px;overflow:hidden;box-shadow:0 0 0 2px #84719288}.bar.health i{background:linear-gradient(#f3b2cb,#e581ab)}.bar.exp{height:15px;margin-top:8px}.bar.exp i{background:linear-gradient(#bfe6ff,#7cbeeb)}.bar em{font:15px Jua;color:#fff8fa;line-height:20px;text-shadow:0 1px 3px #69435a}.bar.exp em{font-size:11px;line-height:11px}.playerHud small{font-size:14px;color:#e6d6f4;white-space:nowrap;display:block;margin-top:8px}.location{top:28px;color:#f5ebfc}.location strong{font:25px Jua}.location small{font-size:13px}.location span{font-size:15px;color:#e9dbf6}.topRight .coin{font-size:20px}.topRight button{background:url('assets/ui-button.webp') center/100% 100%;border:0;box-shadow:none;padding:10px 20px}
#minimap{top:92px;right:28px;bottom:auto;width:170px;height:130px;border:7px solid #c9b4dc;border-radius:38%;box-shadow:0 0 0 3px #6c658c,0 5px 24px #07112f99}.bottomHud{bottom:20px;color:#f4e9ff}.skills{position:relative;gap:8px;background:url('assets/upgrade/skillbar.webp') center/100% 100% no-repeat;padding:18px 24px 16px;isolation:isolate}.skills button{position:relative;min-width:85px;width:85px;height:100px;border:0;box-shadow:none;background:none;padding:0;color:#fff2fc;border-radius:50% 50% 15px 15px}.skills button img{display:block;width:64px;height:64px;object-fit:contain;margin:0 auto;filter:drop-shadow(0 2px 4px #49335c)}.skills button kbd{position:absolute;top:46px;left:50%;transform:translateX(-50%);font:14px Jua;background:#655375d9;border-color:#e6cfee;border-radius:8px;padding:1px 7px}.skills button span{display:block;font-size:13px;margin-top:7px;white-space:nowrap}.skills button em{position:static;display:block;font:12px Jua;color:#ddcee9;line-height:16px}.bottomHud>small{font-size:13px;text-shadow:0 1px 3px #16233e}#elementSelect{gap:6px;margin-bottom:0}#elementSelect button{font-size:14px;border-radius:15px;background:#172245bd;padding:4px 13px;border:1px solid #c6b3e080;box-shadow:none}#elementSelect button.active{background:#57456ac9;border-color:#f7daaa}
.cornerButton{position:fixed;bottom:16px;z-index:6;width:112px;height:136px;background:none;border:0;box-shadow:none;padding:0;color:#f8ecff}.cornerButton.journal{left:24px}.cornerButton.pouch{right:24px}.cornerButton img{width:100%;height:98px;object-fit:contain}.cornerButton kbd{display:block;width:max-content;margin:-7px auto 4px;font:14px Jua;background:#fff1e8;color:#775b87;border-color:#ccb1da}.cornerButton span{font-size:16px;text-shadow:0 1px 3px #182445}
.veil{background:#07122ab5;backdrop-filter:none}.book{width:min(1040px,94vw);max-height:90vh;border:36px solid transparent;border-image:url('assets/upgrade/menu-panel.webp') 150 fill /36px stretch;background:none;color:#554267;box-shadow:0 15px 50px #030817aa;padding:8px 16px;border-radius:0}.book h2{font:30px Jua;color:#755a96}.book header small{font-size:13px;color:#9a79a6}.book small{color:#7d6893}.book button{background:#eee0f6;border:1px solid #be9dce;box-shadow:inset 0 0 10px #fff9;padding:9px 14px;color:#745a8f;border-radius:13px}.book button.active{background:#d9c1eb;border-color:#9173ad;color:#4c365f}.book #closeMenu{border:0;background:none;font-size:17px}.book .tabs{gap:8px;flex-wrap:wrap}.book .tabs button{font-size:17px}.book footer{font-size:13px;color:#857094;border-top:1px solid #bea3cc55;padding:12px 0 0}.book #menuContent{padding:6px 8px}.buildTabs button{position:relative;padding:10px 8px;background:#eeebf8!important;color:#745c91!important;font-size:17px}.buildTabs button.active{background:#dfcbee!important}.buildTabs img{display:block;width:50px;height:50px;object-fit:contain;margin:auto}.buildTabs small{font-size:13px;margin-top:4px}.summaryLine{font-size:16px;color:#75588f;flex-wrap:wrap;gap:8px;margin:14px 0}.skillGrid{gap:12px}.skillCard{position:relative;border:2px solid #c7afd8;background:linear-gradient(140deg,#fff8f0,#ede3f4);border-radius:18px;padding:14px;min-height:210px;overflow:hidden}.skillCard .skillArt{width:54px;height:54px;object-fit:contain;float:right;margin:0 0 8px 8px}.skillCard h3{font:19px Jua;color:#73528c;margin:8px 0}.skillCard p{font-size:15px;color:#80648e;line-height:1.45;min-height:44px}.skillCard small{font-size:13px;color:#9170a0}.skillCard .rank{font-size:14px;color:#ad79bd;display:block;margin:8px 0}.skillCard button{font-size:15px;padding:7px 10px}.relicCard{background:#f5eaf7!important;color:#75558a!important;border-radius:14px}.relicCard strong{font-size:16px;text-shadow:0 1px #725383}.relicCard small{font-size:14px;line-height:1.5;color:#776186}.slot{background:#eee3f4!important;border-radius:12px}.slot em{font-size:12px}.settings .settingRow{border-color:#c2a7ce66;color:#705287}.settings label{font-size:19px}.settings p,.controls,.emptyNote,.wishPage p{font-size:16px;line-height:1.65;color:#8d7399}.settings input[type=range]{accent-color:#a986c0}.controls{color:#826992}.book .danger{background:#f0d4dc;color:#a56178}.wishPage h3{font:25px Jua;color:#795598}.wishPage .rates{font-size:16px}.emptyNote{padding:38px 10px}.emptyNote button{margin-top:20px}#toast,#interactHint,#cinemaHint{font:17px Jua;color:#fff0fb;background:#403856d9;border:1px solid #dfc2e7;border-radius:18px;padding:10px 18px;box-shadow:none}#bossHud{top:23px;width:min(480px,42vw);color:#f2dcff;font-size:22px;text-shadow:0 2px 5px #17152f}#bossHud .bar{border-color:#c7a7d7;border-radius:15px;height:18px}#bossHud .bar i{background:linear-gradient(#d8aae7,#ae78c9)}#musicStart{position:fixed;bottom:20px;left:20px;z-index:40;border:0;background:#182344a8;border-radius:16px;font-size:15px;box-shadow:none;color:#e8daf5;padding:8px 14px}
@media(max-width:1100px){.playerHud{transform:scale(.85);transform-origin:top left}.location{top:22px;left:51%;max-width:240px}.location strong{font-size:21px}.location span{font-size:13px}.cornerButton{width:95px;height:115px}.cornerButton img{height:80px}.skills{padding:14px 15px}.skills button{width:75px;min-width:75px}.book{border-width:26px;border-image-width:26px;padding:8px}.skillCard{padding:10px}}@media(max-width:800px){.playerHud{left:8px;top:8px;transform:scale(.65)}.location{top:115px;left:12px;transform:none;text-align:left}.location strong{font-size:18px}.location span{font-size:12px;max-width:240px}#minimap{width:105px;height:80px;right:12px;top:65px;border-width:4px}.topRight{top:12px}.topRight .coin{font-size:15px}.bottomHud{bottom:8px}.skills{padding:10px 8px;gap:2px}.skills button{width:58px;min-width:58px;height:85px}.skills button img{width:48px;height:48px}.skills button kbd{top:34px;font-size:12px}.skills button span{font-size:10px}.skills button em{font-size:10px}.bottomHud>small{display:none}.cornerButton{bottom:8px;width:64px;height:95px}.cornerButton img{height:60px}.cornerButton.journal{left:6px}.cornerButton.pouch{right:6px}.cornerButton span{font-size:11px}.cornerButton kbd{font-size:11px}.book{border-width:18px;border-image-width:18px;padding:4px;max-height:94vh}.book h2{font-size:24px}.book .tabs button{font-size:14px;padding:7px}.buildTabs button{font-size:13px}.buildTabs img{width:38px;height:38px}.buildTabs small{font-size:11px}.skillGrid{grid-template-columns:repeat(2,1fr)}.skillCard h3{font-size:16px}.skillCard p{font-size:14px}.skillCard .skillArt{width:40px;height:40px}.titleLogo{top:10%;width:85vw}#title nav{top:43%}#title nav button{font-size:20px;height:48px}.titleFoot{font-size:12px}.relicGrid{grid-template-columns:repeat(2,1fr)}#bossHud{top:75px;width:50vw;left:55%;font-size:17px}#musicStart{bottom:5px;font-size:12px}}
.playerHud .portrait{flex:0 0 134px}.playerHud .statusBody{flex:0 1 220px;min-width:0}.playerHud .playerName{font:24px Jua}.playerHud .playerName b{font:16px Jua;float:none;margin-left:12px}.playerHud .bar.health{height:24px;border:2px solid #ddd1ed;border-image:none;background:#454057dd}.playerHud .bar.health em{font:15px Jua;line-height:20px}.book #menuContent>p{font-size:14px!important;color:#8a719a!important;line-height:1.55}#hud .cornerButton{pointer-events:auto}

/* Repair: use alpha title art and align every slot to its painted inner ring. */
#title nav button{background-image:url('assets/repair/title-button.webp');background-color:transparent;background-size:100% 100%;border:0!important;border-image:none!important;outline:none;box-shadow:none!important;color:#655078;text-shadow:0 1px 1px #fff4;border-radius:0;filter:none}
#title nav button:before,#title nav button:after{display:none!important}#title nav button:hover{color:#9470a5;filter:none;transform:translateY(-1px)}#title nav button:focus-visible{outline:2px solid #eed0ff;outline-offset:3px;border-radius:50%}
.skills{--bar-width:min(600px,calc(100vw - 148px));--icon-size:82px;position:relative;display:block;width:var(--bar-width);height:205px;gap:0;padding:0;margin:5px 0;background-size:100% auto;background-position:center top;background-repeat:no-repeat}
.skills button{position:absolute;left:calc(var(--slot-x) - 54px);top:14px;width:108px;min-width:0;height:190px;padding:0;display:block;border:0!important;border-image:none!important;border-radius:0;background:none;box-shadow:none!important;color:#fff4ff;filter:none;overflow:visible}
.skills button:nth-child(1){--slot-x:20.9%}.skills button:nth-child(2){--slot-x:35.3%}.skills button:nth-child(3){--slot-x:49.9%}.skills button:nth-child(4){--slot-x:64.6%}.skills button:nth-child(5){--slot-x:79.5%}
.skills button img{width:var(--icon-size);height:var(--icon-size);object-fit:cover;display:block;margin:0 auto;border-radius:50%;clip-path:circle(49%);filter:none;background:#253248}
.skills button kbd{position:absolute;left:50%;top:81px;transform:translateX(-50%);margin:0;font:14px Jua;padding:1px 7px;border:1px solid #ead7f1;background:#655375;color:#fff5fb;border-radius:8px}
.skills button span{position:absolute;left:-5px;top:148px;width:118px;margin:0;font-size:14px;line-height:18px;white-space:nowrap;text-align:center;text-shadow:0 1px 2px #071126}
.skills button em{position:absolute;left:0;top:171px;width:100%;margin:0;font:13px Jua;color:#e3d8f0;text-align:center;text-shadow:0 1px 2px #071126}
.bottomHud{bottom:12px}.bottomHud>small{font-size:12px;margin-top:0}#elementSelect{margin-bottom:6px}
.skillCard .skillArt{width:62px;height:62px;object-fit:cover;float:right;border-radius:13px;border:2px solid #d1b9e0;margin:0 0 9px 10px;filter:none}.buildTabs img{border-radius:12px;filter:none}
.playerHud .portrait>img,.cornerButton img,.titleLogo img{filter:none}.skills button:hover img{outline:2px solid #ffeac3;outline-offset:1px}.skills button:hover{box-shadow:none!important}
@media(max-width:800px){.skills{--bar-width:min(540px,calc(100vw - 122px));--icon-size:calc(var(--bar-width)*.137);height:185px}.skills button{left:calc(var(--slot-x) - 46px);top:calc(var(--bar-width)*.023);width:92px;height:175px}.skills button kbd{top:calc(var(--icon-size) - 2px);font-size:12px}.skills button span{left:-7px;top:calc(var(--bar-width)*.27);width:106px;font-size:12px;line-height:16px}.skills button em{top:calc(var(--bar-width)*.27 + 23px);font-size:12px}.bottomHud{bottom:8px}.cornerButton{bottom:10px}.bottomHud>small{display:none}}

#worldVignette{position:fixed;inset:0;z-index:1;pointer-events:none;background:radial-gradient(ellipse at 50% 45%,transparent 25%,#020b2180 100%);transform:translateZ(0)}

#hud{z-index:5}#title nav button{font:22px Jua,sans-serif}

/* Match icons to the painted ring interiors at every viewport size. */
.skills{--icon-size:calc(var(--bar-width)*.125);background:none}
.skills::before{content:'';position:absolute;inset:0;z-index:2;pointer-events:none;background:url('assets/upgrade/skillbar.webp') center top/100% auto no-repeat}
.skills button{top:calc(var(--bar-width)*.030);z-index:auto}
.skills button img{position:relative;z-index:1;clip-path:circle(50%);border-radius:50%}
.skills button kbd,.skills button span,.skills button em{z-index:3}
.skills button kbd{top:calc(var(--bar-width)*.132);font-size:14px}
@media(max-width:800px){.skills button{top:calc(var(--bar-width)*.030)}.skills button kbd{top:calc(var(--bar-width)*.132);font-size:12px}}

/* Anchor every circle to the artwork, independent of button content layout. */
.skills{--ring-width:calc(var(--bar-width)*.128);--ring-height:calc(var(--bar-width)*.132)}
.skills button{left:var(--slot-x);top:calc(var(--bar-width)*.0946);width:var(--ring-width);height:var(--ring-height);min-width:0;min-height:0;margin:0;padding:0;transform:translate(-50%,-50%)!important;overflow:visible;line-height:normal}
.skills button img{position:absolute;inset:0;width:100%;height:100%;margin:0;object-fit:cover;border-radius:50%;clip-path:ellipse(50% 50%);transform:none}
.skills button:nth-child(1){--slot-x:20.96%}.skills button:nth-child(2){--slot-x:35.31%}.skills button:nth-child(3){--slot-x:49.94%}.skills button:nth-child(4){--slot-x:64.69%}.skills button:nth-child(5){--slot-x:79.65%}
.skills button kbd{left:50%;top:calc(var(--bar-width)*.141);transform:translateX(-50%);white-space:nowrap}
.skills button span{left:50%;top:calc(var(--bar-width)*.230);width:118px;transform:translateX(-50%);margin:0;text-align:center}
.skills button em{left:50%;top:calc(var(--bar-width)*.230 + 23px);width:118px;transform:translateX(-50%);margin:0;text-align:center}
@media(max-width:800px){.skills button{left:var(--slot-x);top:calc(var(--bar-width)*.0946);width:var(--ring-width);height:var(--ring-height)}.skills button kbd{top:calc(var(--bar-width)*.141)}.skills button span{left:50%;top:calc(var(--bar-width)*.230);width:100px}.skills button em{left:50%;top:calc(var(--bar-width)*.230 + 23px);width:100px}}
