Massive phonons and gravitational dynamics in a photon-fluid model