Jim Parsons gets the lion’s share of credit for the runaway success of “The Big Bang Theory.” His Emmy-winning portrayal of Sheldon Cooper was the ultimate revenge of the nerds. But the sitcom wouldn’t have worked without Kaley Cuoco. Her spin on the “dumb blonde” gave the series the humanity that the brainiacs next door were too stupid to discover on their own.

The underrated Cuoco’s talents get even more of a showcase in HBO Max’s “The Flight Attendant,” an eight-part series about Cassandra, a globe-trotting party girl forced to grow up after she wakes up next to a bloody corpse.

It’s a gruesome premise, but Cuoco manages to inject humor into the murder mystery with her slapstick reactions to the chaos. In one scene, she survives a grim visitation held for her late one-night stand by emptying every Champagne glass in sight. When her character suffers a panic attack, you can almost see her channeling the late John Ritter, her co-star on “8 Simple Rules.”

“If you were to remove the humor from the show, then it would just be like, ‘Oh, my gosh. This is so traumatic,’ ” said showrunner Steve Yockey, who shut down production for several months due to the pandemic. The cast returned in August to shoot the final three episodes. “It’s the humor that really makes it lift and pop.”

Cuoco was looking for a new adventure that wouldn’t detour too wildly from Penny Hofstadter, the “Big Bang” role that would eventually earn her $1 million an episode.

“I just love the art of making someone laugh, and not taking yourself too seriously,” Cuoco said this summer during a Television Critics Association virtual press conference. “Obviously, I did that for years on the show [‘Big Bang’], and loved it and would do it again in a heartbeat. This was a great, kind of a new path, but not so far off that people are like, ‘What is she doing?’ There’s still that levity and that side of me that gets to come out.”

Cuoco also had the chance to stretch behind the camera by taking up executive producer duties for the first time.

The 34-year-old actor had a tough time finding something she wanted to get behind until she came across a snippet from Chris Bohjalian’s 2018 book, “The Flight Attendant,” on Amazon.

“It was just one sentence,” she said. “I got this weird chill and I called my team and said, “Hey, I’d love to get the rights to this book.’ And their first question was, ‘OK, so you read the book?’ And I’m like, ‘Oh, yeah. I totally read the book.’ ”

She had not read the book.

While her team jumped into action, Cuoco tore through the novel.

“Thank God I loved it as much as I thought I would,” she said. “There was a bidding war and I won the rights. Then I’m like, ‘What do I do now that I’ve got it?’ Like, I didn’t believe it.”

One of the most important steps was surrounding herself with a top-notch cast, which includes Oscar nominee Rosie Perez as a fellow flight attendant and Minnesota native T.R. Knight as her long-suffering brother. Zosia Mamet, who plays Cassandra’s best friend, said Cuoco is just as warm in real life as she is on screen.

“Kaley and I read together in front of a room of people and everyone was like, ‘Did you two know each other before?’ And I was like, ‘No, we just met,’ ” said Mamet, best known for “Girls.” “I think she bopped me on the nose in a little improv we did. It was love at first sight.”

Cuoco’s ability to keep “bopping” viewers throughout a thriller keeps you rooting for Cassandra — even if she might have blood on her hands.