There are two main components to 'Twine': the Twine application(s) and the Story Formats.

1. The Twine application is responsible for editing the different Passage types (Standard, JavaScript, and CSS (Stylesheet) that make up your story project, and for combining the passages of your project with a Story Format to create a Story HTML file. (the Publish to File option)

2. A Story Format is a mini web-application. it uses the information contained within the embedded Passages to generate the web-page shown to the Reader. It is responsible for defining the custom macro language used by the Author, the core functionallity of the story, as well as it's default visual layout & styling.

This is why the choice of which Story Format you use to write your story is important.

Harlowe is the simplest story format, it has been designed for beginners with limited (or no) programming experience. It can be simple to learn however that simplicity comes at a cost, it has performance issues when dealing with certain types of information and it can be difficult to extend the story format's core functionallity.

Snowman is the hardest story format to use, it has been designed with web-developers in mind. It includes very little core functionallity, the Author is expected to write all require functionallity themselves.

SugarCube sits somewhere in between the other two story formats. It is designed to be used by both beginners and web-developers a like, it's macro langauge and core-functionally is more feature rich than the other two. The core functionallity of the story format can be extended by the Author, however such bounty comes with a cost of needing to learn more about programming techniques and possibly web-development technologies like HTML, CSS, and JavaScript.

As a rule of thumb, it's hard to go wrong with SugarCube, as you have a great deal of functionality built in, the option to build your own functionality, and a fairly low chance of having major performance issues. Also as a rule, though, you don't need to pick one format and marry it. It is always wise to try to build something small in all of them to get a sense for which you prefer and where the capabilities of each sit, as your own subjective preferences and needs are also a factor.

A detective game isn't a feature list, so no one can tell you which is better for you just from that. Every format could be used to write a game with detective elements.