Clear and informative tutorial on video file formats
I don't think you will find a single clear tutorial as you are talking about a very very broad field and talking about multiple aspects of it.  Many, many, many tutorials exist for help with encoding for YouTube or encoding for Bluray.  In fact, most Bluray authoring software has pretty good walkthroughs in their help.

Youtube itself outlines the basics for getting the best quality encoding for it here, provides conversion settings for unsupported formats here and has links to numerous videos related to creating videos here.

As for understanding file formats vs codecs, I don't know that a tutorial would be much help as it is a conceptual thing not something you can walk-through.  I generally tell people that a video file format is a bit like a filing cabinet, it gives the general organization, but doesn't define the data held within.  The codec is like the filing system and determines how the data the file format holds is stored.

As far as choosing what file format to use or codec, again, with so many to choose from, they really are better covered in tutorials about a specific need.  H.264 in general ends up being by far the most common these days and the file format itself is more or less irrelevant as long as it's using an H.264 codec since it's fairly simple to move an H.264 stream from one format to another.

Similarly, CBR vs VBR 1 pass vs VBR 2 pass is again really more of a conceptual thing rather than something a tutorial can cover.  Most people seem to get it ok when you simply describe video as a bunch of photos and say that CBR uses the same amount of data for every photo, regardless of how complicated the picture is, VBR 1 pass uses less when it notices that a photo is easy to store and more when it is hard and VBR 2 pass looks through all the photos first to make sure that it makes all the photos the overall best quality they can be by spreading the data around to where it's needed.

Ultimately though compression in and of itself is a field that people spend their entire careers in.  It is very deep and complex and you really aren't going to find an all inclusive tutorial to cover everything.  It simply doesn't exist.  The closest I've ever seen was actually the section on encoding in one of the Premiere Pro manuals (I think it was CS2, but it might have been Premiere Pro 6.5 (pre Creative Suite).) but that content is a bit dated now as that was DVD era and prior to H.264 really taking center stage for most purposes.