/* ── STEPPER ── */
.stepper-wrap {
  background: #ffffff;
  border-bottom: 1px solid #e4e4e7;
  padding: 20px 32px;
}

.stepper {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  flex-shrink: 0;
  max-width: 20vw;
}

@media (min-width: 600px) {
  .step {
    flex-direction: row;
  }
}

.step-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  border: 1.5px solid #e4e4e7;
  color: #71717a;
  background: #ffffff;
  flex-shrink: 0;
}

.step.active .step-circle {
  background: var(--checkout-theme-color);
  border-color: var(--checkout-theme-color);
  color: #ffffff;
}

.step.done .step-circle {
  background: #f0fdf4;
  border-color: #16a34a;
  color: #16a34a;
  font-size: 14px;
}

.step-label {
  font-size: 13px;
  font-weight: 500;
  color: #71717a;
  text-align: center;
}
.step.active .step-label {
  color: var(--checkout-theme-color);
  font-weight: 600;
}
.step.done .step-label {
  color: #71717a;
}

.step-connector {
  flex: 1;
  height: 1px;
  background: #e4e4e7;
  margin: 0 16px;
}
.step-connector.done {
  background: #16a34a;
}

/* ── CARD ── */
.card {
  background: #ffffff;
  border: 1px solid #e4e4e7;
  border-radius: 12px;
  overflow: hidden;
  -webkit-border-radius: 12px;
  -moz-border-radius: 12px;
  -ms-border-radius: 12px;
  -o-border-radius: 12px;
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid #e4e4e7;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-header-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #e4e4e7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #71717a;
  font-size: 15px;
  flex-shrink: 0;
  -webkit-border-radius: 8px;
  -moz-border-radius: 8px;
  -ms-border-radius: 8px;
  -o-border-radius: 8px;
}

.card-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #09090b;
}

.card-body {
  padding: 20px;
}

/* ── DROPSHIPPER ── */
.dropship-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  background: #ffffff;
  border: 1px solid #e4e4e7;
  border-radius: 12px;
  margin-bottom: 16px;
  cursor: pointer;
  transition: background 0.12s;
}
.dropship-row:hover {
  background: #f4f4f5;
}

.checkbox {
  width: 16px;
  height: 16px;
  border: 1.5px solid #d4d4d8;
  border-radius: 4px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.12s;
}
.checkbox.checked {
  background: #09090b;
  border-color: #09090b;
}
.checkbox.checked::after {
  content: "";
  width: 8px;
  height: 5px;
  border-left: 1.5px solid #fff;
  border-bottom: 1.5px solid #fff;
  transform: rotate(-45deg) translateY(-1px);
}

.dropship-label {
  font-size: 13px;
  font-weight: 500;
  color: #09090b;
}

.dropship-desc {
  font-size: 12px;
  color: #71717a;
  margin-left: auto;
}

/* ── ADDRESS CARD ── */
.address-box {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.address-box:hover {
  border-color: #18181b;
}

.address-radio {
  width: 16px;
  height: 16px;
  border: 1.5px solid #09090b;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.address-radio::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--checkout-theme-color);
}

.address-info {
  flex: 1;
}

.address-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.address-name {
  font-size: 13px;
  font-weight: 600;
  color: #09090b;
}

.address-phone {
  font-size: 12px;
  color: #71717a;
}

.badge-primary {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--checkout-theme-color);
  color: #ffffff;
  letter-spacing: 0.02em;
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  -ms-border-radius: 4px;
  -o-border-radius: 4px;
}

.address-full {
  font-size: 13px;
  color: #71717a;
  line-height: 1.5;
}

.address-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
  color: #09090b;
  margin-top: 8px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.add-address-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 40px;
  border: 1px dashed #d4d4d8;
  border-radius: 8px;
  background: transparent;
  font-size: 13px;
  font-weight: 500;
  color: #71717a;
  cursor: pointer;
  font-family: inherit;
  transition:
    border-color 0.12s,
    color 0.12s;
  margin-top: 12px;
}
.add-address-btn:hover {
  border-color: #18181b;
  color: #09090b;
}

