I spent about half a page writing a report, but the time ran out, and it all disappeared. I don't have the strength to repeat it.
So, in short.
After fiddling with developing secondary heroes and leveling up my main heroes for about 2-3 weeks, a plan matured in my head. The essence is to catch Valera off guard by going to his Castle through the Dungeon while he's clearing the treasure rooms in the sands. The path turned out to be very winding, and I was spotted in time. Then came a battle in the field. Orin attacks Octavia. Then, in the Castle, Octavia defends herself with the remnants of her army, bravely but unsuccessfully. In the end, I won.
Thanks to Valera for the game; I was impressed that, despite the bad starting conditions, he gave me a good fight.