Even though water clarity in Boston Harbor has improved twofold and concentrations of contaminants have dropped 80 percent this past year, the area’s major beaches aren’t much cleaner than they were in the 1990s. Officials attribute the successes to a $4.1 billion, 16-year cleanup effort that ended in 2000. Sewage and stormwater discharges, however, have kept the beaches shut about 20 percent of the time this summer — a problem that officials said would be difficult (and not cheap) to solve.