/* ── SHIPPING METHOD ── */
.shipping-option {
  margin: 5px 0;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.shipping-option.selected {
  border-color: #e4e4e7;
  background: #ffffff;
}

.shipping-radio {
  width: 16px;
  height: 16px;
  border: 1.5px solid #d4d4d8;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s;
}
.shipping-option.selected .shipping-radio {
  border-color: var(--checkout-theme-color);
}
.shipping-option.selected .shipping-radio::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--checkout-theme-color);
}

.shipping-info {
  flex: 1;
}
.shipping-name {
  font-size: 13px;
  font-weight: 500;
  color: #09090b;
}
.shipping-eta {
  font-size: 12px;
  color: #71717a;
}
.shipping-price {
  font-size: 13px;
  font-weight: 600;
  color: #09090b;
}
.shipping-price.free {
  color: #16a34a;
}

.shipping-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── ORDER ITEMS ── */
.order-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid #e4e4e7;
}
.order-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.order-item:first-child {
  padding-top: 0;
}

.item-thumb {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #e4e4e7;
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a1a1aa;
  font-size: 20px;
}
.item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.item-details {
  flex: 1;
  min-width: 0;
}
.item-name {
  font-size: 13px;
  font-weight: 500;
  color: #09090b;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
  text-decoration: none;
}
.item-name-2line {
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  line-clamp: 2;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;

  line-height: 1.4;
  min-height: calc(1.4em * 2);
}

.item-meta {
  font-size: 12px;
  color: #71717a;
}

.item-price {
  font-size: 13px;
  font-weight: 600;
  color: #09090b;
  flex-shrink: 0;
}

/* ── SIDEBAR ── */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Voucher */
.voucher-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border: 1px dashed #d4d4d8;
  border-radius: 8px;
  cursor: pointer;
  transition:
    border-color 0.12s,
    background 0.12s;
  background: transparent;
  width: 100%;
  font-family: inherit;
}
.voucher-trigger:hover {
  border-color: #18181b;
  background: #71717a;
}

.voucher-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: #71717a;
  border: 1px solid #e4e4e7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #71717a;
  font-size: 14px;
  flex-shrink: 0;
}

.voucher-label {
  flex: 1;
  text-align: left;
  font-size: 13px;
  font-weight: 500;
  color: #71717a;
}

