/* V0.580 — board-first presentation. Scope to Block Puzzle only. */
.bp580-page{max-width:1220px;--bp-board:#141d3a;--bp-cell:#28375a;--bp-block:#7462f1;--bp-block-hi:#a296ff;--bp-preview:#56dbb6;--bp-clear:#ffcf70}
.bp580-page .bp322-title{display:flex;align-items:center;justify-content:space-between;gap:22px;margin:8px 0 10px;padding:13px 22px;border:1px solid #dddff0;border-radius:24px;background:linear-gradient(125deg,#fff 0%,#f3f1ff 70%,#e9f1ff 100%)}
.bp580-page .bp322-title h1{font-size:clamp(1.7rem,2.4vw,2.4rem);line-height:1.04;margin:0 0 5px;letter-spacing:-.055em}
.bp580-page .bp322-title h1 small{display:inline;font-size:.34em;letter-spacing:0;font-weight:750;color:#65628f;margin-left:8px}
.bp580-page .bp322-title .eyebrow{font-size:.64rem;color:#61539d;letter-spacing:.13em;font-weight:900}
.bp580-page .bp322-title p{font-size:.79rem;max-width:730px;line-height:1.32;color:#5f687a;margin:3px 0 0}
.bp580-page .bp322-scorebox{flex-shrink:0;min-width:142px;border:none;border-radius:17px;background:#201a49;color:#fff;text-align:left;padding:12px 17px;box-shadow:0 8px 22px #241e5330}
.bp580-page .bp322-scorebox small{color:#ada5ea;font-weight:800;letter-spacing:.08em}
.bp580-page .bp322-scorebox strong{color:#fff;font-variant-numeric:tabular-nums;font-size:2.1rem}
.bp580-page .bp322-scorebox span{color:#c7c2e7}
.bp580-page .bp322-modes{margin:0 0 7px;gap:7px}
.bp580-page .bp322-modes button{border-radius:10px;padding:7px 13px;font-size:.81rem;min-height:34px}
.bp580-page .bp322-modes button.active{background:#242047;color:#fff;box-shadow:0 3px 10px #25204d1f}
.bp580-page .bp322-game-card{padding:12px;background:linear-gradient(135deg,#fff,#f8f9ff);border:1px solid #e1e4f0;border-radius:23px;box-shadow:0 14px 34px #2734510e}
.bp580-page .bp322-strip{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:0 3px 10px}
.bp580-page .bp322-state-main strong{font-size:1.03rem;color:#272047}
.bp580-page .bp322-state-main small{font-size:.72rem;color:#737991}
.bp580-page .bp322-live{gap:6px}
.bp580-page .bp322-live span{min-width:61px;border:none;background:#edeffe;padding:6px 9px;border-radius:11px}
.bp580-page .bp322-live small{font-size:.62rem;color:#73709a}
.bp580-page .bp322-live b{font-size:1.04rem;color:#30295f}
.bp580-page .bp322-stage{display:grid;grid-template-columns:minmax(0,1fr) 205px;gap:12px;margin-top:9px;align-items:start}
.bp580-page .bp322-play{display:grid;grid-template-columns:minmax(0,1fr) 170px;grid-template-rows:31px 1fr auto;grid-template-areas:'board label' 'board tray' 'board actions';align-items:stretch;column-gap:14px;row-gap:8px;min-width:0}
.bp580-page .bp322-board-shell{grid-area:board;width:min(100%,450px);max-width:450px;justify-self:center;margin:0}
.bp580-page .bp322-board{padding:9px;gap:4px;border-radius:20px;box-shadow:0 12px 32px #151f3840,0 0 0 5px #f0efff}
.bp580-page .bp322-cell{border-radius:7px;touch-action:none}
.bp580-page .bp322-tray-label{grid-area:label;margin:0;display:block;width:100%;align-self:end;letter-spacing:.08em;font-size:.66rem;color:#3f3763}
.bp580-page .bp322-tray-label small{display:block;margin-top:3px;font-size:.64rem}
.bp580-page .bp322-tray{grid-area:tray;display:flex;flex-direction:column;align-self:stretch;justify-content:center;min-height:0;width:100%;gap:9px;margin:0}
.bp580-page .bp322-piece{flex:1 1 0;min-height:82px;padding:6px;border:1px solid #dddff0;background:#fff;border-radius:15px;box-shadow:0 5px 10px #1b20400d}
.bp580-page .bp322-piece.selected{background:#f3f0ff;border-color:#8c73ef;box-shadow:0 0 0 3px #8c73ef23,0 8px 14px #1b204018}
.bp580-page .bp322-mini{grid-template-columns:repeat(var(--mw),15px);grid-template-rows:repeat(var(--mh),15px);gap:2px}
.bp580-page .bp322-mini i{width:15px;height:15px;border-radius:4px}
.bp580-page .bp322-primary-actions{grid-area:actions;display:grid;grid-template-columns:1fr 1fr;gap:6px;width:100%;margin:0}
.bp580-page .bp322-primary-actions button{min-height:38px;font-size:.75rem;padding:4px 2px;border-radius:10px}
.bp580-page .bp322-side{gap:8px}
.bp580-page .bp322-run-card,.bp580-page .bp322-next-card,.bp580-page .bp322-tools,.bp580-page .bp322-tip{padding:10px;border-radius:14px;border-color:#e0e1f1}
.bp580-page .bp322-tools button{font-size:.72rem}
.bp580-page .bp322-tip{background:#eeefff}
.bp580-page .bp322-tip .eyebrow{color:#7363bb}
.bp580-page .bp322-stats{margin:10px 0;gap:7px}
.bp580-page .bp322-stats>div{border-radius:12px;padding:8px 11px}
.bp580-page .bp322-stats strong{color:#2f265f}
.bp580-page .bp322-help,.bp580-page .bp322-advanced{margin-top:9px}
.bp580-page .bp322-guide{margin-top:11px}
.bp580-page .bp322-piece:focus-visible,.bp580-page .bp322-modes button:focus-visible,.bp580-page .bp322-primary-actions button:focus-visible{outline:3px solid #aa81ff;outline-offset:2px}
.bp580-page .bp580-feedback{position:absolute;top:12px;left:50%;transform:translate(-50%,-20px);z-index:4;background:#161b39;color:#fff;border-radius:999px;font-size:.85rem;font-weight:800;padding:9px 16px;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s;box-shadow:0 10px 25px #0003;white-space:nowrap}
.bp580-page .bp580-feedback.visible{opacity:1;transform:translate(-50%,0)}
@media(min-width:1020px) and (max-height:850px){.bp580-page .bp322-title p{max-width:490px}.bp580-page .bp322-title{padding-top:10px;padding-bottom:10px}.bp580-page .bp322-board-shell{width:min(100%,430px)}.bp580-page .bp322-stage{gap:8px}.bp580-page .bp322-tip{display:none}}
@media(max-width:990px){.bp580-page .bp322-stage{grid-template-columns:1fr}.bp580-page .bp322-side{display:grid;grid-template-columns:1fr 1fr}.bp580-page .bp322-tip{grid-column:1/-1}}
@media(max-width:700px){.bp580-page{padding:5px 0 60px}.bp580-page .bp322-title{padding:9px 11px;border-radius:15px;gap:9px;margin:4px 0 6px;align-items:center;display:flex}.bp580-page .bp322-title .eyebrow,.bp580-page .bp322-title p,.bp580-page .bp322-title h1 small{display:none}.bp580-page .bp322-title h1{font-size:1.45rem;margin:0}.bp580-page .bp322-scorebox{min-width:94px;padding:7px 11px;border-radius:12px}.bp580-page .bp322-scorebox small{font-size:.59rem}.bp580-page .bp322-scorebox strong{font-size:1.42rem;line-height:1.12}.bp580-page .bp322-scorebox span{font-size:.62rem}.bp580-page .bp322-modes{display:grid;grid-template-columns:repeat(3,1fr);gap:5px;margin-bottom:6px}.bp580-page .bp322-modes button{padding:7px 3px;min-height:35px}.bp580-page .bp322-game-card{padding:7px;border-radius:17px}.bp580-page .bp322-strip{display:grid;gap:5px;padding:2px 2px 6px}.bp580-page .bp322-state-main strong{font-size:.89rem}.bp580-page .bp322-state-main small{font-size:.67rem;line-height:1.24;margin-top:0}.bp580-page .bp322-live{margin:0;display:grid;grid-template-columns:repeat(4,1fr);gap:4px}.bp580-page .bp322-live span{min-width:0;padding:4px 2px;border-radius:8px}.bp580-page .bp322-live small{font-size:.54rem}.bp580-page .bp322-live b{font-size:.83rem}.bp580-page .bp322-stage{display:block;margin-top:7px}.bp580-page .bp322-play{display:grid;grid-template-columns:1fr;grid-template-rows:none;grid-template-areas:'board' 'label' 'tray' 'actions';gap:6px}.bp580-page .bp322-board-shell{width:min(100%,365px);max-width:none;justify-self:center}.bp580-page .bp322-board{padding:6px;gap:3px;border-radius:15px;box-shadow:0 7px 20px #151f3840,0 0 0 2px #eeeaff}.bp580-page .bp322-cell{border-radius:5px}.bp580-page .bp322-tray-label{display:flex;justify-content:space-between;align-items:center;font-size:.61rem;padding:2px 5px 0;margin:0}.bp580-page .bp322-tray-label small{display:block;font-size:.59rem;margin:0}.bp580-page .bp322-tray{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));min-height:70px;gap:6px;width:100%;margin:0}.bp580-page .bp322-piece{min-height:68px;padding:4px;border-radius:11px}.bp580-page .bp322-mini{grid-template-columns:repeat(var(--mw),11px);grid-template-rows:repeat(var(--mh),11px);gap:2px}.bp580-page .bp322-mini i{width:11px;height:11px;border-radius:3px}.bp580-page .bp322-piece small{display:none}.bp580-page .bp322-primary-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}.bp580-page .bp322-primary-actions button{min-height:38px;font-size:.72rem;padding:4px 1px}.bp580-page .bp322-side{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-top:7px}.bp580-page .bp322-run-card,.bp580-page .bp322-tip{display:none}.bp580-page .bp322-next-card,.bp580-page .bp322-tools{padding:6px;grid-column:auto}.bp580-page .bp322-tools{grid-template-columns:repeat(2,1fr);gap:3px}.bp580-page .bp322-tools button{min-height:32px;font-size:.59rem;padding:2px}.bp580-page .bp322-stats{margin:7px 0;gap:4px;grid-template-columns:repeat(3,1fr)}.bp580-page .bp322-stats>div{padding:5px 7px}.bp580-page .bp322-stats small{font-size:.61rem}.bp580-page .bp322-stats strong{font-size:.96rem}.bp580-page .bp322-guide{display:none}.bp580-page .bp322-help,.bp580-page .bp322-advanced{padding:10px}}
@media(max-width:360px){.bp580-page .bp322-title h1{font-size:1.25rem}.bp580-page .bp322-board-shell{width:min(100%,325px)}.bp580-page .bp322-live span{padding:4px 1px}}
@media(prefers-reduced-motion:reduce){.bp580-page .bp580-feedback{transition:none}}
@media(max-width:700px){.bp580-page .bp322-title{flex-direction:row!important;justify-content:space-between;text-align:left}.bp580-page .bp322-title>div:first-child{flex:1;min-width:0}.bp580-page .bp322-title h1{white-space:nowrap}.bp580-page .bp322-scorebox{flex-shrink:0}}
@media(max-width:700px){.bp580-page .bp322-scorebox{padding:5px 9px;min-width:81px}.bp580-page .bp322-scorebox strong{font-size:1.24rem}.bp580-page .bp322-scorebox span{display:none}.bp580-page .bp322-state-main small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}}
@media(max-width:700px){.bp580-page .bp322-strip{grid-template-columns:minmax(0,1fr)}.bp580-page .bp322-state-main,.bp580-page .bp322-live{min-width:0;width:100%}.bp580-page .bp322-live .clean{min-width:0}}
