Detecting or preventing theft or loss