How can I add a wait time to turn the light off to this automation?
- id: '1671648472715'
alias: 'Lights: Bathroom Automation'
description: ''
trigger:
- platform: state
entity_id:
- binary_sensor.p1_motion_ias_zone
condition:
- condition: time
before: 07:00:00
after: '17:00:00'
weekday:
- sat
- fri
- thu
- wed
- tue
- mon
- sun
action:
- service: light.turn_on
data: {}
target:
entity_id: light.bathroom
mode: single