/* Keep sentence geometry intact, with move controls immediately below the board. */
.rule-card-game .grid-workspace{grid-template-columns:minmax(0,1.65fr) minmax(280px,1fr);gap:32px;align-items:start}
.rule-card-game .grid-board{min-width:0}
.rule-card-game .grid-reading-hint,.rule-card-game .rules-reading-hint{margin:0 0 13px;font:12px/1.6 var(--sans);color:var(--muted)}
.rule-card-game .grid-scroll{padding:4px;scroll-padding:8px}
.rule-card-game .word-grid{gap:7px;padding:12px;background:#10181382;border-color:#e4d5ac24;align-items:stretch;min-width:max(var(--grid-min-width,0px),calc(var(--grid-columns,5) * 92px + 24px))}
.rule-card-game .word-tile{container-type:inline-size;min-height:66px;padding:15px 7px 11px;border-radius:3px;background:#e9e0c8;border-color:#cabd9a;gap:3px}
.rule-card-game .word-tile .tile-word{font:600 clamp(10px,20cqw,14px)/1.3 var(--serif);letter-spacing:0;overflow-wrap:normal;word-break:normal}
.rule-card-game .word-tile.long-word .tile-word{font:500 clamp(10px,18cqw,12px)/1.3 var(--sans);overflow-wrap:normal;word-break:normal}
.rule-card-game .word-tile.long-word.word-verb .tile-word{font-size:clamp(10px,16cqw,11px);overflow-wrap:normal;word-break:normal}
.rule-card-game .word-tile.word-verb{background:#d5cbb2}
.rule-card-game .word-tile.rare-connector{background:#d2dfd3;border-top-color:#9bb4a1;border-right-color:#9bb4a1;border-bottom-color:#9bb4a1;border-left-color:#9bb4a1}
.rule-card-game .word-tile .tile-rarity{font:600 10px/1.3 var(--sans);letter-spacing:0;color:#405b46}
.rule-card-game .word-tile .tile-role{font:600 10px/1.2 var(--sans);letter-spacing:0;color:#514633}
.rule-card-game .word-tile .tile-position{font-size:10px;color:var(--paper-label)}
.rule-card-game .word-tile.word-rarity-common .tile-rarity{color:var(--paper-label)}
.rule-card-game .word-tile.word-rarity-uncommon{background:#dce2cb}
.rule-card-game .word-tile.word-rarity-rare{background:#d4e0e5}
.rule-card-game .word-tile.word-rarity-rare .tile-rarity{color:#355e79}
.rule-card-game .word-tile.word-rarity-epic{background:#e5d7e4}
.rule-card-game .word-tile.word-rarity-epic .tile-rarity{color:#765079}
.rule-card-game .word-tile.empty{background:transparent;border-top:1px solid transparent;border-right:1px solid transparent;border-bottom:1px solid transparent;border-left:1px solid transparent;color:#c0b69970}
.rule-card-game .word-tile.empty .tile-word{font:18px var(--serif)}
.rule-card-game .word-tile.empty:disabled{opacity:1}
.rule-card-game .word-tile.related{border-color:#cfa556;background:#f0dfb5}
.rule-card-game .word-tile.related:not(.selected):not(:focus-visible){outline:2px dashed #726445;outline-offset:-4px}
.rule-card-game .word-tile.selected{background:#f6e9c7;outline:2px solid var(--gold);outline-offset:1px}
.rule-card-game .word-tile.destination{border-color:#d8bf7275;border-style:dashed;background:#d8bf720d;color:#e4cc91}
.rule-card-game .word-tile.destination:hover{background:#d8bf7226}
.rule-card-game .word-tile.push-path{border-color:#a8c8c0;border-style:dashed}
.rule-card-game .word-tile.empty.push-path{background:#a8c8c01a}
.rule-card-game .sentence-number{position:absolute;top:3px;left:5px;font:10px/1.2 var(--sans);color:var(--paper-label)}
.rule-card-game .push-marker{position:absolute;bottom:1px;right:5px;font:15px/1 var(--sans);color:#315b55}
.rule-card-game .empty .push-marker{color:#c9e3dc}
.rule-card-game .grid-tools{display:flex;flex-direction:column;gap:10px;margin:10px 4px 7px;padding:12px;background:#18241f;border:1px solid #b9aa7960;border-radius:3px;min-width:0}
.rule-card-game .tile-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px}
.rule-card-game .tile-selection{min-height:0;font:12px/1.55 var(--sans)}
.rule-card-game .grid-tools .tile-toolbar button{flex:0 0 auto;padding:6px 10px}
.rule-card-game .grid-directions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
.rule-card-game .grid-tools button{min-height:44px;font:13px/1.35 var(--sans);box-shadow:none}
.rule-card-game .grid-tools button:disabled{opacity:.35}
.rule-card-game .grid-directions button[aria-pressed="true"]{border-color:#a8c8c0;background:#a8c8c021;color:#d6eee7}
.rule-card-game .push-preview{padding-top:13px;border-top:1px solid var(--line)}
.rule-card-game .push-preview .eyebrow{margin:0 0 6px;font-size:10px;color:#b5d0c7}
.rule-card-game .push-preview h3{margin:0 0 10px;font:22px/1.2 var(--serif);color:var(--paper)}
.rule-card-game .push-preview p{margin:8px 0;font:12px/1.6 var(--sans);color:var(--paper)}
.rule-card-game .push-effect{padding-left:10px;border-left:2px solid #92b9a0}
.rule-card-game .push-effect.broken{border-left-color:#cb917c}
.rule-card-game .push-effect strong,.rule-card-game .push-effect span{display:block}
.rule-card-game .push-effect strong{font-weight:600}
.rule-card-game .push-effect span{margin-top:3px;color:var(--muted)}
.rule-card-game .push-preview .push-preview-score{color:#c1dacf}
.rule-card-game .push-confirm-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.rule-card-game #confirm-push{flex:0 1 auto;max-width:100%;color:var(--paper);background:transparent;border-color:var(--red);padding:10px 16px}
.rule-card-game #confirm-push:hover:not(:disabled){background:#c358421a}
.rule-card-game .workshop-tools .tile-selection{min-height:44px;display:flex;align-items:center}
.rule-card-game .workshop-tools #stash-tile{align-self:flex-start;min-height:44px}
.rule-card-game .workshop-tools .keyboard-hint{display:none}
.rule-card-game .grid-workspace .formed-rules-wrap{margin:0;min-width:0}
.rule-card-game .formed-rules-wrap h3{font:25px/1.15 var(--serif);margin:0 0 5px}
.rule-card-game .formed-rules{grid-template-columns:minmax(0,1fr);gap:0}
.rule-card-game .formed-rule{border:0;border-top:1px solid var(--line);border-radius:0;background:transparent;padding:13px 0}
.rule-card-game .formed-rule.related{background:#d6b7660c}
.rule-card-game .formed-rule.new{border-top-color:var(--gold)}
.rule-card-game .formed-rule .sentence-link{display:flex;align-items:baseline;justify-content:flex-start;gap:10px;width:100%;min-height:44px;padding:4px 0;margin:0;text-align:left;border-top:1px solid transparent;border-right:1px solid transparent;border-bottom:1px solid transparent;border-left:1px solid transparent;background:transparent;box-shadow:none;color:var(--paper);letter-spacing:0}
.rule-card-game .sentence-link:hover:not(:disabled){color:var(--gold);background:transparent}
.rule-card-game .sentence-link:focus-visible{outline:2px solid var(--gold);outline-offset:3px}
.rule-card-game .sentence-link:disabled{opacity:1;cursor:default}
.rule-card-game .sentence-index{flex:0 0 30px;font:11px/1.4 var(--sans);color:#c9b67e}
.rule-card-game .sentence-link strong{font:600 16px/1.4 var(--serif);color:inherit}
.rule-card-game .formed-rule p{font:12px/1.65 var(--sans);margin:2px 0 7px 41px;color:#d0cdbf}
.rule-card-game .formed-rule small{margin-left:41px;font:10px/1.6 var(--sans);color:#bdb294;letter-spacing:.04em}
.rule-card-game .formed-rule.inactive .sentence-link strong{text-decoration:line-through}
.rule-card-game .rule-clauses{display:grid;gap:12px;list-style:none;margin:3px 0 12px 41px;padding:0;counter-reset:clause}
.rule-card-game .rule-clause{position:relative;padding-left:11px;border-left:2px solid #8ca994}
.rule-card-game .rule-clause.inactive{border-left-color:#c58b76}
.rule-card-game .rule-clause>strong{font:600 13px/1.45 var(--serif)}
.rule-card-game .rule-clause.inactive>strong{text-decoration:line-through;text-decoration-color:#ca8973}
.rule-card-game .rule-clause>p,.rule-card-game .rule-clause>small{margin-left:0}
.rule-card-game .rule-clause.inactive>small{color:#d29b89}
.rule-card-game .formed-rule.partial>small{color:#ddbc86}
.rule-card-game .grid-help{margin:16px 4px 0;font:12px/1.65 var(--sans);color:var(--muted)}
.rule-card-game .grid-help summary{min-height:44px;cursor:pointer;color:var(--paper);padding:10px 0}
.rule-card-game .grid-help p{max-width:60ch;margin:0 0 10px}
.rule-card-game .workshop-intro{padding:0 0 16px;border:0;background:transparent;margin-bottom:10px;max-width:720px}
.rule-card-game .workshop-intro h3{font-size:28px;margin:8px 0}
.rule-card-game .workshop-intro p{font:13px/1.6 var(--sans)}
.rule-card-game .word-reserve{grid-template-columns:repeat(auto-fill,minmax(100px,1fr))}
.rule-card-game .word-reserve .word-tile{min-height:48px;padding:10px 7px}
@media(max-width:1000px){
  .rule-card-game .grid-workspace{grid-template-columns:minmax(0,1.5fr) minmax(245px,1fr);gap:22px}
  .rule-card-game .word-grid{gap:5px;padding:9px}
  .rule-card-game .word-tile{min-height:62px;padding:15px 4px 10px}
}
@media(max-width:760px){
  .rule-card-game .grid-workspace{grid-template-columns:minmax(0,1fr);gap:23px}
  .rule-card-game .word-grid{gap:5px;padding:8px}
  .rule-card-game .word-tile{min-height:62px;padding-left:2px;padding-right:2px}
  .rule-card-game .grid-reading-hint{font-size:11px;margin-bottom:8px}
  .rule-card-game .grid-tools{padding:10px;gap:8px}
  .rule-card-game .grid-tools button{font-size:12px}
  .rule-card-game .tile-toolbar{gap:6px}
  .rule-card-game .tile-selection{font-size:11px}
  .rule-card-game .grid-directions{gap:5px}
  .rule-card-game .formed-rules-wrap h3{font-size:24px}
  .rule-card-game .sentence-link strong{font-size:16px}
}
@media(prefers-reduced-motion:reduce){.rule-card-game .grid-scroll{scroll-behavior:auto}}
