I feel very ashamed to answer my own question, but having found a possible answer, I don’t see why I shouldn’t share it with the community.
I would like to start by bringing in this table of orbital energies (from the appendix I linked to in the question) as a reference point for further explanations:
$$\begin{array}{ccc}
\hline
\text{Element} & \text{Energy of outer s orbital / eV} & \text{Energy of outer p orbital / eV} \\
\hline
\text{Carbon} & -19.43 & -10.66 \\
\text{Silicon} & -14.89 & -7.78 \\
\text{Germanium} & \mathbf{-16.05} & -7.54 \\
\text{Tin} & -14.56 & -7.01 \\
\text{Lead} & \mathbf{-15.12} & -6.81 \\
\hline
\end{array}$$
As you can see, the energies of the p orbitals get higher and higher as you go down the group, while the energies of the s orbitals don't.
The reason why, in general, orbitals rise in energy when going down a group is that even though the nuclear charge is bigger (which has a stronger effect than the rise in the quantum number $n$), the increased screening effect of added electrons prevails over this rise.
Germanium has such a low 4s electron energy because of the so-called d-block contraction. Since it has 10 added protons due to the existence of the d-block, and the d electrons don’t shield this increased nuclear charge well, the s electrons are stabilised. The p electrons don’t feel this effect as much because they are shielded more than the s electrons (less penetration), thus experiencing the rise in the nuclear charge less, while being shielded additionally by the stabilised s electrons (and presumably by the d electrons as well, to a lesser extent).
The lowered energy of the 6s orbital of lead is the result of the equivalent f-block contraction, amplified by the relativistic contraction of the s shell. The p electrons don’t have a noticeable change for the same reason they didn’t in germanium.
Now, tin has d electrons too, so it will experience the d-block contraction – but to a far more limited extent, since the change in nuclear charge is not as big in percentage. To illustrate this concept, it is useful to bring in this formula:
$$E \approx -13.6 \left(\frac{Z}{n}\right)^2 \mathrm{~eV}$$
where $E$ is the energy of the electron (in the hydrogen-like atom!), $Z$ the nuclear charge and $n$ the principal quantum number. Since it refers to hydrogen-like atoms, this formula obviously doesn’t bring in the screening effect. To see why the d-block contraction doesn’t have such a strong influence on the tin atom, we can use this formula to calculate how the non-screened, non-relativistic energy grows from Si to Sn:
$$\begin{array}{cc}
\hline
\text{Element} & \text{Non-screened energy of outer orbital / eV} \\
\hline
\ce{Si} & -296.178 \\
\ce{Ge} & -870.4 \\
\ce{Sn} & -1360 \\
\hline
\end{array}$$
As you can see, the percentual change from Si to Ge is much higher than the change from Ge to Sn – thus, the increase in nuclear charge from Ge to Sn doesn’t have an enormous effect on the electron energy, while the screening effect between Ge and Sn grows steadily: the orbital energy is lowered in the many-electron atom. Hence, the Sn s shell is stabilised, but to a lesser extent.
Now, why does Sn form divalent compounds so easily, when Ge and Si have lower s energies and don’t? There’s a passage in Greenwood’s Chemistry of the Elements (2nd ed), pp 226-7 that explains it:
The term “inert-pair effect is somewhat misleading since it implies that the energy required to involve $n\mathrm{s^2}$ electrons in bonding increases in the sequence $\ce{Al} < \ce{Ga} < \ce{In} < \ce{Tl}$. […] This is not so […]. The explanation lies rather in the decrease in bond energy with increase in size from Al to Tl so that the energy required to involve the s electrons in bonding is not compensated by the energy released in forming the 2 additional bonds.
Indeed, that is what happens: the $\ce{Sn-X}$ bonds are longer than the $\ce{Si-X}$ bonds, and thus have smaller energy, as permeakra pointed out in his/her comment. However, I believe this is not due to the interference of the d-subshell, but simply to the larger Sn nuclear charge. This increased nuclear charge amplifies the repulsion to the nuclei of the other species (say, oxygen), thus lengthening the bond. Since the s electrons have a very low energy compared to the p ones, they do not participate in this bond – they cannot overlap.
In short, tin forms divalent compounds because:
- Its s subshell is more stable than the p subshell, because of screening differences;
- Its bonds are longer, due to the increased nuclear charge: thus, the s electrons don’t bond.
The combined effect is smaller in germanium compounds (Ge is more tetravalent), because even though the s shell is more stabilised, the bonds are shorter; it is stronger in lead compounds (Pb is more divalent) because the 6s shell is more stabilised than the Sn 5s shell and the bonds are even longer.