/* Lotus House — hệ thống thiết kế
   Màu: nền trung tính + 1 màu nhấn (hồng sen) chỉ cho hành động chính và trạng thái đang chọn.
   Chiều sâu: viền mảnh 1px; đổ bóng chỉ cho thứ nổi lên (menu, hộp thoại, thông báo).
   Chuyển động: chỉ transform/opacity; 120ms (chạm) · 240ms (chuyển trạng thái) · 420ms (xuất hiện). */
:root {
  --bg: #f6f5f3;
  --surface: #ffffff;
  --sunken: #efedf0;
  --ink: #1b1a1f;
  --ink-2: #5d5b64;
  --ink-3: #8d8a94;
  --line: rgba(27, 26, 31, .10);
  --line-2: rgba(27, 26, 31, .18);

  --accent: #b8285f;
  --accent-press: #96194b;
  --accent-soft: #fbecf2;
  --accent-ink: #8d1a47;

  --ok: #137a4b;     --ok-soft: #e6f4ec;
  --warn: #93550a;   --warn-soft: #fdf1dc;
  --danger: #b42318; --danger-soft: #fdecea;
  --info: #3651b8;   --info-soft: #ebeffb;

  --r-sm: 8px; --r: 12px; --r-lg: 16px; --r-xl: 20px;
  --shadow-float: 0 12px 32px rgba(27, 26, 31, .12), 0 2px 6px rgba(27, 26, 31, .06);
  --shadow-pill: 0 1px 2px rgba(27, 26, 31, .10), 0 1px 1px rgba(27, 26, 31, .04);

  --dur-fast: 120ms; --dur: 240ms; --dur-slow: 420ms;
  --ease: cubic-bezier(.4, 0, .2, 1);
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  --ease-exit: cubic-bezier(.4, 0, 1, 1);

  /* Chữ: Fraunces (có chân, mềm như cánh sen) cho tiêu đề và con số lớn;
     Be Vietnam Pro (vẽ riêng cho tiếng Việt) cho mọi chữ còn lại. */
  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --nav-h: 66px;
  --side-w: 232px;
  --head-h: 64px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 15px/1.55 var(--font-body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
h1, h2, h3, #brandName, .hs-v, .big, .rname, .bamt, .total-v b, .month-label {
  font-family: var(--font-display); font-optical-sizing: auto; font-variant-numeric: lining-nums tabular-nums;
}
h1 { font-size: 28px; line-height: 1.1; margin: 0; font-weight: 500; letter-spacing: -.02em; }
h2 { font-size: 26px; line-height: 1.15; margin: 0; font-weight: 500; letter-spacing: -.02em; }
h3 { margin: 0 0 18px; font-size: 24px; line-height: 1.2; font-weight: 500; letter-spacing: -.02em; padding-right: 44px; }
h4 { margin: 0 0 12px; font-size: 12px; line-height: 1.3; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); font-weight: 600; }
a { color: var(--accent); }
button { font: inherit; color: inherit; }
.ic { flex: none; display: block; }
.small .ic, .muted .ic, .amber-text .ic { display: inline-block; vertical-align: -2px; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* ---------- Đầu trang + chọn tòa ---------- */
.top { position: sticky; top: 0; z-index: 30; background: rgba(246, 245, 243, .92); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top); }
.top-in { display: flex; align-items: center; gap: 10px; padding: 10px 16px 6px; }
.logo { width: 34px; height: 34px; border-radius: 10px; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.logo svg { width: 24px; height: 24px; }
/* Nút chuyển ngôn ngữ */
.lang-btn { min-width: 44px; height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--surface); font-weight: 700; font-size: 13px; letter-spacing: .06em; color: var(--ink-2); cursor: pointer; transition: background-color var(--dur-fast) var(--ease); }
.lang-btn:hover { background: var(--accent-soft); color: var(--accent-ink); }
#brandName { font-weight: 600; font-size: 20px; letter-spacing: -.02em; }

.bswitch-wrap { padding: 4px 12px 10px; }
.bswitch { position: relative; display: flex; gap: 2px; padding: 4px; background: var(--sunken); border-radius: var(--r); overflow-x: auto; scrollbar-width: none; }
.bswitch::-webkit-scrollbar { display: none; }
.seg-ind { position: absolute; top: 0; left: 0; border-radius: var(--r-sm); background: var(--surface); box-shadow: var(--shadow-pill); transition: transform var(--dur) var(--ease), width var(--dur) var(--ease); pointer-events: none; }
.bchip { position: relative; z-index: 1; flex: 1 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 36px; padding: 6px 12px; border: 0; background: none; border-radius: var(--r-sm); cursor: pointer; color: var(--ink-2); font-weight: 600; font-size: 14px; white-space: nowrap; transition: color var(--dur-fast) var(--ease); }
.bchip:hover { color: var(--ink); }
.bchip.on { color: var(--ink); }
.bdot { width: 8px; height: 8px; border-radius: 50%; background: var(--bc); }
.bl-short { display: none; }
.bswitch.compact .bl-full { display: none; }
.bswitch.compact .bl-short { display: inline; }
.bswitch.compact .bchip { padding: 6px 10px; gap: 6px; }
.bcount { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--danger); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; letter-spacing: .02em; }

