/* v4 classical shell. Controls/palette/notation reuse the Spark source components.
 * Changed placement follows the current explicit UI contract. */
*{box-sizing:border-box}[hidden]{display:none!important}
html{color-scheme:dark}body.studio{margin:0;background:#0f1419;color:#f4f7fb;font:400 15px/1.5 var(--font-sans);min-height:100vh}
.studio .top{position:relative;inset:auto;min-height:68px;height:68px;display:block;border-bottom:1px solid rgba(255,210,77,.18);background:#0f1419;padding:0}.reserved-brand{height:68px;width:100%}
.site-layout{display:grid;grid-template-columns:148px minmax(0,1fr);gap:20px;padding:18px 24px 0 16px;max-width:1660px;margin:auto}.site-menu{display:flex;flex-direction:column;gap:5px;align-self:start;padding-top:8px}.site-menu details{border-bottom:1px solid #343b46;padding-bottom:12px}.site-menu summary{color:#ffd24d;font-weight:700;padding:10px 8px}.site-menu a{display:block;padding:10px 12px;color:#d7e6f5;border:1px solid transparent;border-radius:8px;text-decoration:none;margin:4px 0}.site-menu a[aria-current="page"]{background:linear-gradient(#3b506b,#2b3c52);border-color:#6a7b94;color:#fff}.site-menu a[aria-disabled="true"]{opacity:.45;pointer-events:none}
.studio main{padding:0;min-width:0;margin:0;width:100%}.studio .play-section{padding:0;background:none;scroll-margin-top:0}.studio .play-shell{display:grid;width:100%;grid-template-columns:minmax(0,var(--studio-board-width,620px)) minmax(360px,460px);gap:24px;justify-content:center;align-items:start}
.play-board-column{min-width:0}.play-frame{position:relative}.studio .play-panel{display:flex;flex-direction:column;min-width:0;min-height:440px;height:var(--panel-height,620px);padding:16px;background:linear-gradient(155deg,#303949 0%,#252d3a 70%,#202733);border:1px solid rgba(255,236,160,.22);border-radius:16px;overflow:visible;gap:10px;box-shadow:inset 0 1px rgba(255,255,255,.1),0 8px 28px rgba(0,0,0,.18)}
.lab-board-frame{margin:0;padding:20px;position:relative}.lab-board-wrap{position:relative;padding:22px}.position-lab-board{position:relative;overflow:hidden;aspect-ratio:1;width:100%}.lab-grid{position:absolute;inset:0;display:grid;grid-template:repeat(8,minmax(0,1fr))/repeat(8,minmax(0,1fr));touch-action:none}.lab-square{position:relative;padding:0;border:0;border-radius:0;min-height:0;min-width:0}.lab-square.light{background:var(--board-light)}.lab-square.dark{background:var(--board-dark)}.lab-square.is-from.light,.lab-square.is-to.light{background:#d2cc8b!important}.lab-square.is-from.dark,.lab-square.is-to.dark{background:#969d6b!important}.lab-square.is-from,.lab-square.is-to{box-shadow:inset 0 0 0 1px rgba(92,104,61,.18)!important}.lab-square.is-selected{box-shadow:inset 0 0 0 3px #4b967d!important}.lab-square::before,.lab-square::after{content:none!important}
.lab-pieces{position:absolute;inset:0;pointer-events:none}.lab-piece{position:absolute;width:12.5%;height:12.5%;top:0;left:0;display:grid;place-items:center;pointer-events:none;z-index:3}.lab-piece img{width:80%;height:80%;object-fit:contain;filter:drop-shadow(0 2px 1px rgba(0,0,0,.7))}.lab-piece.is-dragging{z-index:10;filter:drop-shadow(0 8px 8px rgba(0,0,0,.45))}.position-lab-board.is-black{transform:rotate(180deg)}.position-lab-board.is-black .lab-piece img{transform:rotate(180deg)}
.lab-coords-files{position:absolute;display:grid;grid-template-columns:repeat(8,1fr);left:22px;right:22px;bottom:6px;text-align:center;pointer-events:none;font-size:11px}.lab-coords-ranks{position:absolute;display:grid;grid-template-rows:repeat(8,1fr);left:6px;top:22px;bottom:22px;width:14px;text-align:center;font-size:11px;pointer-events:none}.lab-coords-ranks span{display:grid;place-items:center}
/* Source Spark satin selection / graphite player button depth. */
.studio .button,.studio .demo-control{min-height:40px;padding:9px 14px;border:1px solid #647083;border-radius:9px;background:linear-gradient(180deg,#424c5e,#2b3343);color:#f4f7fb;box-shadow:inset 0 1px rgba(255,255,255,.18),inset 0 -1px rgba(0,0,0,.2),0 3px 0 rgba(4,13,26,.6);font:700 .87rem/1.25 var(--font-sans);cursor:pointer;text-decoration:none;text-align:center;transition:filter 220ms var(--ease),border-color 220ms var(--ease),transform 220ms var(--ease),box-shadow 220ms var(--ease)}.studio .button:hover,.studio .demo-control:hover{filter:brightness(1.13);border-color:#d8b764;color:#fff}.studio .button:active,.studio .demo-control:active{transform:translateY(2px);box-shadow:inset 0 1px rgba(255,255,255,.1),0 1px 0 rgba(4,13,26,.6)}.studio .button.gold{border-color:#ffe99a;background:linear-gradient(135deg,#ffeca0,#ffd24d);color:#191709;box-shadow:inset 0 1px rgba(255,255,255,.65),inset 0 -2px rgba(189,135,27,.22),0 3px 0 #8f6a1f;min-height:44px}.button:disabled,.demo-control:disabled{opacity:.42;cursor:default}.studio :is(button,input,textarea,summary,a):focus-visible{outline:2px solid #ffd24d;outline-offset:3px}.studio :is(input[type=checkbox],input[type=radio]){accent-color:#f2e7c2;width:16px;height:16px}
.form-field{display:grid;gap:6px;margin-bottom:12px}.form-field>label,.form-field legend{font-size:.8rem;font-weight:750;color:#eee1bc}select,input[type=text],input[type=number],textarea{min-width:0;width:100%;padding:9px 11px;border:1px solid #d7cea9;border-radius:9px;background:linear-gradient(#fff7e2,#efe3bc);color:#1e2a38;font:inherit}input[type=range]{accent-color:#63e69a;width:100%;padding:0;min-height:18px}select option{background:#fff7e2;color:#1e2a38}
.play-setup{display:flex;flex-direction:column;flex:1;gap:0}.play-setup h1{font-family:var(--font-display);font-size:1.75rem;margin:0 0 16px}.form-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}.play-setup>.form-row{grid-template-columns:1fr}.play-choice{min-width:0}.play-choice button{min-width:0;padding:6px 8px;white-space:normal;box-shadow:inset 0 1px rgba(255,255,255,.12),0 2px 0 rgba(4,13,26,.45)}.clock-presets{display:flex;flex-wrap:wrap;gap:5px;margin:8px 0 0}.clock-presets button{min-height:27px;border:1px solid #667184;border-radius:6px;background:#39475b;color:#eef4fb;font-size:.76rem;padding:3px 7px;transition:background 200ms var(--ease),color 200ms var(--ease)}.clock-presets button.is-active{background:#f2e7c2;color:#1e2a38}.play-setup-actions{margin-top:auto}
.studio #game-panel,.studio #analysis-panel{overflow:visible;min-width:0}.studio .play-score{display:flex;flex-direction:column;flex:1;min-height:120px;grid-template:none;margin:0;overflow:hidden;border:1px solid rgba(255,236,160,.19);border-radius:11px;background:rgba(7,17,29,.28)}.studio .play-score .play-players{flex:none;grid-template-columns:36px minmax(0,1fr) minmax(0,1fr)}.play-player{padding:8px;gap:6px}.play-player strong{font-size:.84rem;line-height:1.3}.play-player img{width:23px;height:23px}.play-player time{display:block;color:#fff7e2;font-weight:750;font-variant-numeric:tabular-nums;white-space:nowrap;font-size:1rem}.notation{flex:1;min-height:0;overflow:auto;font-variant-numeric:tabular-nums}.notation-empty{padding:12px;color:#c8d4e2;font-size:.85rem}.studio #play-notation{width:100%;flex:1;align-self:stretch}.studio #play-notation .lab-score-row{grid-template-columns:36px minmax(0,1fr) minmax(0,1fr);width:100%}.lab-score-row>span{padding:5px 8px}.play-move,.lab-analysis-move{font:inherit}
.navigation{display:grid;grid-template-columns:34px repeat(4,minmax(0,50px)) 34px;justify-content:center;gap:6px;margin:2px 0 0}.studio .navigation :is(button,.spark-tool){width:100%;height:34px;min-height:34px;padding:4px;font-size:1rem;border-radius:8px}.navigation svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:2.1;stroke-linecap:round}.navigation-menu[aria-disabled=true]{cursor:default;color:#d2d9e3}.studio .navigation .spark-tool.is-flip{background:linear-gradient(#424c5e,#2b3343);border-color:#647083;box-shadow:inset 0 1px rgba(255,255,255,.18),0 3px 0 rgba(4,13,26,.6)}
/* Plugin ensureHint / renderPvLines palette and full-width table, embedded in the panel. */
.training-card{border:1px solid #729a86;border-radius:11px;background:rgba(13,16,22,.86);padding:11px 13px;box-shadow:0 3px 12px rgba(0,0,0,.18)}.training-title{display:flex;justify-content:space-between;align-items:center;gap:10px;font-weight:750;color:#eee1bc;font-size:.87rem}.training-title small{display:block;color:#c8d4e2;font-size:.74rem;font-weight:500}.training-lines{margin-top:8px;min-height:29px;color:#c8d4e2;transition:opacity 220ms var(--ease)}.training-hints{border-collapse:collapse;width:100%;font-size:.94rem;line-height:1.65;table-layout:auto}.training-hints td{padding:3px 7px 3px 0;white-space:nowrap}.training-hints td:first-child{color:#e6c46d;font-size:.8rem;font-weight:700;width:1%}.training-hints td:nth-child(2){color:#bdc7d7;font-size:.8rem;width:1%}.training-hints td:last-child{font-weight:700;text-align:left;padding-right:0}.training-hints img{width:1.15em;height:1.15em;object-fit:contain;vertical-align:-.16em;margin-right:.25em;filter:drop-shadow(0 1px 1px #000)}.training-hints [data-tone=good]{color:#83e5a3}.training-hints [data-tone=bad]{color:#ffada6}.training-hints [data-tone=neutral]{color:#e6eaf2}.training-options{margin-top:7px;padding-top:7px;border-top:1px solid rgba(255,236,160,.15);font-size:.78rem;color:#c8d4e2}.training-options summary{cursor:pointer}.training-options :is(label,.option-row){display:grid;grid-template-columns:74px minmax(0,1fr);align-items:center;gap:8px;margin:9px 0 0}.training-options .play-choice{padding:3px;gap:4px}.training-options .play-choice button{min-height:30px;font-size:.76rem;padding:5px}.training-options input[type=hidden]{display:none}
.game-result{padding:10px;border-top:1px solid rgba(255,236,160,.2);text-align:center;color:#fff7e2}.game-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}.status{font-size:.79rem;color:#c8d4e2;margin:0;min-height:0}.status:empty{display:none}.error-banner{border-left:3px solid #ff8178;color:#ffb8b3;padding:8px 12px;margin:0 0 10px}
.studio .lab-analysis-record{display:flex;flex-direction:column;min-height:0;flex:1;height:auto}.studio .lab-analysis-workspace{display:flex;flex:1;min-height:0;max-height:none;height:auto;min-width:0}.studio .lab-analysis-score{flex:1;min-height:90px;margin:10px 0 0;display:flex;flex-direction:column;max-height:none;height:auto}.lab-score-body{overflow:auto;flex:1;min-height:0;min-width:0}.lab-analysis-io{padding:12px;display:grid;gap:12px}.spark-engine{margin-bottom:0;min-width:0}.spark-engine-head{gap:8px;padding-left:9px;flex-wrap:wrap}.spark-engine-switch b{font-size:.83rem}.spark-engine-switch span{width:40px;height:24px}.spark-engine-switch span::after{width:16px;height:16px}.spark-engine-switch input:checked+span::after{transform:translateX(16px)}.spark-engine-eval{font-size:.78rem!important;color:#e7c976!important;line-height:1.3;white-space:normal;flex:1;min-width:100px!important}.spark-engine-state{font-size:.68rem;padding:4px 7px}.spark-engine-icon{width:30px;height:30px}.spark-engine-settings{max-width:100%;width:330px}.spark-engine-settings label{grid-template-columns:100px minmax(0,1fr) 45px;gap:8px}.lab-score-head{grid-template-columns:36px minmax(0,1fr) minmax(0,1fr)}.lab-score-head span{min-width:0;font-size:.78rem;overflow-wrap:anywhere}.lab-analysis-variation{font-size:.83rem;min-width:0}.spark-variation-line{padding:4px 6px 4px calc(var(--depth,1)*10px);min-width:0}.spark-variation-actions{flex-wrap:wrap}.spark-engine-moves{max-width:100%}
/* Existing Spark pieces/tools relocated to right, two full rows. */
.studio[data-page=editor] .play-panel{height:auto;min-height:var(--panel-height,620px)}.studio .lab-editor{padding:0;margin:0;min-width:0;display:flex;flex-direction:column;gap:9px}.editor-palette{display:grid;gap:6px}.studio .lab-editor-piece-dock.is-black,.studio .lab-editor-piece-dock.is-white{width:100%;margin:0;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;padding:5px 6px;border:1px solid rgba(255,236,160,.2);border-radius:10px;background:rgba(8,18,29,.4)}.studio .lab-editor-piece-dock .lab-piece-row{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:4px}.studio .lab-editor-piece-dock .lab-piece-row button,.studio .lab-editor-piece-dock .lab-editor-tools button{min-width:0;min-height:35px;height:35px;padding:2px;border:1px solid #738297;border-radius:7px;background:linear-gradient(#3b506b,#2b3c52);box-shadow:inset 0 1px rgba(255,255,255,.12),0 2px 0 rgba(4,13,26,.5);transition:background 220ms var(--ease),border-color 220ms var(--ease)}.studio .lab-editor-piece-dock .lab-piece-row img{width:31px;height:31px;max-width:100%;object-fit:contain}.studio .lab-editor-piece-dock .lab-editor-tools{display:grid;grid-template-columns:32px 32px;gap:4px;margin:0}.studio .lab-editor-tools button{color:#f4f7fb}.studio .lab-editor-piece-dock button.is-active{border-color:#fff7e2;background:linear-gradient(#fff7e2,#e2d5a8);color:#1e2a38;box-shadow:inset 0 0 0 1px #fff7e2,0 2px 0 rgba(4,13,26,.5)}.editor-fen-status{font-size:.75rem;color:#ffcf8b;line-height:1.35;margin:0}.editor-fen-status:empty{display:none}.studio .lab-fen-editor{margin:0}.studio .lab-fen-editor>label{font-size:.8rem;color:#eee1bc;font-weight:750}.studio .lab-fen-editor input{padding:9px;border:1px solid rgba(255,236,160,.3);border-radius:9px;background:linear-gradient(#232833,#1a1e26);color:#f7faff;font:400 .74rem/1.4 ui-monospace,SFMono-Regular,Consolas,monospace;letter-spacing:-.018em}.studio .lab-fen-editor>div{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:7px}.studio #editor-copy,.studio #editor-paste{background:linear-gradient(#fff7e2,#e2d5a8);color:#1e2a38;border-color:#fff7e2;min-height:35px;padding:7px;font-size:.8rem}.studio .lab-editor .form-field{margin:0}.castling{display:grid;grid-template-columns:1fr 1fr;gap:6px}.castling label{display:flex;align-items:center;gap:6px;font-size:.78rem}.editor-counters{display:grid;grid-template-columns:1fr;gap:9px}.editor-counters label{font-size:.8rem;line-height:1.35;min-height:0}.editor-counters input{width:100%;max-width:100px;min-height:35px;padding:6px 9px;font-size:.85rem}.studio .lab-editor-commands{display:grid;grid-template-columns:1fr;gap:8px;margin-top:3px}.editor-board-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}.studio .lab-editor-commands .button{min-height:35px;padding:7px;font-size:.78rem}.studio .lab-editor-commands .gold{min-height:40px}
.studio-board-resize{display:none}@media(min-width:901px) and (min-height:601px){.studio-board-resize{display:block;position:absolute;right:0;bottom:0;z-index:5;width:30px;height:30px;padding:0;border:0;border-radius:3px;background:transparent;color:#ffd24d;cursor:nwse-resize;touch-action:none}.studio-board-resize::before,.studio-board-resize::after{content:'';position:absolute;height:2px;background:currentColor;transform:rotate(-45deg);border-radius:1px}.studio-board-resize::before{width:14px;right:3px;bottom:8px}.studio-board-resize::after{width:8px;right:3px;bottom:4px}.is-board-resizing,.is-board-resizing *{cursor:nwse-resize!important;user-select:none!important}}
@media(max-width:1200px){.site-layout{grid-template-columns:110px minmax(0,1fr);gap:12px;padding:14px 12px}.studio .play-shell{grid-template-columns:minmax(0,var(--studio-board-width,430px)) minmax(340px,400px);gap:18px}.studio .play-panel{padding:12px}.studio .lab-editor-piece-dock .lab-editor-tools{grid-template-columns:29px 29px}.studio .lab-editor-piece-dock .lab-piece-row{gap:3px}}
@media(max-width:900px){.site-layout{grid-template-columns:100px minmax(0,1fr);gap:12px;padding:14px 12px}.studio .play-shell{grid-template-columns:minmax(0,1fr);gap:18px;max-width:620px;margin:auto}.studio .play-panel,.studio[data-page=editor] .play-panel{height:auto;min-height:0}.studio #game-panel,.studio #analysis-panel{min-height:440px!important}.notation,.lab-score-body{max-height:400px;min-height:160px}.studio-board-resize{display:none}}
@media(max-width:600px){.site-layout{display:block;padding:8px 12px}.site-menu{padding:0;margin-bottom:12px;font-size:.8rem}.site-menu details{display:flex;padding:0;border:0}.site-menu summary{padding:0 0 5px;color:#ffd24d;font-size:.76rem}.site-menu a{display:inline-block;margin:0 5px 0 0;padding:6px 13px}.studio .top,.reserved-brand{height:50px;min-height:50px}.lab-board-frame{padding:8px;border-radius:12px}.lab-board-wrap{padding:16px}.lab-coords-files{left:16px;right:16px;bottom:3px;font-size:9px}.lab-coords-ranks{top:16px;bottom:16px;left:1px;font-size:9px}.studio .play-panel{padding:12px;border-radius:12px}.play-setup h1{font-size:1.4rem}.spark-engine-head{gap:7px}.spark-engine-eval{font-size:.7rem!important}.spark-engine-state{font-size:.66rem}.spark-engine-settings label{grid-template-columns:90px minmax(0,1fr) 40px;font-size:.78rem}.play-player strong{font-size:.78rem}.play-player img{width:19px;height:19px}.play-player{padding:6px;gap:4px}.navigation{gap:5px;grid-template-columns:32px repeat(4,minmax(0,43px)) 32px}.studio .lab-editor-piece-dock .lab-editor-tools{grid-template-columns:30px 30px}.studio .lab-editor-piece-dock .lab-piece-row img{width:28px;height:28px}.training-hints{font-size:.87rem}.training-options :is(label,.option-row){grid-template-columns:66px minmax(0,1fr)}.editor-counters{gap:7px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition:none!important;animation:none!important}}

/* Exact latest live Spark site-hero.css:1401–1422,1693–1702,1790–1796.
   P-393 cream background keeps black fills and white outlines visible. */
.studio .lab-editor-piece-dock .lab-piece-row button{display:grid;place-items:center;padding:0;border:1px solid rgba(0,0,0,.4);background:#E9DDB4;box-shadow:inset 0 1px rgba(255,255,255,.2),inset 0 -2px rgba(0,0,0,.18),0 3px 0 rgba(4,13,26,.72),0 7px 14px rgba(0,0,0,.2)}
.studio .lab-editor-piece-dock .lab-piece-row button:hover{background:#F4EBCC}
.studio .lab-editor-piece-dock .lab-piece-row button.is-active{border:2px solid #FFD24D;background:#F4EBCC;box-shadow:0 0 0 1px rgba(255,210,77,.4),0 0 14px rgba(255,210,77,.45)}
.studio .lab-editor-piece-dock .lab-editor-tools button{display:grid;place-items:center;padding:0;border:1px solid rgba(157,213,255,.35);background:#2F4763;color:#E9F3FF;box-shadow:inset 0 1px rgba(255,255,255,.2),inset 0 -2px rgba(0,0,0,.18),0 3px 0 rgba(4,13,26,.72),0 7px 14px rgba(0,0,0,.2)}
.studio .lab-editor-piece-dock .lab-editor-tools button:hover{background:#3B587A}
.studio .lab-editor-piece-dock .lab-editor-tools button.is-active{border:2px solid #FFD24D;background:#3B587A;box-shadow:0 0 0 1px rgba(255,210,77,.4),0 0 14px rgba(255,210,77,.45)}
.studio .lab-editor-piece-dock .lab-editor-tools [data-tool=trash]{color:#FF8B82}
.studio .lab-editor-piece-dock .lab-editor-tools [data-tool=trash]:hover{color:#FFB3AC}
.studio .lab-editor-piece-dock .lab-editor-tools [data-tool=trash].is-active{border-color:#D9463C;background:#3A2126;color:#FFB3AC;box-shadow:0 0 0 1px rgba(217,70,60,.4),0 0 14px rgba(217,70,60,.4)}
.studio .lab-tool-icon{margin:0}

/* Tooltips remain within the panel instead of creating invisible overflow. */
.spark-engine-icon.is-gear[data-tip]::after{left:auto;right:0;transform:translateY(-4px)}
.spark-engine-icon.is-gear[data-tip]:hover::after,.spark-engine-icon.is-gear[data-tip]:focus-visible::after{transform:translateY(0)}

/* Plugin ensureHint uses userSelect:none. Hints are read-only output, not fields. */
.training-lines,.training-hints,.training-hints *{cursor:default;user-select:none}

/* Semantic cursor family: read-only output has no editing affordance.
   Actual fields and interactive move buttons keep their normal cursors/focus. */
:is(.spark-engine-eval,.spark-engine-state,.spark-engine-line>b,.engine-credit,.play-player,.lab-score-head,.lab-score-row>span:first-child,.status,.play-fen-status,.play-fen-note,.lab-analysis-data summary small){cursor:default}

@media(max-width:520px){.spark-engine-settings{width:auto;max-width:none;border-radius:16px 16px 0 0;box-shadow:0 0 0 100vmax rgba(4,10,20,.6),0 -10px 30px rgba(0,0,0,.5)}}

@media(pointer:coarse){.lab-grid{touch-action:pan-y}.lab-square[data-occupied=true]{touch-action:none}}

:is(.notation-empty,.game-result,.training-title span,.training-title small,.editor-fen-status,.lab-coords-files,.lab-coords-ranks,.range-label output,.play-no,.lab-score-row>span:not(:has(button))){cursor:default}

/* Coarse-pointer landscape keeps the whole square board in view. Source
   responsive composition is adapted to the available height; panel uses page flow. */
@media(pointer:coarse) and (min-width:601px) and (max-height:520px){
 .site-layout{grid-template-columns:80px minmax(0,1fr);gap:12px;padding:8px 12px}
 .studio .play-shell{grid-template-columns:minmax(260px,calc(100vh - 92px)) minmax(300px,1fr);max-width:none;gap:14px}
 .lab-board-frame{padding:8px}.lab-board-wrap{padding:16px}
 .lab-coords-files{left:16px;right:16px;bottom:3px;font-size:9px}.lab-coords-ranks{top:16px;bottom:16px;left:1px;font-size:9px}
 .studio .play-panel{padding:12px}.site-menu a{padding:8px 7px}
}

/* v5 F01: editor uses intrinsic content size, unlike fixed notation panels. */
.studio[data-page=editor] .play-panel{contain:layout style}
.studio[data-page=game] .play-panel{height:auto;min-height:max(440px,var(--panel-height,620px));align-self:start;contain:layout style}.studio #game-panel .play-score{max-height:420px}
/* Source play.css play-in for new hint output; generated lines never take focus. */
.training-lines.is-entering{animation:play-in 260ms var(--ease) backwards}

/* Latest author feedback: a bright warm workspace with the Spark gold/cream
   controls, slate accents and readable navy type. */
.studio .play-player img{padding:2px;border:1px solid #a89064;border-radius:4px}
.studio .training-hints td:nth-child(3){text-align:left;font-weight:700}
.studio .training-hints td:last-child{text-align:right;padding-left:3px;font-variant-numeric:tabular-nums}
.studio .training-hints img{border:1px solid #a58f60;border-radius:4px;padding:1px;filter:none;width:1.25em;height:1.25em}
.studio :is(.training-options,.premove-options){border-top:1px solid #cbb98f}
.premove-options{margin-top:7px;padding-top:7px;font-size:.78rem}.premove-options summary{cursor:pointer}.premove-options :is(label,.option-row){display:grid;grid-template-columns:90px minmax(0,1fr);align-items:center;gap:8px;margin-top:8px}.premove-options .play-choice button{font-size:.76rem;min-height:30px;padding:5px}
/* Ready Spark crown correction, adapted to this board id. */
#chess-board.is-black .lab-target-marker.is-promotion{transform:translate(-50%,-50%) rotate(180deg)}
#chess-board.is-black .lab-square[data-occupied=true] .lab-target-marker.is-promotion{left:4%;bottom:4%;right:auto;top:auto;transform:rotate(180deg)}
/* Lichess queued origin/destination remain distinguishable from last move. */
.studio :is(input,textarea)::placeholder{opacity:1}
.studio .lab-editor{background:transparent;border:0;box-shadow:none}
/* Curator whole-view correction: cream copy/paste needs separation from the
   newly light panel, so these actions share the raised slate-blue family. */
/* Disabled remains readable without using the active action palette. */
.studio .play-panel .button[disabled],.studio .navigation .demo-control[disabled],.studio .lab-fen-editor :is(#editor-copy,#editor-paste)[disabled]{opacity:1;cursor:default;filter:none}

/* v6 disabled navigation keeps readable words rather than fading the link. */
.site-menu a[aria-disabled=true]{opacity:1;cursor:default}

/* v6 design: muted sage/slate surfaces harmonize with the approved board.
   Board colors and piece SVGs are deliberately kept exact. */
.studio .play-panel{position:relative}
.studio :is(.play-move,.lab-analysis-move,.lab-score-move,.lab-score-move.is-regular,.spark-variation-move,.spark-variation-line){opacity:1}
.studio :is(.play-move,.lab-analysis-move).is-current{font-weight:850}
.studio #lab-analysis-notation .lab-analysis-move{opacity:1;padding:1px 4px}
.studio .training-title{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:7px;font-size:1rem}.training-purpose{font-size:.8rem;line-height:1.35;margin:2px 0 7px}
.studio .training-lines{margin-top:6px;height:calc(var(--hint-lines,1)*32px);min-height:32px;transition:height 220ms var(--ease);overflow:hidden}
.studio .training-hints{table-layout:fixed;font-size:.93rem;line-height:1.6}
.studio .training-hints tr{height:32px}.studio .training-hints td{height:32px;vertical-align:middle;transition:color 220ms var(--ease)}
.studio .training-hints td:first-child{width:24px}.studio .training-hints td:nth-child(2){width:38px}.studio .training-hints td:last-child{width:80px;text-align:right}
.studio .training-options h2,.studio .premove-options h2{font-size:.9rem;margin:8px 0}
.studio .game-settings{right:12px;top:12px;width:calc(100% - 24px);max-width:420px;z-index:35}
.studio .game-settings .option-row{display:grid;grid-template-columns:92px minmax(0,1fr);gap:8px;align-items:center;margin:10px 0}
.studio .game-settings .option-row>span{font-weight:700;line-height:1.35}
.studio .game-settings input[type=hidden]{display:none}
.studio .navigation{width:100%;grid-template-columns:repeat(5,minmax(44px,1fr));justify-content:stretch;gap:6px}
.studio .navigation :is(button,.spark-tool){min-width:44px;min-height:44px;height:44px;font-size:1.15rem;padding:7px}
.navigation svg{width:23px;height:23px}
@media(max-width:520px){.studio .game-settings{position:fixed;right:0;left:0;top:auto;bottom:0;width:auto;max-width:none;padding-bottom:calc(18px + env(safe-area-inset-bottom));z-index:60}.studio .training-title{font-size:.93rem}}

/* B7 trial: matte olive surroundings, same approved board and piece assets. */
.studio .spark-engine-settings{padding-top:0;overflow:hidden}
.studio .spark-engine-settings-head{border-bottom:1px solid #6a8872;margin:0 -16px 12px;padding:10px 16px;min-height:49px}
.studio .spark-engine-settings-head strong{font-size:1.12rem;line-height:1.3}
/* Orientation changes are atomic at Spark's edge-on midpoint; no nested CSS turn. */
#chess-board,#chess-board .lab-piece,#chess-board .lab-piece img{transition:none}
.game-undo{display:grid;gap:5px}.studio #undo-move{display:flex;align-items:center;justify-content:center;gap:9px;min-height:44px;width:100%}
#undo-move svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.undo-note{margin:0;color:#394d55;font-size:.75rem;line-height:1.35}
.studio .lab-score-result{color:#193d48}
@media(max-width:520px){.studio .spark-engine-settings-head{margin-left:-20px;margin-right:-20px;padding-left:20px;padding-right:20px}}

/* v10 common mode/header/action/field contracts. The approved board is intact. */
.mode-heading{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;background:#9eaf98;border:1px solid #7d9277;border-radius:10px;padding:9px 10px;color:#243e2d;flex:none;box-shadow:inset 0 1px #d1dbc8}
.mode-heading h1{font:750 1.3rem/1.2 var(--font-display);margin:0;text-align:center;color:#243e2d}
.mode-navigation-tools{display:grid;grid-template-columns:repeat(6,minmax(44px,1fr));align-items:center;gap:6px;flex:none}.studio .mode-navigation-tools .navigation{display:contents;margin:0}.studio .mode-navigation-tools #flip-board{width:100%;min-width:44px}
.studio #flip-board{width:44px;height:44px;min-width:44px;min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:7px;background:linear-gradient(#4a6c8b,#314e69);border:1px solid #274861;box-shadow:inset 0 1px #ffffff55,0 3px 0 #1d3449;color:#fff;padding:7px}
#flip-board svg{width:23px;height:23px;flex:none;fill:none;stroke:currentColor;stroke-width:2;stroke-linejoin:round;stroke-linecap:round}.flip-label{display:none}
.studio #editor-panel #flip-board{width:100%;grid-column:1/-1;font:650 .85rem/1.2 var(--font-sans)}#editor-panel .flip-label{display:inline}
.studio #flip-board:disabled{background:#e2e5e7;color:#4b5863;border-color:#aab3ba;box-shadow:inset 0 1px #fff,0 2px 0 #b2bac0;cursor:default}.route-pending #chess-board{pointer-events:none}
.studio .training-title{background:#adbea4;border-bottom:1px solid #8ba180;margin:-11px -13px 9px;padding:9px 12px;border-radius:10px 10px 0 0;align-items:center;flex-wrap:nowrap;gap:8px}.studio .spark-engine-head{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;background:#adbea4;border-bottom:1px solid #8ba180;padding:9px 10px;gap:6px}
.studio .spark-engine-head .spark-engine-switch{grid-column:1;grid-row:1}.studio .spark-engine-head .spark-engine-eval{grid-column:2;grid-row:1;min-width:0!important;overflow-wrap:anywhere}.studio .spark-engine-head .is-gear{grid-column:3;grid-row:1;margin:0}.studio .spark-engine-head .spark-engine-state{grid-column:1/3;grid-row:2;justify-self:start}.studio .spark-engine-head .is-extend{grid-column:3;grid-row:2}
.studio[data-page=analysis] .play-panel{height:auto;min-height:var(--panel-height,620px);align-self:start;contain:layout style}.studio #analysis-panel{display:flex;flex-direction:column;flex:1 0 auto;min-height:calc(var(--panel-height,620px) - 94px);gap:8px}.studio .lab-analysis-score{min-height:110px}.studio .lab-score-body{min-height:68px}
.studio .spark-engine-eval{font-size:.83rem!important;font-weight:750;color:#294832!important;text-align:center}.studio .spark-engine-state{font-size:.72rem;color:#304e39}
.training-meta{display:flex;justify-content:space-between;align-items:center;gap:8px;color:#304c39}.training-meta strong{font-size:.78rem;line-height:1.35;white-space:nowrap}.training-meta .training-purpose{font-size:.74rem;margin:0;text-align:right;color:#3a5140}
.studio .training-hints td:nth-child(2){font-weight:650;color:#30473c}.studio .training-hints td:first-child{font-weight:750;color:#30473c}
.studio .setup-editor-action{margin-top:10px;width:100%;min-height:42px}
.studio .short-field{display:grid;grid-template-columns:max-content max-content;align-items:center;justify-content:center;gap:12px;padding:5px 8px;color:#304b38}.short-field>span{font-size:.83rem;font-weight:750}.short-field input[type=hidden]{display:none}
.studio .editor-counters .form-field{display:grid;grid-template-columns:minmax(0,1fr) 12ch;align-items:center;gap:12px}.studio .editor-counters input{max-width:none;width:12ch;min-width:12ch;font-variant-numeric:tabular-nums;text-align:center}.studio .editor-counters #editor-ep{width:5ch;min-width:5ch;justify-self:end}
.studio .lab-fen-editor>label{display:block;margin-bottom:7px}.studio .lab-fen-editor{padding:5px 0}
.studio .lab-editor-commands{grid-template-columns:1fr 1fr;gap:9px}.editor-board-actions{grid-column:1/-1}.studio #editor-panel :is(.lab-editor-commands .button,#editor-copy,#editor-paste){min-height:44px;height:44px;padding:6px 8px;font-size:.83rem;line-height:1.2;display:inline-flex;align-items:center;justify-content:center}
.site-menu a[aria-disabled=true]{background:transparent;border-color:transparent;opacity:.55;color:#344d3e}
.studio .game-result{display:flex;flex-direction:column;align-items:center;gap:3px;padding:10px 12px;background:#b9c9ab;border-top:2px solid #829771;color:#354620}
.game-result strong{font:850 1.55rem/1.2 var(--font-display);font-variant-numeric:tabular-nums}.game-result span{font-size:.87rem;font-weight:750;color:#354620}
.studio .lab-score-result{font-weight:850;font-size:1.15rem;color:#334321;background:#b9c9ab;padding:8px}
.studio :is(.training-meta,.engine-identity,.engine-build,.mode-role,.mode-variant,.game-result,.status){cursor:default}
@media(max-width:600px){.site-menu details{display:block}.site-menu a{margin:3px 2px 0 0;padding:7px 10px}.mode-heading{gap:8px;padding:8px}.mode-heading h1{font-size:1.2rem}.studio .training-title{margin-left:-13px;margin-right:-13px}.lab-analysis-io{padding:12px}}
