Rafael Nadal clinches 12th Barcelona Open title