The SPHERE infrared survey for exoplanets (SHINE): IV. Complete observations, data reduction and analysis, detection performances, and final results