Questions tagged as 'margin'

6
answers

What is the difference between padding and margin in CSS?

So I realize that I see a setback to another element when the left, top, right e bottom. Is there a difference between margin and padding in CSS? A response with examples (images or code) would help a lot in understand...
asked by 14.03.2017 / 15:36
2
answers

Why margin-top affects the parent div

Because when I give a margin-top in the child element, does this affect the parent element? See the example below: body{ background-color: #aaaaaa; } .topo{ width: calc(100% - 20px); max-width: 1200px; height: 130px; display:...
asked by 17.10.2018 / 14:26
1
answer

How do I put margin between an image and an HTML list?

I tried this, but the ordered list continues to paste the image ol { margin-left: 5px; } figure { margin-left: auto; margin-right: 20px; }     
asked by 27.07.2018 / 15:48
1
answer

2 simple columns with bootstrap

I have a simple question about bootstrap. I may lack some insight to understand the case. I even have some mastery over, but following these images: I know it's a simple question, I know how to solve it with css normally, but I want to...
asked by 23.05.2018 / 16:04
2
answers

How to center and position two images side by side? html css

HTML:<divid="ladoalado"><img src="imgs/login.png"><img src="imgs/cadastro.png"></div> CSS: #ladoalado{ float: left; margin: auto; } Image of the code:     
asked by 30.09.2018 / 17:46
1
answer

Position fixed mixing margin

When I set my header # header as position fixed, it took the style (for example the margin) of the div.interface, I do not understand why this happens, I want my div.interface to have margin-top: 100px and mine header 0px @charset "UTF-8";...
asked by 10.09.2018 / 16:46
0
answers

Problem with border on second sheet when printing CSS

I'm having trouble printing a document from a table. The first page respects the margins and works normally. Already the other pages, when necessary, overlap my header that accompanies all the pages. The next few pages do not respect the...
asked by 10.10.2018 / 20:19
1
answer

Margin of an element inside a div [closed]

I am not able to assign a margin-top to the element to id="cat" that is within a div . How could I assign this margin?     Test <style> a#cat{ text-decoration: none; color: black; mar...
asked by 05.12.2018 / 18:09