With a 5600XT as a base, and keeping the cost right down one you've sold the i5/Mobo/RAM then I'd get the below
CPU: Intel Core i5-10400F 2.9 GHz 6-Core Processor
Motherboard: MSI B560M PRO-VDH WIFI Micro ATX LGA1200 Motherboard
Memory: Crucial Ballistix 16 GB (2 x 8 GB) DDR4-3200 CL16 Memory
Total: ~£279
No point in spending more on a 12400(F) and a more expensive LGA1700 board to get almost no extra performance from it, unless you somehow manage to get a much faster GPU for good price. If prices do normalise again, you can easily sell this kit and get whatever you need with a small loss, but probably end up on a platform that will last longer anyhow. You'll have probably spent £150 after selling the old kit, which is about what an i7 7700K costs at auction.