Kabul explosion kills 40 at gathering of clerics