I think it's the best episode of the season, and certainly the best ever written by Russell T Davies. The sources are good sources - The Edge of Destruction, also written at the last minute by Old Who's first script editor, putting the Tardis crew in a single set for 50 minutes; also I think Arthur C. Clarke's A Fall of Moondust, where a group of tourists is trapped on the Moon, though without the sinister alien presence. (The eye of faith may detect inspiration also from Delta and the Bannermen, or The Leisure Hive, but personally I don't.) Davies takes this and puts his own particular interpretation onto the situation, and for once his writing remains tight up to the last moment.
He's helped by a couple of stellar performances - Lesley Sharp as Sky and the unnamed baddie, and Rakie Ayola as the hostess in particular; also from the past we have David Troughton as the Professor, and from the future Colin Morgan as Jethro. The scenes with Lesley Sharp first echoing, then synching with, then anticipating the other cast members' lines are just incredible. (The only irritating moment is Rose's brief appearance, which is difficult to reconcile with what we later find out she's been doing - the similar moment in The Poison Sky is at least set in the present day.)
Quite apart from the creepiness of the basic concept, it's a story where the Doctor's normal cockiness and air of mystery, which normally seem to get authority figures magically co-operating with him, work against him; and his fellow passengers end up baying for his blood. It's notable that they are not, particularly, authority figures; and the one who is nominally in charge, the Hostess, ends up being the one who saves them all. And the specific point where the Doctor's credibility breaks down completely is when he tries to urge compassion, which rather more often works to shame other characters into cooperating. It's a great subversion and stretching of the show's usual assumptions.
After two stories where we've had the Doctor's own intimate relations (his daughter and River Song) on screen, here we have the Doctor observing and interacting with several other family dynamics - Biff, Val and Jethro; the Professor and Dee Dee; Sky and her absent ex; perhaps also the Hostess and the crew. (Indeed, it might have been better if this had been shown between The Doctor's Daughter and Silence in the Library, as was originally planned.)
Midnight was Russell T Davies' nineteenth story for Who, which puts him ahead of the 18 stories written entirely or partly by Robert Holmes. Andy Murray suggests (in his piece in Time and Relative Dissertations in Space) that we can see the frustrated attempts of the tall, fair-haired Chancellor Goth to hunt down and destroy the Doctor as the tall, fair-haired Holmes working through his own frustration with the central character of the show. Note that in this story the Doctor loses his authority over the other passengers and even his voice, and that he is actually killed off at the beginning of the next story; am I going too far in detecting a subconscious desire to get rid of him on the part of the executive producer and chief writer? (Not that there is the same physical resemblance between RTD and the villain of either story.)
Two further pieces of trivia from the BBC via Wikipedia: it is the first story since Genesis of the Daleks where the Tardis does not appear, and the only Who story where the villain is never named.
(Robert Holmes' 18 stories: The Krotons, The Space Pirates, Spearhead from Space, Terror of the Autons, Carnival of Monsters, The Time Warrior, The Deadly Assassin, The Talons of Weng-Chiang, The Sun Makers, The Ribos Operation, The Power of Kroll, The Caves of Androzani, The Two Doctors, and The Mysterious Planet; plus also The Ark In Space, The Brain of Morbius, Pyramids of Mars and the first episode of The Ultimate Foe. Of course, in screen time he is still well ahead of RTD, since all but one of the above were at least the equivalent of four 25-minute episodes.)