@InityeSubmitted about 2 years ago
I don't know how to make img margins on phone view, it was supposed to cover all space
I don't know how to make img margins on phone view, it was supposed to cover all space
Hello I'm new at coding but this is the solution that I implemented in my version of this challenge
@media (max-width: 600px){ .mobileProduct{ display: flex; flex-direction: column; width: 23rem; border-top-right-radius: 1rem; border-top-left-radius: 1rem; }
.card {
display: flex;
flex-direction: column;
background-color: var(--white);
border-radius: 1rem;
height: 43rem;
width: 23rem;
align-items: center;
justify-content: flex-end;
}
.desktopProduct {
display: none;
}
.text {
display: flex;
flex-direction: column;
align-items: center;
margin: 1rem;
}
}
Hi, just did the same challenge and inspecting your code, found a better way to center elements on sites. Thank you for that, and your solution looks great.
My code is way different because I try to use only the basic of HTML and CSS. This way, I find that a lot of problems come up and start training that part of coding that is solving problems and coming up with solution on the fly.