/* ==================================================================
   云栖 PMS · 移动端样式
   ================================================================== */

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

:root {
  --bg: #F3F5F8;
  --card: #FFFFFF;
  --ink: #101828;
  --ink-2: #475467;
  --muted: #8B94A3;
  --line: #E7EAF0;
  --line-2: #F1F3F7;
  --brand: #0E7A68;
  --brand-600: #0A5E50;
  --brand-50: #E9F6F3;
  --gold: #A9781F;
  --green: #12805C;   --green-bg: #E8F6EF;
  --amber: #B45309;   --amber-bg: #FCF2E5;
  --blue: #1D4ED8;    --blue-bg: #EDF2FE;
  --violet: #6D3AC7;  --violet-bg: #F3EEFD;
  --red: #C0392B;     --red-bg: #FBEDEB;
  --shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 6px 16px rgba(16, 24, 40, .05);
  --shadow-lg: 0 12px 30px rgba(16, 24, 40, .12);
  --r: 14px;
  --r-lg: 20px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "HarmonyOS Sans SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
}

html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overscroll-behavior: none;
}
button { font-family: inherit; border: 0; background: none; color: inherit; cursor: pointer; padding: 0; }
input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
b, strong { font-weight: 650; }
svg { display: block; }
.muted-note { color: var(--muted); font-size: 12.5px; margin: 10px 4px; }
.center { text-align: center; }

/* ---------------- 外壳 ---------------- */
.app {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
  max-width: 430px;
  margin: 0 auto;
  background: var(--bg);
  overflow: hidden;
}

