The prompt shape matters here. "Split this file" optimises for the thing you can measure, which is file size, so you get 31 files. Ask for the boundary instead: "which parts of this file change for different reasons, and what would each own". Then refactor along the answer.
It also helps to say explicitly that a component used once should stay inline. Otherwise extraction is the default move at every level.