That said, like many similar interview/hiring stories shared here, it reeks of single-sidedness. Specifically, there is not enough detail regarding your interactions with the interviewers to warrant calling this a horror story. The only points of interest in this piece, in my opinion, were that the interviewers were late and there was a clear communication issue (particularly when it came to scheduling the interviews).
Other than that, all we know is that you tripped up during some of your interviews. In those situations, based on your post, it was never really your fault, which is not the best attitude to have.
Finally, them saying that your engineering skills needed more work shouldn’t be insulting. Amazon hires tons of engineers and they are generally very technically competent. However good you think you are, there are millions who are just as good, and there are thousands who are better. Amazon can only hire so many people and this was likely their way of saying they simply had more candidates with more experience.
I know it is frustrating. I can say this because I have absolutely been in your shoes. (Dream job, all the way to the last stage, then no offer.) At the end of the day, we have to acknowledge the competitiveness of our field and use that to drive us to become better.