The second option is correct. Here's the breakdown.
First, you hit with a power attack. This triggers Cornugon Smash.
Second, you make an Intimidate check. Since this check explicitly happens after your first attack is finished, Shatter Defenses cannot come into play. In order for Shatter Defenses to work, you need to hit an opponent who is shaken, and the opponent is not shaken here until after the hit has gone though.
Third, you make another attack. This attack will activate Shatter Defenses. However, this attack is made against your opponent's non-flat-footed AC. Since you need to make your second attack roll before the attack hits, and the first attack cannot have activated Shatter Defenses, this attack has to be made against the enemy's normal AC.
The reason that the second attack is against normal AC and not flat-footed AC is that Shatter Defenses doesn't take effect until you have actually hit your enemy. You make your second attack roll before you hit with your second attack. Since Shatter Defenses requires you to hit before it works, the attack roll for the second attack is made against normal AC, not flat-footed AC.
The third and later attacks are against flat-footed AC.
I understand your confusion, but the real answer, like in many cases, is "whoever wrote/edited this feat did so poorly". The interpretation favoured by all of the answers here is assuming that the feat is written poorly, but that it works like every other feat in the book. Namely, that it provides an effect after a hit, rather than passively providing a benefit that triggers under a particular circumstance. If you, as a GM, want to read it differently, no one is stopping you. If you want to do this as a player, make sure to ask your GM in either case, since this involves a poorly worded feat.
The core reason that the second interpretation is more likely to be correct than the first is that there are few to no feats that work like the first interpretation implies. Feats like this are almost always active, and require an action on the part of the player to activate, rather than working passively.
To give an example: Suppose you had Shatter Defenses, but didn't have Cornugon Smash. On your turn, you full attack an enemy. On your Wizard friend's turn, he casts fear. On your enemy's turn, he runs away, providing an attack of opportunity. With interpretation 1, you would attack his flat-footed AC, since he is currently panicked and has been hit by you this round. This doesn't work with the way feats typically work, and it doesn't work with the fluff description of of the feat, which says that it
leaves opponents unable to defend themselves if you strike them when their defenses are already compromised.
With interpretation 1, you aren't striking a foe whose defenses are already compromised. You are striking a foe, and then his defenses are becoming compromised. While the wording of the feat may be unclear, it makes a lot more sense that it requires you to hit a foe that is already shaken than otherwise.