@font-face {
  font-family: 'Starfall Rounded';
  src: url('assets/fonts/round-500.woff') format('woff');
  font-style: normal;
  font-weight: 100 599;
  font-display: swap;
}
@font-face {
  font-family: 'Starfall Rounded';
  src: url('assets/fonts/round-800.woff') format('woff');
  font-style: normal;
  font-weight: 600 950;
  font-display: swap;
}
:root{color-scheme:dark;--gold:#efd595;--line:#ab8a53;--ink:#101224;--paper:#ffefce;--ui:'Starfall Rounded','Hiragino Maru Gothic ProN','Hiragino Sans','Yu Gothic',sans-serif;font-family:var(--ui);font-weight:500;color:#fff6e6;background:var(--ink)}*{box-sizing:border-box}body{margin:0}button{font:inherit;color:inherit;cursor:pointer;-webkit-tap-highlight-color:transparent}button:focus-visible{outline:3px solid #8ee9ff;outline-offset:3px}button:disabled{cursor:default;opacity:.6}button:active:not(:disabled){filter:brightness(1.2)}[hidden]{display:none!important}i[data-i],.icon{display:inline-flex;width:1.25em;height:1.25em;flex-shrink:0;align-items:center;justify-content:center}svg{width:100%;height:100%;display:block}#app{position:relative;width:100%;height:100vh;height:100dvh;overflow:hidden;isolation:isolate;background:#0d1221;user-select:none}#field{position:absolute;width:100%;height:100%;touch-action:none}#home{position:absolute;inset:0;background:linear-gradient(90deg,#080c19ed 0%,#10102b90 32%,transparent 65%),linear-gradient(0deg,#070d20f5 0%,transparent 32%),url(assets/cover.webp) 61% 38%/cover}#home:before{content:'';position:absolute;inset:0;background:linear-gradient(180deg,#0710208a,transparent 17%);pointer-events:none}.frame{position:absolute;inset:16px;border:1px solid #e2bf784a;pointer-events:none}.frame:before,.frame:after{content:'✧';position:absolute;color:var(--gold);font-size:21px;top:-14px}.frame:before{left:-8px}.frame:after{right:-8px}.mast{position:absolute;top:max(35px,env(safe-area-inset-top));left:5%;right:5%;display:flex;justify-content:space-between;align-items:center}.wordmark{display:flex;align-items:center;font:600 17px var(--ui);letter-spacing:3px;color:#f6e3b8;text-shadow:0 2px 10px #10101d}.wordmark span{font-weight:400}.wordmark i{width:36px;height:36px;margin-right:10px}.round{border:1px solid #d9bc8399;border-radius:50%;width:44px;height:44px;background:#101526db;color:var(--gold);display:grid;place-items:center}.round i{width:19px;height:19px}.titleblock{position:absolute;top:48%;left:8%;transform:translateY(-50%);text-align:center;width:min(43%,535px);filter:drop-shadow(0 3px 10px #0d102680)}.eyeline,.kicker{font:600 12px var(--ui);letter-spacing:.27em;color:var(--gold);display:flex;justify-content:center;align-items:center;gap:12px}.eyeline b{height:1px;width:40px;background:linear-gradient(90deg,transparent,var(--gold))}.eyeline b:last-child{transform:scaleX(-1)}h1{font:600 clamp(55px,6.2vw,102px)/1.17 var(--ui);letter-spacing:.035em;color:#fff1cb;text-shadow:0 1px 0 #fdf6e9,0 3px 0 #765536,0 5px 20px #131426;margin:24px -15px 19px}h1 strong{font-size:.9em;font-weight:inherit;letter-spacing:-.07em}.subtitle{font:500 17px var(--ui);letter-spacing:.21em;color:#f5deac;margin:0 0 34px}.gilt{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:22px;padding:14px 34px;min-height:55px;background:linear-gradient(125deg,#ffe6ae,#dcb775 65%,#e6cb92);color:#362335;border:1px solid #fff0ce;box-shadow:inset 0 0 0 3px #bc995c,inset 0 0 0 4px #fce1ae,0 4px 18px #07091270;font:700 17px var(--ui);letter-spacing:.1em}.gilt i:last-child{width:13px}.setup{margin:10px auto 0;background:#10112286;border:0;color:#f0e0c7;display:flex;align-items:center;gap:8px;font-size:13px;padding:9px 14px;border-radius:3px}.setup small{border-bottom:1px solid #ac9879;color:#e7c991}.homefoot{position:absolute;bottom:max(36px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);display:flex;justify-content:center;width:max-content;max-width:94%;background:linear-gradient(90deg,transparent,#111326d9 25%,#111326d9 75%,transparent);padding:8px 14px}.homefoot button{display:flex;gap:9px;align-items:center;border:0;border-right:1px solid #b7a57a71;background:transparent;padding:5px 25px;font:600 15px var(--ui);letter-spacing:.08em}.homefoot button:last-child{border:0}.homefoot i{color:var(--gold);width:22px;height:22px}
#hud{position:absolute;inset:0;pointer-events:none;padding:max(12px,env(safe-area-inset-top)) max(14px,env(safe-area-inset-right)) 0;background:linear-gradient(#0a1224b3,transparent 110px,transparent 85%,#070e1d88)}.upper{display:flex;gap:8px;align-items:center;max-width:900px;margin:auto}.portrait{width:48px;height:48px;border:2px solid #ddc38c;outline:2px solid #272035;border-radius:12px 3px;background:#3f3055;overflow:hidden;box-shadow:0 2px 8px #1119}.portrait img{width:100%;height:100%;object-fit:cover}.vitals{width:clamp(98px,34vw,210px)}.vitals>div:first-child{display:flex;align-items:center;justify-content:space-between;text-shadow:0 2px 3px #111}.vitals b{font:700 17px var(--ui)}.vitals strong{color:#ffe7a8;font:700 14px var(--ui)}.hp,.experience,#bossbar>div{position:relative;height:14px;background:#101b28;border:1px solid #baa77e;border-radius:4px;overflow:hidden;margin-top:3px}.hp span,.experience span,#bossbar span{background:linear-gradient(#9fe7a0,#358e74);height:100%;display:block;transition:width .12s}.hp small{position:absolute;inset:0;text-align:center;font:bold 10px/12px var(--ui);text-shadow:0 1px 3px #121}.clock{margin-left:auto;text-align:center;background:#141529cc;border:1px solid #bdab785e;min-width:74px;padding:4px 9px;border-radius:3px}.clock strong,.clock small{display:block}.clock strong{font:700 22px/1.05 var(--ui);font-variant-numeric:tabular-nums}.clock small{font:600 9px var(--ui);letter-spacing:.13em;color:#f2d69a}.upper button{pointer-events:auto}.experience{max-width:900px;margin:7px auto 0;border-color:#b99bc183;height:5px}.experience span{background:linear-gradient(90deg,#9874e6,#d9b6ff)}.subhud{display:flex;max-width:900px;justify-content:flex-end;gap:6px;margin:7px auto}.subhud span{display:flex;align-items:center;gap:6px;background:#111b2bba;border:1px solid #c7b78555;border-radius:30px;padding:3px 9px;font:700 14px var(--ui)}.subhud i{color:#e8d39a}.subhud span:last-child{color:#ffda79}#bossbar{max-width:260px;margin:8px auto;text-align:center;text-shadow:0 2px 4px black;font-size:13px}#bossbar>div{height:7px}#bossbar span{background:#e2759f}#belt{position:absolute;bottom:max(19px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);display:flex;gap:5px;padding:5px 8px;background:#12182be0;border:1px solid #bda46d8c;border-radius:6px}.slot{position:relative;width:40px;height:40px;border:1px solid #a9956b;border-radius:4px;background:#162029;display:grid;place-items:center;color:#797d8c}.slot img{width:100%;height:100%;object-fit:cover;border-radius:3px}.slot small{position:absolute;bottom:-1px;right:-1px;background:#141629da;min-width:12px;text-align:center;color:#ffde8d;font:bold 11px var(--ui)}.slot.off{border-color:#62647088}.slot.off i{width:15px}#hint,#notice{position:absolute;left:50%;transform:translateX(-50%);width:max-content;max-width:94%;text-align:center;color:#fff2d4;text-shadow:0 2px 3px #151325}#hint{bottom:85px;background:#121929cb;border:1px solid #ad966a85;border-radius:22px;padding:7px 15px;font-size:13px}#notice{top:23%;font:700 20px var(--ui);letter-spacing:.12em}#notice:empty,#hint:empty{display:none}#stick{position:absolute;pointer-events:none;width:100px;height:100px;border:1px solid #f5e9c896;border-radius:50%;background:#b3b3ef22;transform:translate(-50%,-50%);box-shadow:inset 0 0 0 5px #ffffff0c}#stick span{position:absolute;left:29px;top:29px;width:40px;height:40px;border-radius:50%;background:#dfd9f49c;border:2px solid #fff9}
#overlay,#loading{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;padding:max(16px,env(safe-area-inset-top)) 12px max(16px,env(safe-area-inset-bottom));background:#090c1bd9}#overlay.choosing{align-items:flex-end;background:linear-gradient(0deg,#070c1af2,transparent 68%);padding-bottom:max(84px,env(safe-area-inset-bottom))}#loading{z-index:5;flex-direction:column;color:var(--gold);font:16px var(--ui)}#loading i{width:50px;height:50px;animation:spin 5s linear infinite}@keyframes spin{to{transform:rotate(1turn)}}#sheet{width:min(100%,590px);max-height:100%;overflow:auto;background:radial-gradient(ellipse at 50% 0,#383250,#161c32 58%,#101625);border:1px solid #c6a774;box-shadow:inset 0 0 0 4px #151a2b,inset 0 0 0 5px #bea2693b,0 12px 50px #050a16aa;padding:25px 22px 22px;text-align:center;position:relative;scrollbar-width:thin}#sheet h2{margin:6px 0 18px;font:700 28px var(--ui);letter-spacing:.08em;color:#fff0cf}.kicker{font-size:10px}.kicker:before,.kicker:after{content:'✧';font-size:14px}.close{position:absolute;right:12px;top:10px;border:none;background:transparent;font-size:24px;width:40px;height:40px;color:var(--gold)}.choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.choosing #sheet{width:min(100%,620px);background:transparent;border:0;box-shadow:none;padding:0;overflow:visible}.choosing #sheet h2{margin:2px 0 14px;font:700 31px var(--ui);letter-spacing:.09em;text-shadow:0 2px 2px #79400e,0 0 14px #a85b07;color:#ffdfa1}.choosing .kicker{font:600 13px var(--ui);letter-spacing:.15em;text-shadow:0 2px 4px #12131f}.choice{position:relative;border:1px solid #c5aa78;background:linear-gradient(155deg,#393b58,#161c32 68%);border-radius:7px;padding:9px 7px 10px;box-shadow:inset 0 0 0 3px #11192a,inset 0 0 0 4px #bca67447,0 7px 24px #090b14b5;display:flex;align-items:center;flex-direction:column}.choice:first-child{border-color:#ffdb8c;box-shadow:inset 0 0 0 3px #302738,inset 0 0 0 4px #c9af7559,0 0 13px #ffc55c50}.choice img{width:68px;height:68px;border-radius:8px;border:1px solid #d1b87d;box-shadow:0 3px 8px #101125}.choice strong{font:700 17px var(--ui);margin:7px 0 5px}.choice small{font:bold 10px var(--ui);color:#eed297;letter-spacing:.12em}.choice p{margin:6px 0 0;padding-top:7px;border-top:1px solid #beaa812e;font-size:12px;line-height:1.5;color:#e1e2ed}.list{display:grid;gap:8px;text-align:left;margin:12px 0}.row{width:100%;display:flex;align-items:center;text-align:left;gap:12px;padding:10px 13px;min-height:58px;background:#11182b;border:1px solid #aa976649;border-radius:3px}.row.selected{border-color:#e0c288;background:linear-gradient(110deg,#44374c,#1e2338)}.row strong,.row small{display:block}.row strong{font:700 16px var(--ui);color:#ffedc8}.row small{font-size:12px;color:#c4c4d5;line-height:1.5;margin-top:4px}.row img{width:48px;height:48px;border-radius:4px;object-fit:cover}.row>i{width:30px;height:30px;color:var(--gold)}.row em{margin-left:auto;font:600 12px var(--ui);color:#f4d68e;white-space:nowrap}.sheetnote{color:#d0cbd8;font-size:14px;line-height:1.6}.balance{color:#ffdc91;font:bold 16px var(--ui)}.actions,.difficulty{display:flex;justify-content:center;gap:9px;flex-wrap:wrap;margin-top:15px}.secondary,.difficulty button{background:#24263b;border:1px solid #baa071;color:#f5dfb7;min-height:44px;padding:8px 16px;border-radius:3px;font-size:14px}.difficulty .active{background:#55425b;border-color:#f4dc9a}.stats{display:flex;justify-content:center;gap:20px;margin:18px 0}.stats span{font-size:12px;color:#cec6ca}.stats b{display:block;font:700 23px var(--ui);color:#f6e2af}.locknote{font-size:12px;color:#d7c29e}.collected{opacity:.7}.divider{border:0;height:1px;background:linear-gradient(90deg,transparent,#b89a68,transparent);margin:16px 0}
@media(max-width:700px) and (orientation:portrait){#home{background:linear-gradient(0deg,#0a1022 0%,#101127d9 26%,#0a132334 53%,transparent 70%),url(assets/cover.webp) 70% top/auto 72% no-repeat,#101122}.mast{top:max(25px,env(safe-area-inset-top));left:7%;right:7%}.wordmark{font-size:14px}.wordmark i{width:28px;height:28px}.titleblock{left:5%;width:90%;top:auto;bottom:calc(92px + env(safe-area-inset-bottom)/2);transform:none}.eyeline{font-size:10px}h1{font-size:clamp(47px,13.5vw,78px);line-height:1.03;margin:12px 0 11px}h1 br{display:none}h1 strong{display:block;font-size:.94em}.subtitle{font-size:14px;margin:0 0 17px}.gilt{min-height:49px;font-size:16px;padding:11px 25px}.homefoot{bottom:max(24px,env(safe-area-inset-bottom));max-width:96%;padding:7px 1px}.homefoot button{font-size:13px;padding:5px 12px;gap:5px}.homefoot i{width:19px}.frame{inset:10px}.setup{margin-top:4px}.choice img{width:clamp(43px,12vw,65px);height:auto}.choice strong{font-size:clamp(13px,3.7vw,17px)}.choice p{font-size:12px}.choices{gap:5px}.choice{padding:8px 5px}.portrait{width:42px;height:42px}.upper{gap:6px}.vitals b{font-size:15px}.upper .round{width:44px;height:44px}#sheet{padding:22px 13px 14px}.choosing #sheet{padding:0}.row{gap:8px;padding:8px 9px}.titleblock .setup{font-size:12px}}@media(max-height:590px){.mast{top:18px}.titleblock{top:45%}h1{font-size:48px;margin:12px 0}.subtitle{margin-bottom:14px}.homefoot{bottom:16px}.choice p{font-size:12px}#overlay.choosing{padding-bottom:14px}.choosing #sheet h2{margin-bottom:6px}.choices img{width:44px;height:44px}}@media(max-height:590px) and (orientation:portrait){.titleblock{top:auto;bottom:67px}.titleblock h1{font-size:44px}.titleblock .subtitle{font-size:12px;margin-bottom:10px}}@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}
@media(max-height:590px) and (orientation:portrait){.choice p{display:block}.choosing #sheet{max-height:72vh;overflow:auto}}

/* Compact letterforms keep names, counters and upgrade text legible in a single glance. */
.mast {justify-content:flex-end}
.eyeline {gap:9px;color:#f9d998}
.eyeline b {width:clamp(35px,6vw,72px)}
.eyeline i {width:15px;height:15px}
.titleblock h1 {font-weight:800;letter-spacing:.01em;line-height:1.16;
  color:#fff1cc;text-shadow:0 2px #997140,0 4px #51394c,0 5px 14px #100e26}
.titleblock h1 span {display:inline-block;color:#f6dc9b;font-size:.81em;vertical-align:baseline}
.titleblock h1 strong {display:inline-block;letter-spacing:-.055em;color:#fff8ea}
.subtitle {font-weight:800;letter-spacing:.1em}
.gilt, .homefoot button, #sheet h2 {letter-spacing:.025em}
.kicker, .choosing .kicker {letter-spacing:.03em}
.choosing #sheet h2 {font-size:clamp(23px,6vw,31px);letter-spacing:.025em}
.choice strong {line-height:1.3;letter-spacing:0;overflow-wrap:anywhere}
.choice small {font-size:11px;letter-spacing:.02em}
.choice p {font-size:13px;line-height:1.48}
.row small {font-size:13px;line-height:1.48;color:#d9d6e5}
.setup small {font-size:12px}
.vitals>div:first-child {gap:4px}
.clock strong {font-variant-numeric:tabular-nums;letter-spacing:.015em}
.clock small {font-size:11px;line-height:1.25;letter-spacing:.025em}
.subhud span {font-variant-numeric:tabular-nums}
#hint {font-weight:800;letter-spacing:0}
@media(max-width:700px) and (orientation:portrait){
  .titleblock h1 {font-size:clamp(43px,12.9vw,76px);line-height:1.10}
  .titleblock h1 strong {display:block;font-size:1em}
  .choice strong {font-size:clamp(14px,3.65vw,18px)}
  .homefoot button {min-height:42px;padding-inline:10px}
}
@media(max-height:590px) and (orientation:portrait){
  .titleblock h1 {font-size:40px}
}

#belt{pointer-events:auto;align-items:center;touch-action:manipulation;color:#eadaba}
.belt-label{display:grid;justify-items:center;gap:3px;margin-left:2px;font-size:11px;font-weight:800}
.belt-label i{width:17px;height:17px}
.section-label{text-align:left;border-bottom:1px solid #a990635c;padding-bottom:6px;font-size:14px;color:#e7c690;margin:16px 0 5px}
.choice-skills{margin:8px auto 0;padding:7px 14px;min-height:38px;border-radius:20px;border:1px solid #a8916a;background:#131b2fec;color:#ffecd0;font-size:13px}
.ledger{display:flex;justify-content:space-between;align-items:center;color:#e3deef;background:#14192b;padding:9px 12px;border-radius:4px;font-size:14px}
.ledger span{display:flex;align-items:center;gap:5px;color:#ffdb86}
.weapon-tabs{display:flex;justify-content:center;gap:8px;margin:17px 0 10px}
.weapon-tabs button{background:#1b2034;border:1px solid #78748e;border-radius:7px;padding:3px;width:clamp(42px,12vw,59px);min-height:44px}
.weapon-tabs button[aria-pressed=true]{border:2px solid #ffdf91;box-shadow:0 0 10px #efbf5736}
.weapon-tabs img{display:block;width:100%;border-radius:4px}
.branches{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;text-align:left}
.branch{border:1px solid #827b90;background:#192237;padding:12px;border-radius:6px;display:flex;flex-direction:column}
.branch.equipped{border-color:#e3bc75;background:#332f41}
.branch strong{font-size:17px;color:#ffedcb}
.branch em{display:inline-block;margin-left:4px;font:inherit;font-size:12px;color:#ffda91}
.branch p{font-size:14px;line-height:1.6;flex:1;color:#e1deec;margin:9px 0}
.branch button{width:100%;padding:7px 4px;font-weight:800}
@media(max-width:359px){.branches{grid-template-columns:1fr}.slot{width:34px;height:34px}}

.build-count{color:#ffedc8;font-size:14px;font-weight:800;margin:0 0 8px;text-shadow:0 1px 4px #101224,0 1px 8px #101224}.choosing #sheet:has(.build-count) h2{margin-bottom:3px}

#speed{pointer-events:auto;touch-action:manipulation;margin-right:auto;min-width:50px;min-height:44px;padding:5px 10px;background:#131a30df;color:#f8e8ca;border:1px solid #a58b64;border-radius:8px;font-size:15px;font-weight:800}
#speed[aria-pressed=true]{color:#30251c;background:#e6c68d}
.subhud{align-items:flex-start}
.draft-actions{display:flex;justify-content:center;gap:6px;flex-wrap:wrap}
.draft-actions .choice-skills{margin:7px 0 0;min-height:44px}
