Why are corals so colorful?

One of the most striking things about coral is its bright coloring. But many are a dull green or brown. So, what gives some corals their bright hues?