/* src/styles/cart.css */
.t-cart {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  color: var(--ink);
  font-family: inherit;
}

.t-cart__backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  cursor: default;
  background: rgba(16, 15, 13, 0.42);
  transition: opacity 280ms ease;
}

.t-cart__drawer {
  position: absolute;
  top: 0;
  right: 0;
  width: min(520px, 100%);
  height: 100%;
  display: flex;
  flex-direction: column;
  background: #f7f3ec;
  transform: translateX(100%);
  transition: transform 360ms cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: -24px 0 70px rgba(16, 15, 13, 0.16);
}

.t-cart.is-open {
  pointer-events: auto;
}

.t-cart.is-open .t-cart__backdrop {
  opacity: 1;
}

.t-cart.is-open .t-cart__drawer {
  transform: none;
}

.t-cart__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 36px 28px;
  border-bottom: 1px solid var(--line);
}

.t-cart__eyebrow,
.t-cart__article {
  display: block;
  color: var(--gold);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.t-cart__header h2 {
  margin: 8px 0 0;
  font-size: 34px;
  font-weight: 400;
  line-height: 1;
}

.t-cart__count {
  color: var(--muted);
  font-size: 16px;
  vertical-align: top;
}

.t-cart__close {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  padding: 0;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  background: transparent;
}

.t-cart__items {
  flex: 1;
  overflow-y: auto;
  padding: 8px 36px;
}

.t-cart__item {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}

.t-cart__item img {
  width: 88px;
  height: 108px;
  display: block;
  object-fit: cover;
  background: #eee9df;
}

.t-cart__item-body {
  min-width: 0;
}

.t-cart__item h3 {
  margin: 7px 0 14px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
}

.t-cart__item > strong {
  align-self: start;
  padding-top: 23px;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}

.t-cart__quantity {
  display: flex;
  align-items: center;
  gap: 12px;
}

.t-cart__quantity button {
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  line-height: 1;
  background: transparent;
}

.t-cart__quantity span {
  min-width: 12px;
  text-align: center;
  font-size: 12px;
}

.t-cart__quantity .t-cart__remove {
  width: auto;
  margin-left: 6px;
  border: 0;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.t-cart__empty {
  margin: auto;
  padding: 48px 36px;
  text-align: center;
}

.t-cart__empty p {
  margin: 0 0 10px;
  font-family: Georgia, serif;
  font-size: 28px;
}

.t-cart__empty span {
  display: block;
  max-width: 300px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.t-cart__footer {
  padding: 26px 36px 32px;
  border-top: 1px solid var(--line);
  background: #f7f3ec;
}

.t-cart__total {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.t-cart__total strong {
  font-weight: 600;
}

.t-cart__email {
  display: grid;
  gap: 7px;
  margin: 0 0 14px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.t-cart__email-input {
  width: 100%;
  min-height: 44px;
  box-sizing: border-box;
  border: 1px solid var(--line);
  padding: 0 12px;
  color: var(--ink);
  font: inherit;
  letter-spacing: normal;
  text-transform: none;
  background: #fff;
}

.t-cart__checkout {
  width: 100%;
  padding: 17px 24px;
  border: 1px solid var(--ink);
  color: #f7f3ec;
  cursor: pointer;
  font: inherit;
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  background: var(--ink);
}

.t-cart__status {
  min-height: 1.5em;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.card__add {
  cursor: pointer;
}

@media (max-width: 600px) {
  .t-cart__header,
  .t-cart__items,
  .t-cart__footer {
    padding-left: 20px;
    padding-right: 20px;
  }

  .t-cart__item {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .t-cart__item img {
    width: 72px;
    height: 92px;
  }

  .t-cart__item > strong {
    grid-column: 2;
    padding: 0;
  }
}

.bag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.bag__count {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 30px;
  border-radius: 50%;
  color: #f7f3ec;
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0;
  background: #100f0d;
}

.card__variant-data,
.card__variant-data[hidden] {
  display: none !important;
}