  In this work, we study the local zeta functions of Calabi-Yau fourfolds. This
is done by developing arithmetic deformation techniques to compute the factor
of the zeta function that is attributed to the horizontal four-form cohomology.
This, in turn, is sensitive to the complex structure of the fourfold. Focusing
mainly on examples of fourfolds with a single complex structure parameter, it
is demonstrated that the proposed arithmetic techniques are both applicable and
consistent. We present a Calabi-Yau fourfold for which a factor of the
horizontal four-form cohomology further splits into two pieces of Hodge type
$(4,0)+(2,2)+(0,4)$ and $(3,1)+(1,3)$. The latter factor corresponds to a
weight-3 modular form, which allows expressing the value of the periods in
terms of critical values of the L-function of this modular form, in accordance
with Deligne's conjecture. The arithmetic considerations are related to
M-theory Calabi-Yau fourfold compactifications with background four-form
fluxes. We classify such background fluxes according to their Hodge type. For
those fluxes associated to modular forms, we express their couplings in the
low-energy effective action in terms of L-function values.
