Answer the question
In order to leave comments, you need to log in
Why doesn't it reassign the style?
grid-column changes at 375 resolution, but in DevTools it is crossed out, although the property is written later than the main one (you can see the lines on the screenshot).
Moreover, if I remove grid-column from this "non-working" one, the markup changes. That is, it seems to work, but in the dev Tuls - it is supposedly turned off. What does it have to do with
Answer the question
In order to leave comments, you need to log in
Specificity of selectors
The top selector has more weight. There's a class selector + a pseudo-class selector.
Because the first selector refers to a specific element, in this case the fifth, and the lower selector tries to refer to all at once, as you noted above, this is the weight of the selectors, the upper one, so to speak, is more important than the lower one, if it’s easier to explain, in your case then in the media query, just refer to the fifth one separately, then everything will be ok
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question