The Supreme Court’s historic decision establishing marriage equality for same-sex couples nationwide marked a major shift in the recognition of gay, lesbian, and bisexual people as a central part of the fabric of American society. Transgender people, however, continue to face barriers to full equality. One such barrier has been much discussed: State laws and school board policies—like the one adopted by a school board in Virginia against Gavin Grimm—that bar transgender people from using school restrooms.

Another barrier is, ironically, the Americans with Disabilities Act, a federal law that prohibits discrimination against people with stigmatized medical conditions—unless that stigmatized medical condition is “gender identity disorder” (GID). The story of how the ADA’s GID exclusion came to be, and why one federal court says it must now end, tells us much about the next civil rights frontier: Transgender equality.

In 1989, on the floor of the Senate, Republicans William Armstrong and Jesse Helms urged their colleagues to vote against the ADA because it could protect what they characterized as “immoral” medical conditions. “If this were a bill involving people in a wheelchair or those who have been injured in the war, that is one thing,” Helms quipped, using language we might now expect from President Donald Trump or Attorney General Jeff Sessions, “but how in the world did you get to the place that you did not even [ex]clude transvestites” and people “engaged in activities that most Americans find abhorrent”? For Helms, the ADA flew in the face of an employer’s right to set up “moral standards” for his business—the right to ask his employees, “Are you HIV positive? Are you this or that?”

Although the ADA’s progressive sponsors, the late Sen. Ted Kennedy and Sen. Tom Harkin, vigorously defended the ADA’s protection of people with HIV/AIDS, no one stood to defend the transgender community’s inclusion in the law. To secure passage of the ADA, “gender identity disorders” were excluded alongside “pedophilia,” “pyromania,” “kleptomania,” and a few other conditions deemed “sexually deviant.”

For 25 years, the ADA’s exclusion of transgender people stood unchallenged. On Thursday, that finally changed, thanks to a courageous woman named Kate Lynn Blatt.

In the fall of 2006, Cabela’s Retail Inc., a popular sporting goods store, hired Blatt, a transgender woman, as a merchandise stocker. Blatt explained to Cabela’s that she has gender dysphoria—a serious but treatable condition that does not interfere with her ability to do her job as long as she is permitted to live her life fully as a woman.

Despite notifying her employer about her medical needs, Cabela’s refused the very modest accommodations she requested. It would not issue her a female uniform or a name tag bearing her female name. And it refused to allow her to use the female employee washroom, suggesting that she use the bathroom at a Dunkin Donuts across the street.

When Cabela’s abruptly fired her after just six months on the job, Blatt sued under the ADA. Cabela’s responded that she had no case—pointing to the ADA’s GID exclusion.

Blatt then did something that no one had ever been done before. She and her lawyers, Sidney L. Gold, Neelima Vanguri, and Brian Farrell of Sidney L. Gold & Associates, argued in court that the ADA does not exclude her. On Thursday, a federal district court in Pennsylvania agreed. It did so in a brilliant opinion that made two important points.

The first was that being transgender—identifying with the gender different than a person’s designated birth sex—is not itself a medical condition. The second was that gender dysphoria—the clinically significant distress that some transgender people experience as a result of identifying with the gender different than the one designated at birth—is a medical condition.

Based on these two points, the court concluded that transgender people with gender dysphoria are not excluded from pursuing civil rights protections under the ADA. To find otherwise, the court suggested, would have required it to answer a question of constitutional magnitude about whether there is any defensible justification for excluding transgender people from a federal civil rights law. (There isn’t.)

Blatt’s successful challenge will reverberate far beyond her individual case, setting the stage for legal challenges to discriminatory laws and private activity that target all transgender people—those who experience gender dysphoria and those who do not. The ADA’s unique requirement of “reasonable accommodation” provides a commonsense solution for many of the problems created by anti-transgender bathroom, housing, hospital, and employment policies, and beyond. While not technically binding on other courts, the court’s decision in Blatt’s case will strongly influence federal and state courts to come, given its careful interpretation of the words of the ADA and its consistency with contemporary medical standards.

The seeds of prejudice in the ADA have sown the future of transgender rights advocacy. For this, a debt of gratitude is surely owed—not to the conservative congressmen who held transgender people back, but to Blatt and other transgender pioneers who, in the words of Justice Anthony Kennedy, “furthe[r] our understanding of what freedom is and must become.”