It is shown how to explicitly coarse-grain the microscopic dynamics of the rule-based Vicsek model for self-propelled agents. The hydrodynamic equations are derived by means of an Enskog-type kinetic theory. Expressions for all transport coefficients are given. The transition from a disordered to a flocking state, which at large particle speeds appears to be a fluctuation-induced first-order phase transition, is studied numerically and analytically.