Absolute positioning ignoring padding of parent
问题 How do you make an absolute positioned element honor the padding of its parent? I want an inner div to stretch across the width of its parent and to be positioned at the bottom of that parent, basically a footer. But the child has to honor the padding of the parent and it's not doing that. The child is pressed right up against the edge of the parent. So I want this: but I'm getting this: <html> <body> <div style="background-color: blue; padding: 10px; position: relative; height: 100px;"> <div