/* 本包独立视觉系统：深青、旧金、暖白。原版与旧存档不套用。 */
.tx-edition { --tx-ink:#101d22; --tx-paper:#f2ead9; --tx-gold:#d7b77a; --tx-muted:#b9c5c4; }
/* 天玄属性顺序沿用原槽位，但可见底图必须是风/雷而不是旧世界金/木。 */
.tx-edition .radar-node.n-metal { background-image:url("../assets/yuanwen-ui/surfaces/v2/ui/灵根属性_风.svg"); }
.tx-edition .radar-node.n-wood { background-image:url("../assets/yuanwen-ui/surfaces/v2/ui/灵根属性_雷.svg"); }
.tx-edition .edp-lg-gold { background-image:url("../assets/yuanwen-ui/surfaces/v2/ui/灵根属性_风.svg"); }
.tx-edition .edp-lg-wood { background-image:url("../assets/yuanwen-ui/surfaces/v2/ui/灵根属性_雷.svg"); }
.tx-edition #game-screen::after { content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(180deg,#061318b3,transparent 40%,#071116dc);z-index:0; }
.tx-edition #hud-top { background:linear-gradient(180deg,#071317ed,#071317bb);border-bottom:1px solid #d7b77a55; }
.tx-edition #game-screen .hud-craft { opacity:.7; }
.tx-edition #year-badge { background:none;border:1px solid #d7b77a55;border-radius:.3rem;font-family:inherit; }
.tx-chapter-header { position:absolute;top:12.2rem;left:7rem;right:7rem;z-index:2;pointer-events:none; }
.tx-eyebrow { color:var(--tx-gold);font:500 1rem/1.8 "Source Han Sans SC",sans-serif;letter-spacing:.24em; }
.tx-chapter-title { color:var(--tx-paper);font:400 3.4rem/1.3 "STKaiti","KaiTi",serif;letter-spacing:.15em;margin:.3rem 0; }
.tx-chapter-context { color:#ced9d5;font:400 1.12rem/1.8 "Source Han Sans SC",sans-serif; }
.tx-bond-button { position:absolute;right:0;top:1rem;pointer-events:auto;background:#11252ad9;border:1px solid #d7b77a80;color:var(--tx-paper);font:500 1.2rem/1.4 inherit;padding:1rem 1.5rem;border-radius:.3rem;cursor:pointer; }
.tx-edition .event-row.tx-event-layout { display:flex;gap:2.1rem;position:absolute;left:7rem;right:7rem;top:22rem;bottom:auto;width:auto;height:32rem;overflow:visible;align-items:stretch;pointer-events:auto; }
.tx-story-cards { display:flex;gap:1.3rem;flex:1;min-width:0;overflow-x:auto;overflow-y:hidden;padding:.4rem .2rem .7rem;scrollbar-width:thin;scrollbar-color:#b69a65 #152a2c; }
.tx-routine-cards { width:25rem;flex-shrink:0;display:flex;flex-direction:column;gap:.7rem;padding-left:1.6rem;border-left:1px solid #d7b77a55;overflow-y:auto; }
.tx-routine-cards::before { content:"这一年的修行";font-size:1rem;letter-spacing:.25em;color:var(--tx-gold);margin:.2rem 0 .4rem; }
.tx-edition .tx-card { position:relative;flex:0 0 21rem;width:21rem;height:30rem;overflow:hidden;background:#112328;border:1px solid #9b875a90;border-radius:.45rem;color:var(--tx-paper);box-shadow:0 .8rem 2rem #0005;transition:transform .18s,border-color .18s; }
.tx-edition .tx-card.is-hover { transform:translateY(-.25rem);border-color:#e6c687; }
.tx-edition .tx-card:focus-visible,.tx-edition button:focus-visible { outline:2px solid #f5d79c;outline-offset:3px; }
.tx-edition .tx-card>.card-shadow,.tx-edition .tx-card>.bg,.tx-edition .tx-card>.type-bg,.tx-edition .tx-card>.border,.tx-edition .tx-card>.name-side,.tx-edition .tx-card .card-need-mask { display:none!important; }
.tx-edition .tx-card .art { left:0;top:0;width:100%;height:19rem;object-fit:cover;object-position:center 28%;mask-image:linear-gradient(#000 75%,transparent); }
.tx-edition .tx-card .type { left:1rem;top:1rem;width:auto;height:auto;padding:.3rem .65rem;background:#0b2029df;border:1px solid #bca47688;border-radius:.2rem;font:500 .9rem/1.4 "Source Han Sans SC",sans-serif;letter-spacing:.18em;text-shadow:none; }
.tx-edition .tx-card .name { top:18rem;left:1.35rem;width:calc(100% - 2.7rem);height:auto;display:block;color:#fff2d4;text-align:left;font:500 1.6rem/1.45 "Source Han Sans SC",sans-serif;text-shadow:none; }
.tx-edition .tx-card .desc { top:21rem;left:1.35rem;width:calc(100% - 2.7rem);height:auto;display:block;color:#ced7d3;text-align:left;font:400 1.08rem/1.85 "Source Han Sans SC",sans-serif;word-break:normal;overflow-wrap:anywhere; }
.tx-edition .tx-card .card-need { top:15.5rem;bottom:auto;left:auto;right:1rem;width:auto;height:auto; }
.tx-edition .tx-card .card-year { font-size:.9rem;color:#ebdfc7; }
.tx-card-foot { position:absolute;bottom:0;left:1.35rem;right:1.35rem;border-top:1px solid #d7b77a35;padding:.9rem 0;display:flex;justify-content:space-between;gap:.5rem;font-size:.9rem;color:#d8bd8e;z-index:5; }
.tx-edition .tx-routine-cards .tx-card { flex:0 0 8.8rem;min-height:8.8rem;width:100%;height:8.8rem;background:#12252aed;box-shadow:none; }
.tx-edition .tx-routine-cards .tx-card .art { width:5.8rem;height:100%;mask-image:linear-gradient(90deg,#000 45%,transparent);opacity:.65;object-position:42% 20%; }
.tx-edition .tx-routine-cards .tx-card .type,.tx-edition .tx-routine-cards .tx-card .card-need,.tx-edition .tx-routine-cards .tx-card .card-rewards { display:none; }
.tx-edition .tx-routine-cards .tx-card .name { top:.8rem;left:5rem;width:calc(100% - 6rem);font-size:1.25rem; }
.tx-edition .tx-routine-cards .tx-card .desc { top:2.8rem;left:5rem;width:calc(100% - 6rem);font-size:.94rem;line-height:1.7; }
.tx-routine-cards .tx-card-foot { font-size:.78rem;left:5rem;padding:.5rem 0; }
.tx-routine-rewards { display:none; }
.tx-empty { display:flex;align-items:center;justify-content:center;width:100%;padding:4rem;text-align:center;white-space:pre-line;color:#dce0d6;font:400 1.5rem/2.1 "STKaiti","KaiTi",serif;border:1px solid #c2a36c3a;background:linear-gradient(120deg,#0c2025c9,#142a3150);border-radius:.4rem; }
.tx-edition #dialogue-box { background:#102129f2;border:1px solid #cbb4779c;border-radius:.5rem;box-shadow:0 1rem 4rem #0009; }
.tx-edition #dialogue-text { color:#f1ecde;font-family:"Source Han Sans SC",sans-serif;font-weight:400;line-height:1.9; }
.tx-edition .choice-button { background:#16313bef;border:1px solid #c4a86e9a;color:#fff1d2;border-radius:.3rem;box-shadow:0 .2rem .7rem #0007; }
.tx-edition .choice-button:hover { background:#294955; }
.tx-edition .choice-art { border-color:#b49a68; }
.tx-bonds { margin:auto;width:min(72rem,92vw);max-height:88dvh;overflow:auto;border:1px solid #c0a26b;border-radius:10px;background:#101f26;color:#ece8dc;padding:2.4rem;font-family:"Microsoft YaHei",sans-serif; }
.tx-bonds::backdrop { background:#020b12c9;backdrop-filter:blur(7px); }
.tx-bonds h2 { font:400 2.4rem/1.5 "STKaiti","KaiTi",serif;margin:.4rem 0; }
.tx-bond-intro { color:#bdcbc9;font-size:1rem;line-height:1.8;max-width:44rem; }
.tx-dialog-close { float:right;padding:.55rem 1rem;color:#e4d5b3;background:#203943;border:1px solid #bba77c;border-radius:4px;cursor:pointer; }
.tx-bond-grid { display:grid;grid-template-columns:repeat(2,1fr);gap:1.4rem;margin-top:1.7rem; }
.tx-bond-person { padding:1.4rem;background:#172d34;border:1px solid #d5b57440;border-radius:6px; }
.tx-bond-person>img { float:left;width:4rem;height:4rem;object-fit:cover;border-radius:50%;margin:0 1rem 1rem 0;border:1px solid #cbb47a; }
.tx-bond-person h3 { font-size:1.25rem;line-height:1.8; }
.tx-bond-kind { color:#d0b780;font-size:.9rem; }
.tx-unmet { filter:brightness(0); }
.tx-memory { clear:both;border-top:1px solid #bda56f33;padding-top:.8rem;margin-top:.8rem; }
.tx-memory b { font-size:1rem;color:#eed9ac; }
.tx-memory p { font-size:.95rem;color:#ccd6d2;line-height:1.8;margin:.4rem 0; }
.tx-memory small { color:#91aaa8;font-size:.78rem; }

/* 镜头中保留能读清的命中节奏；与运算帧同源，倍速/暂停由现有播放器控制。 */
.tx-edition .battle-shell { overflow:hidden;background:#0b1820;border:1px solid #ae986aaa;border-radius:.4rem; }
.tx-edition .battle-shell-frame,.tx-edition .battle-top-mask { display:none; }
.tx-edition .battle-backdrop { object-fit:cover;filter:brightness(.57) saturate(.7); }
.tx-edition .battle-shell::after { content:"";position:absolute;inset:0;z-index:1;pointer-events:none;background:linear-gradient(#0611179c,transparent 30%,transparent 65%,#061117ed);box-shadow:inset 0 0 9rem #020e1488; }
.tx-edition .battle-side.player { left:14rem; }
.tx-edition .battle-side.enemy { left:55rem; }
.tx-edition .battle-side { top:40rem;z-index:4; }
.tx-edition .tx-fullbody .battle-role,.tx-edition .tx-fullbody .battle-role-tint { left:-5rem;top:-32rem;width:31rem;height:35rem;object-fit:contain;object-position:center bottom;transform:none; }
.tx-edition .tx-portrait-fighter .battle-role { mask-image:radial-gradient(ellipse at center,#000 37%,transparent 72%);object-fit:cover;border-radius:50%;opacity:.95; }
.tx-edition .tx-portrait-fighter .battle-role-tint { display:none; }
.tx-edition .battle-hud { z-index:5; }
.tx-edition #battle-log { background:#081820ad;color:#bfcfca;border-left:2px solid #c4a36988;padding:.7rem 1rem;height:6rem;overflow:auto;max-width:40rem;font-size:.85rem;z-index:5; }
.tx-edition #skill-banner { background:linear-gradient(90deg,transparent,#071e2bdc,transparent);border-top:1px solid #dbbf8170;border-bottom:1px solid #dbbf8170;color:#f5e5bc;font:400 2.3rem/1.6 "STKaiti","KaiTi",serif;letter-spacing:.2em;z-index:10; }
.tx-edition #tx-battle-effects { position:absolute;inset:0;pointer-events:none;overflow:hidden;z-index:4;--fx-color:#d5f1ff; }
.tx-edition [data-tx-family="fire"] #tx-battle-effects { --fx-color:#ff944a; }
.tx-edition [data-tx-family="ice"] #tx-battle-effects { --fx-color:#88e5ff; }
.tx-edition [data-tx-family="gate"] #tx-battle-effects { --fx-color:#ff5265; }
.tx-edition [data-tx-family="wind"] #tx-battle-effects { --fx-color:#6ee7d8; }
.tx-edition [data-tx-family="thunder"] #tx-battle-effects { --fx-color:#b4a3ff; }
.tx-edition [data-tx-family="guard"] #tx-battle-effects { --fx-color:#f6d486; }
.tx-fx { display:block;position:absolute;top:55%;color:var(--fx-color); }
.tx-fx.player { left:31%; }.tx-fx.enemy { left:73%; }
.tx-charge { width:12rem;height:12rem;margin:-6rem;border:1px solid currentColor;border-radius:50%;box-shadow:0 0 2rem currentColor,inset 0 0 2rem currentColor;animation:tx-charge calc(var(--battle-sec)*1.3) ease-out both; }
.tx-strike { width:19rem;height:.35rem;margin-left:-9rem;background:#f4ffff;box-shadow:0 0 .7rem .35rem currentColor,0 0 2rem currentColor;animation:tx-strike calc(var(--battle-sec)*1.4) ease-out both; }
.tx-ring { width:11rem;height:11rem;margin:-5.5rem;border:2px solid currentColor;border-radius:50%;box-shadow:0 0 1rem currentColor;animation:tx-ring calc(var(--battle-sec)*1.4) ease-out both; }
.tx-spark { width:.35rem;height:1.4rem;background:currentColor;box-shadow:0 0 .6rem currentColor;animation:tx-spark calc(var(--battle-sec)*1.4) ease-out both; }
.tx-afterimage { width:9rem;height:21rem;margin:-10rem -4rem;border-left:1rem solid currentColor;filter:blur(.6rem);animation:tx-ring calc(var(--battle-sec)*1.3) ease-out both; }
@keyframes tx-charge { from{transform:scale(.45);opacity:0}35%{opacity:.55}to{transform:scale(1.2);opacity:0} }
@keyframes tx-strike { from{transform:rotate(-28deg) scaleX(.05);opacity:1}30%{transform:rotate(-28deg) scaleX(1);opacity:1}to{transform:rotate(-28deg) scaleX(1.3);opacity:0} }
@keyframes tx-ring { from{transform:scale(.2);opacity:.8}to{transform:scale(1.6);opacity:0} }
@keyframes tx-spark { from{transform:rotate(var(--angle)) translateY(0);opacity:1}to{transform:rotate(var(--angle)) translateY(var(--distance));opacity:0} }
.tx-edition .battle-side.player.attack-lunge { animation:tx-lunge-right calc(var(--battle-sec)*.8) ease-out both; }
.tx-edition .battle-side.enemy.attack-lunge { animation:tx-lunge-left calc(var(--battle-sec)*.8) ease-out both; }
@keyframes tx-lunge-right { 0%{transform:translateX(-1rem) rotate(-3deg)}35%{transform:translateX(8rem) rotate(3deg)}100%{transform:none} }
@keyframes tx-lunge-left { 0%{transform:translateX(1rem) rotate(3deg)}35%{transform:translateX(-8rem) rotate(-3deg)}100%{transform:none} }
.tx-edition .playback-paused .tx-fx { animation-play-state:paused; }

/* 竖屏手机不用把 1920 像素画布缩成一张邮票。 */
@media(max-width:960px) {
 html.tx-mobile,html.tx-mobile body { overflow:auto;background:#0a171e;font-size:16px!important; }
 .tx-mobile #game-container { width:100%!important;height:100dvh!important;min-height:640px;overflow-x:hidden;overflow-y:auto;margin:0; }
 .tx-mobile .screen.active { position:absolute;inset:0;min-height:100%;height:auto; }
 .tx-mobile #game-screen { overflow:auto; }
 .tx-mobile #scene-image { position:fixed;height:100dvh;width:100%;object-fit:cover; }
 .tx-mobile #game-screen #hud-top { width:100%;height:6.5rem;position:relative;inset:0;background:#091923e8; }
 .tx-mobile .hud-mid,.tx-mobile .hud-craft,.tx-mobile .hud-right .life-box,.tx-mobile .hud-right .currency,.tx-mobile #year-badge { display:none; }
 .tx-mobile .hud-id, .tx-mobile .hud-bars { left:.5rem;top:.5rem;transform:scale(.66);transform-origin:top left; }
 .tx-mobile .hud-right { left:auto;right:.5rem;top:.5rem;width:3rem; }
 .tx-mobile #btn-settings-ingame { position:relative;inset:0;width:2.8rem;height:2.8rem; }
 .tx-mobile .tx-chapter-header { position:relative;inset:auto;padding:1.4rem 1rem .8rem; }
 .tx-mobile .tx-eyebrow { font-size:.65rem; }
 .tx-mobile .tx-chapter-title { font-size:2rem; }
 .tx-mobile .tx-chapter-context { font-size:.85rem;max-width:75%; }
 .tx-mobile .tx-bond-button { right:1rem;top:1.9rem;font-size:.8rem;padding:.65rem; }
 .tx-mobile #events-panel { position:relative;inset:auto;min-height:26rem;padding-bottom:8rem; }
 .tx-mobile .event-row.tx-event-layout { position:relative;inset:auto;width:auto;height:auto;margin:0 1rem;display:flex;flex-direction:column;gap:1rem; }
 .tx-mobile .tx-story-cards { flex:none;gap:.8rem;overflow-x:auto;scroll-snap-type:x mandatory; }
 .tx-mobile .tx-story-cards .tx-card { flex:0 0 78vw;width:78vw;height:26rem;scroll-snap-align:start; }
 .tx-mobile .tx-card .art { height:15rem; }.tx-mobile .tx-card .name { top:14.5rem;font-size:1.3rem; }
 .tx-mobile .tx-card .desc { top:17rem;font-size:.95rem; }.tx-mobile .tx-card .card-need { top:12rem; }
 .tx-mobile .tx-routine-cards { width:100%;padding:1rem 0 0;border-left:0;border-top:1px solid #b79d6d55;overflow:visible; }
 .tx-mobile .tx-empty { font-size:1rem;padding:2rem 1rem;min-height:10rem; }
 .tx-mobile #dialogue-mask { position:fixed;inset:0;z-index:60; }
 .tx-mobile #dialogue-box { position:fixed;left:4%;top:18%;width:92%;height:auto;min-height:16rem;max-height:45dvh;z-index:65;padding:1.2rem;overflow:auto; }
 .tx-mobile #dialogue-box>img,.tx-mobile #dialogue-player-wrap,.tx-mobile #dialogue-head-wrap { display:none; }
 .tx-mobile #dialogue-box .dialogue-scroll,.tx-mobile #dialogue-box .dialogue-content { position:static;inset:auto;width:auto;height:auto; }
 .tx-mobile #dialogue-text { position:relative;inset:auto;width:auto;height:auto;font-size:1rem;padding:1rem; }
 .tx-mobile #choices-list { position:fixed;left:4%;right:4%;top:auto;bottom:9%;height:auto;width:92%;display:flex;flex-wrap:wrap;justify-content:center;gap:.5rem;z-index:66; }
 .tx-mobile .choice-button { position:relative!important;left:auto!important;bottom:auto!important;top:auto!important;min-height:48px;width:auto!important;max-width:46%;height:auto!important;padding:.6rem .9rem;font-size:.9rem; }
 .tx-mobile .choice-art { display:none; }
 .tx-mobile #action-bar { position:fixed;left:0;bottom:0;width:100%;height:4.7rem;background:#0b1c25f2;z-index:30; }
 .tx-mobile .dock-block { display:none; }.tx-mobile .dock-btn { position:absolute!important;top:.2rem!important;width:4.2rem!important;height:4.2rem!important; }
 .tx-mobile #btn-skills { left:1rem!important; }.tx-mobile #btn-inventory { right:1rem!important;left:auto!important; }
 .tx-mobile #btn-year-advance { position:fixed;bottom:1rem;left:calc(50% - 4rem);width:8rem;min-height:44px;z-index:35;font-size:.9rem; }
 .tx-mobile #battle-screen { background:#06131c;overflow:hidden;min-height:100dvh; }
 .tx-mobile .battle-full-mask { display:none; }
 .tx-mobile .battle-shell { position:absolute;left:0;top:0;transform:none;width:100%;height:100dvh;border:0; }
 .tx-mobile .battle-backdrop { width:100%;height:100%; }
 .tx-mobile .battle-stage { width:100%;height:100%; }.tx-mobile .battle-side { top:66%;width:35%;height:2rem; }
 .tx-mobile .battle-side.player { left:6%; }.tx-mobile .battle-side.enemy { left:61%; }
 .tx-mobile .tx-fullbody .battle-role,.tx-mobile .tx-fullbody .battle-role-tint { left:-2.3rem;top:-15rem;width:13rem;height:17rem; }
 .tx-mobile .tx-portrait-fighter .battle-role { width:12rem;height:15rem;top:-13rem;left:-2rem; }
 .tx-mobile .battle-shade { width:100%;height:2rem; }
 .tx-mobile .battle-hud { position:relative;inset:auto;width:100%;height:9rem;display:flex;gap:1rem;padding:1rem; }
 .tx-mobile .battle-hud .fighter { position:relative;inset:auto;width:50%;height:auto;display:block; }
 .tx-mobile .battle-portrait,.tx-mobile .battle-buffs { display:none; }
 .tx-mobile .fighter-meta { position:relative;inset:auto;width:100%; }.tx-mobile .fighter-name { font-size:1rem; }
 .tx-mobile .battle-stat-bar { width:100%;height:1.2rem;margin-top:.4rem; }.tx-mobile .battle-stat-bar b { font-size:.7rem; }
 .tx-mobile #skill-banner,.tx-mobile #skill-banner.enemy { left:50%!important;top:22%;width:100%;font-size:1.5rem; }
 .tx-mobile #battle-log { left:1rem;top:auto;bottom:7rem;width:calc(100% - 2rem);height:5rem;font-size:.72rem; }
 .tx-mobile #battle-action-bar,.tx-mobile #battle-weapon-slots { display:none; }
 .tx-mobile .battle-control { top:auto!important;bottom:1.5rem!important;width:3.5rem!important;height:3.5rem!important;transform:none!important; }
 .tx-mobile #btn-battle-pause { left:1rem!important;right:auto!important; }.tx-mobile #btn-battle-speed { left:5.5rem!important;right:auto!important; }.tx-mobile #btn-battle-skip { left:auto!important;right:1rem!important;font-size:.85rem; }
 .tx-mobile .tx-fx.player { left:25%; }.tx-mobile .tx-fx.enemy { left:75%; }
 .tx-bonds { font-size:16px;padding:1.2rem; }.tx-bond-grid { grid-template-columns:1fr; }.tx-bonds h2 { font-size:1.7rem; }
}
@media(prefers-reduced-motion:reduce) {
 .tx-edition .tx-card,.tx-edition .battle-side { animation:none!important;transition:none!important; }
 .tx-edition .tx-fx { display:none!important; }
}

.tx-edition #events-panel { inset:0; height:auto; z-index:2; }
.tx-edition #year-badge { top:9.8rem;left:7rem;width:9rem;height:2rem;font-size:1.1rem; }
.tx-edition #mod-destiny { left:17rem;top:10rem;font-size:.9rem; }
.tx-edition #hud-top { z-index:4; }
.tx-edition #battle-log { left:2rem;right:auto;top:auto;bottom:3.5rem;width:42rem;height:5rem; }
.tx-edition #battle-action-bar { display:none; }
.tx-edition .fighter-name { display:block;visibility:visible;color:#ecdfbf;font-size:1.3rem; }
.tx-edition .tx-card .desc { font-size:1.25rem;line-height:1.7; }
.tx-edition .tx-routine-cards .tx-card .desc { font-size:1.12rem;line-height:1.65; }
.tx-edition .tx-routine-cards .tx-card { flex-basis:9.4rem;min-height:9.4rem; }
.tx-edition .tx-card-foot { font-size:1rem; }
.tx-edition .tx-no-story .tx-story-cards { display:none; }
.tx-edition .tx-no-story .tx-routine-cards { width:100%;padding:0;border:0;flex-direction:row;gap:1.5rem;overflow:auto; }
.tx-edition .tx-no-story .tx-routine-cards::before { display:none; }
.tx-edition .tx-no-story .tx-routine-cards .tx-card { flex:1 0 21rem;height:30rem;min-height:30rem; }
.tx-edition .tx-no-story .tx-routine-cards .tx-card .art { width:100%;height:19rem;opacity:1;mask-image:linear-gradient(#000 75%,transparent);object-position:center 28%; }
.tx-edition .tx-no-story .tx-routine-cards .tx-card .name { left:1.35rem;top:18rem;width:calc(100% - 2.7rem);font-size:1.6rem; }
.tx-edition .tx-no-story .tx-routine-cards .tx-card .desc { left:1.35rem;top:21rem;width:calc(100% - 2.7rem);font-size:1.25rem; }
.tx-edition .tx-no-story .tx-card-foot { left:1.35rem;padding:.9rem 0;font-size:1rem; }
.tx-edition #game-container:has(#dialogue-box:not(.hidden)) #mod-paper-overlay { visibility:hidden;pointer-events:none; }
.tx-edition #title-screen #game-title { display:none; }
.tx-edition #btn-mod,.tx-edition #btn-savepath,.tx-edition #btn-qq,.tx-edition .chrome-ver { display:none; }
.tx-title { position:absolute;left:12rem;top:18rem;z-index:2;text-shadow:0 .3rem 2rem #000; }
.tx-title h1 { color:#f7ebcf;font:400 7rem/1.45 "STKaiti","KaiTi",serif;letter-spacing:.2em; }
.tx-title>p:last-child { color:#eadfc5;font-size:1.4rem;letter-spacing:.2em; }
.tx-edition #title-screen>.full-bg { content:url("../assets/v2/scene/scene_103.png");filter:brightness(.48); }
.tx-edition .title-menu .ink-btn { background:#132831d9;border:1px solid #bda37288;color:#f4e6c6;box-shadow:0 .5rem 2rem #0006;border-radius:.25rem; }
.tx-edition .title-menu .ink-btn:not(:disabled):hover { transform:translateX(-.3rem);background:#294550; }
.tx-edition .birth-panel { background:#10232cf2;border:1px solid #b69b6c99;border-radius:.5rem; }
.tx-edition .birth-name-col label { color:#e4d5b5; }.tx-edition .lg-label { white-space:nowrap; }
.tx-edition #dialogue-box { height:26rem;top:47%; }
.tx-edition #dialogue-text { top:6rem;height:15rem;left:11rem;width:46rem; }
.tx-edition #dialogue-head-wrap { top:2rem; }.tx-edition #dialogue-player-wrap { display:none; }
.tx-edition #dialogue-location { top:4rem; }
.tx-edition #dialogue-continue { bottom:1rem; }
@media(max-width:960px) {
 .tx-mobile .tx-title { left:1.7rem;top:14%; }.tx-mobile .tx-title h1 { font-size:3.7rem; }.tx-mobile .tx-title>p:last-child { font-size:.95rem; }
 .tx-mobile .chrome-fate { left:1rem;top:1rem;transform:scale(.65);transform-origin:top left; }
 .tx-mobile .chrome-settings { left:auto;right:1rem;top:1rem;width:3rem;height:3rem; }
 .tx-mobile .title-menu { left:1.5rem;right:1.5rem;top:43%;width:auto;height:auto;display:grid;grid-template-columns:1fr 1fr;gap:.8rem; }
 .tx-mobile .title-menu .ink-btn { position:static;inset:auto;width:auto;min-height:50px;height:auto;padding:.8rem;font:500 1rem/1.4 "Microsoft YaHei",sans-serif; }
 .tx-mobile .title-menu .ink-btn:first-child { grid-column:span 2;min-height:58px;background:#36535e; }
 .tx-mobile .chrome-extra { left:1rem;right:1rem;bottom:1.4rem;top:auto;width:auto;display:flex;flex-wrap:wrap;gap:.5rem; }
 .tx-mobile .chrome-extra button { position:static;width:auto;height:auto;min-height:44px;font-size:.8rem;padding:.4rem .7rem;background:#12262ad9;border:1px solid #b49f7755; }
 .tx-mobile .chrome-ver { display:none; }
 .tx-mobile .birth-panel { position:relative;left:auto;top:auto;width:calc(100% - 2rem);height:auto;min-height:640px;margin:5rem 1rem 1rem;padding:1rem;display:flex;flex-direction:column;gap:1rem; }
 .tx-mobile .birth-panel>* { position:relative;inset:auto;width:auto;height:auto; }
 .tx-mobile .birth-title { font-size:1.8rem;line-height:1.4;background:none;padding:0; }
 .tx-mobile .birth-close { position:absolute;top:.7rem;right:.7rem;left:auto;width:2rem;height:2rem; }
 .tx-mobile .birth-slots { display:flex;flex-direction:column;gap:.6rem;margin-top:1rem; }
 .tx-mobile .birth-book { position:relative;inset:auto!important;width:100%;height:3.4rem;background-size:100% 100%; }
 .tx-mobile .birth-book .book-name { font-size:1rem; }.tx-mobile .birth-book .book-lock { width:2.7rem;height:2.7rem;right:.1rem;top:.2rem; }
 .tx-mobile .birth-tip { opacity:1;font-size:.8rem;text-align:left;min-height:2rem; }
 .tx-mobile .linggen-total { display:flex;gap:.5rem;align-items:center; }.tx-mobile .linggen-total>* { position:static;inset:auto;width:auto;font-size:.9rem; }.tx-mobile .linggen-lock { width:2rem;height:2rem; }
 .tx-mobile .radar-wrap { align-self:center;width:20.625rem;height:19.5rem;transform:scale(.68);transform-origin:top center;margin-bottom:-6rem; }
 .tx-mobile .birth-name-col { display:flex;align-items:center;gap:1rem; }.tx-mobile .birth-name-col>* { position:static;inset:auto; }.tx-mobile .birth-name-col label { font-size:1rem;width:3rem;height:3rem; }.tx-mobile .birth-name-col input { width:calc(100% - 4rem);height:3rem;font-size:1rem; }
 .tx-mobile .redraw-cost { display:none; }.tx-mobile .birth-btn { position:static;width:100%;height:3rem;min-height:3rem;font-size:1.2rem;background:#294954;border:1px solid #bca271; }
 .tx-mobile #dialogue-box { height:auto;top:18%; }.tx-mobile #dialogue-text { top:auto;left:auto;width:auto;height:auto;min-height:8rem; }
 .tx-mobile #dialogue-location { display:none; }.tx-mobile #dialogue-continue { position:relative;inset:auto;width:auto;height:auto;text-align:right;font-size:.8rem; }
 .tx-mobile #choices-panel { position:fixed;inset:0;width:100%;height:100%;pointer-events:none;z-index:103; }
 .tx-mobile #choices-list { pointer-events:none; }.tx-mobile .choice-button { pointer-events:auto; }
 .tx-mobile .choice-row.many .choice-button-text,.tx-mobile .choice-button-text { font-size:.9rem;line-height:1.45; }
 .tx-mobile .hud-id,.tx-mobile .hud-bars { transform:scale(.66);transform-origin:top left; }.tx-mobile .hud-bars { left:1rem; }
 .tx-mobile #action-bar { height:4.7rem;background:#0b1c25f2;border-top:1px solid #bca47266; }
 .tx-mobile #action-bar { left:0;right:0;bottom:0;width:100%;transform:none; }
 .tx-mobile #btn-skills,.tx-mobile #btn-inventory { background:#203943;border:1px solid #b9a17480;border-radius:.3rem;width:4.3rem!important;height:3rem!important;top:.7rem!important;color:#f0dfbe; }
 .tx-mobile #btn-skills::after { content:"玄技";font-size:1rem; }.tx-mobile #btn-inventory::after { content:"行囊";font-size:1rem; }
 .tx-mobile #battle-log { top:auto;bottom:6rem;left:1rem;right:1rem;width:auto;max-width:none;height:5rem;font-size:.8rem; }
 .tx-mobile .tx-fullbody .battle-role,.tx-mobile .tx-fullbody .battle-role-tint { left:-1rem;width:11.5rem; }
 .tx-mobile .tx-card .desc { font-size:.95rem; }.tx-mobile .tx-routine-cards .tx-card .desc { font-size:.94rem; }
 .tx-mobile .tx-card .card-year { font-size:.78rem; }.tx-mobile .tx-card-foot { font-size:.8rem; }
 .tx-mobile .tx-no-story .tx-routine-cards { flex-direction:column;gap:.75rem; }
 .tx-mobile .tx-no-story .tx-routine-cards .tx-card { flex:0 0 10rem;height:10rem;min-height:10rem;width:100%; }
 .tx-mobile .tx-no-story .tx-routine-cards .tx-card .art { width:6rem;height:100%;mask-image:linear-gradient(90deg,#000 45%,transparent); }
 .tx-mobile .tx-no-story .tx-routine-cards .tx-card .name { top:1rem;left:5rem;font-size:1.25rem;width:calc(100% - 6rem); }
 .tx-mobile .tx-no-story .tx-routine-cards .tx-card .desc { top:3rem;left:5rem;font-size:.94rem;width:calc(100% - 6rem); }
 .tx-mobile .tx-no-story .tx-card-foot { left:5rem;font-size:.8rem;padding:.7rem 0; }
}
@media(max-width:960px){.tx-mobile #events-panel{position:relative;inset:auto;height:auto;}.tx-mobile #scene-layer{position:fixed;inset:0;}.tx-mobile #hud-top{position:relative;}.tx-mobile #mod-destiny{display:none;}.tx-mobile #dialogue-box{transform:none;}.tx-mobile #action-bar{position:fixed;}.tx-mobile .hud-bars .bar-row{left:0;}.tx-mobile #tx-battle-effects{top:0;height:100%;}}

@media(max-width:960px){.tx-mobile .battle-side.enemy{left:53%;}.tx-mobile #btn-settings-ingame{position:absolute;left:auto;right:.6rem;top:.4rem;}.tx-mobile .hud-right{position:absolute;inset:0;}.tx-mobile #btn-help{display:none;}}

/* 浏览器触屏版：所有关键操作有可见按钮、44px 以上热区，并避开系统手势区。 */
@media(max-width:960px) {
 html.tx-mobile,html.tx-mobile body { min-width:0;min-height:100%;overscroll-behavior:none; }
 .tx-mobile *, .tx-mobile *::before, .tx-mobile *::after { box-sizing:border-box; }
 .tx-mobile button,.tx-mobile select,.tx-mobile input,.tx-mobile [tabindex] { touch-action:manipulation;-webkit-tap-highlight-color:rgba(215,183,122,.18); }
 .tx-mobile button:active,.tx-mobile [role="button"]:active { filter:brightness(1.16); }
 .tx-mobile #game-container { min-height:100dvh;max-width:none; }
 .tx-mobile #title-screen,.tx-mobile #character-creation { min-height:100dvh;overflow-x:hidden;overflow-y:auto; }
 .tx-mobile #title-screen>.full-bg,.tx-mobile #character-creation>.full-bg { position:fixed;inset:0;width:100%;height:100dvh;object-fit:cover; }

 /* 标题页的次级入口允许换行，给“存档搬家”等后续按钮留真实流式空间。 */
 .tx-mobile #title-screen .chrome-extra { position:absolute;left:1rem;right:1rem;top:auto;bottom:calc(1rem + env(safe-area-inset-bottom));width:auto;height:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.5rem;max-height:none;z-index:7; }
 .tx-mobile #title-screen .chrome-extra .mini-ink { position:static!important;width:100%;min-width:0;min-height:44px;height:auto;white-space:normal;font:500 .8rem/1.3 "Source Han Sans SC","Microsoft YaHei",sans-serif;background:#12262ad9;border:1px solid #b49f7755; }
 .tx-mobile #title-screen .chrome-extra .tx-transfer-entry { grid-column:1 / -1; }
 .tx-mobile .chrome-settings { min-width:48px;min-height:48px; }
 .tx-mobile #title-screen>.chrome-settings { left:auto!important;right:1rem;top:1rem;width:48px;height:48px;z-index:8; }

 /* 创建页：书、锁扣、姓名和两颗主按钮都可单手点中。 */
 .tx-mobile .birth-panel { min-height:0;margin-top:max(4rem,env(safe-area-inset-top));margin-bottom:calc(1rem + env(safe-area-inset-bottom));padding:1rem;box-shadow:0 1rem 3rem #00101880;flex-direction:row;flex-wrap:wrap;gap:.65rem; }
 .tx-mobile .birth-panel>* { flex:0 0 100%; }
 .tx-mobile .birth-close { width:48px;height:48px;top:.35rem;right:.35rem; }
 .tx-mobile .birth-slots { margin-top:.75rem; }
 .tx-mobile .birth-book { min-height:60px;height:60px;cursor:pointer; }
 .tx-mobile .birth-book .book-lock { width:48px;height:48px;right:.2rem;top:.35rem; }
 .tx-mobile .birth-tip { min-height:3rem;margin:0;color:#d9e2dd;font-size:.875rem;line-height:1.55; }
 .tx-mobile .linggen-lock { min-width:44px;min-height:44px; }
 .tx-mobile .birth-name-col input { min-height:48px;border:1px solid #aa956c;background:#f9f6ef;color:#152329; }
 .tx-mobile .radar-wrap { margin-bottom:-4rem; }
 .tx-mobile .birth-btn { flex:1 1 calc(50% - .35rem);width:auto;min-height:52px;height:auto; }

 /* 顶栏保持可读；齿轮在对白期间也能被触达。 */
 .tx-mobile #game-screen #hud-top { z-index:105;pointer-events:none;padding-top:env(safe-area-inset-top); }
 .tx-mobile #game-screen #hud-top>* { pointer-events:auto; }
 .tx-mobile #game-screen #hud-top>.hud-right { left:0;right:0;top:0;width:100%!important;height:100%;pointer-events:none; }
 .tx-mobile #game-screen #hud-top>.hud-right #btn-settings-ingame { pointer-events:auto; }
 .tx-mobile #btn-settings-ingame { position:absolute!important;left:auto!important;right:.65rem!important;top:calc(.45rem + env(safe-area-inset-top))!important;width:48px!important;height:48px!important;z-index:2; }
 .tx-mobile .tx-chapter-header { padding-left:1rem;padding-right:1rem; }
 .tx-mobile .tx-chapter-context { max-width:calc(100% - 7.5rem);font-size:.9rem;line-height:1.6; }
 .tx-mobile .tx-bond-button { min-width:7rem;min-height:48px;padding:.55rem .7rem; }
 .tx-mobile #events-panel { padding-bottom:calc(7.5rem + env(safe-area-inset-bottom)); }
 .tx-mobile .tx-story-cards { overscroll-behavior-inline:contain;padding-bottom:.85rem; }
 .tx-mobile .tx-story-cards .tx-card { flex-basis:min(82vw,22rem);width:min(82vw,22rem); }
 .tx-mobile .tx-card { touch-action:pan-y; }
 .tx-mobile .tx-card:active { border-color:#f0d394;box-shadow:0 .35rem 1.2rem #0008; }
 .tx-mobile #action-bar { height:calc(4.75rem + env(safe-area-inset-bottom));padding-bottom:env(safe-area-inset-bottom); }
 .tx-mobile #btn-skills,.tx-mobile #btn-inventory { min-width:72px!important;min-height:48px!important; }
 .tx-mobile #btn-year-advance { bottom:calc(1rem + env(safe-area-inset-bottom));min-height:48px; }
 .tx-mobile #mod-paper-overlay { position:fixed;left:50%;right:auto;top:auto;bottom:calc(5.4rem + env(safe-area-inset-bottom));width:calc(100% - 2rem);max-width:34rem;transform:translateX(-50%);z-index:55; }
 .tx-mobile .mod-paper { display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.75rem;padding:.75rem;background:#f1e2c3f7;border-color:#9c7740;border-radius:6px; }
 .tx-mobile #mod-paper-sections { max-height:7.25rem; }
 .tx-mobile #btn-mod-paper-ok { min-width:72px;min-height:48px;padding:.45rem .65rem; }

 /* 对白与选项使用同一列流式布局；六选一在竖屏两列、横屏三列。 */
 .tx-mobile #dialogue-box { left:1rem;right:1rem;top:max(7.5rem,calc(env(safe-area-inset-top) + 6.5rem));width:auto;min-height:0;max-height:42dvh;padding:1rem;overflow:auto; }
 .tx-mobile #dialogue-text { min-height:0;padding:.65rem .75rem;font-size:1rem;line-height:1.75; }
 .tx-mobile #dialogue-continue { min-height:24px;color:#d8bd8e; }
 .tx-mobile #choices-list { left:1rem;right:1rem;bottom:calc(5.5rem + env(safe-area-inset-bottom));width:auto;display:flex;align-items:stretch;justify-content:center;gap:8px; }
 .tx-mobile #choices-list .choice-item { flex:1 1 calc(50% - 4px);min-width:calc(50% - 4px);max-width:calc(50% - 4px);height:auto;min-height:56px;display:flex;flex-direction:column; }
 .tx-mobile #choices-list .choice-item:only-child { flex-basis:100%;min-width:100%;max-width:100%; }
 .tx-mobile .choice-needs { position:relative;inset:auto;width:100%;height:auto;min-height:0;transform:none;margin:0 0 4px; }
 .tx-mobile .choice-needs:empty { display:none; }
 .tx-mobile .choice-condition,.tx-mobile .choice-warning { width:100%;min-height:28px;height:auto;font-size:.75rem;line-height:1.25; }
 .tx-mobile .choice-button { position:relative!important;inset:auto!important;width:100%!important;max-width:none!important;height:auto!important;min-height:56px;padding:.55rem .65rem;transform:none!important;flex:1 1 auto;box-shadow:0 .25rem .8rem #0009; }
 .tx-mobile .choice-button-text,.tx-mobile .choice-row.many .choice-button-text { min-height:40px;font-size:.95rem;line-height:1.35;word-break:normal;overflow-wrap:anywhere; }
 .tx-mobile .choice-item:has(.choice-art) .choice-button-text { padding-left:48px; }
 .tx-mobile .choice-art { display:block;left:6px;top:auto;bottom:6px;width:44px;height:44px;transform:none;border-width:1px;border-radius:4px;object-position:center 20%;z-index:3; }
 .tx-mobile .choice-death-tag { right:.25rem;top:.2rem;font-size:.7rem; }
 .tx-mobile .choice-realm { left:.2rem;top:.2rem;width:2.6rem;height:1.3rem; }

 /* 通用遮罩和信息卡：固定到实际视口，避免被 1920 舞台坐标或底栏裁掉。 */
 .tx-mobile #settings-overlay,.tx-mobile .game-panel-veil,.tx-mobile #modal-overlay,.tx-mobile #three-select-overlay,.tx-mobile #craft-overlay,.tx-mobile #save-overlay,.tx-mobile #favor-overlay { position:fixed;inset:0; }
 .tx-mobile #settings-overlay { z-index:230;overflow-y:auto;padding:max(12px,env(safe-area-inset-top)) 12px max(16px,env(safe-area-inset-bottom));background:rgba(2,11,18,.82);backdrop-filter:blur(6px); }
 .tx-mobile .set-bg { position:relative;left:auto;top:auto;width:min(100%,42rem);height:auto;min-height:0;margin:0 auto;padding:1.25rem 1rem 1.5rem;background:linear-gradient(155deg,#132b34f7,#0d2028f7);border:1px solid #bda36f;border-radius:10px;box-shadow:0 1.2rem 3rem #000b;color:var(--tx-paper);display:flex;flex-direction:column;gap:.65rem;overflow:visible; }
 .tx-mobile .set-bg>* { position:static; }
 .tx-mobile .set-title { width:auto;height:auto;background:none;opacity:1;padding-right:3.5rem; }
 .tx-mobile .set-title span { position:static;width:auto;height:auto;display:block;text-align:left;color:#f6e6bf;font:400 2rem/1.25 "STKaiti","KaiTi",serif; }
 .tx-mobile .set-close { position:absolute;left:auto;right:.4rem;top:.35rem;width:48px;height:48px; }
 .tx-mobile .set-head { width:auto;height:auto;background:none;border-left:3px solid var(--tx-gold);padding:.1rem 0 .1rem .7rem;margin-top:.35rem; }
 .tx-mobile .set-head span { position:static;display:block;transform:none;color:#ead5a8;font:600 1.05rem/1.5 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .set-line { width:100%;height:1px;background:#d7b77a44; }
 .tx-mobile .set-row { position:static;width:100%;height:auto;min-height:52px;display:grid;grid-template-columns:4.5rem minmax(0,1fr) 3.8rem;align-items:center;gap:.5rem; }
 .tx-mobile .set-row>* { position:static; }
 .tx-mobile .set-name { width:auto;height:auto;background:none; }
 .tx-mobile .set-name span { position:static;width:auto;height:auto;display:block;color:#e4e9e6;font:500 1rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .set-slider { width:auto;height:44px;display:flex;align-items:center; }
 .tx-mobile .set-slider>i { display:none; }
 .tx-mobile .set-slider input[type="range"] { position:static;width:100%;height:44px;margin:0;opacity:1;appearance:auto;accent-color:#c6a562;cursor:pointer; }
 .tx-mobile .set-value { width:auto;height:auto;color:#d9c79f;font:500 .85rem/1.3 "Source Han Sans SC","Microsoft YaHei",sans-serif;font-variant-numeric:tabular-nums; }
 .tx-mobile .set-row-res { grid-template-columns:4.5rem minmax(0,1fr) minmax(0,1fr); }
 .tx-mobile .set-row-full { grid-template-columns:4.5rem minmax(0,1fr); }
 .tx-mobile .set-dd { width:auto;height:44px;background:#0b1c24;border:1px solid #91794e;border-radius:4px; }
 .tx-mobile .set-dd select { position:static;width:100%;height:44px;padding:0 .4rem;color:#f0eadc;background:transparent;font:500 1rem/1.3 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .set-dd .dd-arrow { display:none; }
 .tx-mobile .set-togs { position:static;left:auto;top:auto;width:100%;height:auto;display:grid;grid-template-columns:1fr;gap:8px; }
 .tx-mobile .set-tog,.tx-mobile .set-tog.set-tog-p { position:relative;left:auto;top:auto!important;width:100%;height:auto;min-height:48px;display:flex;align-items:center;gap:.65rem;padding:.4rem .5rem;border:1px solid #d7b77a30;border-radius:5px;background:#0c1c2399; }
 .tx-mobile .set-tog>i { position:relative;left:auto;top:auto;flex:0 0 32px;width:32px;height:32px; }
 .tx-mobile .set-tog>span,.tx-mobile .set-tog.set-tog-p>span { position:static;width:auto;height:auto;display:block;color:#e2e8e4;font:400 .95rem/1.45 "Source Han Sans SC","Microsoft YaHei",sans-serif;white-space:normal; }
 .tx-mobile .set-npc { position:static;left:auto;top:auto;display:grid;grid-template-columns:4.5rem minmax(0,1fr) auto;gap:.5rem;white-space:normal;min-height:48px;align-items:center; }
 .tx-mobile .set-npc>span { color:#e2e8e4;font:500 .95rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .set-npc select,.tx-mobile .set-npc button { min-height:44px;font-size:.9rem; }
 .tx-mobile .set-npc-hint { position:static;left:auto;top:auto;color:#aabdb9;font-size:.8rem;line-height:1.45;white-space:normal; }
 .tx-mobile .set-buttons { position:static;left:auto;top:auto;width:100%;height:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:.4rem; }
 .tx-mobile .set-btn { position:static;width:100%;height:auto;min-height:48px;font:500 1rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif;background:#243f47;border:1px solid #9b8154;border-radius:4px; }
 .tx-mobile .set-bg>button:not(.set-close) { position:static;min-height:48px;margin-top:.25rem; }

 .tx-mobile .game-panel-veil { z-index:220;padding:max(12px,env(safe-area-inset-top)) 12px max(12px,env(safe-area-inset-bottom));overflow:hidden;background:rgba(2,11,18,.82);backdrop-filter:blur(5px);align-items:center; }
 .tx-mobile .game-panel { width:min(100%,45rem)!important;height:min(100%,52rem);max-height:100%;padding:1rem;background:linear-gradient(155deg,#f1ead9,#d8c8a6);border:1px solid #c5a568;border-radius:10px;box-shadow:0 1.2rem 3rem #000c;overflow:hidden; }
 .tx-mobile .panel-head { flex:0 0 auto;min-height:48px;margin:0 0 .35rem; }
 .tx-mobile .panel-title { min-height:44px;height:auto;line-height:44px;font-size:1.15rem; }
 .tx-mobile .panel-close { min-width:48px;width:48px;min-height:48px;height:48px; }
 .tx-mobile #bag-overlay .game-panel { position:relative;display:grid;grid-template-rows:auto minmax(0,1fr);gap:.6rem;padding:1rem;overflow:hidden; }
 .tx-mobile #bag-overlay .game-panel::before { content:"行囊";position:absolute;left:1rem;top:.75rem;color:#26333a;font:600 1.2rem/48px "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile #bag-overlay .panel-tabs { position:static;left:auto;top:auto;width:100%;height:auto;display:flex;gap:4px;margin:48px 0 0;overflow-x:auto; }
 .tx-mobile #bag-overlay .panel-close { left:auto;right:.45rem;top:.45rem;width:48px;height:48px; }
 .tx-mobile #bag-overlay .panel-close::after,.tx-mobile #skill-overlay .panel-close::after { content:"×";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:#f5e8c8;font:500 1.7rem/1 sans-serif;text-shadow:0 1px 3px #000; }
 .tx-mobile #bag-overlay .panel-tab,.tx-mobile #skill-overlay .panel-tab { flex:1 0 60px;min-width:60px;width:auto;height:44px;color:#2b3940;font-size:.95rem; }
 .tx-mobile #bag-overlay .panel-tab.on,.tx-mobile #skill-overlay .panel-tab.on { color:#f7eed9;background-color:#243b43;-webkit-mask:none;mask:none;border-radius:4px; }
 .tx-mobile #bag-overlay #bag-grid { position:static;left:auto;top:auto;width:100%;height:auto;min-height:0;display:grid;grid-template-columns:repeat(auto-fill,64px);grid-auto-rows:64px;gap:8px;justify-content:center;padding:.5rem;overflow-y:auto; }
 .tx-mobile #skill-overlay .game-panel { display:flex;flex-direction:column; }
 .tx-mobile #skill-overlay .panel-tabs { height:auto;min-height:44px;display:flex;gap:4px;margin:.25rem 0;overflow-x:auto;flex:0 0 auto; }
 .tx-mobile #skill-overlay .panel-tab { flex-basis:56px;min-width:56px; }
 .tx-mobile .queue-box { flex:0 0 auto;min-height:0;margin:.15rem 0; }
 .tx-mobile .queue-title { font-size:.88rem;color:#27323b; }
 .tx-mobile #skill-queue { display:grid;grid-auto-flow:column;grid-template-columns:none;grid-template-rows:repeat(2,56px);grid-auto-columns:56px;gap:8px;max-height:128px;margin:.25rem 0;padding:4px;overflow-x:auto;overflow-y:hidden; }
 .tx-mobile #skill-grid { display:grid;grid-template-columns:repeat(auto-fill,56px);grid-auto-rows:56px;gap:8px;justify-content:center;padding:.5rem;min-height:0;overflow-y:auto; }
 .tx-mobile .inv-slot,.tx-mobile .skill-slot,.tx-mobile .queue-slot,.tx-mobile .inv-slot .icon-wrap,.tx-mobile .skill-slot .icon-wrap,.tx-mobile .queue-slot .icon-wrap { width:100%;height:100%;min-width:44px;min-height:44px; }
 .tx-mobile .panel-tip { flex:0 0 auto;min-height:2.4rem;margin:.25rem 0 0;color:#38434a;font-size:.8rem;line-height:1.4; }

 .tx-mobile #modal-overlay { z-index:260;display:flex;align-items:center;justify-content:center;padding:max(16px,env(safe-area-inset-top)) 16px max(16px,env(safe-area-inset-bottom));background:rgba(1,8,13,.78);backdrop-filter:blur(5px); }
 .tx-mobile #modal-overlay.no-mask { background:rgba(1,8,13,.72); }
 .tx-mobile .modal-bk { position:relative;left:auto;top:auto;transform:none;width:min(100%,34rem);height:auto;min-height:17rem;padding:1.25rem;background:linear-gradient(155deg,#142c35,#0d1d25);border:1px solid #c3a46b;border-radius:10px;box-shadow:0 1rem 3rem #000c;display:grid;grid-template-rows:auto minmax(6rem,1fr) auto;gap:1rem; }
 .tx-mobile .modal-bk>* { position:static; }
 .tx-mobile .modal-title { width:auto;height:auto;color:#f5e7c8;font:600 1.4rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .modal-context { width:auto;height:auto;color:#e1e7e4;font:400 1rem/1.7 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .modal-btns { width:auto;height:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px; }
 .tx-mobile .modal-btns .ink-btn { position:static;width:100%;height:auto;min-height:48px;font:500 1rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif;background:#294650;border:1px solid #a88b5b;border-radius:4px; }

 .tx-mobile #craft-overlay,.tx-mobile #save-overlay,.tx-mobile #favor-overlay { z-index:240;overflow-y:auto;padding:max(16px,env(safe-area-inset-top)) 12px max(16px,env(safe-area-inset-bottom));background:rgba(2,11,18,.78); }
 .tx-mobile .veil .ink-panel { width:min(100%,36rem);max-height:none;margin:0 auto;padding:1.25rem;background:linear-gradient(155deg,#eee6d3,#d7c6a2);border:1px solid #b6965f;border-radius:9px; }
 .tx-mobile .veil .ink-panel .ink-btn { min-height:48px; }

 /* 行囊/玄技说明在触屏点按后作为底部信息片展开；确认框与突破层仍压在它上面。 */
 .tx-mobile .item-tip { z-index:225;left:12px!important;right:12px;top:auto!important;bottom:calc(12px + env(safe-area-inset-bottom));width:auto;max-width:24rem;margin:0 auto;filter:drop-shadow(0 .7rem 1.2rem #000a); }
 .tx-mobile #ui-tip { z-index:225;max-width:calc(100vw - 24px); }

 /* 突破/领悟卡在手机改为可滚动卡组；不会把 1920 坐标缩成细字。 */
 .tx-mobile #three-select-overlay { z-index:250;overflow-y:auto;background:#06131de8;padding:max(12px,env(safe-area-inset-top)) 12px calc(76px + env(safe-area-inset-bottom)); }
 .tx-mobile .tso-mask { position:fixed;inset:0;background:linear-gradient(180deg,#041018f2,#0a1d25f2); }
 .tx-mobile .tso-tile { display:none; }
 .tx-mobile .tso-title { position:relative;left:auto;top:auto;width:100%;height:auto;min-height:56px;padding:.6rem;color:#f6e7c4;font-size:1.35rem;line-height:1.35;white-space:normal;background:#102832;border:1px solid #b99b65;border-radius:6px; }
 .tx-mobile .tso-title.is-long { font-size:1.2rem; }
 .tx-mobile .tso-cards { position:relative;left:auto;top:auto;width:100%;height:auto;margin:12px 0;display:flex;flex-direction:column;gap:10px;align-items:stretch; }
 .tx-mobile .tso-card { flex:0 0 158px;width:100%;height:158px;min-height:158px;background:linear-gradient(145deg,#17333c,#0e222a);border:1px solid #a98b58;border-radius:7px;box-shadow:0 .45rem 1.1rem #0008;overflow:hidden; }
 .tx-mobile .tso-card:active { border-color:#efd393; }
 .tx-mobile .tso-name { left:92px;top:10px;width:calc(100% - 152px);height:34px;justify-content:flex-start;font-size:1.05rem;text-align:left; }
 .tx-mobile .tso-lg { left:12px;top:9px;width:40px;height:40px; }
 .tx-mobile .tso-mana { left:auto;right:10px;top:10px;width:52px;height:32px;font-size:.8rem; }
 .tx-mobile .tso-icon { left:12px;top:58px;width:72px;height:72px; }
 .tx-mobile .tso-desc { left:96px;top:52px;width:calc(100% - 108px);height:94px;color:#dfe8e4;font-size:.88rem;line-height:1.5;text-shadow:none; }
 .tx-mobile .tso-abandon { position:fixed;left:50%;top:auto;bottom:calc(12px + env(safe-area-inset-bottom));transform:translateX(-50%);width:min(15rem,calc(100% - 24px));height:52px;font-size:1.1rem;z-index:2; }

 .tx-mobile .tx-bonds { width:calc(100vw - 24px);max-width:42rem;max-height:calc(100dvh - 24px);padding:1rem; }
 .tx-mobile .tx-dialog-close { position:sticky;top:0;z-index:2;float:none;display:block;margin-left:auto;min-width:72px;min-height:48px; }
}

/* 手机横屏：三列选择与左右分栏标题，完整利用 844×390 一类视口。 */
@media(max-width:960px) and (max-height:600px) {
 .tx-mobile #game-container { min-height:100dvh; }
 .tx-mobile .tx-title { left:5%;top:10%;max-width:42%; }
 .tx-mobile .tx-title h1 { font-size:3.15rem; }
 .tx-mobile .title-menu { left:auto;right:4%;top:8%;width:34%;display:grid;grid-template-columns:1fr;gap:6px; }
 .tx-mobile .title-menu .ink-btn,.tx-mobile .title-menu .ink-btn:first-child { grid-column:auto;min-height:44px;padding:.35rem .7rem;font-size:.92rem; }
 .tx-mobile #title-screen>.chrome-settings { left:auto!important;right:40%;top:8px;width:48px;height:48px;z-index:8; }
 .tx-mobile #title-screen .chrome-extra { left:3%;right:auto;bottom:calc(6px + env(safe-area-inset-bottom));width:42%;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px; }
 .tx-mobile #title-screen .chrome-extra .mini-ink { min-height:44px;padding:.2rem .35rem;font-size:.72rem; }
 .tx-mobile #title-screen .chrome-extra .tx-transfer-entry { grid-column:auto; }
 .tx-mobile #character-creation { padding-bottom:64px; }
 .tx-mobile #character-creation::after { content:"";position:fixed;left:0;right:0;bottom:0;height:calc(64px + env(safe-area-inset-bottom));z-index:24;pointer-events:none;background:#081923ed;border-top:1px solid #bca47266; }
 .tx-mobile .birth-panel { width:min(92%,46rem);margin:3.4rem auto .75rem; }
 .tx-mobile .birth-btn.reset,.tx-mobile .birth-btn.start { position:fixed!important;top:auto!important;bottom:calc(6px + env(safe-area-inset-bottom));width:30%;max-width:15rem;min-height:48px;z-index:25; }
 .tx-mobile .birth-btn.reset { left:18%!important;right:auto!important; }
 .tx-mobile .birth-btn.start { left:auto!important;right:18%!important; }
 .tx-mobile #game-screen #hud-top { height:4.8rem; }
 .tx-mobile .hud-id,.tx-mobile .hud-bars { transform:scale(.58); }
 .tx-mobile .tx-chapter-header { padding:.65rem 1rem .45rem; }
 .tx-mobile .tx-chapter-title { font-size:1.65rem; }
 .tx-mobile .event-row.tx-event-layout { flex-direction:row; }
 .tx-mobile .tx-story-cards { min-width:0; }
 .tx-mobile .tx-routine-cards { width:42%;padding:0 0 0 .75rem;border-top:0;border-left:1px solid #b79d6d55;max-height:16rem;overflow-y:auto; }
 .tx-mobile #dialogue-box { top:calc(env(safe-area-inset-top) + 5rem);left:2%;right:2%;max-height:27dvh; }
 .tx-mobile #choices-list { left:2%;right:2%;bottom:calc(4.75rem + env(safe-area-inset-bottom));gap:6px; }
 .tx-mobile #choices-list .choice-item { flex-basis:calc(33.333% - 4px);min-width:calc(33.333% - 4px);max-width:calc(33.333% - 4px); }
 /* 横屏两行选项（4 个＝3+1）按钮若沿用 5.54rem 高，选项块会顶进对白框底边 6px；定高 52px 后两行 110px，与 27dvh 对白框留出空隙。 */
 .tx-mobile .choice-button { min-height:52px;height:52px!important;padding:.3rem .65rem; }
 .tx-mobile .choice-button-text,.tx-mobile .choice-row.many .choice-button-text { min-height:0; }
 .tx-mobile #action-bar { height:4rem; }
 .tx-mobile #btn-skills,.tx-mobile #btn-inventory { top:.45rem!important;height:48px!important; }
 .tx-mobile #btn-year-advance { bottom:calc(.5rem + env(safe-area-inset-bottom)); }
 .tx-mobile .battle-hud { height:5.25rem;padding:.65rem 1rem; }
 .tx-mobile .battle-side { top:72%; }
 .tx-mobile .tx-fullbody .battle-role,.tx-mobile .tx-fullbody .battle-role-tint { top:-12rem;width:12rem;height:14rem; }
 .tx-mobile #battle-log { left:27%;right:27%;bottom:4rem;width:auto;height:3.5rem;padding:.35rem .55rem;font-size:.7rem; }
 .tx-mobile .battle-control { bottom:calc(.65rem + env(safe-area-inset-bottom))!important; }
 .tx-mobile #skill-queue { grid-template-rows:56px;max-height:64px; }
 .tx-mobile .set-togs { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .tx-mobile .set-npc,.tx-mobile .set-npc-hint { grid-column:1 / -1; }
 .tx-mobile #three-select-overlay { padding:8px 10px calc(62px + env(safe-area-inset-bottom)); }
 .tx-mobile .tso-title { min-height:46px;padding:.3rem;font-size:1.1rem; }
 .tx-mobile .tso-cards { flex-direction:row;gap:8px;margin:8px 0; }
 .tx-mobile .tso-card { flex:1 1 0;width:auto;height:242px;min-height:242px; }
 .tx-mobile .tso-name { left:50px;top:8px;width:calc(100% - 98px);font-size:.9rem; }
 .tx-mobile .tso-lg { left:8px;top:7px;width:34px;height:34px; }
 .tx-mobile .tso-mana { right:6px;top:8px;width:42px;height:28px;font-size:.7rem; }
 .tx-mobile .tso-icon { left:50%;top:47px;width:56px;height:56px;transform:translateX(-50%); }
 .tx-mobile .tso-desc { left:10px;top:112px;width:calc(100% - 20px);height:120px;font-size:.78rem;line-height:1.42; }
 .tx-mobile .tso-abandon { bottom:calc(6px + env(safe-area-inset-bottom));height:46px; }
}

@media(hover:none) and (pointer:coarse) {
 .tx-edition .choice-button:hover,.tx-edition .title-menu .ink-btn:not(:disabled):hover { transform:none; }
 .tx-edition .tx-card.is-hover { transform:none; }
}

@media(min-width:961px) {
 .tx-edition #bag-overlay .game-panel,.tx-edition #skill-overlay .game-panel { background-color:#e8dec8;border:1px solid #b79a65;border-radius:.45rem;box-shadow:0 1rem 3rem #0009; }
 .tx-edition #bag-overlay .panel-tab,.tx-edition #skill-overlay .panel-tab { color:#263840; }
 .tx-edition #bag-overlay .panel-tab.on,.tx-edition #skill-overlay .panel-tab.on { color:#f7eed9; }
 .tx-edition #bag-overlay .panel-close,.tx-edition #skill-overlay .panel-close { filter:drop-shadow(0 .2rem .35rem #0009); }
 .tx-edition .tso-desc { left:2.25rem;width:14.9rem;height:15.45rem;font-size:1.05rem;line-height:1.3; }
}

/* 对手详情的手机版本：战斗卡上点“战前详情”，面板内玄技图标再点可读说明。 */
@media(max-width:960px) {
 .tx-mobile .tx-card .card-detail-hint { display:flex!important;align-items:center;justify-content:center;left:auto;right:.65rem;top:.65rem;width:88px;height:44px;padding:0 .45rem;pointer-events:auto;touch-action:manipulation;border:1px solid #c2a66f;border-radius:4px;background:#102a34e8;z-index:12; }
 .tx-mobile .card-detail-hint>img { display:none; }
 .tx-mobile .card-detail-hint>span { position:static;width:auto;height:auto;color:#f5e6c5;font:600 .8rem/1.3 "Source Han Sans SC","Microsoft YaHei",sans-serif; }

 .tx-mobile #enemy-detail-overlay { position:fixed;inset:0;z-index:270;padding:max(12px,env(safe-area-inset-top)) 12px max(12px,env(safe-area-inset-bottom));overflow-y:auto;overflow-x:hidden;background:rgba(2,10,16,.86);backdrop-filter:blur(6px); }
 .tx-mobile #enemy-detail-overlay *:not(.edp-slot) { position:static; }
 .tx-mobile #enemy-detail-overlay .edp-bg { position:relative;left:auto;top:auto;width:min(100%,42rem);height:auto;min-height:0;margin:0 auto;padding:1rem;transform:none;background:linear-gradient(155deg,#142d36,#0b1d25);border:1px solid #bca16c;border-radius:10px;box-shadow:0 1rem 3rem #000b;color:#edf0e8;display:grid;grid-template-columns:1fr;grid-template-areas:"title" "role" "property" "linggen" "skills" "weapons";gap:12px; }
 .tx-mobile .edp-title { grid-area:title;width:auto;height:auto;min-height:48px;padding-right:52px;justify-content:flex-start;color:#f5e5c1;font:500 1.75rem/1.3 "STKaiti","KaiTi",serif; }
 .tx-mobile .edp-exit { position:absolute!important;left:auto;right:.35rem;top:.35rem;width:48px;height:48px;transform:none;z-index:3;background:#203943;border:1px solid #bba77c;border-radius:50%; }
 .tx-mobile .edp-exit::after { content:"×";display:flex;align-items:center;justify-content:center;position:absolute;inset:0;color:#f5e8c8;font:500 1.7rem/1 sans-serif; }
 .tx-mobile .edp-cap { width:auto!important;height:auto!important;min-height:30px;justify-content:flex-start;padding:.15rem .55rem;border-left:3px solid var(--tx-gold);color:#e7d2a5;font:600 .95rem/1.4 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .edp-cap::before { display:none; }

 .tx-mobile .edp-role { grid-area:role;width:auto;height:auto;display:grid;grid-template-columns:72px minmax(0,1fr);grid-template-rows:auto auto auto;gap:6px 10px;padding:.75rem;background:#0b1d2599;border:1px solid #d7b77a35;border-radius:6px; }
 .tx-mobile .edp-avatar { display:none; }
 .tx-mobile .edp-head { grid-column:1;grid-row:1 / 4;width:72px;height:72px;transform:none;padding:6px;align-self:center; }
 .tx-mobile .edp-head-mask { width:60px;height:60px;border-radius:50%; }
 .tx-mobile .edp-head-mask>img { width:100%;height:100%;transform:none;object-fit:cover; }
 .tx-mobile .edp-rolename { grid-column:2;grid-row:1;width:auto;height:auto;min-height:34px;transform:none;display:flex;align-items:center;gap:8px;background:none; }
 .tx-mobile .edp-rolename>.edp-realm { width:56px;height:28px;transform:none;object-fit:contain; }
 .tx-mobile .edp-rolename>.edp-rolename-txt { width:auto;height:auto;transform:none;color:#f4e7cb;font:500 1.15rem/1.3 "Source Han Sans SC","Microsoft YaHei",sans-serif; }
 .tx-mobile .edp-bar { position:relative!important;inset:auto!important;grid-column:2;width:100%;height:24px;transform:none; }
 .tx-mobile .edp-bar.is-hp { grid-row:2; }
 .tx-mobile .edp-bar.is-mp { grid-row:3; }
 .tx-mobile .edp-bar>.fill { position:absolute!important; }
 .tx-mobile .edp-bar>b { position:absolute!important;font-size:.8rem; }

 .tx-mobile .edp-property { grid-area:property;width:auto;height:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px; }
 .tx-mobile .edp-property>.edp-cap { grid-column:1 / -1; }
 .tx-mobile .edp-stat { width:auto;height:auto;min-height:54px;overflow:visible;display:grid;grid-template-columns:1fr auto;gap:3px 8px;padding:.45rem .55rem;background:#102832;border:1px solid #d7b77a2e;border-radius:4px; }
 .tx-mobile .edp-stat-plate { display:none; }
 .tx-mobile .edp-stat>span,.tx-mobile .edp-stat>b { width:auto!important;height:auto!important;justify-content:flex-start;color:#dce6e2;font-size:.8rem; }
 .tx-mobile .edp-stat>b { justify-content:flex-end;color:#f0d8a5; }

 .tx-mobile .edp-linggen { grid-area:linggen;width:auto;height:auto; }
 .tx-mobile .edp-linggen>.edp-cap { margin-bottom:8px; }
 .tx-mobile .edp-star { width:100%;height:auto;transform:none;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;background:none; }
 .tx-mobile .edp-star-poly { display:none; }
 .tx-mobile .edp-star>div { width:auto!important;height:58px!important;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:1px;padding:0 0 4px;background-color:#102832!important;background-size:32px 32px!important;background-position:center 3px!important;background-repeat:no-repeat!important;border:1px solid #d7b77a2e;border-radius:4px;color:#dce6e2; }
 .tx-mobile .edp-star>div::before { display:none; }
 .tx-mobile .edp-lg-gold::before { content:"风"; }.tx-mobile .edp-lg-wood::before { content:"雷"; }.tx-mobile .edp-lg-water::before { content:"水"; }.tx-mobile .edp-lg-fire::before { content:"火"; }.tx-mobile .edp-lg-earth::before { content:"土"; }
 .tx-mobile .edp-lg-num { width:auto;height:auto;background:none; }
 .tx-mobile .edp-lg-num>b { width:auto;height:auto;color:#f1d9a6;font-size:.9rem; }

 .tx-mobile .edp-group { width:auto;height:auto;display:grid;grid-template-columns:minmax(0,1fr) 44px 44px;gap:6px;align-items:center; }
 .tx-mobile .edp-group.is-fashu { grid-area:skills; }.tx-mobile .edp-group.is-fabao { grid-area:weapons; }
 .tx-mobile .edp-group>.edp-cap { grid-column:1; }
 .tx-mobile .edp-page-l,.tx-mobile .edp-page-r { grid-row:1;width:44px;height:44px;transform:none;background:#183640;border:1px solid #9f8659;border-radius:4px;color:#f2dfb9; }
 .tx-mobile .edp-page-l::before,.tx-mobile .edp-page-r::before { display:block;font:400 1.8rem/1 sans-serif; }
 .tx-mobile .edp-page-l::before { content:"‹"; }.tx-mobile .edp-page-r::before { content:"›"; }
 .tx-mobile .edp-page-l { grid-column:2; }.tx-mobile .edp-page-r { grid-column:3; }
 .tx-mobile .edp-slots { grid-column:1 / -1;grid-row:2;width:100%;height:60px;transform:none;display:flex;gap:8px;overflow-x:auto; }
 .tx-mobile .edp-slot { flex:0 0 56px;width:56px;height:56px;min-width:56px;min-height:56px;cursor:pointer;touch-action:manipulation; }
 .tx-mobile .edp-slot>img { position:absolute!important;inset:0;width:100%;height:100%; }
 .tx-mobile .edp-slot:focus-visible { outline:2px solid #f2d18c;outline-offset:2px; }
 .tx-mobile .edp-tip { position:fixed!important;left:12px;right:12px;top:auto;bottom:calc(12px + env(safe-area-inset-bottom));width:auto;height:auto;min-height:112px;padding:1rem;z-index:275;opacity:0;visibility:hidden;pointer-events:none;transform:none;background:#e6dcc5!important;border:1px solid #a78955;border-radius:7px;box-shadow:0 .8rem 2rem #000c; }
 .tx-mobile .edp-tip.is-on { opacity:1;visibility:visible; }
 .tx-mobile .edp-tip-fabao,.tx-mobile .edp-tip-fashu { width:auto;height:auto; }
 .tx-mobile .edp-tip-name { width:auto;height:auto;margin-bottom:.45rem;color:#25333c;font-size:1rem; }
 .tx-mobile .edp-tip-desc { width:auto;height:auto;color:#394255;font-size:.9rem;line-height:1.5;overflow:visible; }
 .tx-mobile .edp-tip-el { float:left;width:32px;height:32px;margin:0 .6rem .35rem 0;transform:none; }
}

@media(max-width:960px) and (max-height:600px) {
 .tx-mobile #enemy-detail-overlay .edp-bg { width:min(100%,52rem);grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);grid-template-areas:"title title" "role property" "linggen skills" "linggen weapons";gap:8px 12px;padding:.75rem; }
 .tx-mobile .edp-title { min-height:40px;font-size:1.4rem; }
 .tx-mobile .edp-role { align-self:start; }
 .tx-mobile .edp-property { align-self:start; }
 .tx-mobile .edp-star { grid-template-columns:repeat(5,minmax(44px,1fr)); }
 .tx-mobile .edp-group { align-self:start; }
}
/* 修行侧重：不是功法卡，不显示虚构的招式图标、玄力消耗或品阶。 */
.tx-edition .tso-card.tx-growth-card {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 16px; padding: 26px 22px; color: #ece5d6;
    background: radial-gradient(ellipse at 50% 20%, #283c40 0%, #142329 60%, #0c171d 100%);
    border: 1px solid var(--growth-color); box-shadow: inset 0 0 25px #0005;
    text-align: center; overflow: hidden;
}
.tx-edition .tx-growth-glyph {
    display: grid; place-items: center; flex: 0 0 auto; width: 78px; height: 78px;
    border: 1px solid var(--growth-color); border-radius: 50%;
    font: 34px "KaiTi", "STKaiti", serif; color: var(--growth-color);
    box-shadow: 0 0 0 8px #ffffff05, 0 0 25px #ffffff08;
}
.tx-edition .tx-growth-name { font: 24px "KaiTi", "STKaiti", serif; letter-spacing: 2px; }
.tx-edition .tx-growth-desc { font-size: 14px; line-height: 1.75; color: #b5c0bf; }
.tx-edition .tx-growth-effect { margin-top: auto; color: var(--growth-color); font-size: 15px; }
@media(max-width: 600px) {
    .tx-edition .tso-card.tx-growth-card { gap: 8px; padding: 15px; min-height: 166px; }
    .tx-edition .tx-growth-glyph { width: 40px; height: 40px; font-size: 23px; }
    .tx-edition .tx-growth-name { font-size: 19px; }
    .tx-edition .tx-growth-desc { font-size: 13px; }
}

/* Combat bodies get a safe area independent of the old portrait offsets.
   The action layer additionally clamps recoil to the visible body rectangle. */
.tx-edition .battle-shell.tx-battle-ready [data-txb-pose] .battle-role,
.tx-edition .battle-shell.tx-battle-ready [data-txb-pose] .battle-role-tint {
    animation: none; left: -9rem; top: -36rem; width: 39rem; height: 39rem;
}
.tx-edition .battle-pop.tx-anchored {
    font-size: clamp(16px, 1.2vw, 22px);
    animation-name: tx-contact-label;
}
.tx-edition .playback-paused .battle-pop.tx-anchored { animation-play-state: paused; }
@keyframes tx-contact-label {
    0% { transform: translate(-50%, -50%) scale(.92); opacity: 1; }
    18%, 38% { transform: translate(-50%, -65%) scale(1.17); opacity: 1; }
    100% { transform: translate(-50%, calc(-50% - 2rem)) scale(1); opacity: 0; }
}

/* Contact is at the semantic foot pivot; the legacy stretched shade is hidden. */
.tx-edition .battle-shell.tx-grounded .battle-shade { display: none; }
.tx-edition .battle-shell.tx-grounded .battle-role { animation: none; }
.tx-edition .battle-shell.tx-grounded .txb-contact-shadow {
    position: absolute; left: 0; top: 0; display: block;
    transform: translate(-50%, -42%); border-radius: 50%; pointer-events: none;
    background: radial-gradient(ellipse, #071012bc 0 20%, #0710127a 43%, #07101220 65%, transparent 76%);
    z-index: -1;
}
.tx-edition .battle-shell.tx-grounded .battle-backdrop { object-position: 50% 100%; filter: brightness(.72) saturate(.82); }
.tx-edition .battle-shell.tx-grounded-arena .battle-backdrop { filter: brightness(.88) saturate(.88); }
.tx-edition .battle-shell.tx-grounded #battle-log {
    left: 25%; right: 25%; top: auto; bottom: 12px; width: auto; height: 46px;
    max-width: none; transform: none; padding: 4px 10px; font-size: 14px;
    mask-image: none; -webkit-mask-image: none; border: 0; background: #08182070;
}
@media(max-width:960px) {
    .tx-mobile .battle-shell.tx-battle-ready.tx-grounded #battle-log {
        left: 12px; right: 12px; bottom: 84px; height: 44px; font-size: 12px;
    }
}
@media(max-width:960px) and (max-height:600px) {
    .tx-mobile .battle-shell.tx-grounded .battle-hud { height: 78px; padding: 8px 14px; }
    .tx-mobile .battle-shell.tx-grounded .fighter-name { font-size: 17px; line-height: 20px; }
    .tx-mobile .battle-shell.tx-grounded .battle-stat-bar { height: 13px; margin-top: 4px; }
    .tx-mobile .battle-shell.tx-grounded .battle-stat-bar b { font-size: 10px; }
    .tx-mobile .battle-shell.tx-battle-ready.tx-grounded #battle-log { bottom: 68px; height: 22px; left: 43%; right: 5%; width: auto; font-size: 10px; }
}
@media(max-width: 960px) {
    .tx-mobile .battle-shell.tx-battle-ready .battle-side { top: 70%; height: 1px; width: 43vw; }
    .tx-mobile .battle-shell.tx-battle-ready .battle-side.player { left: 14%; }
    .tx-mobile .battle-shell.tx-battle-ready .battle-side.enemy { left: 58%; }
    .tx-mobile .battle-shell.tx-battle-ready .tx-fullbody .battle-role,
    .tx-mobile .battle-shell.tx-battle-ready .tx-fullbody .battle-role-tint {
        left: -4vw; top: -58vw; width: 43vw; height: 58vw;
    }
    .tx-mobile .battle-shell.tx-battle-ready [data-txb-pose] .battle-role,
    .tx-mobile .battle-shell.tx-battle-ready [data-txb-pose] .battle-role-tint {
        left: -7.5vw; top: -62vw; width: 50vw; height: 62vw;
    }
}
@media(max-width: 960px) and (max-height: 600px) {
    .tx-mobile .battle-shell.tx-battle-ready .battle-side { top: 65%; width: 27vw; }
    .tx-mobile .battle-shell.tx-battle-ready .battle-side.player { left: 17%; }
    .tx-mobile .battle-shell.tx-battle-ready .battle-side.enemy { left: 63%; }
    .tx-mobile .battle-shell.tx-battle-ready .tx-fullbody .battle-role,
    .tx-mobile .battle-shell.tx-battle-ready .tx-fullbody .battle-role-tint {
        left: -4vw; top: -44vh; width: 27vw; height: 44vh;
    }
    .tx-mobile .battle-shell.tx-battle-ready [data-txb-pose] .battle-role,
    .tx-mobile .battle-shell.tx-battle-ready [data-txb-pose] .battle-role-tint {
        left: -5vw; top: -48vh; width: 29vw; height: 48vh;
    }
    .tx-mobile .battle-shell.tx-battle-ready #battle-log {
        bottom: 4.8rem; height: 2.25rem; padding: .15rem .5rem;
        font-size: .68rem; line-height: 1.55; background: #08182080;
    }
}
