# CSS behavior changed after software update

**URL:** <https://meta.discourse.org/t/css-behavior-changed-after-software-update/181293>\
**Category:** UX\
**Created:** [February 27, 2021, 2:10am UTC](https://meta.discourse.org/t/css-behavior-changed-after-software-update/181293 "2021-02-27T02:10:00Z")\
**Posts on this page:** 1\
**Showing post:** 11

<div class="post-metadata">

**Author:** ![awesomerobot](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/awesomerobot/32/142900_2.png) [@awesomerobot](https://meta.discourse.org/u/awesomerobot)\
**Post date:** [March 18, 2021, 2:34am UTC](https://meta.discourse.org/t/css-behavior-changed-after-software-update/181293/11 "2021-03-18T02:34:52Z")

</div>

I think there might be two problems here, the first being that you should add `body` before `:not`, otherwise `:not` can be any div without the class.

The second problem is that these styles are clashing with each other:

```css
:not(.staff) .topic-list .category-marketplace a[data-tag-name="wagon"] {
  display: none !important;
}

:not(.primary-group-dealers) .topic-list .category-marketplace a[data-tag-name="wagon"] {
  display: none !important;
}

:not(.primary-group-brokers) .topic-list .category-marketplace a[data-tag-name="wagon"] {
  display: none !important;
}

```

The first style will hide the wagon tag if you’re _not_ staff… but the second and third styles will hide the wagon tag if your primary group is also _not_ dealers/brokers. You’d need to be all 3 to avoid `display: none;`.

I think instead you’d want to combine the 3 like this:

```css
body:not(.staff):not(.primary-group-dealers):not(.primary-group-brokers) .topic-list .category-marketplace a[data-tag-name="wagon"] {
  display: none;
}

```

The first way, with the 3 separate styles acts as a “not and”:

_not_ `staff` _and_ `primary-group-dealers` _and_ `primary-group-brokers`

The second way, with the chained `:not` acts as an “or”:

_not_ `staff` _or_ `primary-group-dealers` _or_ `primary-group-brokers`

---

_[View the full topic](https://meta.discourse.org/t/css-behavior-changed-after-software-update/181293)._
