/* =========================================================
   Booking modal — ResDiary widget overlay
   Shares the Fishers palette from style.css
   ========================================================= */
.bk-overlay{
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(16px, 5vh, 64px) 16px;
  background: color-mix(in oklch, var(--ink-night, #0b1622) 64%, transparent);
  -webkit-backdrop-filter: blur(7px) saturate(1.1);
  backdrop-filter: blur(7px) saturate(1.1);
  opacity: 0;
  visibility: hidden;
  transition: opacity .42s ease, visibility 0s linear .42s;
  overflow-y: auto;
}
.bk-overlay.is-open{
  opacity: 1;
  visibility: visible;
  transition: opacity .42s ease;
}

.bk-panel{
  position: relative;
  width: min(660px, 100%);
  margin: auto;
  background: var(--cream, #f6f3ea);
  box-shadow:
    0 40px 120px -30px color-mix(in oklch, var(--ink-night, #0b1622) 80%, transparent),
    0 0 0 1px color-mix(in oklch, var(--ink-deep, #14202c) 18%, transparent);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  transform: translateY(16px) scale(.985);
  opacity: 0;
  transition: transform .5s cubic-bezier(.22,.61,.36,1), opacity .42s ease;
}
.bk-overlay.is-open .bk-panel{
  transform: none;
  opacity: 1;
}
/* brass hairline along the very top */
.bk-panel::before{
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--brass, #b88a4a);
  z-index: 2;
}

/* ---------- header ---------- */
.bk-head{
  position: relative;
  background: var(--ink-deep, #14202c);
  color: var(--cream, #f6f3ea);
  padding: 26px 56px 24px 30px;
  flex-shrink: 0;
}
.bk-tag{
  font-family: var(--mono, ui-monospace, monospace);
  font-size: 10.5px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--brass, #c79a5b);
  margin: 0 0 9px;
}
.bk-title{
  font-family: var(--serif, "Cormorant Garamond", Georgia, serif);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1.02;
  margin: 0;
  color: var(--cream, #f6f3ea);
}
.bk-title em{ font-style: normal; }
.bk-note{
  display: inline-block;
  margin: 12px 0 0;
  padding: 7px 14px;
  background: var(--brass, #c79a5b);
  color: var(--ink-deep, #14202c);
  font-family: var(--mono, ui-monospace, monospace);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 3px;
}

.bk-close{
  position: absolute;
  top: 18px;
  right: 16px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in oklch, var(--cream, #f6f3ea) 28%, transparent);
  background: transparent;
  color: var(--cream, #f6f3ea);
  cursor: pointer;
  border-radius: 50%;
  transition: background .3s ease, color .3s ease, border-color .3s ease, transform .3s ease;
}
.bk-close:hover{
  background: var(--brass, #b88a4a);
  border-color: var(--brass, #b88a4a);
  color: var(--ink-deep, #14202c);
  transform: rotate(90deg);
}
.bk-close svg{ width: 16px; height: 16px; display: block; }

/* ---------- body ---------- */
.bk-body{
  position: relative;
  flex: 1 1 auto;
  overflow-y: auto;
  background: #fff;
  -webkit-overflow-scrolling: touch;
}
.bk-iframe{
  display: block;
  width: 100%;
  height: 520px;            /* updated live from postMessage */
  border: 0;
  background: #fff;
  transition: height .35s ease;
}
/* boot shimmer behind the iframe before first paint */
.bk-body::after{
  content: "Connecting to ResDiary…";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: 11px/1.6 var(--mono, ui-monospace, monospace);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: color-mix(in oklch, var(--ink, #243240) 45%, transparent);
  background: #fff;
  pointer-events: none;
  opacity: 1;
  transition: opacity .4s ease;
}
.bk-body.is-ready::after{ opacity: 0; }

/* ---------- footer note ---------- */
.bk-foot{
  flex-shrink: 0;
  background: var(--cream, #f6f3ea);
  border-top: 1px solid color-mix(in oklch, var(--ink, #243240) 14%, transparent);
  padding: 12px 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--mono, ui-monospace, monospace);
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: color-mix(in oklch, var(--ink, #243240) 55%, transparent);
}
.bk-foot a{ color: var(--brass-deep, #8a6431); text-decoration: none; border-bottom: 1px solid transparent; }
.bk-foot a:hover{ border-bottom-color: currentColor; }

@media (max-width: 560px){
  .bk-overlay{ padding: 0; }
  .bk-panel{ max-height: 100vh; max-height: 100dvh; width: 100%; }
  .bk-head{ padding: 22px 52px 20px 22px; }
  .bk-foot{ padding: 11px 22px; }
  .bk-foot .bk-foot-addr{ display: none; }
}

@media (prefers-reduced-motion: reduce){
  .bk-overlay, .bk-panel, .bk-iframe, .bk-close{ transition: opacity .25s ease; }
  .bk-panel{ transform: none; }
}
