.cart-drawer {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  max-width: 100%;
  height: 100vh;
  background: #fff;
  z-index: 9999;
  box-shadow: -6px 0 24px rgba(0, 0, 0, 0.15);
  transition: right 0.25s ease;
  display: flex;
  flex-direction: column;
}

.cart-drawer.is-open {
  right: 0;
}

.cart-drawer__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 9998;
  display: none;
}

.cart-drawer__backdrop.is-open {
  display: block;
}

.cart-drawer__head {
  padding: 22px 22px 20px;
  border-bottom: 1px solid #ececec;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-drawer__head strong {
  font-size: 22px;
  line-height: 1.1;
  font-weight: 500;
}

.cart-drawer__close {
  appearance: none;
  border: 0;
  background: transparent;
  font-size: 34px;
  line-height: 1;
  color: #1d67d9;
  cursor: pointer;
  padding: 0;
}

.cart-drawer__body {
  flex: 1;
  overflow: auto;
  padding: 18px 16px;
}

.cart-drawer__foot {
  border-top: 1px solid #ececec;
  padding: 16px 20px 24px;
}

.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cart-item {
  border: 1px solid #d8d8d8;
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 14px;
  background: #fff;
}

.cart-item__layout {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.cart-item__media {
  flex-shrink: 0;
}

.cart-item__content {
  flex: 1;
  min-width: 0;
}

.cart-item__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.cart-item__row--bottom {
  align-items: center;
  margin-top: 10px;
}

.cart-item__title-text {
  font-size: 20px;
  line-height: 1.3;
  font-weight: 700;
  margin: 0;
}

.cart-item__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid #f0f0f0;
}

.cart-item__variant {
  margin-top: 6px;
  font-size: 16px;
  line-height: 1.3;
  color: #111;
}

.cart-item__remove {
  appearance: none;
  border: 0;
  background: transparent;
  color: #666;
  font-size: 20px;
  cursor: pointer;
  padding: 2px;
}

.cart-item__qty {
  margin-top: 0;
  border: 1px solid #c4c4c4;
  border-radius: 999px;
  min-width: 120px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
}

.cart-item__qty-btn {
  width: 24px;
  height: 24px;
  border: 0;
  background: transparent;
  font-size: 24px;
  font-weight: 400;
  line-height: 24px;
  cursor: pointer;
  color: #111;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
  transform: translateY(-1px);
}

.cart-item__qty-value {
  font-size: 18px;
  font-weight: 600;
  line-height: 1;
  min-width: 24px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-1px);
}

.cart-item__price {
  margin-top: 0;
  color: #3f13b8;
  font-size: 20px;
  font-weight: 700;
}

.cart-item__title {
  font-size: 20px;
  font-weight: 700;
  margin: 16px 0 20px;
}

.cart-page__layout,
.checkout-page__layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
}

.cart-page,
.checkout-page {
  padding: 30px 0 50px;
}

.cart-page__stepper,
.checkout-page__stepper {
  display: flex;
  gap: 24px;
  color: #808080;
  margin-bottom: 20px;
}

.cart-page__stepper .is-active,
.checkout-page__stepper .is-active {
  color: #101010;
  font-weight: 600;
}

.cart-page__summary,
.checkout-page__summary {
  background: #f5f5f8;
  border-radius: 14px;
  padding: 22px;
  height: fit-content;
}

.cart-page__summary-row,
.checkout-page__summary-row {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
}

.cart-page__summary-row--total strong,
.checkout-page__summary-row--total strong {
  color: #4a1bb3;
}

.cart-page__checkout-btn,
.checkout-page__submit-btn,
.cart-drawer__btn {
  width: 100%;
  background: #4a1bb3;
  color: #fff;
  border-radius: 999px;
  border: none;
  display: inline-block;
  text-align: center;
  padding: 12px 16px;
  margin-top: 14px;
  font-weight: 600;
}

.cart-drawer__btn--light {
  background: #ececf3;
  color: #4a1bb3;
}

.checkout-page__form input[type="text"],
.checkout-page__form input[type="email"] {
  width: 100%;
  border: 1px solid #e3e3e3;
  border-radius: 10px;
  height: 44px;
  padding: 0 12px;
}

.checkout-page__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.checkout-page__field {
  margin-bottom: 12px;
}

.checkout-page__bank-info {
  border: 1px solid #dfdfdf;
  border-radius: 8px;
  padding: 12px;
  margin: 10px 0 12px;
}

.checkout-page__bank-item {
  padding: 10px 0;
  border-bottom: 1px dashed #e5e5e5;
  text-align: center;
}

