:root {
  --primary: #1f6fe5;
  --primary-dark: #1756b3;
  --primary-light: #eef4ff;
  --bg: #f5f8ff;
  --card: #ffffff;
  --text: #1a2233;
  --text-sub: #5b6577;
  --line: #e6ecf5;
  --ok: #18a058;
  --warn: #f0a020;
  --danger: #d03050;
  --radius: 14px;
  --shadow: 0 2px 12px rgba(31, 111, 229, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
}

body { max-width: 480px; margin: 0 auto; min-height: 100vh; padding-bottom: 88px; }

/* 顶部栏 */
.navbar {
  position: sticky; top: 0; z-index: 20;
  background: var(--card); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; height: 50px; padding: 0 14px;
}
.navbar .back {
  width: 30px; height: 30px; display: flex; align-items: center; justify-content: center;
  color: var(--text); text-decoration: none; font-size: 20px;
}
.navbar .title { flex: 1; text-align: center; font-weight: 600; font-size: 16px; }
.navbar .placeholder { width: 30px; }

/* 区块 */
.page { padding: 14px; }
.section { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; margin-bottom: 14px; }
.section h3 { font-size: 15px; margin-bottom: 12px; }
.muted { color: var(--text-sub); font-size: 13px; }
.price { color: var(--danger); font-weight: 700; }
.big-price { font-size: 26px; font-weight: 700; color: var(--danger); }

/* 表单 */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; color: var(--text-sub); margin-bottom: 6px; }
.field label .req { color: var(--danger); }
.input, .select, .textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 10px;
  padding: 12px; font-size: 15px; background: #fbfcfe; color: var(--text);
  outline: none;
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--primary); background: #fff; }
.textarea { resize: vertical; min-height: 72px; }
.input-group { display: flex; gap: 10px; }
.input-group .input { flex: 1; }
.btn-code { white-space: nowrap; border: 1px solid var(--primary); color: var(--primary); background: #fff; border-radius: 10px; padding: 0 14px; font-size: 14px; }
.btn-code:disabled { color: var(--text-sub); border-color: var(--line); }

/* 按钮 */
.btn {
  display: block; width: 100%; border: none; border-radius: 12px;
  padding: 14px; font-size: 16px; font-weight: 600; cursor: pointer; text-align: center;
  text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:active { background: var(--primary-dark); }
.btn-ghost { background: #fff; color: var(--primary); border: 1px solid var(--primary); }
.btn-disabled { background: #c9d6ea; color: #fff; cursor: not-allowed; }

.bottom-bar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; background: #fff; border-top: 1px solid var(--line);
  padding: 12px 14px; z-index: 20;
}

/* 品类/品牌卡片 */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cat-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px 14px; text-decoration: none; color: var(--text); display: block;
}
.cat-card .icon { font-size: 28px; }
.cat-card .name { font-weight: 600; margin-top: 8px; }
.cat-card .desc { font-size: 12px; color: var(--text-sub); margin-top: 4px; }

.brand-item {
  display: flex; align-items: center; gap: 12px; padding: 14px 0;
  border-bottom: 1px solid var(--line); text-decoration: none; color: var(--text);
}
.brand-item:last-child { border-bottom: none; }
.brand-item .logo {
  width: 40px; height: 40px; border-radius: 10px; background: var(--primary-light);
  display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--primary);
}
.brand-item .meta { flex: 1; }
.brand-item .sub { font-size: 12px; color: var(--text-sub); }
.brand-item .arrow { color: var(--text-sub); }

/* 列表项 */
.row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; }
.row .k { color: var(--text-sub); font-size: 13px; }
.row .v { font-weight: 500; }

/* 状态标签 */
.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12px; }
.tag-pending { background: #fff7e6; color: var(--warn); }
.tag-verify { background: var(--primary-light); color: var(--primary); }
.tag-reject { background: #ffecef; color: var(--danger); }
.tag-paid { background: #e8f7ef; color: var(--ok); }
.tag-cancel { background: #f0f1f3; color: var(--text-sub); }

/* 订单卡片 */
.order-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; }
.order-card .head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.order-card .no { font-size: 12px; color: var(--text-sub); }

/* 时间线 */
.timeline { padding-left: 8px; }
.tl-item { display: flex; gap: 12px; padding-bottom: 18px; position: relative; }
.tl-item::before { content: ""; position: absolute; left: 7px; top: 16px; bottom: 0; width: 1px; background: var(--line); }
.tl-item:last-child::before { display: none; }
.tl-dot { width: 15px; height: 15px; border-radius: 50%; background: var(--line); margin-top: 3px; flex: none; }
.tl-item.active .tl-dot { background: var(--primary); }
.tl-body .t { font-weight: 600; font-size: 14px; }
.tl-body .time { font-size: 12px; color: var(--text-sub); }

/* 收款方式 */
.pay-option { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 10px; padding: 13px; margin-bottom: 10px; }
.pay-option.active { border-color: var(--primary); background: var(--primary-light); }
.pay-option input { accent-color: var(--primary); }

/* 协议勾选 */
.agree-row { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--text-sub); margin: 14px 0; }
.agree-row input { margin-top: 3px; accent-color: var(--primary); }
.agree-row a { color: var(--primary); text-decoration: none; }

/* 步骤条 */
.steps { display: flex; justify-content: space-between; margin: 6px 0 18px; }
.step { flex: 1; text-align: center; font-size: 12px; color: var(--text-sub); }
.step .dot { width: 22px; height: 22px; border-radius: 50%; background: var(--line); color: #fff; margin: 0 auto 4px; display: flex; align-items: center; justify-content: center; font-size: 12px; }
.step.active { color: var(--primary); }
.step.active .dot { background: var(--primary); }

/* toast */
#toast {
  position: fixed; left: 50%; top: 45%; transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.78); color: #fff; padding: 10px 18px; border-radius: 10px;
  font-size: 14px; z-index: 99; display: none; max-width: 80%; text-align: center;
}

/* 底部导航（个人中心用） */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; background: #fff; border-top: 1px solid var(--line);
  display: flex; z-index: 20;
}
.tabbar a { flex: 1; text-align: center; padding: 8px 0; text-decoration: none; color: var(--text-sub); font-size: 12px; }
.tabbar a.active { color: var(--primary); }
.tabbar a .ico { font-size: 20px; display: block; }

.banner {
  background: linear-gradient(135deg, #1f6fe5, #5a9bf5); color: #fff;
  border-radius: var(--radius); padding: 20px 16px; margin-bottom: 14px;
}
.banner h2 { font-size: 18px; }
.banner p { font-size: 13px; opacity: 0.9; margin-top: 6px; }

/* 品牌 Logo */
.navbar .brand-icon {
  width: 30px; height: 30px; border-radius: 8px; object-fit: contain;
}
.banner .banner-logo {
  width: 72px; height: 72px; border-radius: 16px; object-fit: contain;
  display: block; margin: 0 auto 12px; background: #fff;
}
.profile-avatar {
  width: 56px; height: 56px; border-radius: 14px; object-fit: contain;
  background: var(--primary-light); flex: none;
}
