0

I have an issue with my site on Safari and Chrome only. It appears, when I zoom out of the page using STRG and mouse wheel scroll. The layout, which contains 5 links in a row, breaks and I now have only 4 in a row.

Have a look at that sample: https://jsfiddle.net/SchweizerSchoggi/8aoopsqk/ and check in the different browsers zooming out two or three times.

There are no changes in IE and Firefox, only in the webkit browsers. Why does this happen and how can this be solved?

I use nth-child to build my layout:

a { 
  display: inline-block; 
  margin: 0 10px 10px 0; 
  ....
}

a:nth-child(5n+5) { 
  margin: 0 0 10px 0; 
}

Any help or advice is appreciated, thank you in advance.

EDIT: Thanks to @Muhammad Usman, your idea was very helpful to me!

JonSnow
  • 573
  • 14
  • 48

0 Answers0