Most prefab level crossings peieces act as to rerailers. You can see how they do it and maybe 3d print or mould some kind of drop in. Some I have used are the minitrix, and Kato ones (and Hornby back in the day) they will rerail a (not severely) detailed bogie without much ado. Basically make the outer part a ramp with some guide rails.
This shows the idea