There were three different RST gearboxes available. They all had the same gearsets, the only differences:
S1: Final drive of 4.27
S2: Final dive of 3.82, two different gearboxes because of the modified gear lever linkage in ~86
Easiest way to get a very short B5 gearbox:
Use the gear ratios of a GFJ 16V (not sure about the XR2i 16V and the RS1800 that were sold in UK, here in Germany they had a 3.82 axle and short gear ratios, that made them nearly as short as a S1 box) and the final drive of a S1. That's the shortes combination you can get out of Ford standard parts. The RS1600i had the same ratios like the XR3/RST S2 with different 5th gears...