The finite-temperature behavior of gluon and of Faddeev-Popov-ghost propagators is investigated for pure SU(2) Yang-Mills theory in Landau gauge. We present nonperturbative results, obtained using lattice simulations and Dyson-Schwinger equations. Possible limitations of these two approaches, such as finite-volume effects and truncation artifacts, are extensively discussed. Both methods suggest a very different temperature dependence for the magnetic sector when compared to the electric one. In particular, a clear thermodynamic transition seems to affect only the electric sector. These results imply in particular the confinement of transverse gluons at all temperatures and they can be understood inside the framework of the so-called Gribov-Zwanziger scenario of confinement.