:root {
  --ts-bg: #f5f5f5;
  --ts-panel: #ffffff;
  --ts-text: #222222;
  --ts-soft-text: #6f737a;
  --ts-muted: #9a9a9a;
  --ts-line: #f0f0f0;
  --ts-soft: #f7f7f7;
  --ts-primary: #e60012;
  --ts-primary-dark: #c90010;
  --ts-radius: 14px;
  --ts-radius-sm: 8px;
  --ts-font: "Helvetica Neue", Helvetica, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  --ts-real-vh: 100vh;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--ts-bg);
  color: var(--ts-text);
  font: 14px/1.55 var(--ts-font);
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; }
button, a, [role="button"] { touch-action: manipulation; }
button, a, input, select, textarea { -webkit-tap-highlight-color: rgba(230, 0, 18, .12); }
@media (max-width: 768px) { input, select, textarea { font-size: 16px !important; } }

.tomshop-page { width: 100%; }
.tomshop-shell,
.tomshop-shell-form {
  width: min(620px, calc(100% - 24px));
  margin: 0 auto;
  padding: 14px 0 28px;
}

.ts-card,
.ts-order-card,
.ts-success-order-card,
.ts-form-card {
  background: transparent;
  border: 0;
  border-radius: 0;
  overflow: visible;
}

.ts-card-head,
.ts-success-hero,
.ts-product-summary,
.ts-form-section,
.ts-order-head,
.ts-goods-section,
.ts-info-section,
.ts-order-total,
.ts-actions,
.ts-query-form,
.ts-empty {
  background: var(--ts-panel);
}

