The impulsive phase of a solar flare marks the epoch of rapid conversion of energy stored in the pre-flare coronal magnetic field. Hard X-ray observations imply that a substantial fraction of flare energy released during the impulsive phase is converted to the kinetic energy of mildly relativistic electrons (10-100 keV). The liberation of the magnetic free energy can occur as the coronal magnetic field reconfigures and relaxes following reconnection. We investigate a scenario in which products of the reconfiguration - large-scale Alfven wave pulses - transport the energy and magnetic-field changes rapidly through the corona to the lower atmosphere. This offers two possibilities for electron acceleration. Firstly, in a coronal plasma with beta < m_e/m_p, the waves propagate as inertial Alfven waves. In the presence of strong spatial gradients, these generate field-aligned electric fields that can accelerate electrons to energies on the order of 10 keV and above, including by repeated interactions between electrons and wavefronts. Secondly, when they reflect and mode-convert in the chromosphere, a cascade to high wavenumbers may develop. This will also accelerate electrons by turbulence, in a medium with a locally high electron density. This concept, which bridges MHD-based and particle-based views of a flare, provides an interpretation of the recently-observed rapid variations of the line-of-sight component of the photospheric magnetic field across the flare impulsive phase, and offers solutions to some perplexing flare problems, such as the flare number problem of finding and resupplying sufficient electrons to explain the impulsive-phase hard X-ray emission.