:root {
  --ink: #132019;
  --muted: #66736c;
  --paper: #fbfcf9;
  --surface: #fff;
  --line: #dfe5df;
  --green: #1d6b4f;
  --green-dark: #15543d;
  --green-soft: #eaf5ef;
  --sand: #f4eee2;
  --amber: #9c6713;
  --amber-soft: #fff5de;
  --red: #a13d36;
  --red-soft: #fff0ee;
  --radius: 16px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #f5f6f3;
  color: var(--ink);
  font:
    13px Inter,
    ui-sans-serif,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  -webkit-font-smoothing: antialiased;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button,
input,
select {
  min-height: 39px;
}
button {
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 650;
}
button:hover {
  background: var(--green-soft);
}
button.primary {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}
button.danger {
  color: var(--red);
  background: var(--red-soft);
}
input,
select,
textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid #cfd7d1;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
}
textarea {
  min-height: 75px;
  resize: vertical;
}
label {
  display: grid;
  gap: 6px;
  font-size: 11px;
  font-weight: 650;
  color: var(--muted);
}
:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}
[hidden] {
  display: none !important;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font:
    500 clamp(28px, 3vw, 38px) / 1.15 Georgia,
    serif;
  margin-bottom: 9px;
}
h2 {
  font:
    500 25px Georgia,
    serif;
  margin-bottom: 10px;
}
h3 {
  font-size: 14px;
}
small {
  font-size: 11px;
}
.muted {
  color: var(--muted);
  line-height: 1.55;
}
.eyebrow {
  color: var(--green);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 17px;
  background: var(--ink);
  color: white;
  font:
    italic 29px Georgia,
    serif;
  flex-shrink: 0;
}
.brand-mark.small {
  width: 39px;
  height: 39px;
  border-radius: 12px;
  font-size: 22px;
}
.login-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 12% 20%, #1d6b4f1f, transparent 30%),
    radial-gradient(circle at 90% 75%, #caa56629, transparent 28%), #f3f5f0;
}
.login-card {
  display: grid;
  gap: 16px;
  width: min(430px, 100%);
  padding: 38px;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 18px 45px #12201a1a;
}
.login-card .brand-mark {
  margin-bottom: 10px;
}
.login-card p {
  margin-bottom: 0;
}
.login-card h1 {
  font-size: 34px;
}
.login-card small {
  color: var(--muted);
}
.error {
  color: var(--red);
  line-height: 1.5;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 20;
  width: 74px;
  overflow: hidden;
  background: #fff;
  border-right: 1px solid var(--line);
  transition: width 0.18s ease;
  display: flex;
  flex-direction: column;
  box-shadow: 4px 0 20px #13201903;
}
.sidebar:hover,
.sidebar:has(:focus-visible),
.sidebar.open {
  width: 230px;
  box-shadow: 5px 0 20px #1320190a;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 17px;
  text-decoration: none;
  color: var(--ink);
  height: 78px;
  white-space: nowrap;
}
.nav-label {
  font-size: 11px;
  opacity: 0;
  transition: opacity 0.1s;
  white-space: nowrap;
  font-weight: 750;
}
.nav-label small {
  display: block;
  font-weight: 400;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.04em;
  margin-top: 4px;
}
.sidebar:hover .nav-label,
.sidebar:has(:focus-visible) .nav-label,
.sidebar.open .nav-label {
  opacity: 1;
}
.sidebar nav {
  display: grid;
  gap: 7px;
  padding: 22px 12px;
}
.sidebar nav a {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 45px;
  padding: 0 14px;
  border-radius: 9px;
  text-decoration: none;
  color: var(--muted);
  border-left: 3px solid transparent;
  white-space: nowrap;
}
.sidebar nav a.active {
  background: var(--green-soft);
  color: var(--green-dark);
  border-left-color: var(--green);
}
.nav-icon {
  font-size: 18px;
  width: 18px;
  text-align: center;
  flex-shrink: 0;
}
.sidebar-bottom {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
}
.avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--sand);
  color: var(--green-dark);
}
.main-shell {
  margin-left: 74px;
}
.app-header {
  height: 68px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 30px;
  gap: 12px;
}
.app-header > div {
  display: flex;
  align-items: center;
  gap: 14px;
}
.app-header .eyebrow {
  margin: 0;
}
.candidate {
  font-size: 9px;
  font-weight: 750;
  padding: 5px 8px;
  background: var(--sand);
  border-radius: 5px;
  color: #796346;
  letter-spacing: 0.05em;
}
.header-actions {
  gap: 8px !important;
}
.quiet {
  background: var(--surface);
}
.icon-button {
  border: 0;
  min-width: 36px;
  padding: 4px;
  font-size: 22px;
}
#mobile-nav {
  display: none;
}
main {
  max-width: 1800px;
  margin: auto;
  padding: 30px;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
}
.page-heading p {
  margin-bottom: 0;
}
.page-heading .eyebrow {
  margin-bottom: 8px;
}
.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.filters {
  display: flex;
  align-items: end;
  gap: 12px;
  flex-wrap: wrap;
}
.global-filters {
  padding: 15px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 22px;
}
.filters label {
  min-width: 130px;
  flex: 1;
}
.filters label:first-child {
  flex: 2;
}
.filters button {
  flex: 0 0 auto;
}
.notice {
  padding: 13px 16px;
  border-radius: 10px;
  background: var(--amber-soft);
  color: var(--amber);
  line-height: 1.5;
}
.notice.success {
  background: var(--green-soft);
  color: var(--green-dark);
}
.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.card {
  padding: 19px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  min-width: 0;
}
.card .metric-label {
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  display: block;
  margin-bottom: 12px;
}
.card .metric-value {
  font-size: 24px;
  font-weight: 550;
  letter-spacing: -0.03em;
  white-space: nowrap;
}
.card small {
  display: block;
  color: var(--muted);
  margin-top: 8px;
  line-height: 1.5;
}
.card.accent {
  background: var(--green-dark);
  color: #fff;
  border-color: var(--green-dark);
}
.card.accent .metric-label,
.card.accent small {
  color: #d4e8dc;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 18px;
}
.panel-heading {
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.panel-heading h3,
.panel-heading p {
  margin: 0;
}
.panel-body {
  padding: 18px 20px;
}
.table-wrap {
  overflow: auto;
  max-height: 68vh;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 12px;
  white-space: nowrap;
}
th {
  text-align: left;
  background: #f8faf7;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  position: sticky;
  top: 0;
  z-index: 2;
  font-weight: 700;
}
th,
td {
  padding: 13px 16px;
  border-bottom: 1px solid #edf0eb;
}
td.numeric,
th.numeric {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
tbody tr:hover {
  background: color-mix(in srgb, var(--surface) 96%, var(--ink));
}
td.description {
  min-width: 200px;
  max-width: 300px;
  white-space: normal;
  line-height: 1.5;
}
.pill {
  display: inline-block;
  padding: 4px 7px;
  border-radius: 5px;
  background: #f0f2ee;
  color: var(--muted);
  font-size: 10px;
  font-weight: 650;
}
.pill.verified,
.pill.reconciled {
  background: var(--green-soft);
  color: var(--green-dark);
}
.pill.unverified,
.pill.estimated {
  background: var(--amber-soft);
  color: var(--amber);
}
.empty {
  padding: 55px 24px;
  text-align: center;
}
.empty h2 {
  margin-bottom: 12px;
}
.empty p {
  max-width: 530px;
  margin: 0 auto 20px;
  color: var(--muted);
  line-height: 1.6;
}
.subtle {
  color: var(--muted);
  font-size: 11px;
}
.filters.local {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  gap: 8px;
}
.filters.local input,
.filters.local select {
  min-width: 110px;
  flex: 1;
  width: auto;
}
.filters.local input {
  flex: 2;
}
.table-footnote {
  padding: 13px 18px;
  font-size: 11px;
  line-height: 1.6;
  color: var(--muted);
  background: #fafbf8;
}
.report-table th:first-child,
.report-table td:first-child {
  position: sticky;
  left: 0;
  background: inherit;
  min-width: 195px;
  z-index: 1;
}
.report-table th:first-child {
  z-index: 3;
  background: #f8faf7;
}
.report-table .total {
  font-weight: 750;
  background: #f1f6f1;
}
.report-table td small {
  display: block;
  margin-top: 4px;
  font-size: 9px;
  color: var(--muted);
}
.report-table .selected {
  background: #eaf5ef;
}
.availability {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}
.availability p {
  margin: 5px 0 0;
}
.availability .pill {
  flex-shrink: 0;
}
footer {
  font-size: 10px;
  color: var(--muted);
  padding: 16px 0;
  line-height: 1.5;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 25px 70px #13201933;
  width: min(880px, calc(100% - 32px));
  max-height: 90vh;
  padding: 0;
}
dialog::backdrop {
  background: #13201966;
  backdrop-filter: blur(3px);
}
.dialog-heading {
  padding: 22px 25px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.dialog-heading h2 {
  margin-bottom: 0;
}
#dialog-body {
  padding: 24px;
}
#dialog-body :is(input, select, textarea) { font-weight: 450; }
@media (max-width: 480px) {
  dialog:not(.right-drawer):not(:has(.report-prepayment)) {
    width: calc(100% - 16px);
    max-width: calc(100% - 16px);
  }
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.form-grid .wide {
  grid-column: 1/-1;
}
.form-grid .hint {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 22px;
}
.setup-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.mapping {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 18px 0;
}
.file-zone {
  padding: 20px;
  border: 1px dashed #a8bcae;
  border-radius: 10px;
  background: #fbfcf9;
}
.history {
  margin-top: 22px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}
.history summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--muted);
}
.history pre {
  font-size: 10px;
  overflow: auto;
  max-height: 220px;
  background: #f5f6f3;
  padding: 12px;
  border-radius: 8px;
}
.link-button {
  padding: 2px;
  border: 0;
  min-height: 25px;
  background: none;
  color: var(--green);
  text-decoration: underline;
  font-size: 11px;
}
.doc-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.loading {
  padding: 45px;
  color: var(--muted);
  text-align: center;
}
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
@media (max-width: 1100px) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .app-header {
    padding: 0 20px;
  }
  .mapping {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 640px) {
  .sidebar {
    transform: translateX(-100%);
    width: 230px;
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .sidebar.open .nav-label {
    opacity: 1;
  }
  .main-shell {
    margin-left: 0;
  }
  #mobile-nav {
    display: block;
  }
  .app-header {
    height: 62px;
    padding: 0 12px;
  }
  .app-header .eyebrow {
    display: none;
  }
  .candidate {
    font-size: 8px;
  }
  .header-actions button {
    font-size: 10px;
    padding: 7px 9px;
  }
  main {
    padding: 22px 14px;
  }
  .page-heading {
    display: block;
  }
  .page-heading .actions {
    margin-top: 15px;
  }
  h1 {
    font-size: 30px;
  }
  .cards {
    gap: 10px;
  }
  .card {
    padding: 14px;
  }
  .card .metric-value {
    font-size: 20px;
  }
  .filters.global-filters {
    padding: 12px;
    gap: 10px;
  }
  .filters label {
    min-width: 110px;
  }
  .global-filters label:first-child {
    flex-basis: 100%;
  }
  .form-grid,
  .mapping,
  .split {
    grid-template-columns: 1fr;
  }
  .form-grid .wide {
    grid-column: auto;
  }
  #dialog-body {
    padding: 18px;
  }
  .dialog-heading {
    padding: 18px;
  }
  .sidebar-bottom {
    padding-bottom: 25px;
  }
  .availability {
    display: block;
  }
  .availability .pill {
    margin-top: 10px;
  }
  .panel-heading {
    padding: 15px;
  }
  .table-footnote {
    font-size: 10px;
  }
}
.source-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-top: 1px solid var(--line);
}
.source-link {
  display: block;
  margin-top: 5px;
  color: var(--green);
  font-size: 10px;
  text-decoration: none;
}
.source-link:hover {
  text-decoration: underline;
}
.description small {
  display: block;
  margin-top: 5px;
}
.source-pagination button {
  min-width: 82px;
}

