the right way to attach two line is not to attach 2 lines and make one line of the correct length. You will need a flaring tool to do this method, as the lines are likely a flare fitting into the transmission. The problem is it will be of some difficulty to locate the correct fittings for the transmission.
the next echelon down the totem pole would be to cut the existing line square, add a nut and ferrule, then flare the line. 37 degree JIC flare is popular with the automotive aftermarket, but bubble flares and double flares are used occasionally as well. Again you will need a flaring tool, but what type you select is entirely your discretion.
The third step down would be to use a compression style fitting, but since these seal on the outside of the line, if your line is even slightly corroded, it’s likely to leak.
Then, the fourth method is what is currently done. Rubber hose and clamps. This is not a good method for a variety of reasons that you have, and haven’t, mentioned.
You can probably get 5/16 fuel line from any autoparts store, or Ferry Hydraulics on Walden will definitely have it, along with all of the fittings and tools listed above.