I think the problem you have is that you are animating CSS properties that don’t fall under the 60 frames-per-second (FPS) specification. When you animate such properties you get jitter / flickering.
Properties that have buttery smooth 60FPS are transform
and opacity
. Properties such as flex
, margin
, top
etc are known to be prone to flicker when animated.
You can read more about it here: Animation performance and frame rate. The section related to your problem is under ‘CSS property cost’
Note: although Firefox also uses this specficiation, even at 60fps, animations are sometimes prone to flicker due to sub-pixel rendering issues (this isn’t what is causing your problem though – Firefox sub-pixel rendering bug, but it is handy to know).