What's my best option for a sensor in this situation?

Sounds like you've done some good work, congrats!

What about something like this? Infrared emitter and detector in one package. This is just one example, I'm sure there are dozens of similar devices. It may be necessary to put some reflective tape or something on the bottom of the train if that is permissible. Or maybe it would work without it. At any rate, some experimentation would be needed.

PS: Mouser stocks over 100 "optical switches" the one I linked above has a range of only a few mm which may not be enough. So some research is needed. Luckily, Mouser's parametric search includes sensing distance.