PORTLAND, Ore. (CN) — In a federal lawsuit against Oregon, the United States and a school district, parents and students say a school district’s policy on gender identity creates the “unavoidable consequence” that their children will see students of the opposite sex naked.

Parents for Privacy and its members say Dallas School District No. 2 et al. violates children’s civil rights by forcing them to share locker rooms with students whose gender identity does not match their biological sex.

They claim the government is holding education funding “hostage” by threatening to cut off Title IX funding to schools that do not comply with federal policy. Defendants include Oregon’s governor, the U.S. Secretary of Education, and Attorney General Jeff Sessions and their agencies.

Dallas, Oregon, pop. 15,000, is about 15 miles west of Salem, the state capital. It is the seat of rural Polk County.

Oregon this year became the first state to allow residents to mark a “not specified” gender option on state identification cards. Its Department of Motor Vehicles now allows people to mark an “X” for a non-binary gender on driver’s licenses and ID cards.

Last year, an Oregon judge granted an Army veteran’s petition to be legally considered “non-binary,” in a first-of-its-kind ruling.

Advocates for transgender rights praised those decisions in one of the nation’s most politically progressive states, but as in other states, rural parts of Oregon tend to be more conservative.

The parents object to a May 2016 directive from the Obama administration. The joint guidance from the Department of Justice and Department of Education did not create any legal requirements, but told schools that they must treat transgender students according to their gender identities.

Around that time, the Oregon Department of Education issued related guidelines for transgender students. Among other things, the guidelines recommended that non-binary students should be allowed to use the bathrooms that match their identities.

The parents claim those guidelines, and policies such as the one adopted by the Dallas School District, improperly substitute gender identity for “sex” for Title IX purposes.

“The consequence of the federal rule and the district policy is unavoidable: adolescent students, in the midst of disrobing within private intimate spaces, will encounter an adolescent student of the opposite sex in their midst,” the complaint states.

The school district adopted seven policies on harassment and student safety, which the plaintiffs say are hurting students.

Among other things, they say some students have been avoiding restrooms and locker rooms out of fear they will encounter someone who was born of the opposite sex.

The complaint cites “Student A,” who identifies as male, and was allowed to use the boys’ locker room and showers at Dallas High School.

The complaint refers to Student A using female pronouns, and claims allowing him to use boys’ facilities has damaging effects on male students.

Also, the parents say, “girl plaintiffs and other biologically female students at Dallas High School face living in ongoing anxiety, fear, and apprehension that a biological boy will be permitted to walk in at any time while they are using the school locker rooms or showers and see them in a state of undress or while changing.”

Dallas High School student Elliot Yoder testified at a school board meeting in December 2015 after school district officers said he could use the boys’ locker room. Yoder, then 14, used a unisex bathroom before asking to use the boys’ locker room.

“Yes, I was born as a female,” he said at the meeting, according to The Oregonian newspaper. “I disregard that part of myself completely when I’m in the boys’ locker room. I never fully undress. I don’t shower with them. I don’t even look at any of them. I don’t look at the person whose locker is directly below mine. I’m not in there to spy on your kids. I’m not in there for any other reason but to change in a place that is not completely separate from everybody else.”

The plaintiffs seek declaratory judgment and damages for violations of the Administrative Procedures Act, Title IX, religious freedom, due process and discrimination.

They are represented by Herbert Grey of Beaverton and Ryan Adams of Canby. The Nov. 13 lawsuit is 65 pages long.

Students and Parents for Privacy filed a similar lawsuit in Illinois last year, shortly after Chicago Public Schools announced that transgender students would be allowed to use bathrooms and locker rooms corresponding to their gender identities.

The Dallas School District did not respond to a request for comment.