I vote for the M471 or the M4521 since they seem to be pin compatible it does not matter that much which of the two.
There is also the issue of the Arduino framework that needs to be looked at. I presume a lot of the work for the STM32 based MCU's could be reused to make it work. I myself won't use it for projects due to being more of a bare metal guy, and also won't be using a lot of them either. Just a hobbyist with some projects I would say
very good point
IDE play an important role ... bootloader too if needed to be flashed too ?? thats why you had an second mcu on the arduino's, it could help flash the main mcu ??
how to start the board from scratch ...
for the form factor you could go as an "old uno" footprint / size
if you get an mcu with all the gpio's, the design can be bigger ... do you require a reset button ??
before ordering some pcb, you could output an 3d view to get an idea ??
EDIT dont use castellation, it was a nightmare at my job, pcb quality was bad, they shorted themselves out
standard headers pinout spacing is ok, if someone need them, just add them / solder them