:root:not([data-game="reversi"]) .only-reversi { display: none !important; }
:root[data-game="reversi"] .board-wrap.only-gomoku,
:root[data-game="reversi"] #page-footer .only-gomoku,
:root[data-game="reversi"] #game-faq .only-gomoku,
:root[data-game="reversi"] .rules-list.only-gomoku { display: none; }
.rv-wrap { container-type: inline-size; width: 100%; aspect-ratio: 1; min-width: 0; min-height: 0; }
.rv-wrap::before, .rv-wrap::after { display: none; }
#reversi-board { position: absolute; inset: 3.2%; display: grid; min-width: 0; min-height: 0; grid-template-columns: repeat(8,minmax(0,1fr)); grid-template-rows: repeat(8,minmax(0,1fr)); border: 1px solid #193e2d; border-radius: 4px; overflow: hidden; background: #315f49; }
.rv-cell { position: relative; display: grid; place-items: center; width: 100%; height: 100%; min-width: 0; min-height: 0; box-sizing: border-box; padding: 0; border: 1px solid #dce6d72e; border-radius: 0; cursor: pointer; }
.rv-cell:disabled { cursor: default; opacity: 1; }
.rv-light,.rv-dark { background: #315f49; }
.rv-cell:focus-visible { outline: 3px solid #fff3cf; outline-offset: -3px; z-index: 1; }
.rv-disc { display: block; width: 78%; aspect-ratio: 1; border-radius: 50%; pointer-events: none; box-shadow: 0 3px 3px #10251b70,inset 0 2px 2px #ffffff38,inset 0 -4px 4px #00000032; }
.rv-motion-face { position: absolute; inset: 0; width: 78%; height: auto; margin: auto; }
.rv-black { background: radial-gradient(circle at 34% 27%,#545953,#202722 72%); }
.rv-white { background: radial-gradient(circle at 34% 27%,#fffdf5,#dfd8c9 80%); }
.rv-ghost { opacity: .76; outline: 3px solid #f4e6b5; outline-offset: 2px; }
.rv-legal::after { content: ''; width: 17%; aspect-ratio: 1; border-radius: 50%; background: #e8eedc; opacity: .6; pointer-events: none; }
.rv-legal:has(.rv-disc)::after { display: none; }
.rv-legal:disabled { cursor: default; }
.rv-legal:not(:disabled):hover::after { opacity: .95; transform: scale(1.2); }
.rv-preview { box-shadow: inset 0 0 0 3px #f4e6b5; }
.rv-last { box-shadow: inset 0 0 0 2px #e7bd62; }
/* Keep the disc count beside the colour so the shared status band stays two rows. */
.player-chip.only-reversi > span:last-child { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 4px; }
.only-reversi strong { grid-area: 2 / 1; }
.only-reversi small:not(.rv-count) { grid-area: 1 / 1 / 2 / 3; }
.only-reversi .rv-count { grid-area: 2 / 2; color: var(--muted); font-size: 12px; font-weight: 500; line-height: 1.3; font-variant-numeric: tabular-nums; }
.rv-hint { width: var(--col); min-height: 20px; margin: 10px 0 0; color: var(--muted); font: 14px/1.45 var(--sans); text-align: center; }
