Laterally deformable nanomechanical zeroth-order gratings: anomalous diffraction studied by rigorous coupled-wave analysis.