:root {
  --bk-bg: #f4f6f9;
  --bk-surface: #ffffff;
  --bk-text: #1f2933;
  --bk-muted: #616e7c;
  --bk-sandbox: #ffb020;
  --bk-sandbox-text: #3d2a00;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bk-bg: #12161c;
    --bk-surface: #1c222b;
    --bk-text: #e4e7eb;
    --bk-muted: #9aa5b1;
  }
}

body {
  background: var(--bk-bg);
  color: var(--bk-text);
}

.card {
  background: var(--bk-surface);
  color: var(--bk-text);
}

.text-muted-bk {
  color: var(--bk-muted);
}

.sandbox-banner {
  background: var(--bk-sandbox);
  color: var(--bk-sandbox-text);
}

#toastWrap {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 1080;
  max-width: calc(100vw - 2rem);
}

.secret-box {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  word-break: break-all;
  user-select: all;
}

.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

/* ---- room calendar ---- */
:root {
  --cal-confirmed: #2f9e44;
  --cal-pending: #f0b429;
  --cal-hold: #74c0fc;
  --cal-closure: #868e96;
  --cal-today: #fff3bf;
  --cal-weekend: #f1f3f5;
  --cal-label: #1f2933;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --cal-today: #3d3500;
    --cal-weekend: #20262e;
  }
}
.cal-wrap { max-height: 75vh; }
.cal-table { table-layout: fixed; min-width: 100%; }
.cal-table th, .cal-table td { white-space: nowrap; }
.cal-table .cal-room { position: sticky; left: 0; z-index: 2; background: var(--bk-surface); width: 7.5rem; min-width: 7.5rem; }
.cal-day { width: 3.25rem; min-width: 3.25rem; text-align: center; font-weight: 500; font-size: .75rem; line-height: 1.15; }
.cal-table .cal-today { background: var(--cal-today) !important; }
.cal-table .cal-weekend { background: var(--cal-weekend); }
.cal-group th { background: var(--bk-bg); font-size: .8rem; position: sticky; left: 0; }
.cal-cell { height: 2.25rem; padding: 0 .25rem !important; overflow: hidden; vertical-align: middle; font-size: .75rem; }
.cal-label { display: block; overflow: hidden; text-overflow: ellipsis; color: var(--cal-label); font-weight: 600; }
.cal-table .cal-confirmed { background: var(--cal-confirmed); cursor: pointer; }
.cal-table .cal-confirmed .cal-label { color: #fff; }
.cal-table .cal-pending { background: var(--cal-pending); cursor: pointer; }
.cal-table .cal-hold { background: repeating-linear-gradient(45deg, var(--cal-hold), var(--cal-hold) 6px, #a5d8ff 6px, #a5d8ff 12px); }
.cal-table .cal-closure { background: var(--cal-closure); }
.cal-table .cal-closure .cal-label { color: #fff; }
.cal-table .cal-clickable { cursor: pointer; }
.cal-table .cal-clickable:hover, .cal-clickable:focus { background: rgba(0, 0, 0, .06); outline: none; }
.cal-key { display: inline-block; width: .9rem; height: .9rem; border-radius: .2rem; vertical-align: -2px; margin-right: .3rem; }
.cal-key.cal-hold { background: var(--cal-hold); }
.cal-key.cal-confirmed { background: var(--cal-confirmed); }
.cal-key.cal-pending { background: var(--cal-pending); }
.cal-key.cal-closure { background: var(--cal-closure); }

.prop-list { max-height: 60vh; overflow-y: auto; }
@media (max-width: 991.98px) { .prop-list { max-height: 30vh; } }

/* Boat manifest: print only the passenger list */
@media print {
  #appShell, #toastWrap, .no-print, .sandbox-banner { display: none !important; }
  body { background: #fff; color: #000; }
  .card { box-shadow: none !important; border: 0; }
  #page { padding: 0 !important; }
}
