A submarine is 306 m horizontally out from the shore and 120 m beneath the surface of the water. A laser beam is sent from the sub so that it strikes the surface of the water at a point 245 m from the shore. If the beam just strikes the top of a building standing directly at the water's edge, find the height of the building.