/* BalayHub — app styles. Mobile-first; large touch targets for everyday phone use. */

@font-face {
  font-family: "Manrope";
  src: url("/fonts/manrope-var.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --navy: #16324f;
  --navy-2: #1f4570;
  --teal: #0e7c66;
  --teal-2: #0b6a57;
  --teal-soft: #e3f4ef;
  --bg: #f4f6f9;
  --surface: #ffffff;
  --line: #e2e7ee;
  --line-2: #cfd7e2;
  --text: #17212e;
  --muted: #5b6878;
  --red: #b42318;
  --red-soft: #fdecea;
  --amber: #a15c07;
  --amber-soft: #fef3e2;
  --blue: #1d5fb8;
  --blue-soft: #e8f0fc;
  --green: #08744a;
  --green-soft: #e4f5ec;
  --gray-soft: #eef1f5;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(16, 32, 56, .06), 0 4px 16px rgba(16, 32, 56, .05);
  --sidebar: 248px;
  --focus: 0 0 0 3px rgba(14, 124, 102, .35);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { line-height: 1.25; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: 1.5rem; font-weight: 800; }
h2 { font-size: 1.15rem; font-weight: 750; }
h3 { font-size: 1rem; font-weight: 700; }
p { margin: 0; }
a { color: var(--teal); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: none; box-shadow: var(--focus); }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.boot { display: grid; place-items: center; min-height: 100vh; color: var(--muted); }

/* ---------------------------------------------------------------- banners */
.offline-banner {
  position: sticky; top: 0; z-index: 60;
  background: var(--amber-soft); color: var(--amber); border-bottom: 1px solid #f3d29b;
  padding: 10px 16px; font-size: .9rem; font-weight: 600; text-align: center;
}
.alert { padding: 12px 14px; border-radius: var(--radius-sm); font-size: .92rem; font-weight: 600; }
.alert--error { background: var(--red-soft); color: var(--red); }
.alert--info { background: var(--blue-soft); color: var(--blue); }
.alert--warn { background: var(--amber-soft); color: var(--amber); }
.alert--ok { background: var(--green-soft); color: var(--green); }
.alert a { color: inherit; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 10px 18px; border-radius: 12px; border: 1px solid transparent;
  font-weight: 700; font-size: .95rem; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, color .15s;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn:disabled { opacity: .6; cursor: progress; }
.btn--primary { background: var(--teal); color: #fff; }
.btn--primary:hover { background: var(--teal-2); }
.btn--secondary { background: var(--surface); border-color: var(--line-2); color: var(--navy); }
.btn--secondary:hover { border-color: var(--navy); }
.btn--ghost { background: transparent; color: var(--navy); }
.btn--ghost:hover { background: var(--gray-soft); }
.btn--danger { background: var(--surface); border-color: #f0b8b2; color: var(--red); }
.btn--danger:hover { background: var(--red-soft); }
.btn--sm { min-height: 38px; padding: 6px 12px; font-size: .88rem; border-radius: 10px; }
.btn--block { width: 100%; }
.link-btn { background: none; border: 0; padding: 0; color: var(--teal); font-weight: 700; cursor: pointer; text-decoration: underline; }

/* ---------------------------------------------------------------- public pages */
.public { min-height: 100vh; display: flex; flex-direction: column; }
.public__top { padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em; }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand b { color: var(--teal); font-weight: 800; }
.public__main { flex: 1; display: grid; place-items: center; padding: 16px 16px 48px; }
.auth-card { width: 100%; max-width: 440px; background: var(--surface); border-radius: 18px; box-shadow: var(--shadow); padding: 28px 22px; }
.auth-card h1 { margin-bottom: 6px; }
.auth-card .lead { color: var(--muted); margin-bottom: 20px; }
.auth-card__foot { margin-top: 18px; text-align: center; color: var(--muted); font-size: .93rem; }

.welcome { width: 100%; max-width: 1040px; display: grid; gap: 32px; align-items: center; }
.welcome__copy h1 { font-size: clamp(2rem, 6vw, 3rem); color: var(--navy); letter-spacing: -0.03em; }
.welcome__copy h1 span { color: var(--teal); }
.welcome__copy p { font-size: 1.1rem; color: var(--muted); margin: 14px 0 24px; max-width: 34em; }
.welcome__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.welcome__actions .btn { min-width: 160px; }
.welcome__points { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 10px; }
.welcome__points li { display: flex; gap: 10px; align-items: flex-start; color: var(--text); font-weight: 600; }
.welcome__points li::before { content: ""; flex: none; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%; background: var(--teal-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%230e7c66' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/16px no-repeat; }
.welcome__preview { background: var(--surface); border-radius: 20px; box-shadow: var(--shadow); padding: 18px; display: grid; gap: 12px; }
.welcome__preview small { color: var(--muted); font-size: .78rem; }
@media (min-width: 880px) { .welcome { grid-template-columns: 1.1fr 1fr; } }

/* ---------------------------------------------------------------- app shell */
.shell { min-height: 100vh; }
.sidebar { display: none; }
.topbar {
  position: sticky; top: 0; z-index: 30; background: var(--navy); color: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px;
  padding-top: max(12px, env(safe-area-inset-top));
}
.topbar .brand { color: #fff; font-size: 1.1rem; }
.topbar .brand b { color: #5fd3b8; }
.topbar__org { font-size: .8rem; opacity: .8; max-width: 45vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.content { padding: 16px 16px calc(96px + env(safe-area-inset-bottom)); max-width: 1180px; margin: 0 auto; }

.bottomnav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; background: var(--surface);
  border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, 1fr);
  padding-bottom: env(safe-area-inset-bottom);
}
.bottomnav a, .bottomnav button {
  display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px 9px;
  font-size: .72rem; font-weight: 700; color: var(--muted); text-decoration: none; background: none; border: 0; cursor: pointer;
}
.bottomnav svg { width: 24px; height: 24px; }
.bottomnav [aria-current="page"] { color: var(--teal); }

.morenav { position: fixed; inset: 0; z-index: 50; background: rgba(10, 20, 35, .4); display: flex; align-items: flex-end; }
.morenav__sheet { background: var(--surface); width: 100%; border-radius: 18px 18px 0 0; padding: 12px 12px calc(16px + env(safe-area-inset-bottom)); }
.morenav__sheet a, .morenav__sheet button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 12px; border-radius: 12px; color: var(--text); text-decoration: none; font-weight: 700; background: none; border: 0; cursor: pointer; text-align: left; }
.morenav__sheet a:hover, .morenav__sheet button:hover { background: var(--gray-soft); }
.morenav__sheet svg { width: 22px; height: 22px; color: var(--navy); }

@media (min-width: 960px) {
  .shell { display: grid; grid-template-columns: var(--sidebar) 1fr; }
  .topbar, .bottomnav { display: none; }
  .sidebar {
    display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh;
    background: var(--navy); color: #fff; padding: 20px 14px;
  }
  .sidebar .brand { color: #fff; padding: 4px 8px 18px; }
  .sidebar .brand b { color: #5fd3b8; }
  .sidebar nav { display: grid; gap: 2px; }
  .sidebar nav a {
    display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px;
    color: rgba(255,255,255,.82); text-decoration: none; font-weight: 650; font-size: .95rem;
  }
  .sidebar nav a svg { width: 20px; height: 20px; }
  .sidebar nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
  .sidebar nav a[aria-current="page"] { background: rgba(95, 211, 184, .16); color: #fff; }
  .sidebar__foot { margin-top: auto; border-top: 1px solid rgba(255,255,255,.12); padding: 14px 8px 0; font-size: .85rem; }
  .sidebar__foot strong { display: block; }
  .sidebar__foot span { opacity: .75; }
  .sidebar__foot button { margin-top: 10px; color: #fff; border-color: rgba(255,255,255,.3); background: transparent; }
  .content { padding: 28px 32px 48px; }
}

/* ---------------------------------------------------------------- page structure */
.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.page-head__title { display: grid; gap: 2px; }
.page-head__title p { color: var(--muted); font-size: .93rem; }
.page-head__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-weight: 700; text-decoration: none; font-size: .9rem; margin-bottom: 6px; }
.back:hover { color: var(--navy); }

.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.card + .card, .stack > * + * { margin-top: 16px; }
.card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card__head a { font-weight: 700; font-size: .9rem; text-decoration: none; }
.grid { display: grid; gap: 16px; }
.grid > *, .stats > *, .stack > * { min-width: 0; }
@media (min-width: 760px) { .grid--2 { grid-template-columns: 1fr 1fr; } .grid--3 { grid-template-columns: repeat(3, 1fr); } }

.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px;
  text-decoration: none; color: inherit; display: block; border: 1px solid transparent;
}
a.stat:hover { border-color: var(--line-2); }
.stat__label { font-size: .8rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.stat__value { overflow-wrap: anywhere; font-size: clamp(1.1rem, 4.6vw, 1.45rem); font-weight: 800; margin-top: 4px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat__sub { font-size: .82rem; color: var(--muted); margin-top: 2px; }
.stat--alert .stat__value { color: var(--red); }
.stat--good .stat__value { color: var(--green); }

.quick { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 760px) { .quick { grid-template-columns: repeat(4, 1fr); } }
.quick a, .quick button {
  display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 12px; background: var(--teal-soft);
  color: var(--teal-2); font-weight: 750; text-decoration: none; border: 0; cursor: pointer; font-size: .93rem; text-align: left;
}
.quick a:hover, .quick button:hover { background: #d2ece4; }
.quick svg { width: 22px; height: 22px; flex: none; }

/* ---------------------------------------------------------------- lists */
.list { list-style: none; margin: 0; padding: 0; }
.list > li + li { border-top: 1px solid var(--line); }
.row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 2px;
  color: inherit; text-decoration: none;
}
a.row:hover .row__title { color: var(--teal); }
.row__main { min-width: 0; display: grid; gap: 2px; }
.row__title { font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.row__sub { font-size: .85rem; color: var(--muted); }
.row__end { text-align: right; display: grid; gap: 4px; justify-items: end; flex: none; }
.amount { font-weight: 800; font-variant-numeric: tabular-nums; }
.amount--neg { color: var(--red); }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.strike { text-decoration: line-through; }

.badge {
  display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px;
  font-size: .75rem; font-weight: 750; white-space: nowrap; background: var(--gray-soft); color: var(--muted);
}
.badge--paid, .badge--vacant, .badge--resolved, .badge--active, .badge--low { background: var(--green-soft); color: var(--green); }
.badge--partial, .badge--in_progress, .badge--medium, .badge--expiring { background: var(--amber-soft); color: var(--amber); }
.badge--overdue, .badge--urgent, .badge--high, .badge--voided { background: var(--red-soft); color: var(--red); }
.badge--unpaid, .badge--open, .badge--occupied { background: var(--blue-soft); color: var(--blue); }
.badge--vacant { background: var(--teal-soft); color: var(--teal-2); }

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 750; white-space: nowrap; }
.table td.num, .table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table tfoot td { font-weight: 800; border-bottom: 0; }

.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; align-items: center; }
.toolbar .search { flex: 1 1 220px; }
.tabs { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 14px; padding-bottom: 2px; }
.tabs a, .tabs button {
  padding: 8px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line-2);
  font-weight: 700; font-size: .88rem; color: var(--muted); text-decoration: none; white-space: nowrap; cursor: pointer;
}
.tabs [aria-current="true"], .tabs [aria-selected="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }

.empty { text-align: center; padding: 32px 16px; display: grid; gap: 10px; justify-items: center; }
.empty svg { width: 48px; height: 48px; color: var(--line-2); }
.empty h3 { font-size: 1.05rem; }
.empty p { color: var(--muted); max-width: 30em; }

.dl { display: grid; grid-template-columns: minmax(110px, 40%) 1fr; gap: 8px 12px; margin: 0; font-size: .94rem; }
.dl dt { color: var(--muted); font-weight: 600; }
.dl dd { margin: 0; font-weight: 650; word-break: break-word; }

/* ---------------------------------------------------------------- forms */
.form { display: grid; gap: 14px; }
.form-row { display: grid; gap: 14px; }
@media (min-width: 560px) { .form-row--2 { grid-template-columns: 1fr 1fr; } }
.field { display: grid; gap: 6px; }
.field label, .field legend { font-weight: 700; font-size: .9rem; }
.field .req { color: var(--red); }
.field .hint { font-size: .82rem; color: var(--muted); }
.field .error { font-size: .84rem; color: var(--red); font-weight: 650; }
.input, select.input, textarea.input {
  width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px;
  background: #fff; font-size: 1rem;
}
textarea.input { min-height: 96px; resize: vertical; }
.input:focus { border-color: var(--teal); box-shadow: var(--focus); outline: none; }
.field--invalid .input { border-color: var(--red); }
.input-money { position: relative; }
.input-money::before { content: "₱"; position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 700; }
.input-money .input { padding-left: 28px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--teal); flex: none; }
.checks { display: grid; gap: 8px; max-height: 220px; overflow: auto; padding: 4px; }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; margin-top: 4px; }
@media (max-width: 559px) { .form-actions .btn { flex: 1 1 auto; } }

/* ---------------------------------------------------------------- dialog */
dialog.modal {
  border: 0; padding: 0; border-radius: 18px; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 32px);
  box-shadow: 0 20px 60px rgba(10, 20, 35, .3); color: var(--text);
}
dialog.modal::backdrop { background: rgba(10, 20, 35, .45); }
.modal__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 6px; }
.modal__body { padding: 10px 20px 20px; overflow: auto; max-height: calc(100vh - 120px); }
.modal__close { background: none; border: 0; font-size: 1.6rem; line-height: 1; cursor: pointer; color: var(--muted); width: 40px; height: 40px; border-radius: 10px; }
.modal__close:hover { background: var(--gray-soft); }
@media (max-width: 559px) {
  dialog.modal { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 18px 18px 0 0; max-height: 92vh; }
}

/* ---------------------------------------------------------------- toasts */
.toasts { position: fixed; z-index: 100; left: 50%; transform: translateX(-50%); bottom: calc(84px + env(safe-area-inset-bottom)); display: grid; gap: 8px; width: min(420px, calc(100vw - 32px)); }
@media (min-width: 960px) { .toasts { bottom: 24px; } }
.toast { background: var(--navy); color: #fff; padding: 12px 16px; border-radius: 12px; font-weight: 650; box-shadow: var(--shadow); font-size: .93rem; }
.toast--error { background: var(--red); }

/* ---------------------------------------------------------------- misc */
.bar { height: 8px; border-radius: 99px; background: var(--gray-soft); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--teal); border-radius: 99px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.divider { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.files { display: grid; gap: 8px; }
.file-link { display: inline-flex; gap: 6px; align-items: center; font-weight: 650; font-size: .9rem; }
.skeleton { height: 120px; border-radius: var(--radius); background: linear-gradient(90deg, #e9edf2, #f4f6f9, #e9edf2); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.prose { max-width: 760px; }
.prose h2 { margin: 22px 0 8px; }
.prose p, .prose li { color: var(--text); margin-bottom: 8px; }
.prose ul { padding-left: 20px; }

@media print {
  .sidebar, .topbar, .bottomnav, .page-head__actions, .toolbar, .no-print { display: none !important; }
  .shell { display: block; }
  .content { padding: 0; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  body { background: #fff; }
}

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ================================================================ short-term rentals */
.subhead { font-size: .82rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 750; margin: 6px 0 6px; }
.tabs--compact { margin-bottom: 0; }
.tabs--compact button { padding: 6px 12px; font-size: .84rem; }
.input--sm { min-height: 38px; padding: 6px 10px; font-size: .9rem; width: auto; }
.card--flush { padding: 0; overflow: hidden; }
.stat--flat { box-shadow: none; border: 1px solid var(--line); }
.stat--flat .stat__value { font-size: 1.6rem; }
.stat--flat .stat__label { text-transform: none; letter-spacing: 0; font-size: .9rem; color: var(--text); font-weight: 650; margin-top: 2px; }
.hero-num { font-size: 2rem; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin: 2px 0 4px; }
.delta { display: inline-block; font-size: .8rem; font-weight: 750; padding: 2px 8px; border-radius: 99px; margin-bottom: 6px; }
.delta--up { background: var(--green-soft); color: var(--green); }
.delta--down { background: var(--red-soft); color: var(--red); }
.trend-chips { margin: 4px 0 10px; }
.trend-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; background: var(--gray-soft); font-size: .88rem; }
.row-link { cursor: pointer; }
.row-link:hover td { background: #f7f9fb; }
.row-link:focus-visible { outline: 2px solid var(--teal); }

/* channel colors (bars, badges) */
.badge--ch-direct { background: var(--teal-soft); color: var(--teal-2); }
.badge--ch-airbnb { background: #fdecee; color: #c0263a; }
.badge--ch-booking { background: #e6eefb; color: #1e4fa3; }
.badge--ch-agoda { background: #f2ebfb; color: #6a35b5; }
.badge--ch-other { background: var(--gray-soft); color: var(--muted); }

/* charts */
.chart { position: relative; }
.chart-plot svg { display: block; overflow: visible; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .85rem; color: var(--muted); margin: 4px 0 6px; }
.chart-legend__item { display: inline-flex; align-items: center; gap: 6px; }
.chart-swatch { display: inline-block; width: 10px; height: 10px; border-radius: 3px; border: 2px solid transparent; }
.chart-swatch--dashed { border-style: dashed; height: 0; width: 14px; border-width: 2px 0 0; border-radius: 0; }
.chart-tip { position: absolute; z-index: 5; min-width: 160px; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; box-shadow: var(--shadow); padding: 8px 10px; font-size: .84rem; pointer-events: none; }
.chart-tip__row { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.chart-foot { text-align: right; margin-top: 4px; }

/* multi-calendar */
.cal-scroll { overflow: auto; max-height: calc(100vh - 260px); min-height: 240px; -webkit-overflow-scrolling: touch; }
.cal { --cal-col: 64px; --cal-side: 190px; width: max-content; min-width: 100%; }
@media (max-width: 640px) { .cal { --cal-col: 54px; --cal-side: 128px; } }
.cal-row { display: flex; border-bottom: 1px solid var(--line); min-height: 64px; }
.cal-row--head { position: sticky; top: 0; z-index: 4; background: var(--surface); min-height: 48px; }
.cal-side {
  position: sticky; left: 0; z-index: 3; flex: none; width: var(--cal-side); background: var(--surface);
  border-right: 1px solid var(--line); padding: 8px 10px; display: flex; flex-direction: column; gap: 3px; justify-content: center; font-size: .82rem; color: var(--muted);
}
.cal-row--head .cal-side { z-index: 5; font-weight: 700; }
.cal-name { font-weight: 750; color: var(--text); text-decoration: none; font-size: .9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-prop { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-side .badge { align-self: flex-start; }
.cal-days { display: flex; position: relative; }
.cal-day-head { width: var(--cal-col); flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: .75rem; color: var(--muted); border-left: 1px solid var(--line); }
.cal-day-head b { font-size: .95rem; color: var(--text); }
.cal-day-head.is-weekend b { color: var(--navy); }
.cal-day-head.is-today { background: var(--teal-soft); }
.cal-day-head.is-today b { color: var(--teal-2); }
.cal-cell {
  width: var(--cal-col); flex: none; border: 0; border-left: 1px solid var(--line); background: transparent; cursor: pointer;
  font-size: .76rem; color: var(--muted); padding: 34px 2px 4px; font-variant-numeric: tabular-nums;
}
.cal-cell:hover { background: #f3f6f9; }
.cal-cell.is-past { background: repeating-linear-gradient(135deg, #fafbfc, #fafbfc 6px, #f3f5f8 6px, #f3f5f8 12px); color: #a7b0bb; }
.cal-cell.is-today { box-shadow: inset 2px 0 0 var(--teal); }
.cal-cell.has-override { color: var(--navy); font-weight: 750; }
.cal-bar {
  position: absolute; top: 8px; height: 26px; border-radius: 13px; border: 0; z-index: 2; cursor: pointer;
  color: #fff; font-size: .78rem; font-weight: 700; padding: 0 10px; text-align: left;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; box-shadow: 0 0 0 2px var(--surface);
}
.cal-bar.cut-left { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.cal-bar.cut-right { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.cal-bar--direct { background: var(--teal); }
.cal-bar--airbnb { background: #d93b52; }
.cal-bar--booking { background: #1e4fa3; }
.cal-bar--agoda { background: #6a35b5; }
.cal-bar--other { background: #5b6878; }
.cal-bar--block { background: #c9d1dc; color: #3b4652; }
.cal-legend { margin-bottom: 10px; gap: 12px; font-size: .82rem; color: var(--muted); }
.cal-legend__item { display: inline-flex; align-items: center; gap: 6px; }
.cal-swatch { display: inline-block; width: 18px; height: 10px; border-radius: 5px; }
.cal-title { min-width: 120px; text-align: center; }

/* reservations */
.res-layout { display: grid; gap: 16px; }
.res-layout > * { min-width: 0; }
.res-side { display: none; }
.saved-views { display: grid; gap: 2px; }
.saved-views button { text-align: left; background: none; border: 0; padding: 9px 10px; border-radius: 8px; font-weight: 650; color: var(--text); cursor: pointer; font-size: .92rem; }
.saved-views button:hover { background: var(--gray-soft); }
.saved-views button[aria-current="true"] { background: var(--teal-soft); color: var(--teal-2); }
.res-view-select { flex: 1 1 200px; }
@media (min-width: 1100px) {
  .res-layout { grid-template-columns: 230px 1fr; align-items: start; }
  .res-side { display: block; position: sticky; top: 20px; }
  .res-view-select { display: none; }
}
.toolbar select.input { width: auto; flex: 0 1 200px; }

/* listings */
.listing-grid { display: grid; gap: 16px; }
@media (min-width: 760px) { .listing-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1200px) { .listing-grid { grid-template-columns: repeat(3, 1fr); } }
.listing-grid .card + .card { margin-top: 0; }
.listing.is-focus { box-shadow: 0 0 0 2px var(--teal), var(--shadow); }

.res-table td.small { white-space: nowrap; }
