It did exactly what you asked. That's the problem.
Every rule you add closes one loophole and leaves the rest open. That's why alignment isn't a rulebook โ it's the ongoing work of teaching a system what you actually meant, and checking whether it understood.