Close call: Gloucester can’t complete valiant comeback attempt in loss at Danvers