Currently, I am developing a website at and I am interested in replicating the layout of another site. The site I would like to emulate is , which features multiple sections with child divs that have margins around them.
In order to achieve this effect on my site, I have used JavaScript to set the width and margins of the container-spice
div dynamically based on the window size. I am now attempting to add a constant pixel margin to the right of the children within the left-container
, which is nested inside the container-spice
div.
Adjusting the padding-right
and margin-right
properties of the left-container
div has not produced the desired result. I am looking for a solution that does not involve modifying the properties of the children within the left-container
, as they will be used in other parts of the site.