Longer than a word — smaller than a sentence
Solution 1:
The basic grammatical units are morpheme, word, phrase, clause and sentence. In the definition given in the ‘Longman Student Grammar of Spoken English’, a phrase is ‘a structural unit built from words, consisting of a head plus (optionally) modifiers.’ In 'The Cambridge Encyclopedia of the English Language', David Crystal puts it a little differently: 'A cluster of words smaller than a clause, forming a grammatical unit.' (He mentions that it is sometimes called a 'group'. This is the term used in functional grammar.) To take an example, the sentence ‘Egyptians have approved a controversial new constitution’ contains two phrases: ‘Egyptians’ and ‘a controversial new constitution’.
This is the generally understood use of phrase. It is not to be confused with its use in the approach to grammar known as ‘immediate constituent analysis’. There, phrase is used rather differently, in that a sentence is divided into a Noun Phrase and a Verb Phrase, and each of those is further divided into all the constituent parts of the sentence.
Solution 2:
The definition of a phrase is a sequence of words that do not form a sentence.
By "sequence" I mean they are normally in some order, or at least not separated by full stops or line-endings and such. So a list of words is not a phrase.
In some situations, it makes sense to include single words in what count as phrases, but usually a phrase consists of more than one word.
In certain modern branches of linguistics, a phrase is sometimes a sequence of words that form a constituent. But usually something like a noun phrase is rather a kind of phrase, a constituent phrase, as opposed to non-constituent phrases.
Your examples, however, could be said to be sentences, though not full or complete sentences: they can be introduced with a capital and ended with a sentence-ending stop, but they are probably not (full) clauses.
Good job!
Nice shirt!
You could say these are elliptical clauses and hence elliptical complete sentences, because they do not syntactically depend on any (other) clause and the omitted words can be easily supplied:
[You have done a] good job!
[That's a] nice shirt!
A clause is conventionally a phrase that contains a finite verb and (all) its constituents. In (certain recent branches of?) Anglo-Saxon linguistics, any verb will do, not just finite verbs.