개발자 99% 커뮤니티에서 수다 떨어요!
<!DOCTYPE html>
<head>
<title>Web1</title>
<style>
body {
display: flex;
height: 100vh;
align-items: center;
justify-content: center;
flex-direction: column;
}
div{
background-color: teal;
width: 200px;
height: 200px;
}
@media screen and (min-width: 601px) and (max-width: 1200px) and (orientation: landscape) {
div{
background-color: wheat;
}
}
span{
font-size: 36px;
}
@media screen and (orientation: landscape) {
span:first-child {display: none;}
}
@media screen and (orientation: portrait) {
span:nth-child(2) {display: none;}
}
</style>
</head>
<body>
<div></div>
<span>Flip!</span>
<span>Good!</span>
</body>
</html>
궁금해요!! firstchild로 선택하면 되지않나용?