Arduino 300 Outputs

If you only need one relay to be on at a time, then things get much simpler. Arrange them in a 18x18 matrix.

SQRT 300 is < 18 so you just need to drive one of 18 lines HIGH, and one of 18 LOW.

3 shift registers for each of the HIGH and LOW drivers.

You'll still need approriate power handling devices , but if there are 'high-side drivers like the low-side TPIC6B595 you don't even need these.

you will need freewheel diodes, of course. 1N4148's are cheap

Allan