Florida lawmakers agreed Wednesday to shut down the state's juvenile boot camps after the death of a 14-year-old boy who had been kicked and punched by guards.

The move, agreed to by House and Senate negotiators, is part of a state budget agreement that still requires both chambers' approval.

Under the deal, Florida's four remaining boot camps would be replaced with a new, less militaristic program. The state would pump an additional $32.6 million into juvenile justice programs, increasing total spending to $699.5 million.

"Unfortunately it has taken the death of a young man to get to this point," said Republican Rep. Gus Barreiro, chairman of the House Juvenile Justice Appropriations Committee.

The move was prompted by the death Jan. 6 of Martin Lee Anderson, who was roughed up in a videotaped scuffle at a Panama City boot camp. The camp was shut down after the boy's death, which remains under investigation and has drawn protests from civil rights leaders.

"Now there won't be any more children being abused while in the custody of the state," said attorney Ben Crump, who is representing Anderson's parents in a lawsuit against the state and the sheriff's office that ran the camp. "It is something good to have a legacy knowing that his death wasn't in vain."

Florida had nine juvenile boot camps at the height of the program but is now down to four, with about 130 offenders in all. The teenagers are sent there for mid-level crimes such as burglary and drugs, and usually stay for four to six months.

Guards operate like drill sergeants, typically waking up the teenagers at 5 a.m. for calisthenics, yelling in their faces, and using push-ups and running as punishment for breaking the rules.

Gov. Jeb Bush, who had been a strong supporter of the boot camps, has said he supports the new measures, which would take effect July 1.

The new juvenile programs, like the boot camps, would be run by sheriffs, but they would be closely monitored by the state. The programs would emphasize self-esteem and prohibit physical intervention between guards and youngsters. Under the old system, guards were legally allowed to physically intervene for disciplinary purposes.

A medical examiner concluded Anderson died of natural causes — a blood disorder. But the boy's family and others disputed that, and the body was exhumed for a second autopsy. The results have not been released, but the office of a special prosecutor has said Anderson did not die of natural causes.