.cart {
  position: relative;
  display: block;
}

.cart__top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart .cart-items .cart-item + .cart-item {
  margin-top: 2.4rem;
}

.cart__empty-text,
.is-empty .cart__contents,
cart-items.is-empty .title-wrapper-with-link {
  display: none;
}

.cart__top-note {
  background-color: rgb(var(--color-gray-100));
  color: rgb(var(--color-gray-700));
  width: 100%;
  border-radius: 0.8rem;
  padding: 1.6rem;
  margin-top: 2.4rem;
  margin-bottom: 3.2rem;
  display: flex;
  column-gap: 1.2rem;
  align-items: center;
}

.cart__top-note .svg-wrapper {
  flex-shrink: 0;
  width: 2.4rem;
  height: 2.4rem;
  color: black;
}

.cart .cart-item {
  display: grid;
  width: 100%;
  column-gap: 1.6rem;
  row-gap: 1.6rem;
}

.cart .cart-item__media {
  width: 10rem;
  height: 7rem;
  display: flex;
  box-sizing: content-box;
  border-radius: 8px;
  overflow: hidden;
}

.cart thead {
  display: none;
}

.cart thead > tr {
  display: grid;
  grid-template-columns: 18rem 64fr 30fr 30fr;
  column-gap: 2.4rem;
  padding: 1.6rem;
  color: rgb(var(--color-gray-400));
  font-size: 1.5rem;
  line-height: 1.7rem;
}

@media screen and (min-width: 990px) {
  .cart .cart-item {
    grid-template-columns: 18rem 60fr 35fr 25fr;
  }

  .cart .cart-item__media {
    width: 18rem;
    height: 12rem;
    display: flex;
    box-sizing: content-box;
  }

  .cart .cart-item {
    column-gap: 2.4rem;
  }

  .cart thead {
    display: block;
  }
}

@media screen and (min-width: 750px) {
  .cart .cart-item__details,
  .cart .cart-item__quantity,
  .cart .cart-item__totals {
    display: flex;
    flex-flow: column;
    justify-content: center;
  }
}

.cart .cart-items {
  display: flex;
  flex-flow: column;
}

.cart .cart-items tbody {
  border-top: 1px solid rgb(var(--color-gray-200));
  border-bottom: 1px solid rgb(var(--color-gray-200));
  padding: 2.4rem 0;
}

@media screen and (min-width: 990px) {
  .cart .cart-items tbody {
    border: 1px solid rgb(var(--color-gray-200));
    border-radius: 0.8rem;
    padding: 1.6rem;
  }
}

.cart .cart-item__media .cart-item__image {
  width: 100%;
  height: 100%;
  max-width: unset;
  object-fit: scale-down;
  object-position: center;
}

.is-empty .cart__empty-text {
  display: block;
}

.is-empty .cart__warnings {
  display: flex;
  flex-flow: column;
  align-items: center;
}

.cart__warnings {
  display: none;
  text-align: center;
  padding: 3rem 0 1rem;
  align-items: center;
}

.cart__empty-text {
  margin: 4.5rem 0 2rem;
}

.cart__contents > * + * {
  margin-top: 2.5rem;
}

.cart__login-title {
  margin: 5.5rem 0 0.5rem;
}

.cart__login-paragraph {
  margin-top: 0.8rem;
  color: rgb(var(--color-foreground-secondary));
}

.cart__login-paragraph a {
  font-size: inherit;
}

@media screen and (min-width: 990px) {
  .cart__warnings {
    padding: 4rem 0 1rem;
  }

  .cart__empty-text {
    margin: 0 0 3rem;
  }
}

cart-items {
  display: block;
}

.cart__items {
  position: relative;
}

.cart__items--disabled {
  pointer-events: none;
}

.is-empty .cart__footer,
.is-empty .cart__top-row,
.is-empty .cart__top-note {
  display: none;
}

.cart__footer-wrapper:last-child .cart__footer {
  padding-bottom: 5rem;
}

.cart__footer > div:only-child {
  margin-left: auto;
}

.cart__footer > * + * {
  margin-top: 6.5rem;
}

.cart__footer .discounts {
  margin-bottom: 1rem;
}

.cart__note {
  height: fit-content;
  top: 2.5rem;
}

.cart__note label {
  display: flex;
  align-items: flex-end;
  position: absolute;
  line-height: 1;
  height: 1.8rem;
  top: -3rem;
  color: rgba(var(--color-foreground), 0.75);
}

.cart__note .field__input {
  height: 100%;
  position: relative;
  border-radius: var(--inputs-radius);
  padding: 1rem 2rem;
}

.cart__note .text-area {
  resize: vertical;
}

.cart__note:after,
.cart__note:hover.cart__note:after,
.cart__note:before,
.cart__note:hover.cart__note:before,
.cart__note .field__input:focus,
.cart__note .field__input {
  border-bottom-right-radius: 0;
}

@media screen and (min-width: 750px) {
  .cart__items {
    grid-column-start: 1;
    grid-column-end: 3;
  }

  .cart__contents > * + * {
    margin-top: 0;
  }

  .cart__items + .cart__footer {
    grid-column: 2;
  }

  .cart__footer {
    display: flex;
    justify-content: space-between;
    border: 0;
  }

  .cart__footer-wrapper:last-child {
    padding-top: 0;
  }

  .cart__footer > * + * {
    margin-left: 4rem;
    margin-top: 0;
  }
}

.cart__ctas button {
  width: 100%;
}

.cart__ctas > * + * {
  margin-top: 1rem;
}

.cart__update-button {
  margin-bottom: 1rem;
}

.cart__dynamic-checkout-buttons {
  max-width: 36rem;
  margin: 0 auto;
}

.cart__dynamic-checkout-buttons:has(.dynamic-checkout__content:empty) {
  margin: 0;
}

.cart-note__label {
  display: inline-block;
  margin-bottom: 1rem;
  line-height: calc(1 + 1 / var(--font-body-scale));
}

.tax-note {
  margin: 2.2rem 0 1.6rem auto;
  text-align: center;
  display: block;
}

.cart__checkout-button {
  max-width: 36rem;
}

.cart__blocks {
  width: 100%;
  max-width: 60rem;
  display: flex;
  flex-flow: column;
  row-gap: 1.6rem;
}

.cart__ctas {
  display: flex;
  flex-flow: column;
  gap: 1rem;
}

@media screen and (min-width: 750px) {
  .cart-note {
    max-width: 35rem;
  }

  .cart__update-button {
    margin-bottom: 0;
    margin-right: 0.8rem;
  }

  .tax-note {
    margin-bottom: 2.2rem;
    text-align: right;
  }

  [data-shopify-buttoncontainer] {
    justify-content: flex-end;
  }
}

.cart__back-button {
  color: black;
  text-decoration: underline;
  font-weight: 600;
  text-underline-offset: 0.2rem;
  letter-spacing: -0.03rem;
}
