Displaying Energy usage of 2 sensors combined in the Energy Dashboard

I recently purchased 3 Shelly Pro 4PM’s to get insights in the energy usage for the 12 electrical groups in my house.
This works fine, but my electrical “Bora” stove uses 2x 16A groups and these are monitored separately.
Instead of displaying these individually I would like to see the sum of these 2 sensors combined in the Energy Dashboard.

After searching and trying numerous approaches I can’t get this to work.
The newly created template sensor simply keeps adding up the totals of the 2 individual sensors, and not the daily values as expected.

Does anyone know how to solve this?

template:
  - sensor:
    - name: "Shelly Pro 4PM Bora Energy"
      unit_of_measurement: "kWh"
      state_class: total_increasing
      device_class: energy
      state: >
        {% if now().hour == 0 and now().minute == 0 and now().second == 0 -%}
          0
        {%- else -%}
            {{ (states('sensor.shelly_pro_4pm_groep_1_4_switch_0_energy')|float(0) +
            states('sensor.shelly_pro_4pm_groep_1_4_switch_1_energy')|float(0)) }}
        {%- endif %}

Nearly finished, just a little bit of fine-tuning required to make it look nice.

Why?
The sensor is not total_increasing, then, and it’s likely the source of the issue.

I read elsewhere that this solved the issue.

Removed the piece of code, created a new sensor and that solved the issue.