WASHINGTON — Judging by most headlines, Katie McGinty had a forgettable week at the Democratic convention — she called her opponent "an a--hole" and, by many accounts flopped in the spotlight: political pundits panned her Thursday night speech.

A couple weeks later, though, she has surged in public opinion polls, turning her campaign against Sen. Pat Toomey (R., Pa.) into essentially a dead heat. The results, after a stretch in which Toomey had no obvious missteps and McGinty had no obvious gains suggests that much of their campaign may be out of their hands, and dependent instead of the Hillary Clinton-Donald Trump match up atop the ticket.

"In some ways, you could argue that she had a worse week and a half, 10 days than he did — and yet she's gotten closer," said Terry Madonna, the Franklin & Marshall pollster whose survey, released, Aug. 4, found McGinty with a 39-38 lead among likely voters.

On Monday a poll for WHTM-TV and ABC27 put McGinty up 42-40.

What gives? The key common factor: both surveys found Clinton extending a significant lead over Trump in Pennsylvania, 11 in the F&M poll, 10 in the ABC27 survey, reflecting her "bounce" from the Democratic National Convention in Philadelphia and a damaging week for Trump's campaign, when he feuded with the family of a slain American soldier and seemed to invite Russian hackers to unearth Clinton's personal emails.

"When I looked at these polls, basically what I saw was, when Hillary Clinton did better, the bigger the lead, the better that McGinty did — we're seeing a coattail effect," Madonna said.

(There was one exception: the Democratic outfit Public Policy Polling found McGinty within one percentage point of Toomey, even though Clinton's Pennsylvania lead was only three in their survey. That poll, however, was done earlier than the other two).

Toomey has long planned for a tough race — no matter who his opponent was — based on the idea that Democrats were likely to win the presidential contest in Pennsylvania, as they have six straight times.

But people close to him believe he can overcome a four- or five-point Trump loss in the Keystone State. Other Republican senators have won reelection under similar circumstances.

What would make for a steep climb — and maybe an impossible one — would be a 10 or 11 point Clinton win.

That's because over recent years fewer and fewer people have split their tickets — voting for one party for president, and then switching columns and choose the other party for Congress (in this example, Democrat Clinton for president, and then Republican Toomey for senate).

That's the fear worrying Republicans both in Pennsylvania and Washington, who know that a Toomey defeat could mean losing the chamber entirely.

McGinty has not scored too many direct hits on Toomey so far, but Madonna said she may not have to. Clinton's coattails may be enough.

"What does McGinty have to do? If Clinton hypothetically wins the state by 11 or 12 points, just ride the wave -- ride the wave," he said.

Of course, the big question is if Clinton can actually sustain that margin, or if the polls tighten, as they often do. Madonna said a clearer picture of the race may emerge later this month, once the noise of the two national conventions fade and pollsters find it easier to track which voters are actually likely to show up on Election Day.

You can follow Tamari on Twitter or email him at jtamari@phillynews.com.