:root {
  color-scheme: light;
  --ink: #321f1d;
  --muted: #776462;
  --faint: #725f5d;
  --line: #f0dcd8;
  --surface: #ffffff;
  --canvas: #fff7f5;
  --brand: #e33b35;
  --brand-dark: #bd2828;
  --brand-pale: #fff0ed;
  --warn: #b66400;
  --warn-pale: #fff6e8;
  --danger: #b52e2e;
  --danger-pale: #fff0f0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: radial-gradient(circle at 84% 0%, #ffe0d7 0, transparent 27rem), var(--canvas);
  color: var(--ink);
}

button, input { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, a:focus-visible {
  outline: 3px solid #ff8a65;
  outline-offset: 3px;
}

.page-shell { width: min(100% - 32px, 700px); margin: 0 auto; padding: 22px 0 28px; }
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; }
.brand-mark { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 11px; background: linear-gradient(135deg, var(--brand), #ff653f); color: #fff; font-weight: 800; box-shadow: 0 6px 14px rgba(227,59,53,.18); }
.brand strong, .brand small { display: block; }
.brand strong { letter-spacing: .04em; font-size: 16px; }
.brand small { margin-top: 1px; color: var(--muted); font-size: 11px; }
.header-badge { border: 1px solid #f0beb5; border-radius: 999px; padding: 5px 9px; color: var(--brand-dark); background: #fff7f3; font-size: 12px; }

.hero { padding: 48px 0 25px; }
.eyebrow { margin: 0 0 12px; color: var(--brand); font-size: 13px; font-weight: 700; letter-spacing: .1em; }
h1 { max-width: 620px; margin: 0; font-size: clamp(31px, 8.6vw, 50px); line-height: 1.18; letter-spacing: -.045em; }
.no-wrap { white-space: nowrap; }
.intro { max-width: 560px; margin: 15px 0 0; color: var(--muted); font-size: 15px; line-height: 1.7; }
.platform-status-list { display: flex; flex-wrap: wrap; gap: 7px; margin: 17px 0 0; padding: 0; list-style: none; }
.platform-status-list li { border: 1px solid #efc1b9; border-radius: 999px; padding: 6px 10px; color: var(--brand-dark); background: #fff; font-size: 12px; font-weight: 700; }
.platform-status-list .is-enabled::before { content: "✓"; margin-right: 5px; color: var(--brand); }
.platform-status-list .is-reserved { border-style: dashed; color: var(--muted); background: rgba(255,255,255,.7); font-weight: 600; }
.platform-status-list small { margin-left: 3px; color: var(--faint); font-size: 10px; font-weight: 600; }

.query-panel, .support-section, .trust-card, .result-card { border: 1px solid var(--line); border-radius: 18px; background: var(--surface); box-shadow: 0 12px 32px rgba(111, 43, 34, .07); }
.query-panel { padding: 20px; }
.section-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.section-heading h2, .support-section h2, .trust-card h2 { margin: 0; font-size: 15px; }
.section-heading span { color: var(--faint); font-size: 12px; }
.mode-switch { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px; margin: 0 0 14px; padding: 4px; border-radius: 11px; background: #fff0ed; }
.mode-button { min-height: 38px; border: 1px solid transparent; border-radius: 8px; color: var(--muted); background: transparent; font-size: 14px; font-weight: 700; }
.mode-button-secondary { padding-inline: 14px; font-size: 12px; }
.mode-button:hover { color: var(--brand-dark); }
.mode-button.is-selected { border-color: #f1c4bd; color: var(--brand-dark); background: #fff; box-shadow: 0 2px 5px rgba(111, 43, 34, .08); }
.input-wrap { display: flex; align-items: center; min-height: 52px; border: 1px solid #e7c7c1; border-radius: 12px; background: #fff; transition: border-color .15s, box-shadow .15s; }
.input-wrap:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px #ffe0da; }
.link-icon { flex: 0 0 auto; width: 42px; color: var(--brand); font-size: 27px; text-align: center; transform: rotate(-35deg); }
input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 15px; }
input::placeholder { color: #806f6c; opacity: 1; }
.inline-button, .text-button { border: 0; background: transparent; color: var(--brand); font-size: 14px; font-weight: 700; }
.inline-button { flex: 0 0 auto; margin: 5px; padding: 9px 10px; border-radius: 8px; }
.inline-button:hover, .text-button:hover { background: var(--brand-pale); }
.field-help { margin: 9px 0 0; color: var(--faint); font-size: 12px; line-height: 1.5; }
.action-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 19px; }
.text-button { padding: 10px 8px; border-radius: 8px; }
.primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 128px; min-height: 44px; border: 1px solid var(--brand); border-radius: 10px; color: #fff; background: linear-gradient(135deg, var(--brand), #ff5b37); font-weight: 700; box-shadow: 0 6px 14px rgba(227,59,53,.2); }
.primary-button:hover { background: linear-gradient(135deg, var(--brand-dark), #e9462d); }
.primary-button:disabled { cursor: wait; opacity: .7; }
.button-spinner { display: none; width: 15px; height: 15px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
.is-loading .button-spinner { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-message { min-height: 20px; margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.form-message.error { color: var(--danger); }

.result-region { margin-top: 16px; }
.result-card { overflow: hidden; }
.result-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 15px 18px; border-bottom: 1px solid var(--line); background: #fffaf9; }
.result-header p, .result-body p { margin: 0; }
.result-kicker { color: var(--muted); font-size: 12px; }
.status-pill { flex: 0 0 auto; border-radius: 99px; padding: 5px 9px; font-size: 12px; font-weight: 700; }
.status-pending { color: var(--warn); background: var(--warn-pale); }
.status-available { color: var(--brand-dark); background: var(--brand-pale); }
.result-body { padding: 18px; }
.result-title { margin: 0 0 8px; font-size: 18px; line-height: 1.45; }
.result-copy { color: var(--muted); font-size: 14px; line-height: 1.65; }
.result-link { display: inline-flex; align-items: center; margin-top: 15px; color: var(--brand); font-size: 14px; font-weight: 700; text-decoration: none; }
.result-link:hover { text-decoration: underline; }
.result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.result-actions .primary-button, .result-actions > .copy-command { flex: 1 1 180px; min-height: 44px; }
.copy-command { padding: 9px 13px; border: 1px solid #efc1b9; border-radius: 10px; color: var(--brand-dark); background: #fff; font-weight: 700; }
.copy-command:hover { background: var(--brand-pale); }
.command-preview { overflow-wrap: anywhere; margin-top: 13px !important; padding: 9px 10px; border-radius: 8px; color: #7b4e48 !important; background: #fff5f2; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 12px !important; }
.claim-instructions { margin-top: 18px; padding: 14px 15px; border-radius: 12px; background: #fff3ec; }
.claim-instructions h3 { margin: 0; font-size: 14px; }
.claim-instructions ol { margin: 9px 0 0; padding-left: 20px; color: #7b5147; font-size: 12px; line-height: 1.65; }
.claim-instructions li + li { margin-top: 5px; }
.page-toast { position: fixed; z-index: 20; left: 50%; bottom: 24px; max-width: min(88vw, 440px); padding: 11px 16px; border-radius: 999px; color: #fff; background: rgba(57,31,28,.94); box-shadow: 0 10px 28px rgba(91,35,29,.24); font-size: 13px; text-align: center; opacity: 0; pointer-events: none; transform: translate(-50%, 12px); transition: opacity .16s, transform .16s; }
.page-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.page-toast.error { background: rgba(150,47,47,.95); }
.settlement-note { margin-top: 12px !important; color: var(--faint) !important; font-size: 12px !important; }
.product-summary { display: grid; grid-template-columns: 74px 1fr; gap: 14px; align-items: start; }
.product-summary.without-image { grid-template-columns: 1fr; }
.product-image { width: 74px; height: 74px; border-radius: 10px; object-fit: cover; background: #fff0ed; }
.product-image.is-hidden { display: none; }
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 18px; }
.price-stat { min-width: 0; padding: 10px; border-radius: 10px; background: #fff7f5; }
.price-stat strong, .price-stat span { display: block; }
.price-stat span { color: var(--muted); font-size: 11px; }
.price-stat strong { overflow: hidden; margin-top: 4px; color: var(--ink); font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.price-stat.primary { background: var(--brand-pale); }
.price-stat.primary strong { color: var(--brand-dark); }
.history-section, .offers-section { margin-top: 20px; }
.history-title { margin: 0 0 10px; font-size: 14px; }
.mini-chart { display: flex; align-items: end; gap: 4px; height: 66px; padding: 8px 6px; border-radius: 10px; background: #fff5f2; }
.chart-bar { display: block; flex: 1 1 0; min-width: 3px; border-radius: 4px 4px 1px 1px; background: #f06a54; }
.history-list { margin: 9px 0 0; padding: 0; list-style: none; }
.history-list li { display: flex; justify-content: space-between; gap: 16px; padding: 6px 1px; border-bottom: 1px dashed #f0dcd8; color: var(--muted); font-size: 12px; }
.history-list li:last-child { border-bottom: 0; }
.history-list strong { color: var(--ink); }
.offers-list { display: grid; gap: 8px; }
.offer-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px; border-radius: 10px; background: #fff7f5; }
.offer-item strong, .offer-item span { display: block; }
.offer-item strong { font-size: 13px; }
.offer-item span { margin-top: 3px; color: var(--muted); font-size: 12px; }
.offer-link { flex: 0 0 auto; color: var(--brand); font-size: 13px; font-weight: 700; }
.offer-command { flex: 0 0 auto; border: 0; padding: 0; color: var(--brand); background: transparent; font-size: 13px; font-weight: 700; }
.search-results { margin-top: 16px; }
.search-item { align-items: flex-start; }
.search-item-action { display: flex; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.binding-note { margin-top: 12px !important; color: var(--faint) !important; font-size: 12px !important; }
.binding-note.is-confirmed { color: var(--brand-dark) !important; font-weight: 700; }
.content-section { margin-top: 28px; }
.secondary-disclosure { margin-top: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.76); }
.secondary-disclosure > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 17px; color: #70443e; font-size: 14px; font-weight: 700; list-style: none; cursor: pointer; }
.secondary-disclosure > summary::-webkit-details-marker { display: none; }
.secondary-disclosure > summary:hover { background: #fff9f7; }
.secondary-disclosure > summary small { flex: 0 0 auto; color: var(--brand); font-size: 12px; font-weight: 700; }
.secondary-disclosure > summary small::before { content: "＋ "; }
.secondary-disclosure[open] > summary { border-bottom: 1px solid var(--line); background: #fff9f7; }
.secondary-disclosure[open] > summary small::before { content: "－ "; }
.secondary-disclosure[open] > summary small { font-size: 0; }
.secondary-disclosure[open] > summary small::after { content: "收起"; font-size: 12px; }
.secondary-disclosure .content-section { margin-top: 0; padding: 17px; }
.content-heading { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.content-heading h2 { margin: 0; font-size: 19px; letter-spacing: -.02em; }
.section-eyebrow { margin: 0 0 4px; color: var(--brand); font-size: 12px; font-weight: 700; letter-spacing: .08em; }
.section-status { flex: 0 0 auto; color: var(--faint); font-size: 12px; }
.service-grid, .promotion-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.service-card, .promotion-card, .section-empty { min-width: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: 0 8px 20px rgba(111,43,34,.05); }
.service-card { padding: 15px; }
.service-card h3, .promotion-card h3 { margin: 0; font-size: 15px; line-height: 1.45; }
.service-card p, .promotion-card p, .section-empty p { margin: 7px 0 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.service-card .copy-command, .service-card .primary-button { width: 100%; margin-top: 12px; font-size: 13px; }
.service-card .copy-command:disabled { cursor: not-allowed; color: var(--faint); border-color: var(--line); background: #fff7f5; }
.service-card .command-preview { margin-top: 10px !important; }
.service-result-note { margin: 10px 0 0 !important; color: var(--faint) !important; font-size: 12px !important; line-height: 1.55; }
.section-empty { grid-column: 1 / -1; padding: 17px; }
.section-empty h3 { margin: 0; font-size: 15px; }
.promotion-grid { grid-template-columns: 1fr; }
.promotion-card { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 12px; padding: 12px; }
.promotion-card.without-image { grid-template-columns: 1fr; }
.promotion-image { width: 76px; height: 76px; border-radius: 10px; background: #fff0ed; object-fit: cover; }
.promotion-image.is-hidden { display: none; }
.promotion-copy { min-width: 0; }
.promotion-copy h3 { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.promotion-meta { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.promotion-tag { border-radius: 99px; padding: 3px 7px; color: #8a4b43; background: #fff0ed; font-size: 11px; }
.promotion-price { margin-top: 9px !important; color: var(--brand-dark) !important; font-size: 15px !important; font-weight: 800; }
.promotion-discount { color: #8a4b43 !important; }
.promotion-link { margin-top: 8px; min-height: 0; color: var(--brand); font-size: 13px; font-weight: 700; }
.venue-button { width: 100%; margin-top: 12px; font-size: 13px; }
.promotion-card .result-actions { margin-top: 10px; }
.promotion-card .primary-button { width: 100%; min-height: 40px; font-size: 13px; }

.support-section { margin-top: 16px; padding: 19px; }
.platform-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 12px; padding: 0; list-style: none; }
.platform-list li { border: 1px solid #edd2cc; border-radius: 999px; padding: 6px 10px; color: #7c4a43; background: #fffafa; font-size: 12px; }
.support-note { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.trust-card { display: flex; gap: 12px; margin-top: 16px; padding: 17px; background: linear-gradient(120deg, #fff7f4, #fff); box-shadow: none; }
.trust-icon { display: grid; flex: 0 0 auto; width: 26px; height: 26px; place-items: center; border-radius: 50%; color: #fff; background: var(--brand); font-size: 14px; font-weight: 900; }
.trust-card p { margin: 7px 0 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.site-footer { padding: 0 16px 28px; color: var(--faint); font-size: 12px; text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (min-width: 720px) {
  .page-shell { width: min(100% - 48px, 700px); padding-top: 34px; }
  .hero { padding-top: 58px; padding-bottom: 30px; }
  .query-panel { padding: 24px; }
  .product-summary { grid-template-columns: 92px 1fr; }
  .product-summary.without-image { grid-template-columns: 1fr; }
  .product-image { width: 92px; height: 92px; }
}

@media (max-width: 390px) {
  .page-shell { width: min(100% - 24px, 700px); }
  .query-panel { padding: 16px; }
  .section-heading { display: block; }
  .section-heading span { display: block; margin-top: 5px; }
  .mode-button-secondary { padding-inline: 10px; }
  .secondary-disclosure .content-section { padding: 14px; }
  .price-grid { grid-template-columns: 1fr; }
  .service-grid { grid-template-columns: 1fr; }
}
