Entropy Production Beyond the Diffusion Limit: A Phase Transition in the Two-Allele Wright–Fisher Model