Design and implement an object-oriented simulation framework for a two-player, turn-based game similar to tic-tac-toe. The system should initialize game state, validate and apply moves, alternate turns, detect terminal states, and determine whether the result is a win, loss, or draw. Expose a clean API so that a caller can step through the simulation, inspect state, and replay or debug game progress.
After building a minimal working version, extend the design to support follow-up requirements such as different board sizes, custom win conditions, move history, undo, and adding new game rules without rewriting the core engine. You should focus on clean code, modularity, good data modeling, testability, and the ability to evolve the design as requirements change. The emphasis is on simulation logic and software design, not advanced algorithms.