MADISON, Wis. (AP) — Democratic Wisconsin Sen. Tammy Baldwin, one of the most liberal members of Congress, defeated Republican Leah Vukmir, a staunch supporter of President Donald Trump, to win a second term Tuesday.

Baldwin led Vukmir in fundraising and the polls throughout the race. Vukmir campaigned as the underdog and urged Republicans who supported Trump to surprise the pollsters like they did in 2016.

But Democrats came through for Baldwin in a race that marked the first time in Wisconsin history both major party candidates for U.S. Senate were women.

Baldwin has recent history on her side: In the last three midterm elections, no incumbent Wisconsin senator from the party not in the White House lost a re-election bid.

Baldwin, 56, won her first local race at age 24 and was elected to the Senate in 2012, beating former Republican Gov. Tommy Thompson, in a year when former President Barack Obama was also on the ballot. Baldwin was the first openly gay person elected to the Senate.

Vukmir, first elected to the Legislature in 2002, is one of the Senate’s most conservative members. She is a close ally of Republican Gov. Scott Walker, helping to pass the Act 10 collective bargaining law, 20-week abortion ban and right-to-work bill.

Baldwin and Vukmir disagreed on every major issue including health care, immigration, taxes, abortion, national security, gun control and criminal justice.

Baldwin said in her victory speech that the win sends a “loud and clear message” that people in Wisconsin want a senator who will stand up for them against special interests. Baldwin was an early target for outside conservative groups that spent millions attacking her over the summer. But after Vukmir won the August primary, Baldwin outraised her more than 5-to-1.

“Democrats, Republicans and Independents sent a loud and clear message tonight that they wanted a senator who works not for the special interests, but someone who works for you,” Baldwin said.

Stephenie Hamen, a 42-year-old artist from Sun Prairie, said she voted for Baldwin, in part as a vote for women’s rights and a vote against Trump.

“I don’t know if it was to vent (against the president),” she said. “It’s a way to stand up for women as Americans and be heard. It’s a scary time to be a woman in America. No matter what (Trump) says about being a white man in America, it’s scarier for women and minorities. If the Republicans stay in power, we’re writing a check for that party to do whatever they want. If we continue down that path we have no idea what’s coming next.”

While Baldwin campaigned with former President Barack Obama and independent Vermont Sen. Bernie Sanders, Vukmir rallied with President Donald Trump and forcefully supported his Supreme Court pick Brett Kavanaugh. Baldwin voted against his confirmation.

Baldwin is a supporter of Sanders’ “Medicare for All” bill and ran as a defender of the Affordable Care Act. Baldwin cast Vukmir, a nurse, as the potential deciding vote to repeal the law and its guarantees of insurance for people with pre-existing conditions.

Vukmir, 60, focused on Baldwin’s handling of the opioid over-prescription crisis at the Tomah Veterans Affairs Medical Center, saying her inaction let veterans down. But the widow and parents of a veteran who died there has come out in support of Baldwin, cutting television ads to help her and undercutting Vukmir’s criticism.

Baldwin recounted the story of her childhood illness that made her an advocate for universal health coverage, while also speaking in detail for the first time about her mother’s struggles with mental illness and prescription drug abuse. Baldwin said that has fueled her fight against opioid abuse.

Baldwin portrayed Vukmir as siding with insurance companies over people, citing her votes in the Legislature against bills the insurance industry opposed that would expand insurance coverage for hearing aids and cochlear implants, mental health care and substance abuse treatments and access to oral chemotherapy.

Vukmir said her positions were misrepresented, and as a nurse she was looking out for the best interests of health care consumers.