Empress Eudokia of the Isaurian dynasty inherited the throne of Emperor Nikephoros and thus became the first Empress Regnant in Roman history. Some accounts say that she was indeed the first female ruler in all of Western history.
Nevertheless, the fact of her gender immediately mired her rule, with various generals declaring their support for her son from her first marriage, Frederi de Perigord. Frederi was already Doux of Armeniacon, a title inherited from his father the Exarch of Serbia, who had been assassinated by the late Emperor Nikephoros. The Empire was plunged into civil war when the new Empress tried to remove her eight year old son from power.
Though the Empire was rich, the civil war drained the coffers of Constantinople as it dragged on. Eudokia employed the Varangian guard as well as mercenary bands to put down the rebellion waged in her son's name. Eventually the war was won and the various conspirators were thrown in prison. Frederi suffered a more unique fate, being castrated and thus made ineligible to inherit any titles. Her rule secure, the Empress divided administration of her Empire among loyal generals.
Eudokia then turned to an acute problem: she needed to sire an heir. Frederi was her only child up to that point, and at 35 years old, she knew her time was limited. Her second husband, Guitard Capet, hadn't managed yet to get her pregnant. In desperation she started a series of adulterous affairs with various generals throughout the empire. Eventually she did get pregnant, and had a son in 826, who she named Augustus. The Empress would then go on to have two more children, both of illicit parentage, though this was unknown to Guitard.
With the support of her generals and the question of succession out of the way, Eudokia set her sights on the biggest prize of all: the restoration of the old imperial borders. She was blessed when an opportunity arose in the form of a revolt within the Abbasid Caliphate. The Caliphate had been subjugated by the Western Protectorate of the Tang Dynasty in China, who had extended its influence over Tibet and was encroaching westward. They briefly held the Abbasids as a tributary state until various parts of it rebelled. The Empress Eudokia took advantage of the situation to stage an invasion of Jerusalem, conquering the city and creating a staging ground for further campaigns in the east.