I was a little surprised why someone would have to resign for this, or thought "Well, just another thing about how America is so uptight... If it's a consensual relationship, who cares?" But, I did some digging to learn more why, and it's explicitly against house rules to have relationships with staffers. I worked on campaigns when I was younger and relationships on campaigns between staffers and even the candidate were relatively common ... not necessarily acceptable, but common as a sort of "open secret." At least, everybody would know somebody on some campaign who was allegedly hooking up with someone.
But, in 2018 in the wake of a slew of sexual misconduct allegations, the House passed bipartisan internal rules barring relationships between House members and their staffers:
It's explicitly against the rules, and was passed to prevent abuse, as well as a handful of other changes protecting accusers and shielding tax payers from footing the bill for law suits that come out of relationships like these:
House prohibits sexual relationships between lawmakers and their staffers
...
"Thanks to the #MeToo movement, the American public has made it clear that they have had enough," said Rep. Jackie Speier (D-Calif.). "They expect Congress to lead, and for once we are."
The bipartisan bills are Congress's most definitive response to the #MeToo campaign and the wave of harassment and misconduct scandals that have led to at least eight members resigning or announcing plans to retire in the past four months. Amid a national reckoning over sexual misbehavior in the workplace, news reports exposing lawmakers' secretive process for settling harassment complaints with taxpayer dollars pushed House leaders to confront criticisms of the system.
"With this bill we are shining a blazing light on the scourge of workplace abuse, which has been allowed to fester in the shadows for too long," said House Minority Leader Nancy Pelosi (D-Calif.).
In response to the "Ridiculous that Hill should resign when men wouldn't" or what have you, 8 male congressmen resigned amidst similar allegations of misconduct in 2018. The imbalance of power in relationships like this has always been on the periphery, but now they're front-and-center and this is a response to decades, or perhaps centuries, of potential abuse and liability.
Cynical opinion: People only "feel sorry" for her because she's an attractive woman. If she were a balding white guy in his late 40's, there would be no sympathy here.
I think people feel sympathetically for her because rumors suggest her husband also released compromising photos of her with the person she was seeing, so she's likely a victim of revenge porn as well.
But I think you're right in that if she was a man or a Republican woman, I don't think there'd be many people mourning her resignation over this. .. I'd have written her off as a scumbag. But that'd also change this story pretty significantly in the wake of why the House passed that resolution in 2018 in the first place.