@media (min-width: 760px) {
  body {
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(1200px 600px at 50% -10%, #E7ECF3 0%, #DDE3EC 60%, #D6DDE8 100%);
    padding: 24px;
  }
  .app {
    height: min(920px, calc(100vh - 48px));
    height: min(920px, calc(100dvh - 48px));
    border-radius: 34px;
    box-shadow: 0 30px 70px rgba(16, 24, 40, .22), 0 2px 0 rgba(255, 255, 255, .8) inset;
    border: 1px solid rgba(255, 255, 255, .6);
  }
  .app::after {
    content: "";
    position: absolute;
    top: 8px; left: 50%;
    width: 108px; height: 5px;
    margin-left: -54px;
    border-radius: 99px;
    background: rgba(16, 24, 40, .12);
    pointer-events: none;
    z-index: 40;
  }
}

.view {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
  scrollbar-width: none;
}
.view::-webkit-scrollbar { display: none; }

.scroll-pad { height: calc(28px + var(--safe-b)); }

/* ---------------- 顶栏 ---------------- */
.topbar {
  position: relative;
  z-index: 5;
  background: linear-gradient(180deg, #FFFFFF 0%, #FDFEFE 100%);
  border-bottom: 1px solid var(--line);
  padding: calc(12px + env(safe-area-inset-top, 0px)) 16px 10px;
}
@media (min-width: 760px) {
  .topbar { padding-top: 26px; }
  .tb-row { padding-top: 2px; }
}
.tb-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tb-id { min-width: 0; }
.tb-title {
  font-size: 18px; font-weight: 680; letter-spacing: .2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.tb-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }

.biz-pill {
  display: inline-flex; align-items: center; gap: 5px;
  height: 32px; padding: 0 12px; border-radius: 99px;
  background: var(--brand-50); color: var(--brand-600);
  font-size: 12.5px; font-weight: 600; white-space: nowrap;
  transition: transform .12s ease, background .16s ease;
}
.biz-pill svg { width: 15px; height: 15px; }
.biz-pill:active { transform: scale(.96); }
.biz-pill.ghost { background: #F2F4F7; color: var(--ink-2); }

.tb-kpis {
  display: flex; gap: 12px;
  margin-top: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 1px;
}
.tb-kpis::-webkit-scrollbar { display: none; }
.kpi { display: flex; align-items: baseline; gap: 5px; flex: 0 0 auto; }
.kpi b { font-size: 16px; font-weight: 700; letter-spacing: -.2px; font-variant-numeric: tabular-nums; }
.kpi span { font-size: 11.5px; color: var(--muted); }
.kpi.tone-blue b { color: var(--blue); }
.kpi.tone-violet b { color: var(--violet); }
.kpi.tone-amber b { color: var(--amber); }
.kpi.tone-green b { color: var(--green); }
.kpi[data-act] { cursor: pointer; }

/* ---------------- 底部导航 ---------------- */
.tabbar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-top: 1px solid var(--line);
  padding-bottom: var(--safe-b);
  height: calc(58px + var(--safe-b));
  z-index: 20;
}
.tab {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  height: 100%; color: var(--muted);
  transition: color .16s ease;
}
.tab-ico svg { width: 22px; height: 22px; }
.tab-label { font-size: 10.5px; font-weight: 550; letter-spacing: .2px; }
.tab.active { color: var(--brand); }
.tab.active .tab-ico svg { stroke-width: 2; }
.tab:active { opacity: .6; }

/* ---------------- 通用 ---------------- */
.screen { padding-top: 2px; animation: fadeIn .18s ease both; }
.toolbar { padding: 10px 16px 2px; display: flex; flex-direction: column; gap: 8px; }
.section { padding: 14px 16px 0; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; padding: 18px 4px 8px; }
.section-title h3 { font-size: 14px; font-weight: 650; color: var(--ink-2); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 44px; padding: 0 18px; border-radius: 12px;
  font-size: 15px; font-weight: 600;
  transition: transform .12s ease, opacity .12s ease, background .16s ease;
}
.btn svg { width: 18px; height: 18px; }
.btn:active { transform: scale(.975); }
.btn.primary { background: var(--brand); color: #fff; box-shadow: 0 4px 12px rgba(14, 122, 104, .24); }
.btn.primary:disabled { background: #C9CED8; box-shadow: none; color: #fff; }
.btn.ghost { background: #F1F3F7; color: var(--ink-2); }
.btn.soft { background: #fff; border: 1px solid var(--line); color: var(--ink-2); box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.btn.danger { background: var(--red); color: #fff; }
.btn.block { width: 100%; }

.link { color: var(--brand); font-size: 12.5px; font-weight: 650; }

.fab {
  position: absolute; right: 16px; bottom: calc(72px + var(--safe-b));
  width: 54px; height: 54px; border-radius: 18px;
  background: var(--brand); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 24px rgba(14, 122, 104, .34);
  z-index: 9;
  transition: transform .14s ease;
}
.fab svg { width: 24px; height: 24px; }
.fab:active { transform: scale(.94); }
#fab-host { position: absolute; inset: 0; pointer-events: none; z-index: 9; }
#fab-host .fab { pointer-events: auto; }

/* 分段控件 */
.seg { display: flex; background: #EAEDF2; border-radius: 12px; padding: 3px; gap: 2px; }
.seg button {
  flex: 1; height: 32px; border-radius: 9px;
  font-size: 13px; font-weight: 550; color: var(--ink-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  transition: background .16s ease, color .16s ease, box-shadow .16s ease;
}
.seg button i { font-style: normal; font-size: 11px; color: var(--muted); }
.seg button.on {
  background: #fff; color: var(--ink); font-weight: 650;
  box-shadow: 0 1px 3px rgba(16, 24, 40, .1);
}
.seg button.on i { color: var(--brand); }

/* 横向 chips */
.chips { display: flex; gap: 7px; overflow-x: auto; scrollbar-width: none; padding: 1px 0; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; height: 34px; padding: 0 13px; border-radius: 99px;
  background: #fff; border: 1px solid var(--line);
  font-size: 12.5px; color: var(--ink-2);
  display: inline-flex; align-items: center; gap: 5px;
  transition: all .15s ease;
}
.chip i { font-style: normal; font-size: 11px; color: var(--muted); }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 600; }
.chip.on i { color: rgba(255, 255, 255, .7); }

/* 状态胶囊 */
.pill {
  display: inline-flex; align-items: center; height: 21px; padding: 0 8px;
  border-radius: 6px; font-size: 11px; font-weight: 650; white-space: nowrap;
}
.tone-blue { color: var(--blue); background: var(--blue-bg); }
.tone-green { color: var(--green); background: var(--green-bg); }
.tone-amber { color: var(--amber); background: var(--amber-bg); }
.tone-red { color: var(--red); background: var(--red-bg); }
.tone-violet { color: var(--violet); background: var(--violet-bg); }
.tone-gray { color: #667085; background: #F0F2F5; }

/* 头像 */
.avatar {
  width: 40px; height: 40px; border-radius: 13px;
  background: #EDF1F6; color: #5B6472;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 650; flex: 0 0 auto;
}
.avatar.sm { width: 32px; height: 32px; border-radius: 10px; font-size: 13px; }
.avatar.vip { background: linear-gradient(145deg, #FBF1DC, #F4E3C0); color: var(--gold); }

.vip-tag {
  font-size: 9.5px; font-weight: 700; letter-spacing: .6px;
  color: var(--gold); background: #FBF2DE;
  padding: 1px 5px; border-radius: 4px;
}

.empty { padding: 56px 24px; text-align: center; color: var(--muted); }
.empty-ico { width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 18px; background: #EDF0F5; display: flex; align-items: center; justify-content: center; color: #A3ACBA; }
.empty-ico svg { width: 26px; height: 26px; }
.empty h4 { font-size: 15px; color: var(--ink-2); font-weight: 600; margin-bottom: 4px; }
.empty p { font-size: 12.5px; }

.card { background: var(--card); border-radius: var(--r); border: 1px solid var(--line); box-shadow: var(--shadow); overflow: hidden; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; padding: 14px 16px 4px; }
.card-head h3 { font-size: 14px; font-weight: 650; }
.card-head span { font-size: 12px; color: var(--muted); }

/* ---------------- 房态 ---------------- */
.floor-block { padding: 0 16px; }
.floor-block:first-of-type { padding-top: 12px; }
.floor-label { display: flex; align-items: baseline; gap: 8px; padding: 14px 2px 8px; }
.floor-label span { font-size: 13px; font-weight: 700; color: var(--ink-2); letter-spacing: .5px; }
.floor-label i { font-style: normal; font-size: 11.5px; color: var(--muted); }

.room-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 16px; }
.floor-block .room-grid { padding: 0; }

.room-card {
  position: relative;
  display: flex; flex-direction: column; gap: 2px;
  padding: 12px 12px 11px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  text-align: left;
  overflow: hidden;
  transition: transform .14s ease, box-shadow .16s ease;
}
.room-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--line); }
.room-card:active { transform: scale(.975); box-shadow: var(--shadow); }
.rc-top { display: flex; align-items: center; justify-content: space-between; }
.rc-num { font-size: 19px; font-weight: 720; letter-spacing: -.3px; font-variant-numeric: tabular-nums; }
.rc-badge { font-size: 10px; font-weight: 650; padding: 2px 6px; border-radius: 5px; }
.rc-type { font-size: 11.5px; color: var(--muted); }
.rc-guest { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; margin-top: 7px; }
.rc-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-name.muted { color: var(--muted); font-weight: 500; }
.rc-meta { font-size: 10.5px; color: var(--muted); white-space: nowrap; }

.st-occ { background: linear-gradient(180deg, #F7FAFF 0%, #FFFFFF 70%); }
.st-occ::before { background: var(--blue); }
.st-booked { background: linear-gradient(180deg, #FAF8FF 0%, #FFFFFF 70%); }
.st-booked::before { background: var(--violet); }
.st-clean::before { background: #CDE9DE; }
.st-dirty { background: linear-gradient(180deg, #FFFCF6 0%, #FFFFFF 70%); }
.st-dirty::before { background: var(--amber); }
.st-ooo { background: #FAFBFC; }
.st-ooo::before { background: var(--red); opacity: .55; }
.st-ooo .rc-num { color: #98A1AF; }

/* ---------------- 预订列表 ---------------- */
.list { padding: 8px 16px 0; display: flex; flex-direction: column; gap: 8px; }
.res-row {
  display: flex; align-items: center; gap: 11px;
  padding: 12px; background: #fff;
  border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  text-align: left;
  transition: transform .14s ease;
}
.res-row:active { transform: scale(.985); }
.res-row > svg { width: 16px; height: 16px; flex: 0 0 auto; color: #C6CDD8; }
.rr-main { flex: 1; min-width: 0; }
.rr-line1 { display: flex; align-items: center; gap: 6px; }
.rr-name { font-size: 14.5px; font-weight: 650; white-space: nowrap; }
.rr-line2 { display: flex; align-items: center; gap: 5px; margin-top: 3px; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; }
.rr-line2 i { font-style: normal; opacity: .5; }
.rr-right { text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.rr-right b { font-size: 13.5px; font-weight: 650; font-variant-numeric: tabular-nums; }
.rr-right span { font-size: 10.5px; color: var(--muted); letter-spacing: .3px; }

/* ---------------- 表单 / 页面 ---------------- */
.page-layer { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: center; background: var(--bg); }
/* 弹层必须盖在整页之上：页面 60 / 底部面板 70 / 确认框 90 */
.sheet-layer { z-index: 70; }
.confirm-layer { z-index: 90; }
.page {
  width: 100%; max-width: 430px; height: 100%;
  background: var(--bg); display: flex; flex-direction: column;
}
.page-head {
  display: flex; align-items: center; gap: 6px;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 12px 10px;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
@media (min-width: 760px) { .page-head { padding-top: 24px; } }
.page-head h2 { flex: 1; font-size: 16px; font-weight: 650; text-align: center; }
.page-head .icon-btn { width: 34px; height: 34px; }
.page-head-right { min-width: 34px; display: flex; justify-content: flex-end; }
.head-count { font-size: 12px; color: var(--muted); }
.page-body { flex: 1; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.page-body::-webkit-scrollbar { display: none; }
.page-foot {
  padding: 10px 16px calc(12px + var(--safe-b));
  background: rgba(255, 255, 255, .97);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
}

.icon-btn {
  width: 40px; height: 40px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink-2); background: transparent;
}
.icon-btn svg { width: 21px; height: 21px; }
.icon-btn:active { background: #F1F3F7; }

.form { padding: 14px 16px 0; display: flex; flex-direction: column; gap: 12px; }
.form-block { display: flex; flex-direction: column; gap: 10px; }
.form-block.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.field-hint { font-size: 11px; color: var(--muted); }
.input {
  height: 46px; width: 100%;
  padding: 0 13px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 11px;
  font-size: 15px;
  outline: none;
  transition: border-color .16s ease, box-shadow .16s ease;
  appearance: none;
}
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(14, 122, 104, .1); }
.input.readonly { display: flex; align-items: center; color: var(--muted); background: #F6F7F9; }
select.input { background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' stroke='%238B94A3' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 34px; }
input[type="date"], input[type="time"] { min-height: 46px; }
.two-inline { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

.form-note { font-size: 12px; color: var(--muted); line-height: 1.6; padding: 2px; }
.summary-card {
  background: linear-gradient(180deg, #F0F8F6, #F7FBFA);
  border: 1px solid #DCEDE8; border-radius: 12px;
  padding: 13px 14px; margin: 2px 0 8px;
}
.summary-card > div { display: flex; align-items: baseline; justify-content: space-between; }
.summary-card span { font-size: 13px; color: var(--ink-2); }
.summary-card b { font-size: 19px; color: var(--brand-600); font-weight: 700; font-variant-numeric: tabular-nums; }
.summary-card p { font-size: 11.5px; color: #5C847C; margin-top: 4px; }

.type-picker { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tp {
  position: relative; text-align: left;
  padding: 11px 12px; border-radius: 12px;
  background: #fff; border: 1.5px solid var(--line);
  display: flex; flex-direction: column; gap: 1px;
  transition: all .15s ease;
}
.tp b { font-size: 13.5px; font-weight: 650; }
.tp span { font-size: 11.5px; color: var(--muted); }
.tp .tp-avail { font-style: normal; font-size: 10.5px; color: var(--brand); margin-top: 3px; }
.tp.on { border-color: var(--brand); background: var(--brand-50); }
.tp.on b { color: var(--brand-600); }

.switch-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 13px;
}
.switch-row b { display: block; font-size: 13.5px; font-weight: 600; }
.switch-row i { font-style: normal; font-size: 11.5px; color: var(--muted); }
.switch-row input { width: 20px; height: 20px; accent-color: var(--brand); }

.walkin-hero, .checkin-hero {
  display: flex; align-items: center; gap: 13px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 15px;
}
.wh-num { font-size: 30px; font-weight: 720; letter-spacing: -1px; color: var(--brand-600); }
.wh-meta b { display: block; font-size: 14px; }
.wh-meta span { font-size: 12px; color: var(--muted); }
.checkin-hero > div { display: flex; flex-direction: column; gap: 2px; }
.checkin-hero b { font-size: 15px; }
.checkin-hero span { font-size: 12px; color: var(--muted); }

.quick-chips { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.quick-chips::-webkit-scrollbar { display: none; }
.method-picker { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; }
.mp {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 10px 4px; border-radius: 11px;
  background: #fff; border: 1.5px solid var(--line);
  font-size: 11.5px; color: var(--ink-2);
  transition: all .15s ease;
}
.mp svg { width: 19px; height: 19px; color: var(--muted); }
.mp.on { border-color: var(--brand); background: var(--brand-50); color: var(--brand-600); font-weight: 650; }
.mp.on svg { color: var(--brand); }
.pay-amount { text-align: center; padding: 18px 0 10px; }
.pay-amount span { display: block; font-size: 12.5px; color: var(--muted); }
.pay-amount b { font-size: 34px; font-weight: 720; letter-spacing: -1px; color: var(--ink); font-variant-numeric: tabular-nums; }

.pay-bar { display: flex; align-items: center; gap: 12px; }
.pay-bar .pb-main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.pay-bar .pb-main span { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pay-bar .pb-main b { font-size: 19px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.3px; }
.pay-bar .btn { flex: 0 0 auto; min-width: 44%; height: 46px; }

/* 房价设置 */
.type-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 13px;
}
.tr-main b { display: block; font-size: 14px; }
.tr-main span { font-size: 11.5px; color: var(--muted); }
.tr-input { display: flex; align-items: center; gap: 3px; background: #F6F7F9; border-radius: 9px; padding: 0 10px; height: 38px; }
.tr-input span { font-size: 13px; color: var(--muted); }
.tr-input input { width: 64px; border: 0; background: transparent; font-size: 15px; font-weight: 650; outline: none; text-align: right; font-variant-numeric: tabular-nums; }
.room-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 16px 16px; }
.rchip { font-size: 11.5px; color: var(--ink-2); background: #F3F5F8; border-radius: 6px; padding: 3px 7px; font-variant-numeric: tabular-nums; }

/* ---------------- 账单 ---------------- */
.folio-skeleton { height: 60vh; background: linear-gradient(100deg, #F1F3F7 30%, #F7F9FB 50%, #F1F3F7 70%); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
.folio-hero {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 10px;
  padding: 18px 18px 16px;
  background: linear-gradient(160deg, #0F7C6A 0%, #0B5F52 100%);
  color: #fff;
}
.fh-name { font-size: 20px; font-weight: 680; display: flex; align-items: baseline; gap: 8px; }
.fh-room { font-size: 13px; font-weight: 600; background: rgba(255, 255, 255, .18); padding: 2px 7px; border-radius: 6px; }
.fh-meta { font-size: 12px; opacity: .8; margin-top: 4px; }
.fh-code { font-size: 11px; opacity: .6; margin-top: 6px; letter-spacing: .4px; }
.folio-hero .pill { background: rgba(255, 255, 255, .2); color: #fff; }

.folio-groups { padding: 6px 16px 0; }
.fg { margin-top: 14px; }
.fg-date { font-size: 11.5px; color: var(--muted); font-weight: 600; padding: 0 2px 6px; letter-spacing: .3px; }
.fg-list { background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.fg-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 14px;
  border-top: 1px solid var(--line-2);
}
.fg-item:first-child { border-top: 0; }
.fg-item .fi-main { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--ink-2); min-width: 0; }
.fg-item .fi-main span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fg-item b { font-size: 14px; font-weight: 650; font-variant-numeric: tabular-nums; }
.fg-item.credit b { color: var(--green); }
.fi-tag { font-style: normal; font-size: 9.5px; color: var(--muted); background: #F2F4F7; padding: 1px 4px; border-radius: 4px; flex: 0 0 auto; }
.folio-empty { text-align: center; color: var(--muted); font-size: 13px; padding: 48px 0; }

.folio-sum { display: flex; justify-content: space-between; gap: 8px; padding: 2px 2px 10px; }
.folio-sum > div { display: flex; flex-direction: column; gap: 1px; }
.folio-sum i { font-style: normal; font-size: 11px; color: var(--muted); }
.folio-sum b { font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; }
.fs-balance { margin-left: auto; text-align: right; }
.fs-balance b.warn { color: var(--red); }
.fs-balance b.credit { color: var(--green); }
.foot-actions { display: flex; gap: 8px; }
.foot-actions .btn { flex: 1; padding: 0 10px; font-size: 14px; }
.foot-actions .btn.ghost { background: #F1F3F7; }
.page-foot .foot-actions { display:flex; gap:6px; flex-wrap:nowrap; }
.page-foot .foot-actions .btn { flex:1 1 0; min-width:0; padding:0 4px; font-size:13px; white-space:nowrap; }
.detail-entry .de-more svg { width:14px; height:14px; }
.folio-sum + .folio-sum { margin-top:2px; }

/* 订单详情 */
.res-detail { padding: 4px 0 0; }
.rd-head { display: flex; align-items: center; gap: 11px; }
.rd-name { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.rd-name b { font-size: 16px; display: inline-flex; align-items: center; gap: 6px; }
.rd-name span { font-size: 12px; color: var(--muted); }
.rd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; margin-top: 16px; padding: 14px; background: #F7F8FA; border-radius: 12px; }
.rd-grid > div { display: flex; flex-direction: column; gap: 1px; }
.rd-grid i { font-style: normal; font-size: 11px; color: var(--muted); }
.rd-grid b { font-size: 13.5px; font-weight: 600; }
.rd-balance { display: flex; align-items: baseline; justify-content: space-between; margin-top: 12px; padding: 0 4px; }
.rd-balance span { font-size: 12.5px; color: var(--muted); }
.rd-balance b { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rd-balance b.warn { color: var(--red); }
.rd-note { display: flex; gap: 6px; align-items: flex-start; font-size: 12px; color: var(--ink-2); background: #FFF9EC; border: 1px solid #F6E7C6; border-radius: 10px; padding: 9px 11px; margin-top: 12px; }
.rd-note svg { width: 14px; height: 14px; flex: 0 0 auto; margin-top: 1px; color: var(--amber); }

.guest-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px; background: #F7F8FA; border-radius: 12px; }
.guest-stats > div { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.guest-stats b { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.guest-stats span { font-size: 11px; color: var(--muted); }

/* 搜索 */
.search-bar { display: flex; align-items: center; gap: 8px; margin: 12px 16px 4px; padding: 0 12px; height: 42px; background: #fff; border: 1px solid var(--line); border-radius: 11px; }
.search-bar svg { width: 17px; height: 17px; color: var(--muted); flex: 0 0 auto; }
.search-bar input { flex: 1; border: 0; outline: none; font-size: 14.5px; background: transparent; }

/* ---------------- 客房 ---------------- */
.inline-note {
  display: flex; align-items: center; gap: 8px;
  margin: 10px 16px 0; padding: 10px 12px;
  background: #FFF9EC; border: 1px solid #F6E7C6; border-radius: 11px;
  font-size: 12px; color: #8A6520;
}
.inline-note svg { width: 15px; height: 15px; flex: 0 0 auto; color: var(--amber); }
.inline-note span { flex: 1; }
.inline-note .link { color: var(--amber); }

.hk-list { gap: 9px; }
.hk-card {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  padding: 13px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.hk-card.done { opacity: .62; }
.hk-num {
  width: 50px; flex: 0 0 auto; text-align: center;
  font-size: 17px; font-weight: 700; letter-spacing: -.3px;
  font-variant-numeric: tabular-nums;
}
.hk-num i { display: block; font-style: normal; font-size: 10px; font-weight: 500; color: var(--muted); letter-spacing: .3px; }
.hk-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hk-main b { font-size: 13.5px; font-weight: 650; }
.hk-main span { font-size: 11.5px; color: var(--muted); }
.hk-main em { font-style: normal; font-size: 11px; color: var(--amber); }
.hk-actions { display: flex; gap: 6px; }
.mini-btn {
  height: 34px; padding: 0 13px; border-radius: 9px;
  background: #F1F3F7; color: var(--ink-2);
  font-size: 12.5px; font-weight: 600;
}
.mini-btn.solid { background: var(--brand); color: #fff; }
.mini-btn:active { opacity: .75; }
.hk-done { color: var(--green); }
.hk-done svg { width: 20px; height: 20px; }

/* ---------------- 报表 ---------------- */
.kpi-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.kt {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  padding: 13px 14px; display: flex; flex-direction: column; gap: 1px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.kt span { font-size: 11.5px; color: var(--muted); }
.kt b { font-size: 22px; font-weight: 720; letter-spacing: -.6px; font-variant-numeric: tabular-nums; }
.kt i { font-style: normal; font-size: 10.5px; color: var(--muted); }
.kt.accent { background: linear-gradient(155deg, #0F7C6A, #0A5B4E); border-color: transparent; color: #fff; }
.kt.accent span, .kt.accent i { color: rgba(255, 255, 255, .72); }

.chart { display: flex; align-items: flex-end; gap: 7px; height: 132px; padding: 18px 16px 4px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bar-track { width: 100%; flex: 1; display: flex; align-items: flex-end; }
.bar-fill {
  width: 100%; border-radius: 5px 5px 3px 3px;
  background: linear-gradient(180deg, #BFDCD4, #D8E9E4);
  min-height: 4px;
  transition: height .4s cubic-bezier(.2, .8, .2, 1);
}
.bar-col.today .bar-fill { background: linear-gradient(180deg, #0F7C6A, #37A08C); }
.bar-x { font-size: 9.5px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.bar-col.today .bar-x { color: var(--brand); font-weight: 700; }
.chart-legend { display: flex; justify-content: space-between; padding: 0 16px 14px; font-size: 10.5px; color: var(--muted); }

.mix { padding: 8px 16px 16px; display: flex; flex-direction: column; gap: 12px; }
.mix-top { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--ink-2); margin-bottom: 5px; }
.mix-top b { font-weight: 650; font-variant-numeric: tabular-nums; }
.mix-bar { height: 6px; background: #EFF2F6; border-radius: 99px; overflow: hidden; }
.trial-banner {
  width: 100%; display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; border-radius: 14px; text-align: left;
  background: #FFF7E8; border: 1px solid #F3DFB8;
}
.trial-banner b { font-size: 13.5px; color: #8A5A00; flex: 0 0 auto; }
.trial-banner span { flex: 1; font-size: 12px; color: #A9791F; }
.trial-banner svg { width: 16px; height: 16px; color: #C08A2A; }
.trial-banner.bad { background: #FDECEA; border-color: #F3C9C3; }
.trial-banner.bad b { color: #A93226; }
.trial-banner.bad span { color: #B4574C; }
.trial-banner.bad svg { color: #C0574A; }
.sub-ok { color: #0B7A55; }
.sub-warn { color: #A65A08; }
.sub-bad { color: #B03A2C; }
.idno-box { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 26px; letter-spacing: 6px; font-weight: 700; text-align: center; padding: 18px 0; background: #F5F8FA; border-radius: 12px; user-select: none; -webkit-user-select: none; }
.src-meta { font-style: normal; color: var(--muted); font-size: 11px; margin-left: 4px; }
.mix-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #1D9A83, #57BFA9); }
.mix-row:nth-child(2) .mix-bar i { background: linear-gradient(90deg, #C79A48, #E0BE86); }

.op-rows { padding: 6px 0 6px; }
.op-row {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 12px 16px; font-size: 13.5px; color: var(--ink-2);
  border-top: 1px solid var(--line-2); text-align: left;
}
.op-row:first-child { border-top: 0; }
.op-row span { flex: 1; }
.op-row b { font-weight: 650; color: var(--ink); font-variant-numeric: tabular-nums; }
.op-row svg { width: 15px; height: 15px; color: #C3CAD5; }
.op-row:active { background: #FAFBFC; }

.audit-card {
  display: flex; align-items: center; gap: 12px; width: 100%;
  background: linear-gradient(120deg, #101828, #1E2C45);
  border-radius: var(--r); padding: 16px;
  color: #fff; text-align: left;
  box-shadow: 0 8px 20px rgba(16, 24, 40, .18);
}
.ac-ico { width: 40px; height: 40px; border-radius: 12px; background: rgba(255, 255, 255, .12); display: flex; align-items: center; justify-content: center; }
.ac-ico svg { width: 20px; height: 20px; }
.ac-main { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.ac-main b { font-size: 14px; font-weight: 650; }
.ac-main span { font-size: 11.5px; color: rgba(255, 255, 255, .62); }
.audit-card > svg { width: 16px; height: 16px; color: rgba(255, 255, 255, .4); }

/* ---------------- 夜审 ---------------- */
.night { padding: 14px 16px 0; }
.night-hero {
  background: linear-gradient(150deg, #101828 0%, #22304A 100%);
  border-radius: var(--r-lg); padding: 20px; color: #fff;
  box-shadow: 0 14px 30px rgba(16, 24, 40, .22);
}
.nh-label { font-size: 11.5px; color: rgba(255, 255, 255, .55); letter-spacing: .4px; }
.nh-date { font-size: 24px; font-weight: 700; letter-spacing: -.4px; margin-top: 2px; }
.nh-arrow { display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 12px; color: rgba(255, 255, 255, .7); }
.nh-arrow svg { width: 13px; height: 13px; transform: rotate(90deg); }
.night-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 12px 0; }
.night-summary > div { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 11px 12px; display: flex; flex-direction: column; gap: 1px; }
.night-summary i { font-style: normal; font-size: 10.5px; color: var(--muted); }
.night-summary b { font-size: 15.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.night .card { margin-bottom: 12px; }
.night-list { padding: 6px 0 8px; }
.nl-row { display: flex; align-items: center; gap: 10px; padding: 11px 16px; border-top: 1px solid var(--line-2); }
.nl-row:first-child { border-top: 0; }
.nl-ico { width: 24px; height: 24px; border-radius: 8px; background: var(--green-bg); color: var(--green); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.nl-ico svg { width: 14px; height: 14px; }
.nl-row.bad .nl-ico { background: var(--red-bg); color: var(--red); }
.nl-main { flex: 1; display: flex; flex-direction: column; }
.nl-main b { font-size: 13px; font-weight: 600; }
.nl-main span { font-size: 11px; color: var(--muted); }
.nl-val { font-size: 12.5px; font-weight: 650; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.night-block { padding: 0 16px 16px; }
.night-block p { font-size: 12px; color: var(--red); margin-bottom: 8px; }
.block-item {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 11px 12px; margin-bottom: 6px;
  background: #FDF4F2; border: 1px solid #F7DDD8; border-radius: 10px;
  text-align: left;
}
.block-item b { font-size: 15px; font-weight: 700; }
.block-item span { flex: 1; font-size: 12px; color: var(--ink-2); }
.block-item svg { width: 14px; height: 14px; color: #C08E86; }

.log-list { padding: 6px 16px 14px; }
.log-row { display: flex; gap: 10px; padding: 7px 0; }
.log-dot { width: 6px; height: 6px; border-radius: 99px; background: var(--brand); margin-top: 7px; flex: 0 0 auto; }
.log-row b { display: block; font-size: 12px; font-weight: 550; color: var(--ink-2); line-height: 1.5; }
.log-row i { font-style: normal; font-size: 10.5px; color: var(--muted); }

/* ---------------- 更多 ---------------- */
.profile-card {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  padding: 16px; box-shadow: var(--shadow);
}
.pc-main { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.pc-main b { font-size: 16px; font-weight: 680; }
.pc-main span { font-size: 11.5px; color: var(--muted); }
.pc-badge { font-size: 10.5px; font-weight: 650; color: var(--green); background: var(--green-bg); padding: 3px 8px; border-radius: 99px; }

.menu-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); }
.menu-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 15px; border-top: 1px solid var(--line-2); text-align: left; }
.menu-row:first-child { border-top: 0; }
.menu-row:active { background: #FAFBFC; }
.mr-ico { width: 34px; height: 34px; border-radius: 10px; background: #F2F4F7; color: var(--ink-2); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.mr-ico svg { width: 18px; height: 18px; }
.mr-main { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.mr-main b { font-size: 14px; font-weight: 600; }
.mr-main i { font-style: normal; font-size: 11px; color: var(--muted); }
.menu-row > svg { width: 15px; height: 15px; color: #C6CDD8; }
.menu-row.danger .mr-ico { background: var(--red-bg); color: var(--red); }
.menu-row.danger .mr-main b { color: var(--red); }

.about-card { display: flex; align-items: center; gap: 12px; padding: 8px 4px; }
.about-logo {
  width: 46px; height: 46px; border-radius: 14px;
  background: linear-gradient(145deg, #0F7C6A, #0A5B4E); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; font-weight: 700; letter-spacing: 1px;
  box-shadow: 0 6px 14px rgba(14, 122, 104, .26);
}
.about-card b { display: block; font-size: 14px; }
.about-card span { font-size: 11.5px; color: var(--muted); }

.log-page { padding-top: 10px; }
.op-log { display: flex; gap: 10px; padding: 11px 12px; background: #fff; border: 1px solid var(--line); border-radius: 11px; }
.ol-time { font-size: 11px; color: var(--muted); text-align: right; width: 46px; flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.ol-time i { display: block; font-style: normal; font-size: 9.5px; opacity: .7; }
.ol-main { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.ol-main b { font-size: 12.5px; font-weight: 650; }
.ol-main span { font-size: 11.5px; color: var(--ink-2); line-height: 1.5; }
.ol-user { font-size: 10.5px; color: var(--muted); align-self: flex-start; }

/* ---------------- 弹层 ---------------- */
#layers { position: fixed; inset: 0; pointer-events: none; z-index: 50; }
.layer { position: fixed; inset: 0; display: flex; align-items: flex-end; justify-content: center; pointer-events: auto; }
.layer.out { pointer-events: none; }
.backdrop { position: absolute; inset: 0; background: rgba(16, 24, 40, .42); opacity: 0; transition: opacity .22s ease; backdrop-filter: blur(1px); }
.layer.in .backdrop { opacity: 1; }
.layer.out .backdrop { opacity: 0; }

.sheet {
  position: relative; width: 100%; max-width: 430px;
  max-height: 88dvh; overflow-y: auto;
  background: #F7F8FA;
  border-radius: 22px 22px 0 0;
  padding: 6px 16px calc(14px + var(--safe-b));
  transform: translateY(100%);
  transition: transform .28s cubic-bezier(.22, .85, .28, 1);
  box-shadow: 0 -10px 40px rgba(16, 24, 40, .16);
  scrollbar-width: none;
}
.sheet::-webkit-scrollbar { display: none; }
.layer.in .sheet { transform: translateY(0); }
.layer.out .sheet { transform: translateY(100%); }
.sheet-grip { width: 36px; height: 4px; border-radius: 99px; background: #D8DDE5; margin: 4px auto 6px; }
.sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; padding: 4px 0 10px; }
.sheet-title-wrap h3 { font-size: 17px; font-weight: 680; }
.sheet-title-wrap p { font-size: 12px; color: var(--muted); margin-top: 1px; }
.sheet-head-body { padding-bottom: 6px; }
.sheet-list { display: flex; flex-direction: column; gap: 2px; background: #fff; border-radius: 14px; overflow: hidden; }
.sheet-item {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px; width: 100%; text-align: left;
  border-top: 1px solid var(--line-2);
  transition: background .14s ease;
}
.sheet-item:first-child { border-top: 0; }
.sheet-item:active { background: #F5F7F9; }
.si-ico { width: 30px; height: 30px; border-radius: 9px; background: #F2F4F7; color: var(--ink-2); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.si-ico svg { width: 17px; height: 17px; }
.si-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.si-label { font-size: 14.5px; font-weight: 550; }
.si-sub { font-size: 11.5px; color: var(--muted); }
.sheet-item.danger .si-label { color: var(--red); }
.sheet-item.danger .si-ico { background: var(--red-bg); color: var(--red); }
.sheet-foot { padding-top: 10px; }

.sheet-room { background: #fff; border-radius: 14px; padding: 14px; }
.sheet-guest { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 14px; padding: 13px 14px; }
.sheet-guest > div { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.sheet-guest b { font-size: 15px; display: flex; align-items: center; gap: 6px; }
.sheet-guest span { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-note { display: flex; align-items: center; gap: 6px; background: #fff; border-radius: 14px; padding: 13px 14px; font-size: 12.5px; color: var(--muted); }
.sheet-note b { font-size: 14px; color: var(--ink); font-weight: 650; }
.sheet-note i { font-style: normal; opacity: .5; }
.sr-num { font-size: 30px; font-weight: 720; letter-spacing: -1px; line-height: 1.1; }
.sr-meta { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--muted); margin-top: 3px; }
.sr-meta i { font-style: normal; opacity: .5; }
.sr-guest { display: flex; align-items: center; gap: 9px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.sr-guest > div { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.sr-guest b { font-size: 14px; }
.sr-guest span { font-size: 11px; color: var(--muted); }

/* 确认框 */
.confirm-layer { align-items: center; }
.confirm {
  position: relative; width: calc(100% - 56px); max-width: 320px;
  background: #fff; border-radius: 18px; padding: 20px;
  text-align: center;
  transform: scale(.92); opacity: 0;
  transition: transform .2s cubic-bezier(.2, .9, .3, 1.2), opacity .18s ease;
  box-shadow: var(--shadow-lg);
}
.layer.in .confirm { transform: scale(1); opacity: 1; }
.confirm h3 { font-size: 16px; font-weight: 680; margin-bottom: 6px; }
.confirm p { font-size: 13px; color: var(--ink-2); line-height: 1.55; }
.confirm-actions { display: flex; gap: 8px; margin-top: 18px; }
.confirm-actions .btn { flex: 1; height: 42px; font-size: 14.5px; }

/* 轻提示 */
#toasts {
  position: fixed; left: 0; right: 0; bottom: calc(136px + var(--safe-b));
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  z-index: 200; pointer-events: none;
}
.toast {
  display: inline-flex; align-items: center; gap: 7px;
  max-width: 86vw;
  background: rgba(16, 24, 40, .92);
  color: #fff; font-size: 13px; font-weight: 500;
  padding: 10px 15px; border-radius: 99px;
  opacity: 0; transform: translateY(10px) scale(.96);
  transition: all .22s cubic-bezier(.2, .9, .3, 1.1);
  box-shadow: 0 10px 24px rgba(16, 24, 40, .22);
  backdrop-filter: blur(8px);
}
.toast.in { opacity: 1; transform: translateY(0) scale(1); }
.toast svg { width: 16px; height: 16px; flex: 0 0 auto; }
.toast.ok svg { color: #5FD3B6; }
.toast.warn svg { color: #F5B544; }

/* 启动页 */
.boot {
  position: fixed; inset: 0; z-index: 300;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  background: linear-gradient(165deg, #0F7C6A 0%, #0A5348 100%);
  color: #fff;
  transition: opacity .4s ease, visibility .4s ease;
}
.boot.hide { opacity: 0; visibility: hidden; }
.boot-mark {
  width: 66px; height: 66px; border-radius: 20px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .22);
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; font-weight: 600; letter-spacing: 2px;
  margin-bottom: 12px;
  animation: breathe 2.4s ease-in-out infinite;
}
.boot-text { font-size: 17px; font-weight: 650; letter-spacing: 2px; }
.boot-sub { font-size: 11.5px; color: rgba(255, 255, 255, .6); margin-top: 2px; }
.boot-error { padding: 24px; text-align: center; font-size: 14px; line-height: 1.7; color: #fff; }
.boot-error span { font-size: 12px; opacity: .7; }

@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ==================================================================
   首次初始化向导
   ================================================================== */
.setup-root { min-height: 100vh; min-height: 100dvh; background: var(--bg); }
.wizard {
  display: flex; flex-direction: column;
  max-width: 430px; margin: 0 auto;
  height: 100vh; height: 100dvh; background: var(--bg);
  position: relative;
}
.wz-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 20px 10px;
  background: #fff; border-bottom: 1px solid var(--line);
}
.wz-brand { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 650; color: var(--ink-2); }
.wz-logo {
  width: 26px; height: 26px; border-radius: 8px;
  background: linear-gradient(145deg, #0F7C6A, #0A5B4E); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; letter-spacing: 1px;
}
.wz-dots { display: flex; gap: 5px; }
.wz-dots i { width: 6px; height: 6px; border-radius: 99px; background: #DDE2EA; transition: all .2s ease; }
.wz-dots i.done { background: #9FD3C6; }
.wz-dots i.on { width: 18px; background: var(--brand); }
.wz-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding-bottom: 18px; }
.wz-foot {
  padding: 10px 20px calc(14px + var(--safe-b));
  background: #fff; border-top: 1px solid var(--line);
}
.wz-foot-row { display: flex; gap: 10px; }
.wz-foot-row .btn { flex: 1; }
.wz-foot-row .btn.ghost { flex: 0 0 34%; }
.wz-foot-col { display: flex; flex-direction: column; gap: 8px; }
.wz-foot-col .btn { width: 100%; }

.wz-hero { padding: 34px 20px 0; text-align: center; }
.wz-mark {
  width: 68px; height: 68px; border-radius: 22px; margin: 0 auto 18px;
  background: linear-gradient(150deg, #12907A, #0A5B4E); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; font-weight: 600; letter-spacing: 2px;
  box-shadow: 0 14px 30px rgba(14, 122, 104, .28);
}
.wz-mark.ok { background: linear-gradient(150deg, #17A98C, #0B6B5A); }
.wz-mark svg { width: 34px; height: 34px; stroke-width: 2.2; }
.wz-hero h1 { font-size: 22px; font-weight: 700; letter-spacing: -.4px; }
.wz-hero > p { font-size: 13px; color: var(--muted); line-height: 1.7; margin-top: 8px; }
.wz-steps-list { list-style: none; padding: 0; margin: 24px 0 0; display: flex; flex-direction: column; gap: 10px; text-align: left; }
.wz-steps-list li {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.wz-steps-list li > b {
  width: 28px; height: 28px; flex: 0 0 auto; border-radius: 9px;
  background: var(--brand-50); color: var(--brand-600);
  display: flex; align-items: center; justify-content: center; font-size: 13px;
}
.wz-steps-list li span { display: flex; flex-direction: column; gap: 1px; }
.wz-steps-list li span b { font-size: 14px; font-weight: 650; }
.wz-steps-list li span i { font-style: normal; font-size: 11.5px; color: var(--muted); }
.wz-tip { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin-top: 18px; }

.wz-title { padding: 22px 20px 4px; }
.wz-title h2 { font-size: 20px; font-weight: 700; letter-spacing: -.3px; }
.wz-title p { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.wz-sub { font-size: 12px; font-weight: 650; color: var(--ink-2); }
.wz-empty {
  padding: 20px; text-align: center; font-size: 12.5px; color: var(--muted);
  background: #fff; border: 1px dashed var(--line); border-radius: 12px;
}
.wz-list { display: flex; flex-direction: column; gap: 8px; }
.wz-item {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 8px 12px 14px;
}
.wz-item-main { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.wz-item-main b { font-size: 14px; font-weight: 650; }
.wz-item-main span { font-size: 11.5px; color: var(--muted); }
.wz-item .icon-btn { width: 32px; height: 32px; color: var(--muted); }
.wz-item .icon-btn svg { width: 16px; height: 16px; }
.req { font-style: normal; color: var(--red); }

.wz-room-preview {
  background: var(--brand-50); color: var(--brand-600);
  border: 1px solid #D3E9E3; border-radius: 11px;
  padding: 11px 13px; font-size: 12.5px; font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.wz-floors { display: flex; flex-direction: column; gap: 10px; }
.wz-floor { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.wz-floor-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.wz-floor-head b { font-size: 13px; font-weight: 700; }
.wz-floor-head span { font-size: 11.5px; color: var(--muted); }
.wz-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.wz-chip {
  font-size: 12px; padding: 5px 9px; border-radius: 7px;
  background: #F3F5F8; color: var(--ink-2); font-variant-numeric: tabular-nums;
}
.wz-chip:active { background: var(--red-bg); color: var(--red); }
.wz-done-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 22px; }
.wz-done-grid > div { background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 14px 8px; display: flex; flex-direction: column; gap: 2px; }
.wz-done-grid b { font-size: 22px; font-weight: 720; color: var(--brand-600); font-variant-numeric: tabular-nums; }
.wz-done-grid span { font-size: 11px; color: var(--muted); }

/* ==================================================================
   新手引导 / 教程
   ================================================================== */
.tour-layer { align-items: stretch; justify-content: center; }
.tour {
  width: 100%; max-width: 430px; height: 100%;
  background: linear-gradient(170deg, #0F7C6A 0%, #0A5B4E 62%, #08483E 100%);
  color: #fff; display: flex; flex-direction: column;
  padding: calc(16px + env(safe-area-inset-top, 0px)) 24px calc(20px + var(--safe-b));
}
.tour-top { display: flex; align-items: center; justify-content: space-between; }
.tour-brand { font-size: 11.5px; color: rgba(255, 255, 255, .6); letter-spacing: .4px; }
.tour .link { color: rgba(255, 255, 255, .78); }
.tour-body { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: left; padding-bottom: 14vh; }
.tour-ico {
  width: 60px; height: 60px; border-radius: 18px; margin-bottom: 22px;
  background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .2);
  display: flex; align-items: center; justify-content: center;
}
.tour-ico svg { width: 28px; height: 28px; }
.tour-body h2 { font-size: 26px; font-weight: 700; letter-spacing: -.5px; line-height: 1.3; }
.tour-body p { font-size: 14px; line-height: 1.75; color: rgba(255, 255, 255, .78); margin-top: 12px; }
.tour-foot { display: flex; flex-direction: column; gap: 18px; }
.tour-dots { display: flex; gap: 6px; }
.tour-dots i { width: 6px; height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .3); }
.tour-dots i.on { width: 20px; background: #fff; }
.tour-actions { display: flex; gap: 10px; }
.tour-actions .btn { flex: 1; }
.tour-actions .btn.primary { background: #fff; color: var(--brand-600); box-shadow: none; }
.tour-actions .btn.ghost { background: rgba(255, 255, 255, .14); color: #fff; }
.tour-actions span { flex: 1; }

.tut { padding: 16px 16px 0; }
.tut-hero { display: flex; gap: 12px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 15px; }
.tut-ico { width: 42px; height: 42px; border-radius: 12px; background: var(--brand-50); color: var(--brand-600); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.tut-ico svg { width: 21px; height: 21px; }
.tut-hero h2 { font-size: 16px; font-weight: 680; }
.tut-hero p { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.tut-steps { margin: 14px 0; display: flex; flex-direction: column; gap: 10px; }
.tut-step { display: flex; gap: 11px; background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 13px; }
.ts-num { width: 22px; height: 22px; flex: 0 0 auto; border-radius: 7px; background: #F2F4F7; color: var(--ink-2); font-size: 11.5px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.ts-main b { display: block; font-size: 13.5px; font-weight: 650; margin-bottom: 3px; }
.ts-main span { font-size: 12px; color: var(--ink-2); line-height: 1.65; }
.tut .btn { margin-top: 8px; }

.tut-list { padding: 12px 16px 0; display: flex; flex-direction: column; gap: 8px; }
.tut-row {
  display: flex; align-items: center; gap: 12px; width: 100%;
  background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 13px;
  text-align: left;
}
.tut-row:active { background: #FAFBFC; }
.tr2-ico { width: 36px; height: 36px; border-radius: 11px; background: var(--brand-50); color: var(--brand-600); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.tr2-ico svg { width: 18px; height: 18px; }
.tr2-main { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.tr2-main b { font-size: 14px; font-weight: 650; }
.tr2-main i { font-style: normal; font-size: 11.5px; color: var(--muted); }
.tut-row > svg { width: 15px; height: 15px; color: #C6CDD8; }

/* 顶栏帮助按钮 */
.tb-actions { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.tb-help {
  width: 34px; height: 34px; border-radius: 99px;
  border: 1px solid var(--line); background: #fff;
  color: var(--muted); font-size: 13px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
  flex: 0 0 auto;
}
.tb-help:active { background: #F2F4F7; }

/* 空状态引导 */
.onboard { padding: 40px 22px 0; text-align: center; }
.ob-ico {
  width: 66px; height: 66px; margin: 0 auto 16px; border-radius: 20px;
  background: #fff; border: 1px solid var(--line); color: var(--brand);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 20px rgba(16, 24, 40, .06);
}
.ob-ico svg { width: 30px; height: 30px; }
.onboard h2 { font-size: 19px; font-weight: 700; }
.onboard > p { font-size: 13px; color: var(--muted); line-height: 1.7; margin: 8px 0 20px; }
.ob-flow { display: flex; flex-direction: column; gap: 9px; margin-bottom: 22px; text-align: left; }
.ob-flow > div { display: flex; align-items: center; gap: 11px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.ob-flow b { width: 26px; height: 26px; border-radius: 8px; background: var(--brand-50); color: var(--brand-600); font-size: 12px; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.ob-flow span { font-size: 13px; font-weight: 600; }
.ob-flow i { font-style: normal; font-size: 11px; color: var(--muted); margin-left: auto; }
.onboard .btn + .btn { margin-top: 9px; }

/* 房间分组 */
.room-group { background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 12px; }
.rg-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 9px; }
.rg-head b { font-size: 13px; font-weight: 700; }
.rg-head span { font-size: 11.5px; color: var(--muted); }
.rg-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.rg-chip {
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  padding: 6px 10px; border-radius: 8px; background: #F3F5F8;
  font-size: 12.5px; font-weight: 650; font-variant-numeric: tabular-nums;
  border-left: 3px solid #DDE2EA;
}
.rg-chip i { font-style: normal; font-size: 9.5px; font-weight: 500; color: var(--muted); }
.rg-chip.st-occ { background: #F2F6FF; border-left-color: var(--blue); }
.rg-chip.st-booked { background: #F7F4FF; border-left-color: var(--violet); }
.rg-chip.st-dirty { background: #FFF9F2; border-left-color: var(--amber); }
.rg-chip.st-ooo { background: #FBF3F2; border-left-color: var(--red); }
.rg-chip.st-clean { border-left-color: #BFE3D7; }

/* ==================================================================
   房态图例与状态配色
   ================================================================== */
.legend {
  display: flex; gap: 6px; margin-top: 9px;
  overflow: hidden;
}
.lg {
  flex: 1 1 0; min-width: 0;
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  height: 27px; padding: 0 4px; border-radius: 8px;
  font-size: 11px; font-weight: 600; white-space: nowrap;
  border: 1px solid transparent;
  transition: box-shadow .15s ease, transform .12s ease;
}
.lg s { width: 6px; height: 6px; border-radius: 2px; background: currentColor; text-decoration: none; flex: 0 0 auto; }
.lg b { font-weight: 700; font-variant-numeric: tabular-nums; }
.lg.on { box-shadow: 0 0 0 2px rgba(16, 24, 40, .14); }
.lg:active { transform: scale(.96); }
.lg-rate { background: #fff; border-color: var(--line); color: var(--ink); gap: 4px; }
.lg-rate b { font-size: 13px; }
.lg-rate i { font-style: normal; color: var(--muted); font-weight: 500; }
.lg-occ { background: #D6E4FF; color: #123FC4; border-color: #8FB4FF; }
.lg-booked { background: #E5D8FC; color: #5F25B8; border-color: #B693F0; }
.lg-clean { background: #D2F1E1; color: #0A6B4B; border-color: #8ED9B5; }
.lg-dirty { background: #FFE1BC; color: #94470A; border-color: #F2B366; }
.lg-ooo { background: #FAD1C9; color: #96271A; border-color: #EE9A8C; }

/* 房态卡片：颜色即状态（高对比版本） */
.room-card.st-occ { background: #D8E5FF; border-color: #8FB4FF; }
.room-card.st-occ::before { background: #123FC4; width: 4px; }
.room-card.st-booked { background: #E6D9FD; border-color: #B693F0; }
.room-card.st-booked::before { background: #6526C9; width: 4px; }
.room-card.st-clean { background: #D6F2E3; border-color: #8ED9B5; }
.room-card.st-clean::before { background: #0A7A55; width: 4px; }
.room-card.st-dirty { background: #FFE4C2; border-color: #F2B366; }
.room-card.st-dirty::before { background: #B45309; width: 4px; }
.room-card.st-ooo { background: #FBD5CE; border-color: #EE9A8C; }
.room-card.st-ooo::before { background: #A93226; opacity: .9; width: 4px; }
.room-card.st-ooo .rc-num { color: #8A2B20; }
.room-card.st-occ .rc-badge { background: #123FC4; color: #fff; }
.room-card.st-booked .rc-badge { background: #6526C9; color: #fff; }
.room-card.st-clean .rc-badge { background: #0A7A55; color: #fff; }
.room-card.st-dirty .rc-badge { background: #B45309; color: #fff; }
.room-card.st-cleaning .rc-badge { background: #11707E; color: #fff; }
.room-card.st-ooo .rc-badge { background: #A93226; color: #fff; }
.room-card .rc-type { color: #5A6678; }
.room-card .rc-num { color: var(--ink); }
.rc-guest { min-width: 0; }
.rc-name { flex: 1 1 auto; min-width: 0; }
.rc-meta { flex: 0 0 auto; }
.rc-foot {
  margin-top: 3px; font-size: 10.5px; color: #5E6B7E;
  font-variant-numeric: tabular-nums;
}

.room-grid-all { padding-top: 12px; }

/* ==================================================================
   经营类型选择（酒店 / 民宿）
   ================================================================== */
.mode-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 20px 0 4px; }
.mode-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  background: #fff; border: 1.5px solid var(--line); border-radius: 14px;
  padding: 14px 14px 13px; text-align: left;
  transition: all .16s ease;
}
.mode-card b { font-size: 16px; font-weight: 700; }
.mode-card i, .mode-card b { max-width: 100%; overflow-wrap: anywhere; }
.mode-card i { font-style: normal; font-size: 11px; color: var(--muted); }
.mode-card.on {
  border-color: var(--brand); background: var(--brand-50);
  box-shadow: 0 4px 14px rgba(14, 122, 104, .12);
}
.mode-card.on b { color: var(--brand-600); }
.mode-card.on i { color: #4E8C7F; }

/* ==================================================================
   数据备份 / 诊断
   ================================================================== */
.backup-text {
  width: 100%; height: 220px; padding: 12px;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 11px; line-height: 1.5;
  resize: vertical; white-space: pre; overflow: auto;
  background: #fff; border: 1px solid var(--line); border-radius: 11px;
  color: var(--ink-2);
}
.diag-card {
  background: #fff; border: 1px solid var(--line); border-radius: 13px;
  overflow: hidden;
}
.diag-row {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 11px 14px; border-top: 1px solid var(--line-2);
  font-size: 12px;
}
.diag-row:first-child { border-top: 0; }
.diag-row i { flex: 0 0 78px; font-style: normal; color: var(--muted); }
.diag-row b { flex: 1; font-weight: 550; color: var(--ink-2); word-break: break-all; }

/* ==================================================================
   远期房态
   ================================================================== */
.tb-help svg { width: 16px; height: 16px; }
.head-link { font-size: 12.5px; color: var(--brand); font-weight: 650; background: none; padding: 8px 6px; min-height: 32px; min-width: 44px; text-align: center; }

.cal { display: flex; flex-direction: column; min-height: 0; }
.cal-toolbar { padding: 10px 16px 8px; }
.cal-scroll {
  overflow: auto; max-height: calc(100vh - 250px); max-height: calc(100dvh - 250px);
  -webkit-overflow-scrolling: touch;
  border-top: 1px solid var(--line);
}
.cal-table { border-collapse: separate; border-spacing: 0; font-size: 11px; }
.cal-table { background: #fff; }
.cal-table th, .cal-table td { border-right: 1px solid #E4E9F0; border-bottom: 1px solid #E4E9F0; }
.cal-corner {
  position: sticky; left: 0; top: 0; z-index: 3; background: #fff;
  width: 58px; min-width: 58px; padding: 6px 4px; color: var(--muted); font-size: 9.5px; font-weight: 500;
}
.cal-day { position: sticky; top: 0; z-index: 2; background: #fff; min-width: 52px; padding: 5px 2px; text-align: center; font-weight: 500; }
.cal-day b { display: block; font-size: 11.5px; color: var(--ink); font-variant-numeric: tabular-nums; }
.cal-day i { display: block; font-style: normal; font-size: 9px; color: var(--muted); }
.cal-day em { display: block; font-style: normal; font-size: 9px; color: var(--green); font-weight: 700; }
.cal-day.today { background: #E9F0FF; }
.cal-day.today b { color: var(--blue); }
.cal-day.today i { color: var(--blue); }
.cal-room {
  position: sticky; left: 0; z-index: 1; background: #fff;
  width: 58px; min-width: 58px; padding: 6px 4px; text-align: left; font-weight: 500;
}
.cal-room b { display: block; font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cal-room i { display: block; font-style: normal; font-size: 9px; color: var(--muted); max-width: 52px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-cell { width: 52px; min-width: 52px; height: 38px; text-align: center; font-size: 10px; font-weight: 700; cursor: pointer; background: #fff; }
.cal-cell.s-free { background: #fff; }
.cal-cell.s-booked { background: #EDE6FE; color: #6D3AC7; }
.cal-cell.s-occ { background: #E3ECFF; color: #1D4ED8; }
.cal-cell.s-ooo { background: #FBE3E0; color: #B03A2C; }
.cal-cell.s-past { background: #F7F8FA; }
.cal-cell.s-free:active { background: #F0FBF6; }
.cal-foot { display: flex; gap: 16px; align-items: center; }
.cf-item { display: flex; align-items: baseline; gap: 4px; }
.cf-item b { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cf-item i { font-style: normal; font-size: 10.5px; color: var(--muted); }
.c-blue { color: var(--blue); }
.c-violet { color: var(--violet); }
.c-green { color: var(--green); }
.c-red { color: var(--red); }

.cal-cell-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cal-cell-head > div { display: flex; flex-direction: column; }
.cal-cell-head b { font-size: 18px; font-weight: 700; }
.cal-cell-head span { font-size: 11.5px; color: var(--muted); }
.cal-cell-date { font-size: 12px; color: var(--muted); margin: 4px 0 10px; }
.day-block { padding: 4px 0 8px; }
.day-block h4 { font-size: 12px; font-weight: 650; margin-bottom: 6px; color: var(--ink-2); }
.day-list { display: flex; flex-wrap: wrap; gap: 5px; }
.day-chip { font-size: 11.5px; padding: 3px 7px; border-radius: 6px; font-variant-numeric: tabular-nums; }
.day-chip.blue { background: var(--blue-bg); color: var(--blue); }
.day-chip.violet { background: var(--violet-bg); color: var(--violet); }
.day-chip.green { background: var(--green-bg); color: var(--green); }
.day-chip.red { background: var(--red-bg); color: var(--red); }

/* ==================================================================
   搜索
   ================================================================== */
.search-sec { font-size: 11.5px; color: var(--muted); padding: 10px 4px 2px; font-weight: 600; }
.search-hint { padding: 40px 20px; text-align: center; color: var(--muted); font-size: 12.5px; line-height: 2; }
.search-hint b { color: var(--ink-2); }
.search-empty { padding: 48px 20px; }
.sr-num {
  width: 46px; height: 40px; flex: 0 0 auto; border-radius: 10px;
  background: var(--brand-50); color: var(--brand-600);
  display: flex; align-items: center; justify-content: center;
  font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums;
}

/* ==================================================================
   批量编辑（房间 / 房型）
   ================================================================== */
.head-link { padding: 6px 2px; }
.page-foot:empty { display: none; }
.batch-bar { display: flex; align-items: center; gap: 8px; }
.bb-count { flex: 1; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.batch-bar .btn { height: 42px; padding: 0 16px; }
.batch-bar .btn.danger:disabled,
.batch-bar .btn.ghost:disabled { opacity: .45; }

.rg-chip.on {
  background: var(--brand-50) !important;
  color: var(--brand-600) !important;
  box-shadow: 0 0 0 2px var(--brand);
  border-left-color: var(--brand) !important;
}
.rg-chip.on i { color: var(--brand-600) !important; }

.type-row.sel-row { cursor: pointer; }
.type-row.sel-row:active { background: #FAFBFC; }
.type-row.on { border-color: var(--brand); background: var(--brand-50); }
.sel-box {
  width: 22px; height: 22px; flex: 0 0 auto; border-radius: 7px;
  border: 1.5px solid var(--line); background: #fff;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
}
.sel-box svg { width: 14px; height: 14px; }
.type-row.on .sel-box { background: var(--brand); border-color: var(--brand); }

/* ==================================================================
   iOS / Safari 适配
   ================================================================== */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  touch-action: manipulation;
}
button, [data-act], .tab, .chip, .room-card { -webkit-tap-highlight-color: transparent; }

/* iOS 聚焦输入框不小于 16px，否则会自动放大页面 */
.input, input.input, select.input, textarea { font-size: 16px; }
input:not([type="checkbox"]):not([type="radio"]), select, textarea { font-size: 16px; }
.tr-input input, .field-inline input, .search-bar input { font-size: 16px; }

/* 刘海屏横向安全区 */
.topbar, .page-head { padding-left: max(12px, env(safe-area-inset-left)); padding-right: max(12px, env(safe-area-inset-right)); }
.tabbar { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }

/* iOS 上整页不跟随橡皮筋，滚动交给内部容器 */
body, .app { overscroll-behavior: none; }
.page-body, .view { -webkit-overflow-scrolling: touch; }

/* 独立窗口（添加到主屏幕）时去掉浏览器下边距 */
@media (display-mode: standalone) {
  .app { max-width: none; }
}






/* 表单底部的小字链接（切换登录方式、去注册） */
.link-row { display:flex; align-items:center; justify-content:center; gap:4px; margin-top:10px; font-size:13px; }
.link-row .link-tip { color: var(--mut); }
.link-row .link { background:none; border:0; padding:0 2px; color:#0E7A68; font-size:13px; text-decoration:underline; text-underline-offset:2px; }
/* 民宿保洁看板：房间网格，未打扫标红 */
.hk-tip { padding: 10px 16px 4px; font-size: 12.5px; color: var(--mut); }
.hk-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px; padding:8px 16px 0; }
.hk-room {
  position:relative; display:flex; flex-direction:column; gap:2px;
  padding:12px 12px 10px; border-radius:14px; text-align:left;
  background:#fff; border:1px solid var(--line);
}
.hk-room .hr-num { font-size:21px; font-weight:800; letter-spacing:.5px; }
.hk-room .hr-status { font-size:12px; font-weight:600; }
.hk-room .hr-type { font-size:11.5px; color:var(--mut); }
.hk-room.dirty { background:#FDECEA; border-color:#F3C9C3; }
.hk-room.dirty .hr-status { color:#B03A2C; }
.hk-room.clean { background:#E6F7F0; border-color:#C7EBDD; }
.hk-room.clean .hr-status { color:#0B7A55; }
.hk-room.booked { background:#F1EBFD; border-color:#DCCEF8; }
.hk-room.booked .hr-status { color:#5B3FA8; }
.hk-room.occ { background:#E8F0FE; border-color:#C9D9F8; }
.hk-room.occ .hr-status { color:#1A56B8; }
.hk-room.ooo { background:#F3F4F6; border-color:#E2E4E8; }
.hk-room.ooo .hr-status { color:#6B7280; }
/* 打扫中（保洁已开始打扫） */
.st-cleaning { background: linear-gradient(180deg, #F3FBFD 0%, #FFFFFF 70%); }
.st-cleaning::before { background: #2BA3B5; }
.rg-chip.st-cleaning { background: #F1FAFC; border-left-color: #2BA3B5; }
.lg-cleaning s { background: #2BA3B5; }
/* 酒店保洁任务卡 */
.hk-task { display:flex; flex-direction:column; gap:6px; padding:12px; border-radius:14px; background:#fff; border:1px solid var(--line); }
.hk-task.dirty { background:#FDECEA; border-color:#F3C9C3; }
.hk-task.cleaning { background:#EAF7FA; border-color:#BFE4EC; }
.ht-top { display:flex; align-items:center; justify-content:space-between; }
.ht-num { font-size:20px; font-weight:800; }
.ht-badge { font-size:11px; font-weight:700; padding:2px 7px; border-radius:6px; color:#fff; }
.ht-badge.dirty { background:#B03A2C; }
.ht-badge.cleaning { background:#11707E; }
.ht-meta { font-size:11.5px; color:var(--mut); }
.ht-actions { display:flex; justify-content:flex-end; margin-top:2px; }
.ht-hint { font-size:11.5px; color:#11707E; }
.wz-body > .mode-picker { margin: 12px 20px 4px; }

/* ===== 日账单 / 月账单 ===== */
.day-nav { display:flex; align-items:center; gap:8px; padding:10px 2px 2px; }
.dn-btn { width:34px; height:34px; border-radius:10px; border:1px solid var(--line); background:#fff; font-size:20px; line-height:1; color:var(--ink); display:flex; align-items:center; justify-content:center; }
.dn-btn:disabled { opacity:.35; }
.dn-main { flex:1; display:flex; align-items:center; justify-content:center; gap:8px; font-size:14px; font-weight:600; position:relative; }
.dn-main .dn-input { position:absolute; inset:0; width:100%; height:100%; opacity:0; border:0; }
.dn-today { border:0; background:none; color:#0E7A68; font-size:12.5px; text-decoration:underline; }
.book-list { display:flex; flex-direction:column; }
.bk-row { display:flex; align-items:center; gap:10px; padding:10px 2px; border-bottom:1px dashed var(--line); }
.bk-row:last-child { border-bottom:0; }
.bk-main { flex:1; min-width:0; }
.bk-main b { display:block; font-size:13.5px; font-weight:600; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.bk-main span { display:block; font-size:11.5px; color:var(--mut); margin-top:2px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.bk-amt { font-size:14px; font-weight:700; font-variant-numeric:tabular-nums; white-space:nowrap; }
.bk-amt.in { color:#0B7A55; }
.bk-amt.out { color:#B45309; }
.mk-list { display:flex; flex-direction:column; }
.mk-row { display:flex; align-items:center; gap:10px; padding:9px 2px; border:0; background:none; text-align:left; border-bottom:1px dashed var(--line); }
.mk-row:last-child { border-bottom:0; }
.mk-date { width:38px; display:flex; flex-direction:column; align-items:center; }
.mk-date b { font-size:15px; font-weight:700; }
.mk-date i { font-size:10px; color:var(--mut); font-style:normal; }
.mk-bar { flex:1; height:6px; border-radius:4px; background:#EEF2F1; overflow:hidden; }
.mk-bar i { display:block; height:100%; background:linear-gradient(90deg,#0E7A68,#35B79A); border-radius:4px; }
.mk-nums { width:104px; text-align:right; }
.mk-nums b { display:block; font-size:13px; font-weight:700; font-variant-numeric:tabular-nums; }
.mk-nums i { display:block; font-size:10.5px; color:var(--mut); font-style:normal; }
/* 卡片内列表留白：明细行不要贴着边框 */
.card > .book-list, .card > .mk-list { padding: 0 14px; }
.card > .mix { padding: 8px 16px 16px; }
/* 当日明细入口按钮 */
.detail-entry { display:flex; align-items:center; gap:12px; width:100%; padding:14px 16px; border:1px solid var(--line); background:var(--card); border-radius:var(--r); box-shadow:var(--shadow); text-align:left; }
.detail-entry .de-ico { width:34px; height:34px; border-radius:11px; background:#EAF4F1; color:#0E7A68; display:flex; align-items:center; justify-content:center; flex:0 0 auto; }
.detail-entry .de-main { flex:1; min-width:0; }
.detail-entry .de-main b { display:block; font-size:14px; font-weight:650; }
.detail-entry .de-main i { display:block; font-size:11.5px; color:var(--mut); font-style:normal; margin-top:2px; }
.detail-entry .de-more { font-size:12.5px; color:#0E7A68; font-weight:600; display:flex; align-items:center; gap:2px; flex:0 0 auto; white-space:nowrap; }
.src-other { display:flex; flex-wrap:wrap; gap:10px; align-items:baseline; padding:2px 16px 14px; font-size:12px; color:var(--mut); }
.src-other b { color:var(--ink); font-variant-numeric:tabular-nums; }
.src-other i { font-style:normal; color:#98A1AF; }

/* 空净房间上的未来预订提示：不改变房态，只提示 */
.room-card .future-hint { color: #3E63C4; }

/* 员工管理：成员行 */
.staff-row { display:flex; align-items:center; gap:10px; padding:12px 14px; border-bottom:1px solid var(--line); }
.staff-row:last-child { border-bottom:0; }
.staff-main { flex:1; min-width:0; }
.staff-main b { display:block; font-size:14px; font-weight:650; }
.staff-main span { display:block; font-size:12px; color:var(--mut); margin-top:2px; }
.staff-me { font-style:normal; font-size:10.5px; color:#0E7A68; background:#E7F4F0; border-radius:4px; padding:1px 4px; margin-left:2px; }
.staff-del { padding:6px 12px; font-size:12.5px; }

/* 远期房态：格子里显示客人姓名 */
.cal-cell { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 650; }
.cal-cell.s-occ, .cal-cell.s-booked { letter-spacing: -0.2px; }

/* 老 WebView 兼容：Chrome < 87 不认识 inset 简写，弹层会没有定位，表现为点了没反应 */
#fab-host, .page-layer, #layers, .layer, .backdrop, .boot, .dn-main .dn-input {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}

/* 房价开关 */
.tr-price-off { display:flex; align-items:center; gap:6px; font-size:12px; color:var(--mut); white-space:nowrap; }
.mini-btn.ghost { background:transparent; border:1px solid var(--line); color:var(--mut); }

/* ---------------- 隐私政策 / 首次同意 ---------------- */
.privacy-gate { position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(15,23,42,.58); z-index: 3000; display: flex; align-items: center; justify-content: center; padding: 18px; }
.pg-card { background: #fff; border-radius: 18px; max-width: 420px; width: 100%; max-height: 88vh; overflow: auto; padding: 22px 20px 18px; box-shadow: 0 18px 50px rgba(2,6,23,.28); }
.pg-brand { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #0f766e; margin-bottom: 6px; }
.pg-logo { width: 26px; height: 26px; border-radius: 8px; background: #0f766e; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.pg-card h2 { font-size: 19px; margin: 4px 0 8px; color: #0f172a; }
.pg-lead { font-size: 13px; color: #475569; line-height: 1.65; margin: 0 0 10px; }
.pg-list { margin: 0 0 10px; padding-left: 18px; font-size: 12.5px; color: #334155; line-height: 1.75; }
.pg-link { background: none; border: 0; color: #0f766e; font-size: 13px; padding: 4px 0; text-decoration: underline; }
.pg-actions { display: flex; gap: 10px; margin-top: 12px; }
.pg-actions .btn { flex: 1; }
.pg-foot { font-size: 11px; color: #94a3b8; margin: 12px 0 0; text-align: center; }
.pg-blocked { position: fixed; top: 0; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: center; padding: 24px; font-size: 15px; color: #475569; background: #f8fafc; text-align: center; }
.privacy-body { padding: 16px 18px 40px; font-size: 13.5px; line-height: 1.75; color: #334155; }
.privacy-body h3 { font-size: 15px; color: #0f172a; margin: 18px 0 6px; }
.privacy-body ul { padding-left: 18px; }
.privacy-body p { margin: 6px 0; }
.pv-meta { font-size: 12px; color: #94a3b8; }
.pv-table { width: 100%; border-collapse: collapse; font-size: 12px; margin: 8px 0 12px; }
.pv-table th, .pv-table td { border: 1px solid #e2e8f0; padding: 6px; text-align: left; vertical-align: top; }
.pv-table th { background: #f1f5f9; color: #0f172a; }

/* ---------------- 应用内更新 ---------------- */
.update-gate { position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(15,23,42,.58); z-index: 3200; display: flex; align-items: center; justify-content: center; padding: 18px; }
.update-card h2 { font-size: 19px; margin: 4px 0 8px; }
.update-notes { max-height: 180px; overflow: auto; font-size: 12.5px; line-height: 1.7; color: #475569; background: #f8fafc; border-radius: 10px; padding: 10px 12px; margin: 8px 0 4px; }
