If you’re a Republican lawmaker in Oklahoma, you’re used to having pretty good job security.

More than 70 out of 101 seats in the House of Representatives are controlled by the GOP; of the Senate’s 48 members, all but nine are Republicans.

Yet Democrats have won the majority of legislative special elections this year — flipping four seats that were once comfortably in GOP hands.

In the most recent election, 26-year-old Allison Ikley-Freeman, the Democratic candidate, challenged Republican Brian O’Hara to win a seat in Senate District 37.

The seat opened up after incumbent Republican Dan Newberry announced his resignation over the summer. In the 2016 general election, Newberry handily defeated his Democratic opponent by 16 points. In 2012, Newberry had run unopposed.

The Republican not only had the power of a fairly safe GOP seat but had considerably more fundraising prowess. According to the state’s latest campaign disclosures, O’Hara spent $43,330.84. During the same period, Ikley-Freeman spent $15,508.54.

But then she won by 29 votes.

So what happened?

In a phone interview with The Intercept, Ikley-Freeman said that the voters she talked to were outraged primarily by one issue: the budget.

The experience of conservatives in deep-red Oklahoma districts, ousted on the back of anger at tattered budgets, doesn’t bode well for Republicans looking to pass a similar tax plan at the federal level. “The budget issue was the main motivator,” she said. “That’s when I’m knocking on doors, that was the main issue that I heard from people, was that the budget issue had them worried. It had them scared. And frustrated.”

After years of tax cuts, Oklahoma found itself in a similar situation to neighboring Kansas. Gov. Mary Fallin, who was elected as part of a tea party wave in 2010, made cutting taxes a priority. But when oil prices collapsed in 2014, so did much of the state’s remaining revenues.

Now Republicans at the national level are looking to replicate the disaster that was Oklahoma and Kansas. Sam Brownback, the former Republican senator from Kansas who left to become governor, even dropped by his old haunt on Wednesday to help rally his former colleagues on Capitol Hill.

Brownback, though, remembered it much differently. “What we did actually worked,” Brownback professed. 

That couldn’t be more wrong. In Oklahoma, residents saw the consequences unfold before them. Spending on essential services like education and mental health care plummeted. Earlier this year, the Washington Post reported that out of 513 school districts, 96 have eliminated either Monday or Friday classes because they can only afford to send kids to school for four days a week.

Even some unlikely voices started calling for tax increases. Dewey Bartlett Jr, former president of the Oklahoma Independent Petroleum Association lobbying group, said that the state needs to increase taxes on oil producers to fund services. “I came out of the closet,” Bartlett joked to the Christian Science Monitor. “We can’t cut our state government to the bone and expect our state to do well.”

Lawmakers failed to pass a budget fix  that would raise some taxes in order to fund services earlier this month, because it takes a 75 percent vote to enact a revenue-raising measure.

Ikley-Freeman is a therapist by training and acutely aware of the underfunding of mental health services.

“A consequence of this [budget] hole is our Department of Mental Health, that covers mental health for low-income Oklahomans in the state, have announced they are discontinuing coverage for outpatient services because they simply don’t have the funds to continue without this budget hole being closed,” she said.

She was skeptical of some of the budget fixes proposed by the Republican-led chamber, such as increasing regressive taxation on things like cigarettes. “It’s taxing low-income Oklahomans to pay for services like mental health that they couldn’t afford to begin with,” she said.

Another thing that benefited Ikley-Freeman was low turnout. Special elections typically have low turnout, and this one was no different. In her election, 4,437 people voted, compared to nearly 32,000 who voted in that same district in 2016. Democratic pollster Michael Whelan, who worked with Ikley-Freeman’s campaign, told the Washington Post that low turnout among Republicans was a factor in the election.

“The formula has been very similar for each of these races,” Whelan said of the Democrats’ special election victories in Oklahoma this year. “There are a lot of Republicans out there with buyer’s remorse with President Trump, which naturally suppresses turnout.”

Going forward, Ikley-Freeman plans to look at corporate tax breaks and incentives as a potential area to cut back to help fill the budget hole.

“We have a lot of corporations in Oklahoma who were given incentives to move here many many years ago that have continued and at this point are draining Oklahoma dry and really need to be discontinued,” she said.

Ikley-Freeman is one of the four Democrats who won special elections this year.

In House District 46, the Republican candidate won by almost 20 percentage points in the 2016 election. In this year’s special election, the Republican lost by around 20 points. In House District 75, the Republican candidate won by 19 points in the 2016 election. In the special election, the Democrat defeated the Republican by five points. In Senate District 44, the Republican won by 10 points during the last election in 2014. This year, the Democrats picked up the seat by nine points.

The collapse in Republican turnout may also foretell a similar situation in Alabama’s upcoming special election to replace Jeff Sessions, where GOP candidate Roy Moore faces off with Democrat Doug Jones. GOP turnout in the August Senate primary was low — at 17.62 percent.

Fallin is term-limited, and six Republicans, three Democrats, and three Libertarians will be competing in a June 2018 primary to succeed her. Earlier this year, a range of political watchers — from Larry Sabato’s Crystal Ball to Decision Desk HQ — deemed the state to be either “Likely Republican” or “Safe Republican.” After the series of unlikely Democratic wins this year, they — along with many of their allies in Congress — may find themselves surprised in 2018.

Top photo: Hundreds of supporters and workers of the oil and gas field are bused into the Capitol to lobby against HB 1054 before the House of Representatives special session at the Oklahoma State Capitol in Oklahoma City on Wednesday Nov. 8, 2017. A plan to hike taxes on tobacco, alcohol, fuel, and energy production in order to plug a hole in Oklahoma’s budget and to stabilize state spending has fallen five votes short in the House amid bipartisan opposition. The full House voted 71-27 on Wednesday.