.daily-index {
  display: flex;
  gap: 12px;
  align-items: end;
  margin: 16px 0;
  flex-wrap: wrap;
}
.daily-index > input {
  flex: 1;
  min-width: 220px;
}
.daily-index label {
  min-width: 160px;
}
.daily-scroll {
  max-height: 70vh;
  overflow: auto;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.daily-grid {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.daily-grid th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f4f7f3;
}
.expense-entry {
  position: sticky;
  top: 44px;
  background: #fff;
  z-index: 1;
}
.daily-grid td {
  min-width: 120px;
}
.daily-grid input,
.daily-grid select {
  min-width: 120px;
}
.inactive-booking {
  opacity: 0.48;
  filter: grayscale(1);
}
.inactive-booking td {
  background: #f2f2ef;
}
.right-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  max-height: 100dvh;
  height: 100dvh;
  max-width: 100%;
  width: min(480px, 100vw);
  border-radius: 0;
}
.sidebar {
  overflow: clip;
}

.global-filters.daily-scope{background:transparent;border:0;box-shadow:none;padding:0;max-width:220px}

.sample-banner{background:var(--sand);color:#695332;padding:12px 16px;border-radius:8px;font-weight:650}.guest-split{display:grid;grid-template-columns:minmax(0,1fr);background:white;border:1px solid var(--line);border-radius:14px;overflow:hidden}.guest-split.has-selection{grid-template-columns:minmax(0,1fr) 390px}.guest-register{overflow:auto;max-height:73vh}.guest-ledger{width:100%;min-width:1120px;border-collapse:collapse}.guest-ledger th{background:#f7f8f4;position:sticky;top:0;z-index:1}.guest-ledger td{padding:18px 10px;white-space:nowrap;border-top:1px solid var(--line)}.guest-ledger tr{cursor:pointer}.guest-ledger tr.selected{background:#edf5eb;box-shadow:inset 3px 0 var(--green)}.guest-ledger tr:hover{background:#f5f8f3}.guest-ledger select{width:auto;max-width:115px;padding:4px;min-height:28px}.guest-name{font-weight:650}.finance-status{border:0;border-radius:20px;min-height:28px;padding:5px 10px;font-size:11px}.finance-status.paid{background:#dcefd8;color:#20552a}.finance-status.due{background:#fde4e0;color:#a13125}.finance-status.refunded{background:#e5e5e1;color:#666}.guest-detail{padding:24px;border-left:1px solid var(--line);max-height:73vh;overflow:auto}.detail-top{display:flex;justify-content:space-between;align-items:center}.detail-top button{border:0}.guest-detail h2{margin-top:16px}.guest-detail h3{margin-top:26px;color:var(--green);font-size:11px;letter-spacing:.08em}.guest-detail-line{display:flex;justify-content:space-between;gap:15px;padding:9px 0}.guest-detail-line.booked{border-top:1px solid var(--line);margin-top:20px;font-size:14px}.booking-breakdown{padding:0 0 14px 14px;color:var(--muted);font-size:11px;border-bottom:1px solid var(--line)}.extension-notice{padding:12px;background:var(--green-soft);border-radius:8px;line-height:1.6}.payment-history{width:100%;font-size:11px}.payment-history td,.payment-history th{padding:7px 3px}.guest-adjustments .form-grid{grid-template-columns:1fr}.unavailable-room{opacity:.4}@media(max-width:1100px){.guest-split.has-selection{grid-template-columns:minmax(0,1fr) 340px}}@media(max-width:760px){.guest-split.has-selection{grid-template-columns:1fr}.guest-detail{border-left:0;border-top:1px solid var(--line);max-height:none}}
.guest-ledger td.numeric {
  text-align: left;
}
/* Approved reference: persistent wordmark/menu, compact action row, title-case headings. */
.sidebar,.sidebar:hover,.sidebar:has(:focus-visible),.sidebar.open{width:200px;background:#fbfbf9;box-shadow:none}
.main-shell{margin-left:200px}.sidebar .nav-label{opacity:1;font-size:13px;font-weight:650}.sidebar nav{padding:20px 10px;gap:9px}.sidebar nav a{padding:0 13px;gap:15px;border-left:0;min-height:44px;border-radius:8px;color:#14221b}.sidebar nav a.active{background:#dfebdf;color:#164f35}.nav-icon{width:22px;height:22px;display:flex;align-items:center;justify-content:center}.brand{height:162px;flex-direction:column;gap:3px;padding:17px 10px 20px;border-bottom:1px solid #e2e3dc}.brand-symbol{font:italic 700 66px/.75 Georgia,serif;color:#17543b;margin:2px 0 10px}.brand-name{font:700 23px Georgia,serif;letter-spacing:-.6px}.brand-tagline{font-size:8px;letter-spacing:2.2px;font-weight:700;margin-top:4px}.brand-wave{margin-top:8px}.sidebar-bottom{padding:18px 14px;gap:10px}.sidebar-bottom .nav-label{font-size:11px}.ui-icon{flex-shrink:0;vertical-align:middle}
.reference-guest .app-header{position:fixed;bottom:0;left:0;width:199px;height:60px;padding:8px;z-index:21;border-top:1px solid var(--line);background:#fbfbf9}.reference-guest .app-header>div:first-child{display:none}.reference-guest .header-actions{display:flex;width:100%;justify-content:center}.reference-guest .header-actions button{font-size:10px;min-height:30px;padding:5px 7px}.reference-guest .sidebar-bottom{display:none}.reference-guest main{padding:60px 24px 20px;max-width:none;background:#fcfcfa;min-height:100vh}.reference-guest .page-heading{align-items:center;margin:0 0 32px;gap:15px}.reference-guest #page-kicker,.reference-guest #page-description{display:none}.guest-title-row{display:flex;align-items:center;gap:28px}.reference-guest h1{font:700 50px/1.1 Georgia,serif;letter-spacing:-1.6px;margin:0;white-space:nowrap}.reference-month{position:relative;display:flex;align-items:center;gap:12px;border:1px solid #d4d7d2;border-radius:8px;background:white;padding:0 12px;height:46px;color:#17251d}.reference-month select{border:0;background:transparent;min-height:42px;min-width:190px;padding:4px 20px 4px 0;color:#17251d;font-size:15px;font-weight:600;outline-offset:7px}.reference-guest .actions{gap:12px;flex-wrap:nowrap}.reference-guest .actions button{display:inline-flex;align-items:center;justify-content:center;gap:10px;border:1px solid #adb5ad;border-radius:9px;min-height:45px;padding:10px 18px;font-size:14px;font-weight:600;background:#fff;color:#16231a;box-shadow:0 1px 2px #00000004}.reference-guest .actions button.primary{background:#176642;color:white;border-color:#176642}.reference-guest .actions .reference-upload{width:46px;padding:10px}.reference-filter-row{display:flex;align-items:center;gap:24px;margin-bottom:30px}.reference-filter-row>label{display:flex;align-items:center;gap:14px;font-size:15px;font-weight:400;color:#101a14;white-space:nowrap}.reference-filter-row input[type=date]{width:190px;min-height:42px;border-color:#d5d8d2;font-size:14px;background:#fff}.reference-search{display:flex;align-items:center;flex:1;min-width:180px;gap:12px;border:1px solid #d5d8d2;border-radius:8px;padding:0 13px;height:43px;background:white}.reference-search input{border:0;padding:8px 0;min-width:0;background:transparent;font-size:14px;outline-offset:8px}.reference-source{display:flex;gap:9px;align-items:center;background:#e4eee5;color:#22382a;padding:10px 15px;border-radius:8px;white-space:nowrap;font-size:14px}.reference-demo-note{position:absolute;top:16px;left:224px;padding:5px 13px;border-radius:6px;background:#f2e6ca;color:#302e22;letter-spacing:1px;font-size:10px;font-weight:700}.reference-register-label{font-size:11px;font-weight:750;letter-spacing:1px;color:#185736;border-top:1px solid #e0e3dc;padding:17px 0 12px}.reference-guest .guest-split{border:0;border-top:1px solid #e0e3dc;border-radius:0;background:transparent}.reference-guest .guest-register{max-height:72vh}.reference-guest .guest-ledger{min-width:1040px}.reference-guest .guest-ledger th{text-transform:none;letter-spacing:0;font-size:13px;color:#111c14;font-weight:700;background:#fcfcfa;padding:15px 9px;height:62px}.reference-guest .guest-ledger td{font-size:12px;padding:20px 9px;border-color:#e2e5df}.reference-guest .guest-ledger td:first-child{font-weight:650;color:#155f3b}.reference-guest .guest-ledger th select{font-size:11px;min-height:24px;border:0;background:transparent;border-radius:4px;padding:2px;width:auto;max-width:100px}.column-sort{display:flex;align-items:center;gap:3px}.column-sort select{max-width:118px!important}.money-heading{display:flex;flex-direction:column;align-items:flex-start;gap:4px;line-height:1.3}.money-heading small{font-size:12px;font-weight:400}.reference-guest .guest-detail{padding:17px 20px 25px;border-left:1px solid #d9ddd5;background:transparent}.reference-guest .guest-detail h2{font-weight:700;font-size:30px;margin:12px 0}.reference-guest .guest-detail-line{font-size:13px}.reference-guest .guest-detail .detail-top .eyebrow{font-size:11px}.reference-guest .finance-status{min-height:25px;font-size:11px;padding:4px 10px}.reference-footnote{margin-top:22px;font:italic 12px Georgia,serif;color:#71756c}.reference-guest .guest-ledger td.numeric{text-align:left}
@media(min-width:761px) and (max-width:1350px){.reference-guest .page-heading{flex-wrap:wrap}.reference-guest .actions{margin-left:auto}.reference-filter-row{gap:12px;flex-wrap:wrap}.reference-filter-row input[type=date]{width:160px}.guest-title-row{gap:18px}.reference-guest h1{font-size:43px}}
@media(max-width:760px){.sidebar,.sidebar:hover,.sidebar.open{width:200px;transform:translateX(-100%)}.sidebar.open{transform:translateX(0)}.main-shell{margin-left:0}.reference-guest main{padding:80px 14px 20px}.reference-guest .app-header{top:0;bottom:auto;left:0;width:100%;height:52px;justify-content:space-between}.reference-guest .app-header>div:first-child{display:flex}.reference-guest .app-header .header-actions{width:auto}.reference-guest #mobile-nav{display:block}.reference-demo-note{top:58px;left:14px;font-size:8px}.guest-title-row{flex-wrap:wrap;gap:14px}.reference-guest h1{font-size:37px}.reference-guest .page-heading{display:flex;flex-wrap:wrap;margin-bottom:18px}.reference-guest .actions{flex-wrap:wrap;gap:7px;margin-top:6px}.reference-guest .actions button{font-size:12px;padding:8px 10px;min-height:40px}.reference-filter-row{gap:12px;flex-wrap:wrap}.reference-filter-row>label{font-size:12px;gap:8px}.reference-filter-row input[type=date]{width:137px}.reference-search{flex-basis:100%}.reference-source{font-size:12px}.reference-guest .guest-split.has-selection{grid-template-columns:1fr}.reference-guest .guest-detail{border-left:0;border-top:1px solid #d9ddd5}.reference-guest .sidebar-bottom{display:none}}

.reference-guest .guest-ledger th select.compact-sort{font-size:0!important;width:22px;max-width:22px;min-width:22px;padding:0}.reference-guest .guest-ledger th select.compact-sort option{font-size:12px}
@media(max-width:760px){#mobile-nav{display:block}}

/* Compact navigation expands over the workspace; guest details use the full viewport. */
.sidebar .header-actions{margin-top:auto;padding:16px 10px;min-width:198px;opacity:0;pointer-events:none;justify-content:center;gap:6px}
.sidebar .header-actions button{font-size:11px;padding:7px}
.brand-logo{display:block;width:176px;height:142px;object-fit:contain;max-width:none}
.reference-guest .guest-split.has-selection{grid-template-columns:minmax(0,1fr)}
.reference-guest .guest-detail{position:fixed;inset:0 0 0 auto;width:min(440px,100vw);height:100dvh;max-height:100dvh;overflow-y:auto;overscroll-behavior:contain;z-index:50;background:#fcfcfa;border-left:1px solid #d9ddd5;border-top:0;box-shadow:-12px 0 40px #14221b18;padding:24px;box-sizing:border-box}
.reference-guest .guest-detail[hidden]{display:none}
.reference-guest .guest-detail .detail-top{position:sticky;top:-24px;background:#fcfcfa;z-index:2;padding:12px 0}
@media(min-width:761px){
.sidebar{width:74px;transition:width .18s ease;overflow:clip}
.sidebar:hover,.sidebar:has(:focus-visible),.sidebar.open{width:200px}
.main-shell{margin-left:74px}
.sidebar .nav-label{opacity:0;transition:opacity .15s ease;white-space:nowrap}
.sidebar:hover .nav-label,.sidebar:has(:focus-visible) .nav-label,.sidebar.open .nav-label{opacity:1}
.brand{width:200px;align-items:flex-start;padding-left:12px}
.brand-logo{width:50px;transition:width .18s ease}
.sidebar:hover .brand-logo,.sidebar:has(:focus-visible) .brand-logo,.sidebar.open .brand-logo{width:176px}
.sidebar:hover .header-actions,.sidebar:has(:focus-visible) .header-actions,.sidebar.open .header-actions{opacity:1;pointer-events:auto}
.reference-guest .app-header{display:none}
.reference-demo-note{left:98px}
}
@media(max-width:760px){.sidebar .header-actions{opacity:1;pointer-events:auto}.brand{height:162px}.brand-logo{width:176px}.reference-guest .guest-detail{border-left:1px solid #d9ddd5}}

.guest-detail-backdrop{position:fixed;inset:0;width:100%;height:100dvh;z-index:49;border:0;border-radius:0;background:transparent;padding:0;cursor:default}
.guest-detail-backdrop:hover{background:transparent}
.guest-detail-backdrop[hidden]{display:none}
.booked-details{border-top:1px solid var(--line);margin-top:20px}
.booked-details summary{display:flex;align-items:center;gap:10px;cursor:pointer;list-style:none}
.booked-details summary::-webkit-details-marker{display:none}
.booked-details summary::before{content:"›";font-size:22px;color:var(--green);transition:transform .15s ease}
.booked-details[open] summary::before{transform:rotate(90deg)}
.booked-details summary .guest-detail-line.booked{flex:1;border:0;margin:0}
.booked-details summary:focus-visible{outline:2px solid var(--green);outline-offset:4px}

.booked-details summary::before{content:none}
.booked-details summary::after{content:"›";font-size:22px;color:var(--green);transition:transform .15s ease}
.booked-details[open] summary::after{transform:rotate(90deg)}
.guest-detail-line.refund-reported strong{color:#b3261e}
.balance-payment-entry{padding:12px 0;border-bottom:1px solid var(--line);display:grid;gap:8px}
.booked-details summary::after{content:none}
.booked-details summary .guest-detail-line>span{display:inline-flex;align-items:center;gap:10px}
.booked-details summary .guest-detail-line>span::after{content:"›";font-size:22px;color:var(--green);transition:transform .15s ease}
.booked-details[open] summary .guest-detail-line>span::after{transform:rotate(90deg)}

.reference-guest .guest-detail{width:min(520px,100vw)}

.sidebar-footer{margin-top:auto;padding:12px 10px;border-top:1px solid var(--line);width:200px}
.sidebar-footer-row{display:flex;align-items:center;gap:14px;min-height:42px;margin:0;padding:9px 13px;width:178px;border:0;background:transparent;color:var(--ink);font-size:13px;cursor:pointer;text-align:left}
.footer-icon{width:22px;flex-shrink:0;text-align:center;font-size:20px}
.sidebar-footer-row input{width:30px;min-height:18px;margin-left:auto;accent-color:var(--green)}
.connected-user{display:grid;gap:8px;padding:12px;font-size:11px;overflow-wrap:anywhere}
.sidebar-user summary{list-style:none}.sidebar-user summary::-webkit-details-marker{display:none}
.sidebar-user:not([open]) .connected-user{display:none}
.name-sort-menu{position:relative;display:inline-block}
.name-sort-menu summary{cursor:pointer;list-style:none;display:flex;align-items:center;justify-content:center;width:25px;height:25px;font-size:20px;border-radius:5px}
.name-sort-menu summary::-webkit-details-marker{display:none}
.name-sort-options{position:absolute;top:28px;left:0;z-index:5;min-width:155px;padding:6px;background:var(--surface);border:1px solid var(--line);border-radius:8px;box-shadow:0 5px 18px #0002;display:grid;gap:3px}
.name-sort-options button{text-align:left;border:0;background:transparent;min-height:32px;padding:6px 10px;color:var(--ink)}
.name-sort-options button:hover{background:var(--green-soft)}
.night-mode{color-scheme:dark;--ink:#eff5ff;--muted:#b9cbe0;--paper:#09172e;--surface:#142a46;--line:#344b68;--green:#8bd5aa;--green-dark:#9fe5bc;--green-soft:#203956;--sand:#3e3829;--amber:#efbb6b;--red:#ff9e96}
.night-mode body,.night-mode .reference-guest main,.night-mode .reference-guest .guest-detail,.night-mode .guest-detail .detail-top{background:#09172e;color:var(--ink)}
.night-mode .sidebar,.night-mode .sidebar:hover,.night-mode .sidebar.open,.night-mode .app-header,.night-mode .reference-month,.night-mode .reference-search,.night-mode .card,.night-mode .panel,.night-mode dialog,.night-mode .guest-split,.night-mode input,.night-mode select,.night-mode textarea{background:var(--surface);color:var(--ink);border-color:var(--line)}
.night-mode .sidebar nav a,.night-mode .reference-month select,.night-mode .reference-filter-row>label,.night-mode .reference-guest .guest-ledger th,.night-mode .reference-guest .guest-ledger td:first-child{color:var(--ink)}
.night-mode .sidebar nav a.active,.night-mode .reference-source,.night-mode .guest-ledger tr.selected,.night-mode .guest-ledger tr:hover{background:var(--green-soft);color:var(--ink)}
.night-mode .reference-guest .guest-ledger th,.night-mode .payment-history th{background:#09172e}
.night-mode .reference-guest .actions button{background:var(--surface);color:var(--ink);border-color:var(--line)}
.night-mode .reference-guest .actions button.primary{background:#206944;color:#fff}
.night-mode .brand-logo{filter:invert(1)}
.night-mode .guest-detail-line.refund-reported strong{color:#ff9e96}
@media(min-width:761px){.sidebar:not(:hover):not(:has(:focus-visible)):not(.open) #night-mode,.sidebar:not(:hover):not(:has(:focus-visible)):not(.open) .connected-user{visibility:hidden}}

.night-mode .reference-filter-row input[type=date]{background:var(--surface);color:var(--ink);border-color:var(--line)}
.night-mode .reference-guest .guest-ledger td{border-color:var(--line)}
.night-mode .inactive-booking{background:#102039}
.sidebar-footer-row input[role=switch]{appearance:none;border:0;border-radius:12px;background:#9ba69e;height:18px;min-height:18px;width:30px;padding:2px;cursor:pointer;flex-shrink:0}
.sidebar-footer-row input[role=switch]::before{content:"";display:block;width:14px;height:14px;border-radius:50%;background:#fff;transition:transform .15s}
.sidebar-footer-row input[role=switch]:checked{background:#28754e}
.sidebar-footer-row input[role=switch]:checked::before{transform:translateX(12px)}
.sidebar-footer{width:100%}
.sidebar-footer-row{width:100%}

.guest-save-actions{display:flex;align-items:center;gap:10px;margin-top:14px}
.guest-save-actions button{display:inline-flex;align-items:center;gap:7px}
.guest-edit-event{border-top:1px solid var(--line);padding:14px 0}
.guest-edit-event td{white-space:pre-wrap;overflow-wrap:anywhere;vertical-align:top;font-size:12px}
.guest-edit-event th{white-space:normal}

.payment-paid,.guest-detail-line.payment-paid strong{color:#1b7a45}
.payment-due,.guest-detail-line.payment-due strong{color:#bd6b09}
.night-mode .payment-paid,.night-mode .guest-detail-line.payment-paid strong{color:#8bd5aa}
.night-mode .payment-due,.night-mode .guest-detail-line.payment-due strong{color:#efbb6b}
.payment-history .refund-reported{color:var(--red)}
.guest-form-section{display:grid;gap:12px;border-top:1px solid var(--line);padding-top:12px;margin-top:12px}
.guest-form-section h3{margin:4px 0!important}
.guest-form-section[hidden]{display:none}
.remove-payment{border:0;min-height:24px;padding:2px 6px;font-size:18px;color:var(--red);background:transparent}

.workspace-calendar{position:fixed;inset:auto;margin:0;width:284px;max-height:calc(100dvh - 16px);overflow:auto;overscroll-behavior:contain;padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--ink);box-shadow:0 10px 40px #0003}
.workspace-calendar:not(:popover-open){display:none}
.calendar-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.calendar-heading button{min-height:30px;padding:3px 10px;font-size:20px}
.calendar-days{display:grid;grid-template-columns:repeat(7,1fr);gap:3px}
.calendar-days span{font-size:10px;text-align:center;padding:6px 0;color:var(--muted)}
.calendar-days button{min-height:30px;padding:4px 0;border:0;border-radius:5px;background:transparent;color:var(--ink);font-size:12px}
.calendar-days button:hover,.calendar-days button.selected{background:var(--green-soft);color:var(--green)}
.calendar-days button.other-month{opacity:.4}.calendar-days button:disabled{opacity:.2;cursor:default}
.guest-form-section{display:block}
.guest-form-section>summary{cursor:pointer;font-size:11px;font-weight:750;letter-spacing:.07em;color:var(--green);padding:8px 0;list-style:disclosure-closed}
.guest-form-section[open]>summary{list-style:disclosure-open;margin-bottom:10px}
.guest-form-section>label,.guest-form-section>.balance-payment-entry{margin:12px 0}
.upsales-entry{display:grid;grid-template-columns:repeat(4,minmax(140px,1fr));gap:12px;align-items:end;border-bottom:1px solid var(--line);padding-bottom:20px}
.upsales-entry input,.upsales-entry select{width:100%}.upsales-grid td{white-space:nowrap}
@media(max-width:760px){.upsales-entry{grid-template-columns:1fr 1fr}}

.sidebar nav{min-height:0;overflow-y:auto;flex:1;align-content:start}

/* Shared white review workspace, following the approved Guest Finance reference. */
:root:not(.night-mode) { --paper:#fff; --surface:#fff; --ink:#17231c; --muted:#646b67; --line:#dce0dc; }
body, #app main, #app.reference-guest main { background:var(--paper); }
#app main { max-width:none; min-height:100dvh; padding:26px clamp(16px,2.3vw,38px); }
#app .page-heading { gap:16px; margin-bottom:18px; align-items:center; flex-wrap:wrap; }
#app .page-heading h1 { margin:0; font:700 clamp(32px,3.1vw,48px)/1.12 Georgia,serif; letter-spacing:-.035em; color:var(--ink); }
#app .page-heading .actions { margin-left:auto; flex-wrap:wrap; }
#app .page-heading .actions:empty { display:none; }
#app .guest-title-row { flex-wrap:wrap; gap:18px; }
#app #page-kicker, #app #page-description { display:none; }
#app .sidebar { background:var(--surface); }
#register-tools { display:grid; gap:4px; }
#app .reference-demo-note { position:static; display:inline-block; margin:0 0 8px; }
@media(min-width:761px) { #app .app-header { display:none; } }
@media(max-width:760px), (hover:none) and (pointer:coarse) {
  #app .app-header { display:flex; position:sticky; top:0; left:0; width:100%; height:45px; z-index:10; background:var(--surface); }
  #app .app-header>div:first-child { display:flex; }
  #app main { padding:16px 12px; }
  #app .page-heading { gap:10px; }
  #app .sidebar.open { z-index:30; }
}
.finance-wave {
  width:36px; height:16px; flex:none; background:var(--green-dark);
  mask:url("/assets/finance-wave.png") center/contain no-repeat;
}

#app:is([data-page="pl"],[data-page="kpi"]) #page-description { display:block; margin-top:6px; font-size:12px; }
#app[data-page="kpi"] .page-heading h1 { font-family:Inter,ui-sans-serif,system-ui,sans-serif; font-weight:650; }

/* Sizes and hover treatment from the COO unified workspace rail. */
#app .sidebar { --rail-bg:#ffe0e3; --rail-open:#ffe0e3; --rail-ink:#202124; --rail-line:#dedfe2; --rail-selected:#fdbec4; --rail-accent:#303135; color:var(--rail-ink); border-right:1px solid var(--rail-line); background:var(--rail-bg); backdrop-filter:none; }
.night-mode #app .sidebar { --rail-bg:#10233e; --rail-open:#10233e; --rail-ink:#eff5ff; --rail-line:#344b68; --rail-selected:#294566; --rail-accent:#accdf7; }
#app .sidebar .brand {position:relative;flex:0 0 88px;width:100%;height:88px;border:0;padding:0;overflow:hidden;}
#app .sidebar .brand-logo {position:absolute;width:64px;height:64px;left:4px;top:9px;object-fit:contain;transition:none;}
#app .sidebar:is(:hover,:has(:focus-visible),.open) .brand-logo {width:108px;height:108px;left:16px;top:-15px;}
#app .sidebar nav {gap:3px;padding:6px 12px;align-content:start;}
#app .sidebar nav a,#app .sidebar-footer-row {color:inherit;border:0;border-radius:6px;gap:16px;min-height:38px;padding:8px 12px;}
#app .sidebar nav a:hover,#app .sidebar-footer-row:hover {background:#80808012;}
#app .sidebar nav a.active {background:var(--rail-selected);color:var(--rail-accent);}
#app .sidebar .nav-label {font-size:13px;letter-spacing:.65px;font-weight:600;}
#app .sidebar-footer {margin:20px 12px 14px;padding:10px 0 0;width:calc(100% - 24px);border-color:var(--rail-line);}
@media(min-width:761px) {
  #app .sidebar {width:72px;transition:width .2s ease,background-color .2s ease,box-shadow .2s ease;}
  #app .main-shell {margin-left:72px;}
  #app .sidebar:is(:hover,:has(:focus-visible),.open) {width:224px;background:var(--rail-open);box-shadow:none;}
  #app .sidebar:not(:hover):not(:has(:focus-visible)):not(.open) nav a {width:48px;}
}
#close-navigation {display:none;color:inherit;}
@media(max-width:760px), (hover:none) and (pointer:coarse) {
  #app .main-shell {margin-left:0;}
  #app .sidebar {display:none;}
  #app .sidebar.open {
    display:flex;
    width:min(272px, calc(100vw - 48px));
    height:100dvh;
    transform:none;
    background:var(--rail-open);
  }
  #app .sidebar nav a, #app .sidebar-footer-row {min-height:44px;}
  #app .app-header {
    height:48px;
    padding:0 12px 0 6px;
    border-top:0;
    justify-content:space-between;
  }
  #app .app-header > div {gap:4px;}
  .mobile-logo {object-fit:cover;}
  .night-mode .mobile-logo {filter:invert(1);}
  #mobile-nav, #close-navigation {
    display:grid;
    place-items:center;
    width:44px;
    height:44px;
    background:transparent;
  }
  #close-navigation {position:absolute;right:8px;top:10px;}
  #nav-scrim {position:fixed;inset:0;background:#101d244a;z-index:29;}
  body:has(.sidebar.open) {overflow:hidden;}
  #app main {min-height:calc(100dvh - 48px);}
  .login-shell {padding:16px;min-height:100dvh;}
  .login-card {padding:clamp(20px, 6vw, 32px);min-width:0;}
  .login-card input, #dialog-body :is(input, select, textarea) {font-size:16px;}
  #dialog-body :is(label,input,select,textarea) {min-width:0;}
  .form-actions {flex-wrap:wrap;}
  .dialog-heading {gap:12px;padding:12px 16px;}
  .dialog-heading h2 {font-size:23px;}
  #dialog-body {padding:16px;}
}
@media(pointer:coarse) {
  .workspace-calendar {width:min(336px, calc(100vw - 16px));}
  .calendar-days button, .calendar-heading button {min-height:40px;}
}
#close-dialog {flex:0 0 44px;height:44px;}
.dialog-heading {position:sticky;top:0;background:var(--surface);z-index:3;}
body:has(#dialog[open]) {overflow:hidden;}
.night-mode .login-card, .night-mode .global-filters {background:var(--surface);}
.night-mode .login-shell {background:var(--paper);}
.night-mode .candidate {color:#f1d9b0;}
.night-mode {--amber-soft:#3a3020;--red-soft:#442930;}
.night-mode :is(.file-zone,.history pre,.pill:not(.verified,.reconciled,.estimated,.unverified)) {background:var(--green-soft);}
.night-mode th {background:var(--surface);}
.night-mode :is(th,td) {border-bottom-color:var(--line);}
.night-mode :is(input,textarea)::placeholder {color:var(--muted);opacity:1;}
.night-mode button.primary {background:#216644;color:white;border-color:#3d815e;}
@media(max-height:640px) {
  #app .sidebar {overflow-y:auto;}
  #app .sidebar nav {flex:none;overflow:visible;}
}

#app:is([data-page="expenses"],[data-page="income"],[data-page="cashflow"]) .reg-scroll thead th,
#app.reference-guest .guest-ledger thead th { background:#dce7f0; color:#1b3449; }
.night-mode #app:is([data-page="expenses"],[data-page="income"],[data-page="cashflow"]) .reg-scroll thead th,
.night-mode #app.reference-guest .guest-ledger thead th { background:#294566; color:#eff5ff; }

.income-evidence img, .income-evidence iframe { display: block; width: 100%; margin: 8px 0; border: 0; }
.income-evidence img { max-height: 55vh; object-fit: contain; object-position: left center; }
.income-evidence iframe { height: 55vh; }

@media (min-width:761px) {
  #app .main-shell {min-width:0}
  #app .sidebar:is(:hover,:has(:focus-visible),.open) ~ .main-shell {margin-left:224px}
}

.record-confirm {width:min(375px,90vw);height:auto;padding:22px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--ink)}
.record-confirm p {margin:0 0 18px}
.record-confirm .delete-word {color:var(--red,#b42318)}

dialog.record-confirm[open] {position:fixed;inset:0;margin:auto;width:min(390px,calc(100vw - 32px));min-height:0;height:fit-content;max-height:calc(100dvh - 32px);max-width:none;padding:20px 22px;box-sizing:border-box}
dialog.record-confirm .form-actions {margin-top:14px}
dialog.party-selection h3 {margin:0 0 14px}
.party-selection .worktree-payee {display:grid;grid-template-columns:minmax(0,1fr)}
.party-selection .reg-payee-options {position:static;grid-column:1/-1;width:100%;min-width:0;max-width:none;max-height:min(32vh,240px);margin-top:6px;box-shadow:none}
