:root {
  /* Color — surface */
  --ui-bg: #ffffff;
  --ui-bg-muted: #f9f9f9;
  --ui-bg-hover: #f4f4f5;
  --ui-backdrop: rgba(0, 0, 0, 0.5);

  /* Color — border */
  --ui-border: #e4e4e7;
  --ui-border-input: #d4d4d8;
  --ui-ring: #18181b;

  /* Color — text */
  --ui-text: #09090b;
  --ui-text-muted: #71717a;
  --ui-text-subtle: #a1a1aa;
  --ui-text-invert: #ffffff;

  /* Color — accent (dark fill, like btn-checkout) */
  --ui-accent: #18181b;
  --ui-accent-fg: #ffffff;

  /* Color — semantic */
  --ui-success: #16a34a;
  --ui-success-bg: #f0fdf4;
  --ui-success-border: #bbf7d0;
  --ui-danger: #dc2626;
  --ui-danger-bg: #fef2f2;
  --ui-danger-border: #fecaca;
  --ui-warning: #d97706;
  --ui-warning-bg: #fffbeb;
  --ui-warning-border: #fde68a;
  --ui-info: #2563eb;
  --ui-info-bg: #eff6ff;
  --ui-info-border: #bfdbfe;

  /* Radius */
  --ui-radius-sm: 6px;
  --ui-radius: 8px;
  --ui-radius-lg: 12px;
  --ui-radius-full: 9999px;

  /* Shadow */
  --ui-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --ui-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --ui-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.12);

  /* Focus ring */
  --ui-focus-shadow: 0 0 0 3px rgba(24, 24, 27, 0.06);

  /* Typography */
  --ui-font: "Albert Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --ui-fs-xs: 11px;
  --ui-fs-sm: 12px;
  --ui-fs-base: 13px;
  --ui-fs-md: 14px;
  --ui-fs-lg: 16px;
  --ui-fs-xl: 18px;
  --ui-fs-2xl: 22px;
  --ui-fs-3xl: 28px;

  /* Spacing scale */
  --ui-sp-1: 4px;
  --ui-sp-2: 8px;
  --ui-sp-3: 12px;
  --ui-sp-4: 16px;
  --ui-sp-5: 20px;
  --ui-sp-6: 24px;
  --ui-sp-8: 32px;

  /* Transition */
  --ui-transition: 0.15s ease;
  --ui-transition-fast: 0.12s ease;

  /* Z-index layers */
  --ui-z-navbar: 100;
  --ui-z-dropdown: 200;
  --ui-z-modal: 1050;
  --ui-z-toast: 1100;
  --ui-z-tooltip: 1200;
}

/* ── 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;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  flex-shrink: 0;
}

.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: #09090b;
  border-color: #09090b;
  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;
}
.step.active .step-label {
  color: #09090b;
  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: #09090b;
}

.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: #09090b;
  color: #ffffff;
  letter-spacing: 0.02em;
}

.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: #18181b;
  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: #09090b;
}
.shipping-option.selected .shipping-radio::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #09090b;
}

.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;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.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: #09090b;
  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: var(--ui-sp-3);
  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: var(--ui-fs-sm);
  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: var(--ui-sp-3);
  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: var(--ui-sp-6);
}
