It is very easy to reach the Barcelona airport from Viladecans by bus. There is a line that takes you there night and day.