It has long been known that many questions concerning the distribution of the primes can be related to the analytic properties of the Riemann zeta-function and, in particular, the location of its zeros. In this talk, I will show how the classical Beurling-Selberg extremal problem in harmonic analysis arises naturally when studying the vertical distribution of the zeros of the Riemann zeta-function. Using this relationship, along with techniques from Fourier analysis and reproducing kernel Hilbert spaces, we can prove the sharpest known bounds for the number of zeros in a long interval on the critical line and we can also study the pair correlation of zeros. Our results on pair correlation extend earlier work of P. X. Gallagher and give some evidence for a well-known conjecture of H. L. Montgomery. This is based on joint works with Emanuel Carneiro, Vorrapan Chandee, and Friedrich Littmann.