Mechanical and metallic properties of tantalum nitrides from first-principles calculations