PDF improvements

This addresses some of the issues raised in #2061 and #2060. I couldn't figure out how to add detailed section numbers to the PDF build, so I've left that off. However, this does fix the additional 2 chapters that should not be present.