Add an `order` parameter to the magic square solver that can dynamically set the side length of the square. Make the necessary changes to the value range, diagonal sum, and row and column sums.