I have set the width of element using calc function as below
width: calc((100% - (2rem * 2)) / 3);
Try to use 100vw instead of 100% for your calculation: width: calc((100vw - (2rem * 2)) / 3);.
width: calc((100vw - (2rem * 2)) / 3);
I think, this should solve the problem.