Ive created a flow that works with my nest camera that makes turns on my deck and rear floodlights using my tp link switch and then turns off after 10 minutes. What I want to add to this flow is that the deck lights turn on at nighttime and then at 10 pm they turn off and are only turned on if there is motion detected by my cameras. Basically need to add the area from start of nighttime to 10pm.