:root{--ink:#2f2925;--muted:#8c8279;--accent:#d9733b;--sheet:#f7f3ec;--card:#fff;--placeholder:#e6ddd1;--sky-top:#bcd9e8;--sky-bottom:#f4e3c9;--shadow:0 2px 6px #5a3c201a;color:var(--ink);-webkit-text-size-adjust:100%;font-family:-apple-system,BlinkMacSystemFont,SF Pro Text,Inter,system-ui,sans-serif}*{box-sizing:border-box}html,body,#root{overscroll-behavior:none;background:var(--sheet);height:100%;margin:0;overflow:hidden}button{font:inherit;color:inherit;cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;background:0 0;border:0;padding:0}button:active:not(:disabled){transform:scale(.97)}button:disabled{cursor:default}.muted{color:var(--muted)}.app{flex-direction:column;max-width:520px;height:100dvh;margin:0 auto;display:flex}.scene-area{background:linear-gradient(var(--sky-top), var(--sky-bottom));flex:none;height:56dvh;min-height:330px;position:relative}.scene{position:absolute;inset:0}.scene canvas{display:block}.hud{padding:calc(env(safe-area-inset-top) + 8px) 16px 0;pointer-events:none;position:absolute;inset:0 0 auto}.hud button{pointer-events:auto}.hud-top{justify-content:space-between;align-items:center;display:flex}.player{align-items:center;gap:10px;display:flex}.crest{background:var(--card);width:38px;height:38px;box-shadow:var(--shadow);border-radius:50%}.player-name{color:#5c534c;font-size:12px;font-weight:600}.power strong{font-size:21px;font-weight:800}.power span{color:var(--muted);font-size:11px;font-weight:600}.currencies{gap:8px;display:flex}.pill{background:#ffffffbf;border-radius:14px;align-items:center;gap:6px;height:28px;padding:0 10px;font-size:13px;font-weight:700;display:inline-flex}.plus{background:var(--accent);color:#fff;border-radius:50%;width:22px;height:22px;margin-right:-6px;font-weight:800;line-height:22px}.resources{background:#fff9;border-radius:13px;grid-template-columns:repeat(4,1fr);align-items:center;height:26px;margin-top:8px;padding:0 12px;font-size:12.5px;font-weight:700;display:grid}.resource{align-items:center;gap:6px;display:inline-flex}.dot{background:var(--placeholder);border-radius:4px;width:14px;height:14px;display:inline-block}.dot-gold{background:#e2b84a;border-radius:50%}.dot-gem{background:#e06a9a;transform:rotate(45deg)scale(.8)}.stage{left:50%;top:calc(env(safe-area-inset-top) + 92px);flex-direction:column;align-items:center;gap:6px;display:flex;position:absolute;transform:translate(-50%)}.stage-pill{background:#ffffffb8;border-radius:13px;height:26px;padding:0 14px;font-size:12px;font-weight:700;line-height:26px}.waves{gap:4px;display:flex}.wave{background:#fffc;border-radius:2px;width:17px;height:3.5px}.wave.done{background:#2f29258c}.skillbar{justify-content:center;align-items:center;gap:8px;display:flex;position:absolute;bottom:34px;left:0;right:0}.skill{background:var(--card);width:44px;height:44px;box-shadow:var(--shadow);border-radius:50%}.auto-pill{background:var(--card);height:28px;box-shadow:var(--shadow);border-radius:14px;align-items:center;gap:6px;padding:0 12px;font-size:12px;font-weight:700;display:inline-flex;position:absolute;right:16px}.auto-dot{background:#6dbb72;border-radius:50%;width:8px;height:8px}.sheet{z-index:1;background:var(--sheet);border-radius:24px 24px 0 0;flex-direction:column;flex:auto;gap:14px;margin-top:-24px;padding:18px 16px 12px;display:flex;position:relative;overflow-y:auto;box-shadow:0 -3px 12px #3b2a1a1a}.section-head{justify-content:space-between;align-items:baseline;margin-bottom:10px;display:flex}.section-head h2{margin:0;font-size:15px;font-weight:800}.section-head .muted{font-size:11px;font-weight:600}.grid{grid-template-columns:repeat(4,1fr);gap:10px;display:grid}.card{aspect-ratio:82/80;background:var(--card);box-shadow:var(--shadow);border-radius:16px;flex-direction:column;justify-content:center;align-items:center;gap:4px;display:flex}.card-icon{background:var(--rarity-soft,var(--placeholder));border-radius:50%;width:36px;height:36px}.card-label{color:var(--muted);font-size:9.5px;font-weight:600}.card-foot{align-items:center;gap:6px;display:flex}.card-level{color:#6f665e;text-align:right;min-width:14px;font-size:12px;font-weight:700}.card-bar{background:var(--rarity,var(--placeholder));border-radius:2px;width:30px;height:4px}.card.fresh{animation:.45s ease-out card-fresh}@keyframes card-fresh{0%{box-shadow:0 0 0 3px var(--rarity), var(--shadow);transform:scale(1.04)}to{box-shadow:0 0 0 0 transparent, var(--shadow);transform:scale(1)}}.gatebar{grid-template-columns:1fr auto 1fr;align-items:center;gap:12px;margin-top:auto;display:grid}.gate-info{text-align:left;flex-direction:column;justify-content:center;align-items:flex-start;gap:4px;min-height:44px;font-size:14px;display:flex}.gate-odds{font-size:11px;font-weight:600}.recruit{background:var(--accent);color:#fff;border-radius:26px;flex-direction:column;justify-content:center;align-items:center;min-width:178px;height:52px;display:flex;box-shadow:0 4px 10px #8a3c1040}.recruit-title{font-size:16px;font-weight:800}.recruit-sub{opacity:.85;font-size:11px;font-weight:600}.recruit:disabled{box-shadow:none;background:#d8cfc4}.auto-round{background:var(--card);width:52px;height:52px;box-shadow:var(--shadow);color:var(--muted);border-radius:50%;justify-self:end;font-size:11px;font-weight:700}.auto-round.running{color:var(--accent);box-shadow:0 0 0 2px var(--accent), var(--shadow)}.coming-soon{text-align:center;padding-top:40px}.coming-soon h2{margin:0 0 6px;font-size:17px}.nav{background:var(--card);padding:6px 4px calc(env(safe-area-inset-bottom) + 6px);border-top:1px solid #ece5da;flex:none;grid-template-columns:repeat(5,1fr);display:grid}.tab{color:#9b9188;flex-direction:column;justify-content:center;align-items:center;gap:4px;min-height:48px;font-size:10px;font-weight:600;display:flex}.tab-icon{background:var(--placeholder);border-radius:6px;width:22px;height:22px}.tab.active{color:var(--ink);font-weight:700}.tab.active .tab-icon{background:var(--accent);border-radius:50%;box-shadow:0 0 0 7px #fbe7da}.tab-label{white-space:nowrap}.rarity-plain{--rarity:#a69d93;--rarity-soft:#eeeae4}.rarity-solid{--rarity:#6fa86a;--rarity-soft:#e2efe0}.rarity-fine{--rarity:#5b8fc6;--rarity-soft:#e0eaf5}.rarity-noble{--rarity:#9472bd;--rarity-soft:#ece4f4}.rarity-splendid{--rarity:#db8c3f;--rarity-soft:#f7e8d8}.rarity-heroic{--rarity:#c95b51;--rarity-soft:#f5e0dd}.rarity-legendary{--rarity:#cfa83a;--rarity-soft:#f6edd0}.rarity-mythic{--rarity:#3cada6;--rarity-soft:#d8f0ee}.rarity-dot{background:var(--rarity);border-radius:50%;flex:none;width:10px;height:10px}.sheet-backdrop{z-index:10;background:#2f292552;justify-content:center;align-items:flex-end;animation:.15s ease-out fade-in;display:flex;position:fixed;inset:0}.bottom-sheet{background:var(--sheet);width:100%;max-width:520px;max-height:88dvh;padding:16px 16px calc(env(safe-area-inset-bottom) + 16px);border-radius:24px 24px 0 0;animation:.2s ease-out slide-up;overflow-y:auto}.bottom-sheet-head{justify-content:space-between;align-items:center;min-height:44px;margin-bottom:8px;display:flex}.bottom-sheet-head h2{margin:0;font-size:17px;font-weight:800}.close{width:44px;height:44px;color:var(--muted);margin-right:-10px;font-size:24px}.sheet-text{margin:8px 0;font-size:13px;line-height:1.45}.sheet-subhead{margin:16px 0 8px;font-size:13px;font-weight:700}.sheet-actions{grid-template-columns:1fr 1fr;gap:12px;margin-top:16px;display:grid}.sheet-actions.single{grid-template-columns:1fr}@keyframes fade-in{0%{opacity:0}}@keyframes slide-up{0%{opacity:.6;transform:translateY(24px)}}.btn{background:var(--card);min-height:52px;box-shadow:var(--shadow);border-radius:26px;flex-direction:column;justify-content:center;align-items:center;font-size:15px;font-weight:800;display:flex}.btn small{opacity:.8;font-size:11px;font-weight:600}.btn.primary{background:var(--accent);color:#fff;box-shadow:0 4px 10px #8a3c1040}.btn.primary:disabled{box-shadow:none;background:#d8cfc4}.btn.danger{color:#b5483e}.recruit-info{background:var(--card);box-shadow:var(--shadow);border-radius:16px;min-width:0;padding:12px}.ri-label{color:var(--muted);margin-bottom:8px;font-size:11px;font-weight:700}.ri-head{align-items:center;gap:10px;display:flex}.ri-icon{background:var(--rarity-soft);width:40px;height:40px;box-shadow:inset 0 0 0 2px var(--rarity);border-radius:50%;flex:none}.ri-name{font-size:14px;font-weight:800}.ri-sub{color:var(--muted);font-size:12px;font-weight:600}.ri-rarity{color:var(--rarity);font-weight:700}.ri-stat{justify-content:space-between;margin-top:12px;font-size:13px;display:flex}.ri-empty{margin:8px 0 0;font-size:12px}.ri-talents{flex-direction:column;gap:6px;margin:8px 0 0;padding:0;font-size:12px;list-style:none;display:flex}.ri-talents li{grid-template-columns:1fr auto;column-gap:8px;display:grid}.ri-quality{grid-column:1/-1;font-size:10.5px}.power-compare{justify-content:center;align-items:baseline;gap:8px;margin-bottom:12px;font-size:15px;display:flex}.power-compare strong{font-size:19px}.power-compare .arrow{font-size:14px}.power-compare.up .arrow,.power-compare.up strong:last-of-type{color:#4f9a55}.power-compare.down .arrow,.power-compare.down strong:last-of-type{color:#c2534a}.compare-cols{grid-template-columns:1fr 1fr;gap:10px;display:grid}.choice-grid{grid-template-columns:repeat(3,1fr);gap:8px;display:grid}.choice{background:var(--card);min-height:44px;box-shadow:var(--shadow);border-radius:14px;justify-content:center;align-items:center;gap:6px;font-size:13px;font-weight:700;display:inline-flex}.choice.selected{box-shadow:0 0 0 2px var(--accent), var(--shadow)}.stepper{grid-template-columns:44px 1fr 44px;align-items:center;gap:8px;display:grid}.stepper>button{background:var(--card);height:44px;box-shadow:var(--shadow);border-radius:22px;font-size:22px;font-weight:700}.stepper>button:disabled{opacity:.35}.stepper-value{flex-direction:column;align-items:center;font-size:16px;display:flex}.stepper-value .muted{font-size:11px;font-weight:600}.odds-list{background:var(--card);box-shadow:var(--shadow);border-radius:16px;margin:12px 0 0;padding:0;list-style:none}.odds-list li{align-items:center;gap:10px;min-height:40px;padding:0 14px;font-size:14px;display:flex}.odds-list li+li{border-top:1px solid #f0eae1}.odds-list li strong{margin-left:auto}.dev-pill{z-index:2;color:#fff;letter-spacing:.5px;background:#2f2925b3;border-radius:14px;height:28px;padding:0 10px;font-size:11px;font-weight:800;position:absolute;bottom:42px;left:12px}
