Rotate the status of the binary sensor

Hello.

I have a binary_sensor.dishwasher_door that is active when the door is open, shows the door-open icon and glows yellow on the UI tab.
I wish it was active and shines yellow in the card when the dishwasher door is closed together with the door-close icon.

I tried to create another, custom binary_sensor, but it works the same.

How do you handle such a request?
thanks for the help

  - platform: template 
    sensors:
      mycka_dvere:
        friendly_name: Dveře myčky jsou
        entity_id:
          - binary_sensor.mycka_nadobi_door
        value_template: >-
          {%- if is_state('binary_sensor.mycka_nadobi_door', "on" ) -%}
          off
          {%- else -%}
          on
          {%- endif -%}

So it looks very good.
I still have to figure out to display the door-open icon and door_close at the right time.

Thanks

No, it’s not working properly right now.
Before replenishment device_class sensor works the way I want. Door closed = active (yellow icon).
When I add device_class: door, everything turns. The sensor is active when the door is open.