Midrin was the best med for me but it was discontinued in 2007. Two of those before lying down and I slept off most of the headache.
That’s what I use...same effect too. 2 pills at onset, and then within an hour I’d be woosey enough to sleep a bit.
Even with that though, I generally feel like crap the rest of the day.