.shogi-setup{margin:.35rem 0 .1rem}
.shogi-setup summary{min-height:44px;display:flex;align-items:center;gap:.5rem;cursor:pointer;font-weight:750;color:var(--jade)}
.shogi-setup summary::before{content:"+";font-size:1.15em}
.shogi-setup[open] summary::before{content:"−"}
.shogi-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.45rem;padding:.45rem .6rem .65rem;background:#f3f5eb;border-radius:12px}
.shogi-options label{display:grid;gap:.2rem;font-size:.8rem;font-weight:700;color:var(--soft)}
.shogi-options select{
  appearance:none;width:100%;min-height:44px;height:44px;
  padding-inline:.4rem 1.2rem;
  background:var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%231b5143' stroke-width='1.5'/%3E%3C/svg%3E") right .35rem center / .65rem no-repeat;
}
[dir=rtl] .shogi-options select{background-position:left .35rem center}
.shogi-options p{grid-column:1/-1;margin:0;color:var(--soft);font-size:.82rem}
#shogi-review-bar{display:flex;flex-wrap:wrap;gap:.35rem;align-items:center;margin:.35rem 0;padding:.45rem;background:#eff2e5;border-radius:10px}
#shogi-review-bar output{margin-inline-end:auto;font-weight:700}
#shogi-review-bar button{padding-inline:.65rem}
.shogi-cpu .cell,.shogi-reviewing .cell{cursor:default}
.shogi-cpu .cell:hover,.shogi-reviewing .cell:hover{background:repeating-linear-gradient(8deg,#fff2b814 0 1px,#8e512412 2px 3px,transparent 4px 10px),linear-gradient(130deg,#e8c88f,#d3ac72)}
.shogi-game-board{display:flex;flex-direction:column;min-width:0}
.shogi-game-board:has(.flipped) #south{order:-1}
.shogi-game-board:has(.flipped) #north{order:1}
.shogi-promotion .actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
.shogi-promotion .actions button{min-height:54px}
@media(max-width:430px){
  .shogi-options select{font-size:.8rem}
  .shogi-setup summary,#shogi-review-bar button{font-size:.84rem}
  .reserve strong{max-width:100%;white-space:normal}
  #dialog-detail{font-size:.92rem}
}