.checkout-page__bank-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.checkout-page__bank-qr {
  margin-bottom: 10px;
}

.checkout-page__bank-qr img {
  display: block;
  width: 150px;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  border: 1px solid #e3e3e3;
  border-radius: 8px;
  padding: 4px;
  background-color: #fff;
}

.checkout-page__bank-meta p {
  margin: 0 0 4px;
}

.checkout-page__bank-meta p:last-child {
  margin-bottom: 0;
}

.checkout-page__bank-name {
  margin-bottom: 6px !important;
}

.checkout-page__loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(1px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}

.checkout-page__loading-overlay.is-active {
  display: flex;
}

.checkout-page__loading-box {
  text-align: center;
  padding: 16px 20px;
  border: 1px solid #e6e6e6;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.checkout-page__loading-spinner {
  width: 34px;
  height: 34px;
  border: 3px solid #e8defa;
  border-top-color: #4a1bb3;
  border-radius: 50%;
  margin: 0 auto 10px;
  animation: checkout-spin 0.8s linear infinite;
}

@keyframes checkout-spin {
  to {
    transform: rotate(360deg);
  }
}

.checkout-page__message {
  margin-top: 10px;
  font-weight: 600;
}

/* Cart page visual tuning to match design */
.cart-page__stepper {
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 46px;
}

.checkout-page__stepper {
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 46px;
}

.cart-page__stepper span {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding-right: 42px;
  margin-right: 18px;
  font-size: 14px;
  line-height: 1.1;
  color: #111;
  font-weight: 600;
}

.checkout-page__stepper span {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding-right: 42px;
  margin-right: 18px;
  font-size: 14px;
  line-height: 1.1;
  color: #111;
  font-weight: 600;
}

.cart-page__stepper span::before {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #d5d7e2;
  color: #8c90a3;
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.checkout-page__stepper span::before {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #d5d7e2;
  color: #8c90a3;
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cart-page__stepper span:nth-child(1)::before {
  content: "1";
}

.checkout-page__stepper span:nth-child(1)::before {
  content: "1";
}

.cart-page__stepper span:nth-child(2)::before {
  content: "2";
}

.checkout-page__stepper span:nth-child(2)::before {
  content: "2";
}

.cart-page__stepper span:nth-child(3)::before {
  content: "3";
}

.checkout-page__stepper span:nth-child(3)::before {
  content: "3";
}

.cart-page__stepper span::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 28px;
  height: 1px;
  background: #d9dbe5;
  transform: translateY(-50%);
}

.checkout-page__stepper span::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 28px;
  height: 1px;
  background: #d9dbe5;
  transform: translateY(-50%);
}

.cart-page__stepper span:last-child {
  margin-right: 0;
  padding-right: 0;
}

.checkout-page__stepper span:last-child {
  margin-right: 0;
  padding-right: 0;
}

.cart-page__stepper span:last-child::after {
  display: none;
}

.checkout-page__stepper span:last-child::after {
  display: none;
}

.cart-page__stepper .is-active::before {
  border-color: #0c1f54;
  background: #0c1f54;
  color: #fff;
}

.checkout-page__stepper .is-active::before {
  border-color: #0c1f54;
  background: #0c1f54;
  color: #fff;
}

.cart-page__title {
  font-size: 24px;
  line-height: 1.05;
  text-align: center;
  margin: 0 0 26px;
  font-weight: 700;
}

.checkout-page__title {
  font-size: 32px;
  line-height: 1.1;
  text-align: center;
  margin: 0 0 26px;
  font-weight: 700;
}

.cart-page__layout {
  gap: 38px;
  align-items: start;
}

.checkout-page__layout {
  gap: 38px;
  align-items: start;
}

.cart-page__items .cart-item {
  border: 0;
  border-top: 1px solid #ededf3;
  border-radius: 0;
  margin: 0;
  padding: 22px 0;
}

.cart-page__items .cart-item:last-child {
  border-bottom: 1px solid #ededf3;
}

.cart-page__items .cart-item__layout {
  align-items: center;
  gap: 16px;
}

.cart-page__items .cart-item__avatar {
  width: 48px;
  height: 48px;
}

.cart-page__items .cart-item__title-text {
  font-size: 18px;
  line-height: 1.1;
}

.cart-page__items .cart-item__variant {
  font-size: 16px;
  line-height: 1.2;
  color: #555;
}

.cart-page__items .cart-item__qty {
  min-width: 120px;
  height: 48px;
  padding: 0 12px;
  border-color: #ececf2;
}

