Lord is used for God, Jesus and for other people in positions of authority. For example:
Let all the house of Israel therefore know for certain that God has made him both Lord and Christ, this Jesus whom you crucified. (Acts 2:36)
Here, “Lord” is clearly referring to Jesus.
But in Acts 3:19-20 we read
Repent therefore, and turn again, that your sins may be blotted out, that times of refreshing may come from the presence of the Lord, and that he may send the Christ appointed for you, Jesus,
This time, “Lord” must mean God as he is described as sending Jesus. In other places, it can refer to a man who has great authority (e.g., Caesar).
In the New Testament, the Greek word translated Lord is κυριος (kyrios). In the Old Testament, the Hebrew word translated Lord is either אדן (adon) or אדני (adonay). In almost all cases, adonay refers to God and adon refers to human lords.
In the Old Testament, it is common to see LORD in upper case letters (actually in small caps). In these cases, the Hebrew word is יהוה (Yahweh). This is the personal name of God (see Exodus 3:13-15 and Exodus 6:2-3) and means something like “He will be who he will be”.
Several centuries before Jesus, Jews stopped pronouncing this name as it was considered too sacred, and they started to substitute the word Adonay (Lord) instead whenever they came across the word Yahweh. Following that tradition, almost all English translations also translate Yahweh as Lord. But to highlight that it is the personal name of God, it is printed in all capitals as LORD.