/* Stay page: a booking-first panel and one responsive photo viewer. */
:root {
  --booking-panel-width: clamp(380px, 32vw, 440px);
  --ui-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--paper); color: var(--ink); font-family: "EB Garamond", Georgia, serif; }
[hidden] { display: none !important; }
a { color: inherit; text-underline-offset: 4px; }
button, input, select { font: inherit; }
button, summary { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .45; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; white-space: nowrap; clip-path: inset(50%); }
.skip-link { position: fixed; left: 16px; top: -80px; padding: 12px 18px; background: var(--paper); color: var(--ink); z-index: 30; }
.skip-link:focus { top: 12px; }
.stay-layout { display: grid; grid-template-columns: var(--booking-panel-width) minmax(0, 1fr); min-height: 100dvh; }
.property-panel { background: var(--brown); color: var(--paper); height: 100dvh; overflow-y: auto; padding: 24px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.property-navigation { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 14px; font-size: 15px; }
.property-navigation a { display: inline-flex; align-items: center; min-height: 28px; text-decoration: none; }
.property-navigation a:hover, .property-shortcuts a:hover { text-decoration: underline; }
.eyebrow { font-family: var(--ui-font); font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.property-overview .eyebrow { color: var(--paper-deep); margin: 0 0 7px; }
.property-overview h1 { font-size: 38px; font-weight: 500; letter-spacing: -.035em; line-height: 1.05; margin: 0; overflow-wrap: anywhere; }
.property-subtitle { font-size: 19px; line-height: 1.2; margin: 7px 0 0; text-wrap: pretty; }
.property-summary { font-size: 16px; line-height: 1.35; margin: 10px 0 0; }
.property-facts { display: grid; gap: 4px; margin-top: 14px; font-size: 15px; line-height: 1.3; text-transform: capitalize; }

.property-shortcuts { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 8px 0 14px; font-size: 14px; }
.property-shortcuts a { display: inline-flex; align-items: center; min-height: 28px; }

/* The light booking surface is the primary action, not another sidebar link. */
.inline-booking { background: var(--panel); border: 1px solid var(--paper-deep); border-radius: var(--corner-media); color: var(--ink); padding: 18px; }
.booking-heading-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; }
.inline-booking h2 { font-size: 27px; font-weight: 500; letter-spacing: -.025em; line-height: 1.05; margin: 0; }
.booking-badge { font-family: var(--ui-font); font-size: 10px; border: 1px solid var(--line); border-radius: 3px; padding: 4px 6px; white-space: nowrap; }
.booking-intro { font-size: 15px; line-height: 1.3; margin: 8px 0 14px; }
.booking-steps { display: flex; flex-wrap: wrap; gap: 10px 22px; padding: 0 0 10px; margin: 0; list-style: none; border-bottom: 1px solid var(--line); font-family: var(--ui-font); font-size: 11px; color: var(--muted); }
.booking-steps li { display: flex; align-items: center; gap: 6px; }
.booking-steps li > span { display: inline-grid; place-items: center; border: 1px solid var(--line); width: 20px; height: 20px; border-radius: 50%; }
.booking-steps [aria-current="step"] { color: var(--ink); font-weight: 650; }
.booking-steps [aria-current="step"] > span { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.inline-booking fieldset { display: grid; gap: 12px; border: 0; min-width: 0; margin: 14px 0 0; padding: 0; }
.inline-booking label { display: grid; gap: 5px; font-family: var(--ui-font); font-size: 12px; line-height: 1.4; }
.inline-booking input, .inline-booking select { background: var(--paper); border: 1px solid var(--line); border-radius: var(--corner-control); color: var(--ink); font-family: var(--ui-font); font-size: 16px; min-height: 44px; min-width: 0; padding: 9px 10px; width: 100%; }
.inline-booking input:focus, .inline-booking select:focus { border-color: var(--ink); }
.inline-booking .field-label { display: flex; justify-content: space-between; gap: 8px; }
.field-label small { font-size: 11px; font-weight: 400; color: var(--muted); }
.guest-name-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.booking-actions { display: grid; grid-template-columns: 105px minmax(0, 1fr); gap: 12px; align-items: end; }
.inline-booking .booking-primary { background: var(--ink); border: 1px solid var(--ink); border-radius: var(--corner-control); color: var(--paper); font-size: 18px; font-weight: 500; min-height: 44px; padding: 9px 12px; }
.inline-booking .booking-primary:hover:not(:disabled) { background: var(--accent-dark); }
.inline-booking .booking-primary:disabled { opacity: .5; }
.booking-status { margin: 0; font-size: 15px; line-height: 1.35; }
.booking-status.bad { border-left: 3px solid var(--bad); padding: 8px 10px; font-weight: 600; }
.booking-status.is-loading { color: var(--muted); }
.request-access { display: grid; gap: 6px; margin-top: 14px; text-align: center; }
.request-access > span { color: var(--muted); font-size: 13px; }
.request-access a { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 9px 12px; border: 1px solid var(--ink); border-radius: var(--corner-control); background: var(--paper); font-size: 17px; font-weight: 600; text-decoration: none; }
.request-access a:hover { background: var(--paper-deep); }
.booking-reassurance { border-top: 1px solid var(--line); padding-top: 12px; margin: 10px 0 0; font-size: 13px; line-height: 1.35; color: var(--muted); }
.stay-summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 15px; line-height: 1.3; }
.stay-summary button, .booking-confirmation button { background: transparent; border: 0; color: inherit; min-height: 32px; padding: 4px 0; text-decoration: underline; text-underline-offset: 3px; }
.booking-estimate { display: grid; gap: 10px; border: 1px solid var(--line); padding: 12px; border-radius: var(--corner-control); }
.booking-estimate > p { font-size: 17px; font-weight: 600; margin: 0; }
.booking-estimate > div { display: grid; gap: 8px; }
.booking-estimate-row { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr) auto; font-size: 14px; line-height: 1.3; }
.booking-estimate-row > span:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.booking-estimate-row.is-total { border-top: 1px solid var(--line); padding-top: 10px; font-size: 17px; font-weight: 650; }
.booking-estimate-row.is-deposit { color: var(--muted); }
.booking-estimate > small { color: var(--muted); font-size: 12px; line-height: 1.35; }
.inline-booking .whatsapp-consent { font-family: inherit; font-size: 14px; line-height: 1.4; }
.booking-confirmation { display: grid; gap: 10px; padding-top: 16px; font-size: 16px; line-height: 1.35; }
.booking-confirmation > p { font-size: 24px; margin: 0; }
.booking-confirmation > strong { display: block; background: var(--paper-deep); padding: 12px; font-family: var(--ui-font); font-size: 20px; overflow-wrap: anywhere; }
.booking-confirmation > div { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.booking-confirmation a { min-height: 32px; display: inline-flex; align-items: center; }
.booking-unavailable { padding: 20px 0; }

/* Scoped calendar treatment leaves the legacy request page unchanged. */
.inline-booking .booking-calendar { font-family: var(--ui-font); }
.inline-booking .booking-calendar button { border-color: var(--line); border-radius: var(--corner-control); }
.inline-booking .booking-calendar .calendar-selection { gap: 8px; }
.inline-booking .booking-calendar .calendar-selection button { background: var(--paper); min-height: 57px; padding: 9px 10px; }
.inline-booking .booking-calendar .calendar-selection span { font-size: 11px; color: var(--muted); }
.inline-booking .booking-calendar .calendar-selection strong { font-size: 13px; font-weight: 600; margin-top: 4px; }
.inline-booking .booking-calendar .calendar-selection [aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.inline-booking .booking-calendar .calendar-navigation { margin: 10px 0 4px; }
.inline-booking .booking-calendar .calendar-navigation button { min-width: 36px; min-height: 36px; padding: 2px; font-size: 23px; }
.inline-booking .booking-calendar .calendar-navigation strong { font-size: 13px; }
.inline-booking .booking-calendar th { color: var(--muted); font-size: 10px; padding: 7px 0; }
.inline-booking .booking-calendar td { padding: 1px; }
.inline-booking .booking-calendar td button { min-height: 32px; font-size: 13px; }
.inline-booking .booking-calendar td button:hover:not(:disabled) { box-shadow: inset 0 0 0 1px var(--ink); }
.inline-booking .booking-calendar td button.is-selected { background: var(--ink); color: var(--paper); }
.inline-booking .booking-calendar td button.is-in-range { background: var(--paper-deep); color: var(--ink); }
.inline-booking .booking-calendar td button.is-blocked:not(:disabled) { outline-color: var(--ink); }
.inline-booking .booking-calendar button:focus-visible { outline-color: var(--ink); }
.inline-booking .booking-calendar .calendar-rules, .inline-booking .booking-calendar .calendar-legend, .inline-booking .booking-calendar .calendar-status { font-family: "EB Garamond", Georgia, serif; font-size: 13px; line-height: 1.3; margin: 7px 0; }
.inline-booking .booking-calendar .calendar-legend { color: var(--muted); }
.inline-booking .booking-calendar .calendar-status { font-weight: 500; }
.inline-booking .booking-calendar .calendar-actions { justify-content: space-between; gap: 6px; }
.inline-booking .booking-calendar .calendar-actions button { font-family: inherit; font-size: 11px; min-height: 32px; padding: 6px 8px; }

.property-disclosure { border-bottom: 1px solid color-mix(in srgb, var(--paper) 30%, transparent); margin-top: 4px; }
.property-disclosure summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; list-style: none; font-size: 17px; }
.property-disclosure summary::-webkit-details-marker { display: none; }
.disclosure-mark { font-family: var(--ui-font); font-size: 18px; font-weight: 300; }
.property-disclosure[open] .disclosure-mark { transform: rotate(45deg); }
.disclosure-content { padding: 0 0 18px; }
.property-kind { margin: 0 0 8px; font-size: 14px; text-transform: capitalize; color: var(--paper-deep); }
.property-address { display: grid; font-size: 16px; font-style: normal; line-height: 1.4; }
.map-links { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; }
.map-links a { display: inline-flex; align-items: center; min-height: 32px; font-size: 15px; }
.property-disclosure .host-contact { border: 0; margin: 0; padding: 0 0 16px; }
.property-disclosure .host-contact h2 { font-size: 18px; }
.property-disclosure .host-contact-person { border-top: 1px solid color-mix(in srgb, var(--paper) 25%, transparent); padding-top: 12px; }
.property-disclosure .host-contact-person strong { font-size: 18px; }
.property-disclosure .host-contact-links { gap: 4px 16px; }
.property-disclosure .host-contact-links a { display: inline-flex; align-items: center; min-height: 32px; font-size: 15px; }
.property-disclosure .contact-note { color: var(--paper-deep); }

/* Photos retain their full frame; no duplicate desktop/mobile gallery. */
.gallery-panel { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; gap: 16px; height: 100dvh; min-width: 0; padding: 26px 28px 22px; }
.gallery-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.gallery-toolbar .eyebrow { color: var(--muted); }
.gallery-toolbar p { margin: 4px 0 0; font-size: 20px; }
.gallery-controls { display: flex; align-items: center; gap: 8px; }
.gallery-controls > span { font-family: var(--ui-font); font-size: 12px; font-variant-numeric: tabular-nums; margin-right: 8px; }
.gallery-controls button { display: inline-grid; place-items: center; width: 44px; height: 44px; background: transparent; border: 1px solid var(--line); border-radius: var(--corner-control); color: var(--ink); font-size: 21px; }
.gallery-controls button:hover:not(:disabled) { background: var(--ink); color: var(--paper); }
.photo-viewer { position: relative; margin: 0; min-height: 0; display: grid; place-items: center; }
.selected-photo-button { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 0; padding: 0; border: 0; background: transparent; z-index: 1; }
.selected-photo-button img { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; border-radius: var(--corner-media); transition: opacity 100ms linear; }
.photo-expand { position: absolute; right: 12px; bottom: 12px; padding: 8px 12px; background: var(--paper); color: var(--ink); border: 1px solid var(--line); border-radius: var(--corner-control); font-size: 14px; }
.selected-photo-button img.is-loading, #photo-lightbox img.is-loading { opacity: .14; }
.thumbnail-list { display: flex; gap: 10px; overflow-x: auto; padding: 3px 2px 8px; min-width: 0; scrollbar-width: thin; scrollbar-color: var(--muted) transparent; }
.thumbnail-list button { background: transparent; border: 2px solid transparent; border-radius: var(--corner-media); flex: 0 0 76px; padding: 3px; height: 76px; }
.thumbnail-list img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 2px; opacity: .7; }
.thumbnail-list button[aria-pressed="true"] { border-color: var(--ink); }
.thumbnail-list button[aria-pressed="true"] img, .thumbnail-list button:hover img { opacity: 1; }
.empty-photo { display: grid; place-items: center; font-size: 20px; color: var(--muted); }
.site-error { max-width: 680px; margin: 0 auto; padding: 80px 24px; }
.site-error h1 { font-size: 36px; font-weight: 500; }
.site-error .brand { font-size: 20px; }
#photo-lightbox {
  background: var(--overlay);
  border: 0;
  color: var(--paper);
  height: 100dvh;
  margin: 0;
  max-height: none;
  max-width: none;
  padding: 18px;
  position: fixed;
  width: 100vw;
}

