/* Anime 39: live UI, shared with the illustrated home and combat atlases. */
:root{--ink:#eee7d5;--muted:#b8c3d2;--paper:#223047;--edge:#88754f;--gold:#dfb868;--green:#d7b16d;--dark:#111c31;--red:#e6a18e;--top:46px;background:#111c31;color:#eee7d5}
body{background:#111c31}.game{background:#18253b;color:#eee7d5}
button,input,select{color:#ecdfc3;background:#283b52;border-color:#8b7a57;box-shadow:0 2px 0 #090e1e55}
button:hover{background:#354d65}.primary,button.primary{color:#292331;background:linear-gradient(#e8cc83,#caa45c);border-color:#f4d79a;box-shadow:0 2px 0 #715735}
.primary:hover,button.primary:hover{background:#f0d58e}button.selected,button.active{background:#4a5360;border-color:#f1d693;color:#ffe0a1}
input,select{color-scheme:dark}small,p{color:inherit}.muted{color:#b8c3d2}.empty{color:#c3cddb}
.topbar{height:var(--top);background:linear-gradient(100deg,#121b2e,#25364c);border-bottom:1px solid #a48a55;box-shadow:0 2px 12px #0e142c70;color:#ffefd0}
.brand{color:#fae9bf!important}.brand small{color:#b9c5d4}.money{color:#efd297}.time-badge{color:#d0b575;background:#27384a}.top-meta .connection{color:#9fccb8}.top-meta .install-button{background:#2a3c4d;color:#e8d6ad}
.paper,.modal,.d-world-sheet{background:#223148;color:#eee4d0;border-color:#998159}.modal>header{border-color:#817353;background:linear-gradient(100deg,#172438,#2b3b50)}.modal>header h2{color:#f4ddb0}.eyebrow{color:#cdb784}.veil{background:#0b112acc}.modal-body{color:#e9e1d0}.modal button{color:#f3e8cf;background:#2b3e54;border-color:#857657}.modal button.primary{background:linear-gradient(#e8cc83,#caa45c);color:#292331}.modal button.selected{background:#4a5360;border-color:#f1d693;color:#ffe0a1}
.anime-portrait{background:linear-gradient(135deg,#4d6179,#1a273e);border-radius:4px;object-fit:cover;flex:none;image-rendering:auto!important}
.anime-item{image-rendering:auto!important;overflow:hidden;filter:drop-shadow(0 2px 2px #0a112b80)}.art-core{filter:hue-rotate(135deg) saturate(1.2) drop-shadow(0 2px 2px #0a112b80)}
.unit-figure{position:relative;display:inline-block;width:100%;height:100%;min-height:0;pointer-events:none}.unit-figure>svg{width:100%;height:100%;overflow:hidden;filter:drop-shadow(0 2px 1px #11182b90)}.unit-weapon{position:absolute;left:49%;top:36%;width:46%;height:48%;transform:rotate(8deg)}.unit-weapon>.item-art{width:100%!important;height:100%!important}
.d-preparation,.a-room,.r-room,.c-room,.q-room,.g-room,.x-room{background:linear-gradient(135deg,#26344b,#131e33);color:#eee5d1}
.d-title,.a-heading,.r-heading{border-color:#8f7951;color:#f7e6bd}.d-title h1,.a-heading h1,.r-heading h1{color:#f7e6bd}
.d-board,.a-party{background:#18283d;border-color:#9f8a63}.d-board>header,.a-team-picker{background:#1c2f47;color:#eae2ce}
.d-plan-board{background:linear-gradient(#142b4055,#142b4088),url('/assets/anime39/arena.png') center 70%/cover;border-color:#7b91a1}
.d-plan-cell{background:#173f5940!important;border-color:#aacde742!important;color:#d8d1bd}.d-plan-cell.enemy-zone{background:#69465044!important}.d-plan-cell.selected{background:#eac77a35!important;box-shadow:inset 0 0 0 2px #f3d493!important}.d-plan-cell.in-range{background:#4b9bc333!important}.d-plan-cell.linked{border-color:#8aecdb!important}.d-plan-cell>span:not(.unit-figure){position:absolute;bottom:0;left:0;right:0;background:#15243dd6;color:#f3e7c9;z-index:1;line-height:1.3;font-size:10px}.d-plan-cell{position:relative;padding:2px 2px 12px!important;overflow:hidden}.d-plan-cell .unit-figure{height:100%;max-width:70px}.d-plan-caption,.d-plan-reading{background:#1a2e43;color:#d8e1e8}.d-plan-reading span,.d-plan-reading small{color:#c1d0dc}.d-plan-reading b{color:#f5dda5}
.d-gear,.d-learn,.d-edit,.d-hero-detail,.d-trial{background:#24344d;color:#eee6d5;border-color:#8e805e}.d-gear>header{background:#24344d}.d-gear>header h2{color:#f6dfad}.d-gear h2 small{color:#b1c5d8}.d-gear-slot{background:#263f54;color:#f1e7cc}.d-loadout button{background:#2b3f58}.d-focus,.d-skill,.d-hero-stats,.d-item-choice,.d-gear-detail{background:#192b42;color:#e4e3d6}
.a-board{background:linear-gradient(#162a3e30,#162a3e80),url('/assets/anime39/arena.png') center/cover}.a-board-cells>button,.a-empty-cell{background:#173a5144;border-color:#91b3c94a}.a-board-cells>button{padding:3px;position:relative;overflow:hidden}.a-board-cells>button>.unit-figure{height:100%;width:75%;max-width:85px}.a-board-cells>button>span:not(.unit-figure){position:absolute;bottom:1px;left:0;right:0;background:#14243dda;color:#f5e9c9;text-align:center;display:block;font-size:10px}.a-board-cells small{display:none}.a-board-edge,.a-loadout{background:#1d3048;color:#d3dbe2}
.a-match,.a-rating,.a-opponent,.a-result-row,.a-results-list,.a-history-list article,.a-analysis{background:#22344c;color:#f0e5cf;border-color:#8a7857}.a-rating{background:linear-gradient(100deg,#34435b,#1c2b41)}.a-rating b,.a-rating strong{color:#efd08c}.a-opponent p,.a-match-note,.a-results-footer small{color:#bac8d5}.a-rounds>div{background:#1b2c42;color:#d9dfdc;border-color:#796d52}.a-rounds .win,.a-result-score.win{background:#24493f;color:#bde4bf}.a-rounds .loss{background:#5a343c;color:#efb6a5}.a-result-opponent,.a-outcome-health,.a-result-observation{color:#e8e3d5}.a-result-observation{background:#263f55!important}.a-hp-comparison i{background:#111e34}.a-history-summary{background:#243b51}
.r-tree,.r-detail,.r-progress{background:#22334b;color:#e9e5d7;border-color:#867958}.r-branches>div{background:#263e53;color:#e3d3af}.r-nodes button{background:#22354d;color:#d4dee6}.r-nodes button.learned{background:#304c51;border-color:#adc78e;color:#eaf1ce}.r-nodes button.selected{background:#4a4d52;border-color:#f2d180;color:#ffe6af}.r-products button,.r-cost{background:#192b43;color:#e7e0cd}.r-progress{color:#d9ddcf}
.forge-main{background:linear-gradient(#152238db,#152238f2),url('/assets/anime39/hall.png') left center/cover}.market-main{background:linear-gradient(#142238e8,#142238f5),url('/assets/anime39/hall.png') right center/cover}.organization-main{background:#18283e}
.fx-floating,.fx-copy,.fx-floating>header,.l-reference{background:#1c2c42;color:#eae0ca;border-color:#a78b55}.fx-sheet .fx-copy h2,.fx-copy-title h2{color:#f3d897}.fx-clip{background:#17263c;border-color:#a28b5c}.fx-caption{background:#1b2c45ee;color:#f0e3c4}.fx-controls{background:#13243cd9}.fx-phase{background:#203850;color:#f4d796}
.welcome{background:#15243b}.welcome-art{background-image:url('/assets/anime39/hall.png')!important;background-position:center;background-size:cover}.welcome-paper{background:#192b41f0;color:#eee2c6}.welcome-paper .lead{color:#f4dbac}
/* Battle is full height: battlefield + simultaneous army comparison. */
.veil:has(.lab-modal){padding:0!important}.veil .lab-modal{max-width:none!important;width:100%!important;height:100%!important;border:0;border-radius:0;background:#111e33;color:#ede3cc}
.lab-modal>.modal-body{padding:6px}.l-room,.l-room:has(.l-compare-controls){grid-template-rows:28px minmax(0,1fr) 29px 29px;gap:4px}.l-heading{gap:6px}.l-heading h2{font-size:14px}.l-heading small{font-size:10px;color:#c3cad3}.l-heading>span{color:#f4d595}.l-moment-select{display:block!important;font-size:10px;min-height:25px;height:25px;width:105px;background:#25384e;color:#ede1c4;border:1px solid #88795c;padding:2px}
.l-layout{grid-template-columns:minmax(0,1fr) minmax(0,1.1fr);gap:6px}.l-stage{display:block;position:relative;min-width:0;min-height:0}.l-keymoments,.l-stage>.l-roster{display:none}.l-canvas-wrap{height:100%;border-color:#8f8268;border-radius:4px}
.l-analysis{background:#17273d;color:#e9e4d5;border-color:#8f8268}.l-analysis>nav{flex-basis:25px;background:#27394e;padding:1px 4px}.l-analysis>nav button{font-size:11px;min-height:23px;padding:2px 9px}.l-analysis>nav>small{color:#b4c7d5}#l-panel{padding:4px}
.lab-modal button{color:#eee5cf;background:#2a3f56;border-color:#7b745d;box-shadow:none}.lab-modal button.selected{color:#f9de9a;background:#495064;border-color:#dabd75}.lab-modal button.primary{color:#252839;background:#dabb73}.l-playback{gap:5px}.l-playback button{min-height:28px;font-size:10px}.l-playback select{color:#ecdfc3;background:#25394d}.l-playback label>span{color:#d6dce2}
.l-footer{padding-top:2px;border-color:#56667b;gap:5px}.l-footer>div:first-child>span{display:none}.l-footer b{font-size:10px}.l-footer button{min-height:26px;font-size:10px}.l-compare-controls small{max-width:100px;overflow:hidden;text-overflow:ellipsis}.l-compare-controls{gap:3px}
.l-unit-focus,.l-item-focus,.l-comparison{color:#eee4ce}.l-target,.l-unit-numbers,.l-comparison-team,.l-comparison-metrics>div{background:#293e54;color:#eadfc8}.l-target span{color:#ecc594}.l-target small,.l-skill-line small{color:#c6d0da}.l-team-id.side-0{color:#a6dfed}.l-team-id.side-1{color:#efb99f}.l-health{background:#10213b}.l-health em{background:#80c6ad}.l-equipment button,.l-log-entries button{background:#243b52;color:#e2e4db}.l-log-entries .down{background:#503642;color:#f8ceb7}.l-log-entries time{color:#eed28e}.l-reference-paper,.l-ref-section,.l-ref-stats,.l-ref-skill,.l-ref-equipment{color:#ece2c9;background:#21344c}
.p-live-data{background:#18293f;color:#efe3cb}.p-live-data .bc-metrics button{background:#2a3f56;color:#dce1dc}.p-live-data .bc-metrics button.selected{background:#4a5360;color:#ffe0a1}
@media(max-height:340px){:root{--top:36px}.l-room,.l-room:has(.l-compare-controls){grid-template-rows:25px minmax(0,1fr) 27px 27px;gap:3px}.lab-modal>.modal-body{padding:4px}.l-heading h2{font-size:12px}.l-heading small{font-size:9px}.l-analysis>nav{flex-basis:24px}.l-footer button{min-height:24px}.l-moment-select{width:85px;font-size:9px}.l-compare-controls small{max-width:60px}.top-meta .time-badge{font-size:8px}}
/* The original parchment panels are replaced as a group, including their copy. */
.d-equipped,.d-gear-candidates article,.d-slots button,.d-node-sheet,.d-loot-preview,.d-report-loot,.d-investments article{background:#293d53;color:#efe5cc;border-color:#85785d}
.d-equipped{background:#1b3048;border-left-color:#dbb970}.d-equipped :is(b,p,small),.d-gear-candidates :is(p,small,button),.d-node-sheet :is(p,small,h2,b),.d-slots button{color:#e8e0cc}.d-slots button.selected{background:#485260;border-color:#e5c784;color:#ffe3a3}.d-gear-candidates article .d-candidate-info{color:#f1d59c;background:none}.d-gear-candidates article button.primary{color:#292331}
.d-preparation .d-board{grid-template-rows:27px 15px minmax(0,1fr) 36px 24px 30px;gap:3px}.d-preparation:has(.l-plan) .d-board{grid-template-rows:27px 15px minmax(0,1fr) 36px 24px}.d-preparation .d-title{height:28px}.d-preparation .d-plan-reading{padding:3px 5px;overflow:hidden;gap:1px}.d-plan-reading>span{font-size:9px;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.d-plan-reading b{font-size:10px}.d-plan-board .d-plan-cell .unit-figure{display:block;line-height:normal;flex-shrink:1;height:100%;min-height:0}.d-plan-board .unit-figure>svg{display:block;width:100%;height:100%;max-height:none!important;max-width:none!important}.d-plan-board .unit-figure .unit-weapon{line-height:normal}
.d-dungeon{background:linear-gradient(#19263cd9,#19263ce8),url('/assets/anime39/dungeon.png') center/cover}.d-route-map{background:linear-gradient(#15263c30,#15263c88),url('/assets/anime39/dungeon.png') center/cover}.d-route-map button{background:#24364bea;border-color:#c6a46c;color:#f0dbb0}.d-route-map button.selected{background:#665838;color:#fff1c7}.d-route-rule{color:#c2cedb}.d-neighbors{background:#1b2e44;color:#dce1da}
.m-room,.g-room{background:linear-gradient(#1b2c42e8,#142138f5);color:#e9e2d0}.m-room :is(h1,h2,h3,p,small,label),.g-room :is(h2,h3,p,small,label){color:inherit}.m-tabs button,.m-toolbar select,.m-pager button,.m-recipe-grid button{background:#293d54;color:#dfdfd5;border-color:#7a745f}.m-tabs button.selected,.m-recipe-grid button.selected{background:#4d5260;color:#ffe0a1;border-color:#e2be74}.m-card,.m-empty,.m-object,.m-current,.m-note,.m-craft-desk,.m-ended-list>div,.m-discovery .m-demand-board,.m-sale-object{background:#263a51;color:#eae2ce;border-color:#8a7b5c}.m-card.q2{background:#39354e;border-color:#b5a0d2}.m-card.q1{border-color:#89bbae}.m-object :is(p,small,b,h2),.m-current,.m-card :is(h3,p,small,b){color:inherit}.m-note{color:#c3d0da}.m-materials button,.m-trade-total,.m-focus-label select{background:#1d3149;color:#f0dfb8}.m-materials button.short{background:#50323e;color:#f3b6a4}.m-forge.m-designed-workbench .m-before-craft,.m-preview-buyer,.m-skill-opening{background:#254454;color:#e9e5cc;border-color:#a7986a}.m-focus-label>b{color:#afe0c9}.m-market-place>small{color:#c4d0da}.m-discovery .m-shelf,.m-discovery .m-demand-boards{background:#1b2c41}.m-grid .m-card{box-shadow:0 3px 10px #08142860}.m-card .item-art,.m-recipe-grid .item-art{filter:drop-shadow(0 0 7px #cbb57533)}
.commerce-modal,.o-modal{background:#1c2e44;color:#eee3c8}.commerce-modal :is(p,h2,h3,small,label),.o-room :is(h2,h3,p,small,label){color:inherit}.commerce-modal input,.commerce-modal select,.o-room select{background:#233d53;color:#f0dfbc}.lr-stats-grid>div,.lr-skill>strong,.lr-bonuses>b,.lr-traits>button,.o-stats>div,.o-bag,.o-report-rows article{background:#2b4057;color:#ede5cf}.lr-traits>button.is-active{background:#3b5759;color:#dbeacc;border-color:#98bba0}.l-reference :is(p,b,small,h2,h3),.lr-stats-grid :is(small,strong),.lr-skill :is(p,small){color:inherit}.l-reference .lr-muted{color:#b9c9d7}.o-mana{background:#253c54;color:#d9e6ed}.o-room button{background:#263e55;color:#f0e2c4}.o-room button.selected{background:#495565;border-color:#efd58e;color:#f6db9f}.o-room button.primary{background:#d7b570;color:#2e2832}
.x-room{background:linear-gradient(#142139bb,#142139ed),url('/assets/anime39/dungeon.png') center/cover;color:#e9e3d1}.x-road,.x-sheet,.x-travel-note,.x-bag>div>span,.x-rules section,.x-item-cards>section,.x-plan-copy{background:#21364de8;color:#e6e2d4;border-color:#917e5c}.x-crew-list>button{background:#293f57;color:#e9e4d4}.x-crew-list>.fallen{background:#4b3441;color:#eac6b5}.x-road-grid>button{background:#233b51;color:#e9d7b4}.x-road-grid .cleared{background:#31514d;color:#e0e5bd}.x-road-grid .defeated{background:#563841;color:#e8b5a3}.x-policy-tabs>button{background:#2b4057;color:#e8dfc8}.x-policy-tabs>.selected{background:#695b40;color:#ffe6b3}.x-room :is(h1,h2,h3,p,small),.x-plan-copy :is(p,small){color:inherit}
.bc-row{--bc-progress:0%;}.bc-row:before{content:'';position:absolute;left:0;bottom:0;width:var(--bc-progress);height:100%;background:linear-gradient(90deg,#c4b97918,#e0c47828);z-index:-1;pointer-events:none}.bc-row.side-1:before{background:linear-gradient(90deg,#d8958815,#e3ae7b2d)}
@media(max-height:340px){.d-preparation .d-board{grid-template-rows:24px 14px minmax(0,1fr) 30px 22px 28px;gap:2px}.d-preparation:has(.l-plan) .d-board{grid-template-rows:24px 14px minmax(0,1fr) 30px 22px}.d-plan-reading>span{display:none}.d-preparation .d-title{height:26px}.d-plan-cell{padding-bottom:10px!important}.d-plan-cell>span:not(.unit-figure){font-size:9px}}
.l-room.watching .l-moment-select{visibility:visible}.m-discovery .m-shelf{color:#eee1c4;border-color:#8b7c60;border-bottom-color:#be9856;background:linear-gradient(140deg,#30455c,#1e3149)}.m-shelf-foot b,.m-board-title>strong,.m-sale-result>strong{color:#f2ce89}.m-shelf-foot small,.m-shelf-title small,.m-board-title small,.m-board-foot{color:#bbcdd8}.m-board-foot>b{color:#e5dabd}.m-board-title>strong small{color:#ddc48d}.m-sale-result>b{color:#a8d3b2}.l-heading small{font-size:9px}
.fx-facts>span,.skill-charge-guide{background:#273e55;color:#eee3c7;border-color:#82929e}.skill-charge-guide i,.skill-charge-guide .charge-pips{color:#99d5ef}.skill-charge-guide p{color:#c3d3df}.d-charge-intro{color:#afcadd!important}.presentation-modal{background:#17263c;border-color:#aa905c;color:#efe4c8}.p-battle-stage{background:#14253b;border-color:#8593a1}.p-rounds>span{background:#24394b;color:#dce3d7;border-color:#7e8066}.p-rounds .current{background:#74613c}.p-verdict{background:linear-gradient(110deg,#152139f5,#283a51ec,#132239f5)}.p-verdict.loss{background:linear-gradient(110deg,#1e2039f5,#513543ed,#18263bf5)}.p-summary-row{background:#2e4359;color:#e6e3d1;border-left-color:#b4cf9e}.p-home-body>aside{background:#263b52;color:#e5e1d1;border-color:#93845f}.presentation-modal .p-return-treasures>button{background:#2e4157;color:#e9dfc6;border-color:#867858}.presentation-modal .p-return-treasures>.q1{background:#254758;border-color:#8fcacb}.presentation-modal .p-return-treasures>.q2{background:#483e58;border-color:#c4a0da}
.a-board .a-board-cells{background:linear-gradient(#172d4555,#172d4533),url('/assets/anime39/arena.png') center 70%/cover}.a-board .a-board-cells>button,.a-board .a-empty-cell{background:#24455b55!important;border-color:#95bdcd55!important;position:relative}.a-board .a-board-cells>button.selected{background:#dab76233!important;border-color:#f0d289!important}.a-board .a-board-cells>button>.unit-figure{position:absolute;inset:0 0 13px;width:100%;height:auto;max-width:none}.a-board .a-board-cells>button>.unit-figure>svg{width:100%;height:100%}.a-board .a-board-cells>button>span:not(.unit-figure){z-index:2;height:13px;line-height:13px}.a-board .a-board-cells>button small{display:none!important}.a-loadout button{background:#293f56;color:#e8e0cc}

/* Live-route and staging controls retain their meaning without parchment contrast loss. */
.map-controls>button{background:#24384fed;color:#f3dfaa;border-color:#b69d65}.map-controls .icon{color:#f3dfaa}
.x-road-grid .unvisited{background:#293a50;color:#c8d3e1;border-color:#6e839b}.x-road-grid .unvisited .x-stop{color:#9dacbd}.x-road-grid .cleared{background:#295361;color:#ddf0e7;border-color:#8ecac6}.x-road-grid .defeated{background:#603c50;color:#f6d6d6;border-color:#cd9199}.x-path>.x-path-edge{stroke:#344860}.x-path>path{stroke:#9b8965}
.a-quick-gear button,.a-loadout button{background:#273d53;color:#eae1cb;border-color:#8b8666}.a-series-matches>div{background:#253d51}.p-summary-row>span>small{color:#b4c9ce}
.p-departure-canvas{display:block;width:78%;height:38%;max-height:190px;flex:none;border:1px solid #a78e5a;border-radius:6px}.p-departure{gap:8px}.p-departure>small{color:#c4d3dc}
@media(max-height:340px){.p-departure{gap:4px}.p-departure-canvas{height:34%;width:68%}.p-departure h1{font-size:21px}}

.lab-modal .l-skill-open{color:#f1d999;background:#2b4158;padding:3px 7px;border:1px solid #7d877a;border-radius:4px;min-height:23px}.lab-modal .l-reference-toggle{background:#344a61;color:#f5e6bf;border-color:#9c936f}
.anime-item{background:transparent!important}
.m-discovery .m-card{background:#263a51!important;color:#eae2ce!important;border-color:#8c9bab!important}.m-discovery .m-card.q1{background:#234452!important;border-color:#78b9bc!important}.m-discovery .m-card.q2{background:#39354e!important;border-color:#c4a1e0!important}.m-discovery .m-card .m-price{color:#f7d796}.m-discovery .m-card small{color:#c3d1df}

.commerce-modal{background:#1c2d44!important;color:#e9e4d2}.commerce-modal :is(h2,h3,p,label){color:#e9e4d2}.commerce-modal small{color:#baccd8}.commerce-modal input,.commerce-modal select{color:#ede4c8;background:#273d53;border-color:#7e8a98}.commerce-modal .m-stat-grid>div{background:#2a4057;border-color:#647c91;color:#e5e5dd}.commerce-modal .m-stat-grid small{color:#bbcddb}.commerce-modal .m-up{color:#a3e4c5}.commerce-modal .m-down{color:#f4b2ab}.commerce-modal .m-object strong{color:#aedbd5}.m-card-bottom{color:#b6c8d3}.m-affix{color:#c4ded3}
.fx-controls button{background:#243b54e8!important;border-color:#b0a679!important}.fx-caption{background:#142740e6!important}

.r-nodes button.learned{background:#305769;color:#def3e8;border-color:#91c7c0}.p-expedition-footsteps>.loss{background:#593748;color:#f0d7d3;border-color:#b57d93}
.commerce-modal .m-price-research>div,.commerce-modal .m-ledger{background:#2b4057;color:#ede4cd;border-color:#788798}.commerce-modal .m-price-research :is(b,span,small){color:#dddcc8}.commerce-modal .m-sale-result{color:#e9e5d1}.commerce-modal .m-sale-result strong{color:#a6e7c5}
