Funerals are often somber affairs. Also your face after your teacher hands back an exam you failed. Somber is used to describe situations, facial expressions, or moods that are dark, gloomy, or depressing.
Something that is somber is often thought of as "in shadow," as in "the shadow of grief," or "the shadow of a bad mood." This is not just a coincidence. Somber comes from French sombre, which comes from Late Latin subumbrāre "to cast a shadow," from Latin sub umbrā "under a shadow."