#photo-lightbox[open] {
  display: grid;
  gap: 12px;
  grid-template-columns: 52px minmax(0, 1fr) 52px;
  grid-template-rows: 42px minmax(0, 1fr);
}

#photo-lightbox::backdrop {
  background: var(--backdrop);
}

#photo-lightbox button {
  background: var(--paper);
  border: 1px solid var(--paper);
  border-radius: var(--corner-control);
  color: var(--brown);
}

#photo-lightbox button:hover {
  background: var(--brown);
  color: var(--paper);
}

#photo-lightbox button:disabled {
  cursor: default;
  opacity: 0.3;
}

.lightbox-close {
  font-size: 17px;
  grid-column: 2 / 4;
  justify-self: end;
  padding: 6px 14px 7px;
}

.lightbox-nav {
  align-self: center;
  font-size: 28px;
  height: 46px;
  line-height: 1;
  width: 46px;
}

.lightbox-previous {
  grid-column: 1;
  grid-row: 2;
}

.lightbox-next {
  grid-column: 3;
  grid-row: 2;
}

#photo-lightbox figure {
  align-items: center;
  display: flex;
  grid-column: 2;
  grid-row: 2;
  justify-content: center;
  margin: 0;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  position: relative;
  touch-action: none;
}

#photo-lightbox figure img {
  border-radius: var(--corner-media);
  display: block;
  height: auto;
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  position: relative;
  transform: translate3d(0, 0, 0) scale(1);
  transform-origin: center;
  user-select: none;
  will-change: transform;
  width: auto;
  z-index: 1;
}

