:root {
  color-scheme: light;
  --paper: #f9f4e9;
  --white: #fffdf6;
  --ink: #2e477d;
  --deep: #192b52;
  --clay: #dd936d;
  --sand: #e9e9df;
  --foam: #e7edf4;
  --line: #d2d8e0;
  --body: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --display: Baskerville, "Iowan Old Style", Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.65 var(--body); }
body:has(dialog[open]) { overflow: hidden; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: default; }
a { color: inherit; }
img { display: block; max-width: 100%; }
figure, h1, h2, h3, p { margin: 0; }
h1, h2 { font-family: var(--display); font-weight: 400; letter-spacing: -.052em; line-height: .96; }
h2 { font-size: clamp(3.1rem, 7vw, 7.3rem); }
em { font-weight: inherit; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
[id] { scroll-margin-top: 1.7rem; }
.frame { width: min(89%, 1336px); margin-inline: auto; }
.skip-link { position: fixed; z-index: 9; left: 1rem; top: 1rem; padding: .6rem 1rem; background: var(--paper); transform: translateY(-185%); }
.skip-link:focus { transform: none; }
.eyebrow { font-size: .875rem; font-weight: 650; letter-spacing: .2em; text-transform: uppercase; }

.site-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 82px;
  gap: 1.1rem;
}
.wordmark { display: inline-block; width: fit-content; }
.wordmark img { height: auto; }
.site-header nav { display: flex; align-items: center; gap: clamp(1rem, 3.2vw, 3rem); text-align: center; }
.site-header nav a {
  display: grid;
  place-items: center;
  min-height: 44px;
  font-size: .9rem;
  font-weight: 600;
  text-decoration: none;
  text-underline-offset: .3em;
}
.site-header nav a:hover { text-decoration: underline; }
.header-booking { justify-self: end; }

