Crime fiction is the literary genre that fictionalizes crimes, detection, criminals, and criminals’ motives. It is often distinguished by mainstream fiction and other types of genres. However, there are boundaries in science fiction as well as historical fiction. Thus, blurred is indeed the correct word. It is divided into several sub-genres, including detective fiction (such a the whodunit), legal thrillers or courtroom Drama, and hard-boiled fiction.
Italians call a story about detectives, crimes, or “giallo” (en: yellow). This is because crime fiction has had a yellow cover since its inception in the thirties.