The above images was generated by using the following prompts:
Prompt: A tree with no leaves in the isolated black background.
Prompt: huge lightning in the isolated black background, no clouds.
Negative prompt for both: (worst quality, low quality, normal quality:1.8).
We can remove the background by using one of the methods available in [Various ways to remove the background].
Open the tree with a background. Copy and paste the tree without background to the same image.
Copy and paste both lightning images in between the tree layers.
The lightning with background needs to have [Screen] as the layer blend mode.
The lightning without the background needs to have [Divide] as the layer blend mode.
Add outer glow layer style like this to the lightning without the background.
Add a brightness and contrast mask to the top tree layer.
Please remember to Alt + Click between the mask and the tree layer or Right Click the layer to add as clipping mask.
This is the end of the tutorial. 🙂