/* ================= 阳光家园 · 业主共治平台 · 设计系统 ================= */

:root {
  --brand: #f97316;
  --brand-600: #ea580c;
  --brand-50: #fff7ed;
  --brand-100: #ffedd5;
  --ink: #14171c;
  --ink-2: #3a4149;
  --muted: #8892a0;
  --line: #edeff3;
  --bg: #f4f5f7;
  --card: #ffffff;
  --up: #0e9f6e;
  --down: #e02424;
  --gold: #f59e0b;
  --radius: 16px;
  --shadow-sm: 0 1px 2px rgba(20, 23, 28, .04), 0 2px 8px rgba(20, 23, 28, .04);
  --shadow-md: 0 6px 24px rgba(20, 23, 28, .08);
  --safe-bottom: 18px;
}

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

/* hidden 属性必须优先于组件自身的 display */
[hidden] { display: none !important; }

html, body {
  margin: 0;
  height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  color: var(--ink);
  background: #eceff3;
  -webkit-font-smoothing: antialiased;
}

body {
  background:
    radial-gradient(900px 500px at 8% -10%, #ffe7d3 0%, transparent 60%),
    radial-gradient(700px 500px at 100% 10%, #e3ecff 0%, transparent 55%),
    #eef1f5;
}

/* ------------------------------ 桌面展示舞台 ------------------------------ */

.stage {
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 64px;
  padding: 40px 48px;
}

.stage-aside { width: 330px; }
.stage-brand { display: flex; gap: 14px; align-items: center; margin-bottom: 20px; }
.stage-logo {
  width: 48px; height: 48px; border-radius: 14px; flex: none;
  display: grid; place-items: center; font-weight: 700; font-size: 22px; color: #fff;
  background: linear-gradient(150deg, #fb923c, #ea580c);
  box-shadow: 0 8px 20px rgba(234, 88, 12, .32);
}
.stage-brand h1 { font-size: 22px; margin: 0 0 4px; letter-spacing: .5px; }
.stage-brand p { margin: 0; font-size: 12px; color: var(--muted); }
.stage-desc { font-size: 13px; color: var(--ink-2); line-height: 1.7; margin: 0 0 22px; }
.stage-steps { list-style: none; margin: 0 0 24px; padding: 0; display: grid; gap: 12px; counter-reset: s; }
.stage-steps li {
  position: relative; padding: 14px 16px 14px 44px; background: rgba(255, 255, 255, .72);
  border: 1px solid #fff; border-radius: 14px; box-shadow: var(--shadow-sm); counter-increment: s;
}
.stage-steps li::before {
  content: counter(s); position: absolute; left: 14px; top: 15px;
  width: 20px; height: 20px; border-radius: 50%; background: var(--brand-100); color: var(--brand-600);
  font-size: 11px; font-weight: 700; display: grid; place-items: center;
}
.stage-steps b { display: block; font-size: 13px; margin-bottom: 3px; }
.stage-steps span { font-size: 11.5px; color: var(--muted); line-height: 1.6; }
.stage-links { display: flex; gap: 16px; font-size: 12.5px; }
.stage-links a { color: var(--brand-600); text-decoration: none; font-weight: 600; }
.stage-links a:hover { text-decoration: underline; }
.stage-note { margin-top: 22px; font-size: 11px; color: #a2aab6; line-height: 1.7; }

/* -------------------------------- 手机外壳 -------------------------------- */

.phone {
  position: relative;
  width: 400px; height: 856px; flex: none;
  border-radius: 54px; padding: 11px;
  background: linear-gradient(160deg, #2b3038, #14171c);
  box-shadow: 0 40px 80px -20px rgba(20, 23, 28, .45), 0 0 0 1px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .08);
}
.phone::after {
  content: ""; position: absolute; top: 22px; left: 50%; transform: translateX(-50%);
  width: 96px; height: 24px; border-radius: 0 0 16px 16px; background: #14171c; z-index: 30;
}
.phone-screen {
  position: relative; width: 100%; height: 100%; overflow: hidden;
  border-radius: 44px; background: var(--bg);
  display: flex; flex-direction: column;
}

/* -------------------------------- 状态栏 -------------------------------- */

.status-bar {
  height: 46px; flex: none; display: flex; align-items: center; justify-content: space-between;
  padding: 0 26px; font-size: 13px; font-weight: 600; color: #fff;
  background: linear-gradient(150deg, #fb923c, #f97316 60%, #ea580c);
}
.status-bar .status-right { display: flex; gap: 5px; align-items: center; opacity: .95; }
.status-bar.solid { background: #fff; color: var(--ink); }

/* -------------------------------- 导航栏 -------------------------------- */

.nav {
  flex: none; height: 46px; display: grid; grid-template-columns: 40px 1fr 40px; align-items: center;
  padding: 0 10px; color: #fff;
  background: linear-gradient(150deg, #fb923c, #f97316 60%, #ea580c);
}
.nav.with-back { background: #fff; color: var(--ink); border-bottom: 1px solid var(--line); }
.nav h1 { font-size: 16px; font-weight: 600; margin: 0; text-align: center; letter-spacing: .3px; }
.nav-spacer { width: 40px; }
.nav-back, .nav-icon {
  width: 40px; height: 40px; border: 0; background: transparent; color: inherit;
  display: grid; place-items: center; cursor: pointer; border-radius: 12px;
}
.nav-back:active, .nav-icon:active { background: rgba(0, 0, 0, .06); }
.nav-right { display: flex; justify-content: flex-end; }

/* -------------------------------- 内容区 -------------------------------- */

.view {
  flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 0 14px 28px;
  scrollbar-width: none;
}
.view::-webkit-scrollbar { display: none; }

/* --------------------------------- 通用 --------------------------------- */

.card {
  background: var(--card); border-radius: var(--radius); padding: 16px;
  margin-top: 12px; box-shadow: var(--shadow-sm);
}
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.card-head h3 { font-size: 14.5px; margin: 0; font-weight: 600; letter-spacing: .2px; }
.more { font-size: 11.5px; color: var(--muted); text-decoration: none; display: flex; align-items: center; gap: 2px; }
.hint { font-size: 11px; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.tiny { font-size: 11px; color: var(--muted); line-height: 1.7; margin: 10px 0 0; }
.center { text-align: center; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; }
.up { color: var(--up); }
.down { color: var(--down); }
.ok-text { color: var(--up); }
.foot-note { text-align: center; font-size: 10.5px; color: #a8b0bb; line-height: 1.8; margin: 22px 0 6px; }

.btn {
  border: 0; border-radius: 12px; font-size: 13px; font-weight: 600; padding: 11px 18px;
  cursor: pointer; font-family: inherit; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  text-decoration: none; transition: transform .12s ease, box-shadow .12s ease;
}
.btn:active { transform: scale(.98); }
.btn.primary { background: linear-gradient(150deg, #fb923c, #ea580c); color: #fff; box-shadow: 0 6px 16px rgba(234, 88, 12, .28); }
.btn.ghost { background: #fff; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); }
.btn.block { width: 100%; margin-top: 14px; }
.btn.small { padding: 8px 14px; font-size: 12px; }

.chip {
  font-size: 10.5px; padding: 3px 8px; border-radius: 8px; background: #f1f3f6; color: var(--muted); font-weight: 600;
}
.chip.ok { background: #e7f8f1; color: var(--up); }
.chip.bad { background: #fdeaea; color: var(--down); }

.tag {
  display: inline-block; font-size: 10.5px; padding: 3px 9px; border-radius: 20px;
  background: rgba(255, 255, 255, .22); color: #fff; font-weight: 600; letter-spacing: .2px;
}
.tag.ok { background: rgba(255, 255, 255, .9); color: var(--brand-600); }

.ic { flex: none; }

/* --------------------------------- 首页 --------------------------------- */

.hero {
  position: relative; overflow: hidden; margin: 0 -14px; padding: 18px 18px 20px;
  background: linear-gradient(150deg, #fb923c, #f97316 55%, #ea580c);
  color: #fff; border-radius: 0 0 24px 24px;
}
.hero-glow {
  position: absolute; width: 260px; height: 260px; right: -70px; top: -120px;
  background: radial-gradient(circle, rgba(255, 255, 255, .38), transparent 65%); pointer-events: none;
}
.hero-top { display: flex; justify-content: space-between; align-items: flex-start; position: relative; }
.hero-top h2 { font-size: 19px; margin: 8px 0 4px; letter-spacing: .4px; }
.hero-unit { margin: 0; font-size: 12px; opacity: .9; }
.hero-badge {
  text-align: right; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 14px; padding: 8px 12px; backdrop-filter: blur(4px);
}
.hero-badge span { font-size: 10px; opacity: .85; display: block; }
.hero-badge b { font-size: 17px; display: block; line-height: 1.3; }
.hero-badge em { font-size: 9.5px; opacity: .75; font-style: normal; }

.hero-money { position: relative; margin-top: 18px; }
.hero-label { font-size: 11.5px; opacity: .85; margin: 0 0 2px; }
.hero-money strong { font-size: 34px; font-weight: 700; letter-spacing: -.5px; display: block; line-height: 1.15; }
.hero-money strong::before { content: "¥"; font-size: 18px; font-weight: 600; margin-right: 3px; opacity: .9; }
.hero-cols { display: flex; gap: 26px; margin-top: 12px; }
.hero-cols div { display: flex; flex-direction: column; gap: 2px; }
.hero-cols span { font-size: 10.5px; opacity: .8; }
.hero-cols b { font-size: 13.5px; font-weight: 600; }
.hero-cols b.up, .hero-cols b.down { color: #fff; }
.hero-cols b.up::before { content: "▲ "; font-size: 8px; opacity: .8; }
.hero-cols b.down::before { content: "▼ "; font-size: 8px; opacity: .8; }

.sync-strip {
  width: 100%; display: flex; align-items: center; gap: 8px; margin-top: 12px;
  padding: 10px 14px; border-radius: 12px; border: 1px dashed #d9e2de; background: #f2fbf7;
  color: #0b7a56; font-size: 11.5px; font-family: inherit; cursor: pointer; text-align: left;
}
.sync-strip span { flex: 1; }

.quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 16px 8px; }
.quick {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  text-decoration: none; color: var(--ink-2); font-size: 11.5px; padding: 6px 0; border-radius: 12px;
}
.quick:active { background: #f7f8fa; }
.quick-icon {
  width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center;
  background: linear-gradient(160deg, #fff1e4, #ffe3cc); color: var(--brand-600);
}
.quick:nth-child(2) .quick-icon { background: linear-gradient(160deg, #e8f1ff, #d8e6ff); color: #2563eb; }
.quick:nth-child(3) .quick-icon { background: linear-gradient(160deg, #e9f9f1, #d5f2e4); color: #0e9f6e; }
.quick:nth-child(4) .quick-icon { background: linear-gradient(160deg, #f2ecff, #e6dcff); color: #7c3aed; }

.period-card .period-nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.period-nums div { display: flex; flex-direction: column; gap: 3px; }
.period-nums span { font-size: 10.5px; color: var(--muted); }
.period-nums b { font-size: 15px; font-weight: 700; letter-spacing: -.2px; }

.bars { display: flex; align-items: flex-end; gap: 6px; height: 96px; padding-top: 6px; }
.bar-group { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 5px; height: 100%; }
.bars-inner { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 3px; width: 100%; }
.bar { width: 6px; border-radius: 3px 3px 2px 2px; display: block; }
.bar.up { background: linear-gradient(180deg, #34d399, #0e9f6e); }
.bar.down { background: linear-gradient(180deg, #fca5a5, #e02424); }
.bar-group span { font-size: 9px; color: var(--muted); transform: scale(.92); }
.legend { display: flex; gap: 14px; align-items: center; margin-top: 10px; font-size: 10.5px; color: var(--muted); }
.legend .sw { width: 8px; height: 8px; border-radius: 2px; display: inline-block; margin-right: 4px; }
.legend .sw.up { background: #0e9f6e; }
.legend .sw.down { background: #e02424; }
.legend-note { margin-left: auto; }

.hk-card { background: linear-gradient(150deg, #fffaf4, #fff); border: 1px solid #ffe6d1; }
.hk-card-top { display: flex; gap: 12px; align-items: center; }
.hk-mark { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: #fff1e4; color: var(--brand-600); }
.hk-card h3 { font-size: 14px; margin: 0 0 3px; }
.hk-card p { font-size: 11px; color: var(--muted); margin: 0; }
.hk-tags { display: flex; gap: 6px; margin: 12px 0; flex-wrap: wrap; }
.hk-tags span { font-size: 10px; padding: 4px 8px; border-radius: 6px; background: #fff3e8; color: #b45309; }
.hk-actions { display: flex; gap: 8px; }
.hk-actions .btn { flex: 1; padding: 9px 0; font-size: 12px; }

.ann-list { list-style: none; margin: 0; padding: 0; }
.ann-item { display: flex; gap: 10px; align-items: flex-start; padding: 11px 0; border-top: 1px solid var(--line); cursor: pointer; }
.ann-item:first-child { border-top: 0; padding-top: 2px; }
.ann-cat {
  flex: none; font-size: 10px; padding: 3px 7px; border-radius: 6px; background: #f1f3f6; color: var(--muted);
  font-weight: 600; margin-top: 1px;
}
.ann-cat.pub { background: #e7f8f1; color: var(--up); }
.ann-body { flex: 1; min-width: 0; }
.ann-title { font-size: 12.8px; margin: 0 0 3px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ann-sub { font-size: 11px; color: var(--muted); margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ann-date { font-size: 10px; color: #b3bac4; flex: none; }

.roadmap-card h3 { font-size: 13px; margin: 0 0 12px; }
.roadmap { display: grid; gap: 12px; }
.roadmap-row { display: flex; gap: 10px; align-items: flex-start; }
.roadmap-row .dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 5px; flex: none; background: #d5dae2; }
.roadmap-row .dot.done { background: var(--up); }
.roadmap-row .dot.doing { background: var(--gold); box-shadow: 0 0 0 3px #fef3c7; }
.roadmap-row b { display: block; font-size: 12.5px; font-weight: 600; }
.roadmap-row em { font-style: normal; font-size: 11px; color: var(--muted); }

/* ------------------------------- 公示总览 ------------------------------- */

.segment {
  display: flex; gap: 4px; padding: 4px; margin-top: 12px;
  background: #e9ecf1; border-radius: 12px;
}
.segment button {
  flex: 1; border: 0; background: transparent; font-family: inherit; font-size: 12px; color: var(--ink-2);
  padding: 8px 0; border-radius: 9px; cursor: pointer; font-weight: 600;
}
.segment button.on { background: #fff; color: var(--brand-600); box-shadow: var(--shadow-sm); }

.summary-card { box-shadow: var(--shadow-md); }
.summary-top { display: flex; justify-content: space-between; align-items: flex-end; padding-bottom: 14px; border-bottom: 1px dashed var(--line); }
.summary-top p { margin: 0 0 4px; font-size: 11px; }
.summary-top .big { font-size: 28px; font-weight: 700; letter-spacing: -.6px; }
.summary-account { text-align: right; }
.summary-account b { font-size: 14px; }
.summary-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding-top: 14px; }
.summary-grid div { display: flex; flex-direction: column; gap: 4px; }
.summary-grid span { font-size: 10.5px; color: var(--muted); }
.summary-grid b { font-size: 14px; font-weight: 600; }
.chain-note {
  display: flex; align-items: center; gap: 6px; margin-top: 14px; padding: 8px 10px;
  background: #f2fbf7; border-radius: 9px; font-size: 10.5px; color: #0b7a56;
}

.compose-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.compose-head { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 6px; }
.compose-name { display: flex; align-items: center; gap: 6px; color: var(--ink-2); }
.compose-name i { width: 8px; height: 8px; border-radius: 2px; display: inline-block; }
.compose-amt { font-weight: 600; font-variant-numeric: tabular-nums; }
.compose-amt em { font-style: normal; font-size: 10px; color: var(--muted); margin-left: 6px; }
.compose-bar { height: 5px; border-radius: 3px; background: #f1f3f6; overflow: hidden; }
.compose-bar i { display: block; height: 100%; border-radius: 3px; }

.list-head { display: flex; align-items: center; justify-content: space-between; margin: 20px 2px 10px; }
.list-head h3 { font-size: 14.5px; margin: 0; }
.filters { display: flex; gap: 6px; }
.filters button {
  border: 0; background: #fff; color: var(--muted); font-family: inherit; font-size: 11.5px; font-weight: 600;
  padding: 6px 12px; border-radius: 20px; cursor: pointer; box-shadow: var(--shadow-sm);
}
.filters button.on { background: var(--ink); color: #fff; }

.search-row {
  display: flex; align-items: center; gap: 8px; background: #fff; border-radius: 12px;
  padding: 10px 12px; box-shadow: var(--shadow-sm); color: var(--muted); margin-bottom: 10px;
}
.search-row input { flex: 1; border: 0; outline: 0; font-family: inherit; font-size: 12.5px; color: var(--ink); background: transparent; }
.search-row input::placeholder { color: #b3bac4; }

.rows { display: grid; gap: 8px; }
.row {
  display: flex; gap: 10px; align-items: center; background: #fff; border-radius: 14px;
  padding: 12px; text-decoration: none; color: inherit; box-shadow: var(--shadow-sm);
}
.row:active { background: #fafbfc; }
.row-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.row-icon.up { background: #e9f9f1; color: var(--up); }
.row-icon.down { background: #fdeeee; color: var(--down); }
.row-main { flex: 1; min-width: 0; }
.row-title { font-size: 12.8px; margin: 0 0 4px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-sub { font-size: 10.5px; color: var(--muted); margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-right { text-align: right; flex: none; display: flex; flex-direction: column; gap: 3px; }
.row-right b { font-size: 13.5px; font-variant-numeric: tabular-nums; }
.row-voucher { font-size: 9px; color: #b3bac4; font-family: ui-monospace, monospace; }
.rows-skeleton { display: grid; gap: 8px; }
.rows-skeleton i { display: block; height: 58px; border-radius: 14px; background: linear-gradient(90deg, #f1f3f6, #f8f9fb, #f1f3f6); background-size: 200% 100%; animation: sk 1.3s infinite; }
@keyframes sk { 0% { background-position: 0 0; } 100% { background-position: -200% 0; } }
.load-more { display: flex; justify-content: center; margin-top: 12px; }
.load-more .btn { font-size: 12px; padding: 9px 24px; }

.empty { padding: 60px 20px; text-align: center; color: var(--muted); font-size: 13px; }
.empty.small { padding: 26px; }
.loading { padding: 90px 20px; text-align: center; color: var(--muted); font-size: 12px; }
.spinner {
  width: 26px; height: 26px; margin: 0 auto 14px; border-radius: 50%;
  border: 2.5px solid #ffe3cc; border-top-color: var(--brand); animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* -------------------------------- 明细 -------------------------------- */

.entry-hero {
  margin: 12px 0 0; padding: 22px 18px; border-radius: var(--radius); color: #fff; position: relative; overflow: hidden;
}
.entry-hero.up { background: linear-gradient(150deg, #10b981, #047857); }
.entry-hero.down { background: linear-gradient(150deg, #f87171, #b91c1c); }
.entry-hero p { margin: 0; font-size: 11.5px; opacity: .88; }
.entry-hero strong { display: block; font-size: 32px; font-weight: 700; letter-spacing: -.5px; margin: 6px 0 10px; }
.entry-hero h2 { font-size: 13.5px; margin: 0 0 8px; font-weight: 500; line-height: 1.5; opacity: .96; }
.entry-period { font-size: 10.5px; opacity: .8; }

.kv { display: grid; gap: 0; }
.kv > div { display: flex; justify-content: space-between; gap: 18px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.kv > div:last-child { border-bottom: 0; }
.kv span { font-size: 12px; color: var(--muted); flex: none; }
.kv b { font-size: 12px; font-weight: 500; text-align: right; color: var(--ink-2); word-break: break-all; }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 18px 30px; }
.timeline li::before {
  content: ""; position: absolute; left: 9px; top: 18px; bottom: 0; width: 1.5px; background: #e3e8ef;
}
.timeline li.last::before { display: none; }
.tl-dot {
  position: absolute; left: 0; top: 0; width: 19px; height: 19px; border-radius: 50%;
  background: #e7f8f1; color: var(--up); display: grid; place-items: center;
}
.timeline b { font-size: 12.5px; margin-right: 8px; }
.timeline span { font-size: 11.5px; color: var(--ink-2); }
.timeline em { display: block; font-style: normal; font-size: 10.5px; color: var(--up); margin-top: 3px; }

.obj { padding: 12px; border-radius: 12px; background: #fafbfc; margin-bottom: 10px; }
.obj-head { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); margin-bottom: 6px; }
.obj-head b { font-size: 12px; color: var(--ink); }
.obj-head em { margin-left: auto; font-style: normal; font-size: 10px; color: var(--gold); }
.obj-head em.ok { color: var(--up); }
.obj p { margin: 0; font-size: 12px; color: var(--ink-2); line-height: 1.6; }
.obj-reply { margin-top: 8px !important; padding: 8px 10px; background: #fff; border-radius: 8px; color: var(--up); }

/* -------------------------------- 公告页 ------------------------------- */

.ann-page { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 10px; }
.ann-block { background: #fff; border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow-sm); cursor: pointer; }
.ann-block-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.ann-block h3 { font-size: 13.5px; margin: 0 0 6px; line-height: 1.5; }
.ann-block p { font-size: 11.5px; color: var(--muted); margin: 0; line-height: 1.6; }

/* -------------------------------- 家政页 ------------------------------- */

.hk-hero {
  position: relative; overflow: hidden; margin: 0 -14px; padding: 20px 18px 18px; color: #fff;
  background: linear-gradient(150deg, #0f766e, #115e59 60%, #134e4a);
  border-radius: 0 0 24px 24px;
}
.hk-hero-glow {
  position: absolute; width: 240px; height: 240px; right: -80px; top: -110px;
  background: radial-gradient(circle, rgba(45, 212, 191, .5), transparent 65%);
}
.hk-brand { display: flex; gap: 12px; align-items: center; position: relative; }
.hk-logo { width: 42px; height: 42px; border-radius: 12px; background: rgba(255, 255, 255, .16); display: grid; place-items: center; }
.hk-brand h2 { font-size: 18px; margin: 0 0 3px; }
.hk-brand p { font-size: 11px; margin: 0; opacity: .8; }
.hk-metrics { display: flex; gap: 26px; margin-top: 18px; position: relative; }
.hk-metrics div { display: flex; flex-direction: column; gap: 2px; }
.hk-metrics b { font-size: 16px; }
.hk-metrics span { font-size: 10px; opacity: .75; }

.scene-list { display: grid; gap: 8px; }
.scene {
  position: relative; text-align: left; font-family: inherit; cursor: pointer; text-decoration: none;
  border: 1px solid #ffe6d1; background: linear-gradient(140deg, #fffaf4, #fff);
  border-radius: 14px; padding: 12px 14px; display: grid; gap: 3px;
}
.scene span, .scene b, .scene em { text-decoration: none; }
.scene-badge { font-size: 9.5px; color: #b45309; background: #fff1e4; padding: 2px 7px; border-radius: 5px; width: fit-content; }
.scene-title { display: block; font-size: 13.5px; font-weight: 500; color: var(--ink); line-height: 1.5; }
.hk-name { display: block; font-size: 13.5px; font-weight: 500; color: var(--ink); line-height: 1.5; }
.scene b { font-size: 13px; }
.scene > span:nth-of-type(2) { font-size: 11px; color: var(--muted); }
.scene em { font-style: normal; font-size: 10.5px; color: var(--brand-600); display: flex; align-items: center; gap: 2px; margin-top: 2px; }

.hk-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.hk-svc {
  text-align: left; font-family: inherit; cursor: pointer; background: #fff; border: 0; border-radius: 16px;
  padding: 14px; box-shadow: var(--shadow-sm); display: grid; gap: 4px;
}
.hk-svc-icon { width: 38px; height: 38px; border-radius: 11px; background: #e9f9f1; color: #0f766e; display: grid; place-items: center; margin-bottom: 4px; }
.hk-svc b { font-size: 13px; }
.hk-svc > span { font-size: 10.5px; color: var(--muted); }
.hk-price { display: flex; align-items: baseline; gap: 2px; margin-top: 4px; color: var(--down); font-weight: 700; font-size: 15px; }
.hk-price em { font-style: normal; font-size: 10px; }
.hk-price small { font-size: 9.5px; color: var(--muted); font-weight: 400; }
.hk-tag { margin-left: auto; font-style: normal; font-size: 9px; background: #fff1e4; color: #b45309; padding: 2px 6px; border-radius: 5px; }

.click-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.click-list li { display: flex; justify-content: space-between; font-size: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line); }
.click-list li:last-child { border-bottom: 0; }
.click-list span { color: var(--ink-2); font-family: ui-monospace, monospace; font-size: 11px; }

.note-card { background: #fbfcfd; }
.code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 10px; line-height: 1.75;
  background: #0f172a; color: #cbd5e1; padding: 12px; border-radius: 10px; margin: 10px 0 0;
  white-space: pre-wrap; word-break: break-all; overflow-x: auto;
}
.hk-cta { margin-top: 16px; }
.hk-cta .tiny { margin-top: 10px; }

/* --------------------------------- 我的 -------------------------------- */

.me-hero { display: flex; gap: 14px; align-items: center; padding: 20px 6px 6px; }
.avatar {
  width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; flex: none;
  background: linear-gradient(150deg, #fb923c, #ea580c); color: #fff; font-size: 22px; font-weight: 700;
  box-shadow: 0 8px 20px rgba(234, 88, 12, .28);
}
.me-info h2 { font-size: 18px; margin: 0 0 4px; }
.me-info p { font-size: 11.5px; color: var(--muted); margin: 0 0 6px; }
.me-info .tag { background: #e7f8f1; color: var(--up); }
.me-info .tag.ok { background: #e7f8f1; color: var(--up); }

.unit-card .unit-main { margin-bottom: 12px; }
.unit-code { font-size: 19px; font-weight: 700; letter-spacing: .3px; }
.unit-meta { font-size: 11px; color: var(--muted); margin-top: 3px; }

.menu-card { padding: 4px 16px; }
.menu-row {
  width: 100%; display: flex; align-items: center; gap: 8px; border: 0; background: transparent;
  font-family: inherit; cursor: pointer; padding: 14px 0; border-bottom: 1px solid var(--line);
  color: var(--ink); font-size: 13px; text-align: left;
}
.menu-row:last-child { border-bottom: 0; }
.menu-row span { flex: none; }
.menu-row em { flex: 1; font-style: normal; font-size: 11px; color: var(--muted); text-align: right; }
.menu-row .ic { color: #c4cad4; }

.admin-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.admin-card b { font-size: 13px; }
.admin-card p { font-size: 11px; color: var(--muted); margin: 3px 0 0; }

/* -------------------------------- 认证页 ------------------------------- */

.bind-head { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; }
.bind-icon {
  width: 44px; height: 44px; border-radius: 14px; flex: none; display: grid; place-items: center;
  background: linear-gradient(160deg, #fff1e4, #ffe3cc); color: var(--brand-600);
}
.bind-head h2 { font-size: 16px; margin: 0 0 4px; }
.bind-head p { font-size: 11.5px; color: var(--muted); margin: 0; line-height: 1.6; }
.code-input {
  width: 100%; border: 1px solid var(--line); border-radius: 14px; padding: 15px 16px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 22px; letter-spacing: 7px; text-align: center; text-transform: uppercase;
  background: #fafbfc; outline: 0; color: var(--ink);
}
.code-input::placeholder { letter-spacing: 4px; color: #c4cad4; font-size: 18px; }
.code-input:focus { border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3px rgba(249, 115, 22, .12); }

/* ------------------------------- 投票 / 报修 ------------------------------ */

.vote-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.status-pill {
  font-size: 10.5px; font-weight: 600; padding: 3px 9px; border-radius: 20px;
  background: #f1f3f6; color: var(--muted);
}
.status-pill.on { background: #fff1e4; color: var(--brand-600); }
.vote-card { display: block; text-decoration: none; color: inherit; }
.vote-card h3 { font-size: 14.5px; margin: 0 0 6px; line-height: 1.45; }
.vote-sub { font-size: 11.5px; color: var(--muted); margin: 0 0 10px; line-height: 1.6; }
.vote-meta { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-bottom: 8px; gap: 10px; }
.vote-title { font-size: 17px; margin: 4px 0 10px; line-height: 1.45; }

.opt-list { display: grid; gap: 8px; }
.opt {
  display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: 12px;
  border: 1px solid var(--line); background: #fff; cursor: pointer;
}
.opt.mine { border-color: var(--brand); background: #fffaf4; }
.opt.locked { cursor: default; }
.opt input { margin-top: 3px; accent-color: var(--brand); }
.opt-main { flex: 1; min-width: 0; }
.opt-top { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; }
.opt-top b { font-weight: 600; line-height: 1.5; }
.opt-top span { color: var(--muted); font-size: 11px; flex: none; }
.opt-budget { display: inline-block; font-size: 10.5px; color: #b45309; background: #fff3e8; padding: 2px 7px; border-radius: 5px; margin-top: 4px; }
.opt-bar { height: 4px; border-radius: 3px; background: #f1f3f6; margin-top: 8px; overflow: hidden; }
.opt-bar i { display: block; height: 100%; background: linear-gradient(90deg, #fb923c, #ea580c); border-radius: 3px; }

.stars { display: flex; gap: 8px; margin-bottom: 10px; }
.stars button {
  border: 0; background: transparent; font-size: 26px; line-height: 1; color: #e3e7ee;
  cursor: pointer; padding: 0; transition: transform .1s ease, color .1s ease;
}
.stars button.on { color: #f59e0b; }
.stars button:active { transform: scale(1.15); }

/* --------------------------------- 账单 -------------------------------- */

.bill-summary .big { font-size: 30px; font-weight: 700; letter-spacing: -.6px; display: block; margin: 4px 0 2px; }
.bill-lines { margin: 10px 0; }
.bill-line {
  display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 12px;
}
.bill-line span { color: var(--ink-2); display: flex; flex-direction: column; gap: 2px; }
.bill-line em { font-style: normal; font-size: 10.5px; color: var(--muted); }
.bill-line b { font-variant-numeric: tabular-nums; }
.bill-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 10px; font-size: 12.5px; }
.bill-total b { font-size: 17px; color: var(--down); }

/* -------------------------------- 表单 -------------------------------- */

.form { display: grid; gap: 12px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 11.5px; color: var(--ink-2); font-weight: 600; }
.field input, .field select, .field textarea {
  font-family: inherit; font-size: 12.5px; padding: 10px 12px; border: 1px solid var(--line);
  border-radius: 10px; outline: 0; background: #fafbfc; color: var(--ink); width: 100%;
}
.field textarea { resize: vertical; min-height: 76px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); background: #fff; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* -------------------------------- 底部导航 ------------------------------- */

.tabbar {
  flex: none; height: calc(58px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  display: flex; background: rgba(255, 255, 255, .96); border-top: 1px solid var(--line);
  backdrop-filter: blur(12px); z-index: 20;
}
.tab {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  text-decoration: none; color: #9aa3ae; font-size: 10px; font-weight: 500;
}
.tab.on { color: var(--brand-600); }
.tab.on .ic { stroke-width: 2.1; }

/* --------------------------------- 弹层 -------------------------------- */

.sheet-mask {
  position: absolute; inset: 0; z-index: 40; background: rgba(17, 20, 24, .42);
  opacity: 0; transition: opacity .22s ease; display: flex; align-items: flex-end;
}
.sheet-mask.on { opacity: 1; }
.sheet {
  width: 100%; background: #fff; border-radius: 22px 22px 0 0; padding: 18px 18px 22px;
  transform: translateY(100%); transition: transform .26s cubic-bezier(.22, .8, .3, 1);
  max-height: 82%; overflow-y: auto;
}
.sheet-mask.on .sheet { transform: translateY(0); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.sheet-head h3 { font-size: 15px; margin: 0; }
.sheet-close {
  width: 28px; height: 28px; border-radius: 50%; border: 0; background: #f1f3f6; color: var(--muted);
  font-size: 18px; line-height: 1; cursor: pointer; font-family: inherit;
}
.sheet-title { font-size: 14px; margin: 0 0 6px; line-height: 1.5; }
.sheet-meta { font-size: 11px; color: var(--muted); margin: 0 0 10px; }
.sheet-text { font-size: 12.5px; color: var(--ink-2); line-height: 1.75; margin: 0 0 12px; }
.callout { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 10px; background: #f2fbf7; color: #0b7a56; font-size: 11.5px; }
.textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 12px; font-family: inherit;
  font-size: 13px; resize: none; outline: 0; color: var(--ink); background: #fafbfc; line-height: 1.6;
}
.textarea:focus { border-color: var(--brand); background: #fff; }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.chip-btn {
  border: 0; background: #f4f5f7; color: var(--ink-2); font-family: inherit; font-size: 11px;
  padding: 6px 10px; border-radius: 8px; cursor: pointer;
}
.chip-btn:active { background: var(--brand-100); color: var(--brand-600); }

.toast {
  position: absolute; left: 50%; bottom: 96px; transform: translateX(-50%); z-index: 60;
  background: rgba(17, 20, 24, .88); color: #fff; font-size: 12px; padding: 10px 16px;
  border-radius: 10px; max-width: 78%; text-align: center; line-height: 1.5;
  animation: toastIn .2s ease;
}
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 8px); } }

/* -------------------------------- 适配 -------------------------------- */

@media (max-width: 900px) {
  .stage { padding: 0; gap: 0; align-items: stretch; }
  .stage-aside { display: none; }
  .phone {
    width: 100%; height: 100vh; height: 100dvh; border-radius: 0; padding: 0;
    background: var(--bg); box-shadow: none;
  }
  .phone::after { display: none; }
  .phone-screen { border-radius: 0; }
  .status-bar { display: none; }
  .nav { padding-top: env(safe-area-inset-top, 0px); height: calc(46px + env(safe-area-inset-top, 0px)); }
  .sheet-mask { position: fixed; }
}

@media (max-height: 900px) and (min-width: 901px) {
  .phone { transform: scale(.9); }
}

/* 多小区切换 */
.ps-wrap { border-top: 1px dashed #edeff3; padding-top: 12px; margin-bottom: 4px; }
.ps-hint { font-size: 12px; color: #8892a0; margin: 0 0 8px; }
.ps-item {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  background: #fafbfc; border: 1px solid #edeff3; border-radius: 12px;
  padding: 11px 14px; margin-bottom: 8px; font-family: inherit; font-size: 14px; color: #3a4149; cursor: pointer;
}
.ps-item b { font-size: 12px; font-weight: 600; color: #8892a0; }
.ps-item.on { background: #fff7ef; border-color: #ffd9b8; color: #ea580c; }
.ps-item.on b { color: #ea580c; }
