/* hazeljs-examples, Minesweeper: the bar (mines left, the face, the time) and the board, its cells sized to fit (--cs) */
.sweep-bar { display: flex; align-items: center; justify-content: space-between; max-width: 420px; margin: 10px 0 6px; }
.sweep-bar .counter { font-variant-numeric: tabular-nums; font-weight: 700; background: #111827; color: #f87171; border-radius: 6px; padding: 2px 10px; min-width: 64px; text-align: center; }
.sweep-bar .face { font-size: 1.7em; cursor: pointer; user-select: none; }
.board-wrap { overflow-x: auto; padding-bottom: 4px; }
.board { --cs: 30px; display: grid; gap: 2px; background: #7b8698; padding: 3px; border-radius: 8px; width: max-content; user-select: none; -webkit-user-select: none; touch-action: manipulation; }
.board .cell { width: var(--cs); height: var(--cs); border: 0; padding: 0; margin: 0; border-radius: 4px; font: 700 calc(var(--cs) * 0.56) / 1 system-ui, sans-serif;
  display: flex; align-items: center; justify-content: center; cursor: pointer; background: linear-gradient(145deg, #e8edf5, #b4bfcf); color: #1f2937; }
.board .cell.open { background: #d8dee8; cursor: default; }
.board .cell.flag { background: linear-gradient(145deg, #e8edf5, #b4bfcf); }
.board .cell.boom { background: #ef4444; }
.board .cell.miss { background: #fca5a5; }
.board .cell.n1 { color: #2563eb; } .board .cell.n2 { color: #16a34a; } .board .cell.n3 { color: #dc2626; } .board .cell.n4 { color: #1e3a8a; }
.board .cell.n5 { color: #7f1d1d; } .board .cell.n6 { color: #0f766e; } .board .cell.n7 { color: #111827; } .board .cell.n8 { color: #6b7280; }
.board .cell:focus-visible { outline: 2px solid #f59e0b; outline-offset: -2px; }
/* the 💡 hint: the cell to open or flag (yellow, as Solitaire's), and the number that shows it (blue, dashed) */
.board .cell.hint { outline: 3px solid #fbbf24; outline-offset: -3px; }
.board .cell.why { outline: 3px dashed #0ea5e9; outline-offset: -3px; }
#flagmode[aria-pressed="true"] { border-color: #ef4444; background: #fee2e2; color: #7f1d1d; }
/* full screen: the controls on the left (hidden in landscape until ☰), the bar above the board in the rest, the board centred */
html.oracle-fs .sweeper-ui { grid-template-columns: minmax(200px, 0.55fr) minmax(0, 3fr); grid-template-rows: auto minmax(0, 1fr); }
html.oracle-fs .sweeper-ui > .sweep-bar { grid-column: 2; grid-row: 1; justify-self: center; width: min(420px, 100%); margin: 0 0 8px; }
html.oracle-fs .sweeper-ui > .board-wrap { grid-column: 2; grid-row: 2; align-self: start; justify-self: stretch; margin: 0; overflow: auto; max-height: 100%; }
html.oracle-fs .sweeper-ui .board { margin: 0 auto; }
html.oracle-fs .sweeper-ui > .fs-cast { grid-row: 1 / -1; }
html.oracle-fs .fs-tool[aria-pressed="true"] { border-color: #ef4444; background: #fee2e2; }