main { max-width: 1080px; margin: 0 auto; padding: 18px 16px 48px; }

/* ---------- Menu ---------- */
.tabs { position: fixed; z-index: 25; background: var(--surface); }
.tabs button { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; border: 0; background: none; cursor: pointer; color: var(--ink-2); font-weight: 600; white-space: nowrap; transition: color var(--dur-fast) var(--ease); }
.tabs button:hover { color: var(--ink); }
.tabs button.active { color: var(--accent-ink); }
.tab-ind { position: absolute; top: 0; left: 0; border-radius: var(--r); background: var(--accent-soft); transition: transform var(--dur) var(--ease), width var(--dur) var(--ease), height var(--dur) var(--ease); pointer-events: none; }
.tab-ic { position: relative; display: grid; place-items: center; }
.badge { position: absolute; top: -6px; right: -10px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: var(--danger); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--surface); }

/* Điện thoại: menu dưới cùng */
@media (max-width: 760px) {
  .tabs { left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(27, 26, 31, .05); }
  .tabs button { flex: 1; flex-direction: column; gap: 4px; padding: 0; min-height: 54px; justify-content: center; font-size: 11.5px; letter-spacing: .02em; }
  .tab-ic { width: 56px; height: 30px; }
  .tab-ind { border-radius: 99px; }
  main { padding-bottom: calc(var(--nav-h) + 32px + env(safe-area-inset-bottom)); }
}
/* Máy tính / tablet: thanh bên trái */
@media (min-width: 761px) {
  .top { display: flex; align-items: center; height: var(--head-h); padding: 0 20px 0 0; }
  .top-in { width: var(--side-w); padding: 0 20px; flex: none; }
  .bswitch-wrap { flex: 1; padding: 0; max-width: 720px; }
  .tabs { top: var(--head-h); left: 0; bottom: 0; width: var(--side-w); display: flex; flex-direction: column; gap: 2px; padding: 16px 12px; border-right: 1px solid var(--line); }
  .tabs button { padding: 10px 12px; min-height: 44px; font-size: 15px; gap: 16px; }
  body { padding-left: var(--side-w); }
  .top { margin-left: calc(-1 * var(--side-w)); }
  main { padding: 28px 32px 64px; }
}

/* ---------- Nút ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); padding: 9px 15px; border-radius: var(--r); cursor: pointer; text-decoration: none; min-height: 44px; font-weight: 600; font-size: 15px; transition: background-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.btn:hover { background: #f8f7f6; }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .45; cursor: default; transform: none; background: var(--surface); }
.btn.primary { background: var(--accent); border-color: transparent; color: #fff; }
.btn.primary:hover { background: var(--accent-press); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--accent-ink); }
.btn.ghost:hover { background: var(--accent-soft); }
.btn.danger { color: var(--danger); }
.btn.danger:hover { background: var(--danger-soft); }
.btn.icon-only { padding: 0; width: 44px; }
.btn.block { width: 100%; }
.icon-btn { width: 44px; height: 44px; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--surface); display: grid; place-items: center; cursor: pointer; transition: transform 100ms var(--ease); }
.icon-btn:active { transform: scale(.94); }

/* ---------- Chung ---------- */
.bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.row { display: flex; align-items: center; justify-content: space-between; }
.row.gap { gap: 8px; justify-content: flex-start; }
.row-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.row-head h4 { margin: 0; }
.wrap { flex-wrap: wrap; }
.sp { flex: 1; }
.right { text-align: right; }
.mt { margin-top: 20px; }
.muted { color: var(--ink-2); font-size: 14px; }
.small { font-size: 13px; }
.empty { color: var(--ink-2); padding: 18px 0; }
.err-text { color: var(--danger); }
.amber-text { color: var(--warn); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.card.pad { padding: 20px; margin: 0 0 16px; }
.hint { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: var(--accent-soft); color: var(--accent-ink); border-radius: var(--r); padding: 10px 10px 10px 14px; margin: 0 0 16px; font-weight: 600; font-size: 14px; }
.hint > span { display: flex; align-items: center; gap: 8px; }
/* Tiêu đề mục: chữ nhỏ in hoa giãn cách + đường kẻ mảnh (cấu trúc thay cho khung hộp) */
.sec-title { display: flex; align-items: center; gap: 12px; margin: 32px 0 14px; font-family: var(--font-body); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-2); }
.sec-title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.num { font-variant-numeric: tabular-nums; }

.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; padding: 2px 8px; border-radius: 99px; font-weight: 600; white-space: nowrap; line-height: 1.6; letter-spacing: .02em; }
.tag .ic { width: 12px; height: 12px; }
.tag.green { background: var(--ok-soft); color: var(--ok); }
.tag.red { background: var(--danger-soft); color: var(--danger); }
.tag.amber { background: var(--warn-soft); color: var(--warn); }
.tag.gray { background: var(--sunken); color: var(--ink-2); }
.cc { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em; padding: 0 5px; border-radius: 4px; background: var(--sunken); color: var(--ink-2); line-height: 1.6; vertical-align: 1px; }