.ts-card-head {
  padding: 20px 18px 14px;
  border-radius: var(--ts-radius) var(--ts-radius) 0 0;
}
.ts-card-head h1 {
  margin: 0 0 4px;
  font-size: 21px;
  line-height: 1.28;
  font-weight: 500;
}
.ts-card-head p { margin: 0; color: var(--ts-soft-text); }
.ts-link { color: #333; display: inline-flex; margin-top: 10px; }

.ts-query-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
  padding: 14px 18px 18px;
  border-radius: 0 0 var(--ts-radius) var(--ts-radius);
}
.ts-query-input { display: grid; gap: 7px; color: #555; }
.ts-query-input span,
.ts-field > span { color: #555; }
.ts-query-input input,
.ts-field input,
.ts-field select {
  width: 100%;
  height: 40px;
  border: 0;
  border-radius: var(--ts-radius-sm);
  background: #f3f3f3;
  padding: 0 12px;
  color: #222;
  outline: none;
}
.ts-query-input input:focus,
.ts-field input:focus,
.ts-field select:focus { background: #eeeeee; }

.ts-btn {
  appearance: none;
  border: 0;
  border-radius: var(--ts-radius-sm);
  height: 40px;
  min-width: 104px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: #f3f3f3;
  color: #222;
  white-space: nowrap;
  transition: background .15s ease, opacity .15s ease;
}
.ts-btn:hover { background: #e8e8e8; }
.ts-btn-primary { background: var(--ts-primary); color: #fff; }
.ts-btn-primary:hover { background: var(--ts-primary-dark); }
.ts-btn-ghost { background: #f3f3f3; color: #222; }
.ts-btn-small { height: 34px; min-width: 84px; padding: 0 13px; font-size: 13px; }
.ts-btn[disabled], .ts-btn.is-loading { opacity: .65; cursor: not-allowed; }

.ts-result-panel { margin-top: 12px; }
.ts-order-list { display: grid; gap: 12px; }
.ts-order-card,
.ts-success-order-card { background: var(--ts-panel); border-radius: var(--ts-radius); overflow: hidden; }

.ts-order-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 17px 18px 12px;
}
.ts-order-head-main { min-width: 0; }
.ts-order-number {
  display: flex;
  gap: 7px;
  align-items: baseline;
  margin: 0 0 8px;
  color: #777;
}
.ts-order-number strong {
  color: #222;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 500;
  word-break: break-all;
}
.ts-order-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: #777; }
.ts-order-meta span { display: inline-flex; gap: 7px; align-items: baseline; }
.ts-order-meta em { color: #888; font-style: normal; }
.ts-order-meta strong { color: #222; font-weight: 400; }
.ts-order-status { flex: 0 0 auto; }
.ts-status-badge {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 11px;
  border-radius: 999px;
  background: #f2f2f2;
  color: #555;
  font-size: 13px;
}
.ts-status-pending { background: #fff2df; color: #8a5700; }
.ts-status-confirmed,
.ts-status-shipped { background: #eef4f8; color: #426174; }
.ts-status-finished { background: #eef7ee; color: #477248; }
.ts-status-cancelled { background: #f2f2f2; color: #777; }
.ts-status-invalid { background: #fff0f0; color: #b73a3a; }
.ts-source-order { margin: 0; padding: 0 18px 12px; color: var(--ts-muted); }

.ts-goods-section,
.ts-info-section,
.ts-form-section {
  padding: 16px 18px;
}
.ts-goods-section h2,
.ts-info-section h2,
.ts-form-section h2 {
  margin: 0 0 12px;
  font-size: 15px;
  line-height: 1.35;
  font-weight: 500;
  color: #222;
}
.ts-goods-list { display: grid; gap: 0; }
.ts-goods-item {
  display: grid;
  grid-template-columns: 82px 1fr auto;
  gap: 13px;
  align-items: center;
  min-width: 0;
  padding: 8px 0;
}
.ts-goods-thumb,
.ts-product-thumb {
  width: 82px;
  height: 82px;
  border-radius: 10px;
  background: #f6f6f6;
  overflow: hidden;
}
.ts-goods-thumb img,
.ts-product-thumb img { width: 100%; height: 100%; object-fit: contain; }
.ts-goods-main { min-width: 0; }
.ts-goods-title,
.ts-product-title {
  display: -webkit-box;
  overflow: hidden;
  color: #222;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ts-goods-model,
.ts-product-model { margin-top: 5px; color: #777; }
.ts-goods-sub { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 5px; color: #777; }
.ts-goods-amount { min-width: 70px; text-align: right; color: #777; }
.ts-goods-amount span { display: block; margin-bottom: 3px; color: #888; }
.ts-goods-amount strong { color: #222; font-size: 17px; font-weight: 500; }

.ts-order-total {
  display: flex;
  justify-content: flex-end;
  align-items: baseline;
  gap: 18px;
  padding: 13px 18px 16px;
  color: #666;
}
.ts-order-total strong { color: #222; font-size: 18px; font-weight: 500; }

.ts-info-section { padding-top: 14px; padding-bottom: 14px; }
.ts-info-grid,
.ts-logistics-fields { display: grid; grid-template-columns: 1fr; gap: 9px; }
.ts-info-grid > div,
.ts-logistics-fields > div {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: baseline;
  min-width: 0;
}
.ts-info-grid span,
.ts-logistics-fields span { color: #8a8a8a; }
.ts-info-grid strong,
.ts-logistics-fields strong {
  color: #222;
  font-weight: 400;
  min-width: 0;
  word-break: break-word;
}
.ts-logistics-box { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; }
.ts-muted { margin: 0; color: #777; }
.ts-empty { padding: 28px 18px; border-radius: var(--ts-radius); text-align: center; color: #777; }
.ts-empty strong { display: block; margin-bottom: 5px; color: #222; font-size: 15px; font-weight: 500; }
.ts-empty p { margin: 0; }
.ts-empty-left { text-align: left; }

.ts-success-card { background: transparent; }
.ts-success-hero {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 18px;
  border-radius: var(--ts-radius);
  margin-bottom: 12px;
}
.ts-success-mark {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f3f3f3;
  color: #222;
  font-weight: 500;
}
.ts-success-hero h1 { margin: 0 0 2px; font-size: 19px; line-height: 1.25; font-weight: 500; }
.ts-success-hero p { margin: 0; color: #777; }

.ts-actions { display: flex; flex-wrap: wrap; gap: 10px; padding: 12px 0 0; background: transparent; }
.ts-result-actions { justify-content: flex-end; }

.ts-form-card { background: transparent; }
.ts-product-summary {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 13px;
  align-items: center;
  padding: 16px 18px;
}
.ts-product-summary,
.ts-form-section,
.ts-card-head,
.ts-query-form {
  background: #fff;
}
.ts-product-summary { margin-top: 12px; border-radius: var(--ts-radius); }
.ts-product-thumb { width: 86px; height: 86px; }
.ts-product-info { min-width: 0; }
.ts-product-title { font-size: 16px; }
.ts-product-price { margin-top: 7px; color: #222; font-size: 18px; font-weight: 500; }
.ts-form { padding: 0; }
.ts-form-section { margin-top: 12px; border-radius: var(--ts-radius); }
.ts-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px 14px; }
.ts-field { display: grid; gap: 7px; min-width: 0; }
.ts-region-field { margin-top: 13px; }
.ts-region-selects { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ts-pay-option {
  height: 40px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  background: #f3f3f3;
  border-radius: var(--ts-radius-sm);
}
.ts-pay-option input { width: 15px; height: 15px; margin: 0; }
.ts-pay-option strong { font-weight: 400; }

.ts-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 9999;
  transform: translateX(-50%);
  min-width: 180px;
  max-width: calc(100% - 40px);
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(34,34,34,.92);
  color: #fff;
  text-align: center;
}
.ts-toast-error { background: rgba(190, 0, 18, .94); }

@media (min-width: 760px) {
  .tomshop-shell,
  .tomshop-shell-form { padding-top: 22px; padding-bottom: 40px; }
  .ts-query-card { background: transparent; }
  .ts-card-head,
  .ts-query-form { border-radius: var(--ts-radius); }
  .ts-query-form { margin-top: 10px; }
  .ts-order-list { margin-top: 14px; }
  .ts-info-grid { grid-template-columns: 1fr 1fr; }
  .ts-info-wide { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .tomshop-shell,
  .tomshop-shell-form { width: 100%; padding: 0 0 18px; }
  .ts-card-head { border-radius: 0; padding: 18px 16px 12px; }
  .ts-card-head h1 { font-size: 20px; }
  .ts-query-form { border-radius: 0; padding: 12px 16px 16px; }
  .ts-query-form .ts-btn { min-width: 88px; padding: 0 12px; }
  .ts-result-panel { margin-top: 10px; }
  .ts-order-list { padding: 0 10px; gap: 10px; }
  .ts-order-card,
  .ts-success-order-card,
  .ts-success-hero,
  .ts-product-summary,
  .ts-form-section { border-radius: 12px; }
  .ts-order-head { padding: 16px 14px 10px; }
  .ts-order-number strong { font-size: 16px; }
  .ts-order-meta { display: grid; gap: 4px; }
  .ts-goods-section,
  .ts-info-section { padding: 14px; }
  .ts-goods-item { grid-template-columns: 72px 1fr auto; gap: 10px; align-items: start; }
  .ts-goods-thumb { width: 72px; height: 72px; border-radius: 9px; }
  .ts-goods-sub { gap: 10px; font-size: 13px; }
  .ts-goods-amount { min-width: 58px; }
  .ts-goods-amount span { font-size: 12px; }
  .ts-goods-amount strong { font-size: 15px; }
  .ts-order-total { justify-content: flex-end; padding: 12px 14px 15px; }
  .ts-order-total strong { font-size: 17px; }
  .ts-info-grid > div,
  .ts-logistics-fields > div { grid-template-columns: 70px 1fr; gap: 10px; }
  .ts-logistics-box { grid-template-columns: 1fr; }
  .ts-logistics-box .ts-btn { justify-self: start; }
  .ts-success-hero { margin: 10px; padding: 16px 14px; }
  .ts-actions { padding: 10px; }
  .ts-actions .ts-btn { flex: 1 1 auto; }
  .ts-product-summary { margin: 10px 10px 0; grid-template-columns: 76px 1fr; gap: 11px; padding: 14px; }
  .ts-product-thumb { width: 76px; height: 76px; }
  .ts-product-title { font-size: 15px; }
  .ts-product-price { font-size: 17px; }
  .ts-form-section { margin: 10px 10px 0; padding: 14px; }
  .ts-form-grid { grid-template-columns: 1fr; gap: 12px; }
  .ts-region-selects { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 6px; }
  .ts-region-selects select { padding-left: 7px; padding-right: 2px; font-size: 13px; }
}

@media (max-width: 380px) {
  .ts-goods-item { grid-template-columns: 64px 1fr; }
  .ts-goods-thumb { width: 64px; height: 64px; }
  .ts-goods-amount { grid-column: 2; min-width: 0; text-align: left; margin-top: 3px; }
  .ts-goods-amount span,
  .ts-goods-amount strong { display: inline; }
  .ts-goods-amount span { margin-right: 6px; }
}

/* 下单页复刻 */
body.ts-buy-body {
  background: #f9fafb;
  color: #1f2933;
  font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}
.ts-buy-page,
.ts-buy-page button,
.ts-buy-page input,
.ts-buy-page select,
.ts-buy-page textarea {
  font: inherit;
}
.ts-buy-page {
  min-height: 100vh;
  min-height: var(--ts-real-vh, 100vh);
}
.ts-buy-layout {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 24px 16px;
  display: flex;
  align-items: flex-start;
  gap: 24px;
}
.ts-buy-main {
  flex: 1 1 auto;
  width: 66.666%;
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}
.ts-buy-sidebar {
  flex: 0 0 calc(33.333% - 8px);
  min-width: 300px;
}
.ts-buy-card,
.ts-buy-summary-card {
  background: #fff;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0,0,0,.06);
  padding: 16px;
}
.ts-buy-summary-card {
  position: sticky;
  top: 16px;
}
.ts-buy-product {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.ts-buy-thumb {
  width: 80px;
  height: 80px;
  flex: 0 0 80px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 4px;
  background: #f7f7f7;
}
.ts-buy-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ts-buy-product-content {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.ts-buy-product-info {
  min-width: 0;
  padding-top: 3px;
}
.ts-buy-title {
  display: -webkit-box;
  overflow: hidden;
  color: #1f2933;
  font-size: 14px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ts-buy-title:hover {
  color: #f02e2e;
}
.ts-buy-model {
  margin: 4px 0 0;
  color: #6b7280;
  font-size: 12px;
  line-height: 1.4;
}
.ts-buy-product-side {
  flex: 0 0 auto;
  text-align: right;
}
.ts-buy-unit-price {
  margin: 0;
  color: #f02e2e;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 700;
}
.ts-buy-qty {
  display: inline-flex;
  align-items: stretch;
  justify-content: flex-end;
  margin-top: 16px;
  height: 24px;
}
.ts-buy-qty-btn,
.ts-buy-qty input {
  height: 24px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #6b7280;
  text-align: center;
  outline: none;
}
.ts-buy-qty-btn {
  width: 24px;
  padding: 0;
  cursor: pointer;
  line-height: 22px;
}
.ts-buy-qty-btn:hover {
  background: #f5f5f5;
}
.ts-buy-qty-btn:first-child {
  border-radius: 4px 0 0 4px;
}
.ts-buy-qty-btn:last-child {
  border-radius: 0 4px 4px 0;
}
.ts-buy-qty input {
  width: 40px;
  border-left: 0;
  border-right: 0;
  color: #1f2933;
  font-size: 14px;
  -moz-appearance: textfield;
}
.ts-buy-qty input::-webkit-outer-spin-button,
.ts-buy-qty input::-webkit-inner-spin-button {
  margin: 0;
  -webkit-appearance: none;
}
.ts-buy-card.ts-buy-address-card > h2 {
  margin: 0 0 16px;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 400;
  color: #1f2933;
}
/* TomShop v1.22：粘贴区使用“输入区域 + 独立按钮行”的复合文本框，文字不会再从按钮旁穿过。 */
.ts-buy-address-autofill {
  margin: 0 0 16px;
  padding: 0;
  border: 0;
  background: transparent;
}
.ts-buy-address-paste-box {
  display: block;
}
.ts-buy-paste-field {
  display: block;
  margin: 0;
  overflow: hidden;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  background: #fff;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.ts-buy-paste-field:focus-within {
  border-color: #3b82f6;
  box-shadow: 0 0 0 1px #3b82f6;
}
.ts-buy-field.ts-buy-paste-field textarea {
  display: block;
  width: 100%;
  min-height: 122px;
  padding: 12px;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  resize: none;
}
.ts-buy-field.ts-buy-paste-field textarea:focus {
  border: 0;
  box-shadow: none;
}
.ts-buy-paste-action-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 44px;
  padding: 6px 10px 10px;
}
.ts-buy-address-actions {
  margin-top: 6px;
}
body[data-page="tomshop-buy"] .ts-buy-paste-action-row > .ts-buy-address-parse {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 96px;
  height: 32px;
  margin: 0;
  padding: 0 12px;
  border: 0;
  border-radius: 4px;
  box-shadow: none;
  background-color: #ff7a00;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  line-height: 32px;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .15s ease;
}
body[data-page="tomshop-buy"] .ts-buy-paste-action-row > .ts-buy-address-parse:hover {
  background-color: #e96f00;
}
.ts-buy-address-actions p {
  display: none;
  margin: 0;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.5;
}
.ts-buy-address-actions p.is-visible {
  display: block;
}
.ts-buy-address-actions p.is-error {
  color: #f02e2e;
}
.ts-buy-address-actions p.is-ok {
  color: #14805e;
}
.ts-buy-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.ts-buy-field {
  display: block;
  min-width: 0;
}
.ts-buy-field > span {
  display: block;
  margin-bottom: 4px;
  color: #374151;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 500;
}
.ts-buy-field input,
.ts-buy-field select,
.ts-buy-field textarea {
  width: 100%;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  background: #fff;
  color: #1f2933;
  font-size: 14px;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.ts-buy-field input,
.ts-buy-field select {
  height: 40px;
  padding: 0 12px;
}
.ts-buy-field textarea {
  min-height: 58px;
  resize: vertical;
  padding: 8px 12px;
}
.ts-buy-field input::placeholder,
.ts-buy-field textarea::placeholder {
  color: #999;
  font-size: 14px;
}
.ts-buy-field input:focus,
.ts-buy-field select:focus,
.ts-buy-field textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 1px #3b82f6;
}
.ts-buy-region-field,
.ts-buy-detail-field {
  margin-bottom: 16px;
}
.ts-buy-region-selects {
  display: flex;
  gap: 8px;
}
.ts-buy-region-selects select {
  flex: 1 1 0;
  min-width: 0;
}
.ts-buy-region-selects.is-tomshop-city-picker {
  display: block;
  position: relative;
}

/* TomShop v0.444：抽离 orderman/Public/Alizi/alizi-order.css + city-picker.js 的 city-picker 样式骨架。
   只抽外观和 DOM 状态 class；地区数据继续使用 TomShopRegionData，不引入 seajs/jquery/orderman 地区数据。 */
.city-picker-input {
  opacity: 0 !important;
  top: -9999px;
  left: -9999px;
  position: absolute;
}
.city-picker-span {
  position: relative;
  display: block;
  outline: 0;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  border: 1px solid #ccc;
  background-color: #fff;
  color: #ccc;
  cursor: pointer;
  border-radius: 2px;
  min-height: 44px;
  line-height: 42px;
  padding: 0 32px 0 12px;
  box-sizing: border-box;
  width: 100%;
  font-size: 16px;
}
.city-picker-span > .placeholder { color: #aaa; }
.city-picker-span > .arrow {
  position: absolute;
  top: 50%;
  right: 8px;
  width: 10px;
  margin-top: -3px;
  height: 5px;
  background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAoCAYAAADpE0oSAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAABx0RVh0U29mdHdhcmUAQWRvYmUgRmlyZXdvcmtzIENTNui8sowAAAAWdEVYdENyZWF0aW9uIFRpbWUAMDgvMDcvMTMw9/FFAAAAkklEQVRYhe3W0QqAIAwF0Gv0rX7Ufna9aNQwcauQ4u4pcHSYwW5JVTGjlikqYcKEfwGvjt7TihMRAEDO2falkZeFJq6offaUGz5OWqeN4C64db1RfBjufNMQnhiLhAkT/hw8HIsiokB7ZZZzlPNnY7G3j3t7/DZ8hUdQwBcSe6Od2qDv/YG08thbjEXChAl/D94AcPM/RZiYNrgAAAAASUVORK5CYII=) -10px -25px no-repeat;
}
.city-picker-span.focus,
.city-picker-span.open { border-bottom-color: #46A4FF; }
.city-picker-span.open > .arrow { background-position: -10px -10px; }
.city-picker-span > .title {
  color: #333;
}
.city-picker-span > .title > span {
  color: #333;
  padding: 5px;
  border-radius: 3px;
}
.city-picker-span > .title > span.select-item {
  cursor: pointer;
}
.city-picker-span > .title > span:hover { background-color: #f1f8ff; }
.city-picker-dropdown {
  position: absolute;
  width: 100% !important;
  left: -9999px;
  top: -9999px;
  outline: 0;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  z-index: 999999;
  display: none;
  min-width: 330px;
  margin-bottom: 20px;
}
.city-picker-dropdown.is-open {
  display: block;
  left: 0;
  top: 100%;
}
.city-select-wrap { box-shadow: 0 1px 5px rgba(0, 0, 0, .5); }
.city-select-tab {
  border-bottom: 1px solid #ccc;
  background: #f0f0f0;
  font-size: 13px;
  white-space: nowrap;
}
.city-select-tab > a {
  display: inline-block;
  padding: 8px 22px;
  border-left: 1px solid #ccc;
  border-bottom: 1px solid transparent;
  color: #4D4D4D;
  text-align: center;
  outline: 0;
  text-decoration: none;
  cursor: pointer;
  font-size: 14px;
  margin-bottom: -1px;
}
.city-select-tab > a.active {
  background: #fff;
  border-bottom: 1px solid #fff;
  color: #46A4FF;
}
.city-select-tab > a:first-child { border-left: none; }
.city-select-tab > a:last-child.active { border-right: 1px solid #ccc; }
.city-select-content {
  width: 100%;
  min-height: 10px;
  background-color: #fff;
  padding: 10px 15px;
  box-sizing: border-box;
}
.city-select { font-size: 13px; }
.city-select dl {
  line-height: 2;
  clear: both;
  padding: 3px 0;
  margin: 0;
}
.city-select dt {
  position: absolute;
  width: 2.5em;
  font-weight: 500;
  text-align: right;
  line-height: 2;
}
.city-select dd {
  margin-left: 0;
  line-height: 2;
}
.city-select.province dd { margin-left: 3em; }
.city-select a {
  display: inline-block;
  padding: 0 10px;
  outline: 0;
  text-decoration: none;
  white-space: nowrap;
  margin-right: 2px;
  color: #333;
  cursor: pointer;
  font-size: 15px;
}
.city-select a:hover,
.city-select a:focus {
  background-color: #f1f8ff;
  border-radius: 2px;
  color: #46A4FF;
}
.city-select a.active {
  background-color: #46A4FF;
  color: #fff;
  border-radius: 2px;
}

.ts-buy-safe {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  color: #f02e2e;
  font-size: 16px;
  line-height: 1.5;
  font-weight: 600;
}
/* TomShop v0.296：下单侧栏安全提示及相关图标放大一点，提升识别度。 */
.ts-buy-safe .ts-icon {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
}
.ts-buy-method-name .ts-icon,
.ts-buy-check {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}
.ts-buy-pay-detail {
  margin-bottom: 24px;
}
.ts-buy-pay-detail h3 {
  margin: 0 0 8px;
  color: #1f2933;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 500;
}
.ts-buy-pay-detail h3 span {
  margin-left: 4px;
  color: #6b7280;
  font-weight: 400;
}
.ts-buy-pay-detail h3 b,
.ts-buy-pay-row b {
  font-weight: inherit;
}
.ts-buy-pay-row,
.ts-buy-method-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #f3f4f6;
  color: #1f2933;
  font-size: 15px;
}
.ts-buy-pay-row strong {
  font-weight: 400;
}
.ts-buy-methods {
  margin-bottom: 24px;
}
.ts-buy-method-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.ts-buy-method-name .ts-icon,
.ts-buy-check {
  color: #f02e2e;
}
.ts-buy-submit-area {
  display: grid;
  gap: 16px;
}
/* TomShop v1.26：最终结算行使用“应付金额 + 金额”，避免把功能描述“总价”直接当作前台文案。 */
.ts-buy-final-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid #e5e7eb;
}
.ts-buy-final-label {
  color: #1f2933;
  font-size: 16px;
  line-height: 1.4;
  font-weight: 500;
}
.ts-buy-final-price {
  display: inline-flex;
  align-items: baseline;
  justify-content: flex-end;
  color: #f02e2e;
  font-size: 26px;
  line-height: 1.2;
  font-weight: 700;
  white-space: nowrap;
}
.ts-buy-final-price .ts-money-symbol {
  margin-right: 2px;
  font-size: .68em;
  line-height: 1;
  font-weight: 500;
}
.ts-buy-final-price .ts-money-number {
  font-size: 1em;
  line-height: inherit;
}
.ts-buy-submit {
  width: 100%;
  height: 48px;
  border: 0;
  border-radius: 6px;
  background: #f02e2e;
  color: #fff;
  cursor: pointer;
  font-size: 18px;
  font-weight: 500;
  transition: background .15s ease, opacity .15s ease;
}
.ts-buy-submit:hover {
  background: #c91f1f;
}
.ts-buy-submit[disabled],
.ts-buy-submit.is-loading {
  opacity: .68;
  cursor: not-allowed;
}

@media (max-width: 820px) {
  .ts-buy-layout {
    flex-direction: column;
    padding: 16px 12px 24px;
    gap: 16px;
  }
  .ts-buy-main,
  .ts-buy-sidebar {
    width: 100%;
    flex: 1 1 auto;
    min-width: 0;
  }
  .ts-buy-main {
    gap: 16px;
  }
  .ts-buy-summary-card {
    position: static;
  }
}

@media (max-width: 560px) {
  .ts-buy-layout {
    padding-left: 10px;
    padding-right: 10px;
  }
  .ts-buy-card,
  .ts-buy-summary-card {
    padding: 14px;
  }
  .ts-buy-product {
    gap: 12px;
  }
  .ts-buy-thumb {
    width: 72px;
    height: 72px;
    flex-basis: 72px;
  }
  .ts-buy-product-content {
    gap: 10px;
  }
  .ts-buy-product-side {
    min-width: 74px;
  }
  .ts-buy-unit-price {
    font-size: 17px;
  }
  .ts-buy-qty {
    margin-top: 12px;
  }
  .ts-buy-form-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 14px;
  }
  .ts-buy-address-actions {
    gap: 8px;
  }
  .ts-buy-region-selects {
    gap: 6px;
  }
  .ts-buy-region-selects select {
    padding-left: 8px;
    padding-right: 4px;
    font-size: 13px;
  }
  .ts-buy-region-selects.is-tomshop-city-picker select {
    padding: 0;
    font-size: 16px;
  }
  .ts-buy-region-selects.is-tomshop-city-picker .city-picker-dropdown {
    min-width: 0;
  }
  .ts-buy-region-selects.is-tomshop-city-picker .city-select-tab > a {
    padding-left: 18px;
    padding-right: 18px;
  }
  .ts-buy-region-selects.is-tomshop-city-picker .city-select-content {
    padding: 10px 12px;
  }
  .ts-buy-card.ts-buy-address-card > h2 {
    font-size: 17px;
  }
  .ts-buy-paste-field textarea {
    min-height: 170px;
    padding: 14px 12px;
    font-size: 16px;
    line-height: 1.6;
  }
  .ts-buy-paste-action-row {
    min-height: 46px;
    padding: 6px 10px 10px;
  }
  body[data-page="tomshop-buy"] .ts-buy-paste-action-row > .ts-buy-address-parse {
    min-width: 100px;
    height: 34px;
    padding: 0 12px;
    font-size: 14px;
    line-height: 34px;
  }
  .ts-buy-final-price {
    font-size: 24px;
  }
}

@media (max-width: 380px) {
  .ts-buy-product-content {
    flex-direction: column;
  }
  .ts-buy-product-side {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    min-width: 0;
  }
  .ts-buy-qty {
    margin-top: 0;
  }
}

/* 前台订单查询页 */
body.ts-query-body {
  background: #f4f4f4;
  color: #1f2933;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}
.ts-query-shell {
  width: min(720px, 100%);
  margin: 0 auto;
  min-height: 100vh;
  min-height: var(--ts-real-vh, 100vh);
  background: #fff;
}
.ts-query-topbar {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid #f1f1f1;
}
.ts-query-topbar h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 600;
  color: #202124;
}
.ts-query-hero {
  padding: 28px 24px 24px;
}
.ts-query-hero h2 {
  margin: 0 0 8px;
  font-size: 24px;
  line-height: 1.25;
  font-weight: 500;
  color: #202124;
}
.ts-query-hero p {
  margin: 0 0 18px;
  color: #7b818a;
  font-size: 15px;
}
.ts-query-search {
  display: grid;
  grid-template-columns: 1fr 118px;
  gap: 12px;
}
.ts-query-search input {
  width: 100%;
  height: 48px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 0 14px;
  outline: none;
  color: #222;
  background: #fff;
  font-size: 16px;
}
.ts-query-search input:focus {
  border-color: #f02e2e;
}
.ts-query-search input.is-query-error {
  border-color: #ff5722;
  box-shadow: 0 0 0 1px rgba(255, 87, 34, .16);
}
.ts-query-search button {
  height: 48px;
  border: 0;
  border-radius: 6px;
  background: #f02e2e;
  color: #fff;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  justify-content: center;
  white-space: nowrap;
}

.ts-query-results {
  padding: 0 24px 28px;
}
.ts-query-empty {
  padding: 38px 20px;
  text-align: center;
  border-top: 1px solid #f1f1f1;
  color: #7b818a;
}
.ts-query-empty strong {
  display: block;
  margin-bottom: 6px;
  color: #202124;
  font-size: 18px;
  font-weight: 600;
}
.ts-query-empty p {
  margin: 0;
}
.ts-query-result-list {
  display: grid;
  gap: 14px;
}
.ts-query-order-card {
  border-top: 1px solid #f1f1f1;
  padding: 18px 0;
  background: #fff;
}
.ts-query-card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 14px;
}
.ts-query-card-head div {
  display: flex;
  align-items: center;
  gap: 8px;
}
.ts-query-card-head span {
  color: #7b818a;
  font-size: 15px;
}
.ts-query-card-head strong {
  color: #f02e2e;
  font-size: 16px;
  font-weight: 600;
}
.ts-query-card-head em {
  color: #8c929b;
  font-style: normal;
  font-size: 14px;
}
.ts-query-goods-line {
  display: grid;
  grid-template-columns: 86px 1fr auto;
  gap: 14px;
  align-items: center;
  min-width: 0;
}
.ts-query-goods-img {
  width: 86px;
  height: 86px;
  overflow: hidden;
  background: #f6f6f6;
}
.ts-query-goods-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ts-query-goods-text {
  min-width: 0;
}
.ts-query-goods-text a {
  display: -webkit-box;
  overflow: hidden;
  color: #202124;
  font-size: 16px;
  line-height: 1.45;
  font-weight: 600;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ts-query-goods-text p {
  margin: 6px 0 0;
  color: #8c929b;
  font-size: 14px;
}
.ts-query-goods-text span {
  display: block;
  margin-top: 6px;
  color: #666d77;
  font-size: 14px;
}
.ts-query-card-price {
  align-self: start;
  color: #202124;
  font-size: 18px;
  line-height: 1.3;
  white-space: nowrap;
}
.ts-query-card-meta {
  margin-top: 14px;
  display: grid;
  gap: 8px;
}
.ts-query-card-meta div {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 12px;
  align-items: baseline;
}
.ts-query-card-meta span {
  color: #8c929b;
}
.ts-query-card-meta strong {
  min-width: 0;
  color: #202124;
  font-weight: 400;
  word-break: break-word;
}
.ts-query-card-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}
.ts-query-detail-btn {
  min-width: 108px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: #f02e2e;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
}

/* 前台订单详情页 */
body.ts-detail-body {
  background: #f4f4f4;
  color: #202124;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  font-size: 16px;
}
.ts-detail-shell {
  width: min(720px, 100%);
  min-height: 100vh;
  min-height: var(--ts-real-vh, 100vh);
  margin: 0 auto;
  background: #fff;
}
.ts-detail-topbar {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border-bottom: 1px solid #f1f1f1;
}
.ts-detail-topbar h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 600;
}
.ts-detail-back,
.ts-detail-refresh {
  position: absolute;
  top: 0;
  height: 64px;
  display: flex;
  align-items: center;
  color: #333;
}
.ts-detail-back {
  left: 22px;
  font-size: 34px;
  line-height: 1;
  font-weight: 300;
}
.ts-detail-refresh {
  right: 22px;
  color: #73777f;
  font-size: 16px;
  font-weight: 600;
}

.ts-detail-success-hero {
  display: grid;
  grid-template-columns: 50px 1fr;
  gap: 14px;
  align-items: center;
  padding: 28px 24px 24px;
  border-bottom: 1px solid #f1f1f1;
  background: #fff;
}
.ts-detail-success-icon {
  width: 48px;
  height: 48px;
  border: 2px solid #18a957;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #18a957;
}
.ts-detail-success-icon .ts-icon {
  width: 30px;
  height: 30px;
  background-color: currentColor;
}
.ts-detail-success-text strong {
  display: block;
  margin: 0 0 6px;
  color: #202124;
  font-size: 27px;
  line-height: 1.25;
  font-weight: 600;
}
.ts-detail-success-text p {
  margin: 0;
  color: #717780;
  font-size: 17px;
  line-height: 1.55;
  font-weight: 500;
}
.ts-detail-status-card-after-success {
  padding-top: 22px;
  padding-bottom: 22px;
  background: #fafafa;
}
.ts-detail-status-card-after-success h2 {
  margin-bottom: 8px;
  font-size: 23px;
}
.ts-detail-status-card-after-success p {
  font-size: 16px;
  font-weight: 500;
}
.ts-detail-status-card {
  padding: 36px 24px 34px;
  border-bottom: 1px solid #f1f1f1;
}
.ts-detail-status-card h2 {
  margin: 0 0 14px;
  color: #202124;
  font-size: 28px;
  line-height: 1.25;
  font-weight: 600;
}
.ts-detail-status-card p {
  margin: 0;
  color: #717780;
  font-size: 18px;
  line-height: 1.55;
  font-weight: 600;
}
.ts-detail-section {
  padding: 24px;
  border-bottom: 1px solid #f1f1f1;
}
.ts-detail-section h2 {
  margin: 0 0 20px;
  color: #202124;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 600;
}
.ts-detail-goods-list {
  display: grid;
  gap: 16px;
}
.ts-detail-goods-item {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 18px;
  min-width: 0;
}
.ts-detail-goods-img {
  width: 112px;
  height: 112px;
  background: #f5f5f5;
  overflow: hidden;
}
.ts-detail-goods-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ts-detail-goods-main {
  min-width: 0;
}
.ts-detail-goods-title-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: start;
}
.ts-detail-goods-title {
  display: -webkit-box;
  overflow: hidden;
  color: #202124;
  font-size: 19px;
  line-height: 1.45;
  font-weight: 600;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.ts-detail-goods-title-row strong {
  color: #202124;
  font-size: 18px;
  line-height: 1.45;
  font-weight: 400;
  white-space: nowrap;
}
.ts-detail-goods-model,
.ts-detail-goods-qty {
  margin: 10px 0 0;
  color: #747b84;
  font-size: 16px;
  line-height: 1.45;
  font-weight: 600;
}
.ts-detail-info-list {
  display: grid;
  gap: 18px;
}
.ts-detail-info-row {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 14px;
  align-items: baseline;
}
.ts-detail-info-row > span {
  color: #848a93;
  font-size: 18px;
  line-height: 1.4;
  font-weight: 600;
}
.ts-detail-info-row > strong {
  min-width: 0;
  color: #202124;
  font-size: 18px;
  line-height: 1.45;
  font-weight: 400;
  text-align: right;
  word-break: break-word;
}
.ts-detail-info-row .ts-detail-money {
  color: #f02e2e;
  font-size: 22px;
}
.ts-detail-info-row button {
  margin-left: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #f02e2e;
  cursor: pointer;
  font-size: 17px;
}
.ts-detail-last-section {
  padding-bottom: 24px;
}
.ts-detail-bottom-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  padding: 18px 24px 20px;
  background: #fff;
}
.ts-detail-btn {
  height: 54px;
  border-radius: 6px;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 17px;
  line-height: 1;
  font-weight: 600;
  cursor: pointer;
}
.ts-detail-btn-light {
  border: 1px solid #d9d9d9;
  background: #fff;
  color: #202124;
}
.ts-detail-btn-light[disabled] {
  color: #b5b5b5;
  cursor: not-allowed;
}
.ts-detail-btn-red {
  background: #f02e2e;
  color: #fff;
}
.ts-detail-btn-green {
  background: #08bf62;
  color: #fff;
}
.ts-detail-btn svg {
  width: 24px;
  height: 24px;
}
.ts-detail-empty {
  padding: 70px 24px;
  text-align: center;
}
.ts-detail-empty strong {
  display: block;
  margin-bottom: 8px;
  font-size: 22px;
  font-weight: 600;
  color: #202124;
}
.ts-detail-empty p {
  margin: 0 auto 20px;
  max-width: 420px;
  color: #73777f;
  line-height: 1.6;
}
.ts-detail-empty a {
  height: 44px;
  min-width: 128px;
  padding: 0 22px;
  border-radius: 6px;
  background: #f02e2e;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

@media (max-width: 640px) {
  .ts-query-shell,
  .ts-detail-shell {
    width: 100%;
  }
  .ts-query-topbar,
  .ts-detail-topbar,
  .ts-detail-back,
  .ts-detail-refresh {
    height: 56px;
  }
  .ts-query-topbar h1,
  .ts-detail-topbar h1 {
    font-size: 20px;
  }
  .ts-query-hero,
  .ts-query-results {
    padding-left: 18px;
    padding-right: 18px;
  }
  .ts-query-hero h2 {
    font-size: 22px;
  }
  .ts-query-search {
    grid-template-columns: 1fr;
  }
  .ts-query-goods-line {
    grid-template-columns: 78px 1fr;
  }
  .ts-query-card-price {
    grid-column: 2;
    margin-top: -4px;
  }
  .ts-query-goods-img {
    width: 78px;
    height: 78px;
  }
  .ts-detail-back {
    left: 18px;
    font-size: 32px;
  }
  .ts-detail-refresh {
    right: 18px;
    font-size: 15px;
  }
  .ts-detail-status-card {
    padding: 30px 22px 30px;
  }
  .ts-detail-status-card h2 {
    font-size: 25px;
  }
  .ts-detail-status-card p {
    font-size: 17px;
  }
  .ts-detail-section {
    padding: 22px;
  }
  .ts-detail-section h2 {
    font-size: 21px;
  }
  .ts-detail-goods-item {
    grid-template-columns: 96px 1fr;
    gap: 14px;
  }
  .ts-detail-goods-img {
    width: 96px;
    height: 96px;
  }
  .ts-detail-goods-title-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .ts-detail-goods-title {
    font-size: 18px;
  }
  .ts-detail-goods-title-row strong {
    font-size: 17px;
  }
  .ts-detail-info-row {
    grid-template-columns: 98px 1fr;
    gap: 10px;
  }
  .ts-detail-info-row > span,
  .ts-detail-info-row > strong {
    font-size: 17px;
  }
  .ts-detail-info-row .ts-detail-money {
    font-size: 21px;
  }
  .ts-detail-bottom-actions {
    gap: 10px;
    padding: 16px 18px 18px;
  }
  .ts-detail-btn {
    height: 50px;
    font-size: 16px;
  }

  .ts-detail-success-hero {
    grid-template-columns: 44px 1fr;
    gap: 12px;
    padding: 24px 22px 22px;
  }
  .ts-detail-success-icon {
    width: 42px;
    height: 42px;
  }
  .ts-detail-success-icon .ts-icon {
    width: 27px;
    height: 27px;
    background-color: currentColor;
  }
  .ts-detail-success-text strong {
    font-size: 24px;
  }
  .ts-detail-success-text p {
    font-size: 16px;
  }
  .ts-detail-status-card-after-success {
    padding-top: 20px;
    padding-bottom: 20px;
  }
  .ts-detail-status-card-after-success h2 {
    font-size: 21px;
  }
  .ts-detail-status-card-after-success p {
    font-size: 16px;
  }
}

@media (max-width: 380px) {
  .ts-detail-section {
    padding-left: 18px;
    padding-right: 18px;
  }
  .ts-detail-goods-item {
    grid-template-columns: 84px 1fr;
  }
  .ts-detail-goods-img {
    width: 84px;
    height: 84px;
  }
  .ts-detail-info-row {
    grid-template-columns: 86px 1fr;
  }
  .ts-detail-bottom-actions {
    grid-template-columns: 1fr;
  }
}


/* v0.98 前台订单详情细节修正 */
.ts-toast {
  top: 76px;
  bottom: auto;
  padding: 9px 16px;
  font-size: 14px;
  line-height: 1.4;
}
.ts-detail-info-row button.is-copied {
  color: #18a957;
}

@media (min-width: 641px) {
  body.ts-detail-body {
    padding: 20px 0;
  }
  .ts-detail-shell {
    width: 720px;
    max-width: calc(100% - 48px);
    min-height: calc(100vh - 40px);
    border-left: 1px solid #eeeeee;
    border-right: 1px solid #eeeeee;
  }
  .ts-detail-status-card {
    padding: 30px 24px 28px;
  }
  .ts-detail-status-card h2 {
    margin-bottom: 10px;
    font-size: 25px;
  }
  .ts-detail-status-card p {
    font-size: 16px;
    font-weight: 500;
  }
  .ts-detail-success-hero {
    padding: 24px;
  }
  .ts-detail-success-text strong {
    font-size: 25px;
  }
  .ts-detail-success-text p {
    font-size: 16px;
  }
  .ts-detail-section {
    padding: 24px;
  }
  .ts-detail-section h2 {
    margin-bottom: 18px;
    font-size: 21px;
  }
  .ts-detail-goods-item {
    grid-template-columns: 96px 1fr;
    gap: 16px;
    align-items: start;
  }
  .ts-detail-goods-img {
    width: 96px;
    height: 96px;
  }
  .ts-detail-goods-title {
    font-size: 17px;
    line-height: 1.45;
  }
  .ts-detail-goods-title-row strong {
    font-size: 17px;
  }
  .ts-detail-goods-model,
  .ts-detail-goods-qty {
    margin-top: 8px;
    font-size: 15px;
    font-weight: 500;
  }
  .ts-detail-info-list {
    gap: 14px;
  }
  .ts-detail-info-row {
    grid-template-columns: 98px 1fr;
    gap: 12px;
  }
  .ts-detail-info-row > span,
  .ts-detail-info-row > strong {
    font-size: 16px;
  }
  .ts-detail-info-row .ts-detail-money {
    font-size: 20px;
  }
  .ts-detail-info-row button {
    font-size: 15px;
  }
  .ts-detail-bottom-actions {
    padding: 16px 24px 18px;
    border-top: 1px solid #f1f1f1;
  }
  .ts-detail-btn {
    height: 48px;
    font-size: 16px;
  }
}


/* v0.99 订单详情页按静态预览 v2 对齐 */
body.ts-order-preview-body{
  min-height:100vh;
  min-height:var(--ts-real-vh, 100vh);
  background:#f6f7f9;
  color:#222;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"PingFang SC","Microsoft YaHei",sans-serif;
  font-size:15px;
  line-height:1.5;
}
.order-page button,
.order-page a,
.order-page input{font:inherit}
.order-page button{cursor:pointer;border:0;background:none}
.order-page{
  max-width:900px;
  margin:0 auto;
  min-height:100vh;
  min-height:var(--ts-real-vh, 100vh);
  background:#fff;
}
.order-header{
  height:58px;
  display:flex;
  align-items:center;
  justify-content:center;
  position:sticky;
  top:0;
  z-index:20;
  background:rgba(255,255,255,.96);
  border-bottom:1px solid rgba(238,238,238,.82);
  backdrop-filter:saturate(140%) blur(8px);
}
.back-link{
  position:absolute;
  left:18px;
  top:50%;
  transform:translateY(-50%);
  width:34px;
  height:34px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#333;
  text-decoration:none;
  font-size:30px;
  line-height:1;
}
.header-title{font-size:18px;font-weight:500;letter-spacing:.5px}
.refresh-btn{
  position:absolute;
  right:18px;
  top:50%;
  transform:translateY(-50%);
  color:#777;
  font-size:14px;
  padding:7px 2px;
}
.refresh-btn:active{color:#f02e2e}
.order-content{padding:22px 24px 96px}
.status-panel{padding:6px 0 24px;border-bottom:1px solid #eee}
.status-title{font-size:25px;font-weight:500;letter-spacing:.2px;margin:0 0 7px;color:#222;line-height:1.35}
.status-desc{color:#777;font-size:14px;margin:0}
.success-panel{
  display:flex;
  align-items:center;
  gap:18px;
  padding:14px 0 26px;
  border-bottom:1px solid #eee;
}
.success-icon{
  width:58px;
  height:58px;
  flex:0 0 58px;
  border:2px solid #18a957;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#18a957;
}
.success-icon .ts-icon{width:35px;height:35px}
.success-text h1{margin:0 0 6px;color:#222;font-size:25px;line-height:1.3;font-weight:500;letter-spacing:.2px}
.success-text p{margin:0;color:#777;font-size:15px;line-height:1.55}
.section{padding:23px 0;border-bottom:1px solid #eee}
.section:last-of-type{border-bottom:0}
.section-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:14px}
.section-head h2{margin:0;color:#222;font-size:17px;font-weight:500;line-height:1.4}
.section-head span{color:#777;font-size:13px}
.goods-list{display:grid;gap:18px}
.goods-row{display:flex;gap:14px;align-items:flex-start;min-width:0}
.goods-row + .goods-row{padding-top:18px;border-top:1px solid #f2f2f2}
.goods-thumb{width:96px;height:96px;flex:0 0 96px;background:linear-gradient(135deg,#f1f2f4,#fafafa);overflow:hidden;color:inherit;text-decoration:none}
.goods-thumb img{width:100%;height:100%;object-fit:cover;display:block}
.goods-body{min-width:0;flex:1;padding-top:1px}
.goods-title{
  color:#222;
  font-size:16px;
  font-weight:400;
  line-height:1.45;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  text-decoration:none;
}
.goods-sku{color:#888;font-size:13px;margin:7px 0 0}
.goods-count{color:#666;font-size:14px;margin:8px 0 0}
.goods-price{flex:0 0 auto;color:#333;font-size:17px;text-align:right;padding-top:1px;white-space:nowrap}
.info-grid{display:grid;grid-template-columns:1fr 1fr;column-gap:34px;row-gap:0}
.info-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;min-height:38px;padding:7px 0}
.info-row.full{grid-column:1 / -1}
.info-label{flex:0 0 86px;color:#777;text-align:left}
.info-value{flex:1;min-width:0;color:#222;text-align:right;word-break:break-word}
.info-value.money{color:#f02e2e;font-size:19px}
.copy-line{display:inline-flex;align-items:center;justify-content:flex-end;gap:8px}
.copy-btn{color:#f02e2e;font-size:13px;white-space:nowrap;padding:0;border:0;background:transparent;cursor:pointer}
.copy-btn.is-copied{color:#18a957}
.logistics-strip{display:flex;align-items:center;gap:12px;margin:2px 0 17px;padding:13px 14px;background:#fff6f6}
.logistics-icon{width:30px;height:30px;color:#f02e2e;flex:0 0 30px}
.logistics-main{flex:1;min-width:0}
.logistics-main strong{display:block;font-size:15px;font-weight:500;color:#222}
.logistics-main span{display:block;margin-top:1px;font-size:13px;color:#777}
.address-block{display:flex;align-items:flex-start;justify-content:space-between;gap:18px}
.address-person{flex:0 0 170px}
.address-person strong{display:block;font-size:16px;font-weight:500;color:#222}
.address-person span{display:block;color:#777;font-size:13px;margin-top:3px}
.address-text{flex:1;margin:0;color:#333;text-align:right;line-height:1.7}
.address-remark{margin:12px 0 0;color:#777;font-size:13px;line-height:1.6;text-align:right}
.action-bar{
  position:sticky;
  bottom:0;
  z-index:30;
  display:flex;
  justify-content:flex-end;
  gap:12px;
  padding:15px 24px calc(15px + env(safe-area-inset-bottom));
  background:rgba(255,255,255,.96);
  border-top:1px solid #eee;
  backdrop-filter:saturate(140%) blur(8px);
}
.action-btn{
  min-width:122px;
  height:44px;
  padding:0 18px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  font-size:15px;
  color:#333;
  background:#fff;
  border:1px solid #ddd;
  border-radius:4px;
  text-decoration:none;
}
.action-btn[disabled]{color:#b5b5b5;cursor:not-allowed}
.action-btn.primary{color:#fff;background:#f02e2e;border-color:#f02e2e}
.action-btn.primary:active{background:#d92222}
.action-btn.wechat{color:#fff;background:#07c160;border-color:#07c160}
.action-btn .ts-icon{width:18px;height:18px;flex:0 0 18px}
body.ts-order-preview-body .ts-detail-empty{padding:70px 24px;text-align:center}
body.ts-order-preview-body .ts-detail-empty strong{display:block;margin-bottom:8px;font-size:22px;font-weight:500;color:#222}
body.ts-order-preview-body .ts-detail-empty p{margin:0 auto 20px;max-width:420px;color:#777;line-height:1.6}
body.ts-order-preview-body .ts-detail-empty a{height:44px;min-width:128px;padding:0 22px;border-radius:4px;background:#f02e2e;color:#fff;display:inline-flex;align-items:center;justify-content:center;font-weight:500;text-decoration:none}
body.ts-order-preview-body .ts-toast{top:76px;bottom:auto}
@media (min-width:960px){
  body.ts-order-preview-body{padding:26px 0;background:#f6f7f9}
  .order-page{min-height:auto;border-radius:6px;box-shadow:0 8px 28px rgba(20,30,40,.06)}
  .order-header{border-radius:6px 6px 0 0}
  .action-bar{position:static;border-radius:0 0 6px 6px}
  .order-content{padding-bottom:24px}
}
@media (max-width:720px){
  body.ts-order-preview-body{background:#fff}
  .order-header{height:54px}
  .back-link{left:12px}
  .refresh-btn{right:14px}
  .order-content{padding:18px 18px 92px}
  .status-panel{padding-bottom:20px}
  .status-title{font-size:22px}
  .success-panel{gap:14px;padding:10px 0 22px}
  .success-icon{width:50px;height:50px;flex-basis:50px}
  .success-icon .ts-icon{width:31px;height:31px}
  .success-text h1{font-size:22px}
  .success-text p{font-size:14px}
  .goods-thumb{width:86px;height:86px;flex-basis:86px}
  .goods-row{gap:12px}
  .goods-price{font-size:16px}
  .info-grid{display:block}
  .info-row{min-height:36px;padding:7px 0}
  .info-label{flex-basis:82px}
  .address-block{display:block}
  .address-person{margin-bottom:10px}
  .address-text{text-align:left;color:#333}
  .address-remark{text-align:left}
  .action-bar{justify-content:space-between;gap:9px;padding:12px 12px calc(12px + env(safe-area-inset-bottom))}
  .action-btn{flex:1;min-width:0;height:42px;padding:0 8px;font-size:14px}
}
@media (max-width:380px){
  .goods-row{align-items:flex-start}
  .goods-price{display:none}
  .action-btn{font-size:13px}
}


/* v0.101 订单状态图标 */
body.ts-order-preview-body .back-link{
  font-size:0;
  color:#222;
}
/* TomShop v0.355：返回按钮只使用模板中的 ts-icon-chevron-left，不再用 CSS 伪元素补图标。 */
body.ts-order-preview-body .status-panel{
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M12 7.3v5.1l3.4 2.1%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-waiting{
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M12 7.3v5.1l3.4 2.1%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-confirmed{
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M7.8 12.3l2.7 2.7 5.8-6.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272.1%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-shipped{
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Cpath d=%27M3.5 7h10.2v8.4H3.5V7Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27 stroke-linejoin=%27round%27/%3E%3Cpath d=%27M13.7 10.1h3.2l2.6 3.1v2.2h-5.8v-5.3Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27 stroke-linejoin=%27round%27/%3E%3Ccircle cx=%277.2%27 cy=%2717.1%27 r=%271.7%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27/%3E%3Ccircle cx=%2717.2%27 cy=%2717.1%27 r=%271.7%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-done{
  --tomshop-status-color:#18a957;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M7.8 12.3l2.7 2.7 5.8-6.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272.1%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-closed{
  --tomshop-status-color:#777;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M8.8 8.8l6.4 6.4M15.2 8.8l-6.4 6.4%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272%27 stroke-linecap=%27round%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-panel.tomshop-status-danger{
  --tomshop-status-color:#b00020;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Cpath d=%27M12 3.4 21.3 19a1 1 0 0 1-.86 1.5H3.56A1 1 0 0 1 2.7 19L12 3.4Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linejoin=%27round%27/%3E%3Cpath d=%27M12 8.6v5.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272%27 stroke-linecap=%27round%27/%3E%3Ccircle cx=%2712%27 cy=%2717%27 r=%271.1%27 fill=%27black%27/%3E%3C/svg%3E");
}
body.ts-order-preview-body .status-title{
  display:flex;
  align-items:center;
  gap:11px;
}
body.ts-order-preview-body .status-title::before{
  content:"";
  width:29px;
  height:29px;
  flex:0 0 29px;
  background:var(--tomshop-status-color);
  -webkit-mask:var(--tomshop-status-icon) center / contain no-repeat;
  mask:var(--tomshop-status-icon) center / contain no-repeat;
}
@media (max-width:720px){
  body.ts-order-preview-body .status-title{gap:10px}
  body.ts-order-preview-body .status-title::before{width:26px;height:26px;flex-basis:26px}
}


/* v0.103 查询结果状态颜色 */
.ts-query-order-card.tomshop-status-waiting .ts-query-card-head strong,
.ts-query-order-card.tomshop-status-confirmed .ts-query-card-head strong,
.ts-query-order-card.tomshop-status-shipped .ts-query-card-head strong{color:#f02e2e}
.ts-query-order-card.tomshop-status-done .ts-query-card-head strong{color:#18a957}
.ts-query-order-card.tomshop-status-closed .ts-query-card-head strong{color:#777}
.ts-query-order-card.tomshop-status-danger .ts-query-card-head strong{color:#b00020}
.ts-query-order-card.tomshop-status-closed .ts-query-detail-btn{background:#777}
.ts-query-order-card.tomshop-status-danger .ts-query-detail-btn{background:#b00020}

/* v0.143 查询列表状态沿用订单详情状态图标 */
.ts-query-order-card {
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M12 7.3v5.1l3.4 2.1%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-waiting {
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M12 7.3v5.1l3.4 2.1%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-confirmed {
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M7.8 12.3l2.7 2.7 5.8-6.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272.1%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-shipped {
  --tomshop-status-color:#f02e2e;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Cpath d=%27M3.5 7h10.2v8.4H3.5V7Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27 stroke-linejoin=%27round%27/%3E%3Cpath d=%27M13.7 10.1h3.2l2.6 3.1v2.2h-5.8v-5.3Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27 stroke-linejoin=%27round%27/%3E%3Ccircle cx=%277.2%27 cy=%2717.1%27 r=%271.7%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27/%3E%3Ccircle cx=%2717.2%27 cy=%2717.1%27 r=%271.7%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.8%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-done {
  --tomshop-status-color:#18a957;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M7.8 12.3l2.7 2.7 5.8-6.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272.1%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-closed {
  --tomshop-status-color:#777;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Ccircle cx=%2712%27 cy=%2712%27 r=%279%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27/%3E%3Cpath d=%27M8.8 8.8l6.4 6.4M15.2 8.8l-6.4 6.4%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272%27 stroke-linecap=%27round%27/%3E%3C/svg%3E");
}
.ts-query-order-card.tomshop-status-danger {
  --tomshop-status-color:#b00020;
  --tomshop-status-icon:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Cpath d=%27M12 3.4 21.3 19a1 1 0 0 1-.86 1.5H3.56A1 1 0 0 1 2.7 19L12 3.4Z%27 fill=%27none%27 stroke=%27black%27 stroke-width=%271.9%27 stroke-linejoin=%27round%27/%3E%3Cpath d=%27M12 8.6v5.2%27 fill=%27none%27 stroke=%27black%27 stroke-width=%272%27 stroke-linecap=%27round%27/%3E%3Ccircle cx=%2712%27 cy=%2717%27 r=%271.1%27 fill=%27black%27/%3E%3C/svg%3E");
}
.ts-query-card-head strong {
  color: var(--tomshop-status-color, #f02e2e);
}
.ts-query-card-head strong::before {
  content: "";
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  background: var(--tomshop-status-color, currentColor);
  -webkit-mask: var(--tomshop-status-icon) center / contain no-repeat;
  mask: var(--tomshop-status-icon) center / contain no-repeat;
}



/* TomShop v0.374：模板接入基础样式只保留业务入口；tomshop-theme-* 外壳布局交给主题 CSS 或模板外壳生成器控制。 */
.tomshop-buy-entry {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 20px;
  border: 0;
  border-radius: var(--ts-radius-sm);
  background: var(--ts-primary);
  color: #fff;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
}
.tomshop-buy-entry:hover { background: var(--ts-primary-dark); color: #fff; }


/* v0.106 主站主题壳绑定：订单流程不再裸页 */
body.ts-with-theme {
  padding: 0 !important;
  background: var(--bg-primary, #f8fafc);
}
body.ts-with-theme .tomshop-theme-page-shell {
  box-sizing: border-box;
  padding-top: 36px;
  padding-bottom: 40px;
}
body.ts-with-theme .tomshop-theme-page-shell .ts-buy-layout {
  padding-top: 0;
  padding-bottom: 0;
}
@media (max-width: 720px) {
  body.ts-with-theme .tomshop-theme-page-shell {
    padding-top: 16px;
    padding-bottom: 24px;
  }
}
body.ts-with-theme .neo-tomshop-main {
  background: var(--bg-primary, #f8fafc);
}
body.ts-with-theme .neo-tomshop-page-shell {
  width: min(1440px, calc(100% - 3rem));
  padding-top: 1.5rem;
  padding-bottom: 2rem;
}
body.ts-with-theme .ts-buy-page,
body.ts-with-theme .ts-query-shell,
body.ts-with-theme .order-page {
  min-height: auto;
}
body.ts-with-theme .ts-buy-layout {
  width: 100%;
  padding-left: 0;
  padding-right: 0;
}
body.ts-with-theme .ts-buy-summary-card {
  top: 1rem;
}
body.ts-with-theme .ts-query-shell,
body.ts-with-theme .order-page {
  box-shadow: 0 8px 28px rgba(20,30,40,.06);
}
body.ts-with-theme .order-header {
  top: 0;
}
body.ts-with-theme .action-bar {
  margin-left: -24px;
  margin-right: -24px;
}
@media (min-width: 1024px) {
  body.ts-with-theme .neo-tomshop-page-shell {
    padding-top: 3rem;
  }
}
@media (max-width: 720px) {
  body.ts-with-theme .neo-tomshop-page-shell {
    width: 100%;
    padding: 0 0 1rem;
  }
  body.ts-with-theme .ts-buy-layout {
    padding-left: 10px;
    padding-right: 10px;
  }
  body.ts-with-theme .ts-query-shell,
  body.ts-with-theme .order-page {
    box-shadow: none;
  }
  body.ts-with-theme .action-bar {
    margin-left: 0;
    margin-right: 0;
  }
}


/* v0.107 主站主题壳隔离：TomShop 页面只改订单内容，不污染主站导航、搜索、页脚 */
body.ts-with-theme.ts-buy-body,
body.ts-with-theme.ts-query-body,
body.ts-with-theme.ts-detail-body,
body.ts-with-theme.ts-order-preview-body {
  color: var(--text-primary, #0f172a);
  font-family: var(--font-sans, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
  font-size: 16px;
  line-height: 1.5;
}
body.ts-with-theme .neo-tomshop-page-shell {
  padding-top: 2rem;
}
body.ts-with-theme.ts-query-body .neo-tomshop-page-shell,
body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell {
  width: min(980px, calc(100% - 3rem));
}
body.ts-with-theme.ts-buy-body .neo-tomshop-page-shell {
  width: min(1280px, calc(100% - 3rem));
}
body.ts-with-theme .order-page,
body.ts-with-theme .ts-query-shell {
  width: 100%;
  max-width: 900px;
}
body.ts-with-theme.ts-query-body .ts-query-shell {
  max-width: 760px;
}
@media (max-width: 720px) {
  body.ts-with-theme.ts-query-body .neo-tomshop-page-shell,
  body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell,
  body.ts-with-theme.ts-buy-body .neo-tomshop-page-shell {
    width: 100%;
    padding-top: 0;
  }
}

/* v0.108 主站主题化适配：PC 端变成主站内容区卡片，不再像独立手机页硬塞进来 */
@media (min-width: 721px) {
  body.ts-with-theme.ts-buy-body,
  body.ts-with-theme.ts-query-body,
  body.ts-with-theme.ts-detail-body,
  body.ts-with-theme.ts-order-preview-body {
    background: var(--bg-primary, #f8fafc);
  }

  body.ts-with-theme .neo-tomshop-main {
    background: var(--bg-primary, #f8fafc);
  }

  body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell,
  body.ts-with-theme.ts-query-body .neo-tomshop-page-shell {
    width: min(1180px, calc(100% - 3rem));
    padding-top: 2rem;
    padding-bottom: 2.5rem;
  }

  body.ts-with-theme.ts-buy-body .neo-tomshop-page-shell {
    width: min(1280px, calc(100% - 3rem));
    padding-top: 2rem;
    padding-bottom: 2.5rem;
  }

  body.ts-with-theme .ts-buy-layout {
    padding-top: 0;
    padding-bottom: 0;
  }

  body.ts-with-theme .ts-buy-card,
  body.ts-with-theme .ts-buy-summary-card {
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    border-radius: var(--radius-card, .65rem);
    box-shadow: var(--shadow-soft, 0 2px 8px rgba(15, 23, 42, .04), 0 10px 20px rgba(15, 23, 42, .04));
  }

  body.ts-with-theme .ts-buy-summary-card {
    top: 1rem;
  }

  body.ts-with-theme.ts-query-body .ts-query-shell {
    width: 100%;
    max-width: none;
    min-height: auto;
    background: transparent;
    box-shadow: none;
  }

  body.ts-with-theme.ts-query-body .ts-query-topbar {
    display: none;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero,
  body.ts-with-theme.ts-query-body .ts-query-order-card,
  body.ts-with-theme.ts-query-body .ts-query-empty {
    background: var(--panel-bg, #fff);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    border-radius: var(--radius-card, .65rem);
    box-shadow: var(--shadow-soft, 0 2px 8px rgba(15, 23, 42, .04), 0 10px 20px rgba(15, 23, 42, .04));
  }

  body.ts-with-theme.ts-query-body .ts-query-hero {
    padding: 1.4rem 1.5rem;
    margin-bottom: 1rem;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero h2 {
    font-size: 1.35rem;
    font-weight: 500;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero p {
    font-size: .94rem;
  }

  body.ts-with-theme.ts-query-body .ts-query-results {
    padding: 0;
  }

  body.ts-with-theme.ts-query-body .ts-query-result-list {
    gap: 1rem;
  }

  body.ts-with-theme.ts-query-body .ts-query-order-card {
    padding: 1.15rem 1.25rem;
    border-top: 1px solid var(--border, rgba(15, 23, 42, 0.08));
  }

  body.ts-with-theme.ts-query-body .ts-query-empty {
    border-top: 1px solid var(--border, rgba(15, 23, 42, 0.08));
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head {
    padding-bottom: .85rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border, rgba(15, 23, 42, 0.08));
  }

  body.ts-with-theme.ts-order-preview-body .order-page {
    width: 100%;
    max-width: none;
    min-height: auto;
    margin: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
  }

  body.ts-with-theme.ts-order-preview-body .order-header {
    display: flex;
    position: relative;
    top: auto;
    z-index: 1;
  }

  body.ts-with-theme.ts-order-preview-body .order-content {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
    gap: 1rem;
    padding: 0;
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel,
  body.ts-with-theme.ts-order-preview-body .section {
    background: var(--panel-bg, #fff);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    border-radius: var(--radius-card, .65rem);
    box-shadow: var(--shadow-soft, 0 2px 8px rgba(15, 23, 42, .04), 0 10px 20px rgba(15, 23, 42, .04));
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel {
    grid-column: 1 / -1;
    padding: 1.35rem 1.5rem;
    border-bottom: 1px solid var(--border, rgba(15, 23, 42, 0.08));
  }

  body.ts-with-theme.ts-order-preview-body .status-title {
    margin-bottom: .35rem;
    font-size: 1.55rem;
    font-weight: 500;
    line-height: 1.35;
  }

  body.ts-with-theme.ts-order-preview-body .status-desc,
  body.ts-with-theme.ts-order-preview-body .success-text p {
    color: var(--text-secondary, #64748b);
    font-size: .95rem;
    font-weight: 400;
  }

  body.ts-with-theme.ts-order-preview-body .success-panel {
    gap: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon {
    width: 46px;
    height: 46px;
    flex-basis: 46px;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon .ts-icon {
    width: 28px;
    height: 28px;
  }

  body.ts-with-theme.ts-order-preview-body .success-text h1 {
    font-size: 1.45rem;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .section {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border, rgba(15, 23, 42, 0.08));
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: 1 / -1;
  }

  body.ts-with-theme.ts-order-preview-body .section-head {
    margin-bottom: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .section-head h2 {
    font-size: 1.05rem;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .goods-list {
    gap: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-row {
    gap: 1rem;
    align-items: center;
  }

  body.ts-with-theme.ts-order-preview-body .goods-thumb {
    width: 86px;
    height: 86px;
    flex-basis: 86px;
    border-radius: .5rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-thumb img {
    object-fit: contain;
  }

  body.ts-with-theme.ts-order-preview-body .goods-title {
    font-size: 1rem;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .goods-price {
    font-size: 1.05rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-grid {
    display: grid;
    grid-template-columns: 1fr;
    column-gap: 0;
  }

  body.ts-with-theme.ts-order-preview-body .info-row {
    min-height: 34px;
    padding: .35rem 0;
  }

  body.ts-with-theme.ts-order-preview-body .info-label {
    color: var(--text-secondary, #64748b);
    flex-basis: 78px;
  }

  body.ts-with-theme.ts-order-preview-body .info-value {
    color: var(--text-primary, #0f172a);
  }

  body.ts-with-theme.ts-order-preview-body .info-value.money {
    color: #f02e2e;
    font-size: 1.18rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-strip {
    border-radius: .55rem;
    margin-bottom: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-block {
    align-items: center;
  }

  body.ts-with-theme.ts-order-preview-body .address-person {
    flex-basis: 150px;
  }

  body.ts-with-theme.ts-order-preview-body .action-bar {
    position: static;
    justify-content: flex-end;
    gap: .75rem;
    padding: 1rem 0 0;
    margin: 0;
    background: transparent;
    border-top: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
  }

  body.ts-with-theme.ts-order-preview-body .action-btn {
    min-width: 120px;
    height: 42px;
    border-radius: .45rem;
    font-size: .92rem;
  }
}

@media (min-width: 721px) and (max-width: 1120px) {
  body.ts-with-theme.ts-order-preview-body .order-content {
    grid-template-columns: 1fr;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: auto;
  }
}

/* v0.109 PC订单详情紧凑化：让一个订单尽量一屏看完 */
@media (min-width: 721px) {
  body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell {
    width: min(1180px, calc(100% - 2rem));
    padding-top: 1rem;
    padding-bottom: 1.25rem;
  }

  body.ts-with-theme.ts-order-preview-body .order-content {
    grid-template-columns: minmax(0, 1fr) minmax(330px, .78fr);
    gap: .75rem;
    align-items: start;
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel {
    grid-column: 1;
    grid-row: 1;
    min-height: 0;
    padding: .9rem 1.05rem;
  }

  body.ts-with-theme.ts-order-preview-body .status-title,
  body.ts-with-theme.ts-order-preview-body .success-text h1 {
    font-size: 1.28rem;
    line-height: 1.25;
    margin-bottom: .22rem;
  }

  body.ts-with-theme.ts-order-preview-body .status-desc,
  body.ts-with-theme.ts-order-preview-body .success-text p {
    font-size: .86rem;
    line-height: 1.42;
  }

  body.ts-with-theme.ts-order-preview-body .success-panel {
    gap: .75rem;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon .ts-icon {
    width: 23px;
    height: 23px;
  }

  body.ts-with-theme.ts-order-preview-body .section {
    padding: .95rem 1.05rem;
  }

  body.ts-with-theme.ts-order-preview-body .section-head {
    margin-bottom: .65rem;
  }

  body.ts-with-theme.ts-order-preview-body .section-head h2 {
    font-size: .98rem;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2) {
    grid-column: 1;
    grid-row: 2;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(3) {
    grid-column: 2;
    grid-row: 1 / span 2;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(4) {
    grid-column: 2;
    grid-row: 3;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: 1;
    grid-row: 3;
  }

  body.ts-with-theme.ts-order-preview-body .goods-row {
    gap: .8rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-thumb {
    width: 64px;
    height: 64px;
    flex-basis: 64px;
  }

  body.ts-with-theme.ts-order-preview-body .goods-title {
    font-size: .95rem;
    line-height: 1.35;
  }

  body.ts-with-theme.ts-order-preview-body .goods-sku {
    margin-top: .25rem;
    font-size: .8rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-count {
    margin-top: .22rem;
    font-size: .84rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-price {
    font-size: .98rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-row {
    min-height: 28px;
    padding: .2rem 0;
    gap: .75rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-label {
    flex-basis: 72px;
    font-size: .86rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-value {
    font-size: .9rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-value.money {
    font-size: 1.04rem;
  }

  body.ts-with-theme.ts-order-preview-body .copy-btn {
    font-size: .82rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-strip {
    margin: .1rem 0 .65rem;
    padding: .75rem .85rem;
    gap: .65rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-icon {
    width: 23px;
    height: 23px;
    flex-basis: 23px;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-main strong {
    font-size: .9rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-main span {
    font-size: .8rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-block {
    gap: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-person {
    flex-basis: 130px;
  }

  body.ts-with-theme.ts-order-preview-body .address-person strong {
    font-size: .92rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-person span,
  body.ts-with-theme.ts-order-preview-body .address-remark {
    font-size: .78rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-text {
    font-size: .9rem;
    line-height: 1.5;
  }

  body.ts-with-theme.ts-order-preview-body .address-remark {
    margin-top: .45rem;
  }

  body.ts-with-theme.ts-order-preview-body .action-bar {
    margin-top: .75rem;
    padding: .75rem 1.05rem;
    background: var(--panel-bg, #fff);
    border: 1px solid var(--border, rgba(15, 23, 42, 0.08));
    border-radius: var(--radius-card, .65rem);
    box-shadow: var(--shadow-soft, 0 2px 8px rgba(15, 23, 42, .04), 0 10px 20px rgba(15, 23, 42, .04));
  }

  body.ts-with-theme.ts-order-preview-body .action-btn {
    min-width: 110px;
    height: 38px;
    font-size: .86rem;
  }
}

@media (min-width: 721px) and (max-width: 1120px) {
  body.ts-with-theme.ts-order-preview-body .order-content {
    grid-template-columns: 1fr;
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel,
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(3),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(4),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: auto;
    grid-row: auto;
  }
}

/* v0.110 PC订单详情单据化：一张白色单据，不再拆成多张卡片 */
@media (min-width: 721px) {
  body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell {
    width: min(1120px, calc(100% - 2rem));
    padding-top: 1rem;
    padding-bottom: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .order-page {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    background: var(--panel-bg, #fff);
    border: 1px solid var(--border, rgba(15, 23, 42, .08));
    border-radius: var(--radius-card, .65rem);
    box-shadow: var(--shadow-soft, 0 2px 8px rgba(15, 23, 42, .04), 0 10px 20px rgba(15, 23, 42, .04));
    overflow: hidden;
  }

  body.ts-with-theme.ts-order-preview-body .order-header {
    display: flex;
    position: relative;
    top: auto;
    z-index: 1;
  }

  body.ts-with-theme.ts-order-preview-body .order-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, .82fr);
    gap: 0;
    align-items: stretch;
    padding: 0 1.25rem;
    background: var(--panel-bg, #fff);
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel,
  body.ts-with-theme.ts-order-preview-body .section {
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel {
    grid-column: 1 / -1;
    grid-row: 1;
    min-height: auto;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border, rgba(15, 23, 42, .08));
  }

  body.ts-with-theme.ts-order-preview-body .status-title,
  body.ts-with-theme.ts-order-preview-body .success-text h1 {
    margin-bottom: .25rem;
    font-size: 1.28rem;
    line-height: 1.28;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .status-desc,
  body.ts-with-theme.ts-order-preview-body .success-text p {
    font-size: .88rem;
    line-height: 1.45;
    color: var(--text-secondary, #64748b);
  }

  body.ts-with-theme.ts-order-preview-body .success-panel {
    gap: .75rem;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  body.ts-with-theme.ts-order-preview-body .success-icon .ts-icon {
    width: 23px;
    height: 23px;
  }

  body.ts-with-theme.ts-order-preview-body .section {
    padding: 1rem 0;
    border-bottom: 1px solid var(--border, rgba(15, 23, 42, .08));
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2) {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(3) {
    grid-column: 1;
    grid-row: 3;
    padding-right: 1.25rem;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(4) {
    grid-column: 2;
    grid-row: 3;
    padding-left: 1.25rem;
    border-left: 1px solid var(--border, rgba(15, 23, 42, .08));
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: 1 / -1;
    grid-row: 4;
    border-bottom: 0;
  }

  body.ts-with-theme.ts-order-preview-body .section-head {
    margin-bottom: .75rem;
  }

  body.ts-with-theme.ts-order-preview-body .section-head h2 {
    font-size: .98rem;
    line-height: 1.35;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .goods-row {
    gap: .85rem;
    align-items: center;
  }

  body.ts-with-theme.ts-order-preview-body .goods-thumb {
    width: 66px;
    height: 66px;
    flex-basis: 66px;
    border-radius: .45rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-thumb img {
    object-fit: contain;
  }

  body.ts-with-theme.ts-order-preview-body .goods-title {
    font-size: .96rem;
    line-height: 1.35;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .goods-sku {
    margin-top: .22rem;
    font-size: .8rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-count {
    margin-top: .22rem;
    font-size: .84rem;
  }

  body.ts-with-theme.ts-order-preview-body .goods-price {
    font-size: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-grid {
    display: grid;
    grid-template-columns: 1fr;
    row-gap: 0;
  }

  body.ts-with-theme.ts-order-preview-body .info-row {
    min-height: 29px;
    padding: .22rem 0;
    gap: .75rem;
  }

  body.ts-with-theme.ts-order-preview-body .info-label {
    flex-basis: 74px;
    font-size: .86rem;
    color: var(--text-secondary, #64748b);
  }

  body.ts-with-theme.ts-order-preview-body .info-value {
    font-size: .9rem;
    color: var(--text-primary, #0f172a);
  }

  body.ts-with-theme.ts-order-preview-body .info-value.money {
    color: #f02e2e;
    font-size: 1.05rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-strip {
    margin: 0 0 .7rem;
    padding: .72rem .82rem;
    gap: .65rem;
    border-radius: .5rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-icon {
    width: 23px;
    height: 23px;
    flex-basis: 23px;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-main strong {
    font-size: .9rem;
  }

  body.ts-with-theme.ts-order-preview-body .logistics-main span {
    font-size: .8rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-block {
    align-items: center;
    gap: 1rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-person {
    flex-basis: 150px;
  }

  body.ts-with-theme.ts-order-preview-body .address-person strong {
    font-size: .92rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-person span,
  body.ts-with-theme.ts-order-preview-body .address-remark {
    font-size: .78rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-text {
    font-size: .9rem;
    line-height: 1.5;
  }

  body.ts-with-theme.ts-order-preview-body .address-remark {
    margin-top: .45rem;
  }

  body.ts-with-theme.ts-order-preview-body .action-bar {
    position: static;
    justify-content: flex-end;
    gap: .75rem;
    margin: 0;
    padding: .9rem 1.25rem;
    background: var(--panel-bg, #fff);
    border-top: 1px solid var(--border, rgba(15, 23, 42, .08));
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
  }

  body.ts-with-theme.ts-order-preview-body .action-btn {
    min-width: 110px;
    height: 38px;
    border-radius: .45rem;
    font-size: .86rem;
  }
}

@media (min-width: 721px) and (max-width: 1120px) {
  body.ts-with-theme.ts-order-preview-body .order-content {
    grid-template-columns: 1fr;
  }

  body.ts-with-theme.ts-order-preview-body .status-panel,
  body.ts-with-theme.ts-order-preview-body .success-panel,
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(2),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(3),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(4),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    grid-column: 1;
    grid-row: auto;
  }

  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(3),
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(4) {
    padding-right: 0;
    padding-left: 0;
    border-left: 0;
  }
}

/* v0.111 PC订单详情收货信息归拢：姓名、手机、地址放在同一组，不左右拆开 */
@media (min-width: 721px) {
  body.ts-with-theme.ts-order-preview-body .order-content > .section:nth-of-type(5) {
    padding-top: .9rem;
    padding-bottom: .95rem;
  }

  body.ts-with-theme.ts-order-preview-body .address-block {
    display: block;
  }

  body.ts-with-theme.ts-order-preview-body .address-person {
    display: flex;
    align-items: baseline;
    gap: .7rem;
    flex-basis: auto;
    min-width: 0;
  }

  body.ts-with-theme.ts-order-preview-body .address-person strong {
    display: inline;
    font-size: .92rem;
    font-weight: 500;
  }

  body.ts-with-theme.ts-order-preview-body .address-person span {
    display: inline;
    margin-top: 0;
    font-size: .82rem;
    color: var(--text-secondary, #64748b);
  }

  body.ts-with-theme.ts-order-preview-body .address-text {
    margin: .35rem 0 0;
    max-width: 760px;
    text-align: left;
    font-size: .9rem;
    line-height: 1.55;
  }

  body.ts-with-theme.ts-order-preview-body .address-remark {
    margin-top: .35rem;
    text-align: left;
    font-size: .78rem;
  }
}

.ts-query-search button,
.ts-query-detail-btn,
.ts-query-card-head strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.ts-query-search button .ts-icon,
.ts-query-detail-btn .ts-icon,
.ts-query-card-head strong .ts-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}
.ts-query-card-head strong .ts-icon {
  color: currentColor;
}
.logistics-icon.ts-icon {
  display: inline-block;
  background-color: currentColor;
}
.success-icon .ts-icon,
.action-btn .ts-icon,
.ts-buy-safe .ts-icon,
.ts-buy-method-name .ts-icon,
.ts-buy-check {
  background-color: currentColor;
}

.back-link .ts-icon {
  width: 22px;
  height: 22px;
  background-color: currentColor;
}
.refresh-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
}
.refresh-btn .ts-icon {
  width: 15px;
  height: 15px;
  background-color: currentColor;
}
body.ts-order-preview-body .ts-detail-empty a {
  gap: 6px;
}
body.ts-order-preview-body .ts-detail-empty a .ts-icon {
  width: 17px;
  height: 17px;
  background-color: currentColor;
}
.tomshop-query-link,
.tomshop-buy-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tomshop-query-link .ts-icon,
.tomshop-buy-link .ts-icon {
  width: 16px;
  height: 16px;
  background-color: currentColor;
}


/* TomShop v0.444：插件前台旧 iPhone/Safari 图标文字间距统一兼容层。
   根因是旧 Safari 不支持 flex/inline-flex 的 gap；TomShop loader 会把图标后的裸文本统一包成 .ts-icon-text，
   这里集中处理所有插件前台“图标 + 文字”组合，禁止继续按单个截图零散补 margin。 */
.ts-no-flex-gap .tomshop-page .ts-icon + span,
.ts-no-flex-gap .tomshop-page .ts-icon + .ts-icon-text,
.ts-no-flex-gap .order-page .ts-icon + span,
.ts-no-flex-gap .order-page .ts-icon + .ts-icon-text {
  margin-left: 6px;
}
.ts-no-flex-gap .tomshop-page .ts-buy-safe .ts-icon + span,
.ts-no-flex-gap .tomshop-page .ts-buy-safe .ts-icon + .ts-icon-text {
  margin-left: 10px;
}
.ts-no-flex-gap .tomshop-page .ts-buy-method-name .ts-icon + span,
.ts-no-flex-gap .tomshop-page .ts-buy-method-name .ts-icon + .ts-icon-text {
  margin-left: 8px;
}
.ts-no-flex-gap .tomshop-page .ts-icon-text,
.ts-no-flex-gap .order-page .ts-icon-text {
  display: inline-block;
}

/* v0.151 插件前端移动端布局修复：订单查询/订单详情减少空白，底部按钮不换行 */
body.ts-with-theme.ts-query-body .neo-tomshop-main,
body.ts-with-theme.ts-order-preview-body .neo-tomshop-main {
  min-width: 0;
}

@media (max-width: 720px) {
  /* 移动端顶部栏是主题固定结构，neo-tomshop-main 的顶部避让交给主题 CSS 控制；这里不再把 padding-top 归零，避免订单查询标题被 mobile topbar 遮住。 */
  body.ts-with-theme.ts-query-body .neo-tomshop-page-shell,
  body.ts-with-theme.ts-order-preview-body .neo-tomshop-page-shell {
    width: 100%;
    padding: 0 0 12px;
  }

  body.ts-query-body[data-page="tomshop-query-static"] .ts-query-topbar {
    display: none;
  }

  body.ts-with-theme.ts-query-body .ts-query-shell {
    width: 100%;
    max-width: none;
    min-height: auto;
    background: #fff;
  }

  body.ts-with-theme.ts-query-body .ts-query-topbar {
    height: 52px;
  }

  body.ts-with-theme.ts-query-body .ts-query-topbar h1 {
    font-size: 20px;
    font-weight: 500;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero {
    padding: 24px 20px 20px;
  }

  body.ts-query-body[data-page="tomshop-query-static"] .ts-query-hero {
    padding-top: 22px;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero h2 {
    margin-bottom: 8px;
    font-size: 24px;
    line-height: 1.3;
    font-weight: 500;
  }

  body.ts-with-theme.ts-query-body .ts-query-hero p {
    margin-bottom: 16px;
    font-size: 15px;
    line-height: 1.6;
  }

  body.ts-with-theme.ts-query-body .ts-query-search {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  body.ts-with-theme.ts-query-body .ts-query-search input,
  body.ts-with-theme.ts-query-body .ts-query-search button {
    height: 52px;
    border-radius: 8px;
    font-size: 16px;
  }

  body.ts-with-theme.ts-query-body .ts-query-results {
    padding: 0 20px 22px;
  }

  body.ts-with-theme.ts-query-body .ts-query-order-card {
    padding: 18px 0;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head {
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head div {
    min-width: 0;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head em {
    flex: 0 0 auto;
    font-size: 13px;
  }

  body.ts-with-theme.ts-query-body .ts-query-goods-line {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
  }

  body.ts-with-theme.ts-query-body .ts-query-goods-img {
    width: 76px;
    height: 76px;
  }

  body.ts-with-theme.ts-query-body .ts-query-goods-img img {
    object-fit: contain;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-price {
    grid-column: 2;
    margin-top: 8px;
    font-size: 17px;
    text-align: left;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-meta {
    margin-top: 12px;
    gap: 6px;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-meta div {
    grid-template-columns: 74px minmax(0, 1fr);
  }

  body.ts-with-theme.ts-query-body .ts-query-detail-btn {
    width: 100%;
    height: 44px;
  }

  body.ts-order-preview-body .order-page {
    max-width: none;
  }

  body.ts-order-preview-body .order-header {
    height: 52px;
  }

  body.ts-order-preview-body .back-link {
    left: 8px;
    width: 38px;
    height: 38px;
  }

  body.ts-order-preview-body .back-link .ts-icon {
    display: inline-block;
  }

  body.ts-order-preview-body .header-title {
    font-size: 19px;
    font-weight: 500;
  }

  body.ts-order-preview-body .refresh-btn {
    right: 12px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    font-size: 15px;
    line-height: 1;
  }

  body.ts-order-preview-body .refresh-btn .ts-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
  }

  body.ts-order-preview-body .order-content {
    padding: 18px 18px 88px;
  }

  body.ts-order-preview-body .status-panel {
    padding: 4px 0 20px;
  }

  body.ts-order-preview-body .status-title {
    font-size: 22px;
    line-height: 1.35;
  }

  body.ts-order-preview-body .status-desc {
    font-size: 15px;
    line-height: 1.55;
  }

  body.ts-order-preview-body .section {
    padding: 20px 0;
  }

  body.ts-order-preview-body .section-head h2 {
    font-size: 18px;
  }

  body.ts-order-preview-body .goods-row {
    gap: 12px;
    align-items: center;
  }

  body.ts-order-preview-body .goods-thumb {
    width: 82px;
    height: 82px;
    flex-basis: 82px;
  }

  body.ts-order-preview-body .goods-thumb img {
    object-fit: contain;
  }

  body.ts-order-preview-body .goods-title {
    font-size: 16px;
    font-weight: 500;
  }

  body.ts-order-preview-body .goods-price {
    font-size: 16px;
  }

  body.ts-order-preview-body .info-label {
    flex-basis: 78px;
  }

  body.ts-order-preview-body .info-row.full {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 12px;
  }

  body.ts-order-preview-body .copy-line {
    display: flex;
    min-width: 0;
    justify-content: flex-end;
    gap: 8px;
  }

  body.ts-order-preview-body .copy-line > span {
    min-width: 0;
    word-break: break-all;
  }

  body.ts-order-preview-body .action-bar {
    gap: 8px;
    padding: 10px 10px calc(10px + env(safe-area-inset-bottom));
  }

  body.ts-order-preview-body .action-btn {
    flex: 1 1 0;
    min-width: 0;
    height: 44px;
    padding: 0 8px;
    gap: 5px;
    white-space: nowrap;
    line-height: 1.1;
    font-size: 15px;
  }

  body.ts-order-preview-body .action-btn span {
    display: inline-block;
    white-space: nowrap;
  }

  body.ts-order-preview-body .action-btn .ts-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
  }
}

@media (max-width: 420px) {
  body.ts-with-theme.ts-query-body .ts-query-hero {
    padding-right: 18px;
    padding-left: 18px;
  }

  body.ts-with-theme.ts-query-body .ts-query-results {
    padding-right: 18px;
    padding-left: 18px;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head {
    flex-wrap: wrap;
  }

  body.ts-with-theme.ts-query-body .ts-query-card-head em {
    margin-left: 28px;
  }
}

@media (max-width: 360px) {
  body.ts-order-preview-body .action-btn {
    padding: 0 5px;
    gap: 4px;
    font-size: 13px;
  }

  body.ts-order-preview-body .action-btn .ts-icon {
    width: 16px;
    height: 16px;
    flex-basis: 16px;
  }
}

/* v0.355：订单详情移动端顶部栏已经改为页面内普通标题；主题固定 mobile topbar 的顶部避让仍由主题 CSS 统一控制。 */
@media (max-width: 720px) {
  body.ts-with-theme.ts-order-preview-body .order-header {
    top: auto;
  }
}



/* v0.348：只处理手机端订单详情二级标题栏。订单详情/刷新保留显示，但取消 sticky，避免滚动时压住状态提示。 */
@media (max-width: 720px) {
  body.ts-with-theme.ts-order-preview-body .order-header {
    position: relative;
    top: auto;
    z-index: 1;
  }
}



/* v0.355：订单成功页/订单详情页顶部栏保持显示并取消 sticky，避免消失或滚动遮挡。 */
body.ts-with-theme.ts-order-preview-body .order-header {
  display: flex;
  position: relative;
  top: auto;
  z-index: 1;
}
/* v0.355：统一 PC/手机返回按钮，只显示模板中的 ts-icon-chevron-left。 */
body.ts-order-preview-body .back-link .ts-icon {
  display: inline-block;
}

/* TomShop v0.236：前台订单详情摘要排序与金额强调，只改展示层，不改订单数据。 */
.order-summary-grid .order-meta-row{
  grid-column:1 / -1;
}
.order-summary-grid .order-total-row{
  grid-column:1 / -1;
  align-items:center;
  min-height:54px;
  margin-top:9px;
  padding-top:14px;
  border-top:1px solid #eee;
}
.order-summary-grid .order-total-row .info-label{
  color:#444;
  font-size:15px;
}
.order-summary-grid .order-total-row .info-value.money{
  font-size:26px;
  font-weight:600;
  line-height:1.2;
  letter-spacing:.2px;
}
body.ts-with-theme.ts-order-preview-body .order-summary-grid .order-total-row{
  min-height:52px;
  margin-top:.55rem;
  padding-top:.8rem;
  border-top:1px solid var(--border, rgba(15, 23, 42, 0.08));
}
body.ts-with-theme.ts-order-preview-body .order-summary-grid .order-total-row .info-label{
  color:var(--text-primary, #0f172a);
  font-size:.95rem;
}
body.ts-with-theme.ts-order-preview-body .order-summary-grid .order-total-row .info-value.money{
  color:#f02e2e;
  font-size:1.55rem;
  font-weight:600;
}
@media (max-width:720px){
  .order-summary-grid .order-total-row{
    min-height:50px;
    margin-top:8px;
    padding-top:13px;
  }
  .order-summary-grid .order-total-row .info-value.money,
  body.ts-with-theme.ts-order-preview-body .order-summary-grid .order-total-row .info-value.money{
    font-size:25px;
  }
}
@media (max-width:360px){
  .order-summary-grid .order-total-row .info-value.money,
  body.ts-with-theme.ts-order-preview-body .order-summary-grid .order-total-row .info-value.money{
    font-size:23px;
  }
}


/* TomShop v0.266：前台通用提示 SVG 不写死颜色，成功/错误状态由 CSS 统一控制。 */
.ts-front-layer-msg {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 99999;
  transform: translate(-50%, -50%);
  min-width: 260px;
  max-width: calc(100vw - 40px);
  padding: 14px 22px;
  display: flex;
  align-items: center;
  gap: 0;
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 2px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .18);
  color: #333;
  cursor: pointer;
}
.ts-front-layer-msg strong {
  margin: 0;
  color: #333;
  font-size: 16px;
  line-height: 1.45;
  font-weight: 500;
}
.ts-front-layer-icon {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  color: #ff5722;
  margin-right: 14px;
  --ts-front-layer-icon-mark-color: #fff;
}
.ts-front-layer-success .ts-front-layer-icon {
  color: #11aa66;
}
.ts-front-layer-error .ts-front-layer-icon {
  color: #ff5722;
}
.ts-front-layer-icon svg {
  width: 36px;
  height: 36px;
  display: block;
  flex: 0 0 auto;
}
.ts-front-layer-icon-fill {
  fill: currentColor;
}
.ts-front-layer-icon-mark {
  fill: var(--ts-front-layer-icon-mark-color);
}
@media (max-width: 640px) {
  .ts-front-layer-msg {
    min-width: 0;
    width: calc(100vw - 48px);
    padding: 10px 16px;
  }
  .ts-front-layer-icon {
    width: 30px;
    height: 30px;
    margin-right: 14px;
  }
  .ts-front-layer-icon svg {
    width: 30px;
    height: 30px;
  }
}

/* TomShop v0.463：前台提交提示在 iOS 键盘场景下收窄高度，并使用 margin 兜底图标文字间距，避免旧 Safari 不支持 flex gap 时贴在一起。 */



/* TomShop v0.300：拖动时滑轨只让整体边框变蓝，进度层只做浅蓝填充，避免局部蓝边被滑块遮挡后看起来没显示完整。 */
.ts-guard-mask {
  position: fixed;
  z-index: 99998;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  padding: 0;
  margin: 0;
  pointer-events: none;
}
.ts-guard-mask * {
  box-sizing: content-box;
}
.ts-guard-mask #KgPuzzlePopup {
  touch-action: none;
  top: 50%;
  left: 50%;
  width: 320px;
  background: #FFF;
  border-radius: 4px;
  padding: 0 15px 15px 15px;
  margin: 0;
  transform: translate(-50%, -50%);
  transform-origin: center center;
  z-index: 10000;
  position: fixed;
  pointer-events: auto;
}
.ts-guard-mask #KgPuzzleTitle {
  height: 30px;
  border-bottom: 1px #CCC solid;
  margin: calc(15px / 2) 0;
}
.ts-guard-mask #KgPuzzleTitle ol {
  height: 30px;
  line-height: 30px;
  padding: 0;
  margin: 0;
  display: block;
}
.ts-guard-mask #KgPuzzleTitle ol:nth-child(1) {
  float: left;
  font-size: 16px;
  color: #333;
}
.ts-guard-mask #KgPuzzleTitle ol:nth-child(2) {
  float: right;
}
.ts-guard-mask #KgPuzzleTitle ol:nth-child(2) img {
  opacity: .5;
  width: 16px;
  cursor: pointer;
  border: 0;
}
.ts-guard-mask #KgPuzzleTitle ol:nth-child(2) img:hover {
  opacity: 1;
  border: 0;
}
.ts-guard-mask #KgBasemap *,
.ts-guard-mask #KgSlide * {
  padding: 0;
  margin: 0;
  user-select: none;
  box-sizing: content-box;
}
.ts-guard-mask #KgBasemap {
  position: relative;
  width: 320px;
  height: 180px;
  border-radius: 4px;
  overflow: hidden;
}
.ts-guard-mask #KgBasemap img:nth-child(1) {
  position: absolute;
  z-index: 1;
  left: 0;
  top: 0;
  width: 72px;
  height: 100%;
  border: 0;
}
.ts-guard-mask #KgBasemap img.ts-guard-piece {
  filter: drop-shadow(0 0 1px rgba(255,255,255,.95)) drop-shadow(0 0 3px rgba(255,255,255,.55)) drop-shadow(0 2px 4px rgba(15,23,42,.26));
}
.ts-guard-mask #KgBasemap img:nth-child(2),
.ts-guard-mask #KgBasemap a {
  position: absolute;
  z-index: 2;
  width: 75px;
  height: 15px;
  right: 10px;
  top: 5px;
  filter: alpha(opacity=0);
  opacity: 0;
  pointer-events: none;
  display: inline;
  background: none;
  border-radius: 0;
  border: 0;
}
.ts-guard-mask #KgBasemap a {
  background: #FFF;
  opacity: .01;
}
.ts-guard-mask #KgBasemap img:nth-child(3) {
  position: absolute;
  z-index: 3;
  width: 24px;
  height: 24px;
  right: 5px;
  bottom: 5px;
  cursor: pointer;
  border: 0;
}
.ts-guard-mask #KgInterval {
  clear: both;
  width: 100%;
  height: 15px;
}
.ts-guard-mask #KgSlide {
  position: relative;
  width: 318px;
  height: 43px;
  overflow: hidden;
  border: 1px #D2D2D2 solid;
  background: #F7F7F7;
  border-radius: 4px;
  box-sizing: content-box;
}
.ts-guard-mask #KgSlide div:nth-child(1) {
  position: absolute;
  z-index: 6;
  left: 0;
  top: 0;
  height: 43px;
  line-height: 43px;
  font-size: 14px;
  text-align: center;
  border-radius: 4px;
  display: none;
  width: 100%;
  box-sizing: border-box;
}
.ts-guard-mask #KgSlide div:nth-child(1) img {
  vertical-align: middle;
  height: 15px;
  width: 15px;
  border: 0;
}

.ts-guard-mask #KgSlide div:nth-child(1).ts-guard-slide-msg {
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  line-height: 1;
  min-height: 43px;
  padding: 0 14px;
  width: calc(100% - 28px);
  box-sizing: border-box;
  text-align: center;
}
.ts-guard-mask #KgSlide div:nth-child(1).ts-guard-slide-msg span {
  display: block;
  line-height: 1;
}
.ts-guard-mask #KgSlide div:nth-child(1).ts-guard-slide-msg img {
  display: block;
  flex: 0 0 auto;
  margin: 0;
}
.ts-guard-mask #KgSlide div:nth-child(2) {
  position: absolute;
  z-index: 1;
  width: 0;
  height: 43px;
  left: 0;
  top: 0;
  border-radius: 4px 0 0 4px;
  background: #d1e9fe;
  border: 0;
  display: none;
  box-sizing: border-box;
}
.ts-guard-mask #KgSlide div:nth-child(3) {
  position: absolute;
  z-index: 2;
  width: 50px;
  height: 43px;
  left: 0;
  top: 0;
  cursor: move;
  border-radius: 4px;
  border: 1px #D2D2D2 solid;
  background: #FFF center no-repeat;
  box-sizing: border-box;
}
.ts-guard-mask #KgSlide div:nth-child(4) {
  position: absolute;
  z-index: 3;
  pointer-events: none;
  width: 30px;
  height: 43px;
  animation: ai-arrow 1.5s infinite;
  background-image: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,.8), rgba(255,255,255,0));
}
.ts-guard-mask #KgSlide div:nth-child(5) {
  position: absolute;
  z-index: 4;
  pointer-events: none;
  width: 30px;
  height: 43px;
  animation: ai-strip 3.5s infinite;
  background-image: linear-gradient(to right, rgba(247,247,247,0), rgba(247,247,247,.4), rgba(247,247,247,0));
  left: 60px;
}
.ts-guard-mask #KgSlide div:nth-child(6) {
  position: relative;
  z-index: 0;
  overflow: hidden;
  text-shadow: 1px 1px 3px #F7F7F7, 0 0 3px #555555, 0 0 3px #F7F7F7;
  color: #555555;
  height: 43px;
  line-height: 43px;
  font-size: 14px;
  text-align: center;
  padding: 0 0 0 58px;
  width: calc(100% - 58px);
}
.ts-guard-mask #KgPuzzleBody {
  background: #000;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  opacity: .85;
  pointer-events: auto;
}
@keyframes ai-arrow {
  from { left: 0; }
  to { left: 28px; }
}
@keyframes ai-strip {
  from { left: 60px; }
  to { left: calc(318px - 32px); }
}
@keyframes ai-reset {
  to { left: -1px; }
}
@keyframes ai-rate {
  to { width: 0; }
}
@keyframes ai-goin {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes ai-fadein {
  from { opacity: .5; }
  to { opacity: 1; }
}
@keyframes ai-fadeout {
  from { opacity: 1; }
  to { opacity: .4; }
}
@keyframes ts-guard-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@media (max-width: 370px) {
  .ts-guard-mask #KgPuzzlePopup {
    transform: translate(-50%, -50%) scale(.92);
  }
}
@media (max-width: 350px) {
  .ts-guard-mask #KgPuzzlePopup {
    transform: translate(-50%, -50%) scale(.86);
  }
}

/* TomShop v0.423 商品按钮规则前台状态 */
[data-tomshop-buy].tomshop-buy-mode-contact{background:#14b8a6;}
[data-tomshop-buy].tomshop-buy-mode-contact:hover{background:#0f9f90;}
[data-tomshop-buy].tomshop-buy-mode-soldout{background:#9ca3af!important;cursor:pointer;pointer-events:auto;opacity:.88;}
[data-tomshop-buy].is-disabled{background:#9ca3af!important;cursor:not-allowed;pointer-events:auto;opacity:.88;}
[data-tomshop-buy].tomshop-buy-mode-soldout:hover,[data-tomshop-buy].is-disabled:hover{background:#9ca3af!important;}

/* TomShop v0.423 商品按钮规则加载保护 */
[data-tomshop-buy].tomshop-buy-mode-loading{cursor:wait;opacity:.72;pointer-events:auto;}
[data-tomshop-buy].tomshop-buy-mode-loading:hover{opacity:.82;}

/* TomShop v0.463：苹果端前台商品图文间距修复。
   下单页商品图、订单成功/查询详情商品图文布局不再依赖 flex gap，避免旧 iOS/Safari 图片和文字贴在一起。 */
.ts-buy-product {
  gap: 0;
}
.ts-buy-thumb {
  margin-right: 16px;
}
.ts-buy-product-content {
  gap: 0;
}
.ts-buy-product-side {
  margin-left: 16px;
}
.goods-row,
body.ts-order-preview-body .goods-row,
body.ts-with-theme.ts-order-preview-body .goods-row {
  gap: 0;
}
.goods-thumb,
body.ts-order-preview-body .goods-thumb,
body.ts-with-theme.ts-order-preview-body .goods-thumb {
  margin-right: 14px;
}
.goods-price,
body.ts-order-preview-body .goods-price,
body.ts-with-theme.ts-order-preview-body .goods-price {
  margin-left: 14px;
}
@media (max-width: 560px) {
  .ts-buy-thumb {
    margin-right: 12px;
  }
  .ts-buy-product-side {
    margin-left: 10px;
  }
}
@media (max-width: 720px) {
  .goods-thumb,
  body.ts-order-preview-body .goods-thumb,
  body.ts-with-theme.ts-order-preview-body .goods-thumb {
    margin-right: 12px;
  }
  .goods-price,
  body.ts-order-preview-body .goods-price,
  body.ts-with-theme.ts-order-preview-body .goods-price {
    margin-left: 12px;
  }
}
@media (max-width: 380px) {
  .ts-buy-product-side {
    margin-top: 10px;
    margin-left: 0;
  }
}


/* TomShop v1.24：付款方式选择统一使用红色选中态、白色背景，并规范手续费金额层级。 */
.ts-buy-delivery-row {
  margin-bottom: 12px;
}
.ts-buy-payment-title {
  margin-bottom: 8px;
  color: #374151;
  font-size: 14px;
  font-weight: 500;
}
.ts-buy-payment-options {
  display: grid;
  gap: 8px;
}
.ts-buy-payment-option {
  position: relative;
  display: grid;
  grid-template-columns: 18px 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease;
}
.ts-buy-payment-option:hover {
  border-color: #f02e2e;
}
.ts-buy-payment-option.is-selected {
  border-color: #f02e2e;
  background: #fff;
}
.ts-buy-payment-option > input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.ts-buy-payment-radio {
  position: relative;
  width: 16px;
  height: 16px;
  border: 1px solid #c7cbd1;
  border-radius: 50%;
  background: #fff;
}
.ts-buy-payment-option.is-selected .ts-buy-payment-radio {
  border-color: #f02e2e;
}
.ts-buy-payment-option.is-selected .ts-buy-payment-radio::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: #f02e2e;
}
.ts-buy-payment-option.is-selected .ts-buy-payment-icon {
  color: #f02e2e;
}
.ts-buy-payment-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #4b5563;
}
.ts-buy-payment-icon .ts-icon {
  width: 20px;
  height: 20px;
}
.ts-buy-payment-copy {
  min-width: 0;
}
.ts-buy-payment-copy strong,
.ts-buy-payment-copy small {
  display: block;
}
.ts-buy-payment-copy strong {
  color: #1f2933;
  font-size: 15px;
  line-height: 1.4;
  font-weight: 500;
}
.ts-buy-payment-copy small {
  margin-top: 2px;
  overflow: hidden;
  color: #7b818a;
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ts-buy-payment-fee,
.ts-buy-adjustment-value,
.ts-payment-adjustment-value {
  display: inline-flex;
  align-items: baseline;
  color: #f02e2e;
  white-space: nowrap;
}
.ts-buy-payment-fee {
  font-size: 13px;
}
.ts-buy-payment-fee .ts-money-symbol,
.ts-buy-adjustment-value .ts-money-symbol,
.ts-payment-adjustment-value .ts-money-symbol {
  margin-right: 1px;
  font-size: .76em;
  line-height: 1;
}
.ts-buy-payment-fee .ts-money-minus,
.ts-buy-adjustment-value .ts-money-minus,
.ts-payment-adjustment-value .ts-money-minus {
  font-size: 1em;
  line-height: 1;
}
.ts-buy-payment-fee .ts-money-number,
.ts-buy-adjustment-value .ts-money-number,
.ts-payment-adjustment-value .ts-money-number {
  font-size: 1em;
  line-height: inherit;
}
.ts-buy-adjustment-row[hidden] {
  display: none;
}
/* TomShop v1.27：手续费行与应付金额之间只保留一条分隔线；去掉手续费行自身的底边线。 */
.ts-buy-adjustment-row {
  margin-top: -12px;
  margin-bottom: 18px;
  border-bottom: 0;
}
.ts-buy-adjustment-row strong {
  color: #f02e2e;
}
@media (max-width: 560px) {
  .ts-buy-payment-option {
    grid-template-columns: 18px 20px minmax(0, 1fr) auto;
    gap: 8px;
    min-height: 56px;
    padding: 9px 10px;
  }
  .ts-buy-payment-copy small {
    white-space: normal;
  }
}

/* TomShop v1.28：独立在线支付确认页。 */
.ts-payment-body {
  margin: 0;
  background: #f5f6f8;
  color: #1f2933;
}
.ts-payment-page {
  width: min(560px, calc(100% - 32px));
  margin: 42px auto 80px;
}
.ts-payment-card {
  padding: 28px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.ts-payment-head {
  display: flex;
  align-items: center;
  margin-bottom: 24px;
}
.ts-payment-head-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: 14px;
  border-radius: 50%;
  color: #f02e2e;
  background: #fff1f1;
}
.ts-payment-head-icon .ts-icon { width: 24px; height: 24px; }
.ts-payment-head h1 { margin: 0; font-size: 22px; line-height: 1.35; font-weight: 500; }
.ts-payment-head p { margin: 4px 0 0; color: #7b818a; font-size: 14px; }
.ts-payment-order {
  border-top: 1px solid #eceff2;
  border-bottom: 1px solid #eceff2;
  padding: 16px 0;
}
.ts-payment-order > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  min-height: 34px;
}
.ts-payment-order span { color: #68707a; font-size: 14px; }
.ts-payment-order strong { color: #1f2933; font-size: 15px; font-weight: 500; word-break: break-all; text-align: right; }
.ts-payment-order .ts-payment-amount { color: #f02e2e; font-size: 28px; font-weight: 600; }
.ts-payment-order .ts-payment-amount small { margin-right: 2px; font-size: .58em; font-weight: 500; }
.ts-payment-qr-wrap { padding: 26px 0 10px; text-align: center; }
.ts-payment-qr { width: 210px; height: 210px; max-width: 72vw; object-fit: contain; }
.ts-payment-qr-wrap p { margin: 10px 0 0; color: #5f6670; font-size: 14px; }
.ts-payment-message {
  margin-top: 20px;
  padding: 12px 14px;
  border-radius: 4px;
  color: #5f6670;
  background: #f5f6f8;
  font-size: 14px;
  text-align: center;
}
.ts-payment-message.is-error { color: #b42318; background: #fff1f0; }
.ts-payment-message.is-success { color: #067647; background: #ecfdf3; }
.ts-payment-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 20px; }
.ts-payment-actions a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #d9dde3;
  border-radius: 4px;
  color: #374151;
  background: #fff;
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
}
.ts-payment-actions .ts-payment-primary { border-color: #f02e2e; color: #fff; background: #f02e2e; }
.ts-payment-tip { margin: 14px 0 0; color: #8a9099; font-size: 12px; line-height: 1.6; text-align: center; }
.ts-order-pay-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  border-radius: 4px;
  color: #fff;
  background: #f02e2e;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
}
@media (max-width: 560px) {
  .ts-payment-page { width: calc(100% - 24px); margin: 20px auto 60px; }
  .ts-payment-card { padding: 20px 16px; }
  .ts-payment-head h1 { font-size: 19px; }
  .ts-payment-order > div { gap: 12px; }
  .ts-payment-actions { grid-template-columns: 1fr; }
}
