TL;DR
Introduce a form of compressing items on trains (not transportable by other means) as a way to keep train transportation relevant in the late game
Why?
In Space Age, with the introduction of the Turbo Belts and belt stacking, belt throughput is increased through the roof. So much so that it easily rivals train transportation over long distances, displacing trains as the undisputed long distance, high throughput transportation option of choice, leaving trains mostly irrelevant.A way to compress items on trains would help bring the balance between trains and belts back into alignment, by vastly increasing item throughput on trains.
The idea:
Instead of loading trains with loose items like we do currently, introduce palletization, a way to package multiple items into a single one, and then load those onto the trains. These palletized items (pallets from now on) would not be transportable via bots or belts.By manipulating how many items it takes to make each pallet, and the stack size of the pallets, the number of items a regular cargo wagon can transport could be easily controlled.
There could either be just a single pallet research, so the change only has to be made once, or several tiers of pallet research, to help keep the trains in lockstep with the belt stacking.
Each new tier of pallet would be increasing the amount of items that can be transported through pallets in each cargo wagon slot, achieved by the new pallets packing more regular items and / or having a higher stack size.
At the loading stations, the items would be packed onto pallets before sent to the loading buffer. Then those pallets would be loaded into trains, transported to the unloading station, and unloaded into the unloading buffer. From there, the pallets would need to be unpacked before the items in it could be used in crafting, or further transported by bots or belts.
This would necessitate a different train loading and unloading strategy than what is used currently. While not strictly necessary, and regular inserters, chests, and assemblers could be used to handle the pallet logistics, thematically, I think it would be best to have a small set of dedicated entities to manage the loading / unloading process, for example a "pallet crane" (essentially a supersized inserter) to move the pallets around, and a depot (like a special chest that only accepts pallets) where those pallets could be stored.
In case there would be multiple tiers of pallet research, there are some QoL features that would be really nice to have:
1) for the unpacking this would be almost essential, because one would need to drain the system of old pallets before changing over to the new ones, otherwise the old pallets would clog the system.
Fortunately this can easily be solved - the unpacking plant simply needs to work as a recycler that only accepts pallets, and returns 100% of the inputs.
2) for packing, this would not be anywhere near as essential, but having to change the packing recipe for every single loading station for every new tier of pallets would be really annoying and tedious. Therefore, a way to have the packing plants always make the highest tier of pallets would be nice.
3) for train schedules, in order to keep generic interrupts relevant, it would be really good to have the different tiers of palletized cargo detected as a single signal - be that either the raw item, or, preferrably, a general "pallet of [item]" signal (eg "pallet of iron ore" instead of "small / medium / large pallet of iron ore", which could then be used to send the train to the appropriate unloading station. Without this, the unloading train stations would have to be renamed after adopting each new tier of pallets.
Of course, having only a single tier of pallets would neatly sidestep the need for these QoL features altogether.