Jon and Noel started talking about having a family not long after they married in 2013.

An author and a professor who have been together more than a decade, the couple considered adoption, but settled on surrogacy out of a strong desire to have a biological child.

That plan was derailed last year when a southern Utah judge denied their petition to enter a surrogacy agreement with a woman who wanted to help make their family complete.

“We were shocked and we were hurt,” said Noel, who along with his husband spoke on condition they be identified only by first names to protect their privacy. “Straight couples don’t experience this.”

The couple is asking the Utah Supreme Court to declare a portion of the state’s gestational surrogacy law unconstitutional because it deprives gay men the right to have biological children through surrogacy.

That’s because under the law a married couple is required to provide medical evidence that the intended “mother” is medically unable to unable to carry a child.

That means the law can be used when the prospective parents are married heterosexuals or married lesbians, but married gay men are left out.

That exclusion violates the due process and equal protection clauses of the U.S. Constitution, as well as the uniform operation of law clause in the Utah Constitution, attorneys for Noel and Jon wrote in court papers.

“As written, [the law] creates two classes of intended parents; one class for married same-sex male couples and another class for married couples where at least one of the intended parents is female,” attorney Edwin Wall wrote in a brief filed with Utah’s high court.

Justices are set to hear argument in the case on Tuesday at 11 a.m.

The case is the first of its kind to come before the Utah court.

It may also be the first time any U.S. court has considered a challenge to surrogacy laws, which differ from state to state, on similar grounds, Yale law professor Douglas NeJaime said.

“It’s a complicated question.” said NeJaime. “But, I think these are new arguments and there has yet to be a court the country that has struck down a surrogacy law on the grounds that the discrimination is based on sexual orientation or gender.”

The Utah case is on appeal from the 5th District, where in August 2016 Judge Jeffery C. Wilcox said he believed he had no choice but to deny Jon and Noel’s petition “because neither of the legally married intended parents are women.”

Utah’s current surrogacy law was enacted in 2005, well before same-sex marriage was legal in the Beehive State. Under the statute, surrogacy agreements are only enforceable if they have been approved by a judge.

Widenar University law professor John Culhane, who frequently writes about legal issues for LGBTQ individuals and couples, said Utah’s law seems reasonable when viewed strictly as a contract issue, but it doesn’t work in the wake of the 2015 U.S. Supreme Court decision in Obergefell, which legalized gay marriage for the country.

“If marriage equality really means what the Supreme Court said it does, then that should mean this gay married male couple should have the same entitlements as others,” said Culhane.

Attorneys for Jon and Noel make a similar argument in court documents, adding that the Utah law may need a rewrite by legislators to remove gender-specific terms.

“The legislative objective was to afford the marital benefit for intended parents to have their own genetically related children,” court papers say, “not to improperly discriminate against married same-sex male couples.”

The equality argument, Culhane said, is one that any state would be hard-pressed to defend against.

“It’s tough to see how you could really exclude two men, or argue that the statute has to be read by its strict terms,” he said.

In fact, the Utah attorney general’s office, which typically defends state laws before the court, is not fighting Jon and Noel’s case.

In its own brief, the office agrees that the district court’s order should be reversed and supports a gender-neutral reading of the statutes, the brief from Assistant Solicitor General Brent Burnett said.

That’s an important and interesting twist to the case, DeJamie said, but that doesn’t necessarily mean the case will go as easily as some may believe.

“I can assure you that a lot of other states where this question will arrive will fight it,” he said, because in some places, terms like “mother” and “father” have been used specifically to bar gay couples from parenthood.

Jon and Noel said they initially considered abandoning their dreams of raising a family.

Ultimately, they said they decided to challenge the ruling to help ensure that all couples have the same rights in Utah and across the country.

“We were able to marry because of what other people had done and in a small way, we could participate in helping to ensure rights for people like us,” said Noel. “We’d like to have a child. We think that’s not an unreasonable request of the state.”