Motion and 6 Zwave bulbs control

I am a newbie with HA and coming from Vera. I have seriously struggled with the below and could really use some help/guidance. I believe I have most of the pieces but I’m having trouble putting it all together.

I have 6 Zwave bulbs in overhead fixtures and a motion detector in my kitchen. I’d like to:

-When motion is detected turn on all the lights to the last dim level.

When Alexa initiated change in the dim level all lights go to that level.

When motion is not detected for 5 minutes, shut them all off.

I would very much appreciate some help. I have this in my Configuration file.

  - platform: template
    sensors:
      kitchen_brightness:
        friendly_name: "Kitchen Brightness"
        value_template: '{% if states.light.kitchen_74.state == "on"  %}{{  states.light.kitchen_74.attributes.brightness|int }}{% else %}10{% endif %}'

And the below in my Automations:

- id: kitchen_overheads_If_Motion
  alias: "Kitchen Overheads If Motion"
  trigger:
    - platform: state
      entity_id: binary_sensor.motion_kitchen_95
      to: 'on'
  action:
    service: homeassistant.turn_on
    entity_id: light.kitchen_74
    data:
      brightness: "{{ states.sensor.kitchen_brightness.state|int }}"

- id: kitchen_overheads
  alias: "Kitchen Overheads Adjust"
  trigger:
    - platform: state
      entity_id: sensor.kitchen_brightness
  action:
    - service: homeassistant.turn_on
      entity_id: group.kitchenslaves
      data_template:
        brightness: "{{ states.sensor.kitchen_brightness.state|int }}"

- id: kitchen_off_no_motion
  alias: "No Motion Kitchen"
  trigger:
    - platform: state
      entity_id: binary_sensor.motion_kitchen_95
      to: 'off'
      for: '00:05:00'
  action:
    service: light.turn_off
    entity_id: light.kitchen_74