What is the definition of disability used by Social Security?

Under the Social Security Act, "disability" means "inability to engage in any substantial gainful activity by reason of any medically determinable physical or mental impairment which can be expected to result in death or has lasted or can be expected to last for a continuous period of not less than 12 months."