05. CSS Specificity - Gr0mi4/Hello-World GitHub Wiki

This task is mostly theoretical. You need to get a better understanding of what is CSS Specificity and why it's important to understand.

  1. Read this good article https://www.smashingmagazine.com/2007/07/css-specificity-things-you-should-know/
  2. [optional] Read this https://developer.mozilla.org/en-US/docs/Web/CSS/Specificity
  3. Take a look at this funny project: https://specifishity.com/
  4. Calculate specificity values for the following CSS selectors:
  • .vanya.gromov - 20pts ✅
  • .vanya:not(.gromov) 20 pts ❌ (read this https://bitsofco.de/on-not-and-specificity/)
  • #menu .menu-wrapper.open:after 121 pts ✅
  • form > div > div > button:focus 5 pts ❌ (4 elements + 1 pseudo-class)
  • div + .blog:before 12 pts ✅
  • * + .vanya 10 pts ✅
  • style="color: black" 1000 pts ✅
  • style="color: red !important" 999999pts ❌ (actually !important gives you 10,000 pts + 1000 from inline styles)