@import url('./quantity-input.css?v=quantity-manual-20261011-v1');
@import url('./mailbox.css?v=7-compact-mail-dialog-20261011&failure-ui=20261011-1');
@import url('./role-badges.css?v=unified-titles-20261013-v1&title-rewards=20261013-v1');
@import url('./career-frames.css?v=1');
@import url('./achievement-toast.css?v=1');
@import url('./tavern-hints.css?v=2-medal-effects');
@import url('./resource-scrollbar.css?v=history-20261014-v3');
.denar-wallet{position:fixed;right:26px;top:20px;z-index:120;display:flex;align-items:center;gap:8px;padding:4px 0;color:#e4c78b;font:20px/1.4 Georgia,serif;pointer-events:none;text-shadow:0 2px 4px #000;isolation:isolate}
.denar-wallet img{display:block;width:32px;height:32px;object-fit:contain;filter:drop-shadow(0 2px 3px #0009)}
.denar-wallet output{min-width:24px;font-variant-numeric:tabular-nums}
.denar-gain{position:absolute;right:0;top:0;font:14px Georgia,serif;color:#f4d78c;opacity:0;pointer-events:none}
.denar-gain.earned{animation:denar-earned .65s ease-out}
@keyframes denar-earned{0%{opacity:0;transform:translateY(0)}15%{opacity:1}70%{opacity:.9}100%{opacity:0;transform:translateY(-30px)}}
body[data-journal] header{padding-right:145px}
.denar-wallet[hidden]{display:none}
.steam-account{position:fixed;right:26px;top:65px;z-index:121;display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;max-width:min(330px,calc(100vw - 32px));padding:9px 12px;border:1px solid #aa916747;border-radius:6px;background:#161b1ced;color:#d6bd85;font:12px/1.5 system-ui,sans-serif;box-shadow:0 3px 14px #0003}
.steam-account-battle{left:24px;right:auto;top:auto;bottom:22px;justify-content:flex-start}
.steam-account{flex-direction:row;align-items:center;justify-content:flex-start;width:max-content;box-sizing:border-box;gap:10px;padding:6px 10px}
.steam-account-header{display:contents}
.steam-account-header .steam-identity{min-width:0;max-width:145px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.steam-account-header .steam-author-link{color:#efd39a;text-decoration:underline;text-decoration-color:#c4a56a88;text-underline-offset:3px}
.steam-role-badge{order:1;flex-shrink:0;padding:1px 5px;border:1px solid #c4a56a88;border-radius:3px;color:#efd39a;font-size:10px;line-height:1.5}.steam-role-badge[hidden]{display:none}
.steam-account-header button{flex-shrink:0}
.steam-account .denar-wallet,.steam-account .denar-reward{position:relative;inset:auto;margin:0;width:auto;flex-shrink:0}
.steam-account .denar-reward,.steam-account .denar-wallet{order:2;border-left:1px solid #aa91672b;padding:0 0 0 10px;height:auto;min-height:32px;gap:6px}
.steam-account .reward-ring,.steam-account .reward-ring svg{width:32px;height:32px}
.steam-account .reward-ring img{width:20px;height:20px}
.steam-account .reward-balance{font-size:16px}
.steam-account .denar-label{display:none}
.steam-account-header button{order:3}
.steam-account .steam-account-header a,.steam-account .steam-account-header button{border:0;background:transparent;padding:4px 0}
.steam-account .steam-account-header button{color:#99998c;font-size:11px}
.steam-account .steam-account-header a:hover,.steam-account .steam-account-header button:hover{color:#ffe1a0;background:transparent}
.denar-label{font:12px/1.5 system-ui,sans-serif;color:#b9b6a9}
.world-login-toast{position:fixed;bottom:calc(36px + env(safe-area-inset-bottom,0px));left:50%;transform:translateX(-50%);z-index:200;max-width:calc(100vw - 40px);box-sizing:border-box;padding:11px 20px;border:1px solid #aa91677a;border-radius:6px;background:#161b1cf2;color:#ecd6a5;font:14px/1.5 system-ui,sans-serif;text-align:center;box-shadow:0 4px 18px #0005;pointer-events:none}
.world-login-toast[hidden]{display:none}
.world-login-toast.is-showing{animation:world-login-float 3s linear both}
@keyframes world-login-float{from{opacity:1;transform:translate(-50%,0)}to{opacity:0;transform:translate(-50%,-72px)}}
@media(prefers-reduced-motion:reduce){.world-login-toast.is-showing{animation-name:world-login-fade}@keyframes world-login-fade{0%,100%{opacity:0}12%,58%{opacity:1}}}
.steam-account a,.steam-account button{display:inline-block;pointer-events:auto;padding:5px 10px;border:1px solid #aa91677a;border-radius:4px;background:#293333;color:#ecd6a5;text-decoration:none;font:inherit;cursor:pointer}
.steam-account [hidden]{display:none}.steam-account a:hover,.steam-account button:hover{background:#384444}.steam-account a:focus-visible,.steam-account button:focus-visible{outline:2px solid #e4c78b;outline-offset:3px}.steam-account button:disabled{opacity:.55;cursor:wait}
.steam-status{order:4;flex-basis:100%;font-size:11px;color:#b9b6a9}.steam-status:empty,.steam-identity:empty{display:none}
.steam-login-error{position:fixed;left:50%;bottom:36px;transform:translateX(-50%);z-index:1250;display:flex;align-items:center;gap:16px;max-width:600px;box-sizing:border-box;padding:12px 16px;border:1px solid #aa91677a;border-radius:6px;background:#161b1cf2;color:#f0c6a1;font:14px/1.5 system-ui,sans-serif;box-shadow:0 4px 18px #0005}
.steam-login-error[hidden]{display:none}.steam-login-error button{flex-shrink:0;padding:0 4px;border:0;background:transparent;color:#ecd6a5;font:22px/1.2 system-ui,sans-serif;cursor:pointer}.steam-login-error button:focus-visible{outline:2px solid #e4c78b;outline-offset:3px}
@media(max-width:700px){.steam-account{right:12px;top:10px;max-width:min(250px,calc(100vw - 24px));padding:7px 9px}.steam-account-battle{left:12px;right:auto;top:auto;bottom:14px}}
.denar-reward{position:fixed;left:24px;bottom:22px;z-index:120;display:flex;align-items:center;gap:10px;height:44px;pointer-events:none}
.reward-balance{font:19px/1.4 Georgia,serif;font-variant-numeric:tabular-nums;color:#d6bd85;text-shadow:0 1px 3px #000;min-width:22px}
.reward-ring{position:relative;width:44px;height:44px;display:grid;place-items:center;border-radius:50%;background:#15191870}
.reward-ring svg{position:absolute;inset:0;width:44px;height:44px;transform:rotate(-90deg)}
.reward-ring circle{fill:none;stroke-width:2}.reward-ring .ring-track{stroke:#ad956137}.reward-ring .ring-fill{stroke:#c0a064;stroke-linecap:round;stroke-dasharray:100;stroke-dashoffset:100}
.reward-ring img{width:23px;height:23px;object-fit:contain;opacity:.88;filter:drop-shadow(0 1px 2px #0009)}
.denar-reward .denar-gain{right:auto;left:0;width:44px;top:-4px;text-align:center;font-size:16px;text-shadow:0 1px 3px #000}
@media(max-width:700px){.denar-wallet{right:12px;top:10px;font-size:17px}.denar-wallet img{width:27px;height:27px}body[data-journal] header{padding-right:85px}.denar-reward{left:12px;bottom:14px}}
@media(prefers-reduced-motion:reduce){.denar-gain.earned{animation:denar-fade .65s ease-out}@keyframes denar-fade{0%,100%{opacity:0}20%,70%{opacity:1}}}

.denar-gain.spent{color:#efaa83}

/* Floating feedback stays outside the account layout, including its docked state. */
.resource-delta{position:fixed;z-index:320;pointer-events:none;color:#f4d78c;font:700 16px/1.3 Georgia,serif;font-variant-numeric:tabular-nums;text-shadow:0 1px 3px #000;white-space:nowrap;animation:resource-delta-rise 1.1s cubic-bezier(.22,.68,.25,1) both}
.resource-delta.is-spent{color:#efaa83}
.resource-feedback-announcement{position:fixed;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;pointer-events:none}
@keyframes resource-delta-rise{0%{opacity:0;transform:translateY(5px)}14%,65%{opacity:1}100%{opacity:0;transform:translateY(-38px)}}
@media(prefers-reduced-motion:reduce){.resource-delta{animation-name:resource-delta-fade}@keyframes resource-delta-fade{0%,100%{opacity:0}14%,65%{opacity:1}}}

.food-wallet{order:4;display:flex;align-items:center;gap:9px;flex-basis:100%;width:100%;color:#d6bd85;padding-top:5px}.food-wallet[hidden]{display:none}.food-wallet img{width:24px;height:24px;object-fit:contain}.food-wallet output{font:17px Georgia,serif}.food-wallet button{margin-left:auto;border:1px solid #9b814b70;background:#272c23;color:#ddc58c;padding:3px 8px;cursor:pointer}.food-exchange{margin:auto;padding:24px;background:#1b231d;color:#decca4;border:1px solid #a58b55;max-width:calc(100vw - 40px)}.food-exchange::backdrop{background:#0009}.food-exchange input{width:100px}.food-exchange button{padding:6px 12px;cursor:pointer}.steam-account:has(.food-wallet){flex-wrap:wrap}

/* Share the currency column so food stays under denars as names and balances change. */
.steam-account:has(.food-wallet){display:grid;grid-template-columns:minmax(0,auto) auto auto auto;column-gap:10px;row-gap:5px}
.steam-account:has(.food-wallet) .steam-identity,.steam-account:has(.food-wallet) .steam-account-header>a:not(.steam-identity){grid-column:1;grid-row:1}
.steam-account:has(.food-wallet) .steam-role-badge{grid-column:2;grid-row:1}
.steam-account:has(.food-wallet) .denar-reward,.steam-account:has(.food-wallet) .denar-wallet{grid-column:3;grid-row:1}
.steam-account:has(.food-wallet) .steam-account-header>button{grid-column:4;grid-row:1;justify-self:start}
.steam-account .food-wallet{grid-column:3 / 5;grid-row:2;display:grid;grid-template-columns:32px max-content auto;gap:6px;width:auto;min-width:0;padding:0 0 0 11px;align-items:center}
.steam-account .food-wallet[hidden]{display:none}
.steam-account .food-wallet img{justify-self:center;width:20px;height:20px}
.steam-account .food-wallet output{font-size:16px}
.steam-account .food-wallet button{justify-self:end;white-space:nowrap;margin-left:0}
.steam-account:has(.food-wallet) .steam-status{grid-column:1 / -1;grid-row:3}

.resource-shop{position:fixed;inset:auto;margin:0;box-sizing:border-box;width:330px;max-width:calc(100vw - 16px);padding:0;overflow:auto;z-index:160;border-radius:6px;border:1px solid #9b814b99;background:linear-gradient(145deg,#242d24f7,#111a16fc);box-shadow:0 10px 36px #0009;transform-origin:bottom center}
.resource-shop[open]{animation:resource-shop-in .22s cubic-bezier(.22,1,.36,1) both}.resource-shop[open].is-closing{animation:resource-shop-out .18s cubic-bezier(.4,0,.2,1) both}
body .resource-shop .resource-shop-header{display:flex;align-items:center;justify-content:space-between;padding:14px 18px;border-bottom:1px solid #9b814b55;background:none;position:static}
.resource-shop h2{margin:0;color:#e6cf97;font:22px KaiTi,serif}.resource-shop-header button{border:0;background:transparent;color:#decca4;font-size:24px;padding:0 4px}.resource-shop-products{padding:14px}.resource-shop-product{border:1px solid #a58b554d;padding:14px;background:#ffffff04}.resource-shop-product-heading{display:flex;align-items:center;gap:12px}.resource-shop-product-heading img{object-fit:contain}.resource-shop h3{margin:0;font-size:18px}.resource-shop-product-heading p{margin:3px 0 0;color:#aaa58e;font-size:12px}.resource-shop-price{color:#d9bd76}.resource-shop label{display:flex;align-items:center;justify-content:space-between;gap:12px}.resource-shop input{box-sizing:border-box;background:#101813;color:#e7d4a5;border:1px solid #9b814b88;padding:7px;width:100px}.resource-shop [type=submit]{width:100%;background:#75633c;color:#fff0c4;border:1px solid #c5a966;padding:9px}.resource-shop [role=status]{font-size:12px;color:#e1c78a}.resource-shop [role=status]:empty{display:none}.resource-shop .food-exchange-preview{font-size:13px}.resource-shop button:disabled{opacity:.5;cursor:wait}
@keyframes resource-shop-in{from{opacity:0;transform:translateY(22px)}to{opacity:1;transform:translateY(0)}}@keyframes resource-shop-out{from{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(22px)}}


.steam-account:has(.food-wallet){cursor:pointer}

.steam-account .influence-wallet{grid-column:3 / 5;grid-row:3;display:grid;grid-template-columns:32px max-content;gap:6px;align-items:center;padding-left:11px;color:#d6bd85}.steam-account .influence-wallet[hidden]{display:none}.influence-wallet img{justify-self:center;width:20px;height:20px;object-fit:contain}.influence-wallet output{font:16px Georgia,serif;font-variant-numeric:tabular-nums}.steam-account:has(.food-wallet) .steam-status{grid-row:4}

/* Match visible icon height and numeric typography across all three resources. */
.steam-account .reward-ring{background:transparent}
.steam-account .reward-ring img,.steam-account .food-wallet img,.steam-account .influence-wallet img{display:block;width:auto;height:24px;max-width:28px;object-fit:contain;opacity:1;filter:drop-shadow(0 1px 2px #0009)}
.steam-account .reward-balance,.steam-account .denar-wallet output,.steam-account .food-wallet output,.steam-account .influence-wallet output{font:400 16px/24px Georgia,serif;font-variant-numeric:tabular-nums;letter-spacing:0;color:#d6bd85;text-shadow:0 1px 3px #000;min-width:24px}
.steam-account .food-wallet,.steam-account .influence-wallet{min-height:32px}

/* Keep sign-out centered beside the complete resource stack. */
.steam-account:has(.food-wallet) .steam-account-header>button{grid-column:4;grid-row:1 / 4;align-self:center;justify-self:center;margin-left:4px;padding:8px 6px}
.steam-account .food-wallet,.steam-account .influence-wallet{grid-column:3;grid-template-columns:32px max-content}

/* Place sign-out immediately after the role badge in the identity row. */
.steam-account:has(.food-wallet){grid-template-columns:minmax(0,auto) auto auto auto}
.steam-account:has(.food-wallet) .steam-account-header>button{grid-column:3;grid-row:1;align-self:center;justify-self:start;margin:0;padding:4px 0}
.steam-account:has(.food-wallet) .denar-reward,.steam-account:has(.food-wallet) .denar-wallet{grid-column:4;grid-row:1}
.steam-account .food-wallet,.steam-account .influence-wallet{grid-column:4}

/* A full-height, fading divider between identity controls and resources. */
.steam-account:has(.food-wallet) .denar-reward,.steam-account:has(.food-wallet) .denar-wallet{border-left-color:transparent}
.steam-account:has(.food-wallet)::after{content:"";grid-column:4;grid-row:1 / 4;align-self:stretch;justify-self:start;width:1px;background:linear-gradient(180deg,transparent,#ae956780 30%,#ae956780 70%,transparent);pointer-events:none}

.steam-account .denar-reward .reward-ring{background:transparent;box-shadow:none;border:0;border-radius:0}.steam-account .denar-reward .reward-ring img{filter:none}

#resource-shop-title:focus{outline:none}.resource-shop-header button:focus-visible{outline:1px solid #d6bd85;outline-offset:3px}

/* Fixed shop shell; product rows scroll inside without resizing the window. */
.resource-shop{width:580px;height:740px;min-height:0;top:auto;overflow:hidden}
.resource-shop[open]{display:flex;flex-direction:column}
.resource-shop-header,.resource-shop-tabs{flex-shrink:0}
.resource-shop-tabs{display:flex;align-items:center;gap:10px;padding:14px 16px}
.resource-shop-tabs button{flex:1;min-width:0;height:38px;padding:4px 12px;border:1px solid #9b814b66;background:#18221a;color:#decca4;font:15px KaiTi,serif}
.resource-shop-tabs button.is-active,.resource-shop-footer .resource-shop-history.is-active{background:#75633c;border-color:#c5a966;color:#fff0c4}
.resource-shop-footer .resource-shop-history{height:30px;box-sizing:border-box;border:1px solid #a58d5d88;background:#303a2d;color:#e7cd92;font:13px KaiTi,serif;padding:6px 12px;cursor:pointer}
.resource-shop-footer .resource-shop-history:hover{background:#494832;border-color:#c5a966}
.resource-shop-tabs button:disabled{cursor:default;opacity:.35}
.resource-shop-tabs:has(button[data-admin-only="true"]:enabled){padding-bottom:34px}
.resource-shop-tabs button[data-admin-only="true"]{position:relative}
.resource-shop-tabs button[data-admin-only="true"]:enabled::after{content:'仅管理员显示';position:absolute;top:calc(100% + 5px);left:0;width:100%;color:#e68c86;font:11px/16px "Microsoft YaHei",sans-serif;white-space:nowrap;pointer-events:none}
.resource-shop-products{flex:1;min-height:0;overflow:auto;padding:0 16px 16px;scrollbar-gutter:stable}
.resource-shop-product{display:grid;grid-template-columns:80px 108px minmax(210px,1fr) 56px;align-items:center;column-gap:10px;row-gap:0;padding:12px 10px;min-height:72px;min-width:488px}
.resource-shop-product-heading{gap:7px;flex-wrap:nowrap}
.resource-shop-product-heading h3{font-size:17px;white-space:nowrap}
.resource-shop-product-heading img{width:26px;height:32px}
.resource-shop-price{font-size:12px;text-align:center;white-space:nowrap}
.resource-shop-price>span{color:#aaa58e}.resource-shop-price p{margin:5px 0 0}
.resource-shop-exchange-row{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;gap:8px;min-width:0}
.resource-shop-exchange-row label{gap:4px;white-space:nowrap;font-size:12px}
.resource-shop-exchange-row input{width:48px;padding:4px 3px}
.resource-shop-exchange-row .food-exchange-preview{margin:0;font-size:12px;white-space:nowrap;color:#e7d4a5}
.resource-shop-product>[type=submit]{width:56px;padding:6px 4px;white-space:nowrap;font-size:13px}
.resource-shop-product>[role=status]{grid-column:1/-1;margin:0;min-height:14px;line-height:14px;font-size:11px}
.resource-shop-product>[role=status]:empty{display:block;visibility:hidden}
@media(max-width:540px){.resource-shop-tabs{gap:6px}.resource-shop-tabs button{padding-inline:5px}.resource-shop-products{padding-inline:10px}.resource-shop-product{min-width:488px}}

body .resource-shop .resource-shop-header{width:100%;max-width:none;box-sizing:border-box;align-self:stretch;margin:0;flex:0 0 auto}

.resource-shop-product-heading{gap:4px}.resource-shop-product-heading img{flex-shrink:0}.resource-shop-product-heading h3{line-height:1.3}.resource-shop-product-heading p{white-space:nowrap;font-size:11px;line-height:1.4;margin:3px 0 0}.resource-shop-price{line-height:1.4}

.resource-shop .resource-shop-status{min-height:16px;margin:8px 2px 0;line-height:16px;font-size:11px}.resource-shop .resource-shop-status:empty{display:block;visibility:hidden}

/* Keep quantity entry plain and compact. */
.resource-shop-exchange-row input:focus,.resource-shop-exchange-row input:focus-visible{outline:none;box-shadow:none}

body .resource-shop .resource-shop-header{height:34px;min-height:34px;padding:2px 16px;justify-content:flex-end}.resource-shop .shop-visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.resource-shop-product+.resource-shop-product{margin-top:10px}

.steam-account .steam-career-link{grid-column:1/4;grid-row:2;justify-self:start;align-self:center;margin:3px 10px 3px 0;padding:3px 9px;border:1px solid #8a7063;background:#332b29;color:#d8cbc4;text-decoration:none;font-size:12px;line-height:20px}.steam-account .steam-career-link[data-route=wealth]{background:#3b3021;border-color:#ad955a;color:#edcb83}.steam-account .steam-career-link[data-route=logistics]{background:#20372e;border-color:#91a89a;color:#e6eadf}.steam-account .steam-career-link[data-route=military]{background:#252f4a;border-color:#829eb7;color:#e4e9f0}.steam-account .steam-medal-link{grid-column:1/4;grid-row:3;justify-self:start;align-self:center;color:#cfc2a2;padding:3px 0;text-decoration:none;font-size:12px}.steam-account .steam-career-link:hover,.steam-account .steam-medal-link:hover{color:#ffe3a4}.resource-shop-quota{margin:0 16px 10px;font-size:12px;color:#c6b78f}

.steam-account .steam-career-link,.steam-account .steam-medal-link{display:inline-flex;align-items:center;gap:5px}.steam-account .steam-career-link[hidden],.steam-account .steam-medal-link[hidden]{display:none}.steam-career-link img{width:16px;height:18px;object-fit:contain}.steam-medal-link img{width:24px;height:24px;object-fit:contain;border:1px solid #95805880}.steam-career-link[data-tier="7"],.steam-career-link[data-tier="8"]{box-shadow:inset 0 0 0 2px #101813,inset 0 0 0 3px #95805855}

/* Compact identity row, with the rank in the former author slot. */
.steam-account:has(.food-wallet){grid-template-columns:minmax(0,auto) auto;max-width:min(440px,calc(100vw - 24px));column-gap:14px}
.steam-account:has(.food-wallet) .steam-account-header{display:flex;grid-column:1;grid-row:1;align-items:center;gap:7px;min-width:0}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link{order:0;display:inline-flex;white-space:nowrap;margin:0;padding:1px 5px;font-size:11px;line-height:17px;border:1px solid #8a7063;background:#332b29;color:#d8cbc4;border-radius:2px}
.steam-account:has(.food-wallet) .steam-role-badge{order:0;margin:0;background:#29333b;color:#cfdeea;border-color:#829eb780;font-size:10px;white-space:nowrap}
.steam-account:has(.food-wallet) .steam-account-header>button{order:0;margin:0;padding:2px 0;white-space:nowrap}
.steam-account:has(.food-wallet) .steam-identity{flex-shrink:1;max-width:125px}
.steam-account:has(.food-wallet) .steam-medal-link{grid-column:1;grid-row:2/4;align-self:start;display:flex;gap:7px;border:0;background:none;padding:2px 0;margin:0;justify-self:start}
.steam-account .steam-medal-link img{width:36px;height:40px;border:0;object-fit:contain}.steam-account .steam-medal-link:hover img{filter:brightness(1.13)}
.steam-account:has(.food-wallet) .denar-wallet,.steam-account:has(.food-wallet) .denar-reward,.steam-account:has(.food-wallet) .food-wallet,.steam-account:has(.food-wallet) .influence-wallet{grid-column:2}
.steam-account:has(.food-wallet)::after{grid-column:2}.steam-account:has(.food-wallet) .steam-status{grid-column:1/-1}
.steam-account [hidden]{display:none!important}
.progression-window{position:fixed;inset:auto;margin:0;padding:0;width:640px;max-width:calc(100vw - 16px);max-height:calc(100dvh - 32px);border:1px solid #a98d53;border-radius:5px;background:#202a23;color:#d8be83;z-index:170;box-shadow:0 10px 36px #0009;overflow:hidden;box-sizing:border-box}
.progression-window[open]{display:flex;flex-direction:column}.progression-window-bar{height:34px;min-height:34px;display:flex;align-items:center;justify-content:space-between;padding:0 12px;border-bottom:1px solid #ad956954;font:13px KaiTi,serif}.progression-window-bar button{padding:0 4px;border:0;background:none;color:#d8be83;font:24px/28px Georgia,serif;cursor:pointer}.progression-window-bar button:focus:not(:focus-visible){outline:none}.progression-window iframe{display:block;min-height:0;flex:1;width:100%;border:0;background:#202a23}
@media(max-width:480px){.steam-account:has(.food-wallet){column-gap:8px}.steam-account:has(.food-wallet) .steam-account-header{gap:4px}.steam-account:has(.food-wallet) .steam-identity{max-width:78px}.steam-account .steam-medal-link img{width:30px;height:34px}}

/* Identity frames restored from the approved three-career-routes preview. */
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link{position:relative;box-sizing:border-box;height:19px;padding:1px 5px;border:1px solid var(--edge);border-radius:3px;background:var(--base);color:var(--light);font:10px/15px system-ui,"Microsoft YaHei",sans-serif;box-shadow:none;--base:#332B29;--light:#D8CBC4;--edge:#8A7063}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"]{--base:#3D2C1B;--light:#F0E1C3;--metal:#C6A267}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="8"]{--edge:#D9BA7A}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="7"]{--edge:#C6A267}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="6"]{--edge:#B39464}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="5"]{--edge:#A68B65}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="4"]{--edge:#968362}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="3"]{--edge:#88785C}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="wealth"][data-tier="2"]{--edge:#786E5A}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"]{--base:#293820;--light:#E1E9CF;--metal:#A9B878}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="8"]{--edge:#CDCA86}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="7"]{--edge:#B8BD7C}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="6"]{--edge:#A9B878}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="5"]{--edge:#98AC74}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="4"]{--edge:#899C6F}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="3"]{--edge:#7A8D68}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="logistics"][data-tier="2"]{--edge:#6B7E60}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"]{--base:#302B48;--light:#E8E4F2;--metal:#A59BC6}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="8"]{--edge:#D0BB83}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="7"]{--edge:#B8ACC9}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="6"]{--edge:#A59BC6}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="5"]{--edge:#9994B8}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="4"]{--edge:#8C8BA7}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="3"]{--edge:#7E8198}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-route="military"][data-tier="2"]{--edge:#707689}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:before,.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:after{content:"";position:absolute;pointer-events:none;box-sizing:border-box}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="8"]{background:linear-gradient(120deg,color-mix(in srgb,var(--base),var(--metal) 10%),var(--base));box-shadow:inset 0 1px 0 color-mix(in srgb,var(--edge),transparent 75%)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="8"]:before,.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="7"]:before{inset:-3px;background:linear-gradient(var(--edge),var(--edge)) left top/5px 1px no-repeat,linear-gradient(var(--edge),var(--edge)) left top/1px 4px no-repeat,linear-gradient(var(--edge),var(--edge)) right top/5px 1px no-repeat,linear-gradient(var(--edge),var(--edge)) right top/1px 4px no-repeat,linear-gradient(var(--edge),var(--edge)) left bottom/5px 1px no-repeat,linear-gradient(var(--edge),var(--edge)) left bottom/1px 4px no-repeat,linear-gradient(var(--edge),var(--edge)) right bottom/5px 1px no-repeat,linear-gradient(var(--edge),var(--edge)) right bottom/1px 4px no-repeat}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="8"]:after{width:3px;height:3px;background:var(--edge);transform:rotate(45deg);top:-3px;left:calc(50% - 1.5px)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="7"]:after{height:1px;width:8px;background:var(--edge);bottom:-3px;left:calc(50% - 4px)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="6"]:before{top:3px;bottom:3px;left:-3px;right:-3px;border-left:1px solid var(--edge);border-right:1px solid var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="5"]:before{left:4px;right:4px;top:-3px;height:1px;background:var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="5"]:after{left:4px;right:4px;bottom:-3px;height:1px;background:var(--edge);opacity:.7}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="4"]:before{top:-2px;left:-2px;width:5px;height:4px;border-left:1px solid var(--edge);border-top:1px solid var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="4"]:after{bottom:-2px;right:-2px;width:5px;height:4px;border-right:1px solid var(--edge);border-bottom:1px solid var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="3"]:after{left:calc(50% - 3px);bottom:-2px;height:1px;width:6px;background:var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="1"]{--base:#2B2F33;--light:#D9D5CC;--edge:#68727A}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="1"]:before{left:2px;top:2px;bottom:2px;border-left:1px solid var(--edge);opacity:.55}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="0"]:before{left:2px;top:2px;width:3px;height:3px;border-left:1px solid var(--edge);border-top:1px solid var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[data-tier="0"]:after{right:2px;bottom:2px;width:3px;height:3px;border-right:1px solid var(--edge);border-bottom:1px solid var(--edge)}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:hover{color:var(--light);filter:brightness(1.15)}
.steam-account:has(.food-wallet) .steam-account-header .steam-role-badge{box-sizing:border-box;display:inline-flex;height:19px;align-items:center;gap:4px;padding:1px 5px;border:1px solid #ad8ec0;border-radius:3px;background:#35263f;color:#ebdaf3;font:10px/15px system-ui,sans-serif;white-space:nowrap;flex-shrink:0}

.resource-shop .resource-shop-progression{display:block;flex:1;width:100%;min-height:0;border:0;background:#222d25}.resource-shop .resource-shop-progression[hidden],.resource-shop .resource-shop-products[hidden],.resource-shop .resource-shop-quota[hidden]{display:none!important}

.steam-account:has(.food-wallet) .steam-medal-link{display:grid;grid-template-columns:repeat(5,32px);grid-template-rows:repeat(2,28px);gap:4px 7px;align-self:center;padding:2px 0;width:max-content}
.steam-medal-slot{display:flex;align-items:center;justify-content:center;width:32px;height:28px}.steam-account .steam-medal-link img{width:28px;height:28px;object-fit:contain}.steam-medal-slot.is-empty:after{content:none}
@media(max-width:480px){.steam-account:has(.food-wallet) .steam-medal-link{column-gap:4px}}
/* Keep the three rank cost groups on one desktop row. */
.resource-shop{width:640px}

.steam-account .steam-career-link,.steam-account .steam-medal-link{cursor:pointer;font-family:inherit}.steam-account .steam-medal-link{text-align:left}

/* A single food product with two independently submitted exchange rows. */
.resource-shop-food-group{display:grid;grid-template-columns:90px minmax(0,1fr);grid-template-rows:auto auto auto;column-gap:12px;padding:0 12px;border:1px solid #a58b5566;background:#ffffff04;min-width:530px;box-sizing:border-box}
.resource-shop-food-group>.resource-shop-product-heading{grid-column:1;grid-row:1/4;align-self:center;justify-content:center}
.resource-shop-food-group>.resource-shop-product{grid-column:2;min-width:0;grid-template-columns:108px minmax(210px,1fr) 56px;border:0;background:none;padding:12px 0;margin:0;min-height:74px;column-gap:10px}
.resource-shop-food-group>.resource-shop-product+.resource-shop-product{border-top:1px solid #a58b554d;margin:0}

.resource-shop-footer{flex:0 0 auto;display:flex;justify-content:flex-end;align-items:center;padding:8px 14px;border-top:1px solid #a58d5d40;background:#222d25}.resource-shop-footer .resource-shop-logout{border:1px solid #a58d5d88;background:#303a2d;color:#e7cd92;font:13px KaiTi,serif;padding:6px 14px;cursor:pointer}.resource-shop-footer .resource-shop-logout:hover{background:#494832;border-color:#c5a966}.resource-shop-footer .resource-shop-logout:disabled{opacity:.5;cursor:wait}.resource-shop-footer .resource-shop-logout[hidden]{display:none}
.resource-shop-footer{gap:8px;flex-wrap:wrap}
.resource-shop-footer .resource-shop-bag.is-active{background:#75633c;border-color:#c5a966;color:#fff0c4}
.resource-goods-shop{margin-top:20px;padding-top:16px;border-top:1px solid #a58b5555}
.resource-goods-description{font:13px/1.7 system-ui,sans-serif;color:#b9ac8d;margin:8px 0 12px}
.resource-goods-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.resource-goods-card{display:flex;flex-direction:column;align-items:center;min-width:0;padding:12px 10px;border:1px solid #a58b5555;background:#ffffff04;text-align:center}
.resource-goods-card>img{width:100%;height:95px;max-width:135px;object-fit:contain;filter:drop-shadow(0 3px 3px #0006)}
.resource-goods-card h4{font:18px/1.4 KaiTi,STKaiti,serif;color:#e7cd92;margin:8px 0 0}
.resource-goods-owned{font:12px/1.6 system-ui,sans-serif;color:#b9ac8d;margin:4px 0 10px}
.resource-goods-card .resource-goods-quantity{display:flex;justify-content:center;gap:8px;font:13px/1.5 system-ui,sans-serif}
.resource-goods-card .resource-goods-quantity input{width:60px;padding:5px}
.resource-goods-price{font:12px/1.8 system-ui,sans-serif;color:#dfc58c;min-height:44px;margin:10px 0;overflow-wrap:anywhere}
.resource-goods-price-part{display:inline-block;white-space:nowrap}
.resource-goods-actions{display:flex;gap:8px;width:100%;margin-top:auto}
.resource-goods-actions button,.resource-goods-bag-heading>button{flex:1;min-width:0;background:#75633c;border:1px solid #c5a966;color:#fff0c4;padding:7px 10px;font:14px/1.4 KaiTi,STKaiti,serif;cursor:pointer;transition:background .18s cubic-bezier(.22,.61,.36,1),border-color .18s cubic-bezier(.22,.61,.36,1)}
.resource-goods-actions button:hover{background:#8b7749;border-color:#e3c782}
.resource-goods-bag{display:flex;flex-direction:column;flex:1;min-height:0;overflow:hidden;padding:0}
.resource-goods-bag[hidden],.resource-goods-gift[hidden]{display:none!important}
.resource-goods-bag-content{flex:1;min-height:0;overflow:auto;padding:0 16px 16px;scrollbar-gutter:stable}
.resource-goods-bag .resource-goods-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}
.resource-goods-card--owned{display:flex;flex-direction:column;align-items:center;text-align:center;padding:10px 7px}
.resource-goods-identity{display:flex;align-items:center;gap:8px;min-width:0}
.resource-goods-identity>img{width:64px;height:74px;object-fit:contain;flex-shrink:0;filter:drop-shadow(0 3px 3px #0006)}
.resource-goods-identity h4{font-size:17px;margin:0}
.resource-goods-identity .resource-goods-owned{margin:4px 0 0}
.resource-goods-details{min-width:0}
.resource-goods-details .resource-goods-quantity{justify-content:flex-start}
.resource-goods-details .resource-goods-price{min-height:0;margin:8px 0 0}
.resource-goods-card--owned .resource-goods-identity{flex-direction:column;gap:6px;width:100%}
.resource-goods-card--owned .resource-goods-identity h4{font-size:16px;overflow-wrap:anywhere}
.resource-goods-card--owned .resource-goods-owned{margin-bottom:10px}
.resource-goods-card--owned .resource-goods-details{width:100%}
.resource-goods-card--owned .resource-goods-quantity{justify-content:center;gap:5px;font-size:12px}
.resource-goods-card--owned .resource-goods-quantity input{width:42px;padding:4px}
.resource-goods-card--owned .resource-goods-price{margin:8px 0 12px;font-size:11px;line-height:1.7}
.resource-goods-card--owned .resource-goods-price-label,.resource-goods-card--owned .resource-goods-price-part{display:block}
.resource-goods-card--owned .resource-goods-actions{margin-top:auto}
.resource-goods-card--owned .resource-goods-actions button{padding:7px 3px;white-space:nowrap}
.resource-goods-bag:not([hidden]){animation:goods-panel-in .22s cubic-bezier(.22,.61,.36,1) both}
.resource-goods-bag-heading{display:flex;align-items:center;gap:12px;margin-bottom:14px;flex-wrap:wrap}
.resource-goods-bag-heading>p{font:13px/1.6 system-ui,sans-serif;margin:0;color:#d9bd76}
.resource-goods-bag-heading>button{flex:0 0 auto;margin-left:auto}
.resource-goods-bag>.resource-goods-bag-heading{flex:0 0 auto;padding:0 16px}
.resource-goods-fee-notice{flex:0 0 auto;margin:0;padding:11px 16px;border-top:1px solid #a58d5d55;background:#222d25;color:#dfc58c;font:13px/1.7 system-ui,sans-serif}
.resource-goods-gift{flex:1;min-height:0;overflow:auto;padding:0 16px 16px;scrollbar-gutter:stable}
.resource-goods-target:empty{display:none}.resource-goods-target{font:13px/1.6 system-ui,sans-serif;color:#dfc58c;margin:8px 0}
.resource-goods-shop>h3{margin:0;font:18px/1.5 KaiTi,STKaiti,serif;color:#e7cd92}
.resource-goods-shop>.resource-goods-description{margin:4px 0 12px}
.resource-goods-status:empty{display:none}
.resource-goods-shop .resource-goods-grid{display:flex;flex-direction:column;gap:10px}
.resource-goods-card--shop{display:grid;grid-template-columns:minmax(160px,.9fr) minmax(0,1.4fr) 72px;gap:12px;align-items:center;text-align:left;padding:12px}
.resource-goods-card--shop .resource-goods-identity>img{width:48px;height:56px}
.resource-goods-card--shop .resource-goods-actions{margin:0;align-self:center}
.resource-goods-status{font:13px/1.7 system-ui,sans-serif;color:#e1c78a;overflow-wrap:anywhere}
.resource-goods-empty{grid-column:1/-1;font:14px/1.8 system-ui,sans-serif;color:#b9ac8d;padding:18px 0}
@keyframes goods-panel-in{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
@media(max-width:540px){.resource-goods-grid,.resource-goods-bag .resource-goods-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.resource-shop-footer{gap:6px;padding:8px 10px}.resource-goods-bag-content,.resource-goods-bag>.resource-goods-bag-heading,.resource-goods-fee-notice,.resource-goods-gift{padding-inline:10px}.resource-goods-card--owned{padding:10px}.resource-goods-identity>img{width:50px;height:62px}}

/* Compact the account panel through spacing only; keep type and artwork sizes. */
.steam-account:has(.food-wallet){padding:5px 8px;column-gap:9px;row-gap:2px}
.steam-account:has(.food-wallet) .steam-account-header{gap:5px;flex-wrap:wrap}
.steam-account:has(.food-wallet) .steam-medal-link{grid-template-columns:repeat(5,28px);grid-template-rows:repeat(2,28px);gap:2px 4px;padding:0}
.steam-account .steam-medal-slot{width:28px;height:28px}
.steam-account .food-wallet,.steam-account .influence-wallet{min-height:28px;padding-left:8px;grid-template-columns:28px max-content;gap:5px}
.steam-account .denar-reward,.steam-account .denar-wallet{min-height:28px;padding-left:8px;gap:5px}
.steam-account .reward-ring{width:28px;height:28px}


.steam-medal-link,.steam-medal-slot{cursor:pointer;user-select:none;-webkit-user-select:none}.steam-medal-slot img{-webkit-user-drag:none;pointer-events:none}

.resource-shop-food-group>.resource-shop-quota{grid-column:2;grid-row:2;display:flex;align-items:center;justify-content:center;gap:12px;margin:0;color:#b9ac8d;font:14px/1.5 KaiTi,STKaiti,serif;white-space:nowrap}.resource-shop-food-group>.resource-shop-quota::before,.resource-shop-food-group>.resource-shop-quota::after{content:"";flex:1;height:1px}.resource-shop-food-group>.resource-shop-quota::before{background:linear-gradient(90deg,transparent,#ae956780 80%,#ae956780)}.resource-shop-food-group>.resource-shop-quota::after{background:linear-gradient(90deg,#ae956780,#ae956780 20%,transparent)}

/* The wallet button hosts the same rank badge as the progression tree. */
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link{all:unset;display:inline-flex;align-items:center;order:0;margin:0;cursor:pointer;flex-shrink:0}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:before,.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:after{content:none}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link[hidden]{display:none}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:hover{filter:none}
.steam-account:has(.food-wallet) .steam-account-header .steam-career-link:focus-visible{outline:1px solid #d8be83;outline-offset:4px}

/* The identity and its suffixes set the left column width; medals wrap within it. */
.steam-account:has(.food-wallet) .steam-medal-link{display:flex;flex-wrap:wrap;width:auto;max-width:none;min-width:0;height:58px;min-height:0;max-height:58px;box-sizing:border-box;justify-self:stretch;align-self:start;align-content:flex-start;align-items:flex-start;justify-content:flex-start;contain:inline-size;gap:2px 4px;overflow-x:hidden;overflow-y:auto;overscroll-behavior-y:contain;scrollbar-gutter:stable;scrollbar-width:thin;scrollbar-color:#a28b55 #17221c}
.steam-account .steam-medal-link::-webkit-scrollbar{width:5px}
.steam-account .steam-medal-link::-webkit-scrollbar-track{background:#17221c}
.steam-account .steam-medal-link::-webkit-scrollbar-thumb{background:#a28b55;border-radius:3px}
.steam-account .steam-medal-slot{flex:0 0 28px}
.steam-account .steam-medal-slot.is-empty{display:none}
.steam-medal-link.is-readonly,.steam-medal-link.is-readonly .steam-medal-slot{cursor:default}
.steam-account.steam-account-dock{padding-right:23px;transform:translateX(0);transition:transform 560ms cubic-bezier(.65,0,.35,1)}
.steam-account.steam-account-dock.is-collapsed{transform:translateX(calc(-1 * var(--account-slide,0px)))}
.steam-account .steam-account-toggle{position:absolute;inset:0 0 0 auto;display:flex;align-items:center;justify-content:center;width:18px;padding:0;border:0;border-left:1px solid #aa91672b;border-radius:0 5px 5px 0;background:transparent;color:#decca4;opacity:0;transition:opacity 180ms ease;cursor:pointer}
.steam-account .steam-account-toggle svg{width:10px;height:18px;fill:none;stroke:currentColor;stroke-width:1.4;transition:transform 560ms cubic-bezier(.65,0,.35,1)}
.steam-account.is-collapsed .steam-account-toggle svg{transform:rotate(180deg)}
.steam-account .steam-account-toggle:hover,.steam-account .steam-account-toggle:focus-visible{opacity:1;background:#aa91671c}
@media(hover:none){.steam-account .steam-account-toggle{opacity:.7}}


.captain-name-dialog input{box-sizing:border-box;width:100%;min-width:0;padding:10px 12px;min-height:44px;border:1px solid #a88d5c80;border-radius:3px;background:#18221b;color:#e3d4af;font:inherit}.captain-name-dialog input:focus-visible{outline:2px solid #c4a668;outline-offset:2px}.captain-name-dialog input:disabled{opacity:.6}.mail-captain-attachment{padding:12px;border:1px solid #a88d5c50;color:#e4c78b}

/* Feedback keeps its space during requests, errors and retries. */
.resource-shop .resource-shop-status{height:32px;min-height:32px;overflow:auto;overflow-wrap:anywhere}
.resource-shop .resource-goods-status,.resource-shop .resource-goods-status:empty{display:block;height:3.4em;min-height:3.4em;margin:8px 0;overflow:auto;overflow-wrap:anywhere}

.resource-shop .resource-shop-footer .resource-shop-logout-status{flex:1;min-width:0;height:28px;line-height:14px;font-size:11px;overflow:auto;overflow-wrap:anywhere;margin:0}.resource-shop .resource-shop-footer .resource-shop-logout-status:empty{display:block;visibility:hidden}
