In-content tabs and nesting

My intention is to present installation instructions for a software to the user. The document has 3 versions, the second of which has 5 sub-versions:

  1. Binary installation (default for windows and OSX, possible only there)
  2. Source installation (default for linux, possible everywhere)

    1. Ubuntu/Debian
    2. Arch
  3. Development installation (possible everywhere)

And I want it so that only one consistent and relevant version of the document document is seen (and can be linked to) at once, e.g. “Binary installation” or “Source installation for Arch”

Here is what I have now (It’s cropped so ignore the wonky purple header,a nd i already fixed the indentation in the second code sample):

nested tabs

I like it except that (a) I should switch the long-form description (“Installing from source (…)”) to text instead of a header, and (b) it’s not clear that switching between the binary/source/development tabs replaces everything until “Running the notebook”.

Questions:

  1. Is there better UX that more clearly shows that you can switch out the whole “Installation” section? Putting a frame/shadow around it (like in the nested tab area) would fix it but look bad imho.
  2. I don’t think that nested tabs in general are a bad idea, but some people seen to think so. I think this is a valid use case for them, except for the shortcoming mentioned in the first question. Do you agree?