Since heavy-quark pairs can be produced by gluon-gluon or photon-gluon fusion at the lowest perturbative order in QCD, quarkonium production in hadron-hadron or lepton-hadron collisions is a promising probe of the poorly-constrained gluon density of the proton. The physics of the three-dimensional (in momentum space) gluon and quark structure of the proton, encoded in transverse-momentum dependent parton distribution functions (TMD PDFs), is dominated by abundant collinear and soft gluon radiation. However, the formation mechanism of two heavy quarks into a bound state is also controlled by soft gluon exchange. A robust theoretical description of quarkonium production in TMD factorization thus needs to account for the interplay between both sources of gluon radiation. I will describe some recent attempts in doing so making use of effective field theories.