British gov't loses key case over terror suspects' detention