Garage door Thirdreality sensors to control lights help

So, I have two garage roll up doors, they have Thirdreality tilt sensors. I can make a flow to turn on a light when either door is opened, but how do I make a flow to turn off that light, when BOTH of the doors are closed? Connecting the two “door closed” when cards to an ALL card and then a light off command doesn’t work. I’m sure there’s a smart way to do this… These doors are controlled by a zwave wall switch.

WHEN

door A is closed Or

Door B is closed

AND

Door A is closed and

Door B is closed

THEN

Turn off light

So simple, yet I couldn’t see it before. This is perfect, thank you!

Another option if the garagedoor sensors are in zone ‘garage’.

Opening a door will make the zone active.

WHEN

zone ‘garage’ becomes active

THEN

turn on Lights

WHEN

zone ‘garage’ is inactive for 1 minute

THEN

turn off lights

Thanks for the second option! I implemented the first, and it worked perfect. I tried the second, and it didn’t work, so I went back to the first. Sorry I didn’t troubleshoot - thank you for sharing!