The red card will open the second safe, but it's inside the first safe, beyond the cogs.
Once you get inside the safe look at the circular platforms.
Those platforms cause the cogs to move.