Rearranged and simplified calculations related to page numbering and forced pages. Fixed force-page-count="auto" Removed some cruft.