/* Summary */
.summary-rows {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

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

.summary-label {
  font-size: 13px;
  color: #71717a;
}
.summary-value {
  font-size: 13px;
  font-weight: 500;
  color: #09090b;
}
.summary-value.free {
  color: #16a34a;
  font-weight: 500;
}

.summary-divider {
  height: 1px;
  background: #e4e4e7;
  margin: 4px 0;
}

.summary-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.summary-total-label {
  font-size: 14px;
  font-weight: 600;
  color: #09090b;
}
.summary-total-value {
  font-size: 18px;
  font-weight: 700;
  color: #09090b;
  letter-spacing: -0.02em;
}

.btn-checkout {
  width: 100%;
  height: 44px;
  background: var(--checkout-theme-color);
  color: #ffffff !important;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: opacity 0.15s;
  letter-spacing: -0.01em;
}
.btn-checkout:hover {
  opacity: 0.85;
}
.btn-checkout:active {
  opacity: 0.75;
}

.checkout-note {
  text-align: center;
  font-size: 11px;
  color: #a1a1aa;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

/* ── SEPARATOR ── */
.sep {
  height: 1px;
  background: #e4e4e7;
}

/* input-like row */
.input-row {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.input-field {
  flex: 1;
  height: 36px;
  border: 1px solid #d4d4d8;
  border-radius: 8px;
  padding: 0 12px;
  font-size: 13px;
  font-family: inherit;
  color: #09090b;
  background: #ffffff;
  outline: none;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
.input-field:focus {
  border-color: #18181b;
  box-shadow: 0 0 0 3px rgba(24, 24, 27, 0.06);
}
.input-field::placeholder {
  color: #a1a1aa;
}

.btn-sm {
  height: 36px;
  padding: 0 14px;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  background: #ffffff;
  color: #09090b;
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s;
}
.btn-sm:hover {
  background: #f4f4f5;
  color: #09090b;
}

/* items count tag */
.items-count {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 500;
  color: #71717a;
  background: #71717a;
  border: 1px solid #e4e4e7;
  padding: 2px 8px;
  border-radius: 20px;
  margin-left: auto;
}

/* ── TOOLTIP HOVER ── */
.tooltip-wrap {
  position: relative;
  display: inline-flex;
}
.tooltip-wrap:hover .tooltip-box {
  opacity: 1;
  pointer-events: auto;
}
.tooltip-box {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: #09090b;
  color: #ffffff;
  font-size: 11px;
  white-space: nowrap;
  padding: 4px 8px;
  border-radius: 5px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}

.ui-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.ui-badge-dark {
  background: var(--ui-accent);
  color: var(--ui-accent-fg);
}

.ui-badge-success {
  background: var(--ui-success-bg);
  color: var(--ui-success);
  border: 1px solid var(--ui-success-border);
}

.ui-badge-danger {
  background: var(--ui-danger-bg);
  color: var(--ui-danger);
  border: 1px solid var(--ui-danger-border);
}

.ui-badge-warning {
  background: var(--ui-warning-bg);
  color: var(--ui-warning);
  border: 1px solid var(--ui-warning-border);
}

.ui-badge-info {
  background: var(--ui-info-bg);
  color: var(--ui-info);
  border: 1px solid var(--ui-info-border);
}

.ui-badge-neutral {
  background: var(--ui-bg-muted);
  color: var(--ui-text-muted);
  border: 1px solid var(--ui-border);
}

.ui-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: var(--ui-sp-2);
  padding: var(--ui-sp-8) var(--ui-sp-5);
}

.ui-empty-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--ui-bg-muted);
  border: 1px solid var(--ui-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ui-text-subtle);
  margin-bottom: var(--ui-sp-2);
}

.ui-empty-icon svg {
  width: 26px;
  height: 26px;
}

.ui-empty-title {
  font-size: var(--ui-fs-md);
  font-weight: 600;
  color: var(--ui-text);
  margin: 0;
}

.ui-empty-desc {
  font-size: var(--ui-fs-base);
  color: var(--ui-text-muted);
  margin: 0;
  max-width: 320px;
}
.ui-voucher-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: var(--ui-sp-4);
  border: 1.5px solid var(--ui-border);
  border-radius: var(--ui-radius);
  background: var(--ui-bg);
  cursor: pointer;
  transition:
    border-color var(--ui-transition),
    background var(--ui-transition-fast);
  width: 100%;
  text-align: left;
}

.ui-voucher-card:hover {
  border-color: var(--ui-ring);
  background: var(--ui-bg-muted);
}

.ui-voucher-card.selected {
  border-color: var(--ui-ring);
  background: var(--ui-bg-muted);
}

.ui-voucher-card.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}

.ui-voucher-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: var(--ui-radius);
  background: var(--ui-bg-muted);
  border: 1px solid var(--ui-border);
  display: flex;
  align-items: center;
  justify-content: center;
}

.ui-voucher-icon img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.ui-voucher-info {
  flex: 1;
  min-width: 0;
}

.ui-voucher-header {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.ui-voucher-label {
  font-size: var(--ui-fs-base);
  font-weight: 600;
  color: var(--ui-text);
  margin: 0;
  line-height: 1.3;
}

.ui-voucher-tnc {
  font-size: 12px;
  color: var(--ui-text-muted);
  margin: 0 0 4px;
  line-height: 1.45;
}

.ui-voucher-expiry {
  font-size: var(--ui-fs-xs);
  color: var(--ui-text-subtle);
  margin: 0;
}

.ui-voucher-card .ui-checkbox {
  flex-shrink: 0;
  pointer-events: none;
}

.ui-voucher-section-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: var(--ui-sp-4) 0 var(--ui-sp-2);
}

