add "maximal reached level" to every skill and gain and loose of experience will be based on difference between "maximal reached level" and "current level". the bigger is this difference, the slower you loose your exp and the quicker you get it back.
f.e
exp=exp-expLoose/(2^(maxLvl-curLvl));
and for exp gain
exp=exp+expGain*(1+.2*(maxLvl-curLvl));