<div class="kutu">
<h1>Tarayıcının genişliğini değiştirin.</h1>
<ul>
<li>Küçük</li>
<li>Orta</li>
<li>Büyük</li>
</ul>
</div>
.kutu {
width: 100%;
height: 80px;
}
@media (min-width: 1100px) {
body {
background: #fffa84;
}
ul li:nth-child(3) {
background-color: rgba(0, 0, 0, 0.7);
color: rgb(255,255,255);
}
}
@media (min-width: 480px) and (max-width: 1100px) {
body {
background: #50f7b2;
}
ul li:nth-child(2) {
background-color: rgba(0, 0, 0, 0.7);
color: rgb(255,255,255);
}
}
@media (max-width: 480px) {
body {
background: #f95e8a;
}
ul li:nth-child(1) {
background-color: rgba(0, 0, 0, 0.7);
color: rgb(255,255,255);
}
}
@import url('https://fonts.googleapis.com/css?family=Merriweather+Sans:300,800');
body {
font-family: 'Merriweather Sans', sans-serif;
width: 550px;
margin-inline: auto;
}
h1 {
margin-top: 50px;
text-align: center;
margin-bottom: 0;
}
h1:after {
display: block;
content: " ";
font-family: "Open Sans", sans-serif;
font-size: 1rem;
font-weight: 400;
letter-spacing: 0.056rem;
color: rgba(0, 0, 0, 0.5);
width: 80%;
margin: 10px auto;
padding: 0;
border-top: 2px solid rgba(0, 0, 0, 0.1);
}
ul {
display: flex;
flex-direction: row;
list-style: none;
justify-content: center;
margin: 0;
padding: 0;
}
ul li {
margin-right: 10px;
font-size: 18px;
padding: 5px 10px;
border-radius: 5px;
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.