The summer solstice is an annual event that is possible because the earth rotates on a tilted axis. The tilt of the earth remains relatively constant regardless of its position in relation to the sun. This is true at least in terms of a human lifetime. Over hundreds of thousands of years, it is thought the earth actually wobbles somewhat, and this changes the tilt of its axis.
Because of this tilt, the earth presents itself at differing angles to the sun at various times of the year as it makes its annual circuit of our host star. When the earth is sideways in relation to the sun, the heat and light from the sun strike the earth most intensely over the equator. This happens twice per year. It happens once at the beginning of fall and again on the first day of spring. The amount of daylight and dark are equal for those two days.
A solstice occurs when the tilt of the earth either has the north pole leaning toward the sun or the south pole leaning toward the sun. When the north pole is leaning toward the sun, summer has arrived in the northern hemisphere. The opposite is true in the southern hemisphere. On that day, the hemisphere leaning toward the sun has its longest day of the year. The sun is shining directly overhead on the tropic lines. In the northern hemisphere, the sun will be shining on the Tropic of Cancer. This is the first day of the northern summer.
The moment that the sun hits the Tropic of Cancer, it starts its journey back toward the south until on the first day of the southern summer it shines directly on the Tropic of Capricorn. Solstice is the name given to that day when these events occur. It is always either the beginning of summer or winter depending on which half of the world you are living.