First-principles study of the dielectric and dynamical properties of orthorhombic CaMnO3