.store-site .commerce-page {
  padding-block: 34px 74px;
  color: var(--store-ink, #1c2130);
}

.commerce-steps {
  display: flex;
  gap: 26px;
  padding: 0 0 20px;
  margin: 0 0 28px;
  border-bottom: 1px solid var(--store-border, #dddfe6);
  list-style: none;
  counter-reset: order-step;
}

.commerce-steps li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--store-muted, #555e6e);
  font-size: 14px;
}

.commerce-steps li::before {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--store-border, #dddfe6);
  counter-increment: order-step;
  content: counter(order-step);
}

.commerce-steps li[aria-current] {
  color: var(--store-ink, #1c2130);
  font-weight: 700;
}

.commerce-steps li[aria-current]::before {
  border-color: var(--store-blue, #3444aa);
  background: var(--store-blue, #3444aa);
  color: white;
}

.commerce-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(270px, 1fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
}

.commerce-main { min-width: 0; }
.commerce-panel + .commerce-panel { margin-top: 32px; }

.store-site .commerce-panel h2 {
  margin: 0 0 12px;
  font-size: 23px;
  line-height: 1.35;
}

.store-site .commerce-page p {
  margin: 0;
  color: var(--store-muted, #555e6e);
  font-size: 14px;
  line-height: 1.65;
}

.commerce-summary {
  min-width: 0;
  padding: 23px;
  border: 1px solid var(--store-border, #dddfe6);
  background: var(--store-blue-soft, #ecedf7);
}

.commerce-product {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  align-items: start;
  gap: 13px;
}

.commerce-product-media {
  display: grid;
  aspect-ratio: 4 / 3;
  place-items: center;
  background: var(--store-media, #edecf3);
  overflow: hidden;
}

.commerce-product-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.store-site .commerce-product h2 {
  margin: 0 0 6px;
  font-size: 17px;
  line-height: 1.45;
}

.commerce-product a { color: inherit; }
.commerce-amounts { margin: 18px 0 12px; }

.commerce-amounts > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 7px;
  font-size: 14px;
}

.commerce-amounts dt, .commerce-contact dt {
  color: var(--store-muted, #555e6e);
  font-weight: 400;
}

.commerce-amounts dd { margin: 0; }

.commerce-amounts .commerce-total {
  align-items: baseline;
  border-top: 1px solid var(--store-border, #dddfe6);
  margin-top: 14px;
  padding-top: 10px;
}

.store-site .commerce-total .store-price {
  color: var(--store-blue, #3444aa);
  font-size: 22px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.store-site .commerce-return {
  display: inline-block;
  margin-top: 12px;
  color: var(--store-blue, #3444aa);
  font-size: 14px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.commerce-form { margin-top: 20px; }
.commerce-field { margin-bottom: 16px; }

.commerce-field label {
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
  font-size: 14px;
}

.commerce-field label span {
  margin-left: 5px;
  color: var(--store-muted, #555e6e);
  font-size: 12px;
  font-weight: 400;
}

.store-site .commerce-field .form-control {
  display: block;
  width: 100%;
  min-height: 43px;
  padding: 8px 11px;
  border: 1px solid var(--store-border, #dddfe6);
  border-radius: 3px;
  font: inherit;
}

.commerce-field textarea { resize: vertical; }
.commerce-field :focus-visible { outline: 2px solid var(--store-blue, #3444aa); }
.commerce-delivery { padding-left: 1.2em; }
.commerce-delivery li { margin-bottom: 7px; list-style: disc; }

.store-site .commerce-action {
  width: fit-content;
  min-height: 42px;
  margin-top: 12px;
  padding: 8px 15px;
  white-space: normal;
}

.store-site .commerce-action:disabled {
  color: var(--store-muted, #555e6e);
  background: #edf0f4;
  border: 1px solid var(--store-border, #dddfe6);
  opacity: 1;
  cursor: not-allowed;
}

.commerce-payment-methods {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.commerce-channel {
  padding: 13px;
  border: 1px solid var(--store-border, #dddfe6);
  background: white;
}

.commerce-channel-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.commerce-channel-heading span {
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border-radius: 5px;
  background: #1677ff;
  color: white;
  font-size: 13px;
}

.commerce-channel-wechat .commerce-channel-heading span { background: #087b46; }
.store-site .commerce-channel h3 { margin: 0; font-size: 16px; }

.commerce-payment-qr {
  display: block;
  width: min(184px, 100%);
  height: auto;
  margin-top: 12px;
}

.commerce-panel-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.commerce-contact { margin: 14px 0 0; }

.commerce-contact > div {
  display: grid;
  grid-template-columns: minmax(90px, 1fr) minmax(0, 3fr);
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--store-border, #dddfe6);
  font-size: 14px;
}

.commerce-contact dd { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }

@media (max-width: 780px) {
  .store-site .commerce-page { padding-block: 20px 46px; }
  .commerce-steps { margin-bottom: 18px; }
  .commerce-layout { display: flex; flex-direction: column; align-items: stretch; gap: 22px; }
  .commerce-summary { order: -1; padding: 16px; }
  .commerce-product { grid-template-columns: 70px minmax(0, 1fr); }
}

@media (max-width: 345px) {
  .commerce-payment-methods { grid-template-columns: minmax(0, 1fr); }
}
