Parameter estimation
Since the residuals can be considered to be prediction errors, a good linear equation should result in small residuals.
A good principle is therefore to estimate the three parameters of the model (the intercept and the two slope parameters) by adjusting them to make the residuals 'as small as possible'.
Illustration
The diagram below shows an artificial data set.
Drag the three red arrows vertically to adjust the three parameters of the model. Find parameter estimates to make the residuals as small as possible.
Hint: It can be tricky getting the residuals small for all combinations of X and Z. Adjusting the parameters in the following order helps.