Public Opinion, Security Threats, And Foreign Policy Formation: A Theoretical Framework And Comparative Analysis