/* Box sizing rules */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default margin */
body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd {
  margin: 0;
}

/* Remove list styles on ul, ol elements with a list role, which suggests default styling will be removed */
ul[role='list'],
ol[role='list'] {
  list-style: none;
}

/* Set core root defaults */
html:focus-within {
  scroll-behavior: smooth;
}

/* Set core body defaults */
body {
  min-height: 100vh;
  text-rendering: optimizeSpeed;
  line-height: 1.5;
}

/* A elements that don't have a class get default styles */
a:not([class]) {
  text-decoration-skip-ink: auto;
}

/* Make images easier to work with */
img,
picture {
  max-width: 100%;
  display: block;
}

/* Inherit fonts for inputs and buttons */
input,
button,
textarea,
select {
  font: inherit;
}

/* Remove all animations, transitions and smooth scroll for people that prefer not to see them */
@media (prefers-reduced-motion: reduce) {
  html:focus-within {
   scroll-behavior: auto;
  }
  
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

html {
    box-sizing: border-box;
}

body {
    background-color: #f2ebe3;
    font-family: 'Montserrat';
    font-size: 14px;
    color: hsl(228, 12%, 48%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1em;
}

.product-card {
    /* border: 1px solid red; */
    background-color: hsl(0, 0%, 100%);
    width: 100%;
    max-width: 714px;
    display: flex;
    flex-direction: column;
    border-radius: 10px;
    -webkit-border-radius: 10px;
    -moz-border-radius: 10px;
    -ms-border-radius: 10px;
    -o-border-radius: 10px;
}

.product-image {
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
}

.product-info {
    margin: 1.3em;
}

h1 {
    text-transform: uppercase;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.35rem;
}

h2 {
    font-family: 'Fraunces', serif;
    font-size: 2.25em;
    color: black;
    margin: 0.5rem auto 1rem;
    line-height: 1em;
}

.pricing{
    display: flex;
    align-items: center;
    margin: 2rem auto 1rem ;
}

.price {
    color: hsl(158, 36%, 37%);
    font-family: 'Fraunces', serif;
    font-size: 2rem;
    width: 50%;
}

.old-price {
    width: 50%;
    text-decoration: line-through;
}

button {
    border: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    background-color: hsl(158, 36%, 37%);
    color: hsl(30, 38%, 92%);
    padding: 1em 2rem;
    border-radius: 10px;
    -webkit-border-radius: 10px;
    -moz-border-radius: 10px;
    -ms-border-radius: 10px;
    -o-border-radius: 10px;
}

button:active {
    background-color: hsl(160, 34%, 24%);
}

.cart-img{
    margin: auto 1.2rem auto;
}

.attribution {
    font-size: 11px;
    text-align: center;
    position: fixed;
    bottom: 0;
    padding-bottom: 5px;
}

.attribution a {
    color: hsl(228, 45%, 44%);
}

@media (min-width: 714px) {
    .product-card {
        flex-direction: row;
        max-width: 575px;
    }

    .product-image {
        background-image: url('images/image-product-desktop.jpg');
        border-top-right-radius: 0;
        border-bottom-left-radius: 10px;
        max-height: 500px;
    }

    .product-info {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        margin: 1.5rem;
        width: 50%;
    }

    h2 {
        margin: 0;
    }

    .pricing {
        margin: 0;
    }

    .old-price {
        display: flex;
        justify-content: center;
    }

    footer {
        padding-bottom: 10px;
    }
}
