The red 'invalid loadout' icon appeared after that.
Attempting to strip the mech is fruitless:

As I get this when I try to save after stripping the mech:

Then when I mechlab the mech again, a wild fairytale loadout appears!

Clicking on the loadout warning icon, after trying to strip again:

HOLY BAJILLION ERRORS BATMAN.
I'm fairly certain it was module swapping that caused it, as it's happened once or twice to other mechs in the past, but I don't want to try and reproduce it here as it'll take another mech off the field.
Selecting different mechs didn't help, but restarting the client seemed to resolve it.