/* ============================================================
   问医 · 移动端设计系统
   ============================================================ */

:root {
  --primary: #E4633C;
  --primary-deep: #C94A28;
  --primary-soft: #FFF1E9;
  --primary-grad: linear-gradient(135deg, #FF8A5B 0%, #E4633C 55%, #D04A2A 100%);
  --gold: #C9A227;
  --gold-soft: #FBF3DF;

  --bg: #F5F6F8;
  --card: #FFFFFF;
  --text: #1B1D21;
  --text-2: #5C6470;
  --text-3: #9AA1AC;
  --line: #EEF0F3;
  --line-2: #F5F6F8;

  --green: #2FA36B;
  --green-soft: #EAF7F0;
  --red: #E24D4D;
  --blue: #4A78D0;

  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 22px;
  --shadow: 0 2px 14px rgba(24, 30, 42, 0.05);
  --shadow-lg: 0 10px 34px rgba(24, 30, 42, 0.1);
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

body { overflow-x: hidden; }

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  overflow-x: hidden;
}

@media (min-width: 768px) {
  body { background: #EDEFF2; }
  #app { box-shadow: 0 0 60px rgba(0, 0, 0, 0.08); }
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
input, textarea, button, select { font-family: inherit; font-size: inherit; color: inherit; outline: none; border: none; background: none; }
button { cursor: pointer; }
ul, ol { list-style: none; }

/* ============================ 布局 ============================ */

.page { min-height: 100vh; padding-bottom: calc(70px + var(--safe-b)); }
.page.has-bar { padding-bottom: calc(76px + var(--safe-b)); }
.page.no-tab { padding-bottom: calc(20px + var(--safe-b)); }

.wrap { padding: 0 16px; }
.row { display: flex; align-items: center; }
.row-between { display: flex; align-items: center; justify-content: space-between; }
.col { display: flex; flex-direction: column; }
.grow { flex: 1; min-width: 0; }
.gap4 { gap: 4px; } .gap6 { gap: 6px; } .gap8 { gap: 8px; } .gap10 { gap: 10px; } .gap12 { gap: 12px; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; } .mt20 { margin-top: 20px; }
.mb8 { margin-bottom: 8px; } .mb12 { margin-bottom: 12px; }

.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ellipsis2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ellipsis3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ============================ 顶栏 ============================ */

.navbar {
  position: sticky; top: 0; z-index: 50;
  height: 50px; display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line);
  font-size: 17px; font-weight: 600;
}
.navbar .nav-back, .navbar .nav-right {
  position: absolute; top: 0; height: 50px; display: flex; align-items: center; padding: 0 14px;
  font-size: 15px; font-weight: 400; color: var(--text-2);
}
.navbar .nav-back { left: 0; }
.navbar .nav-right { right: 0; color: var(--primary); }
.navbar.plain { background: transparent; border: none; position: absolute; width: 100%; }
.navbar.plain .navbar-title, .navbar.plain .nav-back { color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.2); }

/* ============================ 底部标签栏 ============================ */

.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; z-index: 90;
  display: flex; align-items: center;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--line);
  padding-bottom: var(--safe-b);
}
.tabbar-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 8px 0 6px; font-size: 10px; color: var(--text-3); position: relative;
}
.tabbar-item.active { color: var(--primary); }
.tabbar-item .ic { width: 24px; height: 24px; display: grid; place-items: center; }
.tabbar-item .ic svg { width: 22px; height: 22px; }
.tabbar-item .dot {
  position: absolute; top: 5px; right: 50%; margin-right: -18px;
  min-width: 15px; height: 15px; padding: 0 4px; border-radius: 8px;
  background: var(--red); color: #fff; font-size: 9px; line-height: 15px; text-align: center;
}

/* ============================ 通用卡片 ============================ */

.card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
}
.card-pad { padding: 14px 16px; }
.section { margin-top: 12px; }
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 10px;
}
.section-title { font-size: 17px; font-weight: 700; letter-spacing: -0.2px; }
.section-title .accent { color: var(--primary); }
.section-more { font-size: 12px; color: var(--text-3); display: flex; align-items: center; gap: 2px; }
.section-sub { font-size: 12px; color: var(--text-3); }

