/* 九万兑换站：与商店同一套「纸·墨·松」设计 token，单页、手机优先。 */
:root {
  --font: -apple-system, 'PingFang SC', 'HarmonyOS Sans SC', 'MiSans', 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
  --font-display: 'Noto Serif SC', 'Source Han Serif SC', 'Songti SC', 'STSong', 'SimSun', serif;
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --text: #17201c; --text-2: #36403b; --text-3: #5b6560;
  --brand: #146b56; --brand-deep: #0d4e3f; --brand-soft: #eaf4f0; --brand-line: #b9dacd;
  --seal: #d2462a; --seal-soft: #fcede8;
  --bg: #f6f4ef; --surface: #fff; --surface-2: #faf8f4; --line: #e7e2d8; --line-2: #d6cfc2;
  --ok: #13795b; --ok-soft: #e9f6f0; --warn: #8a5203; --warn-soft: #fdf6e7; --warn-line: #ecc77a; --down: #c0362c;
  --r-card: 16px; --r-ctl: 10px;
  --shadow-1: 0 1px 2px rgba(40, 32, 16, .06); --shadow-2: 0 1px 2px rgba(40, 32, 16, .05), 0 14px 32px -14px rgba(40, 32, 16, .22);
  --dur: 180ms; --ease: cubic-bezier(.2, .8, .2, 1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--font); font-size: 15px; line-height: 1.65; color: var(--text); background: var(--bg); min-height: 100vh; display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }
.wrap { width: 100%; max-width: 720px; margin: 0 auto; padding: 0 16px; }
b { font-weight: 700; }

