We study partially hyperbolic diffeomorphisms homotopic to the identity in 3-manifolds. Under a general minimality condition, we show a dichotomy for the dynamics of the (branching) foliations in the universal cover. This allows us to give a full classification in certain settings: partially hyperbolic diffeomorphisms homotopic to the identity on Seifert fibered manifolds (proving a conjecture of Pujals [BW05] in this setting), and dynamically coherent partially hyperbolic diffeomorphisms on hyperbolic 3-manifolds (proving a classification conjecture of Hertz-Hertz-Ures [CRRU15] in this setting). In both cases, up to iterates we prove that the diffeomorphism is leaf conjugate to the time one map of an Anosov flow. Several other results of independent interest are obtained along the way.