#photo-lightbox figure[data-zoomed="true"] {
  cursor: grab;
}

#photo-lightbox figure[data-dragging="true"] {
  cursor: grabbing;
}

.lightbox-zoom-controls {
  align-items: center;
  bottom: 24px;
  display: flex;
  gap: 5px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  z-index: 4;
}

.lightbox-zoom-controls button {
  font-size: 20px;
  height: 39px;
  line-height: 1;
  min-width: 39px;
  padding: 0 10px 2px;
}

.lightbox-zoom-controls button[data-zoom-reset] {
  font-size: 15px;
  min-width: 68px;
}

.loading-label {
  animation: loading-pulse 1.2s ease-in-out infinite alternate;
  font-size: 18px;
  left: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
}

@keyframes loading-pulse {
  from { opacity: 0.25; }
  to { opacity: 1; }
}

/* Compact desktop and single-column mobile use the same controls and state. */
@media (min-width: 901px) and (max-height: 850px) {
  .property-panel { padding: 16px 22px; }
  .property-navigation { margin-bottom: 14px; }
  .property-overview h1 { font-size: 34px; }
  .property-facts { margin-top: 10px; }
  .property-shortcuts { margin: 8px 0 12px; }
  .inline-booking { padding: 15px; }
  .booking-intro { margin-bottom: 10px; }
  .gallery-panel { padding: 18px 22px 16px; }
}
@media (max-width: 900px) {
  .stay-layout { display: flex; flex-direction: column; }
  .property-panel { display: contents; }
  .property-overview { order: 1; background: var(--brown); color: var(--paper); padding: 18px 20px 16px; }
  .property-navigation { margin-bottom: 16px; }
  .property-overview h1 { font-size: 34px; }
  .property-facts { margin-top: 12px; }
  .property-shortcuts { margin: 10px 0 0; }
  .gallery-panel { order: 2; height: auto; gap: 12px; padding: 16px 20px 12px; }
  .gallery-toolbar p { font-size: 17px; }
  .gallery-toolbar .eyebrow { display: none; }
  .gallery-controls button { width: 40px; height: 40px; }
  .photo-viewer { height: clamp(200px, 58vw, 380px); }
  .photo-expand { font-size: 13px; right: 8px; bottom: 8px; padding: 6px 9px; }
  .thumbnail-list { gap: 7px; }
  .thumbnail-list button { flex-basis: 56px; height: 56px; }
  .inline-booking { order: 3; width: calc(100% - 40px); max-width: 560px; margin: 4px auto 16px; padding: 18px; }
  .inline-booking .booking-calendar td button { min-height: 44px; }
  .inline-booking .booking-calendar .calendar-navigation button { min-width: 44px; min-height: 44px; }
  .inline-booking .booking-calendar .calendar-actions button { min-height: 40px; font-size: 11px; }
  .property-disclosure { order: 4; background: var(--brown); color: var(--paper); padding: 0 20px; margin: 0; border-bottom-color: var(--line); }
  .property-disclosure summary { min-height: 56px; }
  .booking-unavailable { order: 3; text-align: center; }
  #photo-lightbox { padding: 10px; }
  #photo-lightbox[open] { gap: 8px; grid-template-columns: 40px minmax(0, 1fr) 40px; grid-template-rows: 44px minmax(0, 1fr); }
  .lightbox-nav { width: 40px; height: 44px; font-size: 24px; }
  .lightbox-zoom-controls { bottom: 16px; }
  .lightbox-zoom-controls button { height: 44px; min-width: 44px; }
}
@media (max-width: 360px) {
  .property-overview { padding-inline: 16px; }
  .gallery-panel { padding-inline: 12px; }
  .inline-booking { width: calc(100% - 24px); padding: 14px; }
  .booking-badge { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .loading-label { animation: none; }
  .selected-photo-button img, #photo-lightbox img { transition: none; }
}
