Yellow area is content of div#B (shows the extent of width and height of div#B for default box-sizing)

Green area is padding of div#B
 top (30px)
 left (50px)
Margin and padding for div#B:


Style Info for div#B:

Note: Offset (left,top, ..) is measured from border of container to start of margin (and not border) of the enclosed element. Thus, the position of the "Margin Box" of the enclosed block is not affected by margin or padding of the container.