/* Inlaid board coordinates use the same half-cell inset as the touch targets. */
.xq-board {
 --xq-grid:url("data:image/svg+xml,%3Csvg xmlns%3D%22http%3A//www.w3.org/2000/svg%22 viewBox%3D%220 0 900 1000%22%3E%3Cg fill%3D%22none%22 stroke%3D%22%2365401f%22 stroke-linecap%3D%22square%22%3E%3Cpath d%3D%22M43 43H857V957H43Z%22 stroke-width%3D%221.5%22/%3E%3Cpath d%3D%22M50 50H850V950H50Z M50 150h800 M50 250h800 M50 350h800 M50 450h800 M50 550h800 M50 650h800 M50 750h800 M50 850h800 M150 50v400m0 100v400 M250 50v400m0 100v400 M350 50v400m0 100v400 M450 50v400m0 100v400 M550 50v400m0 100v400 M650 50v400m0 100v400 M750 50v400m0 100v400 M350 50l200 200m-200 0 200-200 M350 750l200 200m-200 0 200-200%22 stroke-width%3D%222.6%22/%3E%3Cpath d%3D%22M130 244h14v-14 M130 256h14v14 M170 244h-14v-14 M170 256h-14v14 M730 244h14v-14 M730 256h14v14 M770 244h-14v-14 M770 256h-14v14 M70 344h-14v-14 M70 356h-14v14 M230 344h14v-14 M230 356h14v14 M270 344h-14v-14 M270 356h-14v14 M430 344h14v-14 M430 356h14v14 M470 344h-14v-14 M470 356h-14v14 M630 344h14v-14 M630 356h14v14 M670 344h-14v-14 M670 356h-14v14 M830 344h14v-14 M830 356h14v14 M70 644h-14v-14 M70 656h-14v14 M230 644h14v-14 M230 656h14v14 M270 644h-14v-14 M270 656h-14v14 M430 644h14v-14 M430 656h14v14 M470 644h-14v-14 M470 656h-14v14 M630 644h14v-14 M630 656h14v14 M670 644h-14v-14 M670 656h-14v14 M830 644h14v-14 M830 656h14v14 M130 744h14v-14 M130 756h14v14 M170 744h-14v-14 M170 756h-14v14 M730 744h14v-14 M730 756h14v14 M770 744h-14v-14 M770 756h-14v14%22 stroke-width%3D%222.7%22/%3E%3C/g%3E%3Cg fill%3D%22%23775337%22 font-family%3D%22Songti SC%2CSTKaiti%2CKaiTi%2Cserif%22 font-size%3D%2247%22 font-weight%3D%22600%22 text-anchor%3D%22middle%22%3E%3Ctext x%3D%22249%22 y%3D%22516%22 letter-spacing%3D%2217%22%3E%E6%A5%9A%E6%B2%B3%3C/text%3E%3Ctext x%3D%22647%22 y%3D%22516%22 letter-spacing%3D%2217%22%3E%E6%BC%A2%E7%95%8C%3C/text%3E%3C/g%3E%3C/svg%3E");
 --xq-timber:url("/scenes/festival-xiangqi-wood.webp");
}
.fv[data-room-theme="18"] .fv-chess.xq-board,.vt-play .vt-wood.xq-board {
 container-type:inline-size; isolation:isolate; box-sizing:border-box; position:relative;
 border:clamp(3px,.6vw,6px) solid #77462d; border-radius:7px;
 background-color:#daaf70;
 background-image:var(--xq-grid),linear-gradient(118deg,#fff2bf24 0%,#f6deb21a 43%,#8f541611 100%),var(--xq-timber);
 background-size:100% 100%,100% 100%,cover;
 box-shadow:inset 0 0 0 1px #ffedbf,inset 0 0 0 3px #b1804b,inset 2px 4px 9px #6835165c,0 1px 0 #d19b66,0 3px 0 #824f35,0 5px 0 #482f25,0 10px 15px #17110b80;
}
.fv .fv-chess.xq-board::before,.fv .fv-chess.xq-board::after,
.fv .fv-chess.xq-board > button:nth-child(39)::before,.fv .fv-chess.xq-board > button:nth-child(43)::before{content:none}
.fv .fv-chess.xq-board>button,.vt-crosses .vt-spot {background:transparent}
.xq-board .vt-crosses {container-type:inline-size}
.xq-board button:has(.xq-piece) {isolation:isolate}
.xq-board .xq-piece,.vt-held-piece.xq-piece {
 --xq-ink:#30322a;
 position:relative; z-index:2; display:grid; place-items:center; box-sizing:border-box;
 width:85%; height:auto; aspect-ratio:1; margin:0 0 3%; border-radius:50%;
 border:1px solid #765332;
 background-color:#edcc95;
 background-image:radial-gradient(ellipse at 32% 16%,#fff6d677 0%,#f8e6bd42 47%,#b5844933 72%,#74472170 100%),linear-gradient(118deg,#ffe8b2b5,#f4d49ac4),url("/scenes/festival-xiangqi-wood.webp");
 background-size:100% 100%,100% 100%,560% 560%;
 background-position:center,center,var(--xq-grain,38% 49%);
 color:var(--xq-ink); font:700 clamp(13px,6.15cqw,31px)/1 "Kaiti SC","STKaiti","KaiTi","Songti SC","Noto Serif CJK SC",serif;
 text-shadow:0 1px .25px #fff4cd,0 -.65px .4px #6d442491;
 box-shadow:inset .8px 1.1px .5px #fff6d5,inset -1px -1px 1px #996632,0 1px 0 #b28451,0 2px 0 #936137,0 3px 0 #6b4327,1px 4px 3px #44291168;
 pointer-events:none;
}
.xq-board .xq-piece::before,.vt-held-piece.xq-piece::before {
 content:""; position:absolute; inset:7.4%; border-radius:50%; pointer-events:none;
 border:1px solid color-mix(in srgb,var(--xq-ink) 60%,#b99a62); box-shadow:0 .7px 0 #ffebb8,inset 0 .7px 0 #f7e7bc;
}
.xq-board .xq-piece.xq-red,.vt-held-piece.xq-red {--xq-ink:#8d251e;color:var(--xq-ink)}
.xq-board .xq-piece.xq-black,.vt-held-piece.xq-black {--xq-ink:#262c2b;color:var(--xq-ink)}
.xq-board .xq-piece.long,.vt-held-piece.long.xq-piece {font:bold clamp(8px,2.8cqw,16px)/1 Georgia,serif}
.xq-board .vt-man:not(.long) {font-size:clamp(9px,5.1cqw,28px)}
.xq-board button:nth-child(3n) {--xq-grain:78% 61%}
.xq-board button:nth-child(3n+1) {--xq-grain:13% 19%}
.xq-board button:is(.selected,.picked),.xq-board .xq-in-flight {z-index:4}
.fv .fv-chess.xq-board .selected>.xq-piece,.xq-board .vt-spot.picked .xq-piece,.xq-board .vt-spot[data-vt-held] .xq-piece {
 transform:translateY(-7%) scale(1.065);
 outline:2px solid #226e66; outline-offset:1px;
 box-shadow:inset 1px 1px 1px #fff6d5,0 2px 0 #a87845,0 3px 0 #7d512e,2px 6px 5px #392c207a;
}
.fv .fv-chess.xq-board .last {box-shadow:none;background:radial-gradient(circle,#a67a4359 0 36%,transparent 39%)}
.xq-board .vt-spot.depart::before,.xq-board .vt-spot.arrive::before {border-color:#8b673a}
.xq-board button:is(.legal,.target)::after {z-index:5}
.fv .fv-chess.xq-board .legal:not(:has(.xq-piece))::after,.xq-board .vt-spot.target:not(:has(.xq-piece))::after {
 width:24%;height:auto;aspect-ratio:1;border:1px solid #2b6954;outline:1px solid #fff2c0;background:#477d65;
}
.fv .fv-chess.xq-board .legal:has(.xq-piece)::after,.xq-board .vt-spot.target:has(.xq-piece)::after {
 width:92%;height:auto;aspect-ratio:1;background:transparent;border:2px dashed #336b5b;outline:0;
}
.fv .fv-chess.xq-board .suggested::after {border:3px dashed #346e59}
.fv .fv-chess.xq-board .threatened>.xq-piece {outline:3px solid #b64331;outline-offset:1px}
.xq-board .xq-echo {position:absolute;left:7.5%;top:6%;z-index:1}
.xq-board .xq-contact {position:absolute;inset:6%;border-radius:50%;border:1.5px solid #ffe8a8;box-shadow:0 1px 1px #6f492f77;z-index:3;pointer-events:none}
@media(prefers-reduced-motion:no-preference){
 .xq-board .xq-piece {transition:transform 100ms ease-out,box-shadow 100ms ease-out}
 .fv-board:is([data-fx="move"],[data-fx="capture"],[data-fx="check"]) .fv-chess.xq-board .last>.xq-piece {animation:none}
}
.xq-board .xq-travel-shadow {
 position:absolute;inset:6.8%;z-index:0;pointer-events:none;border-radius:50%;
 background:radial-gradient(ellipse at center,#34210eef 0 57%,#372514b0 69%,#392b184c 81%,transparent 96%);
}
.xq-board .xq-in-flight>.xq-piece:not(.xq-echo) {
 box-shadow:inset .8px 1.1px .5px #fff6d5,inset -1px -1px 1px #996632,0 1px 0 #b28451,0 2px 0 #8c5c35;
}
