I use a program called homeseer (been using it for about 20 years) It's home automation software that's got a lot of scripting and event options.
A lot of my lights are z-wave and are controlled though homeseer
the rest are Hue, and controlled either though the hue app, or homekit, They've also been added to homeseer
For all of the stuff in homeseer that's doesn't have native homekit. I use a program called homebridge, which makes non-homekit things work in homekit. It has plugins for lots of things including homeseer.
I've got my older LG-E6 in homekit through this. as well as my security cams and robo-vacuum.
Because of this extra layer of control, If I need more involved scripting, I can do it in homeseer,
Scenes are done in the home app.
****I've got a ceiling fan and temperature sensor in my bedroom.
I've used those to create a virtual thermostat in homeseer (and added to homekit)
I can set a temp, and the warmer it gets above that, the faster the fan goes.
This is also nice on cooler nights when you leave the window open, if it gets too cold, the fan shuts off.
****I've got under cabinet LEDs and a motion sensor in the kitchen
If the LEDs are off, and the motion sensor trips, they come up to a low level
that level is brighter during the day then at night
they also come up to full when the main overhead light turns on.
The LEDs are also variable color temperature, and those automatic levels shift warmer at night, and cooler during the day.
****I have LED tape on the back of my wall mounted TV to create a
bias light
My TV is available in homekit though homebridge.
There is also a homebridge plugin that makes 2 switches (awake and playing) that look at the ATV.
(they work both ways, so if you wake the TV from the remote, it turns the switch on in the home app, but it also can be used to control the aTV from the home app)
So between monitoring the TV and aTV, the bias light turns on/off automatically
There's also a light sensor in the room, so it brightens/darkens with the room.
****I've got plans to make a "theatre mode" so the lights will dim or brighten automatically.
Someone has written a homebridge plugin that makes the aTV a virtual button (like the eve button)
it has 3 "button states" (play, pause, stop) that you can configure in the home app to trigger devices/scenes
****I have a virtual switch in homeseer that is my "home/away" status
That switch is available in the home app, and is tripped via homekit automations when I leave/arrive home.
This is then used to determine how other automation runs.
the above mentioned fan thermostat looks at this, if I'm not home the fan goes off
and if I'm away, and the front door opens, it alerts my phone.
****also have sonos, This is all through homeseer though.
homeseer watches the speakers, and if I'm playing the TV in the living room, it will auto pair/unpair certain rooms based on other things.
Kitchen pairs on the motion sensor, Bathroom pairs on the main light switch.
So if you're watching TV and step into the other room, the sound follows you. And you don't have to worry about delayed sound echoing in from the other room if no-one is in there.
*the sensors are actually an all in one, so each room has one device that does motion, temp, humidity and light.
You can do some of this in homekit
You might be able to re-create some of them using the eve app (even if you don't have eve products) as it's automations have more options.