Look at the "Simple Switcher regulator ICs.
eg. an LM2576 can convert an input of anything up to 40V to 5V with up to 3A output current.
Personally, I'd design in the option of battery backup from the start, even if the batteries are not initially included.
As in, base the solar panel output on 30V to be able to charge a 24V battery system.
The 24 - 30V range of a nominal 24V lead acid backup battery setup is well within the input range of regulators such as above and keeping the battery voltage higher (24V rather than eg. 12V) halves the current draw from the batteries, which would be considerable at your maximum 400W output.
Smallish solar panel setups for battery charging often just use a shunt regulator to dump any excess if the batteries are already fully charged and/or there is not as much demand as available power, so there are no conversion losses as such as that stage, just a series (schottky) diode to prevent any power flow back to the solar panels when they are dark.
That gives you a pretty efficient (80%) 5V source in one stage. Each regulator could run two 5V outputs at up to 1.5A each, or more lower current rated ones.