This is a solution to the Stats preview card component challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.
Users should be able to:
- View the optimal layout depending on their device's screen size
- Semantic HTML5 markup
- CSS custom properties
- Flexbox
- CSS Grid
- Mobile-first workflow
<div class="card__image">
<div class="card__image--color"></div>
</div>
.card__image {
position: relative;
width: 100%;
height: 320px;
background-image: url("./images/image-header-mobile.jpg");
background-position: center;
background-size: cover;
border-radius: 8px 8px 0 0;
}
@media (min-width: 800px) {
.card {
width: 85%;
display: flex;
flex-direction: row-reverse;
}
}
I definitely need to work and study more on image containers. I'm having trouble accommodating them in different sizes.
I used the guide of challenge found on Frontend Mentors website. Only that.
- Frontend Mentor - heraldofortuna
- Twitter - @heraldofortuna
To my father, for everything.