/* LobbyChess piece set, for every board that draws pieces as text glyphs.
 *
 * The contract, for any renderer:
 *   1. keep writing the glyph into the piece element exactly as before;
 *   2. add three classes to it: lcp, lcp-white|lcp-black, lcp-<k|q|r|b|n|p>
 *      (colour is spelled out because "b" already means bishop);
 *   3. the page carries <body data-piece-theme="lobby"> and links this file.
 * Then the glyph is hidden and the matching SVG from static/img/chesspieces/
 * fills the square. Remove the attribute and the page's own glyph CSS comes
 * back untouched, which is what a future board-theme picker switches.
 * Renderers build the class string inline, e.g. for FEN letter `sym`:
 *   'lcp lcp-' + (sym === sym.toUpperCase() ? 'white' : 'black') + ' lcp-' + sym.toLowerCase()
 *
 * /game (static/game.css) and /lobby (pages/lobby.html) predate this file and
 * carry the same rules inline under their own class names.
 *
 * The piece fills its square, so the square must have a definite size (every
 * current board is an 8x8 grid or fixed-size cells). !important because each
 * page's classic glyph CSS styles the same element with shadows, filters and
 * font sizes, and those must not bleed through the image.
 *
 * Keyed on the piece-letter classes, not on .lcp alone: markup from a cached
 * older script has no letter class and must keep showing its glyph.
 */
[data-piece-theme="lobby"] .lcp:is(.lcp-k, .lcp-q, .lcp-r, .lcp-b, .lcp-n, .lcp-p) {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  color: transparent !important;
  text-shadow: none !important;
  -webkit-text-stroke: 0 !important;
  filter: none !important;
  overflow: hidden !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: contain !important;
}
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-k { background-image: url("/static/img/chesspieces/wK.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-q { background-image: url("/static/img/chesspieces/wQ.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-r { background-image: url("/static/img/chesspieces/wR.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-b { background-image: url("/static/img/chesspieces/wB.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-n { background-image: url("/static/img/chesspieces/wN.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-white.lcp-p { background-image: url("/static/img/chesspieces/wP.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-k { background-image: url("/static/img/chesspieces/bK.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-q { background-image: url("/static/img/chesspieces/bQ.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-r { background-image: url("/static/img/chesspieces/bR.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-b { background-image: url("/static/img/chesspieces/bB.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-n { background-image: url("/static/img/chesspieces/bN.svg") !important; }
[data-piece-theme="lobby"] .lcp.lcp-black.lcp-p { background-image: url("/static/img/chesspieces/bP.svg") !important; }
