Cumulative impact of health deficits, social vulnerabilities, and protective factors on cognitive dynamics in late life: a multistate modeling approach