Misc bottom backet and crankset questions
That's a lot of questions but I think I can answer most of them with a couple of answers.

With respect to cartridge bottom brackets and cranks (Square taper, Octalink etc.):


The cartridge need to be appropriate for the frame bottom bracket shell width (traditionally 68mm for road bike and 73mm for mountain)
The axle length need to be correct for the specific crank you are using to get the correct chain line. It's critical to know that different model cranks need different length axles to get the same chainline, so you need to look up the specifications for the crank to find out the bottom bracket axle length required. 


With respect to Hollowtech II (and other external threaded bearing systems like GXP), things are a bit simpler, because the drive side crank comes with the axle attached. The axle length is just whatever is required for the bottom bracket shell width the crank is designed for. You do have to pick a crank that gives the correct chainline for your frame of course.

With respect to deviation from the correct chainline if you use a different cartridge BB than the crank is designed for, I would not recommend being more than a few millimeters out. If the chainrings are to far inboard you may get interference with the chainstay, too far outboard can result in derailleur reach problems.

If you are using Shimano products you can look up the specifications for cranks, which includes nominal chainline the bottom bracket models that work. Start here: https://productinfo.shimano.com/#/spec.