For Joe Stevens and Julio Valentin, the struggle to open New Jersey’s first medical marijuana dispensary often seemed like chasing a mirage.

While starting any business is a tall order, try getting into selling medical marijuana just as skittish state officials are making rules under the glare of a governor determined to make sure New Jersey has the toughest restrictions in the nation.

Over the span of 21 months, opening the doors to the Greenleaf Compassion Center in Montclair took dozens of meetings and conference calls, hundreds of pages of paperwork that included everything from background checks and financial disclosure forms to how to collect taxes on pot — and long battles for permits to grow at a secret location and then sell to chronically ill patients.

Stevens and Valentin, who poured their life savings into the project, were also forced to play a long waiting game:

They waited while Gov. Chris Christie shut the program down for months because he feared federal officials might arrest someone involved with medical marijuana in New Jersey. They waited while state officials messed up paperwork and kept changing the rules. And they waited while there was nothing but silence from Trenton.

To top it off, opening the state’s first medical marijuana dispensary brought a set of special circumstances you just don’t get when trying to open, say, a dry cleaning business.

For example, while the law allows cultivating and selling medical pot, state officials feared that buying marijuana seeds could actually run afoul of federal law. So they told the Greenleaf founders: please don’t let us know where you got those seeds — Jersey’s own version of "don’t ask, don’t tell."

"The people will see we kept our word. We would not stop the fight," Valentin said as Greenleaf welcomed its first patients on Dec. 6. "And I hate to say it, but it was a fight."

Proponents of medical marijuana said they’re glad Greenleaf kept up that fight, saying that if this group gave up, the whole effort would have ground to a halt.

Instead, Greenleaf wrote what could be the blueprint for medical marijuana dispensaries — and is already paving the way for others.

Just a few weeks ago, a dispensary planned for Egg Harbor Township secured the promise of crucial financing that was elusive because private lenders didn’t think the program would ever get off the ground. Bill Thomas, the leader of the effort, said with Greenleaf’s opening, "they could see the state is willing to open one and that patients show up."

Over the past year, Greenleaf’s founders gave The Star-Ledger behind-the-scenes access for a first-hand look at what it took to open New Jersey’s first medical marijuana center.

What emerged was a story of how two men who have been pals since their days in the Boy Scouts in Newark’s North Ward overcame an increasingly frustrating bureacratic maze set by a governor they suspected of trying to sabatoge the whole program.

The two often feared they’d lose it all — they’ve pumped half a million dollars into the project, and Stevens has put his house up for sale — as chronically ill patients seeking medical pot to ease their pain kept calling them. Some board members and growers quit amid the uncertainty.

There were weeks when the friends avoided each other to keep from coming to blows as the pressure mounted.

And there was a cold day this March when Stevens decided he’d had enough and told the world he was ready to quit.

"We have jumped every hurdle," he said that day. "My heart is in this, but I am at the end of my rope and I don’t know what to do."

The battle played out over a law Christie never liked — one that was signed by Democrat Jon Corzine the day before the Republican governor took office in January 2010.

Christie made no bones about it: without tight controls, the law had so many loopholes he feared Jersey could become like programs in California and Colorado that are derided as toker’s paradises.

His administration took 14 months to approve six potential dispensary operations in March 2011. Greenleaf made the cut, after Stevens and Valentin had plunked down a $20,000 state fee.

After an injury ended his career with the Newark Police Department, Valentin, 43, had opened Eclectic Café, an upscale coffee bar featuring live music in Montclair in 1997. After 15 years as a funeral director and four the medical imaging field, Stevens, 40, was ready for a big change. They were planning a dispensary two years before New Jersey passed a medical marijuana law.

"I heard families’ stories about how (marijuana) brought people quality of life," Stevens said. He wondered whether marijuana could have eased some of his father’s suffering before he died of non-Hodgkin lymphoma.

But just a month after Stevens and Valentin got the go-ahead to build a medical pot business, Christie slammed the brakes on the program to get assurances federal officials wouldn’t arrest anyone involved with it. It stalled everything until the summer of 2011.

The duo then rented and hired a crew to gut a former tobacco "head shop" in a century-old building on Bloomfield Avenue. They leased and renovated a 5,000-square-foot space for cultivation. And they learned everything they could about growing medical pot.

After filling out mountains of paperwork and meeting each state request, Stevens and Valentin spoke with state health officials last December, confident they’d get permission to start growing pot.

Instead, the state produced a new list of requirements and raised more questions. For example, the state had asked them to install two security cameras and they had. Now, state officials said, there needs to be seven cameras — and you can’t get permission to grow pot unless you have them. They were stunned.

"There’s no reason for me to go there and get upset, to stare at a half-empty storefront," Stevens said in January. "We signed leases worth thousands of dollars. What business can last two years without any revenue? I got a call from 67-year-old man from Cedar Grove wants to know when he can pick up his medication. I have no answers."

In February, their spirits were higher. Speaking above the banging of workmen’s hammers in February, Valentin enthusiatically predicted the dispensary would be done by early March. "We’re at the framing stage now, everything was gutted, and electrical, heating and air should be coming Monday... It’s a good feeling."

It didn’t last long. With no word from the state, the frustration boiled over in March as Stevens stood in the half-finished dispensary and went public with his threat to quit. He sent a letter to Christie accusing him of rigging the rules so medical marijuana would fail in New Jersey.

The governor dismissed the criticism, telling Stevens to "get back to work" and defending his approach: "I’m not going to compromise the safety and the security of this program."

But that public spat actually helped break the biggest logjam.

RELATED COVERAGE:

• Medical marijuana activist makes his first legal purchase in Montclair

• N.J.'s first medical marijuana clinic finally opens, welcoming 20 patients

• First N.J. medical marijuana facility to open Thursday in Montclair

• Medical marijuana holdup: Sales tax question stalls N.J. legalization

It was followed by a lawsuit from medical marijuana advocates who claimed the state was purposely delaying the law’s implementation. The governor also faced criticism from across the state that he was stalling while chronically ill New Jerseyans were suffering.

Greenleaf, supporters said, was doing everything by the book, so if this group couldn’t get approved, none would.

In this lowest moment, when Stevens wanted to quit, Valentin told his friend what was at stake. None of the five other nonprofits was close to opening, so giving up would be disappoint the people who had been calling them for months, he said.

"We are here for the patients, the people of New Jersey with the debilitating conditions," Valentin said. "They are the ones who are suffering."

Within a month, things changed. Meetings were held, and Stevens and Valentin credit John O’Brien, a retired State Police lieutenant Christie hired to run the medical marijuana program, with putting it all back on track. Greenleaf starting growing the state’s first legal marijuana crop in April.

The job of growing the pot fell to Ricardo Luis, 33, who met Valentin and Stevens when they came to the hydroponics store he managed in April to ask for some advice. A Union native, Luis started cultivating Greenleaf’s marijuana plants without pay in April, and quit his job last month to work full time for Greenleaf.

"I feel great to be a part of it all, to help them to be the first to open up. It’s a medicine that does help," he said.

Luis is not only the lead cultivator. Suffering from a seizure disorder after a benign vascular tumor was cut out of his brain when he was 15, he is a registered patient with the state’s medical marijuana program. And when his name rises to the top of the list, he will become a Greenleaf customer.

Follow @starledger