Hi
Start with just correctly connecting LEDs and push buttons.
Then use the simulation to check voltage levels, currents and timing.
I guess there are many thousands of tutorials a d documents telling how to.
Write the correct code including denouncing.
After this do simple hardware simulations on how to drive low side BJTs. Also with analysing voltages, currents and timing.
Then
high side BJTs.
Then
optocouplers.
Then
combine optocouplers with BJTs
*****
What I don't understand ... it seems you are not very experienced .... so why don't you look on example designs and application notes? There is plenty good informations in the internet.
Klaus