  Complex Chern-Simons bundles are line bundles with connection, originating in
the study of quantization of moduli spaces of flat connections with complex
gauge groups. In this paper we introduce and study these bundles in the
families setting.
  The central object is a functorial direct image of characteristic classes of
vector bundles with connections, for which we develop a formalism. Our strategy
elaborates on Deligne-Elkik's intersection bundles, and a refined Chern-Simons
theory which parallels the use of Bott-Chern classes in Arakelov geometry. In
the context of moduli spaces, we are confronted with flat relative connections
on families of Riemann surfaces. To be able to rely on the functorial approach,
we prove canonical extension results to global connections, inspired by the
deformation theory of harmonic maps in non-abelian Hodge theory.
  The relative complex Chern-Simons bundle $\mathcal{L}_{CS}$ is then defined
as a functorial direct image of the second Chern class on the relative moduli
space of flat vector bundles. We establish the crystalline nature of
$\mathcal{L}_{CS}$, and the existence of a holomorphic extension of natural
metrics from Arakelov geometry. The curvature of $\mathcal{L}_{CS}$ can be
expressed in terms of the Atiyah-Bott-Goldman form, in agreement with the
classical topological approach.
  To highlight a few applications, we first mention a characterization of
projective structures of Riemann surfaces in terms of connections on
intersection bundles. In particular, we settle a conjecture of
Bertola-Korotkin-Norton on the comparison between the Bergman and the Bers
projective structures. This is the problem of determining the accessory
parameters of quasi-Fuchsian uniformizations. A conjecture of Cappell-Miller is
also established, to the effect that their holomorphic torsion satisfies a
Riemann-Roch formula.
