The best way to fix all this is to load the ePub into Sigil, A/B compare the PDF to the ePub, fix the ePub as needed and use Sigil to generate the ToC.
PDF is a very poor format to use as a source format without a lot of fixing of the converted format.
|