CHONGQING, China — Huang Lincai is a cheery 23-year-old with a lot of optimism — even though he recently lost his job.

For nearly four years, he worked in one of the three cavernous Ford Motor assembly plants in Chongqing, a sprawling metropolis in southwestern China with almost 20 million people. Every day, he spent long hours putting brake fluid into the Ford Focus compact cars that glided past on the assembly line.

But with car sales plunging as the Chinese economy slows, Mr. Huang was laid off in January along with thousands of other workers at Ford’s factories, which are part of a joint venture with a Chongqing automaker.