Safari: Shortcut to switch between developer window and safari
Switch one way: Cmd + `

Switch the other way: Cmd + Shift + `


Replace ` with the necessary language specific equivalent.
Your solution was very close. Normally the key combination you mentioned loops through available windows. In this specific case you have to return to a previous window by adding Shift.