.ij-monthly-bestsellers {
  background: #f7f2e8;
  padding-block: clamp(2.75rem, 5vw, 4.75rem);
}

.ij-monthly-bestsellers__heading {
  align-items: end;
  display: flex;
  gap: 2rem;
  justify-content: space-between;
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.ij-monthly-bestsellers__heading h2 {
  color: #25261f;
  font-family: var(--ij-serif, Georgia, "Times New Roman", serif);
  font-size: clamp(2.25rem, 4vw, 3.75rem);
  font-weight: 400;
  line-height: 1;
  margin: 0;
}

.ij-monthly-bestsellers__heading > p {
  color: #5f605a;
  line-height: 1.55;
  margin: 0 0 .2rem;
  max-width: 32rem;
}

.ij-monthly-bestsellers__list {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 1px;
  background: #ded8ca;
}

.ij-monthly-bestsellers__item {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: #fff;
}

.ij-monthly-bestsellers__image {
  aspect-ratio: 1;
  display: grid;
  overflow: hidden;
  place-items: center;
  position: relative;
  background: #fff;
}

.ij-monthly-bestsellers__image img {
  display: block;
  height: 78%;
  object-fit: contain;
  padding: 0;
  transition: transform .35s ease;
  width: 78%;
}

.ij-monthly-bestsellers__image picture {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
}

.ij-monthly-bestsellers__item:hover img {
  transform: scale(1.035);
}

.ij-monthly-bestsellers__rank {
  align-items: center;
  display: flex;
  height: 2.35rem;
  justify-content: center;
  left: .75rem;
  position: absolute;
  top: .75rem;
  width: 2.35rem;
  z-index: 1;
  background: #25261f;
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
}

.ij-monthly-bestsellers__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: .8rem;
  min-height: 12rem;
  padding: 1rem 1rem 1.2rem;
}

.ij-monthly-bestsellers__name {
  display: -webkit-box;
  overflow: hidden;
  color: #25261f;
  font-size: .95rem;
  font-weight: 400;
  line-height: 1.35;
  text-decoration: none;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.ij-monthly-bestsellers__name:hover,
.ij-monthly-bestsellers__name:focus-visible {
  color: #9d442c;
}

.ij-monthly-bestsellers__price {
  margin-top: auto;
  color: #9d442c;
  font-size: 1rem;
  font-weight: 700;
}

.ij-monthly-bestsellers__actions {
  margin-top: .15rem;
}

.ij-monthly-bestsellers__form {
  align-items: stretch;
  display: grid;
  gap: .45rem;
  grid-template-columns: 9rem 2.75rem;
  justify-content: start;
}

.ij-monthly-bestsellers__form .quantity-button,
.ij-monthly-bestsellers__form .quantity-button__group {
  min-width: 0;
  width: 100%;
}

.ij-monthly-bestsellers__form .quantity-button__group {
  display: flex !important;
  flex-wrap: nowrap !important;
}

.ij-monthly-bestsellers__form .quantity-button__group > .btn,
.ij-monthly-bestsellers__form .quantity-button__group > input,
.ij-monthly-bestsellers__add {
  height: 2.75rem;
  min-height: 2.75rem;
}

.ij-monthly-bestsellers__form .quantity-button__group > .btn {
  flex: 0 0 2.75rem;
  min-width: 2.75rem;
  padding: 0;
  width: 2.75rem;
  background: #fff;
  border: 1px solid #d8d4cc;
  color: #25261f;
}

.ij-monthly-bestsellers__form .quantity-button__group > input {
  display: block !important;
  flex: 0 0 3.5rem !important;
  min-width: 3.5rem !important;
  max-width: 3.5rem !important;
  width: 3.5rem !important;
  padding-inline: .2rem;
  position: static !important;
  visibility: visible !important;
  opacity: 1 !important;
  border: 1px solid #d8d4cc !important;
  border-inline: 0 !important;
  border-radius: 0 !important;
  background: #fff !important;
  color: #25261f !important;
  -webkit-text-fill-color: #25261f;
  text-align: center !important;
}

.ij-monthly-bestsellers__form .quantity-button__group > .btn:first-child {
  border-radius: .35rem 0 0 .35rem;
}

.ij-monthly-bestsellers__form .quantity-button__group > .btn:last-child {
  border-radius: 0 .35rem .35rem 0;
}

.ij-monthly-bestsellers__add {
  min-width: 2.75rem;
  padding: 0;
  width: 2.75rem;
  border-color: #16884f;
  background: #16884f;
  color: #fff;
}

.ij-monthly-bestsellers__add:hover,
.ij-monthly-bestsellers__add:focus-visible {
  border-color: #126b43;
  background: #126b43;
  color: #fff;
}

.ij-monthly-bestsellers__details {
  align-items: center;
  display: inline-flex;
  min-height: 2.75rem;
  color: #25261f;
  font-size: .82rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: .2rem;
}

@media (max-width: 991.98px) {
  .ij-monthly-bestsellers__list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .ij-monthly-bestsellers__heading {
    align-items: start;
    flex-direction: column;
    gap: .85rem;
  }

  .ij-monthly-bestsellers__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-inline: 0;
    overflow: visible;
    padding: 1px;
    scroll-snap-type: none;
  }

  .ij-monthly-bestsellers__item {
    min-width: 0;
    scroll-snap-align: none;
  }

  .ij-monthly-bestsellers__item:last-child {
    margin-right: 0;
  }

  .ij-monthly-bestsellers__rank {
    top: .5rem;
    left: .5rem;
    width: 2rem;
    height: 2rem;
    font-size: .7rem;
  }

  .ij-monthly-bestsellers__body {
    gap: .65rem;
    min-height: 13rem;
    padding: .75rem;
  }

  .ij-monthly-bestsellers__name {
    font-size: .84rem;
  }

  .ij-monthly-bestsellers__price {
    font-size: .92rem;
  }

  .ij-monthly-bestsellers__form {
    grid-template-columns: minmax(0, 1fr);
    gap: .35rem;
  }

  .ij-monthly-bestsellers__form .quantity-button__group > .btn {
    flex: 1 1 0;
    width: auto;
    min-width: 0;
  }

  .ij-monthly-bestsellers__form .quantity-button__group > input {
    flex: 1 1 0 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
  }

  .ij-monthly-bestsellers__add {
    width: 100%;
  }
}