.top { background: #10241e; color: #fff; }
.top-in { display: flex; align-items: center; justify-content: space-between; height: 58px; }
.logo-link { display: inline-flex; align-items: center; gap: 10px; color: #fff; }
.logo-link svg { height: 26px; width: auto; }
.logo-tag { font-size: 13px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: rgba(255, 255, 255, .12); color: #d6ebe3; }
.top-link { font-size: 14px; font-weight: 600; color: #d6ebe3; padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .2); }
.top-link:hover { color: #fff; border-color: rgba(255, 255, 255, .45); }

.main { flex: 1; padding-top: 20px; padding-bottom: 48px; }
.status-line { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--text-2); background: var(--surface); border: 1px solid var(--line); }
.status-line .dot { width: 8px; height: 8px; border-radius: 50%; background: #a59d8f; }
.status-line.ok .dot { background: var(--ok); box-shadow: 0 0 0 3px rgba(19, 121, 91, .16); }
.status-line.down { color: #7a4a02; background: var(--warn-soft); border-color: var(--warn-line); }
.status-line.down .dot { background: #c98a1c; }

.hero { margin: 18px 0 18px; }
.hero h1 { font-family: var(--font-display); font-size: 25px; line-height: 1.3; font-weight: 700; text-wrap: balance; }
.hero p { margin-top: 8px; color: var(--text-2); }
.hero p b { color: var(--brand-deep); }

.tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: #ece7dd; margin-bottom: 14px; }
.tabs button { min-height: 36px; padding: 0 16px; border-radius: 999px; font-size: 14px; font-weight: 700; color: var(--text-2); transition: background var(--dur), color var(--dur); }
.tabs button[aria-selected='true'] { background: var(--surface); color: var(--brand-deep); box-shadow: var(--shadow-1); }

.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 12px; }
.steps li { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; color: var(--text-3); text-align: center; position: relative; }
.steps li span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 12.5px; font-weight: 800; background: #ece7dd; color: var(--text-3); position: relative; z-index: 1; }
.steps li:not(:last-child)::after { content: ''; position: absolute; top: 13px; left: calc(50% + 16px); right: calc(-50% + 16px); height: 2px; background: var(--line-2); }
.steps li.done span { background: var(--brand); color: #fff; }
.steps li.done:not(:last-child)::after { background: var(--brand); }
.steps li.now { color: var(--text); }
.steps li.now span { background: var(--brand); color: #fff; box-shadow: 0 0 0 4px rgba(20, 107, 86, .18); }

.card { padding: 20px; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.card h2 { font-size: 18px; margin-bottom: 12px; }
.field { display: block; margin-bottom: 8px; }
.field > span { display: block; font-size: 14px; font-weight: 700; margin-bottom: 6px; }
.input { width: 100%; min-height: 48px; padding: 12px 14px; border-radius: var(--r-ctl); background: var(--surface); border: 1px solid var(--line-2); font-size: 16px; transition: border-color var(--dur), box-shadow var(--dur); }
textarea.input { resize: vertical; min-height: 120px; line-height: 1.5; font-size: 14px; }
.input::placeholder { color: #8a8273; }
.input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(20, 107, 86, .16); }
.mono { font-family: var(--mono); letter-spacing: .02em; }
.hint { font-size: 13px; color: var(--text-3); margin-bottom: 12px; }
.err { margin-bottom: 12px; padding: 10px 12px; border-radius: var(--r-ctl); background: #fbecea; border: 1px solid #efb5ad; color: #7d231a; font-size: 14px; }
.err.maint { background: var(--warn-soft); border-color: var(--warn-line); color: #6b4206; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 999px; font-size: 16px; font-weight: 700; transition: background var(--dur), transform var(--dur) var(--ease), opacity var(--dur); }
.btn:active:not([disabled]) { transform: scale(.98); }
.btn-primary { width: 100%; color: #fff; background: var(--brand); box-shadow: 0 10px 22px -12px rgba(20, 107, 86, .7); }
.btn-primary:hover:not([disabled]) { background: var(--brand-deep); }
.btn-primary[disabled] { background: #e3ddd1; color: #6b6458; box-shadow: none; cursor: not-allowed; }
.btn-plain { color: var(--text-2); background: var(--surface); border: 1px solid var(--line-2); }
.row { display: flex; gap: 10px; }
.row .btn-plain { flex: 0 0 auto; }
.row .btn-primary { flex: 1; width: auto; }
.safe-note { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; font-size: 13px; color: var(--ok); font-weight: 600; }
.safe-note i { width: 14px; height: 14px; border-radius: 50%; background: var(--ok-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2313795b' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4 8-9'/%3E%3C/svg%3E") center / 9px no-repeat; }
.howto { padding-left: 1.3em; display: grid; gap: 4px; font-size: 14px; color: var(--text-2); margin-bottom: 14px; }
.howto code { font-family: var(--mono); font-size: 13px; padding: 1px 6px; border-radius: 5px; background: var(--brand-soft); color: var(--brand-deep); word-break: break-all; }
.acct { display: grid; gap: 8px; margin-bottom: 14px; padding: 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.acct div { display: grid; grid-template-columns: 6em 1fr; gap: 10px; font-size: 14px; }
.acct dt { color: var(--text-3); }
.acct dd { font-weight: 700; word-break: break-all; }
.warn-note { padding: 10px 12px; margin-bottom: 14px; border-radius: 10px; background: var(--warn-soft); border: 1px solid var(--warn-line); color: #6b4206; font-size: 14px; }
.result-ico { width: 56px; height: 56px; border-radius: 16px; margin-bottom: 12px; display: grid; place-items: center; background: var(--brand-soft); }
.result-ico.ok { background: var(--ok); }
.result-ico.bad { background: var(--seal); }
.result-ico.wait::after { content: ''; width: 24px; height: 24px; border-radius: 50%; border: 3px solid rgba(20, 107, 86, .25); border-top-color: var(--brand); animation: spin .9s linear infinite; }
.result-ico.ok::after, .result-ico.bad::after { content: ''; width: 26px; height: 26px; background: center / contain no-repeat; }
.result-ico.ok::after { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E"); }
.result-ico.bad::after { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 7v6M12 17h.01'/%3E%3C/svg%3E"); }
@keyframes spin { to { transform: rotate(360deg); } }
#result p { color: var(--text-2); }
.after { margin-top: 12px; padding-left: 1.2em; font-size: 14px; color: var(--text-2); display: grid; gap: 4px; }
.check-res { margin-top: 14px; padding: 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); display: grid; gap: 8px; font-size: 14px; }
.check-res .verdict { font-weight: 800; font-size: 15px; }
.check-res .verdict.ok { color: var(--ok); }
.check-res .verdict.no { color: var(--down); }
.check-res dl { display: grid; gap: 6px; }
.check-res dl div { display: grid; grid-template-columns: 6em 1fr; gap: 10px; }
.check-res dt { color: var(--text-3); }

.tips { margin-top: 22px; padding: 18px 20px; border-radius: var(--r-card); background: #fffdf8; border: 1px dashed var(--line-2); }
.tips h2 { font-family: var(--font-display); font-size: 17px; margin-bottom: 8px; }
.tips ul { list-style: none; display: grid; gap: 8px; font-size: 14px; color: var(--text-2); }
.tips li { position: relative; padding-left: 16px; }
.tips li::before { content: ''; position: absolute; left: 0; top: .62em; width: 6px; height: 6px; border-radius: 50%; background: var(--seal); }

.foot { background: #10241e; color: #b9cbc3; font-size: 13px; padding: 22px 0 calc(22px + env(safe-area-inset-bottom)); }
.foot b { color: #fff; }
.foot .legal { margin-top: 8px; color: #8fa69c; font-size: 12.5px; }
.toast { position: fixed; left: 50%; top: 16px; transform: translateX(-50%); padding: 10px 16px; border-radius: 12px; background: #17201c; color: #fff; font-size: 14px; font-weight: 600; z-index: 50; }
@media (min-width: 720px) {
  .main { padding-top: 32px; }
  .hero h1 { font-size: 32px; }
  .card { padding: 26px; }
  .steps li { flex-direction: row; justify-content: center; font-size: 13px; }
  .steps li:not(:last-child)::after { display: none; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 1ms !important; transition-duration: 1ms !important; } }
