'For long' should be accepted too
Only if interrogative or negative.
Can we also say, "It has rained for a long time ?"
Do all adjectives change accordingly in the perfect tense?
No. The adverb "Länge" is a separate word from "Långt".
"Länge" means "For a long time".
Det har länge regnat
No, you'll likely only encounter that in stylised material such as poetry and highbrow literature.
Which word changes De to Det in this sentence?
Which word does the pronoun it refer to, in this exercise? None of them, which is what makes it Det.