/* ===== 重置 ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-font-smoothing: antialiased; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", "Microsoft YaHei", sans-serif;
  background: #f0f4f8;
  color: #1a2033;
  min-height: 100vh;
  line-height: 1.6;
}
a { text-decoration: none; color: inherit; }
input, select, button, textarea { font-family: inherit; outline: none; }

/* ===== 布局 ===== */
.container { max-width: 640px; margin: 0 auto; padding: 0 16px; }
.hidden { display: none !important; }
.text-center { text-align: center; }

/* ===== 顶部导航 ===== */
.header {
  background: #ffffff;
  border-bottom: 1px solid #e8ecf2;
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 1px 8px rgba(0,0,0,0.06);
}
.header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 60px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(135deg, #00b37e, #009e6e);
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; font-weight: 900; color: #fff;
  box-shadow: 0 2px 8px rgba(0,179,126,0.35);
}
.logo-text { font-size: 17px; font-weight: 700; color: #1a2033; letter-spacing: -0.02em; }
.btn-kf {
  display: flex; align-items: center; gap: 6px;
  background: #f0f9f5; border: 1.5px solid #b8e8d8;
  color: #009e6e; padding: 7px 16px; border-radius: 20px;
  font-size: 13px; font-weight: 600; cursor: pointer; transition: all .2s;
}
.btn-kf:hover { background: #e0f5ed; }

/* ===== 公告栏 ===== */
.notice-bar { background: #fffbeb; border-bottom: 1px solid #fde68a; padding: 10px 0; }
.notice-inner { display: flex; align-items: flex-start; gap: 9px; }
.notice-icon { color: #d97706; flex-shrink: 0; display: flex; }
.notice-text { flex: 1; font-size: 13.5px; color: #92400e; line-height: 1.5; }
.notice-close {
  background: none; border: none; color: #b45309;
  cursor: pointer; padding: 2px; display: flex; flex-shrink: 0;
  border-radius: 4px; transition: background .15s;
}
.notice-close:hover { background: #fde68a; }

/* ===== 主体 ===== */
.main { padding: 28px 0 60px; }

/* ===== 步骤条 ===== */
.steps { display: flex; align-items: center; justify-content: center; margin-bottom: 24px; }
.step { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.step-num {
  width: 34px; height: 34px; border-radius: 50%;
  background: #ffffff; border: 2px solid #dde3ec;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700; color: #94a3b8; transition: all .3s;
}
.step.active .step-num {
  background: #00b37e; border-color: #00b37e; color: #fff;
  box-shadow: 0 3px 10px rgba(0,179,126,0.35);
}
.step.done .step-num { background: #e0f5ed; border-color: #00b37e; color: #00b37e; }
.step-label { font-size: 12px; color: #94a3b8; font-weight: 500; }
.step.active .step-label { color: #00b37e; font-weight: 600; }
.step.done .step-label { color: #64748b; }
.step-line { width: 56px; height: 2px; background: #dde3ec; margin: 0 2px; margin-bottom: 22px; transition: background .3s; }
.step-line.done { background: #00b37e; }

/* ===== 卡片 ===== */
.card {
  background: #ffffff; border: 1px solid #e8ecf2;
  border-radius: 20px; overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
.card-header { padding: 24px 28px 20px; border-bottom: 1px solid #f0f4f8; }
.card-header-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card-header h2 { font-size: 20px; font-weight: 700; color: #1a2033; letter-spacing: -0.02em; }
.card-sub { font-size: 13.5px; color: #64748b; margin-top: 5px; }
.card-body { padding: 24px 28px 28px; }

/* ===== 兑换计算器 ===== */
.exchange-box {
  border: 1.5px solid #e2e8f0; border-radius: 16px;
  overflow: hidden; margin-bottom: 14px; background: #fafbfd;
}
.exchange-field { padding: 16px 20px; }
.exchange-field-label {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px; font-size: 13px; color: #64748b; font-weight: 500;
}
.ex-unit-tag {
  background: #e0f5ed; color: #009e6e;
  padding: 3px 10px; border-radius: 20px;
  font-size: 12px; font-weight: 700; letter-spacing: .04em;
}
.ex-input {
  width: 100%; background: none; border: none;
  font-size: 28px; font-weight: 700; color: #1a2033; letter-spacing: -0.02em;
}
.ex-input::placeholder { color: #cbd5e1; font-weight: 500; font-size: 24px; }
.ex-input-result { color: #00b37e; }
.ex-select {
  background: none; border: none;
  font-size: 13px; font-weight: 600; color: #1a2033;
  cursor: pointer; padding: 3px 0; max-width: 160px;
}
.exchange-divider {
  display: flex; align-items: center; padding: 0 20px;
  border-top: 1.5px solid #e2e8f0; border-bottom: 1.5px solid #e2e8f0;
}
.divider-line { flex: 1; }
.exchange-arrow-btn {
  width: 34px; height: 34px; border-radius: 10px;
  background: #ffffff; border: 1.5px solid #e2e8f0;
  display: flex; align-items: center; justify-content: center;
  color: #94a3b8; margin: 8px 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

/* ===== 汇率行 ===== */
.rate-row {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 6px; margin-bottom: 22px;
}
.rate-tag {
  display: flex; align-items: center; gap: 5px;
  font-size: 13px; color: #64748b;
  background: #f8fafc; border: 1px solid #e2e8f0;
  padding: 5px 12px; border-radius: 20px;
}
.rate-tag strong { color: #00b37e; font-weight: 700; }
.fee-tip {
  font-size: 12px; color: #d97706;
  background: #fffbeb; border: 1px solid #fde68a;
  padding: 4px 10px; border-radius: 20px;
}

/* ===== 分割 ===== */
.section-divider { height: 1px; background: #f0f4f8; margin: 4px 0 22px; }
.section-title { font-size: 12px; font-weight: 700; color: #94a3b8; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 12px; }

/* ===== 支付方式 ===== */
.pay-methods { display: flex; gap: 10px; margin-bottom: 4px; }
.pay-method {
  flex: 1; display: flex; align-items: center; justify-content: space-between;
  background: #f8fafc; border: 1.5px solid #e2e8f0;
  border-radius: 12px; padding: 13px 14px; cursor: pointer; transition: all .18s;
}
.pay-method input[type=radio] { display: none; }
.pay-method.active { border-color: #00b37e; background: #f0fdf8; }
.pay-method-inner { display: flex; align-items: center; gap: 10px; }
.pay-icon-wrap {
  width: 34px; height: 34px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; color: #fff;
}
.pay-alipay { background: linear-gradient(135deg, #1677ff, #0958d9); }
.pay-bank { background: linear-gradient(135deg, #f5a623, #e8941a); }
.pay-name { font-size: 14px; font-weight: 600; color: #1a2033; }
.pay-check {
  width: 20px; height: 20px; border-radius: 50%;
  background: #e2e8f0; display: flex; align-items: center; justify-content: center;
  color: transparent; transition: all .18s;
}
.pay-method.active .pay-check { background: #00b37e; color: #fff; }

/* ===== 表单 ===== */
.form-grid { display: flex; flex-direction: column; gap: 14px; margin-bottom: 24px; }
.form-group label { display: block; font-size: 13px; color: #64748b; font-weight: 500; margin-bottom: 7px; }
.form-group input {
  width: 100%; background: #f8fafc;
  border: 1.5px solid #e2e8f0; border-radius: 10px;
  padding: 12px 14px; font-size: 15px; color: #1a2033; transition: border-color .18s, box-shadow .18s;
}
.form-group input:focus { border-color: #00b37e; background: #fff; box-shadow: 0 0 0 3px rgba(0,179,126,0.12); }
.form-group input::placeholder { color: #cbd5e1; }

/* ===== 按钮 ===== */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: linear-gradient(135deg, #00c48c, #00a876);
  border: none; border-radius: 12px; color: #fff;
  font-size: 15px; font-weight: 700; padding: 14px 28px;
  cursor: pointer; transition: opacity .2s, transform .1s, box-shadow .2s;
  box-shadow: 0 4px 14px rgba(0,179,126,0.35);
}
.btn-primary:hover { opacity: .93; box-shadow: 0 6px 20px rgba(0,179,126,0.4); }
.btn-primary:active { transform: scale(.98); }
.btn-full { width: 100%; }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: #fff; border: 1.5px solid #e2e8f0; border-radius: 12px;
  color: #64748b; font-size: 14px; font-weight: 600;
  padding: 12px 28px; cursor: pointer; transition: all .18s;
}
.btn-ghost:hover { border-color: #cbd5e1; color: #475569; background: #f8fafc; }

/* ===== 倒计时徽章 ===== */
.countdown-badge {
  display: flex; align-items: center; gap: 5px;
  background: #fff7ed; border: 1.5px solid #fed7aa;
  border-radius: 20px; padding: 5px 12px;
  color: #ea580c; font-weight: 700; font-size: 15px;
}
.countdown-badge.urgent { background: #fef2f2; border-color: #fecaca; color: #dc2626; }

/* ===== 订单摘要 ===== */
.order-summary {
  display: flex; align-items: center;
  background: #f8fafd; border: 1.5px solid #e8ecf2;
  border-radius: 14px; padding: 16px 20px; margin-bottom: 16px;
}
.order-summary-item { flex: 1; }
.os-label { display: block; font-size: 12px; color: #94a3b8; margin-bottom: 5px; }
.os-val { font-size: 20px; font-weight: 800; color: #1a2033; letter-spacing: -0.02em; }
.os-val-green { color: #00b37e; }
.os-arrow { font-size: 18px; color: #cbd5e1; padding: 0 14px; padding-top: 18px; }

/* ===== 订单详情卡片 ===== */
.order-detail-card {
  background: #f8fafc; border: 1.5px solid #e2e8f0;
  border-radius: 14px; overflow: hidden; margin-bottom: 18px;
}
.order-detail-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: #f1f5f9;
  border-bottom: 1px solid #e2e8f0;
}
.order-detail-title { font-size: 13px; font-weight: 700; color: #475569; }
.btn-copy-all {
  display: inline-flex; align-items: center; gap: 5px;
  background: #00b37e; border: none; border-radius: 7px;
  color: #fff; font-size: 12px; font-weight: 600;
  padding: 6px 12px; cursor: pointer; transition: opacity .18s;
}
.btn-copy-all:hover { opacity: .88; }
.order-detail-body { padding: 4px 0; }
.od-row {
  display: flex; align-items: baseline; gap: 10px;
  padding: 9px 16px; border-bottom: 1px solid #f0f4f8;
}
.od-row:last-child { border-bottom: none; }
.od-key { font-size: 12px; color: #94a3b8; flex-shrink: 0; width: 72px; }
.od-val { font-size: 14px; color: #1a2033; font-weight: 500; word-break: break-all; }
.od-val-green { color: #00b37e; font-weight: 700; }
.od-val-mono { font-family: monospace; font-size: 12px; color: #475569; }
.od-row-addr .od-val { font-size: 12px; }

/* ===== 地址卡片 ===== */
.addr-card {
  background: #f0fdf8; border: 1.5px solid #bbf7e0;
  border-radius: 14px; padding: 18px 20px; margin-bottom: 20px;
}
.addr-card-title {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; color: #047857; margin-bottom: 14px;
}
.addr-qr-layout { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 12px; }
.addr-qr-wrap {
  flex-shrink: 0; background: #fff; border-radius: 10px;
  padding: 8px; border: 1px solid #d1fae5;
}
#qrcode canvas, #qrcode img { display: block; border-radius: 4px; }
.addr-info { flex: 1; display: flex; flex-direction: column; gap: 10px; }
.addr-text-wrap {
  background: #fff; border: 1px solid #d1fae5;
  border-radius: 9px; padding: 10px 12px;
}
.addr-text { font-family: monospace; font-size: 12px; color: #065f46; word-break: break-all; line-height: 1.6; }
.btn-copy-addr {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: #fff; border: 1.5px solid #6ee7b7;
  border-radius: 9px; color: #047857; font-size: 13px; font-weight: 600;
  padding: 9px 16px; cursor: pointer; transition: all .18s; width: 100%;
}
.btn-copy-addr:hover { background: #ecfdf5; }
.addr-warn {
  display: flex; align-items: flex-start; gap: 6px;
  font-size: 12px; color: #b45309;
  background: #fffbeb; border: 1px solid #fde68a;
  border-radius: 8px; padding: 8px 12px;
}
.addr-warn svg { flex-shrink: 0; margin-top: 1px; }

/* ===== 步骤2按钮 ===== */
.step2-btns { display: flex; flex-direction: column; gap: 10px; }

/* ===== 完成页 ===== */
.result-icon {
  width: 72px; height: 72px; border-radius: 50%;
  background: linear-gradient(135deg, #00c48c, #00a876);
  display: flex; align-items: center; justify-content: center;
  margin: 8px auto 20px; color: #fff;
  box-shadow: 0 6px 24px rgba(0,179,126,0.35);
}
.result-title { font-size: 22px; font-weight: 700; color: #1a2033; margin-bottom: 12px; }
.result-desc { font-size: 14px; color: #64748b; line-height: 1.8; margin-bottom: 24px; }
.result-order-box {
  display: inline-flex; align-items: center; gap: 10px;
  background: #f0fdf8; border: 1.5px solid #bbf7e0;
  border-radius: 10px; padding: 12px 20px; margin-bottom: 24px;
}
.result-order-label { font-size: 12px; color: #64748b; }
.result-order-no { font-family: monospace; font-size: 15px; font-weight: 700; color: #047857; }
.text-center .btn-primary,
.text-center .btn-ghost { margin: 6px auto; display: flex; max-width: 300px; }

/* ===== 提示 ===== */
.alert { padding: 12px 16px; border-radius: 10px; font-size: 14px; margin-bottom: 16px; }
.alert-warning { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; }

/* ===== Toast ===== */
.toast {
  position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%);
  background: #1a2033; color: #fff; padding: 10px 22px;
  border-radius: 24px; font-size: 14px; z-index: 9999;
  box-shadow: 0 6px 24px rgba(0,0,0,0.18);
  animation: toastIn .2s ease; white-space: nowrap;
}
@keyframes toastIn { from { opacity:0; transform: translateX(-50%) translateY(10px); } }

/* ===== 滚动跑马灯（固定底部）===== */
.ticker-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  background: #1a2033;
  border-top: 1px solid #2d3a52;
  display: flex; align-items: center;
  height: 40px; overflow: hidden;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.15);
}
.ticker-track { flex: 1; overflow: hidden; position: relative; padding-left: 16px; }
.ticker-content {
  display: inline-block; white-space: nowrap;
  font-size: 13.5px; color: #c8d8ec; font-weight: 500;
  padding-left: 100%;
  animation: tickerScroll 28s linear infinite;
}
.ticker-content:hover { animation-play-state: paused; }
@keyframes tickerScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-66.66%); }
}

/* 有跑马灯时页面底部留出空间 */
body { padding-bottom: 40px; }

/* ===== 页脚 ===== */
.footer { text-align: center; padding: 16px 0 20px; font-size: 13px; color: #94a3b8; }
.footer-kf-link { color: #00b37e; font-weight: 600; transition: opacity .18s; }
.footer-kf-link:hover { opacity: .75; }

/* 公告多行支持 */
.notice-text { white-space: normal; }

/* ===== 响应式 ===== */
@media (max-width: 500px) {
  .card-header, .card-body { padding: 18px 16px 20px; }
  .ex-input { font-size: 22px; }
  .step-line { width: 32px; }
  .addr-qr-layout { flex-direction: column; align-items: center; }
  .addr-info { width: 100%; }
  .order-summary { flex-direction: column; gap: 14px; }
  .os-arrow { display: none; }
}

/* ===================================================
   后台样式
   =================================================== */
.admin-body { background: #f0f4f8; min-height: 100vh; }

.admin-nav {
  background: #ffffff; border-bottom: 1px solid #e8ecf2;
  box-shadow: 0 1px 8px rgba(0,0,0,0.06);
  position: sticky; top: 0; z-index: 100;
}
.admin-nav .container {
  max-width: 1100px; display: flex; align-items: center; height: 60px;
}
.admin-nav .logo { margin-right: auto; }
.nav-links { display: flex; }
.nav-link {
  padding: 0 15px; height: 60px; line-height: 60px;
  font-size: 14px; font-weight: 500; color: #64748b;
  border-bottom: 3px solid transparent; display: block; transition: color .18s;
}
.nav-link:hover { color: #1a2033; }
.nav-link.active { color: #00b37e; border-bottom-color: #00b37e; font-weight: 600; }

.admin-main { max-width: 1100px; margin: 0 auto; padding: 28px 16px 60px; }
.page-title { font-size: 22px; font-weight: 700; color: #1a2033; margin-bottom: 22px; letter-spacing: -0.02em; }

.admin-card {
  background: #ffffff; border: 1px solid #e8ecf2;
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.admin-card-header {
  padding: 14px 22px; border-bottom: 1px solid #f0f4f8;
  font-size: 14px; font-weight: 600; color: #475569; background: #fafbfd;
}
.admin-card-body { padding: 22px; }

.admin-form-group { margin-bottom: 18px; }
.admin-form-group label { display: block; font-size: 13px; color: #64748b; font-weight: 500; margin-bottom: 7px; }
.admin-form-group input[type=text],
.admin-form-group input[type=number],
.admin-form-group input[type=password],
.admin-form-group textarea,
.admin-form-group select {
  width: 100%; background: #f8fafc;
  border: 1.5px solid #e2e8f0; border-radius: 10px;
  padding: 10px 13px; font-size: 14px; color: #1a2033; transition: border-color .18s, box-shadow .18s;
}
.admin-form-group input:focus,
.admin-form-group textarea:focus,
.admin-form-group select:focus { border-color: #00b37e; background: #fff; box-shadow: 0 0 0 3px rgba(0,179,126,0.1); }
.admin-form-group textarea { resize: vertical; min-height: 90px; }

.toggle-switch { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.switch { position: relative; width: 44px; height: 24px; display: inline-block; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; inset: 0; background: #e2e8f0; border-radius: 24px; transition: .25s; }
.slider::before {
  content: ''; position: absolute;
  height: 18px; width: 18px; left: 3px; bottom: 3px;
  background: #fff; border-radius: 50%; transition: .25s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.18);
}
.switch input:checked + .slider { background: #00b37e; }
.switch input:checked + .slider::before { transform: translateX(20px); }

.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th {
  padding: 11px 14px; text-align: left; border-bottom: 1px solid #f0f4f8;
  font-size: 11.5px; font-weight: 700; color: #94a3b8;
  text-transform: uppercase; letter-spacing: .06em; background: #fafbfd;
}
.admin-table td { padding: 12px 14px; border-bottom: 1px solid #f8fafc; color: #334155; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #fafbfd; }

.badge { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.badge-green { background: #dcfce7; color: #15803d; }
.badge-gray { background: #f1f5f9; color: #64748b; }
.badge-yellow { background: #fef9c3; color: #a16207; }
.badge-blue { background: #dbeafe; color: #1d4ed8; }
.badge-red { background: #fee2e2; color: #dc2626; }

.stat-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat-card {
  background: #fff; border: 1px solid #e8ecf2;
  border-radius: 14px; padding: 18px 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.stat-label { font-size: 12px; font-weight: 600; color: #94a3b8; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px; }
.stat-val { font-size: 30px; font-weight: 800; color: #1a2033; letter-spacing: -0.03em; }

.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-box {
  width: 100%; max-width: 380px; background: #fff;
  border: 1px solid #e8ecf2; border-radius: 20px; padding: 36px 32px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.08);
}
.login-logo { text-align: center; margin-bottom: 30px; }
.login-logo .logo-icon { margin: 0 auto 12px; width: 52px; height: 52px; font-size: 22px; }
.login-logo h1 { font-size: 20px; font-weight: 700; color: #1a2033; }
.login-logo p { font-size: 13px; color: #94a3b8; margin-top: 4px; }
.alert-error { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; padding: 10px 14px; border-radius: 8px; font-size: 13px; margin-bottom: 16px; }
