Hair consists of dead keratinized cells that provide several protective functions for the skin. It grows from hair follicles, which extend from the epidermis into the dermis. Each hair shaft has three layers - a medulla, cortex, and cuticle. Hair color is determined by melanin pigments produced in the hair follicles. Hair growth cycles between active and resting phases and is influenced by hormones and nutrition. Nails are hardened keratinized scales that protect the fingertips and toes. They grow from nail matrices within the nail beds. Sweat and sebaceous glands are also skin appendages that release sweat or oily secretions to cool the body and lubricate hair and skin.