'Secret code' behind key type of memory revealed in new brain scans