.ui-voucher-section-divider::before,
.ui-voucher-section-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--ui-border);
}

.ui-voucher-section-label {
  font-size: var(--ui-fs-xs);
  font-weight: 600;
  color: var(--ui-text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.ui-stack {
  display: flex;
  flex-direction: column;
  gap: var(--ui-sp-4);
}

.ui-stack-sm {
  gap: var(--ui-sp-2);
}

.ui-stack-lg {
  gap: 24px;
}

.progress-wrap {
  position: fixed;
  bottom: 90px;
  right: 40px;
  height: 40px;
  width: 40px;
  cursor: pointer;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border-radius: 999px;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  -webkit-transform: translateY(20px);
  -ms-transform: translateY(20px);
  transform: translateY(20px);
  -webkit-transition: all 400ms linear;
  -o-transition: all 400ms linear;
  transition: all 400ms linear;
  background: var(--white);
  border: 1.2px solid rgba(134, 134, 134, 0.12);
}

.progress-wrap::after {
  position: absolute;
  content: " ";
  text-align: center;
  line-height: 40px;
  font-size: 8px;
  color: #000000;
  height: 40px;
  width: 40px;
  cursor: pointer;
  z-index: 1;
  -webkit-transition: all 400ms linear;
  -o-transition: all 400ms linear;
  transition: all 400ms linear;
}

.progress-wrap.active-progress {
  opacity: 1;
  visibility: visible;
  -webkit-transform: translateY(0);
  -ms-transform: translateY(0);
  transform: translateY(0);
}

.progress-wrap svg path {
  fill: none;
}

.progress-wrap svg.progress-circle path {
  box-sizing: border-box;
  stroke: #000000;
  stroke-width: 1.2;
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
  transition-duration: 0.4s;
  transition-timing-function: linear;
}

.ui-payment-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--ui-sp-4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.ui-payment-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.ui-payment-overlay-card {
  background: var(--ui-bg);
  border: 1px solid var(--ui-border);
  border-radius: var(--ui-radius-lg);
  box-shadow: var(--ui-shadow-lg);
  padding: 48px 40px 40px;
  text-align: center;
  max-width: 360px;
  width: 100%;
  animation: ui-modal-in 0.25s ease;
  -webkit-border-radius: var(--ui-radius-lg);
  -moz-border-radius: var(--ui-radius-lg);
  -ms-border-radius: var(--ui-radius-lg);
  -o-border-radius: var(--ui-radius-lg);
}

@keyframes ui-check-pop {
  0% {
    transform: scale(0.4);
    opacity: 0;
  }
  70% {
    transform: scale(1.1);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.ui-payment-check-ring {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--ui-success-bg);
  border: 2px solid var(--ui-success-border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--ui-sp-5);
  animation: ui-check-pop 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

.ui-payment-check-ring svg {
  width: 36px;
  height: 36px;
  color: var(--ui-success);
}

.ui-payment-overlay-title {
  font-size: var(--ui-fs-xl);
  font-weight: 700;
  color: var(--ui-text);
  margin: 0 0 var(--ui-sp-2);
  letter-spacing: -0.02em;
}

.ui-payment-overlay-sub {
  font-size: var(--ui-fs-base);
  color: var(--ui-text-muted);
  margin: 0 0 24px;
  line-height: 1.55;
}

.ui-payment-countdown {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--ui-bg-muted);
  border: 2px solid var(--ui-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  color: var(--ui-text);
  margin: 0 auto 12px;
  transition: border-color 0.3s ease;
}

.ui-payment-countdown.ticking {
  border-color: var(--ui-success);
  color: var(--ui-success);
}

.ui-payment-countdown-label {
  font-size: 12px;
  color: var(--ui-text-subtle);
  margin: 0;
}
