*,
*::before,
*::after {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

:root {
  --black: hsl(212, 21%, 14%);
  --cream: hsl(30, 38%, 92%);
  --grey: hsl(228, 12%, 48%);
  --green: hsl(158, 36%, 37%);
  --green-hover: hsl(158, 42%, 18%);
  --white: hsl(0, 0%, 100%);
  --blue: hsl(228, 45%, 44%);
}

body {
  background-color: var(--cream);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-family: "Montserrat", sans-serif;
}

main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

h1 {
  margin: 1rem 0;
  font-family: "Fraunces", serif;
  font-size: clamp(1.5rem, 5vw, 2.5rem);
  line-height: 1.3;
}

p {
  font-size: 0.875rem;
  color: var(--grey);
  line-height: 1.6;
}

.container {
  display: flex;
  margin: 0 auto;
  border-radius: 0.5rem;
  width: 90%;
  max-width: 40.625rem;
  overflow: hidden;
  background-color: var(--white);
}

.img_section {
  aspect-ratio: 700 / 684;
  border-radius: 0.5rem;
}

.parfum {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.info {
  padding: 1.5rem;
}

.image_section,
.info {
  flex: 0 0 50%;
}

.product {
  text-transform: uppercase;
  letter-spacing: 0.2rem;
  color: var(--grey);
}

.price_section {
  display: flex;
  margin: 1rem 0;
  gap: 1rem;
  justify-content: flex-start;
  align-items: center;
  font-family: "Fraunces", serif;
}

.new_price {
  color: var(--green);
  font-size: 1.5rem;
  font-weight: 700;
}

.old_price {
  color: var(--grey);
  text-decoration: line-through;
  font-size: 0.75rem;
}

.btn {
  background-color: var(--green);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.5rem;
  border: none;
  width: 100%;
  padding: 0.875rem 2rem;
  color: var(--white);
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn:hover,
.btn:focus {
  background-color: var(--green-hover);
}

footer {
  margin-block-end: 1rem;
}

.attribution {
  font-size: 0.875rem;
  text-align: center;
}
.attribution a {
  color: var(--blue);
}

@media (max-width: 37.5rem) {
  .container {
    flex-direction: column;
    max-width: 20rem;
  }

  .img_section {
    aspect-ratio: 600 / 900;
  }

  .parfum {
    border-radius: 0;
  }

  .info {
    border-radius: 0;
  }

  .btn {
    width: 100%;
  }
}
