The title points to a playing card, and the poem plays on that image to say something about how fragile power is. The speaker marvels at how "great and sudden" a "chance hand" can be, meaning the cards you happen to be dealt, but also the way luck can reach in and change everything without warning.
The second stanza stretches the idea. A king "sitting in the sea" might "lose his office," and the picture feels a little absurd, like a ruler stranded somewhere he can't govern. Then comes the sharpest turn: he loses "his own head / to the state of play." A king of clubs in a game can be captured or discarded, and a real king can be beheaded. The poem lets both meanings sit together.
The mood is cool, wry, and slightly ominous. The speaker doesn't seem angry or sad, more quietly struck by how little control even the mighty have once the game is underway.