/* ============================ 按钮 ============================ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 44px; padding: 0 20px; border-radius: 22px;
  font-size: 15px; font-weight: 600;
  background: var(--primary-grad); color: #fff;
  box-shadow: 0 6px 16px rgba(228, 99, 60, 0.28);
  transition: transform .12s, opacity .12s;
}
.btn:active { transform: scale(0.97); opacity: 0.9; }
.btn.block { width: 100%; }
.btn.ghost { background: var(--primary-soft); color: var(--primary); box-shadow: none; }
.btn.line { background: #fff; color: var(--primary); box-shadow: none; border: 1px solid var(--primary); }
.btn.gray { background: #F1F3F6; color: var(--text-2); box-shadow: none; }
.btn.sm { height: 32px; padding: 0 14px; font-size: 13px; border-radius: 16px; box-shadow: none; }
.btn.xs { height: 26px; padding: 0 10px; font-size: 12px; border-radius: 13px; box-shadow: none; }
.btn[disabled] { opacity: 0.45; pointer-events: none; }

/* ============================ 标签 / 徽标 ============================ */

.tag {
  display: inline-flex; align-items: center; height: 20px; padding: 0 7px;
  border-radius: 5px; font-size: 11px; line-height: 1;
  background: var(--primary-soft); color: var(--primary);
}
.tag.gold { background: var(--gold-soft); color: #9A7715; }
.tag.green { background: var(--green-soft); color: var(--green); }
.tag.blue { background: #EDF3FD; color: var(--blue); }
.tag.gray { background: #F2F4F7; color: var(--text-2); }
.tag.line { background: transparent; border: 1px solid currentColor; }

.badge {
  position: absolute; top: -4px; right: -8px;
  min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
  background: var(--red); color: #fff; font-size: 10px; line-height: 16px; text-align: center;
}
.dot-red { width: 6px; height: 6px; border-radius: 3px; background: var(--red); display: inline-block; }

/* ============================ 价格 ============================ */

.price { color: var(--primary); font-weight: 700; }
.price .sym { font-size: 12px; margin-right: 1px; }
.price .int { font-size: 20px; letter-spacing: -0.5px; }
.price .dec { font-size: 12px; }
.price.sm .int { font-size: 16px; }
.price.gray { color: var(--text-3); font-weight: 400; text-decoration: line-through; font-size: 12px; }
.price-orange { color: #F0631E; }

/* ============================ 搜索框 ============================ */

.searchbar {
  display: flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 14px; border-radius: 20px;
  background: #fff; box-shadow: var(--shadow);
}
.searchbar .ph { color: var(--text-3); font-size: 13px; flex: 1; }
.searchbar input { flex: 1; font-size: 13px; }
.searchbar .sbtn { color: var(--primary); font-size: 13px; font-weight: 600; padding-left: 10px; border-left: 1px solid var(--line); }

/* ============================ 医生卡片 ============================ */

.doc-card {
  display: flex; gap: 12px; padding: 14px; background: #fff;
  border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 10px;
  position: relative;
}
.doc-avatar {
  width: 62px; height: 62px; border-radius: 14px; object-fit: cover; flex-shrink: 0;
  background: #F3EEE9; border: 1px solid rgba(0,0,0,.04);
}
.doc-avatar.round { border-radius: 50%; }
.doc-main { flex: 1; min-width: 0; }
.doc-name-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.doc-name { font-size: 16px; font-weight: 700; letter-spacing: -0.2px; }
.doc-title { font-size: 12px; color: var(--text-2); }
.doc-hosp { font-size: 12px; color: var(--text-3); margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-good { font-size: 12px; color: var(--text-2); margin-top: 5px; line-height: 1.5; }
.doc-good b { color: var(--primary); font-weight: 600; }
.doc-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.doc-metrics { display: flex; gap: 10px; font-size: 11px; color: var(--text-3); }
.doc-metrics b { color: var(--text); font-weight: 600; }
.doc-price-row { display: flex; gap: 6px; }
.doc-price-chip {
  display: flex; align-items: center; gap: 3px; height: 26px; padding: 0 9px;
  border-radius: 13px; background: var(--primary-soft); color: var(--primary);
  font-size: 11px; font-weight: 600;
}
.doc-price-chip svg { width: 12px; height: 12px; }
.online-dot { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; color: var(--green); }
.online-dot i { width: 6px; height: 6px; border-radius: 3px; background: var(--green); }
.corner-flag {
  position: absolute; top: 0; right: 0;
  padding: 2px 8px; border-radius: 0 var(--radius) 0 10px;
  background: linear-gradient(135deg, #6FCF97, #2FA36B); color: #fff; font-size: 10px;
}

/* ============================ 筛选栏 ============================ */

.filter-bar {
  position: sticky; top: 0; z-index: 40;
  background: #fff; padding: 8px 0 6px;
  border-bottom: 1px solid var(--line);
}
.filter-row { display: flex; gap: 8px; padding: 0 16px; overflow-x: auto; scrollbar-width: none; }
.filter-row::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0; height: 30px; padding: 0 12px; border-radius: 15px;
  background: #F5F6F8; color: var(--text-2); font-size: 13px;
  display: inline-flex; align-items: center; gap: 4px;
}
.chip.on { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.chip .caret { font-size: 9px; opacity: .6; }

.dropdown-mask { position: fixed; inset: 0; background: rgba(0,0,0,.32); z-index: 60; }
.dropdown {
  position: absolute; left: 0; right: 0; background: #fff; z-index: 61;
  border-radius: 0 0 16px 16px; padding: 6px 0 14px;
  max-height: 62vh; overflow-y: auto;
}

/* ============================ 列表项 ============================ */

.cell {
  display: flex; align-items: center; gap: 12px;
  padding: 15px 16px; background: #fff; position: relative;
}
.cell + .cell::before {
  content: ''; position: absolute; top: 0; left: 52px; right: 0; height: 1px; background: var(--line);
}
.cell.no-icon + .cell.no-icon::before { left: 16px; }
.cell-icon { width: 24px; height: 24px; display: grid; place-items: center; color: var(--primary); flex-shrink: 0; }
.cell-icon svg { width: 20px; height: 20px; }
.cell-title { flex: 1; font-size: 15px; }
.cell-value { font-size: 13px; color: var(--text-3); }
.cell-arrow { color: #C8CDD6; font-size: 15px; }

.group { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.group-title { font-size: 12px; color: var(--text-3); padding: 14px 16px 6px; }

/* ============================ 表单 ============================ */

.field {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; background: #fff; position: relative;
}
.field + .field::before { content: ''; position: absolute; top: 0; left: 16px; right: 0; height: 1px; background: var(--line); }
.field label { width: 76px; font-size: 14px; color: var(--text-2); flex-shrink: 0; }
.field input, .field textarea { flex: 1; font-size: 14px; background: transparent; }
.field textarea { resize: none; min-height: 76px; line-height: 1.6; }
.field .ph { color: var(--text-3); }

.switch { width: 46px; height: 26px; border-radius: 13px; background: #E3E6EB; position: relative; transition: background .2s; }
.switch.on { background: var(--primary); }
.switch i { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 3px rgba(0,0,0,.15); }
.switch.on i { transform: translateX(20px); }

/* ============================ 空状态 / 加载 ============================ */

.empty { padding: 60px 20px; text-align: center; color: var(--text-3); }
.empty .em-ic { width: 72px; height: 72px; margin: 0 auto 14px; opacity: .35; }
.empty .em-t { font-size: 14px; margin-bottom: 6px; color: var(--text-2); }
.empty .em-s { font-size: 12px; }

.skeleton { background: linear-gradient(90deg, #F0F2F5 25%, #F7F8FA 37%, #F0F2F5 63%); background-size: 400% 100%; animation: sk 1.3s ease infinite; border-radius: 8px; }
@keyframes sk { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

.spinner { width: 20px; height: 20px; border: 2px solid rgba(228,99,60,.2); border-top-color: var(--primary); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-line { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 18px; color: var(--text-3); font-size: 12px; }

/* ============================ Toast / 弹层 ============================ */

.toast {
  position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%);
  background: rgba(24, 28, 34, 0.9); color: #fff; padding: 10px 18px;
  border-radius: 10px; font-size: 13px; z-index: 9999; max-width: 74%; text-align: center;
}
.toast-enter-active, .toast-leave-active { transition: opacity .2s; }
.toast-enter-from, .toast-leave-to { opacity: 0; }

.sheet-mask { position: fixed; inset: 0; background: rgba(0,0,0,.42); z-index: 200; }
.sheet {
  position: fixed; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 100%; max-width: 480px; background: #fff;
  border-radius: 20px 20px 0 0; z-index: 201;
  padding-bottom: var(--safe-b); max-height: 82vh; overflow-y: auto;
}
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 10px; font-size: 16px; font-weight: 700; }
.sheet-close { color: var(--text-3); font-size: 13px; font-weight: 400; }

/* ============================ 底部操作栏 ============================ */

.bottom-bar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; z-index: 88;
  display: flex; align-items: center; gap: 10px;
  background: rgba(255,255,255,.97); border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + var(--safe-b));
  backdrop-filter: blur(18px);
}
.bottom-bar .bb-info { flex: 1; min-width: 0; }
.bottom-bar .bb-label { font-size: 11px; color: var(--text-3); }

/* ============================ 首页 ============================ */

.home-hero {
  background: var(--primary-grad);
  padding: 0 16px 56px;
  border-radius: 0 0 26px 26px;
  position: relative;
}
.home-hero::after {
  content: ''; position: absolute; right: -40px; top: -30px;
  width: 200px; height: 200px; border-radius: 50%;
  background: rgba(255,255,255,.1);
}
.hero-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 0 12px; }
.hero-brand { display: flex; align-items: center; gap: 8px; color: #fff; }
.hero-brand .logo { width: 30px; height: 30px; border-radius: 9px; background: rgba(255,255,255,.22); display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.hero-brand .bn { font-size: 18px; font-weight: 700; letter-spacing: -0.3px; }
.hero-brand .bs { font-size: 10px; opacity: .85; }
.hero-search {
  display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px;
  background: #fff; border-radius: 21px; box-shadow: 0 6px 20px rgba(160, 60, 20, .16);
}
.hero-search input { flex: 1; font-size: 13px; }
.hero-search .hint { color: var(--text-3); font-size: 13px; flex: 1; }
.hero-search .go { color: var(--primary); font-size: 13px; font-weight: 600; padding-left: 10px; border-left: 1px solid var(--line); }

.hero-banner {
  margin: -44px 16px 0; border-radius: 16px; overflow: hidden;
  box-shadow: 0 10px 26px rgba(120, 60, 30, .16); position: relative; z-index: 2;
  background: #fff;
}
.hero-banner img { width: 100%; height: auto; display: block; }
.banner-dots { position: absolute; bottom: 8px; left: 0; right: 0; display: flex; justify-content: center; gap: 4px; }
.banner-dots i { width: 5px; height: 5px; border-radius: 3px; background: rgba(255,255,255,.5); }
.banner-dots i.on { width: 14px; background: #fff; }

.quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 16px 10px 6px; }
.quick-item { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 6px 0; }
.quick-ic { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff; }
.quick-ic svg { width: 22px; height: 22px; }
.quick-label { font-size: 12px; font-weight: 600; }
.quick-desc { font-size: 10px; color: var(--text-3); }

.dept-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px 4px; padding: 4px 10px 8px; }
.dept-item { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.dept-ic {
  width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center;
  font-size: 15px; font-weight: 700; color: #fff;
}
.dept-name { font-size: 12px; color: var(--text-2); text-align: center; }

.honor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 16px; }
.honor-card { border-radius: 14px; padding: 12px; }
.honor-num { font-size: 20px; font-weight: 700; letter-spacing: -0.5px; }
.honor-num span { font-size: 12px; font-weight: 400; margin-left: 2px; }
.honor-label { font-size: 13px; font-weight: 600; margin-top: 2px; }
.honor-desc { font-size: 10px; color: var(--text-3); margin-top: 2px; line-height: 1.4; }

.entry-row { display: flex; gap: 10px; padding: 0 16px; }
.entry-card {
  flex: 1; background: #fff; border-radius: 14px; padding: 14px 12px;
  box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px;
}
.entry-t { font-size: 14px; font-weight: 700; }
.entry-s { font-size: 11px; color: var(--text-3); }
.entry-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; margin-bottom: 4px; }

/* ============================ 商城 ============================ */

.mall-hero { background: var(--primary-grad); padding: 12px 16px 60px; }
.mall-tabs { display: flex; gap: 18px; padding: 12px 16px 4px; background: #fff; }
.mall-tab { font-size: 15px; color: var(--text-2); padding-bottom: 8px; position: relative; }
.mall-tab.on { color: var(--text); font-weight: 700; }
.mall-tab.on::after { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 20px; height: 3px; border-radius: 2px; background: var(--primary); }

.cat-scroll { display: flex; gap: 10px; padding: 12px 16px; overflow-x: auto; scrollbar-width: none; }
.cat-scroll::-webkit-scrollbar { display: none; }
.cat-chip { flex-shrink: 0; display: flex; flex-direction: column; align-items: center; gap: 5px; width: 62px; }
.cat-ic { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; font-size: 17px; font-weight: 700; color: #fff; }
.cat-name { font-size: 11px; color: var(--text-2); white-space: nowrap; }

.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 16px; }
.product-card { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); }
.product-cover { width: 100%; aspect-ratio: 1; background: #F7F4F0; object-fit: cover; }
.product-body { padding: 10px 10px 12px; }
.product-name { font-size: 13px; font-weight: 600; line-height: 1.4; height: 37px; overflow: hidden; }
.product-tags { display: flex; gap: 4px; margin-top: 6px; flex-wrap: wrap; }
.product-tags .tag { font-size: 10px; height: 17px; padding: 0 5px; }
.product-bottom { display: flex; align-items: flex-end; justify-content: space-between; margin-top: 8px; }
.product-sales { font-size: 10px; color: var(--text-3); }

.rank-card { display: flex; gap: 10px; padding: 12px; background: #fff; border-radius: 14px; box-shadow: var(--shadow); margin-bottom: 10px; }
.rank-no {
  width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center;
  font-size: 12px; font-weight: 700; color: #fff; flex-shrink: 0;
  background: linear-gradient(135deg, #FFB347, #F0631E);
}
.rank-no.n2 { background: linear-gradient(135deg, #B8C4D4, #8B9AAE); }
.rank-no.n3 { background: linear-gradient(135deg, #D9A87C, #B57C4E); }

/* ============================ 医生详情 ============================ */

.doc-hero { background: var(--primary-grad); padding: 0 16px 20px; position: relative; }
.doc-hero-info { display: flex; gap: 14px; padding-top: 14px; }
.doc-hero-avatar { width: 76px; height: 76px; border-radius: 50%; border: 3px solid rgba(255,255,255,.6); object-fit: cover; background: #F3EEE9; }
.doc-hero-name { color: #fff; font-size: 21px; font-weight: 700; letter-spacing: -0.4px; }
.doc-hero-sub { color: rgba(255,255,255,.9); font-size: 12px; margin-top: 3px; }
.doc-hero-tags { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 8px; }
.doc-hero-tags .tag { background: rgba(255,255,255,.2); color: #fff; }

.stat-row { display: flex; background: #fff; border-radius: 14px; padding: 14px 0; margin: 12px 16px; box-shadow: var(--shadow); }
.stat-item { flex: 1; text-align: center; position: relative; }
.stat-item + .stat-item::before { content: ''; position: absolute; left: 0; top: 4px; bottom: 4px; width: 1px; background: var(--line); }
.stat-num { font-size: 17px; font-weight: 700; }
.stat-label { font-size: 11px; color: var(--text-3); margin-top: 1px; }

.service-row {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #fff;
  border-radius: 14px; margin-bottom: 10px; box-shadow: var(--shadow);
}
.service-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.service-ic svg { width: 20px; height: 20px; }
.service-t { font-size: 15px; font-weight: 600; }
.service-s { font-size: 11px; color: var(--text-3); }

.info-block { background: #fff; border-radius: 14px; padding: 16px; margin: 0 16px 10px; box-shadow: var(--shadow); }
.info-title { font-size: 15px; font-weight: 700; margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.info-title::before { content: ''; width: 3px; height: 14px; border-radius: 2px; background: var(--primary); }
.info-text { font-size: 13px; color: var(--text-2); line-height: 1.75; }

/* ============================ 聊天 ============================ */

.chat-page { background: #F3F5F8; min-height: 100vh; display: flex; flex-direction: column; }
.chat-body { flex: 1; padding: 14px 16px 90px; overflow-y: auto; }
.chat-tip { text-align: center; font-size: 11px; color: var(--text-3); margin: 10px 0 16px; }
.msg-row { display: flex; margin-bottom: 14px; gap: 8px; }
.msg-row.me { flex-direction: row-reverse; }
.msg-av { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0; object-fit: cover; background: #E8E3DD; }
.msg-bubble {
  max-width: 72%; padding: 10px 13px; border-radius: 14px;
  background: #fff; font-size: 14px; line-height: 1.6;
  box-shadow: 0 1px 3px rgba(0,0,0,.04); word-break: break-word;
}
.msg-row.me .msg-bubble { background: var(--primary-grad); color: #fff; }
.msg-bubble.sys { background: rgba(0,0,0,.05); color: var(--text-3); font-size: 12px; box-shadow: none; max-width: 88%; text-align: center; margin: 0 auto; }
.msg-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; max-width: 78%; }
.msg-time { font-size: 10px; color: var(--text-3); text-align: center; margin: 12px 0; }

.chat-input-bar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; background: #fff; border-top: 1px solid var(--line);
  padding: 8px 12px calc(8px + var(--safe-b)); display: flex; align-items: center; gap: 8px;
}
.chat-input { flex: 1; height: 38px; padding: 0 14px; border-radius: 19px; background: #F3F5F8; font-size: 14px; }
.chat-send { width: 38px; height: 38px; border-radius: 50%; background: var(--primary-grad); color: #fff; display: grid; place-items: center; flex-shrink: 0; }

/* ============================ 视频诊室 ============================ */

.room-page { background: #14171C; min-height: 100vh; color: #fff; display: flex; flex-direction: column; }
.room-video { flex: 1; position: relative; display: grid; place-items: center; overflow: hidden; }
.room-doctor { width: 100%; height: 100%; object-fit: cover; opacity: .92; position: absolute; inset: 0; filter: brightness(.72); }
.room-overlay { position: relative; z-index: 2; text-align: center; padding: 20px; }
.room-avatar { width: 96px; height: 96px; border-radius: 50%; margin: 0 auto 14px; border: 3px solid rgba(255,255,255,.35); object-fit: cover; }
.room-name { font-size: 20px; font-weight: 700; }
.room-sub { font-size: 13px; opacity: .8; margin-top: 6px; }
.room-timer { margin-top: 18px; font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: 1px; }
.room-hint { margin-top: 8px; font-size: 12px; opacity: .65; }
.room-self {
  position: absolute; right: 14px; top: 14px; width: 92px; height: 128px;
  border-radius: 12px; background: #23272E; border: 1px solid rgba(255,255,255,.14);
  display: grid; place-items: center; font-size: 11px; color: rgba(255,255,255,.5); z-index: 3;
}
.room-actions { display: flex; justify-content: center; gap: 26px; padding: 22px 0 calc(26px + var(--safe-b)); background: #1B1F25; }
.room-btn { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; color: rgba(255,255,255,.75); }
.room-btn .rb-ic { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.12); }
.room-btn.hangup .rb-ic { background: #E24D4D; }

/* ============================ 我的 ============================ */

.mine-hero { background: var(--primary-grad); padding: 26px 16px 30px; position: relative; }
.mine-user { display: flex; align-items: center; gap: 13px; }
.mine-avatar { width: 62px; height: 62px; border-radius: 50%; border: 2px solid rgba(255,255,255,.55); background: rgba(255,255,255,.2); object-fit: cover; }
.mine-name { color: #fff; font-size: 19px; font-weight: 700; }
.mine-phone { color: rgba(255,255,255,.85); font-size: 12px; margin-top: 2px; }
.mine-edit { display: inline-flex; align-items: center; height: 22px; padding: 0 10px; border-radius: 11px; background: rgba(255,255,255,.22); color: #fff; font-size: 11px; }
.mine-stat { display: flex; margin-top: 18px; }
.mine-stat-item { flex: 1; text-align: center; color: #fff; }
.mine-stat-num { font-size: 19px; font-weight: 700; }
.mine-stat-label { font-size: 11px; opacity: .85; }

.mine-orders { display: flex; background: #fff; border-radius: 14px; padding: 14px 0; margin: -16px 16px 0; box-shadow: var(--shadow); position: relative; z-index: 2; }
.mine-order-item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 5px; position: relative; font-size: 11px; color: var(--text-2); }
.mine-order-item .num { font-size: 19px; font-weight: 700; color: var(--text); }
.mine-order-item .ic { width: 26px; height: 26px; display: grid; place-items: center; color: var(--primary); }

/* ============================ 订单 ============================ */

.order-card { background: #fff; border-radius: 14px; margin-bottom: 10px; box-shadow: var(--shadow); overflow: hidden; }
.order-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line-2); font-size: 12px; color: var(--text-3); }
.order-status { font-size: 13px; font-weight: 600; color: var(--primary); }
.order-status.done { color: var(--text-3); }
.order-goods { display: flex; gap: 10px; padding: 12px 14px; }
.order-goods-cover { width: 66px; height: 66px; border-radius: 10px; object-fit: cover; background: #F7F4F0; flex-shrink: 0; }
.order-goods-name { font-size: 13px; font-weight: 600; line-height: 1.4; }
.order-goods-spec { font-size: 11px; color: var(--text-3); margin-top: 3px; }
.order-foot { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 10px 14px 12px; border-top: 1px solid var(--line-2); }

.status-steps { display: flex; padding: 16px; background: #fff; border-radius: 14px; margin-bottom: 10px; box-shadow: var(--shadow); }
.step { flex: 1; text-align: center; position: relative; font-size: 11px; color: var(--text-3); }
.step.on { color: var(--primary); font-weight: 600; }
.step i { display: block; width: 8px; height: 8px; border-radius: 4px; background: #DDE1E7; margin: 0 auto 6px; }
.step.on i { background: var(--primary); box-shadow: 0 0 0 3px rgba(228,99,60,.16); }
.step::after { content: ''; position: absolute; top: 3px; left: 50%; width: 100%; height: 1px; background: #E8EBF0; }
.step:last-child::after { display: none; }

/* ============================ 登录 ============================ */

.login-page { min-height: 100vh; background: linear-gradient(180deg, #FFF6F1 0%, #FFFFFF 42%, #FFFFFF 100%); padding: 0 24px; }
.login-logo { width: 62px; height: 62px; border-radius: 18px; background: var(--primary-grad); display: grid; place-items: center; color: #fff; font-size: 24px; font-weight: 700; margin: 58px auto 16px; box-shadow: 0 10px 26px rgba(228,99,60,.3); }
.login-title { text-align: center; font-size: 22px; font-weight: 700; letter-spacing: -0.4px; }
.login-sub { text-align: center; font-size: 12px; color: var(--text-3); margin-top: 6px; margin-bottom: 30px; }
.login-field { display: flex; align-items: center; gap: 10px; height: 52px; border-bottom: 1px solid var(--line); }
.login-field input { flex: 1; font-size: 16px; }
.login-field .code-btn { font-size: 13px; color: var(--primary); font-weight: 600; }
.login-agree { display: flex; align-items: flex-start; gap: 7px; margin-top: 20px; font-size: 11px; color: var(--text-3); line-height: 1.6; }
.login-agree .cb { width: 15px; height: 15px; border-radius: 4px; border: 1px solid #CDD3DB; flex-shrink: 0; margin-top: 1px; display: grid; place-items: center; }
.login-agree .cb.on { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ============================ 工具类 ============================ */

.divider { height: 1px; background: var(--line); }
.pill-tabs { display: flex; gap: 8px; padding: 10px 16px; overflow-x: auto; scrollbar-width: none; }
.pill-tabs::-webkit-scrollbar { display: none; }
.pill-tab { flex-shrink: 0; height: 30px; padding: 0 14px; border-radius: 15px; background: #fff; font-size: 13px; color: var(--text-2); display: inline-flex; align-items: center; }
.pill-tab.on { background: var(--primary); color: #fff; font-weight: 600; }

.amount-line { display: flex; justify-content: space-between; font-size: 13px; color: var(--text-2); padding: 3px 0; }
.amount-line b { color: var(--text); font-weight: 600; }

.checkbox { width: 19px; height: 19px; border-radius: 50%; border: 1.5px solid #CFD5DE; display: grid; place-items: center; flex-shrink: 0; }
.checkbox.on { background: var(--primary); border-color: var(--primary); color: #fff; }

.avatar-fallback {
  display: grid; place-items: center; background: linear-gradient(135deg, #FFF0E6, #FFD9C2);
  color: #B4653C; font-weight: 700;
}
