Their Fear and Their Not Going Up are Two Separate Reasons
The ESV translation fixes this confusion by putting in "you" twice where other translations omit the second "you".
while I stood between the LORD and you at that time, to declare to you the word of the LORD. For you were afraid because of the fire, and you did not go up into the mountain. He said:
And it is indeed the other translation that omit it, for the word in Hebrew is עֲלִיתֶ֥ם which is the word for go, however the תֶ֥ם at the end means "you", and it matches the word for "you were afraid", יְרֵאתֶם֙.
That there fear obliged Moses to meditate between God and the people is made clear in Exodus 20:18-19
:
18 Now when all the people saw the thunder and the flashes of
lightning and the sound of the trumpet and the mountain smoking, the
people were afraid[d] and trembled, and they stood far off 19 and said
to Moses, “You speak to us, and we will listen; but do not let God
speak to us, lest we die.”
This comes after they were banned by God from going up the mountain, and demonstrates that it was not their being forbidden alone that necessitated Moses acting as meditator, but also their own fear. Since, they could have heard perfectly well despite the distance, but instead requested the intervention of Moses.