.games-body { --game-green: #185c43; --game-gold: #ad6b21; }
.games-body .masthead { padding: 14px 0; }
.games-body .masthead .eyebrow, .games-body .masthead .strap { display: none; }
.games-body .masthead .brand-logo { width: min(250px, 68vw); height: auto; margin: 0 auto; }
.game-page { max-width: 880px; margin: 24px auto 46px; }
.game-page h2 { margin: 4px 0; font-size: clamp(2.25rem, 5vw, 3.5rem); }
.game-page .eyebrow, #puzzle-date, .game-intro { margin: 0 0 7px; }
#puzzle-date { color: var(--muted); font-size: .9rem; }
.game-layout { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 28px; align-items: start; margin-top: 20px; }
.game-play { padding: clamp(12px, 3vw, 22px); border: 1px solid #d2d3c4; border-radius: 14px; background: #fffcf2; box-shadow: 0 4px 0 #dfded0; }
.game-progress { display: flex; align-items: center; gap: 10px; font-size: .82rem; color: var(--game-green); font-weight: 700; }
.game-progress progress { flex: 1; min-width: 0; height: 8px; accent-color: var(--game-green); }
.active-clue { min-height: 3em; margin: 12px 0; padding: 8px 10px; background: #e5efe4; border-radius: 6px; font-size: .88rem; }
.game-board { display: grid; gap: 3px; width: 100%; max-width: 290px; margin-inline: auto; }
.game-cell { position: relative; min-width: 0; aspect-ratio: 1; }
.game-cell input { box-sizing: border-box; width: 100%; height: 100%; min-width: 0; border: 1px solid #b5b9a8; border-radius: 5px; background: #fffefa; color: #18241d; text-align: center; font: 750 clamp(16px, 3vw, 23px) system-ui, sans-serif; padding: 0; transition: background-color .15s; }
.game-cell input[data-active] { background: #e2eee5; border-color: #729880; }
.game-cell input[data-result="correct"] { background: #c4e5cc; border-color: #679471; }
.game-cell input[data-result="retry"] { background: #f9e4c5; border-color: var(--game-gold); }
.game-cell input:focus { outline: 2px solid var(--game-green); outline-offset: -2px; }
.game-cell span { position: absolute; z-index: 1; top: 2px; left: 3px; font: 10px system-ui, sans-serif; pointer-events: none; }
#clue-heading { margin: 0 0 8px; }
#game-clues h4 { margin: 12px 0 5px; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--game-green); }
#game-clues ul { margin: 0; padding: 0; list-style: none; }
#game-clues button { display: flex; justify-content: space-between; gap: 8px; width: 100%; padding: 8px 9px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: inherit; text-align: left; cursor: pointer; font: inherit; font-size: .91rem; }
#game-clues button[aria-pressed="true"] { background: #e5efe4; border-color: #a9c3b0; }
#game-clues button[data-result="correct"] { color: var(--game-green); }
#game-clues button[data-result="retry"] { color: #80480f; }
#game-clues button span:last-child { white-space: nowrap; font-size: .8em; font-weight: 700; align-self: center; }
#game-status { min-height: 2.6em; margin: 12px 0 0; font-size: .87rem; font-weight: 700; }
#game-status[data-result="correct"] { color: var(--game-green); }
#game-status[data-result="retry"] { color: #80480f; }
#game-share { border: 1px solid var(--game-green); border-radius: 6px; padding: 9px 14px; background: var(--game-green); color: white; cursor: pointer; font: inherit; }
@media (max-width: 620px) {
  .game-layout { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .game-board { max-width: 235px; }
}
@media (prefers-reduced-motion: reduce) { .game-cell input { transition: none; } }

.game-timer { min-width: 3.5ch; text-align: right; font-variant-numeric: tabular-nums; }
.game-confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 10; }
.game-confetti span { position: absolute; top: 48%; left: 50%; width: 8px; height: 12px; border-radius: 2px; background: var(--piece-color); animation: game-burst 1.15s ease-out both; }
@keyframes game-burst {
  0% { transform: translate(0, 0) scale(.2); opacity: 0; }
  16% { opacity: 1; }
  65% { opacity: 1; }
  100% { transform: translate(var(--dx), calc(var(--dy) + 75px)) rotate(var(--spin)); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .game-confetti { display: none; } }

.games-body .skip-link { position: fixed; left: 12px; top: -100px; z-index: 1000; background: #fff; padding: 12px; }
.games-body .skip-link:focus { top: 12px; }
.game-layout[hidden] { display: none; }
.game-result { margin-top: 20px; }
.game-result h3 { margin: 0; color: var(--game-green); }
#game-result-time { margin: 8px 0 14px; font-variant-numeric: tabular-nums; }
#game-solution { font: inherit; background: transparent; color: var(--game-green); border: 1px solid currentColor; border-radius: 5px; padding: 9px 12px; margin: 4px; cursor: pointer; }
#game-share-status:empty { margin: 0; }
.game-archive { margin-top: 28px; padding: 16px 0; border-block: 1px solid #d2d3c4; }
.game-archive summary { cursor: pointer; font-weight: 700; color: var(--game-green); }
.game-archive ul { list-style: none; padding: 0; margin-bottom: 0; }
.game-archive li { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; padding: 9px 0; border-bottom: 1px solid #d2d3c4; }
.game-archive li:last-child { border-bottom: 0; }


.sudoku-page .game-play { max-width: 520px; margin-inline: auto; }
.game-switch { margin: 14px 0; padding: 12px 14px; border: 1px solid #d2d3c4; border-radius: 9px; background: #fffcf2; }
.game-switch a { color: var(--game-green); font-weight: 700; }
.sudoku-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.sudoku-toolbar span { margin-right: auto; color: var(--game-green); }
.sudoku-toolbar button { border: 1px solid var(--game-green); border-radius: 6px; padding: 8px 12px; background: var(--game-green); color: white; cursor: pointer; font: inherit; }
.sudoku-board { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); width: min(100%, 430px); margin: 16px auto; border: 2px solid #405b4b; }
.sudoku-cell { min-width: 0; aspect-ratio: 1; border-right: 1px solid #bcc3b4; border-bottom: 1px solid #bcc3b4; }
.sudoku-cell:nth-child(9n) { border-right: 0; }
.sudoku-cell:nth-last-child(-n+9) { border-bottom: 0; }
.sudoku-cell.box-top { border-top: 2px solid #405b4b; }
.sudoku-cell.box-left { border-left: 2px solid #405b4b; }
.sudoku-cell input { box-sizing: border-box; width: 100%; height: 100%; min-width: 0; border: 0; border-radius: 0; background: #fffefa; color: #18241d; text-align: center; padding: 0; font: 700 clamp(16px, 4vw, 26px) system-ui, sans-serif; }
.sudoku-cell input[readonly] { background: #e9ecdf; color: #26392d; }
.sudoku-cell input[data-result="correct"] { background: #c4e5cc; }
.sudoku-cell input[data-result="retry"] { background: #f9e4c5; }
.sudoku-cell input:focus { position: relative; z-index: 1; outline: 2px solid var(--game-green); outline-offset: -2px; }
#sudoku-status { min-height: 2.6em; margin: 10px 0 0; font-size: .9rem; font-weight: 700; }
@media (max-width: 420px) { .sudoku-toolbar span { width: 100%; } .sudoku-board { width: min(100%, 360px); } }
