17 is an amazing age....
I might double check on the melatonin dosage. I've only used small, tiny dosages, but I know some out there use huge amounts.
Cholidin (sp?) is one that some people swear by, but you might have already tried most of the ingredients.
I am trying to think of my mom who has had this problem, and the only thing that helped her was trazadone before bed, though she no longer takes it. I don't know if they have any drugs in that class that they use to treat dogs?
I wonder if some of those Hylands homeopathics might have something for anxiety or the like that could help? I know that their bedwetting remedy helps some dogs with incontinence, and I think the Nerve Tonic that I use in the day for Jazz before she goes to daycare helps. Btw, I've never had luck with Bach rescue remedy, though I have had luck with some of their other ones.
This is probably a useless idea, but I wonder if some goat's milk before bed would help.
If she is in pain, something for pain before bed?
They have a special senior album for dogs here:
http://throughadogsear.com/ I swear that the car one I have used for Jazz has helped, but I don't know if it would help enough for what you are dealing with. I think they have a free download of a song or two and maybe you could try it out?