I agree with horn34 about staying where you will be diving. One time we stayed for two weeks on Cozumel and then went to Isla for a week. It was a pain to get to. Probably better to just go there on a separate trip.
Cozumel: great diving, nice town, great restaurants, friendly people. Lots of taxis. Never had any worries. We now stay there at least a month each visit.
Isla Mujeres: interesting diving but mostly shallower, MUSA is interesting (once, anyway), lots of sea life. Lots of trash and dog poop, rude vendors, and we only found one restaurant we liked. Taxis can be very cheap if you share a ride. Never worried about our safety.
Loteto (Baja Sur): small town, friendly, some good restaurants, and although the diving can be less than spectacular sometimes the surrounding areas and islands are pretty-much undeveloped and the island beaches are quite beautiful. There is no public transportation and very few taxis so stay close to the marina or get ripped-off with a rental car. Prices tend to be higher than Cozumel or Isla Mujeres. I recommend Blue Nation for diving but have not tried other ops but then they were so good we felt no need to look elsewhere. No worries about safety.
Puerto Vallarta: tons of sea life but less visibility and cooler water temps. The town has something for everyone and lots of good restaurants, lots of taxis, and an excellent bus system. Prices are similar to Cozumel but the taxis over-charge from the airport. No worries about our safety. I recommend diving with PV Ocean Tours.
Playa del Carmen: A good place to get on the ferry to Cozumel
We did some dives there and they were OK but did not really compare to Cozumel. You can catch a bus to the Maya ruins in Tulum at the ADO bus station for about $2.50 US. We have never dove the cenotes but might some day. I would be concerned about our safety in Playa.
Cancun: A good place to catch the ADO bus to Playa and then catch the ferry to Cozumel. I would not consider staying in Canucn.