.hit-chess-app{--hc-ink:#30262a;--hc-burgundy:#641e35;--hc-gold:#b58a43;--hc-cream:#f9f5ec;--hc-white:#f9f3dd;--hc-dark:#87465a;--hc-light:#efe1c8;direction:rtl;font-family:"Heebo",Arial,sans-serif;color:var(--hc-ink);font-size:16px;line-height:1.5;max-width:1200px;margin:24px auto;isolation:isolate}.hit-chess-app *{box-sizing:border-box}.hit-chess-app button,.hit-chess-app input,.hit-chess-app select{font:inherit}.hit-chess-app button{cursor:pointer}.hit-chess-app button:disabled{opacity:.5;cursor:not-allowed}.hit-chess-app :focus-visible{outline:3px solid #1477bb;outline-offset:3px;z-index:2}.hit-chess-app .hc-shell{border:1px solid #e2d1b8;background:var(--hc-cream);border-radius:20px;overflow:hidden;box-shadow:0 14px 45px #42202c12}.hit-chess-app .hc-head{background:linear-gradient(115deg,#411425,#75293f);padding:16px clamp(16px,3vw,30px)!important;min-height:0!important;height:auto!important;display:flex;align-items:center;justify-content:space-between;gap:14px;color:#fff9ec}.hit-chess-app .hc-head h2{font-family:inherit;font-size:clamp(24px,2.6vw,34px)!important;line-height:1.25!important;margin:0 0 3px!important;padding:0!important;font-weight:700;color:inherit}.hit-chess-app .hc-head h2 em{color:#ebc989;font-style:normal}.hit-chess-app .hc-head p{font-size:clamp(13px,1.2vw,15px)!important;line-height:1.5!important;margin:0!important;padding:0!important;color:#f3dce2}.hit-chess-app .hc-emblem{font-size:clamp(32px,3.5vw,44px);line-height:1;color:#e7c181;opacity:.9}.hit-chess-app .hc-setup{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;padding:24px}.hit-chess-app .hc-mode{background:#fffdf8;border:1px solid #e2d3bb;border-radius:15px;padding:25px 14px;display:flex;align-items:center;gap:5px;flex-direction:column;color:#412532;box-shadow:0 5px 12px #4f28300c;transition:transform .15s,border-color .15s}.hit-chess-app .hc-mode:hover{transform:translateY(-2px);border-color:var(--hc-gold)}.hit-chess-app .hc-mode-icon{font-size:58px;line-height:1.25}.hit-chess-app .hc-mode strong{font-size:20px}.hit-chess-app .hc-mode small{font-size:13px;color:#655b59}.hit-chess-app .hc-join{padding:0 24px 26px}.hit-chess-app .hc-join label{font-weight:700;display:block;margin-bottom:7px}.hit-chess-app .hc-join-row{display:flex;gap:10px}.hit-chess-app .hc-join input{min-width:0;flex:1;border:1px solid #bbab97;background:white;padding:12px;border-radius:9px;text-transform:uppercase}.hit-chess-app .hc-join button,.hit-chess-app .hc-actions button,.hit-chess-app .hc-room-panel button{border:0;background:var(--hc-burgundy);color:white;padding:11px 16px;border-radius:9px;font-weight:700}.hit-chess-app .hc-game{padding:clamp(12px,3vw,30px);display:grid;grid-template-columns:minmax(0,1.65fr) minmax(220px,1fr);gap:clamp(16px,3vw,28px);align-items:start}.hit-chess-app .hc-game[hidden],.hit-chess-app .hc-promotion[hidden],.hit-chess-app .hc-room-panel[hidden],.hit-chess-app .hc-difficulty-label[hidden],.hit-chess-app .hc-back[hidden],.hit-chess-app .hc-resign[hidden],.hit-chess-app .hc-setup[hidden],.hit-chess-app .hc-join[hidden]{display:none!important}.hit-chess-app .hc-board-side{min-width:0}.hit-chess-app .hc-status{text-align:center;background:#f1e7d9;border-radius:10px;padding:12px;font-weight:700;margin:0 0 12px;color:#5c2033;min-height:48px}.hit-chess-app .hc-board{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));width:min(100%,650px);aspect-ratio:1;direction:ltr;margin:auto;border:5px solid #4e2633;box-shadow:0 10px 25px #39242d30;touch-action:manipulation}.hit-chess-app .hc-square{border:0!important;padding:0!important;border-radius:0!important;width:100%;aspect-ratio:1;min-width:0;position:relative;display:flex;align-items:center;justify-content:center;line-height:1!important;box-shadow:none!important;appearance:none;-webkit-appearance:none;transition:background-color .1s}.hit-chess-app .hc-light{background:var(--hc-light)!important;color:#633348}.hit-chess-app .hc-dark{background:var(--hc-dark)!important;color:#fcf2db}.hit-chess-app .hc-square.hc-last{box-shadow:inset 0 0 0 100px #e8c15a44!important}.hit-chess-app .hc-square.hc-selected{box-shadow:inset 0 0 0 100px #e9c64a88!important}.hit-chess-app .hc-piece{font-family:"DejaVu Sans","Segoe UI Symbol","Noto Sans Symbols 2",serif;font-size:clamp(24px,5.8vw,58px);font-weight:400;z-index:1;user-select:none;pointer-events:none}.hit-chess-app .hc-white{color:#fffef2;text-shadow:0 2px 1px #37272b,-1px -1px 1px #37272b,1px -1px 1px #37272b,-1px 1px 1px #37272b}.hit-chess-app .hc-black{color:#241b26;text-shadow:0 1px 1px #f5eddf,1px 0 1px #f5eddf}.hit-chess-app .hc-dot{position:absolute;width:23%;aspect-ratio:1;border-radius:50%;background:#22634488;z-index:0}.hit-chess-app .hc-square:has(.hc-piece) .hc-dot{width:86%;border:4px solid #1a774b99;background:transparent}.hit-chess-app .hc-coordinate{position:absolute;font-size:10px;font-weight:700;font-family:inherit;line-height:1.2;pointer-events:none;opacity:.85}.hit-chess-app .hc-rank{top:3px;left:4px}.hit-chess-app .hc-file{right:4px;bottom:3px}.hit-chess-app .hc-instruction{font-size:12px;text-align:center;color:#6c595d;margin:10px 0 0}.hit-chess-app .hc-panel{display:grid;gap:14px}.hit-chess-app .hc-card{background:#fffdf8;border:1px solid #e4d6c2;border-radius:12px;padding:17px;min-width:0}.hit-chess-app .hc-card h3{font-size:17px;margin:0 0 13px;font-weight:800;color:#633047}.hit-chess-app .hc-code{font-size:clamp(20px,2.5vw,30px);font-weight:800;letter-spacing:.14em;direction:ltr;text-align:center;background:#f0e7d7;border-radius:8px;padding:10px;color:#54253a}.hit-chess-app .hc-room-panel p{font-size:14px}.hit-chess-app .hc-room-panel button{width:100%}.hit-chess-app .hc-room-panel small{display:block;margin-top:9px;color:#635c58}.hit-chess-app .hc-difficulty-label{font-weight:700;display:flex;align-items:center;justify-content:space-between;gap:8px}.hit-chess-app .hc-level{border-radius:8px;padding:6px 8px;border:1px solid #bba995;background:#fff;max-width:120px}.hit-chess-app .hc-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:15px}.hit-chess-app .hc-actions button{font-size:13px;padding:10px 8px}.hit-chess-app .hc-actions .hc-resign{background:#783342}.hit-chess-app .hc-moves{display:flex;flex-wrap:wrap;gap:8px;max-height:190px;overflow-y:auto;direction:ltr;text-align:left}.hit-chess-app .hc-move{border-radius:6px;padding:3px 7px;background:#f0e7dc;font-size:14px}.hit-chess-app .hc-empty{color:#776c6b;font-size:13px}.hit-chess-app .hc-promotion{margin:14px 0;padding:12px;text-align:center;background:#fff;border:2px solid #7e4358;border-radius:12px}.hit-chess-app .hc-promotion p{margin:0 0 8px;font-weight:700}.hit-chess-app .hc-promotion button{font-size:36px;background:#f3e9dc;color:#35202a;border:1px solid #d7c4ac;border-radius:8px;margin:4px;padding:5px 12px}.hit-chess-app .hc-loading{padding:30px;text-align:center}@media(max-width:760px){.hit-chess-app .hc-game{grid-template-columns:1fr}.hit-chess-app .hc-panel{grid-template-columns:repeat(2,minmax(0,1fr))}.hit-chess-app .hc-room-panel{grid-column:1/-1}.hit-chess-app .hc-piece{font-size:clamp(27px,8vw,59px)}}@media(max-width:440px){.hit-chess-app .hc-setup{padding:12px;gap:10px}.hit-chess-app .hc-mode{padding:18px 7px}.hit-chess-app .hc-mode-icon{font-size:44px}.hit-chess-app .hc-mode strong{font-size:16px}.hit-chess-app .hc-mode small{font-size:11px}.hit-chess-app .hc-join{padding:4px 12px 20px}.hit-chess-app .hc-join-row{flex-direction:column}.hit-chess-app .hc-game{padding:9px}.hit-chess-app .hc-board{border-width:3px}.hit-chess-app .hc-piece{font-size:clamp(25px,9vw,41px)}.hit-chess-app .hc-panel{grid-template-columns:1fr}.hit-chess-app .hc-room-panel{grid-column:auto}.hit-chess-app .hc-square .hc-coordinate{font-size:9px}}@media(prefers-reduced-motion:reduce){.hit-chess-app *{transition:none!important;animation:none!important}}@media(forced-colors:active){.hit-chess-app .hc-square{border:1px solid CanvasText!important}.hit-chess-app .hc-selected{outline:3px solid Highlight;outline-offset:-3px}.hit-chess-app .hc-target{outline:2px dashed Highlight;outline-offset:-3px}}
/* Reuse the site-provided Heebo font; no external font download. Chess glyphs retain their symbol font. */
.hit-chess-app :is(h1,h2,h3,h4,h5,h6,p,label,small,strong,button,input,select,textarea,option){font-family:inherit!important}

/* Chess-only accessibility and notification upgrades. No site-wide styles. */
.hit-chess-app .hc-status{display:table;width:auto;max-width:100%;min-height:0;margin:0 auto 10px;padding:6px 15px;border:1px solid #d6c7a8;border-radius:999px;background:#fffaf0;color:#57243b;text-align:center;font-size:14px;font-weight:700;line-height:1.5}
.hit-chess-app .hc-status[data-state="check"]{border-color:#a84941;background:#fff0e5;color:#7e2f23}
.hit-chess-app .hc-status[data-state="finished"]{border-color:#bea165;background:#f4ead8}
.hit-chess-app .hc-status[data-state="thinking"]{border-style:dashed}
/* The game controls live beside the board, not below the move journal.
   Sticky controls remain reachable while navigating the board on touch screens. */
.hit-chess-app .hc-shell{overflow:visible}
.hit-chess-app .hc-head{border-radius:19px 19px 0 0}
.hit-chess-app .hc-options[hidden],
.hit-chess-app .hc-actions .hc-back[hidden],
.hit-chess-app .hc-actions .hc-resign[hidden]{display:none!important}
.hit-chess-app .hc-board-side{position:relative;min-width:0}
.hit-chess-app .hc-actions{
  --hc-mobile-float-safe:0px;
  position:sticky;top:calc(8px + env(safe-area-inset-top,0px));z-index:15;
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;
  width:min(100%,650px);margin:0 auto 14px;padding:8px;
  background:linear-gradient(180deg,#fffdf8,#f7efe1);border:1px solid #d8c19e;border-radius:18px;
  box-shadow:0 10px 28px #351b2526, inset 0 1px 0 #fff;
}
.hit-chess-app .hc-actions button{
  display:flex;align-items:center;justify-content:center;gap:10px;
  min-height:56px;min-width:0;width:100%;margin:0;
  background:#fffaf1!important;border:1px solid #dbc29c!important;
  border-radius:14px;color:#5d2b40!important;padding:10px 9px!important;
  text-align:center;font-size:14px;font-weight:800;line-height:1.25;
  box-shadow:0 1px 0 #fff inset, 0 4px 10px #5a32410f;
  transition:background-color .15s,box-shadow .15s,border-color .15s,transform .15s;
}
.hit-chess-app .hc-actions button:hover:not(:disabled){background:#fbf2e4!important;border-color:#cfb07f!important;box-shadow:0 1px 0 #fff inset,0 8px 18px #5a324118;transform:translateY(-1px)}
.hit-chess-app .hc-actions button:active:not(:disabled){background:#f2e1c0!important;box-shadow:0 1px 0 #fff inset,0 2px 8px #5a324112;transform:none}
.hit-chess-app .hc-actions button:disabled{opacity:.5!important;color:#6d5f65!important;background:#fbf8f2!important;border-color:#e4d8c7!important;box-shadow:none!important}
.hit-chess-app .hc-actions button.hc-resign{color:#862b3b!important}
.hit-chess-app .hc-actions button.hc-resign:hover{background:#fff0ed!important;border-color:#e1b2ab!important}
.hit-chess-app .hc-actions .hc-action-icon{
  display:inline-grid;place-items:center;flex:none;
  width:38px;height:38px;border-radius:12px;
  border:1px solid #d3b380;background:linear-gradient(180deg,#6f2842,#5a2037);
  color:#f8e8c8;box-shadow:inset 0 1px 0 #92506b, 0 2px 6px #351b2520;
}
.hit-chess-app .hc-actions .hc-action-icon svg{width:21px;height:21px;display:block;stroke:currentColor;stroke-width:2.25;stroke-linecap:round;stroke-linejoin:round;fill:none;vector-effect:non-scaling-stroke}
.hit-chess-app .hc-actions button:disabled .hc-action-icon{background:linear-gradient(180deg,#cbc1b5,#bdb2a8);border-color:#cfc3b5;color:#f6f0e8;box-shadow:none}
.hit-chess-app .hc-actions .hc-action-label{min-width:0;overflow-wrap:anywhere}
/* Toast design: a small wax-seal-like chess message, without generic status stripes.
   Severity has both a visible caption and an announced sentence, not color alone. */
.hit-chess-app .hc-toast-region{
  position:fixed;top:50%;left:50%;right:auto;bottom:auto;
  transform:translate(-50%,-50%);width:min(390px,calc(100vw - 28px));
  max-height:calc(100dvh - 24px);z-index:100000;pointer-events:none;direction:rtl;
}
.hit-chess-app .hc-toast[hidden]{display:none!important}
.hit-chess-app .hc-toast{
  position:relative;display:flex;align-items:center;gap:14px;
  padding:18px 17px;background:#fffaf1;color:#34242e;
  border:1px solid #d1b990!important;border-radius:18px;
  box-shadow:0 16px 46px #3016223e,0 3px 8px #422c281c,inset 0 0 0 4px #fffdf9;
  font-family:inherit;font-size:15px;font-weight:500;line-height:1.55;
  overflow-wrap:anywhere;max-height:calc(100dvh - 24px);overflow-y:auto;pointer-events:auto;
}
.hit-chess-app .hc-toast-seal{
  display:grid;place-items:center;flex:none;width:49px;height:49px;
  background:#6a2e44;color:#f8e5c3;border:3px double #e5cda4;border-radius:50%;
  box-shadow:0 0 0 2px #6a2e44;
  font-family:"DejaVu Sans","Segoe UI Symbol",serif;font-size:29px;line-height:1;
}
.hit-chess-app .hc-toast-content{display:grid;gap:2px;flex:1;min-width:0}
.hit-chess-app .hc-toast-label{font-size:11px;font-weight:800;letter-spacing:.02em;color:#80613d}
.hit-chess-app .hc-toast-text{font-size:14px;font-weight:600;color:#38262d}
.hit-chess-app .hc-toast[data-kind="success"]{background:#fafaf1;border-color:#b9c6b4!important}
.hit-chess-app .hc-toast[data-kind="warning"]{background:#fff9ed;border-color:#dcbf8e!important}
.hit-chess-app .hc-toast[data-kind="error"]{background:#fff6f3;border-color:#ddb6a9!important}
.hit-chess-app .hc-toast[data-kind="success"] .hc-toast-seal{background:#345c4b;box-shadow:0 0 0 2px #345c4b}
.hit-chess-app .hc-toast[data-kind="warning"] .hc-toast-seal{background:#856027;box-shadow:0 0 0 2px #856027}
.hit-chess-app .hc-toast[data-kind="error"] .hc-toast-seal{background:#833c43;box-shadow:0 0 0 2px #833c43}
.hit-chess-app .hc-toast-close{
  display:grid;place-items:center;flex:none;align-self:start;
  min-width:44px;min-height:44px;width:44px;height:44px;
  margin:-6px -5px -6px 0;padding:0;
  background:transparent;border:1px solid transparent;border-radius:50%;
  color:#5f4952;font-size:25px;line-height:1;font-family:inherit;
}
.hit-chess-app .hc-toast-close:hover{background:#ede4d8;border-color:#d4bfa9}
.hit-chess-app .hc-sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;border:0!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;clip-path:inset(50%)!important}
.hit-chess-app .hc-board .hc-square[aria-disabled="true"]{cursor:default;opacity:1}
.hit-chess-app .hc-board .hc-square.hc-target{outline:2px dashed #fbe29f;outline-offset:-4px}
.hit-chess-app .hc-promotion .hc-promotion-cancel{font-family:inherit;font-size:14px;font-weight:700;padding:10px 12px;vertical-align:middle}
@media(max-width:760px){
  .hit-chess-app .hc-actions{top:calc(8px + env(safe-area-inset-top,0px));gap:7px;padding:7px}
  .hit-chess-app .hc-actions button{min-height:54px;gap:8px;padding:8px 7px!important;font-size:13px}
  .hit-chess-app .hc-actions .hc-action-icon{width:34px;height:34px}
}
@media(max-width:520px){
  .hit-chess-app .hc-actions{--hc-mobile-float-safe:58px;padding-right:calc(8px + var(--hc-mobile-float-safe));}
}
@media(max-width:440px){
  .hit-chess-app .hc-actions{margin-bottom:10px;padding:6px;gap:6px;border-radius:14px;grid-template-columns:repeat(3,minmax(0,1fr));}
  .hit-chess-app .hc-actions button{flex-direction:column;gap:4px;min-height:66px;padding:7px 4px!important;font-size:12px}
  .hit-chess-app .hc-actions .hc-action-icon{width:32px;height:32px}
  .hit-chess-app .hc-actions .hc-action-icon svg{width:18px;height:18px}
  .hit-chess-app .hc-toast-region{width:calc(100vw - 24px)}
  .hit-chess-app .hc-toast{padding:13px 11px;gap:10px}
  .hit-chess-app .hc-toast-seal{width:42px;height:42px;font-size:25px}
  .hit-chess-app .hc-toast-text{font-size:14px}
  .hit-chess-app .hc-toast-close{margin:-5px -5px -5px 0}
}
@media(prefers-reduced-motion:reduce){.hit-chess-app .hc-actions button{transition:none!important}}
@media(forced-colors:active){
  .hit-chess-app .hc-actions,.hit-chess-app .hc-actions button,.hit-chess-app .hc-toast{background:Canvas!important;color:CanvasText!important;border:1px solid CanvasText!important;box-shadow:none!important}
  .hit-chess-app .hc-actions .hc-action-icon,.hit-chess-app .hc-toast-seal{background:Canvas!important;color:CanvasText!important;border:1px solid CanvasText!important;box-shadow:none!important}
  .hit-chess-app .hc-toast-close{color:CanvasText!important}
  .hit-chess-app .hc-board .hc-square.hc-target{outline:2px dashed Highlight}
}

/* Chess invite flow: only the Chess module. Clear, compact steps on desktop and mobile. */
.hit-chess-app .hc-online-guide{margin:-12px 24px 18px;padding:11px 14px;display:flex;align-items:flex-start;gap:7px 15px;flex-wrap:wrap;background:#f2e9dc;border:1px solid #e1d0b8;border-radius:12px;font-size:14px;line-height:1.55;color:#4a3441}
.hit-chess-app .hc-online-guide strong{color:#632b43;flex:none}
.hit-chess-app .hc-room-steps{counter-reset:step;padding:0;margin:12px 0 15px;list-style:none;display:grid;gap:10px}
.hit-chess-app .hc-room-steps li{counter-increment:step;display:flex;align-items:flex-start;gap:9px;font-size:14px;line-height:1.5;margin:0;color:#493944}
.hit-chess-app .hc-room-steps li::before{content:counter(step);display:grid;place-items:center;flex:none;width:24px;height:24px;border:1px solid #d2b58a;background:#f7eada;border-radius:50%;color:#643147;font-size:12px;font-weight:800}
.hit-chess-app .hc-room-panel button.hc-copy-invite{min-height:48px;border:1px solid #642a42;background:#642a42;color:#fffdf6}
.hit-chess-app .hc-room-fallback{margin-top:12px;padding-top:12px;border-top:1px solid #e4d8c8;display:grid;grid-template-columns:1fr auto;align-items:center;gap:6px 9px}
.hit-chess-app .hc-room-fallback>span{grid-column:1/-1;font-size:13px;color:#5a4852}
.hit-chess-app .hc-room-fallback .hc-code{font-size:clamp(17px,2vw,22px);letter-spacing:.09em;display:inline-block;min-width:0;overflow-wrap:anywhere;padding:8px 6px}
.hit-chess-app .hc-room-fallback .hc-copy-code{width:auto;min-height:44px;padding:8px 12px;background:#f4e8d5;color:#552b40;border:1px solid #d6bd99;font-size:13px}
.hit-chess-app .hc-room-wait{font-size:13px;margin:12px 0 0;color:#624a53}
.hit-chess-app .hc-room-help{margin:10px 0;font-size:14px;line-height:1.6}
.hit-chess-app .hc-room-success{display:flex;align-items:center;gap:8px;color:#285a47;font-weight:700;margin:8px 0}
.hit-chess-app .hc-room-success span{font-family:"DejaVu Sans",serif;font-size:18px}
.hit-chess-app .hc-room-code-line{display:flex;justify-content:space-between;align-items:center;gap:8px;padding-top:10px;border-top:1px solid #e4d8c8;font-size:13px}
.hit-chess-app .hc-room-code-line .hc-code{font-size:clamp(17px,2vw,22px);letter-spacing:.08em;padding:7px 9px}
@media(max-width:440px){.hit-chess-app .hc-online-guide{margin:-3px 12px 15px;display:block;padding:10px 12px}.hit-chess-app .hc-online-guide strong{display:block;margin-bottom:3px}.hit-chess-app .hc-room-fallback{grid-template-columns:1fr auto}.hit-chess-app .hc-room-fallback .hc-code{font-size:17px}}
@media(forced-colors:active){.hit-chess-app .hc-online-guide,.hit-chess-app .hc-room-steps li::before,.hit-chess-app .hc-room-fallback .hc-copy-code,.hit-chess-app .hc-room-panel button.hc-copy-invite{color:CanvasText!important;background:Canvas!important;border:1px solid CanvasText!important}}

/* On small screens, inviting someone is the immediate next action: show it BEFORE the board. */
@media(max-width:760px){
 .hit-chess-app .hc-game.hc-inviting .hc-panel{display:contents}
 .hit-chess-app .hc-game.hc-inviting .hc-room-panel{order:-1;grid-column:1;max-width:100%}
 .hit-chess-app .hc-game.hc-inviting .hc-board-side{order:0}
 .hit-chess-app .hc-game.hc-inviting .hc-panel>.hc-card:not(.hc-room-panel){order:1;grid-column:1}
}

/* Chess 1.4: compact, high-contrast, centered chess notices (no generic caption).
   Scoped to the chess root. The wax-seal icon is unchanged. */
.hit-chess-app .hc-toast-region{width:min(360px,calc(100vw - 28px))}
.hit-chess-app .hc-toast{min-height:60px;gap:10px;padding:9px 10px;border-radius:15px;line-height:1.4;box-shadow:0 12px 30px #30162238,inset 0 0 0 2px #fffdf9}
.hit-chess-app .hc-toast-seal{width:38px;height:38px;font-size:23px;border-width:2px;box-shadow:0 0 0 1px #6a2e44}
.hit-chess-app .hc-toast-content{display:block;min-width:0;flex:1}
.hit-chess-app .hc-toast-text{display:block;font-size:14px;line-height:1.4;font-weight:650;color:#34212b}
.hit-chess-app .hc-toast-close{width:44px;min-width:44px;height:44px;min-height:44px;margin:0 -4px 0 0;align-self:center}
/* Matching custom SVG action emblems: strong, consistent 2.4px strokes. */
.hit-chess-app .hc-actions .hc-action-icon{width:36px;height:36px;border-radius:11px;border:1px solid #d2ad73;background:#642a40;color:#fff7e8;box-shadow:inset 0 1px 0 #ffffff42,0 2px 5px #27131c25;font-size:initial;line-height:1}
.hit-chess-app .hc-actions .hc-action-icon svg{display:block;width:23px;height:23px;stroke:currentColor;fill:none;flex:none;overflow:visible}
.hit-chess-app .hc-actions button:disabled .hc-action-icon{background:#e8e0d4;color:#665e60;border-color:#b9afa5;box-shadow:none}
.hit-chess-app .hc-actions button.hc-resign .hc-action-icon{background:#783342;border-color:#c19b78;color:#fff8ef}
@media(max-width:760px){
 .hit-chess-app .hc-actions .hc-action-icon{width:34px;height:34px}
 .hit-chess-app .hc-actions .hc-action-icon svg{width:22px;height:22px}
}
@media(max-width:440px){
 .hit-chess-app .hc-toast-region{width:min(350px,calc(100vw - 22px))}
 .hit-chess-app .hc-toast{min-height:58px;padding:7px 9px;gap:9px}
 .hit-chess-app .hc-toast-seal{width:35px;height:35px;font-size:22px}
 .hit-chess-app .hc-toast-text{font-size:13.5px;line-height:1.38}
 .hit-chess-app .hc-actions .hc-action-icon{width:32px;height:32px;border-radius:10px}
 .hit-chess-app .hc-actions .hc-action-icon svg{width:22px;height:22px}
}
@media(forced-colors:active){
 .hit-chess-app .hc-actions .hc-action-icon,.hit-chess-app .hc-toast-seal{color:CanvasText!important;background:Canvas!important;border:2px solid CanvasText!important;box-shadow:none!important}
}

/* Chess 1.5 - self-contained controls, clocks, openings and end-of-game flow. */
.hit-chess-app .hc-time-choice{margin:-4px 24px 23px;padding:14px 18px;background:#fffdf8;border:1px solid #dfcaaa;border-radius:14px;display:flex;align-items:center;gap:12px;flex-wrap:wrap;color:#4f2c3b}
.hit-chess-app .hc-time-choice[hidden],.hit-chess-app .hc-clocks[hidden],.hit-chess-app .hc-finish[hidden],.hit-chess-app .hc-opening[hidden]{display:none!important}
.hit-chess-app .hc-time-choice label{font-weight:800;flex:none}
.hit-chess-app .hc-time-option{flex:1;min-width:130px;max-width:300px;min-height:44px;padding:8px 12px;border:1px solid #bb9e74;border-radius:10px;background:#fff;color:#4b2639}
.hit-chess-app .hc-time-choice p{margin:0;font-size:12px;color:#635358;flex:1 1 100%;line-height:1.5}
.hit-chess-app .hc-clocks{width:min(100%,650px);margin:0 auto 11px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.hit-chess-app .hc-clock{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 14px;background:#fffaf1;color:#5e3344;border:1px solid #d9c8ac;border-radius:13px;min-width:0}
.hit-chess-app .hc-clock-name{font-weight:700;font-size:13px}
.hit-chess-app .hc-clock-value{font:800 clamp(17px,2.8vw,24px)/1.2 ui-monospace,SFMono-Regular,Consolas,monospace!important;font-variant-numeric:tabular-nums;letter-spacing:.035em;color:#553040}
.hit-chess-app .hc-clock-active{border:2px solid #aa7a3a;background:#f5ead5;padding:8px 13px;box-shadow:inset 0 0 0 2px #fff8ed}
.hit-chess-app .hc-clock-low{border-color:#b24d46;background:#fff1e9}
.hit-chess-app .hc-clock-low .hc-clock-value{color:#9a2a2b}
.hit-chess-app .hc-finish{width:min(100%,650px);margin:0 auto 13px;padding:17px 18px;border-radius:18px;background:linear-gradient(135deg,#522037,#78364d);border:1px solid #a7835d;color:#fff9ec;box-shadow:0 10px 25px #30152222;display:grid;gap:6px;text-align:center}
.hit-chess-app .hc-finish-kicker{font-size:12px;letter-spacing:.02em;color:#efd4aa;font-weight:700}
.hit-chess-app .hc-finish-title{font-size:clamp(18px,2.6vw,25px);font-weight:800;line-height:1.35;color:inherit}
.hit-chess-app .hc-finish-help{font-size:13px;line-height:1.5;color:#f5e6de;margin:0}
.hit-chess-app .hc-finish-actions{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:9px}
.hit-chess-app .hc-finish-actions button{border:1px solid #e7c68f!important;background:#fff8e7!important;color:#522b3b!important;border-radius:10px;padding:10px 13px;min-height:44px;flex:1 1 130px;font-weight:800}
.hit-chess-app .hc-finish-actions button:disabled{opacity:.65}
.hit-chess-app .hc-opening-name{font-size:14px;font-weight:700;color:#5b3045;margin:0}
.hit-chess-app .hc-export-pgn{margin-top:12px;min-height:44px;padding:8px 12px;border-radius:10px;border:1px solid #d5bd94;background:#f8f0e3;color:#5f3044;font-weight:700;font-size:13px}
.hit-chess-app .hc-export-pgn:hover{background:#efe1ca}
/* In the narrow viewport, keep controls immediately above the board instead of
   allowing a sticky toolbar to overlap an unrelated floating mobile menu. */
@media(max-width:760px){
 .hit-chess-app .hc-actions{position:relative;top:auto;z-index:1;padding:7px;gap:7px}
 .hit-chess-app .hc-actions button{min-width:0}
 .hit-chess-app .hc-time-choice{margin:0 12px 16px;padding:13px}
}
@media(max-width:520px){
 .hit-chess-app .hc-actions{padding:6px;gap:5px}
 .hit-chess-app .hc-finish{padding:13px 12px;border-radius:14px}
 .hit-chess-app .hc-finish-actions button{font-size:13px}
 .hit-chess-app .hc-clocks{gap:7px}
 .hit-chess-app .hc-clock{padding:8px;gap:5px}
 .hit-chess-app .hc-clock-active{padding:7px}
 .hit-chess-app .hc-clock-name{font-size:12px}
 .hit-chess-app .hc-clock-value{font-size:18px!important}
}
@media(max-width:350px){
 .hit-chess-app .hc-time-option{min-width:100%;max-width:100%}
 .hit-chess-app .hc-actions button{font-size:11px}
 .hit-chess-app .hc-actions .hc-action-icon{width:28px;height:28px}
}
@media(forced-colors:active){
 .hit-chess-app .hc-clock,.hit-chess-app .hc-time-choice,.hit-chess-app .hc-finish,.hit-chess-app .hc-finish-actions button{background:Canvas!important;color:CanvasText!important;border:1px solid CanvasText!important;box-shadow:none!important}
 .hit-chess-app .hc-clock-active{outline:3px solid Highlight;outline-offset:1px}
}

.hit-chess-app .hc-online-guide[hidden]{display:none!important}
/* Do not place actionable labels under the site's independently injected
   top-right mobile menu. This is scoped to the chess clocks and toolbar only. */
@media(max-width:520px){
 .hit-chess-app .hc-board-side{--hc-float-exclusion:clamp(51px,16vw,65px)}
 .hit-chess-app .hc-clocks{padding-inline-start:var(--hc-float-exclusion)}
 .hit-chess-app .hc-actions{padding-inline-start:calc(6px + var(--hc-float-exclusion))}
}
@media(max-width:520px){
 .hit-chess-app .hc-clocks,.hit-chess-app .hc-actions{width:calc(100% - var(--hc-float-exclusion));margin-left:0;margin-right:auto}
 .hit-chess-app .hc-clocks{padding-inline-start:0}
 .hit-chess-app .hc-actions{padding-inline-start:6px}
}

.hit-chess-app .hc-status[hidden]{display:none!important}


/* Chess 1.6: quiet, inline connection recovery. No global selectors and no blocking overlay. */
.hit-chess-app .hc-network[hidden],.hit-chess-app .hc-network button[hidden]{display:none!important}
.hit-chess-app .hc-network{
 width:min(100%,650px);margin:0 auto 12px;padding:8px 11px;display:flex;align-items:center;justify-content:center;gap:9px;
 border:1px solid #ccb48e;border-radius:12px;background:#fff8ea;color:#543344;
 font-size:13px;line-height:1.5;font-weight:650;flex-wrap:wrap;text-align:center;
}
.hit-chess-app .hc-network-text{min-width:0;flex:1 1 155px}
.hit-chess-app .hc-network-indicator{width:10px;height:10px;flex:none;border-radius:50%;background:#b17b2c;border:2px solid #fff7ea;box-shadow:0 0 0 1px #a57735}
.hit-chess-app .hc-network button{min-width:44px;min-height:44px;padding:7px 11px;border:1px solid #b79564;border-radius:9px;background:#fffdf6;color:#502a3b;font-weight:750}
.hit-chess-app .hc-network button:hover{background:#f2e8d7}
@media(max-width:440px){.hit-chess-app .hc-network{font-size:12px;padding:7px 8px;gap:6px}.hit-chess-app .hc-network button{font-size:12px}}
@media(forced-colors:active){.hit-chess-app .hc-network,.hit-chess-app .hc-network button{background:Canvas!important;color:CanvasText!important;border:1px solid CanvasText!important}.hit-chess-app .hc-network-indicator{background:Highlight!important;border:1px solid CanvasText}}

/* Chess 1.7: prominent but non-blocking turn and check cues. The floating cue
   is centered in the viewport, then disappears; the board status persists. */
.hit-chess-app .hc-status{
 display:block;max-width:min(100%,390px);margin:0 auto 12px;
 padding:10px 18px;border-radius:15px;border:2px solid #ba9a65;
 background:linear-gradient(115deg,#fffdf7,#f4e9d6);color:#58283e;
 font-size:clamp(15px,2.7vw,17px);font-weight:800;line-height:1.55;
 box-shadow:0 4px 13px #3b1f2920;text-align:center;
}
.hit-chess-app .hc-status[data-state="check"]{
 border-color:#a33c38;background:#fff4ea;color:#762c30;
 box-shadow:0 0 0 3px #fff5e8 inset,0 5px 15px #892c3423;
}
.hit-chess-app .hc-square.hc-king-check{
 box-shadow:inset 0 0 0 3px #fff1cc,inset 0 0 0 7px #a73539!important;
}
.hit-chess-app .hc-toast[data-kind="turn"],
.hit-chess-app .hc-toast[data-kind="check"]{
 border-width:2px!important;box-shadow:0 18px 45px #31192346,inset 0 0 0 2px #fffefa;
}
.hit-chess-app .hc-toast[data-kind="turn"]{background:#fffaf0;border-color:#b9975b!important}
.hit-chess-app .hc-toast[data-kind="check"]{background:#fff3ea;border-color:#9d3439!important}
.hit-chess-app .hc-toast[data-kind="check"] .hc-toast-text{color:#702a32;font-weight:800}
.hit-chess-app .hc-toast[data-kind="turn"] .hc-toast-text{font-weight:800}
.hit-chess-app .hc-toast[data-kind="turn"] .hc-toast-seal{background:#633047;box-shadow:0 0 0 1px #633047}
.hit-chess-app .hc-toast[data-kind="check"] .hc-toast-seal{background:#8f333b;box-shadow:0 0 0 1px #8f333b}
@media(max-width:440px){
 .hit-chess-app .hc-status{max-width:100%;font-size:14px;padding:8px 10px;border-radius:12px}
 .hit-chess-app .hc-toast[data-kind="check"],.hit-chess-app .hc-toast[data-kind="turn"]{max-width:100%}
}
@media(forced-colors:active){
 .hit-chess-app .hc-status,.hit-chess-app .hc-toast[data-kind="turn"],.hit-chess-app .hc-toast[data-kind="check"]{background:Canvas!important;color:CanvasText!important;border:2px solid CanvasText!important;box-shadow:none!important}
 .hit-chess-app .hc-square.hc-king-check{outline:4px solid Highlight;outline-offset:-4px;box-shadow:none!important}
}

/* 1.8.1 refinements: comfortable touch selection, learning and draw offers. */
.hit-chess-app .hc-board{touch-action:pan-y pinch-zoom}
.hit-chess-app .hc-setup{grid-template-columns:repeat(2,minmax(0,1fr))}
.hit-chess-app .hc-mode:focus-visible,.hit-chess-app .hc-training-actions button:focus-visible,.hit-chess-app .hc-social button:focus-visible{outline:3px solid #1767b2;outline-offset:3px}
.hit-chess-app .hc-training{width:min(100%,650px);margin:0 auto 12px;padding:13px 15px;background:linear-gradient(140deg,#fff8ea,#f2e5cc);border:1px solid #d8bd95;border-radius:14px;color:#493143}
.hit-chess-app .hc-training[hidden]{display:none!important}
.hit-chess-app .hc-training-title{display:block;color:#612b42;font-weight:800;font-size:17px}
.hit-chess-app .hc-training-info{margin:7px 0 11px;font-size:14px;line-height:1.6}
.hit-chess-app .hc-training-actions{display:flex;flex-wrap:wrap;gap:8px}
.hit-chess-app .hc-training-actions button{min-height:44px;background:#63273e;color:#fffaf0;border:1px solid #793d55;border-radius:10px;padding:8px 13px;font-size:14px;font-weight:700}
.hit-chess-app .hc-training-actions button[hidden]{display:none!important}
.hit-chess-app .hc-social[hidden],.hit-chess-app .hc-draw-reply[hidden],.hit-chess-app .hc-draw-pending[hidden],.hit-chess-app .hc-draw-offer[hidden]{display:none!important}
.hit-chess-app .hc-social-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:12px}
.hit-chess-app .hc-social-head h3{margin:0}
.hit-chess-app .hc-social-hint{font-size:12px;color:#695c60}
.hit-chess-app .hc-draw-controls{display:grid;gap:9px}
 .hit-chess-app .hc-draw-controls button{min-height:44px;padding:9px 14px;border:1px solid #b89670;border-radius:10px;background:#fff5e5;color:#5c2840;font-size:14px;font-weight:700;cursor:pointer}
.hit-chess-app .hc-draw-controls .hc-draw-reply{display:flex;flex-wrap:wrap;gap:8px;align-items:center;padding:10px;background:#f1e6d6;border:1px solid #dbbf98;border-radius:12px}
.hit-chess-app .hc-draw-reply p{flex-basis:100%;margin:0;color:#583144;font-weight:700;font-size:14px}
.hit-chess-app .hc-draw-reply button:first-of-type{background:#64283f;color:white}
.hit-chess-app .hc-draw-pending{font-size:13px;line-height:1.5;color:#675057}
.hit-chess-app .hc-actions .hc-action-icon{border-radius:12px}
@media(max-width:760px){
 .hit-chess-app .hc-social{grid-column:1/-1}
 .hit-chess-app .hc-training{padding:12px}
}
@media(max-width:440px){
 .hit-chess-app .hc-setup{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
 .hit-chess-app .hc-mode{min-height:116px;padding:13px 7px}
 .hit-chess-app .hc-mode strong{font-size:15px}
 .hit-chess-app .hc-mode small{font-size:11px;line-height:1.35;text-align:center}
 .hit-chess-app .hc-mode-icon{font-size:36px}
 .hit-chess-app .hc-training-title{font-size:15px}
 .hit-chess-app .hc-training-info{font-size:13px}
}
@media(forced-colors:active){
 .hit-chess-app .hc-training,.hit-chess-app .hc-social,.hit-chess-app .hc-draw-controls .hc-draw-reply{background:Canvas!important;color:CanvasText!important;border:1px solid CanvasText!important}
 .hit-chess-app .hc-training-actions button,.hit-chess-app .hc-social button{background:ButtonFace!important;color:ButtonText!important;border:1px solid ButtonText!important}
}

@media(max-width:440px){.hit-chess-app .hc-mode small{font-size:12px}}

/* Chess 1.9: compact, centered study toolbar and accessible curriculum. */
.hit-chess-app .hc-game:has(.hc-training:not([hidden])) .hc-actions{
 width:min(100%,460px);grid-template-columns:repeat(2,minmax(0,1fr));margin-inline:auto;
 position:relative;top:auto;z-index:1;padding:7px;gap:10px;
}
.hit-chess-app .hc-game:has(.hc-training:not([hidden])) .hc-actions button{min-width:0;min-height:54px}
.hit-chess-app .hc-training{text-align:center;margin-inline:auto;width:min(100%,650px)}
.hit-chess-app .hc-training-actions{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:10px}
.hit-chess-app .hc-training-actions button{flex:0 1 auto;min-width:110px;min-height:44px}
.hit-chess-app .hc-track-label{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:10px;font-size:14px;font-weight:700;margin-bottom:12px}
.hit-chess-app .hc-track-label[hidden]{display:none!important}
.hit-chess-app .hc-track-select{max-width:100%;min-height:44px;background:#fffdf8;color:#4b2638;border:1px solid #bfa27c;border-radius:10px;padding:7px 11px;font-weight:650}
.hit-chess-app .hc-training-progress{height:7px;width:min(100%,360px);overflow:hidden;margin:10px auto 16px;border-radius:999px;background:#e5d5bc}
.hit-chess-app .hc-training-progress span{display:block;height:100%;background:#6b3248;border-radius:999px;transition:width .2s ease}
.hit-chess-app .hc-game:has(.hc-training:not([hidden])) .hc-actions button[hidden]{display:none!important}
@media(max-width:520px){
 .hit-chess-app .hc-game:has(.hc-training:not([hidden])) .hc-actions{width:min(100%,390px);padding:6px;gap:7px}
 .hit-chess-app .hc-game:has(.hc-training:not([hidden])) .hc-actions button{font-size:12px;min-height:56px;gap:5px}
 .hit-chess-app .hc-training{padding:12px 9px}
 .hit-chess-app .hc-track-select{width:100%}
 .hit-chess-app .hc-training-actions button{flex:1 1 110px}
}
@media(prefers-reduced-motion:reduce){.hit-chess-app .hc-training-progress span{transition:none}}
@media(forced-colors:active){.hit-chess-app .hc-training-progress{border:1px solid CanvasText}.hit-chess-app .hc-training-progress span{background:Highlight}.hit-chess-app .hc-track-select{background:Field;color:FieldText;border:1px solid CanvasText}}

/* Scoped feedback refresh: flat, quiet, non-overlay notices. Screen-reader
   announcements stay in game.js. No dot, floating shadow, seal or generic stripe. */
.hit-chess-app .hc-toast-region[hidden]{display:none!important}
.hit-chess-app .hc-toast-region{
 position:static!important;inset:auto!important;transform:none!important;
 display:block;width:min(100%,650px)!important;max-width:100%!important;
 max-height:none!important;margin:0 auto 12px!important;
 z-index:auto;pointer-events:auto;direction:rtl;
}
.hit-chess-app .hc-toast{
 position:static;display:flex;align-items:center;justify-content:space-between;
 width:100%;max-height:none;overflow:visible;gap:12px;
 min-height:56px;padding:9px 12px;border:1px solid #c8ad82!important;
 border-radius:12px;background:#fffbf4!important;color:#4a2837;
 box-shadow:none!important;filter:none!important;outline:none;
 line-height:1.55;font-size:14px;
}
.hit-chess-app .hc-toast-seal{display:none!important}
.hit-chess-app .hc-toast-content{flex:1;min-width:0;display:block}
.hit-chess-app .hc-toast-text{font:600 14px/1.55 "Heebo",Arial,sans-serif;color:#462538;overflow-wrap:anywhere}
.hit-chess-app .hc-toast[data-kind="warning"]{background:#fff8ea!important;border-color:#b99458!important}
.hit-chess-app .hc-toast[data-kind="error"],.hit-chess-app .hc-toast[data-kind="check"]{background:#fff4ef!important;border-color:#a64d49!important}
.hit-chess-app .hc-toast[data-kind="success"]{background:#f4f8ef!important;border-color:#738d70!important}
.hit-chess-app .hc-toast[data-kind="turn"],.hit-chess-app .hc-toast[data-kind="info"]{background:#fffbf4!important;border-color:#c8ad82!important}
.hit-chess-app .hc-toast[data-kind="check"] .hc-toast-text{color:#722c34;font-weight:750}
.hit-chess-app .hc-toast-close{
 align-self:center;display:grid;place-items:center;flex:none;
 margin:0!important;padding:0;width:44px!important;height:44px!important;
 min-width:44px;min-height:44px;border:1px solid #dcccb6;
 border-radius:9px;background:#fffdf9;color:#512b3c;font-size:25px;
 box-shadow:none!important;line-height:1;
}
.hit-chess-app .hc-toast-close:hover{background:#f5ebdc;border-color:#bfa17f}
.hit-chess-app .hc-toast-close:focus-visible{outline:3px solid #136cab!important;outline-offset:2px}
@media(max-width:440px){
 .hit-chess-app .hc-toast-region{width:100%!important;margin-bottom:10px!important}
 .hit-chess-app .hc-toast{min-height:52px;padding:7px 8px;gap:7px;border-radius:10px}
 .hit-chess-app .hc-toast-text{font-size:13px;line-height:1.5}
}
@media(forced-colors:active){
 .hit-chess-app .hc-toast{background:Canvas!important;color:CanvasText!important;border:2px solid CanvasText!important;box-shadow:none!important}
 .hit-chess-app .hc-toast-text{color:CanvasText!important}
 .hit-chess-app .hc-toast-close{background:ButtonFace!important;color:ButtonText!important;border:1px solid ButtonText!important}
}


/* Accessible popup feedback (1.5). The toast is viewport-fixed and never
   participates in layout, avoiding chessboard jumps during turn changes. */
.hit-chess-app .hc-toast-region{
 position:fixed!important;inset:auto!important;left:50%!important;right:auto!important;
 bottom:calc(26px + env(safe-area-inset-bottom,0px))!important;
 transform:translateX(-50%)!important;
 width:min(420px,calc(100vw - 32px))!important;max-width:calc(100vw - 32px)!important;
 max-height:min(48dvh,260px)!important;overflow-y:auto!important;
 margin:0!important;z-index:9999!important;pointer-events:none;direction:rtl;
}
.hit-chess-app .hc-toast-region[hidden]{display:none!important}
.hit-chess-app .hc-toast{
 display:flex;align-items:center;justify-content:space-between;width:100%;
 max-height:none;gap:10px;min-height:56px;padding:9px 11px;
 background:#fffcf5!important;border:1px solid #b99c77!important;border-radius:13px;
 color:#462538;box-shadow:none!important;filter:none!important;
 pointer-events:auto;text-align:start;
}
.hit-chess-app .hc-toast[hidden]{display:none!important}
.hit-chess-app .hc-toast-close{flex:none;min-width:44px;min-height:44px}
@media(max-width:600px){
 .hit-chess-app .hc-toast-region{bottom:calc(84px + env(safe-area-inset-bottom,0px))!important;
 width:min(400px,calc(100vw - 24px))!important;max-width:calc(100vw - 24px)!important}
 .hit-chess-app .hc-toast{min-height:54px;padding:8px 10px}
 .hit-chess-app .hc-toast-text{font-size:14px}
}
@media(max-height:470px){.hit-chess-app .hc-toast-region{bottom:calc(10px + env(safe-area-inset-bottom,0px))!important;max-height:36dvh!important}}
@media(forced-colors:active){.hit-chess-app .hc-toast{background:Canvas!important;color:CanvasText!important;border:2px solid CanvasText!important}}
