HTML
Kod
<!DOCTYPE html>
<html lang="pl" dir="ltr">
<head>
<meta charset="utf-8">
<title>Testy</title>
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body>
<div class="conteiner">
<div class="box">
<div class="menu1"></div>
</div>
</div>
</body>
</html>
<html lang="pl" dir="ltr">
<head>
<meta charset="utf-8">
<title>Testy</title>
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body>
<div class="conteiner">
<div class="box">
<div class="menu1"></div>
</div>
</div>
</body>
</html>
CSS
Kod
body{
background-image: url(img/tło.png);
}
.conteiner{
width: 100%;
height: 100%
}
.box{
width: 810px;
height: 500px;
background-color: black;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
opacity: 0.5;
}
.menu1{
background-color: #ffffff;
width: 220px;
height: 220px;
margin: 30px;
}
background-image: url(img/tło.png);
}
.conteiner{
width: 100%;
height: 100%
}
.box{
width: 810px;
height: 500px;
background-color: black;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
opacity: 0.5;
}
.menu1{
background-color: #ffffff;
width: 220px;
height: 220px;
margin: 30px;
}