@font-face { font-family: "DM Sans"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/dm-sans.woff2") format("woff2"); }
@font-face { font-family: "Libre Baskerville"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/libre-baskerville.woff2") format("woff2"); }

:root {
  --ink: #0a0a0a;
  --ink-2: #3a3a38;
  --muted: #5e5e5a;
  --hairline: #cfcfcb;
  --soft: #e4e4e0;
  --sunken: #f5f5f2;
  --weekend: #fafaf8;
  --steel: #2c4a5e;
  --steel-soft: #dce6ed;
  --night: #1d2632;
  --on-night: #f5f3ef;
  --last: #f7eed3;
  --full: #c4c7ca;
  --photo: #eceef0;
  --metal: #4a5058;
  --held: #8c5a2b;
  --lodge-w: 200px;
  --room-w: 220px;
  --qty-w: 56px;
}

* { box-sizing: border-box; }
body { margin: 0; background: #fff; color: var(--ink); font: 15px/1.45 "DM Sans", "Helvetica Neue", Arial, sans-serif; }
.wrap { max-width: 1440px; margin: 0 auto; }
a:focus-visible, button:focus-visible, input:focus-visible, .room:focus-visible { outline: 3px solid #7fa3ba; outline-offset: -3px; }

/* The bar for a signed-in person */
.userbar { padding: 8px 48px; background: var(--night); color: var(--on-night); font-size: 14px; line-height: 20px; }
.userbar .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; min-height: 36px; }
.userbar .wrap > span { flex: 1; min-width: 0; }
.userbar.editing .wrap > span { min-width: 240px; }
.userbar strong { font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; font-size: 12px; }
.userbar a { color: var(--on-night); text-decoration: none; padding: 6px 10px; border-radius: 4px; }
.userbar a:hover { background: rgba(245, 243, 239, 0.12); }
.userbar a.bar-main { background: var(--on-night); color: var(--night); font-weight: 600; padding: 6px 16px; }
.bar-clients { display: flex; flex-wrap: wrap; gap: 4px; }
.bar-clients a[aria-current] { background: rgba(245, 243, 239, 0.18); font-weight: 600; }
.userbar form { display: flex; align-items: center; gap: 12px; }
.bar-me { opacity: 0.75; }
.userbar button { height: 32px; padding: 0 12px; border: 1px solid rgba(245, 243, 239, 0.5); border-radius: 4px; background: none; color: var(--on-night); font: inherit; font-size: 13px; cursor: pointer; }
/* While the page fetches current numbers after opening with the last known ones */
.updated.checking span { opacity: 0.6; }

/* Top: the collection, the page name, and who offers it */
.top { padding: 24px 48px; border-bottom: 1px solid var(--hairline); }
.top .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; }
.collection { width: 300px; max-width: 100%; height: auto; display: block; }
.collection-name { margin: 0; font: 400 22px/30px "Libre Baskerville", Georgia, serif; }
h1 { margin: 0; font: 400 22px/30px "Libre Baskerville", Georgia, serif; }
.offered { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; line-height: 16px; color: var(--muted); }
.offered img { width: 200px; height: auto; display: block; }

/* Dates and period */
.controls { padding: 20px 48px; border-bottom: 1px solid var(--soft); }
.controls .wrap { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 40px; }
.controls form { display: flex; flex-direction: column; gap: 6px; }
.controls label { font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.pick { display: flex; gap: 8px; }
.controls input[type="date"] { height: 44px; min-width: 150px; border: 1px solid var(--hairline); border-radius: 6px; padding: 0 12px; font: inherit; color: var(--ink); background: #fff; }
.controls button { height: 44px; padding: 0 16px; border: 0; border-radius: 2px; background: var(--night); color: var(--on-night); font: inherit; font-size: 12px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; cursor: pointer; }
.controls button.quiet { display: none; }
.range { display: flex; align-items: center; gap: 8px; }
.range span { min-width: 250px; text-align: center; font-weight: 500; }
.arrow { width: 44px; height: 44px; flex: none; display: flex; align-items: center; justify-content: center; border: 1px solid var(--hairline); border-radius: 2px; background: #fff; color: var(--ink); }
.arrow.off { opacity: 0.35; pointer-events: none; }
.views { display: flex; border: 1px solid var(--hairline); border-radius: 2px; overflow: hidden; }
.views a { height: 42px; padding: 0 16px; display: flex; align-items: center; font-size: 12px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; text-decoration: none; color: var(--ink); background: #fff; }
.views a.on { background: var(--night); color: var(--on-night); }
.updated { display: flex; align-items: center; gap: 8px; height: 44px; font-size: 11px; line-height: 14px; color: var(--muted); }
.updated span, .updated a { display: inline-flex; align-items: center; gap: 5px; }
.updated a { height: 24px; padding: 0 8px; border: 1px solid var(--soft); border-radius: 2px; color: var(--muted); text-decoration: none; font-size: 10px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; }

main { padding: 24px 48px 48px; }
main .wrap { display: flex; flex-direction: column; gap: 16px; }
.banner { margin: 0; padding: 10px 14px; border-radius: 6px; background: var(--steel-soft); font-size: 14px; line-height: 20px; }

/* The grid */
/* The grid scrolls inside its own box, so the dates stay in view while scrolling down */
.scroll { overflow: auto; max-height: calc(100vh - 16px); border: 1px solid var(--soft); border-radius: 12px; background: #fff; }
table { border-collapse: separate; border-spacing: 0; width: 100%; min-width: max-content; }
th, td { padding: 0; font-weight: 400; }

thead th { position: sticky; top: 0; z-index: 6; height: 56px; background: #fff; border-bottom: 2px solid var(--ink); font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); text-align: left; padding: 0 16px; }
thead .lodge-cell, thead .room, thead .qty { z-index: 9; }
thead .qty { text-align: center; padding: 0; }
thead th.day { min-width: 60px; padding: 0; text-align: center; font-size: 13px; font-weight: 400; letter-spacing: 0; text-transform: none; color: var(--ink); }
th.day span { display: block; font-size: 12px; font-weight: 600; }
th.day.weekend { background: var(--weekend); }
th.day.today { color: var(--held); }

.lodge-cell { position: sticky; left: 0; z-index: 5; width: var(--lodge-w); min-width: var(--lodge-w); max-width: var(--lodge-w); background: #fff; border-right: 1px solid var(--soft); }
.room { position: sticky; left: var(--lodge-w); z-index: 4; width: var(--room-w); min-width: var(--room-w); max-width: var(--room-w); background: #fff; text-align: left; }
.qty { position: sticky; left: calc(var(--lodge-w) + var(--room-w)); z-index: 4; width: var(--qty-w); min-width: var(--qty-w); background: #fff; border-right: 1px solid var(--hairline); text-align: center; font-size: 14px; font-weight: 600; }

/* One lodge: a band in the lodge's own colour with its logo, then its picture beside its room types */
.lodge + .lodge .band th { border-top: 16px solid var(--sunken); }
.client-head th { height: 52px; padding: 0; background: var(--night); color: var(--on-night); text-align: left; }
.client-head span { position: sticky; left: 0; display: inline-block; padding: 0 16px; font: 400 18px/52px "Libre Baskerville", Georgia, serif; }
.lodge + .client-head th { border-top: 16px solid var(--sunken); }
.band th { height: 68px; background: var(--lodge); border-bottom: 1px solid color-mix(in srgb, var(--lodge) 70%, #000); text-align: left; }
.band-name { position: sticky; left: 0; display: inline-flex; align-items: center; gap: 14px; padding: 0 16px; }
.band-logo { height: 44px; display: inline-flex; align-items: center; padding: 6px 14px; border-radius: 8px; background: #fff; }
.band-logo img { display: block; height: 100%; width: auto; max-width: 190px; object-fit: contain; }
.band-text { font-size: 17px; font-weight: 600; }
.band-name small { font-size: 13px; color: var(--ink-2); }
.band.dark .band-text, .band.dark .band-name small { color: #fff; }

tbody .lodge-cell { vertical-align: top; height: 144px; }
.lodge-box { position: absolute; inset: 0; display: flex; flex-direction: column; }
.lodge-photo { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; background: var(--photo); color: var(--metal); }
.lodge-photo img { width: 100%; height: 100%; object-fit: cover; }

tbody .room, tbody .qty, tbody td { height: 44px; border-bottom: 1px solid var(--soft); }
tbody .room { font-size: 14px; cursor: default; }
tbody .room:hover, tbody .room:focus, tbody .room:focus-within { z-index: 30; background: var(--sunken); }
.room-in { display: flex; align-items: center; gap: 8px; padding: 0 16px; color: var(--muted); }
.room-in svg { flex: none; }
.room-in span { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* The card with the room's picture */
.pop { display: none; position: absolute; left: calc(var(--room-w) + var(--qty-w) + 8px); top: 0; width: 300px; padding: 8px 8px 12px; background: #fff; border: 1px solid var(--soft); border-radius: 12px; box-shadow: 0 1px 2px rgba(10, 10, 10, 0.06), 0 8px 24px rgba(10, 10, 10, 0.1); }
.room.up .pop { top: auto; bottom: 0; }
.room:hover .pop, .room:focus .pop, .room:focus-within .pop { display: block; }
.pop-photo { height: 176px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 12px; border: 1px solid var(--soft); border-radius: 12px; background: var(--photo); color: var(--metal); text-align: center; font-size: 12px; line-height: 16px; overflow: hidden; }
.pop-photo.has { padding: 0; }
.pop-photo img { width: 100%; height: 100%; object-fit: cover; }
.pop strong { display: block; padding: 10px 2px 0; font-size: 15px; font-weight: 600; }
.pop small { display: block; padding: 2px 2px 0; font-size: 13px; color: var(--muted); }

tbody td { min-width: 60px; text-align: center; font-size: 14px; line-height: 16px; font-variant-numeric: tabular-nums; background: #fff; }
tbody td small { display: block; font-size: 11px; line-height: 12px; font-weight: 600; color: var(--held); }
td.weekend { background: var(--weekend); }
td.last { background: var(--last); }
td.full { background: var(--full); }
td.unknown { color: var(--muted); }
tbody td.note { text-align: left; color: var(--muted); padding: 14px 16px; }

.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 0; padding: 0; list-style: none; font-size: 13px; color: var(--ink-2); }
.legend li { display: inline-flex; align-items: center; gap: 8px; }
.key { width: 36px; height: 26px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--soft); background: #fff; color: var(--ink); }
.key.last { background: var(--last); border-color: var(--last); font-weight: 500; }
.key.full { background: var(--full); border-color: var(--full); }
.key.held { width: auto; padding: 0 8px; color: var(--held); font-size: 11px; font-weight: 600; }
.legend .hint { gap: 6px; color: var(--muted); }

footer { border-top: 1px solid var(--hairline); padding-top: 16px; font-size: 12px; line-height: 16px; color: var(--muted); }

@media (max-width: 1100px) {
  .top, .controls, .userbar { padding-left: 24px; padding-right: 24px; }
  main { padding: 20px 24px 40px; }
}

/* Phones: the lodge's logo column goes, so the dates keep most of the screen */
@media (max-width: 760px) {
  :root { --lodge-w: 0px; --room-w: 148px; }
  .top, .controls { padding: 16px; }
  .userbar { padding: 8px 16px; }
  .bar-me { display: none; }
  .scroll { max-height: none; }
  thead th { position: static; }
  .band th { height: 56px; }
  .band-logo { height: 36px; padding: 5px 10px; }
  main { padding: 16px 16px 32px; }
  .top .wrap { justify-content: center; text-align: center; }
  .collection { width: 240px; }
  h1 { width: 100%; font-size: 20px; }
  .offered img { width: 160px; }
  .controls .wrap { gap: 14px 16px; }
  .range { width: 100%; }
  .range span { flex: 1; min-width: 0; font-size: 14px; }
  .lodge-cell { display: none; }
  .qty, thead .qty { position: static; }
  .room-in { padding: 0 10px; }
  .room-in svg { display: none; }
  .pop { left: 8px; top: 100%; width: 240px; }
  .room.up .pop { top: auto; bottom: 100%; }
  .pop-photo { height: 130px; }
  .updated { height: auto; }
}
