ALBANY – Adult recreational use of marijuana will be legalized under a plan advanced today by Gov. Andrew M. Cuomo along with the creation of three new taxes – eventually passed on to consumers – that will total $300 million annually.

The Cannabis Regulation and Taxation Act will regulate marijuana from cultivation to retail sales “for the purposes of fostering and promoting temperance in their consumption” and “to promote social equality,’’ according to Cuomo’s budget plan unveiled this afternoon.

Not all the details of the program were immediately released, such as law enforcement strategies to deal with people who drive while high, or precisely how many retail operations will be located in the state.

The plan calls for the creation of an Office of Cannabis Management.

Cuomo had been steadfastly opposed to marijuana legalization, calling it only a couple of years ago a dangerous “gateway” drug. But, as he has moved to the left on an assortment of issues, Cuomo relaxed his views after a state study panel he appointed last year said there were now more benefits than risks to legalizing recreational use of marijuana.