Here's what I did, in case someone else faces this problem.
I inserted the sim card then I bypassed the activation screen by making an emergency call (911 because it's not an emergency number in my country). I pressed the power button until I got the slide to unlock message. I clicked cancel and then pressed the "touch to return to call" at the top of the screen. That's how I got to the home screen.
Once I was on the home screen, I installed SAM from cydia. Hacktivate was turned off so I turned it on and rebooted the phone. This time I did not get the activation screen so I restored my iphone from backup and used the Gevey Sim to unlock.