.button {
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--white);
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 48px;
  padding: .68rem 1.25rem;
  font-weight: 620;
  font-size: .92rem;
  text-decoration: none;
  transition: color .18s ease, background-color .18s ease, border-color .18s ease;
}
.button:not(:disabled):hover { background: var(--deep); border-color: var(--deep); }
.button:focus-visible { outline-color: var(--ink); }
.button:disabled { opacity: .48; }
.button.button-outline { background: transparent; color: var(--ink); }
.button.button-outline:hover { background: var(--ink); color: var(--white); }
.text-link { display: inline-block; font-size: .94rem; font-weight: 650; text-underline-offset: .32em; }

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: clamp(495px, 50vw, 685px);
  overflow: hidden;
  background: var(--deep);
  color: var(--white);
  text-align: center;
}
.hero-image, .hero::before { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-image { z-index: -3; object-fit: cover; object-position: 50% 54%; }
.hero::before {
  content: "";
  z-index: -2;
  background: radial-gradient(ellipse at 50% 46%, rgb(12 23 42 / 60%), transparent 75%),
    linear-gradient(180deg, rgb(15 27 51 / 12%) 0%, rgb(15 27 51 / 26%) 38%, rgb(15 27 51 / 49%) 100%);
}
.hero-copy { position: relative; margin-bottom: clamp(1.4rem, 4.6vw, 4.7rem); text-shadow: 0 2px 18px rgb(13 21 37 / 38%); }
.hero h1 { font-size: clamp(4.65rem, 12vw, 13rem); margin: .09em 0 .13em; }
.hero .eyebrow { letter-spacing: .33em; }
.hero-subtitle { font: italic clamp(1.5rem, 2.75vw, 2.65rem)/1.13 var(--display); }
.hero-tide, .hero-tide::before {
  position: absolute;
  bottom: -2px;
  width: 120%;
  height: clamp(31px, 5.6vw, 90px);
  border-radius: 56% 66% 0 0 / 96% 100% 0 0;
}
.hero-tide { z-index: -1; inset-inline-start: -8%; background: var(--paper); }
.hero-tide::before {
  content: "";
  inset-inline-start: -9%;
  width: 109%;
  bottom: 10px;
  z-index: -1;
  background: rgb(249 244 233 / 45%);
  transform: rotate(-.8deg);
}

.booking { position: relative; z-index: 1; margin-top: -61px; }
.booking-rail {
  display: grid;
  align-items: center;
  grid-template-columns: minmax(123px, .82fr) minmax(0, 3.7fr);
  gap: .25rem clamp(1rem, 2vw, 2.3rem);
  padding: 1.1rem clamp(1.12rem, 2.75vw, 3rem) .85rem;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: 0 14px 45px rgb(36 53 83 / 12%);
}
.booking-rail h2 { font-size: clamp(1.9rem, 3vw, 3.05rem); letter-spacing: -.048em; }
.booking-rail h2 em { display: block; }
.booking-form {
  display: grid;
  grid-template-columns: minmax(16rem, 2.2fr) minmax(4.2rem, .56fr) minmax(max-content, 1.05fr);
  align-items: stretch;
  gap: .85rem;
  color: var(--ink);
}
.booking-native-dates, .booking-dates-trigger { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.booking-native-dates { gap: .6rem; }
.booking-native-dates label, .booking-guests { display: flex; flex-direction: column; }
.booking-native-dates label { gap: .25rem; font-size: .875rem; font-weight: 620; }
.booking-native-dates input, .booking-guests input { color: inherit; width: 100%; }
.booking-native-dates input {
  min-height: 44px;
  padding: .25rem .45rem;
  border: 1px solid var(--line);
  background: var(--white);
}
.booking-dates-trigger, .booking-guests {
  min-height: 65px;
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: .875rem;
  font-weight: 620;
}
.booking-dates-trigger { width: 100%; text-align: left; padding: 0; }
.booking-dates-trigger:hover { border-color: var(--ink); background: #f4f6f9; }
.booking-date { align-content: center; display: grid; gap: .02rem; padding: .46rem clamp(.62rem, 1.2vw, 1rem); }
.booking-date + .booking-date { border-inline-start: 1px solid var(--line); }
.booking-date strong { font-size: .96rem; line-height: 1.42; font-weight: 650; }
.booking-guests { justify-content: center; padding: .36rem .6rem .26rem; min-width: 0; }
.booking-guests:focus-within { border-color: var(--ink); }
.booking-guests input { padding: 0; min-height: 29px; border: 0; background: transparent; font-size: 1rem; }
.booking-guests input:focus-visible { outline-offset: 0; }
.booking-submit { padding-inline: clamp(.72rem, 1.2vw, 1.5rem); }
#booking-notice { grid-column: 2; color: #465778; font-size: .88rem; padding-top: .3rem; min-height: 1.4rem; }

.apartment {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr);
  align-items: center;
  gap: clamp(2.2rem, 7vw, 7.25rem);
  margin-top: clamp(4.4rem, 10vw, 10rem);
}
.apartment-photo img { width: 100%; aspect-ratio: 1.24; object-fit: cover; object-position: 42% center; border-radius: 48% 48% 0 0 / 22% 22% 0 0; }
.apartment-photo figcaption, .gallery-item figcaption { margin-top: .55rem; font-size: .88rem; font-weight: 610; }
.apartment-copy { max-width: 33rem; padding-block: .6rem; }
.apartment-copy h2 { margin: .18em 0 .2em; }
.apartment-copy h2 em { display: block; }
.apartment-copy > p:not(.eyebrow), .island-copy > p { max-width: 35ch; line-height: 1.75; }
.apartment-copy .text-link { margin-top: 1.5rem; }
.apartment-copy .eyebrow { color: #77503e; }

.gallery-section {
  position: relative;
  isolation: isolate;
  margin-top: clamp(5rem, 13vw, 11.5rem);
  padding-block: clamp(2rem, 5.6vw, 6.3rem) clamp(3.4rem, 8vw, 8rem);
  background: var(--foam);
}
.gallery-section::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: clamp(-68px, -4.6vw, -27px) 0 auto;
  height: clamp(45px, 6.8vw, 105px);
  background: inherit;
  border-radius: 56% 44% 0 0 / 87% 86% 0 0;
}
.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem 3rem; margin-bottom: clamp(1.5rem, 4vw, 3.6rem); }
.section-heading p { max-width: 36ch; }
.gallery {
  display: grid;
  grid-template-columns: 1.55fr 1fr 1fr;
  gap: clamp(1rem, 2vw, 1.6rem);
  align-content: start;
}
.gallery-item {
  min-width: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}
.gallery-feature { grid-row: span 2; }
.gallery-link {
  display: block;
  position: relative;
  min-height: 0;
  overflow: hidden;
  background: var(--sand);
}
.gallery-link:focus-visible { outline-offset: 3px; }
.gallery-item img { width: 100%; height: 100%; aspect-ratio: 1.36; object-fit: cover; transition: transform .38s ease; }
.gallery-feature img { position: absolute; inset: 0; object-position: 43% center; }
.gallery-link:hover img { transform: scale(1.035); }
.photo-open {
  position: absolute;
  right: .65rem;
  bottom: .65rem;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  font-size: 1.48rem;
  line-height: 1;
}
.gallery-link:hover .photo-open { color: var(--white); background: var(--ink); }

.island {
  display: grid;
  grid-template-columns: .89fr 1.11fr;
  align-items: stretch;
  margin-top: clamp(4.4rem, 10vw, 10rem);
  background: var(--ink);
  color: var(--white);
}
.island-copy { padding: clamp(1.7rem, 5.45vw, 6rem); align-content: center; }
.island-copy h2 { margin-bottom: .26em; font-size: clamp(3.45rem, 7.6vw, 7.2rem); }
.island-copy h2 em { display: block; color: #f3c7a9; }
.island-copy .button { margin-top: 1.55rem; background: var(--paper); border-color: var(--paper); color: var(--ink); }
.island-copy .button:hover { color: var(--paper); border-color: var(--paper); }
.island-copy .button:focus-visible { outline-color: var(--paper); }
.island-photo { min-height: clamp(335px, 40vw, 590px); position: relative; }
.island-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.site-footer { margin-top: clamp(4.4rem, 9vw, 9rem); background: var(--deep); color: var(--paper); }
.footer-inner { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: .65rem 1.5rem; padding-block: 1.7rem; }
.footer-inner > a:last-child { justify-self: end; }

dialog {
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
  max-height: min(92vh, 92dvh);
}
dialog::backdrop { background: rgb(15 27 51 / 73%); }
.booking-calendar { width: min(94vw, 470px); padding: clamp(.8rem, 3.5vw, 1.6rem); }
.booking-calendar-header { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem; }
.booking-calendar-header h2 { font-size: clamp(2rem, 7vw, 2.8rem); }
.booking-calendar-header p { min-height: 1.55rem; margin-top: .36rem; font-size: .88rem; }
.booking-calendar-month {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  justify-items: center;
  gap: .5rem;
  margin-block: .85rem .35rem;
}
.booking-calendar-month h3 { font-size: 1rem; font-weight: 660; text-align: center; text-transform: capitalize; }
.icon-button {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  padding: 0;
  background: transparent;
  color: inherit;
  border: 1px solid var(--line);
  font-size: 1.5rem;
  line-height: 1;
}
.icon-button:hover:not(:disabled) { background: var(--foam); }
.icon-button:disabled { opacity: .35; }
.booking-calendar-grid { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 1px; text-align: center; }
.booking-calendar-grid th { height: 29px; font-size: .82rem; font-weight: 620; }
.booking-calendar-grid abbr { text-decoration: none; }
.booking-calendar-grid td { padding: 0; }
.booking-calendar-grid td[aria-selected="true"] { background: var(--foam); }
.calendar-day {
  width: 100%;
  min-height: 42px;
  padding: 0;
  border: 1px solid transparent;
  background: transparent;
  color: inherit;
  font-weight: 570;
}
.calendar-day:not(:disabled):hover { background: var(--foam); border-color: var(--ink); }
.calendar-day:disabled { color: #69758a; font-weight: 400; text-decoration: line-through; }
.calendar-day[aria-current="date"] { text-decoration: underline; text-underline-offset: .16em; }
.calendar-day.is-endpoint, .calendar-day.is-endpoint:hover { background: var(--ink); color: var(--white); }
.calendar-day:focus-visible { outline: 2px solid var(--ink); outline-offset: -2px; }
.calendar-day.is-endpoint:focus-visible { outline-color: var(--white); }
.booking-calendar-actions, .lightbox-controls, .lightbox-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: .55rem .75rem;
}
.booking-calendar-actions { margin-top: .8rem; padding-top: .78rem; border-top: 1px solid var(--line); }
.text-button { min-height: 44px; padding: .2rem .35rem; color: inherit; background: transparent; border: 0; text-decoration: underline; text-underline-offset: .25em; font-size: .92rem; font-weight: 650; }
.text-button:disabled { opacity: .52; }

.lightbox { width: min(94vw, 1050px); padding: 0; background: var(--deep); color: var(--white); }
.lightbox-bar, .lightbox-controls { padding: .52rem clamp(.8rem, 3vw, 1.6rem); }
.lightbox-bar p { font-weight: 620; }
.lightbox-image { width: 100%; max-height: 65vh; max-height: 65dvh; height: auto; object-fit: contain; background: #111e3a; }
.lightbox-close span { margin-left: .25rem; font-size: 1.2em; }
.photo-count { font-size: .9rem; }

@media (max-width: 1040px) {
  .booking-rail { grid-template-columns: minmax(102px, .65fr) minmax(0, 3fr); }
  .booking-form { grid-template-columns: minmax(13rem, 1.8fr) minmax(4rem, .55fr) max-content; gap: .6rem; }
  .site-header .wordmark img { width: 165px; }
}

@media (max-width: 760px) {
  .frame { width: min(91%, 1336px); }
  .site-header {
    grid-template-columns: 1fr auto;
    min-height: 0;
    gap: .35rem .6rem;
    padding-block: .75rem .28rem;
  }
  .site-header nav { grid-column: 1 / -1; grid-row: 2; justify-content: center; gap: clamp(.85rem, 4.1vw, 1.9rem); }
  .header-booking { min-height: 44px; padding-inline: .66rem; font-size: .88rem; }
  .site-header .wordmark img { width: min(100%, 166px); }
  .hero { min-height: clamp(360px, 103vw, 565px); }
  .hero-image { object-position: 46% 50%; }
  .hero-copy { margin-bottom: 2.1rem; }
  .hero h1 { font-size: clamp(3.9rem, 14vw, 7rem); }
  .hero-subtitle { font-size: clamp(1.32rem, 5.4vw, 2.15rem); }
  .booking { margin-top: -2.15rem; }
  .booking-rail { grid-template-columns: 1fr; gap: .75rem; padding: .95rem; }
  .booking-rail h2 em { display: inline; }
  .booking-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: .55rem; }
  .booking-dates, .booking-native-dates { grid-column: 1 / -1; }
  .booking-guests, .booking-dates-trigger { min-height: 59px; }
  .booking-submit { line-height: 1.35; text-align: center; }
  #booking-notice { grid-column: 1; padding-top: 0; }
  .apartment, .island { grid-template-columns: 1fr; }
  .apartment { gap: 1.65rem; }
  .apartment-photo img { aspect-ratio: 1.28; }
  .apartment-copy { padding-inline: .13rem; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery-feature { grid-row: auto; grid-column: 1 / -1; }
  .gallery-feature img { position: static; aspect-ratio: 1.63; object-position: center; }
  .island-photo { min-height: 0; aspect-ratio: 1.35; }
  .island-copy { padding-block: 2rem; }
  .footer-inner { grid-template-columns: 1fr auto; }
  .footer-inner p { grid-row: 2; }
}

@media (max-width: 350px) {
  .booking-rail { padding: .7rem; }
  .booking-date { padding-inline: .45rem; }
  .booking-date strong { font-size: .875rem; }
  .booking-calendar .button { padding-inline: .72rem; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-inner > a:last-child { justify-self: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
