:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#193d40;background:#eeeade;font-synthesis:none;font-weight:500;--ink:#193d40;--teal:#148e80;--cream:#fffdf4;--gold:#e7b351;--red:#d8584b}*{box-sizing:border-box}body{margin:0;overflow:hidden;user-select:none;-webkit-user-select:none;touch-action:none}button{font:inherit;border:0;cursor:pointer;color:inherit;touch-action:manipulation;transition:transform .16s,background .16s,box-shadow .16s}button:active{transform:scale(.94)}button:focus-visible{outline:3px solid #e39b34;outline-offset:4px}button:disabled{opacity:.48;cursor:default}button svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}button span,button svg{pointer-events:none}.hidden{display:none!important}#app{height:100dvh;min-height:290px}.shell{height:100%;display:grid;grid-template-columns:260px minmax(0,1fr);max-width:1600px;margin:auto;padding:24px;gap:24px}.rail{display:flex;flex-direction:column;min-height:0;padding:16px 5px 4px}.brand-mark{width:40px;height:40px;background:var(--ink);border-radius:11px;display:grid;place-items:center;color:#f2cd7c;box-shadow:0 4px #c9c6b6;margin-bottom:18px}.brand-mark svg{width:26px;height:26px;fill:#23b49e;stroke:#f2cd7c;stroke-width:2}.eyebrow{text-transform:uppercase;letter-spacing:2.5px;font-size:10px;font-weight:850;color:#7e897f}.brand h1{font-family:Georgia,serif;font-size:43px;line-height:.98;letter-spacing:-2px;font-weight:700;margin:12px 0 9px}.brand h1 span{display:block}.brand .subtitle{text-transform:uppercase;font-size:10px;letter-spacing:3px;font-weight:800;color:#b06a39}.edition{font-size:10px;letter-spacing:1.4px;color:#96998b;margin:22px 0}.rule{height:1px;background:#d4d7c8;margin:0 0 22px}.level-caption{font-size:11px;color:#7d8c7e;text-transform:uppercase;letter-spacing:1.6px;font-weight:700}.kingdom-title{font-family:Georgia,serif;font-size:25px;margin:8px 0 7px}.level-name{font-size:12px;color:#6b8077}.campaign-dots{display:flex;gap:5px;margin:18px 0}.campaign-dots i{height:5px;flex:1;background:#d4d9c6;border-radius:3px}.campaign-dots i.done{background:#159782}.campaign-dots i.active{background:#e4ad46}.objective{background:#e5e7d6;border-radius:12px;padding:15px;display:flex;gap:10px;font-size:11px;line-height:1.55;margin-bottom:14px}.objective b{display:block;color:#1b5148;font-size:12px}.objective .sigil{color:#ac7c36;font-size:24px;line-height:1.2}.rail-bottom{margin-top:auto}.district{border:1px solid #ced2c0;border-radius:12px;padding:14px;background:#f3f1e5;position:relative;overflow:hidden}.district b{font-family:Georgia,serif;font-size:17px}.district p{font-size:10px;color:#798679;margin:6px 0 12px}.castle-mini{height:59px;display:flex;align-items:end;justify-content:center;gap:4px;margin:4px 0 14px}.castle-mini i{display:block;width:23px;background:#b7d3be;border-top:6px dashed #eef0db;height:28px;border-radius:3px 3px 0 0;box-shadow:inset -5px 0 #9fbda8}.castle-mini i:nth-child(2n){height:43px;width:25px}.castle-mini i:nth-child(3){height:56px;background:#549b86;box-shadow:inset -6px 0 #398a76}.castle-mini i.locked{opacity:.23}.small-link{font-size:11px;background:none;padding:0;color:#1b786c;font-weight:800}.rail-foot{font-size:9px;letter-spacing:1px;color:#9b9e8e;text-transform:uppercase;margin:18px 0 0;display:flex;justify-content:space-between}.arena{position:relative;min-width:0;min-height:0;border-radius:23px;background:#dce6d4;overflow:hidden;border:1px solid #d1dccb;box-shadow:0 14px 40px #233f3410}.arena:before{content:"";position:absolute;inset:0;background:radial-gradient(ellipse at 50% 40%,#f7f6e4,transparent 64%);pointer-events:none}.viewport{position:absolute;inset:0;touch-action:none;cursor:grab}.viewport:active{cursor:grabbing}canvas{display:block;width:100%;height:100%;outline:none}.topbar{position:absolute;top:20px;left:22px;right:22px;display:flex;align-items:center;justify-content:space-between;gap:14px;pointer-events:none}.topbar>*{pointer-events:auto}.mission-tag{display:flex;gap:9px;align-items:center;font-size:11px;font-weight:800;letter-spacing:1px}.mission-tag .badge{display:grid;place-items:center;width:31px;height:31px;border-radius:9px;background:#fffdf0;color:#9f7736;box-shadow:0 2px #bdc6af}.tools{display:flex;align-items:center;gap:8px}.icon-btn{width:36px;height:36px;border-radius:50%;background:#fffdf0cc;display:grid;place-items:center;border:1px solid #c7d1bb}.wallet{display:flex;gap:7px;align-items:center;background:#fffdf0da;border-radius:20px;height:34px;padding:0 13px;font-size:12px;font-weight:800}.coin{width:16px;height:16px;border:3px solid #d69b30;background:#f4cd69;border-radius:50%;box-shadow:inset 0 0 0 1px #ffe69a}.fort-hud{position:absolute;top:77px;left:50%;transform:translate(-50%);width:190px;text-align:center;pointer-events:none}.fort-hud .title{display:flex;align-items:center;justify-content:space-between;font-size:9px;font-weight:850;text-transform:uppercase;letter-spacing:1.2px;margin-bottom:6px}.bar{height:7px;background:#2b484328;border-radius:10px;overflow:hidden}.bar i{display:block;width:100%;height:100%;background:#d4574b;border-radius:10px;transition:width .15s}.fort-hud .wave{font-size:9px;color:#7e8d74;margin-top:6px;letter-spacing:1px}.gate-label{position:absolute;pointer-events:none;transform:translate(-50%,-50%);font-weight:900;font-size:23px;letter-spacing:-1px;color:#fff;text-shadow:0 2px 0 #154b4a40;display:grid;place-items:center;min-width:58px;height:42px;border-radius:9px;background:#0e9687e8;border:2px solid #b3f3ce;box-shadow:0 3px #10524e40;transition:background .18s}.gate-label.bad{background:#d15b4eeb;border-color:#ffe0ac}.gate-label .mini{font-size:7px;text-transform:uppercase;letter-spacing:1px;font-weight:750}.gate-label.pulse{animation:gate-pop .25s ease-out}@keyframes gate-pop{0%{scale:1.3}to{scale:1}}.controls{position:absolute;bottom:20px;left:22px;right:22px;display:flex;align-items:end;justify-content:space-between;gap:15px;pointer-events:none}.controls>*{pointer-events:auto}.rotate-box{background:#fffcf0ed;border:1px solid #ccd0bc;border-radius:14px;padding:10px 12px;box-shadow:0 4px #71866d24;min-width:149px}.control-label{font-size:8px;letter-spacing:1.5px;text-transform:uppercase;font-weight:850;color:#758273;margin-bottom:8px;display:flex;justify-content:space-between;gap:10px}.rotate-row{display:flex;gap:7px;align-items:center}.rotate-btn{display:grid;place-items:center;width:38px;height:32px;border-radius:7px;background:#e4e8d5;border:1px solid #cdd5bc}.rotate-hint{font-size:9px;line-height:1.5;color:#537469;min-width:37px}.champion{width:134px;background:#1c4b47;color:#f9e8b8;border:2px solid #f0d08c;border-radius:14px;padding:11px 13px 10px;box-shadow:0 4px #163e3a;position:relative;overflow:hidden}.champion.ready{background:#e4ad46;color:#203f3c;animation:ready-glow 1.5s infinite}.champion .champ-title{display:flex;align-items:center;justify-content:space-between;font-size:11px;font-weight:850;position:relative}.champion .champ-title svg{width:19px;height:19px}.champion .charge{height:4px;background:#ffffff25;border-radius:5px;margin:9px 0 5px;overflow:hidden}.champion .charge i{display:block;height:100%;width:0;background:#f2ce7a;transition:width .15s}.champion small{font-size:8px;letter-spacing:.8px;text-transform:uppercase;position:relative}@keyframes ready-glow{50%{box-shadow:0 0 0 5px #e4ad462b,0 4px #99793c}}.base-hud{position:absolute;bottom:102px;left:50%;transform:translate(-50%);width:100px;pointer-events:none;text-align:center}.base-hud .bar{height:5px}.base-hud .bar i{background:#1b9b86}.base-hud small{font-size:8px;letter-spacing:1.1px;text-transform:uppercase;display:block;margin-bottom:5px;color:#517669;font-weight:800}.onboarding{position:absolute;left:50%;top:67%;transform:translate(-50%,-50%);text-align:center;pointer-events:none;transition:opacity .4s;width:260px}.gesture{font-size:30px;color:#fffbe8;filter:drop-shadow(0 2px 1px #285a4d);animation:swipe 2s ease-in-out infinite}.onboarding .pill{display:inline-block;background:#234c46ed;color:#fffae7;padding:9px 15px;border-radius:20px;font-size:10px;font-weight:750;box-shadow:0 3px 12px #1a484026;margin-top:4px}.onboarding small{display:block;font-size:9px;color:#62816e;margin-top:7px;font-weight:700}.rotate-nudge{position:absolute;bottom:114px;left:22px;padding:7px 10px;background:#fbf0cd;border-radius:7px;color:#8b6634;font-size:9px;box-shadow:0 2px #b99d6930;pointer-events:none;animation:float 1.5s infinite}@keyframes swipe{0%,to{transform:translate(-35px) rotate(-12deg)}50%{transform:translate(35px) rotate(12deg)}}@keyframes float{50%{transform:translateY(-4px)}}.toast{position:absolute;top:135px;left:50%;transform:translate(-50%,-10px);background:#1b4c43e8;color:#fff8df;border:1px solid #6e9b78;border-radius:22px;padding:9px 19px;font-size:11px;font-weight:800;opacity:0;transition:opacity .2s,transform .2s;pointer-events:none;white-space:nowrap}.toast.show{opacity:1;transform:translate(-50%)}.float-text{position:absolute;pointer-events:none;font-weight:900;font-size:22px;color:#fff3b8;text-shadow:0 2px 2px #1d5142;animation:rise .85s ease-out forwards;z-index:5}@keyframes rise{0%{opacity:1;transform:translate(-50%) scale(.7)}25%{transform:translate(-50%,-15px) scale(1.2)}to{opacity:0;transform:translate(-50%,-65px) scale(1)}}.modal-wrap{position:absolute;inset:0;background:#193f3c7d;backdrop-filter:blur(6px);z-index:10;display:flex;align-items:center;justify-content:center;padding:20px;overflow-y:auto;touch-action:pan-y}.modal{width:min(440px,100%);background:#fffaf0;border:1px solid #f4e3bd;border-radius:22px;padding:29px;text-align:center;box-shadow:0 18px 80px #13352c40;animation:modal-in .35s cubic-bezier(.16,1,.3,1);max-height:100%;overflow:auto;touch-action:pan-y}.modal.wide{width:min(650px,100%)}@keyframes modal-in{0%{opacity:0;transform:translateY(22px) scale(.93)}to{opacity:1;transform:none}}.modal .eyebrow{color:#ab7937}.modal h2{font-family:Georgia,serif;font-size:35px;line-height:1.05;letter-spacing:-1px;margin:12px 0}.modal p{font-size:12px;color:#738273;line-height:1.65;margin:12px 0 22px}.medal{font-size:48px;margin:6px 0 10px;color:#d4a143}.stars{color:#dba23e;font-size:26px;letter-spacing:7px;margin:8px 0}.primary{display:block;background:#1a8171;border:1px solid #096051;color:#fff9de;border-radius:11px;padding:14px 20px;font-size:12px;font-weight:800;box-shadow:0 4px #135f53;width:100%;margin:12px 0}.secondary{display:block;background:#ececda;border:1px solid #d8ddc5;color:#416457;border-radius:10px;padding:12px 18px;font-size:11px;font-weight:750;width:100%;margin-top:10px}.result-stats{display:flex;justify-content:center;gap:30px;padding:15px 0;border-top:1px solid #e7e5d5;border-bottom:1px solid #e7e5d5;margin:18px 0}.result-stats b{display:block;font-size:21px;color:#1c6457}.result-stats small{font-size:8px;letter-spacing:1.5px;text-transform:uppercase;color:#83917e}.upgrade-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:20px 0}.upgrade-card{text-align:left;background:#edefdf;border:1px solid #d6dfc9;border-radius:12px;padding:15px 12px}.upgrade-card .upgrade-icon{font-size:26px;color:#1d8d77}.upgrade-card h3{font-size:12px;margin:10px 0 6px}.upgrade-card p{font-size:10px;margin:5px 0 12px;min-height:32px}.upgrade-card button{width:100%;border-radius:7px;background:#1b7c6b;color:#fff4d2;padding:9px 3px;font-size:10px;font-weight:800}.unit-cards{display:flex;gap:8px;margin-top:17px}.unit-card{flex:1;background:#f0eddc;border:2px solid transparent;padding:11px 7px;border-radius:10px;font-size:10px}.unit-card.selected{border-color:#148d78;background:#e0ecdb}.unit-card b{display:block;margin:6px 0}.unit-card small{font-size:9px;color:#788671}.unit-card .unit-icon{font-size:24px}.collection-title{text-align:left;font-size:10px;text-transform:uppercase;letter-spacing:1.3px;color:#748975;font-weight:800;margin-top:25px}.district-build{background:#e7ebd9;border-radius:12px;padding:14px;margin-top:15px;font-size:11px}.daily-row{background:#f5eacd;border-radius:10px;padding:12px;display:flex;align-items:center;justify-content:space-between;font-size:11px;gap:12px;text-align:left;margin-top:15px}.daily-row small{display:block;font-size:9px;margin-top:4px;color:#9a8057}.daily-row button{background:#b58538;color:#fff7db;border-radius:7px;font-size:10px;padding:9px 14px;font-weight:800}.keyboard-note{font-size:9px;color:#8d9885;text-align:center;line-height:1.7;margin-top:17px}.mobile-brand{display:none}.loading{position:absolute;inset:0;display:grid;place-items:center;background:#eeeade;z-index:20;font-family:Georgia,serif;font-size:24px;color:#1c6154}.loading span{animation:float 1s infinite}.status-line{font-size:9px;color:#a0a589;letter-spacing:1px;text-transform:uppercase;position:absolute;left:50%;bottom:6px;transform:translate(-50%);pointer-events:none;white-space:nowrap}@media(min-width:1400px){.shell{padding:30px 45px;gap:40px;grid-template-columns:270px 1fr}.rail{padding-top:25px}.brand h1{font-size:49px}.arena{border-radius:27px}.controls{left:30px;right:30px;bottom:28px}.topbar{top:25px;left:30px;right:30px}}@media(max-width:1000px){.shell{grid-template-columns:210px 1fr;padding:16px;gap:16px}.brand h1{font-size:36px}.rail{padding-top:8px}.edition{margin:15px 0}.objective{padding:12px}.topbar,.controls{left:15px;right:15px}.district{padding:12px}}@media(max-width:650px)and (orientation:portrait){.shell{display:block;padding:0}.rail{display:none}.arena{height:100%;border-radius:0;border:0}.topbar{top:max(14px,env(safe-area-inset-top));left:15px;right:15px}.mission-tag{font-size:10px;letter-spacing:.8px}.fort-hud{top:76px;width:175px}.controls{bottom:max(22px,env(safe-area-inset-bottom));left:14px;right:14px}.rotate-nudge{left:14px;bottom:119px}.rotate-box{min-width:143px}.champion{width:128px}.base-hud{bottom:109px}.modal-wrap{padding:16px}.modal{padding:24px 20px}.modal h2{font-size:31px}.upgrade-grid{gap:6px}.upgrade-card{padding:12px 8px}.upgrade-card h3{font-size:11px}.upgrade-card p{font-size:9px;min-height:42px}.wallet{padding:0 10px}.tools{gap:6px}.icon-btn{width:33px;height:33px}.unit-card{padding:10px 4px}.status-line{bottom:5px}}@media(max-height:560px)and (orientation:landscape){.shell{grid-template-columns:180px 1fr;gap:12px;padding:10px}.rail{padding:4px 0}.brand-mark,.edition,.objective,.district,.rail-foot,.rule{display:none}.brand h1{font-size:30px;margin-top:8px}.brand .subtitle{font-size:8px;letter-spacing:2px}.eyebrow{font-size:8px}.level-caption{font-size:9px;margin-top:20px}.kingdom-title{font-size:20px}.level-name{font-size:10px}.campaign-dots{margin:12px 0}.rail-bottom{margin-top:auto}.arena{border-radius:15px}.topbar{top:10px;left:12px;right:12px}.mission-tag{font-size:9px}.mission-tag .badge{width:25px;height:25px}.tools{gap:5px}.icon-btn{height:29px;width:29px}.wallet{height:28px;font-size:10px;padding:0 9px}.fort-hud{top:51px;width:144px}.fort-hud .title,.fort-hud .wave{font-size:8px}.controls{bottom:12px;left:12px;right:12px;align-items:end}.rotate-box{min-width:118px;padding:8px}.rotate-btn{width:29px;height:27px}.rotate-hint{font-size:8px;min-width:30px}.control-label{font-size:7px;margin-bottom:5px}.champion{width:111px;padding:9px}.champion .champ-title{font-size:10px}.champion .charge{margin:7px 0 4px}.champion small{font-size:7px}.base-hud{bottom:82px;width:80px}.gate-label{font-size:18px;min-width:47px;height:32px;border-radius:7px}.gate-label .mini{font-size:6px}.rotate-nudge{bottom:95px;left:12px;font-size:8px}.onboarding{top:65%;width:220px}.gesture{font-size:23px}.onboarding .pill{font-size:9px;padding:7px 12px}.onboarding small{display:none}.toast{top:93px;font-size:10px;padding:7px 15px}.modal-wrap{padding:12px}.modal{padding:18px 24px;max-height:100%}.modal h2{font-size:27px;margin:7px 0}.modal p{font-size:11px;margin:8px 0 12px}.medal{font-size:30px;margin:0}.stars{font-size:20px;margin:5px 0}.result-stats{padding:8px 0;margin:10px 0}.primary{padding:11px;margin:9px 0}.secondary{padding:10px;margin-top:7px}.upgrade-grid{margin:12px 0}.upgrade-card{padding:10px}.upgrade-card h3{margin:5px 0}.upgrade-card p{min-height:0}.upgrade-icon{display:none}.collection-title{margin-top:14px}.unit-cards{margin-top:9px}.unit-card{padding:7px}.unit-card .unit-icon{font-size:17px}.daily-row{padding:8px;margin-top:9px}.keyboard-note{margin-top:10px}.district-build{padding:10px;margin-top:10px}}@media(prefers-reduced-motion:reduce){*{animation-duration:.01ms!important;transition-duration:.01ms!important}}.faded{opacity:.2}.inline-coin{display:inline-block;vertical-align:middle}@media(min-width:651px)and (min-height:561px){.fort-hud{top:24px}}@media(max-width:650px)and (orientation:portrait){.icon-btn{width:44px;height:44px}.tools{gap:5px}.rotate-btn{width:44px;height:40px}.rotate-box{min-width:158px}.control-label{font-size:7px}.topbar{gap:8px}.mission-tag{font-size:9px;gap:6px}.mission-tag .badge{width:26px;height:30px}.wallet{padding:0 9px}.fort-hud{top:82px}}@media(max-height:560px)and (orientation:landscape){.rotate-btn{width:42px;height:36px}.rotate-box{min-width:140px}.icon-btn{width:36px;height:36px}}.castle-mini{gap:2px}.castle-mini i{width:14px;flex:1;max-width:23px}.castle-mini i:nth-child(2n){width:18px;height:39px}.castle-mini i:nth-child(3n){height:50px}.castle-mini i:nth-child(4n){height:31px}.castle-mini i:nth-child(7){height:58px;background:#549b86}@media(max-width:650px)and (orientation:portrait){.rotate-nudge{bottom:141px}}