.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 0 16px; scrollbar-width: none; }
.chip { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line-2); background: var(--surface); border-radius: 99px; padding: 6px 8px 6px 14px; min-height: 38px; cursor: pointer; white-space: nowrap; font-weight: 600; font-size: 14px; color: var(--ink-2); transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease); }
.chip-n { min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--sunken); display: grid; place-items: center; font-size: 12px; font-variant-numeric: tabular-nums; }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip.on .chip-n { background: rgba(255, 255, 255, .18); }

.meter { height: 6px; border-radius: 99px; background: var(--sunken); overflow: hidden; margin-top: 12px; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--bc, var(--accent)); transform-origin: left; transition: transform 600ms var(--ease-out); }
.meter.ok span { background: var(--ok); }
.meter.lg { height: 8px; margin: 14px 0 10px; }

.empty-state { display: grid; justify-items: center; gap: 8px; padding: 40px 20px; color: var(--ink-2); text-align: center; background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--r-lg); }
.empty-state b { color: var(--ink); font-size: 16px; }
.empty-state .btn { margin-top: 8px; }

/* ---------- Tổng quan ---------- */
/* Thẻ chào: nền shader hoa sen (có nền CSS dự phòng), chữ đậm màu mực để luôn dễ đọc */
.hero { position: relative; overflow: hidden; isolation: isolate; border-radius: var(--r-xl); padding: 22px 22px 20px; margin-bottom: 12px;
  background:
    radial-gradient(120% 90% at 100% 0%, #f2c7d3 0%, transparent 55%),
    radial-gradient(90% 80% at 0% 100%, #f8e4d6 0%, transparent 60%),
    #fbf1ee;
  border: 1px solid rgba(141, 26, 71, .08); }
.hero-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.shader-host { position: absolute; inset: 0; opacity: 0; transition: opacity 900ms var(--ease-out); }
.shader-host.ready { opacity: 1; }
.shader-host canvas { display: block; width: 100% !important; height: 100% !important; }
.hero-date { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--accent-ink); font-weight: 600; text-transform: uppercase; letter-spacing: .12em; margin-bottom: 14px; }
.hero-scope { padding: 3px 10px; border-radius: 99px; background: rgba(255, 255, 255, .6); letter-spacing: .06em; text-transform: none; font-size: 12.5px; }
.hero h1 { font-size: 32px; line-height: 1.05; letter-spacing: -.025em; }
.hero h1 em { font-style: italic; color: var(--accent-ink); }
.hero-stats { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 22px; padding-top: 16px; border-top: 1px solid rgba(141, 26, 71, .14); }
.hero-stats > div { display: grid; gap: 2px; padding: 0 12px; border-left: 1px solid rgba(141, 26, 71, .14); }
.hero-stats > div:first-child { padding-left: 0; border-left: 0; }
.hs-v { font-size: 30px; font-weight: 500; line-height: 1.05; letter-spacing: -.02em; }
.hs-v small { font-size: 16px; font-weight: 500; color: var(--ink-2); margin-left: 1px; }
.hs-l { font-size: 12px; color: var(--ink-2); letter-spacing: .02em; }
.hs-urgent .hs-v { color: var(--danger); }

.quick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.qa.accent { background: var(--accent-soft); border-color: rgba(141, 26, 71, .16); color: var(--accent-ink); }
.qa.accent .ic { color: var(--accent-ink); }
.qa.accent:hover { background: #f8dfe9; }
.qa .btn-n { margin-left: 2px; }
.qa { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); cursor: pointer; font-weight: 600; font-size: 14px; transition: background-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.qa:hover { background: #fbfaf9; }
.qa:active { transform: scale(.97); }
.qa .ic { color: var(--ink-2); }
.qa.primary { background: var(--accent); border-color: transparent; color: #fff; }
.qa.primary .ic { color: #fff; }
.qa.primary:hover { background: var(--accent-press); }

.money { display: block; width: 100%; text-align: left; padding: 16px 18px; cursor: pointer; margin-bottom: 4px; }
.money-row { display: flex; justify-content: space-between; gap: 12px; }
.big { font-size: 26px; font-weight: 500; letter-spacing: -.02em; line-height: 1.2; margin-top: 2px; }
.money-row .muted { font-size: 12px; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
button.money:hover, .bcard:hover, .trow:hover, .brow:hover, .room:hover, .bitem:hover { border-color: var(--line-2); }

.bgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.bcard { display: block; text-align: left; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); cursor: pointer; transition: border-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.bcard:active { transform: scale(.98); }
.bcard-top { display: flex; align-items: center; gap: 10px; }
.bmark .badge { top: -7px; right: -7px; }
.bcard-name { display: grid; flex: 1; min-width: 0; line-height: 1.3; }
.bcard-foot { display: flex; flex-direction: column; gap: 2px; margin-top: 10px; font-size: 13px; }
.bcard-foot > span { display: inline-flex; align-items: center; gap: 4px; }
.bmark { position: relative; width: 36px; height: 36px; flex: none; border-radius: 10px; display: grid; place-items: center; font-weight: 700; font-size: 15px; color: var(--bc); background: color-mix(in srgb, var(--bc) 12%, white); }

.al-group { margin-bottom: 16px; }
.al-head { display: flex; align-items: center; gap: 7px; font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 8px 2px; }
.al-group.danger .al-head { color: var(--danger); }
.al-group.warn .al-head { color: var(--warn); }
.al-group.info .al-head { color: var(--info); }
.count { min-width: 20px; height: 20px; border-radius: 10px; display: grid; place-items: center; font-size: 11px; padding: 0 6px; border: 1.5px solid currentColor; }
.alerts { list-style: none; padding: 0; margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.al { display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer; transition: background-color var(--dur-fast) var(--ease); }
.al + .al { border-top: 1px solid var(--line); }
.al:hover { background: #fbfaf9; }
.al-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.danger .al-ic { background: var(--danger-soft); color: var(--danger); }
.warn .al-ic { background: var(--warn-soft); color: var(--warn); }
.info .al-ic { background: var(--info-soft); color: var(--info); }
.al-body { flex: 1; min-width: 0; }
.al-title { font-weight: 600; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.al-sub { font-weight: 400; font-size: 13px; color: var(--ink-2); }
.al-detail { font-size: 14px; color: var(--ink-2); }
.danger .al-detail { color: var(--danger); }
.chev { color: var(--ink-3); }
.all-good { display: flex; gap: 12px; align-items: center; padding: 16px; background: var(--ok-soft); color: var(--ok); border-radius: var(--r-lg); }
.all-good .muted { color: var(--ok); opacity: .85; }

/* ---------- Phòng ---------- */
.bsection { margin-bottom: 24px; }
.bhead { display: flex; align-items: center; gap: 10px; width: 100%; padding: 4px 2px 0; margin-bottom: 4px; background: none; border: 0; cursor: pointer; text-align: left; font-size: 17px; }
.bhead .bmark { width: 30px; height: 30px; font-size: 13px; border-radius: 8px; }
.bhead .muted { margin-left: 4px; }
.floor { font-size: 12px; font-weight: 600; color: var(--ink-2); text-transform: uppercase; letter-spacing: .08em; margin: 14px 2px 8px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.room { text-align: left; display: flex; flex-direction: column; gap: 2px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px; cursor: pointer; transition: border-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.room:active { transform: scale(.98); }
.room.free { background: transparent; border-style: dashed; border-color: var(--line-2); }
.room-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.rname { font-size: 24px; font-weight: 500; letter-spacing: -.02em; line-height: 1.1; }
.rstate { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 99px; letter-spacing: .02em; }
.room.busy .rstate { background: var(--accent-soft); color: var(--accent-ink); }
.room.free .rstate { background: var(--sunken); color: var(--ink-2); }
.rprice { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.rprice .muted { font-weight: 400; font-size: 13px; }
.rpeople { display: grid; gap: 6px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 14px; }
.rp { display: flex; align-items: center; gap: 7px; min-width: 0; }
.rp > span:not(.cc) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.add-guest { display: inline-flex; align-items: center; gap: 5px; color: var(--accent-ink); font-weight: 600; font-size: 14px; }
.room-people { display: grid; gap: 8px; margin: -4px 0 18px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }

/* ---------- Khách ---------- */
.searchbox { position: relative; margin-bottom: 10px; }
.searchbox .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-3); }
.searchbox input { padding-left: 42px; min-height: 48px; border-radius: var(--r); }
.list { display: grid; gap: 8px; }
.trow { display: flex; gap: 12px; align-items: center; text-align: left; width: 100%; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); cursor: pointer; transition: border-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.trow:active { transform: scale(.99); }
.trow.mini { padding: 8px 10px; border-radius: var(--r); }
.trow.mini .ava { width: 36px; height: 36px; font-size: 14px; }
.ava { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex: none; }
.ava.ph { background: var(--sunken); color: var(--ink-2); display: grid; place-items: center; font-weight: 700; font-size: 17px; }
.ava.xs { width: 22px; height: 22px; font-size: 11px; }
.tinfo { min-width: 0; flex: 1; }
.tname { font-weight: 600; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
.troom { flex: none; }
.room-badge { display: inline-grid; place-items: center; align-content: center; min-width: 50px; height: 50px; padding: 0 8px; border-radius: var(--r); background: color-mix(in srgb, var(--bc, var(--accent)) 10%, white); color: color-mix(in srgb, var(--bc, var(--accent)) 85%, black); font-weight: 700; font-size: 16px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.room-badge small { font-size: 11px; font-weight: 700; letter-spacing: .06em; opacity: .75; }

/* Danh sách gom nhóm: một khối nền trắng, các dòng ngăn bằng đường kẻ mảnh (giống danh sách trên iPhone) */
.list:has(> .trow, > .brow) { gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.list > .trow, .list > .brow { position: relative; border: 0; border-radius: 0; background: transparent; transition: background-color var(--dur-fast) var(--ease); }
.list > .trow + .trow::before, .list > .brow + .brow::before { content: ""; position: absolute; top: 0; left: 72px; right: 0; height: 1px; background: var(--line); }
.list > .trow:hover, .list > .brow:hover { background: #fbfaf9; }
.list > .trow:active, .list > .brow:active { transform: none; background: var(--sunken); }

/* ---------- Tiền thuê ---------- */
.month-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.month-label { flex: 1; text-align: center; font-weight: 700; font-size: 17px; position: relative; cursor: pointer; padding: 8px; border-radius: var(--r); font-variant-numeric: tabular-nums; }
.month-label input { position: absolute; inset: 0; opacity: 0; cursor: pointer; min-height: 0; }
.brow { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 14px 10px 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); cursor: pointer; transition: border-color var(--dur-fast) var(--ease), transform 100ms var(--ease); }
.brow:active { transform: scale(.99); }
.brow.paid { background: transparent; }
.brow.paid .room-badge { filter: grayscale(1); opacity: .7; }
.binfo { flex: 1; min-width: 0; }
.bamt { font-weight: 700; font-size: 16px; font-variant-numeric: tabular-nums; }

/* ---------- Cài đặt ---------- */
.blist { display: grid; gap: 6px; }
.bitem { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); cursor: pointer; }
.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.sw input { position: absolute; opacity: 0; }
.sw span { display: block; width: 32px; height: 32px; border-radius: 50%; background: var(--c); cursor: pointer; box-shadow: 0 0 0 2px var(--surface), 0 0 0 2px transparent; transition: box-shadow var(--dur-fast) var(--ease); }
.sw input:checked + span { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--c); }
.sw input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 4px; }

/* ---------- Form ---------- */
input, select, textarea { font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--surface); color: var(--ink); width: 100%; min-height: 46px; transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease); }
textarea { min-height: 0; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(184, 40, 95, .16); }
input.check { background: #fff8de; border-color: #d4a106; }
.f { display: grid; gap: 6px; margin-bottom: 14px; }
.f > span { font-size: 13px; color: var(--ink-2); font-weight: 600; letter-spacing: .01em; }
.two, .three { display: grid; gap: 0 12px; grid-template-columns: 1fr 1fr; }
.three { grid-template-columns: 1fr 1fr 1fr; }
.chk { display: flex; align-items: center; gap: 10px; font-weight: 600; min-height: 46px; margin-bottom: 14px; cursor: pointer; }
.chk input { width: 22px; height: 22px; min-height: 0; accent-color: var(--accent); }
.note { display: flex; gap: 8px; font-size: 14px; background: var(--warn-soft); color: #5c3606; border-radius: var(--r); padding: 10px 12px; margin: 0 0 14px; }
.note .ic { margin-top: 2px; }
.sec { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 18px; }
.sec.first { border-top: 0; padding-top: 0; margin-top: 0; }
.vn .foreign-only { display: none !important; }

.photos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ph-tile { display: grid; gap: 6px; cursor: pointer; min-width: 0; }
.ph-img { border: 1.5px dashed var(--line-2); border-radius: var(--r-lg); aspect-ratio: 4 / 3; display: grid; place-items: center; background: var(--surface); overflow: hidden; transition: border-color var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease); }
.ph-tile:hover .ph-img { border-color: var(--accent); background: var(--accent-soft); }
.ph-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph-empty { display: grid; justify-items: center; gap: 6px; color: var(--accent-ink); font-weight: 600; font-size: 14px; }
.ph-cap { display: flex; gap: 5px; align-items: flex-start; font-size: 12px; color: var(--ink-2); line-height: 1.35; letter-spacing: .02em; }
.ph-cap .ic { margin-top: 1px; }
.ph-actions { margin-top: 10px; }
#rescanBtn:disabled { display: none; }
#ppStatus:not(:empty), #faceResult:not(:empty) { margin-top: 10px; }

.status { display: block; font-size: 14px; padding: 10px 12px; border-radius: var(--r); background: var(--sunken); margin-top: 4px; }
.status.ok { background: var(--ok-soft); color: var(--ok); }
.status.warn { background: var(--warn-soft); color: var(--warn); }
.status.err { background: var(--danger-soft); color: var(--danger); }
p.status { display: flex; align-items: center; gap: 6px; }
.status .ic { display: inline-block; vertical-align: -3px; margin-right: 4px; }
.spinner { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line-2); border-top-color: var(--accent); vertical-align: -2px; margin-right: 6px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 20px; }
dialog .actions:not(.plain) { position: sticky; bottom: -20px; background: var(--surface); padding: 12px 0 16px; border-top: 1px solid var(--line); margin-bottom: -20px; z-index: 2; }
.total { background: var(--sunken); border-radius: var(--r); padding: 12px 14px; margin-bottom: 14px; font-size: 14px; }
.total-v { display: flex; justify-content: space-between; align-items: baseline; margin-top: 2px; }
.total-v b { font-size: 20px; font-variant-numeric: tabular-nums; }

.sheet { width: 100%; border-collapse: collapse; font-size: 14px; }
.sheet th, .sheet td { border-bottom: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.sheet th { width: 40%; font-weight: 400; color: var(--ink-2); padding-left: 0; }
.sheet td { font-weight: 600; }

/* ---------- Khai báo tạm trú nhanh ---------- */
.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .92em; letter-spacing: -.01em; }
.btn-n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--danger); color: #fff; font-size: 11.5px; font-weight: 700; display: grid; place-items: center; }
.steps { margin: 0 0 16px; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 8px; font-size: 14px; color: var(--ink-2); }
.steps li { counter-increment: s; position: relative; padding-left: 32px; }
.steps li::before { content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: -1px; font-family: var(--font-display); font-size: 15px; color: var(--accent-ink); }
.steps b { color: var(--ink); }
.drop { display: grid; justify-items: center; gap: 6px; padding: 22px 16px; border: 1.5px dashed var(--line-2); border-radius: var(--r-lg); background: var(--surface); text-align: center; cursor: pointer; color: var(--accent-ink); transition: border-color var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease); }
.drop b { color: var(--ink); }
.drop:hover, .drop.over { border-color: var(--accent); background: var(--accent-soft); }
/* Form nhận khách: ô tải hộ chiếu + visa */
.doc-drop { grid-template-columns: auto 1fr; justify-items: start; align-items: center; text-align: left; gap: 14px; padding: 14px; }
.doc-thumb { width: 64px; height: 64px; border-radius: var(--r); background: var(--accent-soft); display: grid; place-items: center; overflow: hidden; flex: none; }
.doc-thumb img { width: 100%; height: 100%; object-fit: cover; }
.doc-txt { display: grid; gap: 2px; }
.face-box { margin-top: 12px; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 0 14px; }
.face-box summary { display: flex; align-items: center; gap: 8px; min-height: 46px; cursor: pointer; font-weight: 600; font-size: 14px; list-style: none; }
.face-box summary::-webkit-details-marker { display: none; }
.face-box[open] summary { border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.face-inner { display: grid; grid-template-columns: 140px 1fr; gap: 14px; align-items: start; }
.face-side { display: grid; gap: 10px; justify-items: start; }
.face-side p { margin: 0; }
.face-box #faceResult { margin-bottom: 14px; }
input.auto, select.auto { border-color: var(--ok); box-shadow: 0 0 0 3px rgba(19, 122, 75, .12); }
.h4-note { text-transform: none; letter-spacing: 0; color: var(--ok); font-weight: 600; margin-left: 6px; }

/* Form nhận khách: bố cục theo form của trang khai báo (3 cột trên máy tính) */
.gform { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; align-items: end; }
.gform .span2 { grid-column: span 2; }
.gform .foreign-only .f { margin-bottom: 14px; }
.f i { color: var(--danger); font-style: normal; margin-left: 2px; }
.f small { font-weight: 400; color: var(--ink-3); }
.dob-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.dob-mode { display: inline-flex; gap: 12px; font-weight: 500; color: var(--ink-2); }
.dob-mode label { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; }
.dob-mode input { width: 16px; height: 16px; min-height: 0; margin: 0; accent-color: var(--accent); }
.dob-f .dob-year { display: none; }
.dob-f.year .dob-full { display: none; }
.dob-f.year .dob-year { display: block; }
@media (max-width: 760px) {
  .gform { grid-template-columns: 1fr; }
  .gform .span2 { grid-column: auto; }
}

/* Xuất khai báo: danh sách chọn khách */
.kb-lead { margin: -6px 0 14px; }
.kb-tools { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.kb-tools .chips { margin: 0; }
.kb-row { position: relative; display: flex; align-items: center; gap: 8px; padding-right: 10px; }
.kb-row + .kb-row::before { content: ""; position: absolute; top: 0; left: 104px; right: 0; height: 1px; background: var(--line); }
.kb-row.on { background: color-mix(in srgb, var(--accent-soft) 45%, white); }
.kb-pick { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; padding: 12px 6px 12px 14px; cursor: pointer; }
.kb-pick input { width: 22px; height: 22px; min-height: 0; accent-color: var(--accent); flex: none; }
.kb-pick .ava { width: 42px; height: 42px; font-size: 15px; }
.kb-pick .kb-name { gap: 3px; justify-items: start; }
.kb-list { margin-top: 10px; }
.link-btn { border: 0; background: none; padding: 0; color: var(--accent-ink); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; font-size: inherit; }
.kb-miss { align-items: flex-start; }
.kb-miss .ic { margin-top: 2px; }
.kb-pick .room-badge .muted { white-space: nowrap; }
@media (max-width: 760px) {
  .kb-pick .ava { display: none; }
  .kb-row + .kb-row::before { left: 48px; }
  .kb-pick { gap: 10px; padding-left: 12px; }
}
.kb-scan { display: grid; gap: 6px; margin: 10px 0 0; }
.kb-scan:empty { display: none; }
.kb-head { margin-top: 22px; }
#kbList { display: grid; gap: 10px; }
.kb-item { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px 14px; background: var(--surface); transition: opacity var(--dur) var(--ease); }
.kb-item.off { opacity: .55; }
.kb-top { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.kb-top input { width: 22px; height: 22px; min-height: 0; accent-color: var(--accent); flex: none; }
.kb-name { display: grid; flex: 1; min-width: 0; line-height: 1.35; }
.kb-name b { font-size: 15.5px; }
.kb-fields { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 0 10px; margin-top: 12px; }
.kb-fields .f { margin-bottom: 0; min-width: 0; }
.kb-fields select, .kb-fields input { max-width: 100%; }
.kb-fields select, .kb-fields input { min-height: 42px; font-size: 15px; padding: 8px 10px; }
.kb-note, .kb-miss { display: flex; gap: 6px; align-items: center; font-size: 13px; }
.kb-note { margin-top: 10px; }
.kb-note { color: var(--ok); }
.kb-miss { color: var(--danger); }
.empty-state.small-pad { padding: 24px 16px; }
@media (max-width: 760px) {
  .kb-fields { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kb-fields .f:first-child { grid-column: 1 / -1; }
  .bar .row.gap .btn { padding: 9px 12px; font-size: 14px; }
}

/* ---------- Hộp thoại ---------- */
dialog { border: 0; border-radius: var(--r-xl); padding: 22px; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 32px); box-shadow: var(--shadow-float); color: var(--ink); background: var(--surface); }
dialog.wide { width: min(860px, calc(100vw - 24px)); }
dialog::backdrop { background: rgba(27, 26, 31, .40); }
dialog[open] { animation: pop var(--dur) var(--ease-out); }
dialog[open]::backdrop { animation: fade var(--dur) var(--ease); }
@keyframes pop { from { opacity: 0; transform: scale(.96); } }
@keyframes fade { from { opacity: 0; } }
.modal-x { position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--sunken); display: grid; place-items: center; cursor: pointer; z-index: 3; color: var(--ink-2); transition: background-color var(--dur-fast) var(--ease); }
#modalBody:focus { outline: none; }
.modal-x:hover { background: #e4e1e6; color: var(--ink); }

/* ---------- Xuất hiện lần lượt ---------- */
.rv.in { animation: rise var(--dur-slow) var(--ease-out) both; animation-delay: var(--d, 0ms); }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }

#toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 16px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: var(--r); opacity: 0; transition: opacity var(--dur) var(--ease-exit), transform var(--dur) var(--ease-exit); pointer-events: none; max-width: 90vw; z-index: 1000; font-weight: 600; font-size: 14px; box-shadow: var(--shadow-float); }
#toast.show { opacity: 1; transform: translate(-50%, 0); transition-timing-function: var(--ease-out); }

/* ---------- Điện thoại ---------- */
@media (max-width: 760px) {
  h1 { font-size: 26px; }
  h2 { font-size: 24px; }
  .hero { padding: 18px 18px 18px; }
  .hero h1 { font-size: 30px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); row-gap: 14px; }
  .hero-stats > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .quick { grid-template-columns: 1fr 1fr; }
  .quick .qa.primary, .quick .qa.accent { grid-column: 1 / -1; }
  .quick .qa.primary + .qa:last-child { grid-column: 1 / -1; } /* chỉ còn 1 nút phụ (tài khoản quản lý) */
  .bgrid { grid-template-columns: 1fr 1fr; }
  .bcard-foot { flex-direction: column; gap: 2px; }
  .three, .two { grid-template-columns: 1fr; }
  .grid { grid-template-columns: 1fr 1fr; }
  .big { font-size: 20px; }
  .hide-sm { display: none; }
  dialog, dialog.wide { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border-radius: 0; padding: 18px 16px; padding-top: max(18px, env(safe-area-inset-top)); }
  dialog[open] { animation: sheet var(--dur-slow) var(--ease-out); }
  dialog .actions:not(.plain) { padding-bottom: max(16px, env(safe-area-inset-bottom)); }
  dialog .actions [data-act="close"] { display: none; }
  dialog .actions .btn:not(.icon-only) { flex: 1 1 auto; }
  dialog .actions .sp { display: none; }
  .modal-x { top: max(14px, env(safe-area-inset-top)); }
  #toast { bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); }
}
@keyframes sheet { from { transform: translateY(24px); opacity: 0; } }
@media (min-width: 761px) and (max-width: 1000px) {
  .bgrid { grid-template-columns: 1fr 1fr; }
}

/* Người dùng bật giảm chuyển động: tắt hiệu ứng, giữ thay đổi trạng thái */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* ---------- Phân quyền ---------- */
.preview-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 14px; padding: 8px 8px 8px 14px; border-radius: var(--r); background: var(--info-soft); color: var(--info); font-size: 14px; font-weight: 500; }
.preview-bar > span { flex: 1; min-width: 0; }
.preview-bar .btn { min-height: 36px; padding: 6px 12px; color: var(--info); }
.checks { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.checks .chk { margin-bottom: 0; font-weight: 500; }

/* ---------- Đầu trang: đồng bộ, thông báo, tài khoản ---------- */
.hd-sp { flex: 1; }
.hd-btn { position: relative; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--surface); display: grid; place-items: center; cursor: pointer; color: var(--ink-2); font-weight: 700; font-size: 14px; flex: none; }
.hd-btn:hover { background: var(--accent-soft); color: var(--accent-ink); }
.hd-btn .badge { top: -4px; right: -4px; }
.me-btn { background: var(--accent-soft); color: var(--accent-ink); border-color: transparent; }
.sync-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); flex: none; transition: background-color var(--dur) var(--ease); }
.sync-dot[data-state="saving"] { background: var(--warn); animation: pulse 1s var(--ease) infinite alternate; }
.sync-dot[data-state="err"] { background: var(--danger); }
@keyframes pulse { to { opacity: .35; } }
@media (min-width: 761px) { .top-in { width: auto; flex: 1; } .bswitch-wrap { flex: 0 1 720px; } }

/* ---------- Đăng nhập ---------- */
body.auth .tabs, body.auth .bswitch-wrap { display: none; }
body.auth { padding-left: 0; }
body.auth .top { margin-left: 0; }
.login { min-height: 70vh; display: grid; place-items: center; padding: 24px 0; }
.login-card { width: min(380px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl); padding: 28px 24px; box-shadow: var(--shadow-float); text-align: left; }
.login-card h1 { margin: 10px 0 4px; }
.login-card > .muted { margin: 0 0 20px; }
.login-logo { width: 52px; height: 52px; border-radius: 14px; background: var(--accent); color: #fff; display: grid; place-items: center; }
.login-logo svg { width: 34px; height: 34px; }
.login-card .btn.block { margin-top: 6px; }
.center { text-align: center; }
#loginErr:not(:empty) { margin-bottom: 12px; }

/* ---------- Tài khoản & thông báo ---------- */
.acc { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px 14px; margin-bottom: 10px; }
.acc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.acc-head .ava { width: 40px; height: 40px; font-size: 15px; }
.acc-head select { width: auto; min-width: 140px; }
.acc .f { margin-bottom: 8px; }
.acc-b { display: grid; gap: 6px; }
.acc-me { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.trow.unread { background: var(--accent-soft); }
.note-text { font-size: 14.5px; line-height: 1.4; }
#accCard #permForm { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
@media (max-width: 760px) { .acc-head { flex-wrap: wrap; } .acc-head select { width: 100%; } }

/* ---------- Hộp xác nhận của app ---------- */
dialog.ask-dlg { width: min(420px, calc(100vw - 32px)); height: auto; max-height: none; margin: auto; border-radius: var(--r-xl); padding: 20px; }
.ask-msg { margin: 0 0 14px; font-size: 16px; line-height: 1.5; font-weight: 500; }
.ask textarea { width: 100%; font-size: 14px; }
.ask .actions { margin-top: 6px; }
.btn.danger-solid { background: var(--danger); border-color: transparent; color: #fff; }
.btn.danger-solid:hover { background: #9a1d13; }
@media (max-width: 760px) { dialog.ask-dlg { width: calc(100vw - 32px); height: auto; max-height: none; border-radius: var(--r-xl); padding: 20px; } dialog.ask-dlg .actions .btn { flex: 1; } }

/* ---------- Chọn để xóa ---------- */
.sel-hint { margin: -6px 0 14px; font-size: 14px; color: var(--ink-2); }
.room.picking, .trow.picking { position: relative; }
.room.picking { padding-right: 44px; }
.trow.picking { padding-left: 50px; }
.pick { position: absolute; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line-2); background: var(--surface); color: transparent; display: grid; place-items: center; transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease); }
.room .pick { top: 14px; right: 14px; }
.trow .pick { left: 14px; top: 50%; transform: translateY(-50%); }
.pick.on { background: var(--danger); border-color: var(--danger); color: #fff; }
.room.picked { border: 1.5px solid var(--danger); background: var(--danger-soft); }
.list > .trow.picked, .trow.picked { background: var(--danger-soft); }
.room.picking .rstate { display: none; }
.selbar { position: fixed; z-index: 40; left: 50%; transform: translateX(-50%); bottom: 20px; width: min(560px, calc(100vw - 24px)); display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 16px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); box-shadow: var(--shadow-float); font-size: 15px; animation: rise var(--dur) var(--ease-out) both; }
.selbar .btn:disabled { opacity: .45; }
main:has(.selbar) { padding-bottom: 120px; }
@media (min-width: 761px) { .selbar { left: calc(50% + var(--side-w) / 2); } }
@media (max-width: 760px) { .selbar { bottom: calc(var(--nav-h) + 14px + env(safe-area-inset-bottom)); } main:has(.selbar) { padding-bottom: calc(var(--nav-h) + 110px); } }
