Solar Impulsive Hard X-Ray Emission and Two-Stage Electron Acceleration