Genarlow Wilson's joy was short-lived.

One minute, a judge ordered him released from prison, saying the young man's 10-year sentence for consensual sex between teens was a "grave miscarriage of justice." Ninety minutes later, Georgia's attorney general said Wilson wasn't going anywhere — the state had appealed.

On Tuesday, Wilson's attorney was fighting to at least get him released on bond during the appeal process. He is now 21 and has been behind bars for more than 28 months.

"Yesterday, they did not consent to a bond," attorney B.J. Bernstein said Tuesday in a cable news interview. "We are hopeful to hurry up and get in front of a judge — one, to get him out pending an appeal, but even more importantly, to get this madness over with."

Bernstein sought a hearing Tuesday in Douglas County court, where Wilson was convicted, even though the district attorney there opposes his release. Douglas County Superior Court Judge David Emerson set the bond hearing for July 5, another three weeks away.

Wilson became a symbol for extreme cases of getting tough on sex offenders when he was sentenced to the mandatory 10-year sentence for having consensual oral sex with a 15-year-old girl in 2003, when Wilson was 17.

If he had instead had sexual intercourse with the teen, he would have fallen under Georgia's "Romeo and Juliet" exception. But under the law in 2003, oral sex for teens still constituted aggravated child molestation and carried a mandatory sentence, plus listing on the sex offender registry.

Lawmakers last year voted to close that loophole, but the state's top court said the new law could not be applied retroactively to Wilson's case.

"As far as I'm concerned, this case is a throwback to Southern justice," said state Sen. Vincent Fort, an Atlanta Democrat and one of several prominent supporters who have rallied to Wilson's cause.

Opponents of Wilson's release said it could lead to similar legal challenges. Georgia prisons currently hold 189 inmates who were sentenced for aggravated child molestation when they were 21 or younger.

In his ruling Monday, Judge Thomas H. Wilson, no relation to Genarlow Wilson, amended that sentence to misdemeanor aggravated child molestation with a 12-month term, plus credit for time served. The habeas corpus hearing was held in his Monroe County court because Genarlow Wilson is imprisoned in Monroe County.

"The fact that Genarlow Wilson has spent two years in prison for what is now classified as a misdemeanor, and without assistance from this Court, will spend eight more years in prison, is a grave miscarriage of justice," the judge wrote. "If this court or any court cannot recognize the injustice of what has occurred here, then our court system has lost sight of the goal our judicial system has always strived to accomplish ... justice being served in a fair and equal manner."

In his notice of appeal, Attorney General Thurbert Baker argued that Georgia law does not give a judge authority to reduce or modify the sentence imposed by the trial court.

He said he would seek an expedited ruling from the Georgia Supreme Court. And he noted that a plea deal is on the table that would spring Wilson in a maximum of five years and also remove him from the sex offender registry.

That isn't good enough, Bernstein says.

"It is really ridiculous when you consider that we had a judge that just said it is a misdemeanor that carries no sex offender registration," she said. "It is extremely, extremely disturbing that the attorney general would take this action now."

A jury in 2005 found Wilson guilty of aggravated child molestation for having oral sex with a 15-year-old girl during a 2003 New Year's Eve party involving alcohol and marijuana. Although the sex act was consensual, it was illegal under Georgia law.

Wilson also was charged with rape for being one of several male partygoers at the Douglas County hotel to have sex with another 17-year-old girl, but was acquitted. The party was captured on a videotape that was played for the jury. Five other male partygoers took plea deals in the case. One has been released from prison and is now in college.

"I think he's certainly going to be changed," Bernstein said of her client Tuesday. "But fortunately, Genarlow has been taking this time in prison and reading like crazy.

"He wants to speak out to young people about realizing that when you party and carry on, you've got consequences sometimes grater than you realize. I think because of his extraordinary personality, he'll be OK, but I don't want this to happen to any other kid. It's crazy."