what is wrong with ths css code?
Why does this code not give me two columns? I have looked at it for too
long for my brain to work. I am then using media queries to change it from
two columns to one.
body {
width: 80%;
margin: 50px auto;
}
section {
width: 70%; // 70 percent of its container
margin: auto;
-webkit-box-shadow: 0 0 5px rgba(0, 0, 0, .3);
box-shadow: 0 0 5px rgba(0, 0, 0, .3);
padding:30px;
}
p {
webkit-columns:2;
columns:2;
-webkit-column-gap:20px;
-moz-column-gap:20px;
column-gap:20px;
}
img {
width:100%;
}
@media screen and (max-width:800px){
p{
-webkit-columns:1;
-moz-columns:1;
columns:1;
}
}
No comments:
Post a Comment