.chessboard-container{box-sizing:border-box;justify-content:center;align-items:center;width:100%;max-width:100%;padding:0;display:flex}.chessboard-container.mini{padding:0}.chessboard-container.mini .chessboard-wrapper{border-width:1px;max-width:100%}.chessboard-container.mobile .chessboard-wrapper{width:100%;max-width:100%}.chessboard-container.desktop .chessboard-wrapper{width:100%;max-width:600px}.chessboard-stack{flex-direction:column;align-items:stretch;width:100%;max-width:600px;display:flex}.chessboard-container.mini .chessboard-stack,.chessboard-container.mobile .chessboard-stack{max-width:100%}.board-row{display:contents}.chessboard-wrapper{aspect-ratio:1;background:var(--sq-dark,#b58863);box-sizing:border-box;border:2px solid #333;border-radius:4px;grid-template-rows:repeat(8,1fr);grid-template-columns:repeat(8,1fr);width:100%;max-width:100%;display:grid;position:relative;overflow:hidden}.chessboard-wrapper .piece--w{--pf:var(--piece-filter-w,opacity(1))}.chessboard-wrapper .piece--b{--pf:var(--piece-filter-b,opacity(1))}.chessboard-wrapper .piece-image,.chessboard-wrapper .promotion-piece{filter:var(--pf,opacity(1)) var(--piece-glow,opacity(1))}.chessboard-wrapper.board-tex--wood .square,.chessboard-wrapper.board-tex--wood .promotion-option{background-image:repeating-linear-gradient(100deg,#0000000f 0 3px,#0000 3px 9px,#ffffff12 9px 11px,#0000 11px 17px)}.chessboard-wrapper.board-tex--marble .square,.chessboard-wrapper.board-tex--marble .promotion-option{background-image:linear-gradient(125deg,#0000 40%,#ffffff59 45%,#0000 50%),linear-gradient(35deg,#0000 60%,#0000001f 63%,#0000 67%)}.chessboard-wrapper.board-tex--neon{--piece-glow:drop-shadow(0 0 2px #c8beffd9);background:#7c6cff99;border-color:#6b5cff;gap:1px;box-shadow:0 0 12px #7c6cff8c}.chessboard-wrapper.board-tex--neon .square .rank-label,.chessboard-wrapper.board-tex--neon .square .file-label{color:#c9c2ff}.chessboard-wrapper.board-tex--neon .promotion-option{border-color:#6b5cff;box-shadow:0 0 10px #7c6cff8c}.square{cursor:pointer;-webkit-user-select:none;user-select:none;aspect-ratio:1;box-sizing:border-box;justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:relative;overflow:hidden}.square.light{background-color:var(--sq-light,#f0d9b5)}.square.light .rank-label,.square.light .file-label{color:var(--sq-dark,#b58863)}.square.dark{background-color:var(--sq-dark,#b58863)}.square.dark .rank-label,.square.dark .file-label{color:var(--sq-light,#f0d9b5)}.square.selected{box-shadow:inset 0 0 0 3px #7b9c6e;background-color:#7b9c6e!important}.square.valid-move:after{content:"";pointer-events:none;background:#00000040;border-radius:50%;width:30%;height:30%;position:absolute}.square.king-in-check{animation:.8s ease-in-out infinite alternate check-flash}.square.check-path-green{box-shadow:inset 0 0 10px #00ff0080;background-color:#00c80066!important}.square.check-path-red{box-shadow:inset 0 0 15px #ff0000b3;background-color:#c8000099!important}.square.pulse{animation:.6s ease-in-out infinite alternate pulse-path}.square .piece{justify-content:center;align-items:center;width:86%;height:86%;transition:transform .1s;display:flex}.square .piece:hover{transform:scale(1.05)}.square .piece-image{object-fit:contain;display:block;width:100%!important;height:100%!important}.square .rank-label{pointer-events:none;z-index:2;font-size:clamp(8px,1.8vw,12px);font-weight:700;line-height:1;display:none;position:absolute;top:1px;left:3px}.square .file-label{pointer-events:none;z-index:2;font-size:clamp(8px,1.8vw,12px);font-weight:700;line-height:1;display:none;position:absolute;bottom:1px;right:3px}.chessboard-container:not(.mini) .square .rank-label,.chessboard-container:not(.mini) .square .file-label{display:block}@keyframes check-flash{0%{background-color:#ff00004d;box-shadow:inset 0 0 10px #f003}to{background-color:#f00c;box-shadow:inset 0 0 20px #f009}}@keyframes pulse-path{0%{opacity:.75;box-shadow:inset 0 0 8px #00ff0040}to{opacity:1;box-shadow:inset 0 0 18px #00ff00d9}}.square.last-move{box-shadow:inset 0 0 0 100vmax #ffd50052}.square.pending-move{box-shadow:inset 0 0 0 4px #1f6feb}.square.lesson-mark{box-shadow:inset 0 0 0 4px #16a34a,inset 0 0 0 100vmax #22c55e47}.square.valid-capture:after{background:0 0;border:4px solid #0000004d;width:88%;height:88%}.square:focus-visible{outline:3px solid var(--focus-color);outline-offset:-3px;z-index:3}.square .piece{position:relative}.square .piece-letter{text-align:center;pointer-events:none;border-radius:4px;min-width:34%;padding:0 3px;font-size:clamp(9px,2vw,15px);font-weight:800;line-height:1.3;position:absolute;bottom:0;left:0}.square .piece-letter.white{color:#000;background:#fff;border:1px solid #000}.square .piece-letter.black{color:#fff;background:#000;border:1px solid #fff}.square .square-coord{color:#fff;pointer-events:none;background:#000000b8;border-radius:3px;padding:1px 3px;font-size:clamp(8px,1.6vw,11px);font-weight:700;line-height:1.1;position:absolute;top:2px;right:2px}.keyboard-mode .square:focus-visible{outline-offset:-5px;outline-width:5px}.board-help{color:var(--text-color-light);margin:0 0 8px;font-size:.9rem}.board-cue{z-index:5;color:#fff;letter-spacing:.03em;pointer-events:none;background:#000c;border-radius:999px;padding:6px 16px;font-weight:800;animation:.25s ease-out board-cue-in;position:absolute;top:8px;left:50%;transform:translate(-50%)}.board-cue.strong{background:#c62828}@keyframes board-cue-in{0%{opacity:0;transform:translate(-50%,-8px)}to{opacity:1;transform:translate(-50%)}}.promotion-picker{z-index:10;color:#fff;background:#000000bf;flex-direction:column;justify-content:center;align-items:center;gap:12px;display:flex;position:absolute;inset:0}.promotion-picker .promotion-title{margin:0;font-size:1.15rem;font-weight:800}.promotion-picker .promotion-options{flex-wrap:wrap;justify-content:center;gap:10px;display:flex}.promotion-picker .promotion-option{background-color:var(--sq-light,#f0d9b5);color:var(--sq-ink,#000);text-transform:capitalize;border:2px solid #fff;border-radius:10px;flex-direction:column;align-items:center;gap:4px;padding:8px 12px;font-weight:700;display:flex}.promotion-picker .promotion-option:hover,.promotion-picker .promotion-option:focus-visible{filter:brightness(1.12);outline-offset:2px;outline:3px solid #ffd400}.promotion-picker .promotion-cancel{color:#fff;background:0 0;border:1px solid #fff;border-radius:8px;padding:6px 16px;font-weight:600}.confirm-move-bar{border:2px solid var(--primary);background:var(--card-bg);color:var(--text-color);border-radius:10px;flex-wrap:wrap;align-items:center;gap:8px;margin-top:10px;padding:10px 12px;display:flex}.confirm-move-bar .confirm-move-text{flex:1;font-weight:700}.confirm-move-bar button{border-radius:8px;padding:6px 16px;font-weight:700}.confirm-move-bar .confirm-btn{border:1px solid var(--primary-dark);background:var(--primary-dark);color:#fff}.confirm-move-bar .cancel-btn{border:1px solid var(--border-color);color:var(--text-color);background:0 0}html.a11y-hc .confirm-move-bar .confirm-btn{background:var(--primary);border-color:var(--primary);color:var(--text-color-reverse)}html.a11y-hc .chessboard-wrapper,html.a11y-board-hc .chessboard-wrapper{box-shadow:none;background:#000;border:3px solid #000;gap:0}html.a11y-hc .promotion-piece,html.a11y-board-hc .promotion-piece{filter:none}html.a11y-hc .chessboard-wrapper .square,html.a11y-board-hc .chessboard-wrapper .square{background-image:none}html.a11y-hc .chessboard-wrapper .promotion-option,html.a11y-board-hc .chessboard-wrapper .promotion-option{box-shadow:none;color:#000;background-color:#fff;background-image:none;border-color:#000}html.a11y-hc .chessboard-wrapper .promotion-option:hover,html.a11y-hc .chessboard-wrapper .promotion-option:focus-visible,html.a11y-board-hc .chessboard-wrapper .promotion-option:hover,html.a11y-board-hc .chessboard-wrapper .promotion-option:focus-visible{filter:none;background-color:#ffd400}html.a11y-hc .chessboard-wrapper.board-tex--neon .square.light .rank-label,html.a11y-hc .chessboard-wrapper.board-tex--neon .square.light .file-label,html.a11y-board-hc .chessboard-wrapper.board-tex--neon .square.light .rank-label,html.a11y-board-hc .chessboard-wrapper.board-tex--neon .square.light .file-label{color:#000}html.a11y-hc .chessboard-wrapper.board-tex--neon .square.dark .rank-label,html.a11y-hc .chessboard-wrapper.board-tex--neon .square.dark .file-label,html.a11y-board-hc .chessboard-wrapper.board-tex--neon .square.dark .rank-label,html.a11y-board-hc .chessboard-wrapper.board-tex--neon .square.dark .file-label{color:#fff}html.a11y-hc .square.light,html.a11y-board-hc .square.light{background-color:#fff}html.a11y-hc .square.light .rank-label,html.a11y-hc .square.light .file-label,html.a11y-board-hc .square.light .rank-label,html.a11y-board-hc .square.light .file-label{color:#000}html.a11y-hc .square.dark,html.a11y-board-hc .square.dark{background-color:#5b6b8c}html.a11y-hc .square.dark .rank-label,html.a11y-hc .square.dark .file-label,html.a11y-board-hc .square.dark .rank-label,html.a11y-board-hc .square.dark .file-label{color:#fff}html.a11y-hc .square.selected,html.a11y-board-hc .square.selected{box-shadow:inset 0 0 0 4px #000;background-color:#ffd400!important}html.a11y-hc .square.last-move,html.a11y-board-hc .square.last-move{box-shadow:inset 0 0 0 4px #ff7a00}html.a11y-hc .square.lesson-mark,html.a11y-board-hc .square.lesson-mark{box-shadow:inset 0 0 0 5px #000,inset 0 0 0 9px #00e5ff}html.a11y-hc .square.valid-move:after,html.a11y-board-hc .square.valid-move:after{background:#000;border:2px solid #fff}html.a11y-hc .square.valid-capture:after,html.a11y-board-hc .square.valid-capture:after{background:0 0;border:5px solid #f05}html.a11y-hc .square .piece-image,html.a11y-board-hc .square .piece-image{filter:drop-shadow(0 0 1px #000)drop-shadow(0 0 1px #000)drop-shadow(0 0 1px #fff)}.chessboard-wrapper.has-frame{border-color:var(--board-frame)}.chessboard-wrapper.has-crest .piece{z-index:2;position:relative}.board-crest{z-index:1;aspect-ratio:1;pointer-events:none;width:25%;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.board-crest .clan-crest{width:100%;height:100%;font-size:clamp(.8rem,3.2vmin,1.8rem)}.chessboard-wrapper.pieces-fx--pulse .piece--w .piece-image{--fx:var(--fx-w,#fff)}.chessboard-wrapper.pieces-fx--pulse .piece--b .piece-image{--fx:var(--fx-b,#000)}.chessboard-wrapper.pieces-fx--pulse .piece-image{animation:2.4s ease-in-out infinite piece-fx-pulse}.chessboard-wrapper.pieces-fx--shimmer .piece-image{animation:3s ease-in-out infinite piece-fx-shimmer}@keyframes piece-fx-pulse{0%,to{filter:var(--pf,opacity(1)) drop-shadow(0 0 1px var(--fx))}50%{filter:var(--pf,opacity(1)) drop-shadow(0 0 6px var(--fx))}}@keyframes piece-fx-shimmer{0%,70%,to{filter:var(--pf,opacity(1)) brightness(1)}85%{filter:var(--pf,opacity(1)) brightness(1.35) saturate(1.2)}}@media (prefers-reduced-motion:reduce){.chessboard-wrapper[class*=pieces-fx--] .piece-image{animation:none}}html.a11y-reduce-motion .chessboard-wrapper[class*=pieces-fx--] .piece-image{animation:none}html.a11y-hc .board-crest,html.a11y-board-hc .board-crest{display:none}html.a11y-hc .chessboard-wrapper[class*=pieces-fx--] .piece-image,html.a11y-board-hc .chessboard-wrapper[class*=pieces-fx--] .piece-image{animation:none}
.board-assistant{border:1px solid var(--border-color);background:var(--card-bg);width:100%;color:var(--text-color);border-radius:10px;margin-top:12px;padding:12px}.board-assistant .board-assistant-label{color:var(--header-color);margin-bottom:6px;font-weight:700;display:block}.board-assistant .board-assistant-row{gap:8px;display:flex}.board-assistant .board-assistant-row input{border:1px solid var(--border-color);background:var(--input-bg);min-width:0;color:var(--input-text-color);border-radius:8px;flex:1;padding:8px 12px;font-size:1rem}.board-assistant .board-assistant-row input::placeholder{color:var(--placeholder-color)}.board-assistant .board-assistant-row button{border:1px solid var(--primary-dark);background:var(--primary-dark);color:#fff;border-radius:8px;padding:8px 18px;font-weight:700}.board-assistant .board-assistant-reply{min-height:1.5em;color:var(--text-color-light);margin:8px 0 0;font-size:.9rem}html.a11y-hc .board-assistant .board-assistant-row button{background:var(--primary);border-color:var(--primary);color:var(--text-color-reverse)}
