Niche specialization and species diversity along a California transect