use clientWidth instead of getBoundingClientRect