:root {
  --bg: #f1f3f7;
  --card: #ffffff;
  --text: #1d2330;
  --muted: #6b7280;
  --primary: #0b6e4f;
  --primary-dark: #08513a;
  --border: #e6e9ef;
  --danger: #b42318;
  --warn-bg: #fff7e6;
  --ok-bg: #e7f6ee;
  --err-bg: #fdecea;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--text); line-height: 1.45; }
a { color: var(--primary); }
h1 { font-size: 1.5rem; margin: 0.5rem 0 1rem; }
h2 { font-size: 1.15rem; margin: 0 0 0.75rem; }

.topbar { background: var(--primary); color: #fff; padding: 0.6rem 1rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; }
.topbar a, .topbar .link-button { color: #fff; text-decoration: none; }
.brand { font-weight: 700; font-size: 1.15rem; }
.business-name { opacity: 0.85; font-size: 0.9rem; }
.nav { display: flex; flex-wrap: wrap; gap: 0.4rem 0.9rem; align-items: center; margin-left: auto; }
.nav a:hover, .link-button:hover { text-decoration: underline; }
.nav-primary { background: #fff; color: var(--primary) !important; padding: 0.25rem 0.7rem; border-radius: 6px; font-weight: 600; }
.inline-form { display: inline; margin: 0; }
.link-button { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }

.container { max-width: 64rem; margin: 0 auto; padding: 1rem; }
.card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 1rem 1.25rem; margin-bottom: 1rem; }
.narrow { max-width: 30rem; margin-left: auto; margin-right: auto; }
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.5rem; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }

.button { display: inline-block; background: var(--primary); color: #fff; border: 0; border-radius: 8px; padding: 0.6rem 1.1rem; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
.button:hover { background: var(--primary-dark); }
.button:disabled { opacity: 0.6; cursor: wait; }
.button-secondary { background: #e8ecef; color: var(--text); }
.button-secondary:hover { background: #d9dee3; }
.button-large { font-size: 1.1rem; padding: 0.8rem 1.4rem; }

form > div { margin-bottom: 0.9rem; }
label { display: block; font-weight: 600; margin-bottom: 0.25rem; }
label.checkbox { display: inline-flex; gap: 0.35rem; align-items: center; font-weight: normal; }
input[type=text], input[type=tel], input[type=password], input[type=number], input[type=search], input[type=date], input[type=email], input:not([type]), select, textarea {
  width: 100%; padding: 0.55rem 0.65rem; border: 1px solid var(--border); border-radius: 6px; font: inherit; background: #fff;
}
input:focus, select:focus { outline: 2px solid var(--primary); outline-offset: 1px; }
.helptext { display: block; color: var(--muted); font-size: 0.85rem; margin-top: 0.2rem; }
.errorlist { color: var(--danger); margin: 0.25rem 0; padding-left: 1.1rem; }

.filters { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: flex-end; margin-bottom: 1rem; }
.filters > * { margin-bottom: 0; }
.filters input[type=search] { flex: 1 1 14rem; width: auto; }
.filters label { font-weight: normal; }

.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--border); border-radius: 10px; margin-bottom: 1rem; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 0.55rem 0.7rem; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { background: #f0f2f5; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.02em; color: var(--muted); }
.num { text-align: right; white-space: nowrap; }
.actions a { margin-right: 0.6rem; white-space: nowrap; }
tr.inactive td { color: var(--muted); }
.low { color: var(--danger); font-weight: 700; }
.neg { color: var(--danger); }
.pos { color: var(--primary); }
.badge { font-size: 0.75rem; background: #eee; border-radius: 4px; padding: 0 0.35rem; }

.messages { list-style: none; padding: 0; margin: 0 0 1rem; }
.message { padding: 0.7rem 1rem; border-radius: 8px; margin-bottom: 0.5rem; background: var(--ok-bg); }
.message-error { background: var(--err-bg); color: var(--danger); margin-bottom: 1rem; }
.notice { background: var(--warn-bg); border-left: 4px solid #e0a100; padding: 0.6rem 0.8rem; border-radius: 4px; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.stat { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 1rem; }
.stat-label { color: var(--muted); font-size: 0.9rem; }
.stat-value { font-size: 1.6rem; font-weight: 700; }
.plain-list { list-style: none; padding: 0; margin: 0; }
.plain-list li { padding: 0.35rem 0; border-bottom: 1px solid var(--border); }
.plain-list li:last-child { border-bottom: 0; }
.summary { margin: 0 0 0.75rem; }
.pagination { display: flex; gap: 1rem; justify-content: center; align-items: center; margin: 1rem 0; }

.filter-box { margin-bottom: 0.75rem; }
.sale-table input.qty { width: 5.5rem; text-align: right; }
.checkout { max-width: 30rem; }
.checkout input { font-size: 1.2rem; margin-bottom: 0.5rem; }

.receipt { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 1.25rem; max-width: 26rem; margin: 0 auto 1rem; }
.receipt h1 { text-align: center; }
.receipt table th { background: none; }
.receipt tfoot th, .receipt tfoot td { border-bottom: 0; }

@media (max-width: 600px) {
  .container { padding: 0.75rem; }
  .nav { margin-left: 0; width: 100%; }
  th, td { padding: 0.45rem 0.5rem; }
  .actions a { display: inline-block; margin: 0.15rem 0.5rem 0.15rem 0; }
}

@media print {
  body { background: #fff; }
  .no-print, .topbar, .messages { display: none !important; }
  .container { padding: 0; }
  .receipt { border: 0; max-width: none; }
}

.pay-methods { border: 1px solid #d5dbe0; border-radius: 6px; padding: 0.5rem 0.75rem; margin: 0 0 1rem; display: flex; gap: 1.5rem; flex-wrap: wrap; }
.pay-methods legend { font-weight: 600; padding: 0 0.25rem; }
.pay-methods label { display: inline-flex; gap: 0.4rem; align-items: center; font-weight: normal; margin: 0; }
.momo-status { text-align: center; }
.momo-status .status-label { font-size: 1.3rem; font-weight: 700; }

.password-wrap { position: relative; }
.password-wrap input { padding-right: 4.5rem; }
.password-toggle { position: absolute; right: 0.35rem; top: 50%; transform: translateY(-50%); background: #e8ecef; border: 0; border-radius: 6px; padding: 0.3rem 0.6rem; font: inherit; font-size: 0.85rem; font-weight: 600; cursor: pointer; }

/* App shell: sidebar on wide screens, compact top bar on phones. */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.brand { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 800; font-size: 1.2rem; color: var(--text); text-decoration: none; }
.brand-mark { display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 9px; background: linear-gradient(135deg, #12b76a, #0b6e4f); color: #fff; font-size: 1rem; }
.topbar { background: #fff; color: var(--text); border-bottom: 1px solid var(--border); }
.topbar .brand, .topbar .link-button { color: var(--text); }
.topnav { margin-left: auto; }
.app { display: grid; grid-template-columns: 15rem 1fr; min-height: 100vh; }
.sidebar { background: #fff; border-right: 1px solid var(--border); padding: 1.25rem 1rem; display: flex; flex-direction: column; gap: 1.5rem; position: sticky; top: 0; height: 100vh; }
.sidebar .nav { flex-direction: column; align-items: stretch; gap: 0.25rem; margin: 0; }
.sidebar .nav a { color: #4b5565; text-decoration: none; padding: 0.6rem 0.85rem; border-radius: 10px; font-weight: 500; }
.sidebar .nav a:hover { background: #f1f4f9; text-decoration: none; }
.sidebar .nav a.active { background: #1570ef; color: #fff; box-shadow: 0 4px 12px rgba(21, 112, 239, 0.3); }
.sidebar .nav-primary { background: none; color: #12b76a !important; padding: 0.6rem 0.85rem; font-weight: 700; }
.sidebar .nav-primary.active { color: #fff !important; }
.sidebar-foot { margin-top: auto; font-size: 0.85rem; color: var(--muted); display: grid; gap: 0.4rem; }
.sidebar-foot .business-name { opacity: 1; font-weight: 600; color: var(--text); }
.sidebar-foot .link-button { color: var(--muted); text-align: left; }
.main { min-width: 0; }
.pagebar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.5rem 0; max-width: 72rem; margin: 0 auto; }
.pagebar-title { font-size: 1.6rem; font-weight: 800; }
.user-chip { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 600; font-size: 0.9rem; line-height: 1.2; }
.user-chip small { color: var(--muted); font-weight: 400; }
.avatar { display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 10px; background: #fee4e2; color: #d92d20; font-weight: 800; }
.app .container { max-width: 72rem; padding: 1rem 1.5rem 2rem; }
.card, .table-wrap, .stat { border-radius: 14px; border-color: transparent; box-shadow: 0 1px 3px rgba(16, 24, 40, 0.06); }

/* Coloured summary cards */
.stats-color .stat { color: #fff; position: relative; overflow: hidden; }
.stats-color .stat::after { content: ""; position: absolute; right: -1.5rem; bottom: -1.5rem; width: 5rem; height: 5rem; border-radius: 50%; background: rgba(255, 255, 255, 0.18); }
.stats-color .stat:nth-child(4n+1) { background: linear-gradient(135deg, #12b76a, #039855); }
.stats-color .stat:nth-child(4n+2) { background: linear-gradient(135deg, #2e90fa, #1570ef); }
.stats-color .stat:nth-child(4n+3) { background: linear-gradient(135deg, #fdb022, #f79009); }
.stats-color .stat:nth-child(4n+4) { background: linear-gradient(135deg, #f97066, #f04438); }
.stats-color .stat-label { color: rgba(255, 255, 255, 0.9); }

/* Dashboard panels and transaction list */
.dash-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 1rem; align-items: start; }
.tx-list { list-style: none; padding: 0; margin: 0; }
.tx-list li { display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 0.9rem; padding: 0.7rem 0; border-bottom: 1px solid #f0f2f5; }
.tx-list li:last-child { border-bottom: 0; }
.tx-dot { width: 1.6rem; height: 1.6rem; border-radius: 6px; background: #1570ef; }
.tx-2 { background: #fdb022; } .tx-3 { background: #12b76a; } .tx-4 { background: #f97066; } .tx-5 { background: #7a5af8; }
.tx-main, .tx-amount { display: grid; }
.tx-main a { font-weight: 700; color: var(--text); text-decoration: none; }
.tx-list small { color: var(--muted); font-size: 0.78rem; }
.tx-amount { font-weight: 700; text-align: right; }
.tx-time { color: var(--muted); font-size: 0.8rem; }

@media (max-width: 860px) {
  .app { display: block; }
  .sidebar { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; padding: 0.6rem 0.75rem; border-right: 0; border-bottom: 1px solid var(--border); }
  .sidebar .nav { flex-direction: row; flex-wrap: nowrap; overflow-x: auto; width: 100%; order: 3; }
  .sidebar .nav a { white-space: nowrap; padding: 0.45rem 0.7rem; }
  .sidebar-foot { margin: 0 0 0 auto; display: flex; gap: 0.75rem; align-items: center; }
  .pagebar { padding: 0.75rem 0.75rem 0; }
  .pagebar-title { font-size: 1.3rem; }
  .user-chip > span:last-child { display: none; }
  .app .container { padding: 0.75rem; }
  .dash-grid { grid-template-columns: 1fr; }
  .tx-list li { grid-template-columns: auto 1fr auto; }
  .tx-time { display: none; }
}
@media print { .app { display: block; } .pagebar { display: none; } }
.status-open { background: #fee4e2; color: #b42318; }
.status-in_progress { background: #fef0c7; color: #b54708; }
.status-resolved { background: #d1fadf; color: #027a48; }

/* Green "Homely" theme */
:root { --primary: #0f4d3a; --primary-dark: #0a3a2b; --accent: #e7b04b; --bg: #f3f5f4; --soft: #e6f0ec; }
body { background: var(--bg); }
.button { border-radius: 999px; padding: 0.65rem 1.3rem; }
.button-secondary { background: #fff; color: var(--primary); box-shadow: inset 0 0 0 1px #d5e2dc; }
.button-secondary:hover { background: var(--soft); }
.card, .table-wrap, .stat { border-radius: 18px; box-shadow: 0 2px 10px rgba(15, 77, 58, 0.06); }
input, select, textarea { border-radius: 12px !important; }
input[type="search"] { border-radius: 999px !important; padding-left: 1rem; }
.badge { border-radius: 999px; }
.brand-mark { background: var(--primary); }
.sidebar .nav a.active { background: var(--primary); box-shadow: 0 4px 12px rgba(15, 77, 58, 0.25); }
.sidebar .nav-primary { color: var(--primary) !important; }
.avatar { background: var(--primary); color: #fff; }
.stats-color .stat { background: #fff !important; color: var(--text); border-left: 4px solid var(--primary); }
.stats-color .stat:nth-child(4n+2) { border-left-color: var(--accent); }
.stats-color .stat:nth-child(4n+3) { border-left-color: #2e8b6e; }
.stats-color .stat:nth-child(4n+4) { border-left-color: #d9534f; }
.stats-color .stat::after { background: var(--soft); }
.stats-color .stat-label { color: var(--muted); }
.greet h1 { font-size: 1.6rem; margin: 0 0 0.2rem; }
.greet p { margin: 0; }
.greet { margin-bottom: 1rem; }
.hero { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.4rem 1.5rem; margin-bottom: 1.25rem; border-radius: 20px; color: #fff;
  background: radial-gradient(circle at 85% 20%, rgba(231, 176, 75, 0.35), transparent 45%), linear-gradient(135deg, #0f4d3a, #1b6b52); }
.hero h2 { margin: 0 0 0.3rem; font-size: 1.25rem; }
.hero p { margin: 0; opacity: 0.85; max-width: 32rem; }
.hero-go { flex: none; width: 2.75rem; height: 2.75rem; border-radius: 50%; background: #fff; color: var(--primary); display: grid; place-items: center; font-size: 1.3rem; font-weight: 700; text-decoration: none; }
.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.75rem; margin-bottom: 1.25rem; max-width: 34rem; }
.quick a { display: grid; justify-items: center; gap: 0.35rem; font-size: 0.8rem; color: var(--text); text-decoration: none; }
.quick a span { width: 3.2rem; height: 3.2rem; border-radius: 16px; display: grid; place-items: center; background: var(--soft); color: var(--primary); }
.quick a:nth-child(2) span { background: #fdf3e1; color: #b07a17; }
.tabbar { display: none; }
@media (max-width: 860px) {
  .sidebar .nav { display: none; }
  .tabbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: #fff; border-top: 1px solid var(--border); padding: 0.35rem 0.25rem calc(0.35rem + env(safe-area-inset-bottom)); box-shadow: 0 -4px 16px rgba(15, 77, 58, 0.06); }
  .tabbar a { flex: 1; display: grid; justify-items: center; gap: 0.15rem; font-size: 0.7rem; color: #8a948f; text-decoration: none; padding: 0.2rem 0; }
  .tabbar a.active { color: var(--primary); font-weight: 600; }
  .app .main { padding-bottom: 4.5rem; }
  .hero { padding: 1.1rem 1.2rem; }
  .stats { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
  .stat-value { font-size: 1.05rem; white-space: normal; overflow-wrap: anywhere; }
}
@media print { .tabbar { display: none !important; } }
.foot-links { display: none; }
@media (max-width: 860px) {
  .foot-links { display: flex; gap: 0.75rem; }
  .foot-links a { color: var(--primary); font-weight: 600; text-decoration: none; }
}
.stats-color .stat > * { position: relative; z-index: 1; }

/* Emerald & gold theme */
:root { --primary: #0F3D36; --primary-dark: #0b2e29; --ink: #132220; --accent: #E6B86A; --bg: #F4F7F6; --soft: #EAF3F1; --muted: #7A8A84; --border: #ECEFED; --text: #132220; }
body { background: var(--bg); color: var(--ink); }
h1, h2, .pagebar-title { color: var(--ink); letter-spacing: -0.01em; }
.button { background: var(--primary); box-shadow: 0 8px 20px -10px rgba(15, 61, 54, 0.6); }
.button:hover { background: var(--ink); }
.button-secondary { background: #fff; color: var(--primary); box-shadow: inset 0 0 0 1px #dcebe8; }
.card, .table-wrap, .stat { border-radius: 22px; box-shadow: 0 4px 20px -10px rgba(0, 0, 0, 0.08); }
th { background: #F7F9F9; color: var(--muted); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); }
.sidebar { background: var(--ink); border-right: 0; }
.sidebar .brand, .sidebar-foot .business-name { color: #fff; }
.sidebar .nav a { color: #b8c7c2; }
.sidebar .nav a:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }
.sidebar .nav a.active { background: var(--accent); color: var(--ink); box-shadow: 0 10px 25px -8px rgba(230, 184, 106, 0.5); font-weight: 700; }
.sidebar .nav-primary { color: var(--accent) !important; }
.sidebar .nav-primary.active { color: var(--ink) !important; }
.sidebar-foot, .sidebar-foot .link-button { color: #8fa39c; }
.brand-mark { background: var(--accent); color: var(--ink); }
.avatar { background: var(--accent); color: var(--ink); border-radius: 50%; }
.hero { border-radius: 26px; background: radial-gradient(circle at 88% 15%, rgba(230, 184, 106, 0.45), transparent 42%), linear-gradient(140deg, #132220, #0F3D36 60%, #162C29); box-shadow: 0 25px 70px -25px rgba(15, 61, 54, 0.55); }
.hero-go { background: var(--accent); color: var(--ink); box-shadow: 0 10px 25px rgba(230, 184, 106, 0.35); }
.quick a span { border-radius: 18px; background: #fff; color: var(--primary); box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05); }
.quick a:nth-child(2) span { background: var(--primary); color: var(--accent); }
.stats-color .stat { border-left: 0; }
.stats-color .stat::after { background: var(--soft); }
.stats-color .stat:nth-child(4n+2)::after { background: #f8ecd6; }
.stats-color .stat-value { color: var(--primary); }
.badge { background: var(--soft); color: var(--primary); font-weight: 600; padding: 0.1rem 0.55rem; }
.notice { background: #fbf3e4; border-left-color: var(--accent); }
.receipt { border-radius: 22px; border-top: 6px solid var(--accent); }
.auth-page { min-height: 100vh; background: radial-gradient(circle at 80% 10%, rgba(230, 184, 106, 0.35), transparent 40%), linear-gradient(160deg, #081519, #0F3D36); }
.auth-page .topbar { background: transparent; border: 0; }
.auth-page .topbar .brand, .auth-page .topbar a, .auth-page .topbar .link-button { color: #fff; }
.auth-page .container { padding-top: 6vh; }
.auth-page .auth-intro { color: #fff; text-align: center; max-width: 30rem; margin: 0 auto 1.25rem; }
.auth-page .auth-intro h1 { color: #fff; font-size: 2rem; margin: 0 0 0.35rem; }
.auth-page .auth-intro h1 span { color: var(--accent); }
.auth-page .auth-intro p { margin: 0; color: #cfe0db; }
.auth-page .card { border-radius: 28px; box-shadow: 0 25px 70px -15px rgba(0, 0, 0, 0.45); }
.auth-page .button { width: 100%; background: var(--accent); color: var(--ink); }
@media (max-width: 860px) {
  .sidebar { background: var(--ink); }
  .sidebar-foot .link-button { color: #cfe0db; }
  .tabbar { left: 0.75rem; right: 0.75rem; bottom: calc(0.6rem + env(safe-area-inset-bottom)); border: 0; border-radius: 22px; background: var(--ink); padding: 0.45rem 0.25rem; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25); }
  .tabbar a { color: #8fa39c; }
  .tabbar a.active { color: var(--accent); }
  .app .main { padding-bottom: 6rem; }
}
.hero h2 { color: #fff; }
.foot-links a { color: var(--accent); }
.tx-dot { background: var(--primary); border-radius: 50%; }
.tx-2 { background: var(--accent); } .tx-3 { background: #2e8b6e; } .tx-4 { background: #d9534f; } .tx-5 { background: var(--muted); }

/* Phone: keep the top strip to two tidy rows (brand, then hostel name and links). */
@media (max-width: 860px) {
  .foot-links { display: inline-flex; flex-wrap: wrap; gap: 0.25rem 0.9rem; }
  .sidebar { padding: 0.6rem 0.9rem; gap: 0.3rem 0.75rem; }
  .sidebar-foot { order: 2; flex: 1 1 100%; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 0.9rem; font-size: 0.82rem; }
  .sidebar-foot .business-name { flex: 1 1 100%; font-size: 0.95rem; }
  .sidebar-foot a, .sidebar-foot .link-button { color: #cfe0db; text-decoration: none; }
  .hide-sm { display: none; }
}

/* ---- Home redesign: greeting header, search, chips, room cards, floating tab bar ---- */
.page-dashboard .pagebar { display: none; }
.home-top { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; margin-bottom: 1rem; }
.loc-chip { display: inline-flex; align-items: center; gap: 0.4rem; max-width: 62%; padding: 0.35rem 0.8rem 0.35rem 0.5rem; border-radius: 999px; background: var(--ink); color: #fff; font-size: 0.85rem; font-weight: 600; text-decoration: none; }
.loc-chip svg { width: 18px; height: 18px; flex: none; color: var(--accent); }
.loc-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.home-actions { display: flex; align-items: center; gap: 0.6rem; }
.round-btn { position: relative; display: grid; place-items: center; width: 2.7rem; height: 2.7rem; border-radius: 50%; background: #fff; color: var(--primary); box-shadow: 0 4px 14px -6px rgba(0, 0, 0, 0.2); }
.round-btn .dot { position: absolute; top: 0.55rem; right: 0.6rem; width: 0.55rem; height: 0.55rem; border-radius: 50%; background: #e5484d; border: 2px solid #fff; }
.avatar-lg { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; border-radius: 50%; background: var(--accent); color: var(--ink); font-weight: 800; text-decoration: none; }
.home-title { margin: 0 0 1rem; font-size: 1.9rem; line-height: 1.15; letter-spacing: -0.02em; }
.home-title span { display: block; color: var(--primary); }
.home-search { display: flex; align-items: center; gap: 0.6rem; padding: 0 1rem; margin-bottom: 0.9rem; border-radius: 999px; background: #e9eeec; color: var(--muted); }
.home-search input { flex: 1; border: 0 !important; background: transparent; padding: 0.85rem 0; outline: none; min-width: 0; }
.home-search input:focus { outline: none; }
.home-search:focus-within { box-shadow: 0 0 0 2px var(--accent); }
.chips { display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.25rem; margin-bottom: 1.1rem; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; padding: 0.45rem 1rem; border-radius: 999px; background: #e9eeec; color: #4d5d57; font-size: 0.85rem; font-weight: 600; text-decoration: none; }
.chip.active { background: var(--ink); color: #fff; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 1.4rem 0 0.75rem; }
.section-head h2 { margin: 0; }
.section-head a { font-size: 0.85rem; font-weight: 600; }
.room-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; margin-bottom: 1.25rem; }
.room-grid.single { grid-template-columns: 1fr; max-width: 22rem; }
.room-card { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 9.5rem; padding: 0.9rem; border-radius: 22px; color: #fff; text-decoration: none; overflow: hidden; background: linear-gradient(160deg, #1b6b52, #0F3D36); }
.room-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0, 0, 0, 0.45), transparent 60%); pointer-events: none; }
.room-card > * { position: relative; z-index: 1; }
.room-card.tone-2 { background: linear-gradient(160deg, #c8923a, #7a5416); }
.room-card.tone-3 { background: linear-gradient(160deg, #2e8b6e, #12493b); }
.room-card.tone-4 { background: linear-gradient(160deg, #3c5a73, #16293a); }
.room-card.tone-5 { background: linear-gradient(160deg, #0F3D36, #132220); }
.room-card.tone-6 { background: linear-gradient(160deg, #b5743b, #5e3417); }
.room-badge { position: absolute !important; top: 0.7rem; left: 0.7rem; padding: 0.15rem 0.6rem; border-radius: 999px; background: rgba(255, 255, 255, 0.92); color: var(--primary); font-size: 0.72rem; font-weight: 700; }
.room-fee { position: absolute !important; top: 0.7rem; right: 0.7rem; padding: 0.15rem 0.55rem; border-radius: 999px; background: rgba(0, 0, 0, 0.35); font-size: 0.72rem; font-weight: 600; }
.room-info { display: grid; gap: 0.1rem; }
.room-info strong { font-size: 1.05rem; }
.room-info small { opacity: 0.9; }
.home-foot { display: none; }

@media (max-width: 860px) {
  .page-dashboard .sidebar { display: none; }
  .home-foot { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.25rem; margin: 1rem 0 0.5rem; font-size: 0.85rem; }
  .home-foot a, .home-foot .link-button { color: var(--muted); text-decoration: none; }
  /* Floating white pill tab bar with a gold marker on the active tab. */
  .tabbar { left: 0.9rem; right: 0.9rem; bottom: calc(0.7rem + env(safe-area-inset-bottom)); border-radius: 26px; background: #fff; padding: 0.55rem 0.35rem; box-shadow: 0 14px 34px -10px rgba(15, 61, 54, 0.35); }
  .tabbar a { position: relative; color: #8a9a94; }
  .tabbar a.active { color: var(--primary); }
  .tabbar a.active::before { content: ""; position: absolute; top: -0.55rem; width: 1.6rem; height: 3px; border-radius: 3px; background: var(--accent); }
}
@media (min-width: 861px) {
  .room-grid { grid-template-columns: repeat(3, 1fr); }
  .home-title { font-size: 2.2rem; }
}

/* ---- Welcome-style login and signup ---- */
.welcome-page .topbar { display: none; }
.welcome-page .container { max-width: 30rem; padding: 0; }
.welcome-page .messages { margin: 0.75rem; }
.welcome { min-height: 100vh; display: flex; flex-direction: column; }
.welcome-hero { padding: 3.2rem 1.5rem 4.2rem; text-align: center; color: #fff; }
.welcome-mark { display: inline-grid; place-items: center; width: 5rem; height: 5rem; margin-bottom: 0.8rem; border-radius: 50%; background: #fff; color: var(--primary); font-size: 2.3rem; font-weight: 800; box-shadow: 0 12px 30px -8px rgba(0, 0, 0, 0.4); }
.welcome-name { font-size: 1.9rem; font-weight: 800; letter-spacing: -0.01em; }
.welcome-sub { margin-top: 0.2rem; color: #cfe0db; }
.welcome-sheet { flex: 1; margin-top: -2.2rem; padding: 1.8rem 1.5rem 2.2rem; border-radius: 36px 36px 0 0; background: #fff; }
.welcome-sheet h1 { margin: 0 0 0.4rem; text-align: center; font-size: 2rem; letter-spacing: 0.08em; color: var(--ink); }
.welcome-lead { margin: 0 0 1.25rem; text-align: center; color: var(--muted); }
.welcome-sheet .button { display: block; width: 100%; padding: 0.9rem 1.3rem; text-align: center; background: var(--ink); color: #fff; box-shadow: none; }
.welcome-sheet .button:hover { background: var(--primary); }
.welcome-sheet .button-outline { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1px #d3dcd9; }
.welcome-sheet .button-outline:hover { background: var(--soft); color: var(--ink); }
.welcome-sheet form > div { margin-bottom: 0.9rem; }
.welcome-note { text-align: center; margin: 0.9rem 0 0; }
.welcome-or { margin: 1.3rem 0 0.6rem; text-align: center; color: var(--muted); font-size: 0.9rem; }

/* Long-text pages such as the privacy policy */
.prose { max-width: 42rem; }
.prose h2 { margin: 1.4rem 0 0.4rem; font-size: 1.1rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: 0.4rem; }
