  The rapidly developing and converging fields of polaritonic chemistry and
quantum optics necessitate a unified approach to predict strongly-correlated
light-matter interactions with atomic-scale resolution. Combining concepts from
both fields presents an opportunity to create a predictive theoretical and
computational approach to describe cavity correlated electron-nuclear dynamics
from first principles. Towards this overarching goal, we introduce a general
time-dependent density-functional theory to study correlated electron, nuclear
and photon interactions on the same quantized footing. In our work we
demonstrate the arising one-to-one correspondence in quantum-electrodynamical
density-functional theory, introduce Kohn-Sham systems, and discuss possible
routes for approximations to the emerging exchange-correlation potentials. We
complement our theoretical formulation with the first ab initio calculation of
a correlated electron-nuclear-photon system. From the time-dependent dipole
moment of a CO$_2$ molecule in an optical cavity, we construct the infrared
spectra and time-dependent quantum-electrodynamical observables such as the
electric displacement field, Rabi splitting between the upper and lower
polaritonic branches and cavity-modulated molecular motion. This
cavity-modulated molecular motion has the potential to alter and open new
chemical reaction pathways as well as create new hybrid states of light and
matter. Our work opens an important new avenue in introducing ab initio methods
to the nascent field of collective strong vibrational light-matter
interactions.
