There are indeed things that the Catechism has to tell us about chastity; in fact, there is a whole section on it (Part Three, Section Two, Chapter Two, Article 6, Heading II) titled "The Vocation to Chastity". Chastity, we are told, is
the successful integration of sexuality within the person and thus the inner unity of man in his bodily and spiritual being.
Considering that sexuality, and therefore marriage and the family, are oriented to the begetting and raising of children, it seems therefore that chastity is all about how one guides one's activity by a Catholic understanding of the purpose of sex, marriage, and family.
Peter Turner's answer is a good one to display the general principles by which one should determine for oneself what sort of behavior is unchaste—the topic is of course broad, and whether a behavior is unchaste can depend on a number of things.
Thomas Aquinas actually addresses the two specific questions you raise ("Would tender kissing to show affection be unchaste? Would the same action be unchaste if it were for sheer enjoyment?"). He states:
A thing is said to be a mortal sin in two ways. First, by reason of its species, and in this way a kiss, caress, or touch does not, of its very nature, imply a mortal sin, for it is possible to do such things without lustful pleasure, either as being the custom of one's country, or on account of some obligation or reasonable cause. Secondly, a thing is said to be a mortal sin by reason of its cause: thus he who gives an alms, in order to lead someone into heresy, sins mortally on account of his corrupt intention. Now it has been stated above, that it is a mortal sin not only to consent to the act, but also to the delectation of a mortal sin. Wherefore since fornication is a mortal sin, and much more so the other kinds of lust, it follows that in such like sins [to] not only consent to the act but also consent to the pleasure is a mortal sin. Consequently, when these kisses and caresses are done for this delectation, it follows that they are mortal sins, and only in this way are they said to be lustful. Therefore in so far as they are lustful, they are mortal sins.
(Summa Theologica, Second Part of the Second Part, Question 154, Article 4; emphasis added)
It appears, therefore, that both your questions are answered affirmatively: It is not unchaste in itself to kiss someone in order to show friendly affection; but it is if you are doing it for the pleasure of the kiss.