Mushroom entity card - change icon color depending the value

I currently have the exact same question with a similar code. And I can’t see why it’s not working.

Mushroom card can set up the colour permanently if it’s a button, not the script or anything else.
For that you need:

  1. Create “Button” helper (Devices & Services → Helpers → Create Helper
  2. Create automation to trigger script by the press of the button (above) - (Automations & Scenes - Automations - Create automation)

Below is the example of the automation:

alias: Diffuser - Button - OFF
description: “”
trigger:

  • platform: state
    entity_id:
    • input_button.input_button_diffuser_off
      condition:
      action:
  • service: script.diffuser_off
    metadata: {}
    data: {}
    mode: single