.cart-page__items .cart-item__qty-btn {
  font-size: 24px;
}

.cart-page__items .cart-item__qty-value {
  font-size: 18px;
}

.cart-page__items .cart-item__price {
  font-size: 18px;
  color: #3510bf;
}

.cart-page__items .cart-item__remove {
  color: #b3b8c6;
  font-size: 20px;
}

.cart-page__update-btn {
  margin-top: 26px;
  padding: 10px 24px;
  border: 0;
  border-radius: 999px;
  background: #f2f3f8;
  color: #4a1bb3;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}

.cart-page__summary {
  border-radius: 18px;
  padding: 24px 26px;
}

.checkout-page__summary {
  border-radius: 18px;
  padding: 24px 26px;
}

.cart-page__summary h3 {
  margin: 0;
  padding-bottom: 18px;
  border-bottom: 1px solid #e5e6ee;
  font-size: 20px;
  line-height: 1.15;
}

.checkout-page__summary h3 {
  margin: 0;
  padding-bottom: 18px;
  border-bottom: 1px solid #e5e6ee;
  font-size: 20px;
  line-height: 1.15;
}

.cart-page__summary-row--total {
  margin-top: 18px;
}

.checkout-page__summary-row--total {
  margin-top: 18px;
}

.cart-page__summary-row--total span,
.cart-page__summary-row--total strong {
  font-size: 18px;
  line-height: 1.1;
  font-weight: 700;
  color: #111;
}

.checkout-page__summary-row--total span,
.checkout-page__summary-row--total strong {
  font-size: 18px;
  line-height: 1.1;
  font-weight: 700;
  color: #111;
}

.cart-page__checkout-btn {
  margin-top: 32px;
  padding: 12px 20px;
  font-size: 16px;
  font-weight: 500;
}

.checkout-page__submit-btn {
  margin-top: 20px;
  padding: 12px 20px;
  font-size: 16px;
  font-weight: 500;
}

.checkout-page__payment h3 {
  font-size: 16px;
  margin-bottom: 5px;
}

.checkout-page__form label {
  display: inline-block;
  font-size: 14px;
  margin-bottom: 6px;
}

.checkout-page__form input::placeholder {
  color: #9a9a9a;
}

.checkout-page__form .checkout-page__error {
  display: block;
  margin-top: 4px;
  color: #d92d20;
  font-size: 12px;
  line-height: 1.3;
}

.checkout-page__form .is-invalid {
  border-color: #d92d20 !important;
}

@media (max-width: 991px) {
  .cart-page__stepper {
    margin-bottom: 24px;
    overflow-x: auto;
    white-space: nowrap;
  }

  .checkout-page__stepper {
    margin-bottom: 24px;
    overflow-x: auto;
    white-space: nowrap;
  }

  .cart-page__stepper span {
    font-size: 14px;
    padding-right: 22px;
    margin-right: 10px;
  }

  .checkout-page__stepper span {
    font-size: 14px;
    padding-right: 22px;
    margin-right: 10px;
  }

  .cart-page__title {
    font-size: 24px;
    margin-bottom: 22px;
  }

  .checkout-page__title {
    font-size: 24px;
    margin-bottom: 22px;
  }

  .cart-page__items .cart-item__title-text {
    font-size: 18px;
  }

  .cart-page__items .cart-item__variant {
    font-size: 14px;
  }

  .cart-page__items .cart-item__qty {
    min-width: 120px;
    height: 48px;
    padding: 0 12px;
  }

  .cart-page__items .cart-item__qty-btn {
    font-size: 24px;
  }

  .cart-page__items .cart-item__qty-value {
    font-size: 14px;
  }

  .cart-page__items .cart-item__price {
    font-size: 18px;
  }

  .cart-page__update-btn {
    font-size: 16px;
  }

  .cart-page__summary h3 {
    font-size: 20px;
  }

  .checkout-page__summary h3 {
    font-size: 20px;
  }

  .cart-page__summary-row--total span,
  .cart-page__summary-row--total strong {
    font-size: 18px;
  }

  .checkout-page__summary-row--total span,
  .checkout-page__summary-row--total strong {
    font-size: 18px;
  }

  .cart-page__checkout-btn {
    font-size: 16px;
  }

  .checkout-page__submit-btn {
    font-size: 16px;
  }

  .cart-page__layout,
  .checkout-page__layout {
    grid-template-columns: 1fr;
  }

  .cart-drawer {
    width: 100%;
    right: -100%;
  }
}
