Theoretical study of the ground-state geometry and excited-state spectrum of pernitric acid (HO2NO2)