/* OnePw public storefront: shared foundations for catalog, payment and account pages. */
.brand-page {
  color-scheme: light;
  --brand-paper: #f6f6f5;
  --brand-surface: #fff;
  --brand-ink: #202225;
  --brand-muted: #696d74;
  --brand-line: #dedfe2;
  --brand-accent: #232528;
  --brand-accent-hover: #3c3f44;
  --brand-tint: #eeeef0;
  --brand-body: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --brand-display: var(--brand-body);
  --brand-numerals: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --radius-panel: 20px;
  --radius-card: 16px;
  --radius-control: 10px;
  --radius-tag: 5px;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  margin: 0;
  background: var(--brand-paper);
  color: var(--brand-ink);
  font: 400 15px/1.65 var(--brand-body);
  overflow-wrap: anywhere;
}
.brand-page *, .brand-page *::before, .brand-page *::after { box-sizing: border-box; }
.brand-page :where(main, section, article, form, div, span, button, a) { min-width: 0; }
.brand-page :where(h1, h2, h3, p, ol) { margin: 0; }
.brand-page :where(h1, h2, h3, strong, b) { font-weight: 600; }
.brand-page :where(input, button, textarea, select) { font: inherit; }
.brand-page a { color: inherit; text-decoration: none; }
.brand-page img { display: block; max-width: 100%; }
.brand-page :where(button, a, input, summary):focus-visible { outline: 3px solid #727986; outline-offset: 4px; }
.brand-page :where([id]) { scroll-margin-top: 100px; }
.brand-page ::selection { background: #d8dbe1; color: #202225; }
.brand-page .sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.brand-page .skip-link { position: fixed; top: -100px; left: 16px; z-index: 40; padding: 10px 16px; border-radius: var(--radius-control); background: var(--brand-ink); color: #fff; }
.brand-page .skip-link:focus { top: 10px; }
.brand-page .clipboard-fallback-input { position: fixed; left: -9999px; top: 0; opacity: 0; pointer-events: none; }

/* Navigation and page rhythm. */
.brand-page .topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  width: 100%; min-height: 76px;
  padding: 14px max(24px, calc((100% - 1120px) / 2));
  border-bottom: 1px solid var(--brand-line); background: var(--brand-paper);
}
.brand-page .brand { display: inline-flex; align-items: center; flex-shrink: 0; gap: 8px; font-size: 24px; line-height: 1.2; font-weight: 600; letter-spacing: -.8px; }
.brand-page .brand__mark { order: 2; align-self: end; width: 6px; height: 6px; margin-bottom: 5px; border-radius: 50%; background: #797d84; }
.brand-page .nav { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.brand-page .nav a { display: grid; place-items: center; min-height: 44px; padding: 8px 14px; border-radius: 8px; color: var(--brand-muted); font-size: 13px; transition: color 150ms, background 150ms; }
.brand-page .nav a:hover { color: var(--brand-ink); background: var(--brand-tint); }
.brand-page .nav a[aria-current="page"] { color: var(--brand-ink); font-weight: 600; }
.brand-page main { flex: 1; width: min(1120px, calc(100% - 48px)); margin: 0 auto; padding: 0 0 64px; }
.brand-page .page-intro { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding: 44px 0 28px; }
.brand-page .page-intro__layout { display: grid; gap: 10px; }
.brand-page .page-intro h1 { font-size: clamp(28px, 3vw, 36px); line-height: 1.35; letter-spacing: -.035em; font-weight: 500; }
.brand-page .page-intro p { color: var(--brand-muted); font-size: 14px; }
.brand-page .brand-page-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; width: min(1120px, calc(100% - 48px)); margin: 0 auto; padding: 24px 0; border-top: 1px solid var(--brand-line); color: var(--brand-muted); font-size: 12px; }
.brand-page .brand-page-footer a:hover { color: var(--brand-ink); }

/* Shared controls. */
.brand-page .primary, .brand-page .secondary, .brand-page .compact-btn, .brand-page .copy-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-width: 0; min-height: 44px; max-width: 100%;
  border: 1px solid var(--brand-line); border-radius: var(--radius-control);
  background: var(--brand-surface); padding: 10px 18px; color: var(--brand-ink);
  font-size: 14px; line-height: 1.5; font-weight: 500; text-align: center; white-space: normal;
  cursor: pointer; transition: background 150ms, border-color 150ms;
}
.brand-page .primary { border-color: var(--brand-accent); background: var(--brand-accent); color: #fff; }
.brand-page .primary:hover { border-color: var(--brand-accent-hover); background: var(--brand-accent-hover); }
.brand-page .secondary:hover, .brand-page .compact-btn:hover, .brand-page .copy-btn:hover { background: var(--brand-tint); border-color: #b9bcc2; }
.brand-page button:disabled { opacity: .45; cursor: not-allowed; }
.brand-page .field { display: grid; gap: 9px; }
.brand-page .field > span { font-size: 13px; font-weight: 500; }
.brand-page .field input { width: 100%; min-width: 0; min-height: 46px; border: 1px solid var(--brand-line); border-radius: var(--radius-control); background: var(--brand-surface); padding: 11px 13px; color: var(--brand-ink); font-size: 16px; line-height: 1.5; }
.brand-page .field input::placeholder { color: var(--brand-muted); opacity: 1; }
.brand-page .field input:focus { border-color: #888e98; }
.brand-page .field input.is-invalid { border-color: #b42318; }
.brand-page .field-hint { color: var(--brand-muted); font-size: 12px; }
.brand-page .form-error { border: 1px solid #efcfcb; border-radius: var(--radius-control); background: #fff4f2; color: #a3251c; padding: 10px 12px; font-size: 13px; }
.brand-page .success-toast { position: fixed; z-index: 30; left: 50%; bottom: 28px; transform: translateX(-50%); max-width: calc(100% - 32px); padding: 12px 22px; border: 1px solid var(--brand-line); border-radius: var(--radius-control); background: var(--brand-accent); color: #fff; box-shadow: 0 8px 30px #20222518; font-size: 14px; }

/* Catalog and checkout, from the first category to the final selection. */
.brand-page .checkout-panel { width: 100%; }
.brand-page .purchase-path { display: flex; flex-wrap: wrap; gap: 24px; padding: 0; list-style: none; color: var(--brand-muted); font-size: 12px; }
.brand-page .purchase-path li { display: flex; align-items: center; gap: 8px; }
.brand-page .purchase-path span { display: grid; place-items: center; width: 25px; height: 25px; border: 1px solid var(--brand-line); border-radius: 50%; font: 400 11px/1 var(--brand-numerals); }
.brand-page .purchase-path [aria-current="step"] { color: var(--brand-ink); font-weight: 500; }
.brand-page .purchase-path [aria-current="step"] span { border-color: var(--brand-ink); background: var(--brand-ink); color: #fff; }
.checkout-page .quick-form { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: 32px; }
.checkout-page .quick-form:has(.checkout-details:not(.hidden)) { grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); }
.checkout-page .product-picker, .checkout-page .product-panel { display: grid; gap: 18px; }
.checkout-page .series-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 18px; }
.checkout-page .series-list:empty { display: none; }
.checkout-page .product-picker.is-series-mode > .product-line-list,
.checkout-page .product-picker.is-detail-mode > .series-list,
.checkout-page .product-picker:not(.is-series-mode):not(.is-detail-mode) > #seriesOptions { display: none; }
.checkout-page .product-line-card, .checkout-page .series-tab, .checkout-page .spec-item {
  display: grid; align-items: center; gap: 22px; width: 100%; min-height: 0; margin: 0; padding: 26px;
  border: 1px solid var(--brand-line); border-radius: var(--radius-card);
  background: var(--brand-surface); color: var(--brand-ink); text-align: left;
  cursor: pointer; transition: border-color 150ms, background 150ms;
}
.checkout-page .product-line-card:hover, .checkout-page .series-tab:hover, .checkout-page .spec-item:hover { border-color: #8d929b; }
.checkout-page .product-line-card { min-height: 220px; align-content: space-between; }
.checkout-page .product-line-card:first-child { background: var(--brand-accent); border-color: var(--brand-accent); color: #fff; }
.checkout-page .product-line-card:first-child:hover { background: var(--brand-accent-hover); }
.checkout-page .series-card__media { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--brand-tint); color: var(--brand-ink); overflow: hidden; }
.checkout-page .series-card__media img { width: 100%; height: 100%; object-fit: cover; }
.checkout-page .series-card__media b { font-size: 23px; font-weight: 500; }
.checkout-page .product-line-card:first-child .series-card__media { background: #ffffff14; color: #fff; }
.checkout-page .series-card__copy, .checkout-page .series-tab__copy, .checkout-page .spec-copy { display: grid; gap: 8px; }
.checkout-page .series-card__copy b, .checkout-page .series-tab__copy b, .checkout-page .spec-copy b { font-size: 20px; line-height: 1.5; font-weight: 500; }
.checkout-page .product-line-card > strong { justify-self: end; font-size: 13px; font-weight: 400; }
.checkout-page .product-line-list:has(> :only-child) .product-line-card { grid-template-columns: 64px minmax(0, 1fr) auto; min-height: 152px; }
.checkout-page .series-tab small, .checkout-page .spec-copy small { color: var(--brand-muted); font-size: 12px; font-weight: 400; line-height: 1.6; }
.checkout-page .series-tab__meta, .checkout-page .spec-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.checkout-page .series-tab__meta strong, .checkout-page .spec-meta strong { font: 500 25px/1.4 var(--brand-numerals); font-variant-numeric: tabular-nums; }
.checkout-page .series-tab__action, .checkout-page .spec-action { display: inline-flex; align-items: center; justify-content: center; justify-self: start; min-height: 32px; border-radius: 7px; background: var(--brand-tint); padding: 5px 12px; font-size: 12px; font-style: normal; line-height: 1.5; }
.checkout-page #productOptions { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.checkout-page .spec-item { grid-template-columns: minmax(0, 1fr) auto; gap: 14px 18px; padding: 18px 20px; border-radius: 12px; }
.checkout-page .spec-item.is-selected, .checkout-page .series-tab.is-selected { border-color: var(--brand-accent); box-shadow: inset 0 0 0 1px var(--brand-accent); background: var(--brand-surface); }
.checkout-page .spec-copy { grid-column: 1; grid-row: 1; gap: 6px; }
.checkout-page .spec-copy b { font-size: 18px; }
.checkout-page .spec-meta { grid-column: 2; grid-row: 1; justify-content: end; align-items: center; gap: 16px; }
.checkout-page .spec-meta strong { font-size: 22px; }
.checkout-page .spec-check { display: grid; place-items: center; flex-shrink: 0; width: 18px; height: 18px; border: 1px solid #b9bdc5; border-radius: 5px; font-size: 12px; line-height: 1; }
.checkout-page .is-selected .spec-check { border-color: var(--brand-accent); background: var(--brand-accent); color: #fff; }
.checkout-page .spec-chip-row { display: flex; flex-wrap: wrap; gap: 5px 10px; }
.checkout-page .spec-chip { padding: 0; font-size: 11px; }
.checkout-page .series-nav:not(.hidden), .checkout-page .product-panel__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 5px; }
.checkout-page .product-panel__head > div { display: grid; gap: 3px; text-align: right; }
.checkout-page .product-panel__head span { font-size: 17px; font-weight: 500; }
.checkout-page .product-panel__head small { color: var(--brand-muted); font-size: 12px; }
.checkout-page .checkout-entry { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-bottom: 24px; color: var(--brand-muted); font-size: 12px; }
.checkout-page .checkout-entry strong { color: var(--brand-ink); font-size: 13px; font-weight: 400; }
.checkout-page .checkout-entry small { font-size: 12px; }
.checkout-page .checkout-entry__eyebrow { display: none; }
.checkout-page .checkout-order { position: sticky; top: 100px; border: 1px solid var(--brand-line); border-radius: 16px; background: var(--brand-surface); }
.checkout-page .checkout-details { display: grid; gap: 20px; padding: 26px; }
.checkout-page .checkout-details__title { font-size: 17px; font-weight: 500; }
.checkout-page .contact-field-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.checkout-page .contact-field-head label { font-size: 13px; font-weight: 500; }
.checkout-page .checkout-extras { display: grid; gap: 0; border-top: 1px solid var(--brand-line); }
.checkout-page .checkout-extras summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 44px; color: var(--brand-muted); font-size: 12px; cursor: pointer; list-style: none; }
.checkout-page .checkout-extras summary::-webkit-details-marker { display: none; }
.checkout-page .checkout-extras summary::after { content: "+"; font: 400 17px/1 var(--brand-numerals); }
.checkout-page .checkout-extras details[open] > summary::after { content: "−"; }
.checkout-page .checkout-extras .field, .checkout-page .checkout-extras .customer-login-panel { margin: 4px 0 14px; }
.checkout-page .checkout-extras .customer-login-panel { padding: 0; border: 0; gap: 10px; }
.checkout-page .checkout-submit { display: grid; gap: 16px; padding: 22px 26px; border-top: 1px solid var(--brand-line); }
.checkout-page .checkout-total { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px; }
.checkout-page .checkout-total small { font-size: 12px; color: var(--brand-muted); }
.checkout-page .checkout-total strong { font: 500 30px/1.3 var(--brand-numerals); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.checkout-page .selected-product-info summary { min-height: 36px; color: var(--brand-muted); font-size: 12px; cursor: pointer; }
.checkout-page .selected-product-info section { padding: 12px 0; }
.checkout-page .selected-product-info h3 { margin-bottom: 8px; font-size: 13px; font-weight: 500; }
.checkout-page .selected-product-info p { margin: 6px 0; color: var(--brand-muted); font-size: 13px; white-space: pre-wrap; }
.checkout-page .contact-type { display: flex; gap: 7px; }
.checkout-page .contact-type button { min-height: 32px; padding: 3px 10px; border: 1px solid var(--brand-line); border-radius: 7px; background: var(--brand-surface); color: var(--brand-muted); font-size: 12px; cursor: pointer; }
.checkout-page .contact-type button.is-selected { border-color: var(--brand-ink); background: var(--brand-tint); color: var(--brand-ink); }
.brand-page .buy-cta { justify-content: space-between; width: 100%; }
.brand-page .buy-cta svg { width: 26px; height: 12px; fill: currentColor; flex-shrink: 0; }
.checkout-page .series-card--loading { display: grid; gap: 24px; min-height: 200px; border: 1px solid var(--brand-line); border-radius: var(--radius-card); background: var(--brand-surface); padding: 26px; }
.checkout-page .series-card--loading > span, .checkout-page .series-card--loading > div { height: 32px; border-radius: 7px; background: var(--brand-tint); }
.checkout-page .series-empty, .checkout-page .catalog-load-error { grid-column: 1 / -1; display: grid; place-items: center; gap: 16px; min-height: 200px; padding: 24px; border: 1px solid var(--brand-line); border-radius: var(--radius-card); background: var(--brand-surface); color: var(--brand-muted); }

/* Identity, query and referrals. */
.brand-page .customer-login-panel { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 16px; padding-bottom: 22px; border-bottom: 1px solid var(--brand-line); }
.brand-page .customer-login-panel__copy { display: grid; gap: 4px; }
.brand-page .customer-login-panel__copy span { font-size: 14px; font-weight: 500; }
.brand-page .customer-login-panel__copy small { color: var(--brand-muted); font-size: 12px; }
.brand-page .customer-login-panel__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.brand-page .customer-login-qr { grid-column: 1 / -1; width: min(100%, 220px); padding: 8px; border: 1px solid var(--brand-line); border-radius: 12px; background: #fff; }
.brand-page .customer-login-qr img { width: 100%; }
.checkout-page .customer-login-panel { grid-template-columns: minmax(0, 1fr); }
.query-brand-page main, .referral-brand-page main { max-width: 800px; }
.brand-page .query-panel { padding: 32px; border: 1px solid var(--brand-line); border-radius: var(--radius-panel); background: var(--brand-surface); }
.brand-page .query-panel .quick-form { display: grid; gap: 22px; }
.brand-page .query-divider { display: flex; align-items: center; gap: 14px; margin: 24px 0; color: var(--brand-muted); font-size: 12px; }
.brand-page .query-divider::after { content: ""; flex: 1; border-top: 1px solid var(--brand-line); }
.brand-page .query-result { display: grid; gap: 14px; margin-top: 28px; }
.brand-page .query-result:empty { display: none; }
.brand-page .query-empty { padding: 24px; border-radius: 12px; background: var(--brand-paper); color: var(--brand-muted); font-size: 14px; text-align: center; }
.brand-page .query-card { display: grid; border: 1px solid var(--brand-line); border-radius: var(--radius-card); background: var(--brand-surface); overflow: hidden; }
.brand-page .query-card__summary { display: grid; gap: 16px; width: 100%; padding: 24px; border: 0; background: var(--brand-surface); color: var(--brand-ink); font: inherit; text-align: left; }
.brand-page .query-card__summary .delivery-head { align-items: start; }
.brand-page .query-card__summary-subject { flex: 1; min-width: min(100%, 160px); }
.brand-page .query-card__summary .delivery-head b { flex-shrink: 0; }
.brand-page .query-card__content { display: grid; gap: 16px; padding: 0 24px 22px; }
.brand-page .query-order-details { border-top: 1px solid var(--brand-line); padding: 0 24px; }
.brand-page .query-order-details > summary { min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 16px; list-style: none; color: var(--brand-muted); font-size: 12px; cursor: pointer; }
.brand-page .query-order-details > summary::-webkit-details-marker { display: none; }
.brand-page .query-order-details > summary::after { content: "+"; font: 400 17px/1 var(--brand-numerals); }
.brand-page .query-order-details[open] > summary::after { content: "−"; }
.brand-page .query-order-details > summary:focus-visible { outline-offset: -4px; }
.brand-page .query-order-details .delivery-meta { padding: 8px 0 22px; }
.brand-page .delivery-head .query-status--neutral { color: var(--brand-muted); background: var(--brand-tint); }
.referral-brand-page #referralForm { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
.referral-brand-page #referralError { grid-column: 1 / -1; grid-row: 2; }
.referral-brand-page #referralBtn { min-height: 48px; }
.brand-page .referral-card { gap: 24px; border: 0; padding-top: 24px; border-top: 1px solid var(--brand-line); border-radius: 0; }
.brand-page .referral-code-box { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 24px; border-radius: 14px; background: var(--brand-paper); }
.brand-page .referral-code-box small { grid-column: 1 / -1; color: var(--brand-muted); font-size: 12px; }
.brand-page .referral-code-box strong { font: 500 48px/1.2 var(--brand-numerals); letter-spacing: .06em; }
.brand-page .referral-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.brand-page .referral-stats div { display: grid; gap: 8px; padding-bottom: 18px; border-bottom: 1px solid var(--brand-line); }
.brand-page .referral-stats small, .brand-page .referral-rewards small { color: var(--brand-muted); font-size: 12px; }
.brand-page .referral-stats b { font-size: 20px; font-weight: 500; }
.brand-page .referral-rewards { display: grid; gap: 12px; }
.brand-page .referral-rewards div { display: grid; gap: 4px; padding: 12px 0; }
.brand-page .referral-rewards p { color: var(--brand-muted); font-size: 13px; }

/* Payment keeps the amount, current state and QR in a single readable panel. */
.order-brand-page main { max-width: 1000px; padding-top: 48px; }
.order-brand-page .pay-box { display: grid; gap: 24px; }
.order-brand-page .pay-box__main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 310px); align-items: start; gap: 36px; padding: 36px; border: 1px solid var(--brand-line); border-radius: var(--radius-panel); background: var(--brand-surface); }
.order-brand-page .order-summary::before { content: "订单支付"; display: block; margin-bottom: 22px; color: var(--brand-muted); font-size: 12px; }
.order-brand-page #orderTitle { margin-bottom: 20px; font-size: 27px; line-height: 1.45; letter-spacing: -.03em; font-weight: 500; }
.order-brand-page #orderMeta { margin-bottom: 22px; color: var(--brand-muted); font-size: 13px; white-space: pre-line; }
.order-brand-page .payment-notice { margin-bottom: 20px; border-radius: var(--radius-control); background: var(--brand-paper); padding: 13px 15px; color: #525963; font-size: 13px; }
.order-brand-page .order-next-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.order-brand-page .cashier-shell { display: grid; gap: 18px; padding-left: 30px; border-left: 1px solid var(--brand-line); }
.order-brand-page .cashier-status { display: grid; justify-items: center; gap: 5px; text-align: center; }
.order-brand-page .cashier-status > strong { font-size: 21px; font-weight: 500; }
.order-brand-page .cashier-status small { color: var(--brand-muted); font-size: 12px; }
.order-brand-page .cashier-topline { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px; padding-top: 18px; border-top: 1px solid var(--brand-line); }
.order-brand-page .cashier-topline span { color: var(--brand-muted); font-size: 13px; }
.order-brand-page .cashier-topline b { font: 500 30px/1.3 var(--brand-numerals); letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
.order-brand-page .qr-wrap { display: grid; place-items: center; width: min(100%, 260px); aspect-ratio: 1; margin: 0 auto; padding: 12px; border: 1px solid var(--brand-line); border-radius: 14px; background: #fff; }
.order-brand-page .qr-wrap img { width: 100%; height: auto; object-fit: contain; }
.order-brand-page .qr-caption { color: var(--brand-muted); font-size: 12px; text-align: center; }
.order-brand-page .qr-actions { display: grid; gap: 12px; }
.order-brand-page .qr-actions small { color: var(--brand-muted); font-size: 12px; }
.order-brand-page .order-controls { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-top: 22px; border-top: 1px solid var(--brand-line); }
.order-brand-page .status-box { display: contents; }
.order-brand-page .order-loading { margin-bottom: 16px; color: var(--brand-muted); font-size: 14px; }
.order-brand-page:not(.order-loading-view) .order-loading,
.order-brand-page.order-loading-view .cashier-shell,
.order-brand-page.order-invalid-view .cashier-shell,
.order-brand-page.order-invalid-view #refreshOrderBtn,
.order-brand-page.order-delivered-view .cashier-shell { display: none; }
.order-brand-page.order-loading-view .pay-box__main,
.order-brand-page.order-invalid-view .pay-box__main,
.order-brand-page.order-delivered-view .pay-box__main { grid-template-columns: minmax(0, 1fr); }
.order-brand-page.order-delivered-view .pay-box__main { gap: 0; padding: 0; border: 0; background: transparent; }
.order-brand-page.order-delivered-view .order-summary::before { content: "订单结果"; }
.order-brand-page.order-delivered-view .payment-notice { padding: 0; color: #32634a; }
.order-brand-page.order-delivered-view .order-controls { padding: 0; border: 0; }
.order-brand-page .card-result { display: grid; gap: 22px; width: 100%; padding: 32px; border: 1px solid var(--brand-line); border-radius: var(--radius-panel); background: var(--brand-surface); }

/* Automatic credentials and manual service progress share the same components. */
.brand-page .delivery-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; }
.brand-page .delivery-head > span { color: var(--brand-muted); font-size: 12px; }
.brand-page .delivery-head b { border-radius: 6px; padding: 4px 8px; color: #32634a; background: #edf4ee; font-size: 12px; font-weight: 500; }
.brand-page .delivery-subject { color: var(--brand-ink); font-size: 20px; font-weight: 500; line-height: 1.5; }
.brand-page .delivery-service-note { color: var(--brand-muted); font-size: 13px; }
.brand-page .delivery-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr)); gap: 18px; }
.brand-page .delivery-meta > span { display: grid; align-content: start; gap: 6px; }
.brand-page .delivery-meta small { color: var(--brand-muted); font-size: 11px; }
.brand-page .delivery-meta b { font-size: 12px; font-weight: 400; }
.brand-page .delivery-bundle { display: grid; gap: 16px; }
.brand-page .delivery-code { display: grid; gap: 12px; padding: 18px; border: 1px solid var(--brand-line); border-radius: 12px; background: var(--brand-paper); }
.brand-page .delivery-code small { color: var(--brand-muted); font-size: 12px; }
.brand-page .delivery-code__line { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; }
.brand-page .delivery-code code, .brand-page .card-result > code { min-width: 0; max-width: 100%; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--brand-ink); font: 400 16px/1.6 ui-monospace, SFMono-Regular, Consolas, monospace; }
.brand-page .delivery-code.is-used code { color: var(--brand-muted); }
.brand-page .delivery-target { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 16px; padding: 16px; border-radius: 10px; background: var(--brand-tint); }
.brand-page .delivery-target > div { display: grid; gap: 6px; }
.brand-page .delivery-target small { color: var(--brand-muted); font-size: 12px; }
.brand-page .delivery-target span { font-size: 13px; }
.brand-page .user-progress-notice b { font-size: 12px; font-weight: 500; }
.brand-page .notice-success { background: #edf4ee; }
.brand-page .notice-warning { background: #faf3e8; }
.brand-page .item-progress-note { border-radius: 8px; background: var(--brand-tint); padding: 10px; color: var(--brand-muted); font-size: 12px; }
.brand-page .item-progress-note.notice-success { background: #edf4ee; }
.brand-page .item-progress-note.notice-warning { background: #faf3e8; }
.brand-page .service-progress__steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 8px 0 0; padding: 0; list-style: none; }
.brand-page .service-progress__steps li { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 7px; color: var(--brand-muted); }
.brand-page .service-progress__steps i { width: 7px; height: 7px; border-radius: 50%; background: #c7c9ce; }
.brand-page .service-progress__steps b { font-size: 12px; font-weight: 400; }
.brand-page .service-progress__steps .is-done { color: #32634a; }
.brand-page .service-progress__steps .is-done i { background: #668c72; }
.brand-page .service-progress__steps .is-active { color: var(--brand-ink); }
.brand-page .service-progress__steps .is-active i { background: var(--brand-ink); }

@media (max-width: 800px) {
  .checkout-page .quick-form:has(.checkout-details:not(.hidden)) { grid-template-columns: minmax(0, 1fr); }
  .checkout-page .checkout-order { position: static; }
  .checkout-page.checkout-has-selection { padding-bottom: calc(100px + env(safe-area-inset-bottom)); }
  .checkout-page .checkout-submit { position: fixed; z-index: 15; bottom: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px max(20px, calc((100% - 600px) / 2)) calc(14px + env(safe-area-inset-bottom)); background: var(--brand-surface); box-shadow: 0 -5px 24px #20222508; }
  .checkout-page .checkout-total { display: grid; gap: 2px; }
  .checkout-page .checkout-total strong { font-size: 26px; }
  .checkout-page .checkout-submit .buy-cta { width: min(50%, 210px); min-height: 48px; }
  .checkout-page :is(input, summary) { scroll-margin-bottom: 120px; }
  .order-brand-page .pay-box__main { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .order-brand-page .cashier-shell { width: min(100%, 340px); margin: 0 auto; padding: 24px 0 0; border-left: 0; border-top: 1px solid var(--brand-line); }
}
@media (max-width: 540px) {
  .brand-page .topbar { min-height: 68px; gap: 12px; padding: 10px 20px; }
  .brand-page .brand { font-size: 22px; }
  .brand-page .nav { gap: 0; }
  .brand-page .nav a { padding: 8px 9px; font-size: 12px; }
  .brand-page main { width: calc(100% - 40px); padding-bottom: 40px; }
  .brand-page .page-intro { padding: 30px 0 24px; gap: 18px; }
  .brand-page .brand-page-footer { width: calc(100% - 40px); padding: 22px 0; }
  .brand-page .purchase-path { width: 100%; justify-content: space-between; gap: 12px; }
  .checkout-page .quick-form { gap: 24px; }
  .checkout-page .product-line-list:has(> :only-child) .product-line-card { grid-template-columns: 48px minmax(0, 1fr); min-height: 148px; padding: 22px; }
  .checkout-page .product-line-list:has(> :only-child) .product-line-card > strong { grid-column: 2; justify-self: start; }
  .checkout-page .checkout-entry { margin-bottom: 20px; }
  .checkout-page .spec-item { padding: 17px; gap: 12px; }
  .checkout-page .spec-meta { gap: 10px; flex-direction: column-reverse; align-items: end; }
  .checkout-page .spec-meta strong { font-size: 20px; }
  .checkout-page .checkout-details, .brand-page .query-panel { padding: 22px; }
  .brand-page .customer-login-panel { grid-template-columns: minmax(0, 1fr); }
  .brand-page .query-card__summary { padding: 18px; }
  .brand-page .query-card__content { padding: 0 18px 18px; }
  .brand-page .query-order-details { padding: 0 18px; }
  .brand-page .referral-code-box { padding: 18px; }
  .brand-page .referral-stats { gap: 16px; }
  .referral-brand-page #referralForm { grid-template-columns: minmax(0, 1fr); }
  .order-brand-page main { padding-top: 30px; }
  .order-brand-page .pay-box__main { padding: 24px; }
  .order-brand-page #orderTitle { font-size: 23px; }
  .order-brand-page .card-result { padding: 22px; }
  .brand-page .delivery-code__line, .brand-page .delivery-target { grid-template-columns: minmax(0, 1fr); }
  .brand-page .delivery-code__line .secondary { justify-self: start; }
  .brand-page .service-progress__steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 801px) and (max-height: 700px) {
  .checkout-page .checkout-order { position: static; }
}
@media (pointer: coarse) {
  .checkout-page .contact-type button { min-height: 44px; }
  .checkout-page .selected-product-info summary { min-height: 44px; padding-top: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .brand-page *, .brand-page *::before, .brand-page *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.brand-page .hidden, .brand-page [hidden] { display: none !important; }
