.board-tools{grid-template-columns:repeat(5,minmax(0,1fr))}#quickThemes{color:var(--gold)}#slamDoor{color:#b99aaa;font-size:13px;margin-top:10px}#slamDoor:hover{color:#ffb3b3;border-color:#905364}.theme-dialog{width:min(960px,94vw);max-height:88svh;padding:26px;border:1px solid #5a5872;border-radius:20px;background:#101725;color:#e5edf8;overflow:auto}.theme-dialog::backdrop{background:#020611d9;backdrop-filter:blur(9px)}.theme-dialog header{display:flex;justify-content:space-between;align-items:center;gap:16px}.theme-dialog h2{margin:4px 0}.theme-dialog p{color:#a4b6cc}.theme-filters{display:flex;gap:8px;margin:18px 0;flex-wrap:wrap}.theme-filters button.active{color:#07131d;background:#d4b16e}.quick-worlds{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.quick-worlds .world-card{min-height:170px;padding:14px}.quick-worlds .world-card img{max-height:100px}.theme-parts{display:grid;grid-template-columns:1fr 1fr;gap:15px;margin-top:20px}.theme-parts label{display:grid;gap:8px}.end-dialog{max-width:470px}.end-dialog footer{display:flex;gap:12px;margin-top:24px}.karma-portrait{position:relative;display:grid;place-items:center;width:100%;height:170px;isolation:isolate}.karma-portrait[data-level='0']{height:105px}.karma-portrait .portrait-avatar{z-index:1;margin:0!important}.karma-portrait>img{position:absolute;width:100%;max-width:430px;object-fit:contain;z-index:0;filter:drop-shadow(0 0 12px #83acff40)}.karma-portrait[data-level='1']>img{transform:scale(.66)}.karma-portrait[data-level='2']>img{transform:scale(.78)}.karma-portrait[data-level='3']>img{transform:scale(.9)}.karma-card{margin:8px 0 20px;color:#c3cfe0;font-size:13px}.karma-card strong{color:var(--gold);font-weight:500}.karma-card summary{cursor:pointer;margin-top:10px}.karma-card p{line-height:1.7;max-width:440px}.theme-note{font-size:13px;line-height:1.6}@media(max-width:650px){.theme-dialog{padding:18px}.quick-worlds{grid-template-columns:repeat(2,minmax(0,1fr))}.theme-parts{grid-template-columns:1fr}.board-tools button{font-size:12px;padding:9px 2px}.end-dialog footer{flex-direction:column}}
/* 2D sprites share measured pedestal anchoring in game, previews and animation. */
.square>img.flat-piece,.preview-cell>img.flat-piece,.motion-piece>img.flat-piece{inset:auto;margin:0;max-width:none;max-height:none;object-fit:fill;transform:none}
#board{touch-action:none;user-select:none;-webkit-user-select:none}#board.dragging{cursor:grabbing}.square.drag-target{box-shadow:inset 0 0 0 4px #f2ce83!important}.drag-piece{pointer-events:none;filter:drop-shadow(0 6px 7px #0008)}.drag-piece img{pointer-events:none}
.lobby-modes{display:grid;gap:10px;margin:20px 0}.lobby-modes button{display:flex;align-items:center;gap:15px;width:100%;padding:17px 18px;text-align:left;border:1px solid #40516a;border-radius:9px;color:#e4edf8;background:linear-gradient(120deg,#203149,#142032)}.lobby-modes button:first-child{border-color:#b69860;background:linear-gradient(120deg,#4a3d28,#233048)}.lobby-modes button>span:first-child{font-size:27px;color:#dfc28a;min-width:30px}.lobby-modes strong{display:block;font-size:16px}.lobby-modes small{display:block;margin-top:5px;font-size:13px;color:#aabbd0}.lobby-modes b{margin-left:auto;color:#cbb07b}.lobby-invitation>h2{font-size:30px!important}.live-engine-toggle{display:flex;align-items:center;gap:12px;padding:15px;background:#203a3f;border:1px solid #528f80;border-radius:8px;color:#d0ffe9;font-size:17px}.live-engine-toggle input{width:21px;height:21px;accent-color:#6de5bf}.analysis-navigation{display:flex;gap:12px;align-items:center;justify-content:space-between;margin:0 0 13px}.analysis-navigation span{font-size:13px;color:#a9b8c9}.engine-arrow{position:absolute;inset:0;width:100%;height:100%;z-index:6;pointer-events:none;filter:drop-shadow(0 1px 2px #071d25);opacity:.9}.engine-line span{overflow-wrap:anywhere;line-height:1.65}.engine-line{min-height:70px}.engine-line:disabled{opacity:.65}
.custom-clock{display:grid;grid-template-columns:1fr 1fr;gap:12px;padding:14px;background:#1d2e43;border-radius:9px;border:1px solid #58708c}.custom-clock label{margin:0}.custom-clock input{margin-top:8px}.custom-clock p{grid-column:1/-1;margin:0}.custom-waiting{margin:35px 0;padding:24px;border:1px solid #506782;border-radius:13px;background:#132135}.custom-waiting .quick-challenge{margin:7px 0}#returnAnalysis{border-color:#a88b53;color:#efd299;margin:12px 0}#analysisPositionCount{max-width:50%;text-align:center}
/* Launch stays attached to the board, before theme browsing. */
.battle-preview-column{min-width:0}.battle-launch{display:grid;gap:10px;margin-top:12px}.battle-launch #beginBattle{width:100%;margin:0;min-height:50px}.battle-launch .error-text:empty{display:none}.battle-launch .error-text{margin:0}.battle-launch #setupSignIn{margin:0}.standings-scroll{overflow-x:auto}.standings-scroll .standings{min-width:660px}.league-paging{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}#cupPlayers{width:100%;margin-top:12px;resize:vertical;font:inherit;font-size:16px;line-height:1.7;min-height:180px}
/* AnnaSchach 2.5D: the board is a shallow plane; sprites stand above it. */
#board.depth-board,.preview-board.depth-board{aspect-ratio:1 / .85;overflow:visible;isolation:isolate}
.depth-board>.square,.depth-board>.preview-cell{overflow:visible;isolation:auto;aspect-ratio:auto;z-index:auto}
.depth-board .square>img.depth-piece,.depth-board .preview-cell>img.depth-piece,.motion-piece>img.depth-piece{position:absolute;inset:auto;margin:0;max-width:none;max-height:none;object-fit:fill;transform:none;pointer-events:none;z-index:var(--piece-depth,10);filter:drop-shadow(0 3px 2px #0008)}
/* Ruby and emerald preserve Ice Crystal's transparent facets and 2.5D silhouettes. */
.depth-board .square>img.depth-piece[data-gem=ruby],.depth-board .preview-cell>img.depth-piece[data-gem=ruby],.motion-piece>img.depth-piece[data-gem=ruby],.pocket-piece img[data-gem=ruby]{filter:drop-shadow(0 3px 3px #420c22a8)}
.depth-board .square>img.depth-piece[data-gem=emerald],.depth-board .preview-cell>img.depth-piece[data-gem=emerald],.motion-piece>img.depth-piece[data-gem=emerald],.pocket-piece img[data-gem=emerald]{filter:drop-shadow(0 0 3px #43e6a866) drop-shadow(0 3px 3px #063b28ae)}
.depth-board[data-pieces="ice-gems"]>.square:not(.dark),.depth-board[data-pieces="ice-gems"]>.preview-cell:not(.dark){background:#f7e1a5 url('/world-assets/ice-gems/diamond-light.webp') center / cover no-repeat}
.depth-board .square.selected>img.depth-piece{filter:drop-shadow(0 0 5px #ffe1a2)}
.board-frame:has(>.depth-board){padding-top:26%}
.preview-board.depth-board{margin-top:26%!important}
.depth-board .engine-arrow{z-index:30}.depth-board .motion-piece{z-index:40}.drag-piece:has(>.depth-piece){isolation:isolate}
.depth-board .motion-piece.ice-motion-piece{z-index:60;transform-style:preserve-3d;will-change:transform,filter}.depth-board .ice-capture-shard{position:absolute;left:50%;top:54%;z-index:55;width:8%;height:16%;pointer-events:none;clip-path:polygon(50% 0,100% 36%,70% 100%,18% 82%,0 30%);background:linear-gradient(145deg,#f5fdff 0%,#c5f3ff 27%,#e9c776 56%,#fff7d4 100%);filter:drop-shadow(0 0 5px #d4f5ffb8)}
/* Tight classic SVGs: the visible silhouette nearly fills the square. */
.square>img.classic-large,.square>img.classic-large[data-piece=p],.preview-cell>img.classic-large,.preview-cell>img.classic-large[data-piece=p],.motion-piece>img.classic-large{inset:auto;left:2%;top:2%;width:96%;height:96%;margin:0;max-width:none;max-height:none;object-fit:contain;object-position:center bottom}
/* Wood & Gold and the preserved Ivory & Gold classic sets share the walnut frame. */
.board-frame:has(#board[data-pieces="classic"][data-theme="walnut"]),.board-frame:has(#board[data-pieces="classic-wood"][data-theme="walnut"]){padding:9px;background:linear-gradient(135deg,#e4bd78 0%,#6d3c20 16%,#bf7c3b 34%,#4b2918 52%,#d5a35d 73%,#5b321b 88%,#e7c47e 100%);border-color:#b37b3f;box-shadow:0 18px 48px #0008,inset 0 0 0 2px #29170c}
.preview-board[data-pieces="classic"][data-theme="walnut"],.preview-board[data-pieces="classic-wood"][data-theme="walnut"]{border:6px solid #8c542b;outline:1px solid #d6a65f;box-shadow:0 14px 34px #0007}
.square img.classic-large,.preview-cell img.classic-large,.motion-piece img.classic-large{filter:drop-shadow(0 2px 2px #0009)}
#board[data-pieces="classic"] .square>img.classic-large,#board[data-pieces="classic"] .motion-piece>img.classic-large,.preview-board[data-pieces="classic"] .preview-cell>img.classic-large,#board[data-pieces="classic-wood"] .square>img.classic-large,#board[data-pieces="classic-wood"] .motion-piece>img.classic-large,.preview-board[data-pieces="classic-wood"] .preview-cell>img.classic-large{left:-1%;top:-1%;width:102%;height:102%}
/* Amber Ice Crystal whites use dedicated recolored RGBA sprites in worlds.mjs. */
