I guess moving the top from 5 to 3rem means you need tho change the height to calc(100% - 3rem).
Could you please check that?