Physical Conditions in the Narrow-Line Region of M51