Answer
The war declaration occurred in response to Karl X Gustav of Sweden's imminent disastrous defeat at the Battle of Warsaw against the alliance of Poland and Lithuania, as Frederick III sought to capitalize on Sweden's weakened position. This opportunistic move by Denmark marked a turning point in the Second Northern War, involving various European powers vying for regional dominance.