Jump to content
  • 0

Непонятный отступ с margin-top?


doox911
 Share

Question


<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="css/index.css" rel="stylesheet" type="text/css">
<meta name="keywords" content="">
<meta name="description" content="">
<title>Лесничество"Русский Лес"</title>
</head>
<body>
<div id="header">
<div id="vc">
</div>
</div>

<div id="podl_content">
<div id="content">
<div class="ukaz">
<h2>Информация о филиале</h2>
</div>
<div id="footer">
</div>
</div>
</div>
<br />
</body>
</html>


body{
margin: 0px;
padding: 0px;
background-image: url(fon2.png);
}
html, body, h1, h2, h3, h4, h5, h6, p, em, strong, abbr, acronym, blockquote, q,
cite, ins, del, dfn, a, div, span, pre, hr, address, br, b, i, sub, sup, big, small,
tt, table, tr, caption, thead, tbody, tfoot, col, colgroup, form, input, label,
textarea, button, fieldset, legend, select, option, optiongroup, ul, ol, dl, dt,
dd, code, var, kdb, samp, img, object, param, map, area, bdo, iframe{
padding: 0;
margin: 0;
}
#header{
z-index: 2;
position: relative;
height: 82px;
width: 100%;
background-image: url(2.png);
background-repeat: repeat-x;
}
#vc{
width: 1320px;
margin: 0 auto;
}
.vm{
display: inline-block;
text-align: center;
width: 220px;
height: 85px;
float: left;
}
.vm:hover{
background-image: url(3.png);
background-repeat: no-repeat;
background-position: 0px 73px;
}
#vc a{
padding:0;
margin:0;
padding-top: 25px;
width: 220px;
height: 57px;
color: #fff;
font-size: 20pt;
font-weight: bold;
text-decoration: none;
}
#vc a:hover{
color: grey;
}
#podl_content{
z-index: 1;
position: relative;
margin: 0px auto;
padding: 0px;
width: 1216px;
background-color: lightgrey;
}
#content{
background-image: url(88.png); position: relative;
background-repeat: repeat-y; /* Отменяем повторение фона */
background-position: center;
margin: 0px auto; padding: 0px;
width: 1214px;
}
.ukaz{
padding: 0px;
padding-top: 5px;
margin: 0px;
margin-top: 5px;
background-image: url(6.png);
height: 45px; text-align: center;
width: 1200px;margin-left: 7px;
}
.ukaz h2{
padding: 0px;
margin: 0px;
color: white;
}
#footer{
background-image: url(54.png);
margin: 0px auto;
height: 82px;
width: 1214px;
}

Помогите пожалуйста понять. Почему используя margin-top: 5px; в .ukaz идёт отступ всего #podl_content?

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. See more about our Guidelines and Privacy Policy