/* Hole in One Chapala
   Restraint is the whole idea. The palette is near-monochrome so the
   photography carries every bit of colour on the page. Type is large,
   spacing is generous, and there is no decorative chrome anywhere. */

:root {
  --paper: #fcfbf9;
  --ink: #1b1c19;
  --ink-soft: #55574f;
  --line: #ddd9d0;
  --sage: #4a5546;
  --brass: #8d7346;

  --measure: 58ch;
  --gutter: clamp(1.5rem, 6vw, 7rem);
  --rhythm: clamp(5.5rem, 13vw, 12rem);

  --display: "Marcellus", Georgia, serif;
  --ui: "Jost", system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 1.0625rem;
  font-weight: 300;
  line-height: 1.75;
  letter-spacing: .008em;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.01em;
  margin: 0;
  text-wrap: balance;
}

h1 { font-size: clamp(2.9rem, 6.4vw, 6rem); line-height: 1.04; }
h2 { font-size: clamp(2.1rem, 4vw, 3.5rem); }
h3 { font-size: clamp(1.35rem, 1.8vw, 1.7rem); }

p { margin: 0 0 1.4em; max-width: var(--measure); }
p:last-child { margin-bottom: 0; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 4px;
}

img { display: block; width: 100%; height: 100%; object-fit: cover; }

.wrap {
  width: min(100%, 86rem);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap--narrow { width: min(100%, 62rem); }

.skip {
  position: absolute; left: -9999px;
  background: var(--ink); color: var(--paper);
  padding: 1rem 1.5rem; z-index: 100;
}
.skip:focus { left: 1rem; top: 1rem; }

/* ---- Image frames ------------------------------------------------------
   Until the photography lands these render as quiet, intentional frames
   rather than broken boxes. Drop a real <img> in and the label disappears. */

.frame {
  position: relative;
  background: #eeebe4;
  overflow: hidden;
}

.frame::after {
  content: attr(data-shot);
  position: absolute;
  inset: auto 0 0 0;
  padding: 1rem 1.25rem;
  font-size: .75rem;
  font-weight: 400;
  letter-spacing: .06em;
  color: #9d998f;
}

.frame:has(img)::after { content: none; }
.frame > img { position: absolute; inset: 0; }

.frame--tall { aspect-ratio: 3 / 4; }
.frame--wide { aspect-ratio: 16 / 10; }
.frame--square { aspect-ratio: 1 / 1; }

/* ---- Masthead ---------------------------------------------------------- */

.masthead {
  position: absolute;
  inset: 0 0 auto;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(1.75rem, 3vw, 2.75rem) var(--gutter);
  color: #fff;
}

.masthead__name {
  font-family: var(--display);
  font-size: clamp(1.05rem, 1.4vw, 1.3rem);
  letter-spacing: .12em;
  text-decoration: none;
}

.masthead__nav {
  display: flex;
  gap: clamp(1.5rem, 3vw, 3rem);
  font-size: .8125rem;
  font-weight: 400;
  letter-spacing: .14em;
}

.masthead__nav a {
  text-decoration: none;
  opacity: .82;
  transition: opacity .25s ease;
}
.masthead__nav a:hover { opacity: 1; }

/* ---- Mobile menu -------------------------------------------------------
   The nav used to be hidden outright below 48rem, which left phone visitors
   with no navigation at all. Now it becomes a full-screen panel. */

.menu-toggle {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  margin: 0;
  background: none;
  border: 0;
  color: inherit;
  cursor: pointer;
  position: relative;
  z-index: 30;
}

.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
  position: absolute;
  left: 50%;
  width: 1.5rem;
  height: 1px;
  background: currentColor;
  transform: translateX(-50%);
  transition: transform .3s ease, opacity .2s ease;
  content: "";
}
.menu-toggle span { top: 50%; }
.menu-toggle span::before { top: -.4rem; }
.menu-toggle span::after { top: .4rem; }

.masthead.is-open .menu-toggle span { background: transparent; }
.masthead.is-open .menu-toggle span::before { transform: translateX(-50%) translateY(.4rem) rotate(45deg); }
.masthead.is-open .menu-toggle span::after { transform: translateX(-50%) translateY(-.4rem) rotate(-45deg); }

@media (max-width: 48rem) {
  .menu-toggle { display: block; }

  .masthead__nav {
    position: fixed;
    inset: 0;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: .5rem;
    padding: 2rem var(--gutter);
    background: var(--ink);
    color: #fff;
    font-size: 1.5rem;
    letter-spacing: .04em;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-1rem);
    transition: opacity .3s ease, transform .3s ease, visibility .3s;
  }

  .masthead.is-open .masthead__nav {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .masthead__nav a {
    opacity: 1;
    padding: .6rem 0;
    font-family: var(--display);
  }

  /* Menu open: the bar itself must stay legible over the panel. */
  .masthead.is-open,
  .masthead.is-stuck.is-open {
    color: #fff;
    background: transparent;
    border: 0;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .masthead.is-open .masthead__name { position: relative; z-index: 30; }
}

/* ---- Hero -------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: min(100svh, 58rem);
  display: grid;
  align-items: end;
  background: #23261f;
  color: #fff;
  overflow: hidden;
}

.hero__media { position: absolute; inset: 0; }
.hero__media img { position: absolute; inset: 0; }

/* Stands in for the photograph. Quiet, so it doesn't fight the type. */
.hero__media--empty {
  background:
    radial-gradient(120% 90% at 22% 92%, rgba(0,0,0,.55), transparent 62%),
    linear-gradient(#2f332a, #191b16);
}

.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top,
    rgba(12,14,11,.72) 0%,
    rgba(12,14,11,.30) 42%,
    rgba(12,14,11,.10) 72%);
}

.hero__body {
  position: relative;
  z-index: 2;
  padding-bottom: clamp(4rem, 9vw, 8rem);
}

.hero h1 { max-width: 15ch; }

.hero__sub {
  margin-top: 1.9rem;
  max-width: 42ch;
  font-size: clamp(1.05rem, 1.3vw, 1.2rem);
  color: rgba(255,255,255,.8);
}

/* ---- Buttons ----------------------------------------------------------- */

.btn {
  display: inline-block;
  margin-top: 2.5rem;
  padding: 1.05rem 2.75rem;
  font-family: var(--ui);
  font-size: .8125rem;
  font-weight: 400;
  letter-spacing: .16em;
  text-decoration: none;
  color: #fff;
  background: transparent;
  border: 1px solid rgba(255,255,255,.55);
  cursor: pointer;
  transition: background .3s ease, border-color .3s ease, color .3s ease;
}
.btn:hover { background: #fff; border-color: #fff; color: var(--ink); }

.btn--solid {
  background: var(--sage);
  border-color: var(--sage);
  color: #fff;
}
.btn--solid:hover { background: var(--ink); border-color: var(--ink); color: #fff; }

/* ---- Sections ---------------------------------------------------------- */

.section { padding-block: var(--rhythm); }
.section--tight { padding-block: clamp(3.5rem, 8vw, 7rem); }
.section--dark { background: var(--sage); color: #fff; }
.section--dark p { color: rgba(255,255,255,.82); }

.lede {
  font-size: clamp(1.2rem, 1.75vw, 1.5rem);
  font-weight: 300;
  line-height: 1.6;
  max-width: 44ch;
}

.prose { margin-top: 2.25rem; color: var(--ink-soft); }

/* ---- Split: text beside a photograph ----------------------------------- */

.split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: center;
}

.split--reverse > :first-child { order: 2; }

@media (max-width: 56rem) {
  .split { grid-template-columns: 1fr; gap: 2.5rem; }
  .split--reverse > :first-child { order: 0; }
}

/* ---- Feature list ------------------------------------------------------ */

.features { margin-top: clamp(4rem, 8vw, 7rem); }

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
  gap: clamp(1rem, 5vw, 4rem);
  padding-block: clamp(2rem, 4vw, 3rem);
  border-top: 1px solid var(--line);
  align-items: baseline;
}
.feature:last-child { border-bottom: 1px solid var(--line); }

.feature p { color: var(--ink-soft); margin: 0; }

@media (max-width: 48rem) {
  .feature { grid-template-columns: 1fr; gap: .75rem; }
}

/* ---- Gallery ----------------------------------------------------------- */

.gallery {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(.75rem, 1.4vw, 1.25rem);
  margin-top: clamp(3rem, 6vw, 5rem);
}

.gallery > *:nth-child(1) { grid-column: span 7; }
.gallery > *:nth-child(2) { grid-column: span 5; }
.gallery > *:nth-child(3) { grid-column: span 5; }
.gallery > *:nth-child(4) { grid-column: span 7; }

@media (max-width: 48rem) {
  .gallery > * { grid-column: span 12 !important; }
}

/* ---- Amenities --------------------------------------------------------- */

.amenities {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: clamp(2.5rem, 5vw, 5rem);
  margin-top: clamp(3rem, 6vw, 5rem);
}

.amenities h3 {
  font-family: var(--ui);
  font-size: .8125rem;
  font-weight: 400;
  letter-spacing: .16em;
  color: var(--brass);
  padding-bottom: 1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--line);
}

.section--dark .amenities h3 {
  color: rgba(255,255,255,.72);
  border-bottom-color: rgba(255,255,255,.24);
}

.amenities ul { margin: 0; padding: 0; list-style: none; }
.amenities li { padding-block: .5rem; color: var(--ink-soft); }
.section--dark .amenities li { color: rgba(255,255,255,.85); }

/* ---- Distances --------------------------------------------------------- */

.distances { margin-top: clamp(2.5rem, 5vw, 4rem); max-width: 48rem; }

.distance {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 2rem;
  justify-content: space-between;
  align-items: baseline;
  padding-block: 1.4rem;
  border-bottom: 1px solid rgba(255,255,255,.22);
}
.distance:first-child { border-top: 1px solid rgba(255,255,255,.22); }

.distance__place { font-size: 1.15rem; }
.distance__time {
  font-size: .9375rem;
  letter-spacing: .06em;
  color: rgba(255,255,255,.66);
  font-variant-numeric: tabular-nums;
}

/* ---- Plain lists ------------------------------------------------------- */

.plain {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  columns: 2;
  column-gap: 3rem;
  max-width: 40rem;
}
.plain li {
  padding-block: .5rem;
  color: var(--ink-soft);
  break-inside: avoid;
}

@media (max-width: 34rem) { .plain { columns: 1; } }

/* ---- Enquiry ----------------------------------------------------------- */

.enquiry {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1fr);
  gap: clamp(3rem, 7vw, 6rem);
  align-items: start;
}

@media (max-width: 56rem) { .enquiry { grid-template-columns: 1fr; } }

.field { margin-bottom: 1.6rem; }

.field label {
  display: block;
  margin-bottom: .6rem;
  font-size: .8125rem;
  letter-spacing: .12em;
  color: var(--ink-soft);
}

.field input,
.field textarea {
  width: 100%;
  padding: .95rem 0;
  font: inherit;
  font-size: 1.0625rem;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  transition: border-color .25s ease;
}

.field input:focus,
.field textarea:focus {
  border-bottom-color: var(--sage);
  outline: 0;
}

.field textarea { min-height: 6rem; resize: vertical; }

.dates { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }

.rules { margin-top: 3rem; list-style: none; padding: 0; }
.rules li { padding-block: .45rem; color: var(--ink-soft); }

/* ---- Footer ------------------------------------------------------------ */

.footer {
  background: var(--ink);
  color: rgba(255,255,255,.62);
  padding-block: clamp(3.5rem, 7vw, 6rem);
  font-size: .9375rem;
}

.footer__grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem 5rem;
  justify-content: space-between;
}

.footer__name {
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: .1em;
  color: #fff;
  margin-bottom: .85rem;
}

.footer a { color: rgba(255,255,255,.85); text-decoration: none; }
.footer a:hover { color: #fff; }

/* ========================================================================
   Cinematic treatment
   Video hero, full-bleed image bands, and a single scroll reveal.
   ===================================================================== */

/* ---- Sticky header ----------------------------------------------------- */

.masthead {
  position: fixed;
  transition: background .35s ease, color .35s ease, box-shadow .35s ease;
  will-change: background-color;
}

.masthead.is-stuck {
  background: rgba(252, 251, 249, .97);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--line);
}

/* backdrop-filter makes this element the containing block for any
   position:fixed child, which collapses the full-screen menu down to the
   height of the header bar. Drop the blur whenever the menu is open. */
.masthead.is-open,
.masthead.is-stuck.is-open {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  background: transparent;
  border-bottom-color: transparent;
}

/* ---- Video hero -------------------------------------------------------- */

.hero { min-height: 100svh; }

.hero__media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero h1 { font-size: clamp(3.1rem, 7.6vw, 7.5rem); }

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: 2rem;
  transform: translateX(-50%);
  z-index: 3;
  width: 1px;
  height: 4rem;
  background: linear-gradient(rgba(255,255,255,0), rgba(255,255,255,.7));
}

@media (prefers-reduced-motion: no-preference) {
  .hero__scroll { animation: drop 2.6s ease-in-out infinite; transform-origin: top; }
  @keyframes drop {
    0%, 100% { transform: translateX(-50%) scaleY(.35); opacity: .4; }
    50%      { transform: translateX(-50%) scaleY(1);   opacity: 1; }
  }
}

/* ---- Full-bleed image band --------------------------------------------- */

.band {
  position: relative;
  min-height: min(78svh, 46rem);
  display: grid;
  place-items: center;
  background: #23261f;
  color: #fff;
  overflow: hidden;
  text-align: center;
}

.band > img,
.band > .band__fill {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.band__fill {
  background:
    radial-gradient(120% 100% at 50% 100%, rgba(0,0,0,.5), transparent 65%),
    linear-gradient(#343829, #1d201a);
}

.band::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(12,14,11,.42);
}

.band__body {
  position: relative;
  z-index: 2;
  padding: var(--gutter);
  max-width: 46rem;
}

.band__body h2 { font-size: clamp(2.3rem, 5vw, 4.2rem); }

.band__body p {
  margin: 1.75rem auto 0;
  max-width: 40ch;
  font-size: clamp(1.1rem, 1.4vw, 1.3rem);
  color: rgba(255,255,255,.82);
}

/* ---- Scroll reveal ----------------------------------------------------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translate3d(0, 1.5rem, 0);
    transition: opacity .6s cubic-bezier(.22, .61, .36, 1),
                transform .6s cubic-bezier(.22, .61, .36, 1);
    will-change: opacity, transform;
  }
  .reveal.is-in {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
  /* Dropping will-change afterwards releases the compositor layer. */
  .reveal.is-done { will-change: auto; }
}

/* ---- Empty image slots -------------------------------------------------
   Until photographs land, every slot shows as a visible, labelled frame so
   the layout reads correctly. All of this disappears once an <img> is in. */

.frame:not(:has(img)) {
  background:
    repeating-linear-gradient(
      -45deg,
      rgba(141,115,70,.055) 0 12px,
      transparent 12px 24px
    ),
    #f0ede6;
  box-shadow: inset 0 0 0 1px var(--line);
  display: grid;
  place-items: center;
}

.frame:not(:has(img))::before {
  content: "";
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid rgba(141,115,70,.4);
  border-radius: 50%;
  background:
    linear-gradient(rgba(141,115,70,.35), rgba(141,115,70,.35)) center/1rem 1px no-repeat,
    linear-gradient(rgba(141,115,70,.35), rgba(141,115,70,.35)) center/1px 1rem no-repeat;
  margin-bottom: 2rem;
}

.frame:not(:has(img))::after {
  color: #8a8478;
  text-align: center;
}

/* Same treatment for the bands and the hero */
.band__fill,
.hero__media--empty {
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.12);
}

.band__fill::after,
.hero__media--empty::after {
  content: attr(data-shot);
  position: absolute;
  left: 50%;
  top: 2rem;
  transform: translateX(-50%);
  font-size: .7rem;
  letter-spacing: .18em;
  color: rgba(255,255,255,.4);
  z-index: 3;
}

/* ---- Hero crop ---------------------------------------------------------
   The hero photograph is portrait, so on wide screens it crops to a band.
   Focal point favours the house and sky over the pool, and the lower
   gradient is deepened because the lit pool is bright behind the type. */

.hero__media img,
.hero__media video { object-position: var(--hero-focal, 50% 40%); }

.hero::after {
  background: linear-gradient(to top,
    rgba(10,12,9,.82) 0%,
    rgba(10,12,9,.52) 30%,
    rgba(10,12,9,.18) 62%,
    rgba(10,12,9,.28) 100%);
}

/* ========================================================================
   Gallery
   Masonry columns. Each photograph keeps its own proportions, so nothing is
   cropped and nothing is stretched past its source resolution.
   ===================================================================== */

.grid {
  columns: 4;
  column-gap: clamp(.5rem, 1vw, 1rem);
  margin-top: clamp(3rem, 6vw, 5rem);
}

@media (max-width: 72rem) { .grid { columns: 3; } }
@media (max-width: 48rem) { .grid { columns: 2; } }
@media (max-width: 30rem) { .grid { columns: 1; } }

.tile {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #efece5;
  overflow: hidden;
  cursor: zoom-in;
  break-inside: avoid;
  margin: 0 0 clamp(.5rem, 1vw, 1rem);
  line-height: 0;
}

/* Natural height: no aspect-ratio, no cover crop. */
.tile img {
  width: 100%;
  height: auto;
  object-fit: fill;
  transform: translateZ(0);
  transition: transform .55s cubic-bezier(.22, .61, .36, 1);
}

.tile:hover img { transform: scale(1.03) translateZ(0); }
.tile[hidden] { display: none; }

.gallery-more {
  display: flex;
  justify-content: center;
  margin-top: clamp(2rem, 4vw, 3rem);
}

.gallery-count {
  margin-top: 1.25rem;
  text-align: center;
  font-size: .8125rem;
  letter-spacing: .12em;
  color: var(--ink-soft);
}

.btn--more {
  margin-top: 0;
  color: var(--ink);
  border-color: var(--ink);
}
.btn--more:hover { background: var(--ink); color: #fff; }

/* ---- Lightbox ---------------------------------------------------------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 12, 9, .96);
  display: none;
  place-items: center;
  padding: clamp(1rem, 4vw, 3rem);
}
.lightbox[open] { display: grid; }

.lightbox img {
  max-width: min(100%, 76rem);
  max-height: 84svh;
  width: auto;
  height: auto;
  object-fit: contain;
}

.lightbox__caption {
  position: absolute;
  bottom: clamp(1rem, 3vw, 2rem);
  left: 0; right: 0;
  text-align: center;
  color: rgba(255,255,255,.7);
  font-size: .875rem;
  letter-spacing: .08em;
}

.lightbox__close,
.lightbox__nav {
  position: absolute;
  background: none;
  border: 0;
  color: rgba(255,255,255,.75);
  font-size: 2rem;
  line-height: 1;
  padding: 1rem;
  cursor: pointer;
  transition: color .2s ease;
}
.lightbox__close:hover,
.lightbox__nav:hover { color: #fff; }

.lightbox__close { top: clamp(.5rem, 2vw, 1.5rem); right: clamp(.5rem, 2vw, 1.5rem); }
.lightbox__nav--prev { left: clamp(.25rem, 2vw, 1.5rem); top: 50%; transform: translateY(-50%); }
.lightbox__nav--next { right: clamp(.25rem, 2vw, 1.5rem); top: 50%; transform: translateY(-50%); }

/* ---- Split and band images now carry real photographs ------------------ */

.split .frame,
.band { background: #e9e6df; }

/* ========================================================================
   Navigation targets and the full gallery
   ===================================================================== */

/* The masthead is fixed, so anchored sections need clearance or their
   headings land underneath it. */
#house, #gallery, #location, #enquire { scroll-margin-top: 5.5rem; }

/* 144 photographs is a wall, so the grid opens at 24 and expands. */
.tile[hidden] { display: none; }

.gallery-more {
  display: flex;
  justify-content: center;
  margin-top: clamp(2rem, 4vw, 3rem);
}

.gallery-count {
  margin-top: 1.25rem;
  text-align: center;
  font-size: .8125rem;
  letter-spacing: .12em;
  color: var(--ink-soft);
}

.btn--more {
  margin-top: 0;
  color: var(--ink);
  border-color: var(--ink);
}
.btn--more:hover { background: var(--ink); color: #fff; }

/* Lightbox counter */
.lightbox__count {
  position: absolute;
  top: clamp(.5rem, 2vw, 1.5rem);
  left: 0; right: 0;
  text-align: center;
  color: rgba(255,255,255,.5);
  font-size: .8125rem;
  letter-spacing: .12em;
}

/* ---- Enquiry form extras ----------------------------------------------- */

/* Honeypot: off-screen rather than display:none, since some bots skip
   hidden fields but not positioned ones. */
.trap {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-errors {
  border-left: 3px solid #9d3f38;
  background: #f8ecea;
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
}
.form-errors p { margin: 0 0 .4rem; font-size: .9375rem; }
.form-errors p:last-child { margin: 0; }

.rooms-line {
  margin-top: clamp(2rem, 4vw, 3rem);
  font-size: 1.05rem;
  letter-spacing: .04em;
  color: var(--ink-soft);
  max-width: none;
}

.field input:invalid:not(:placeholder-shown) { border-bottom-color: #9d3f38; }

/* ========================================================================
   Responsive pass
   Checked at 320, 375, 414, 768, 1024, 1440 and 1920.
   ===================================================================== */

/* iOS needs an explicit 16px on inputs or it zooms the whole page on focus. */
@media (max-width: 48rem) {
  .field input,
  .field textarea { font-size: 16px; }
}

/* Small phones: the two-column date row is too tight side by side. */
@media (max-width: 26rem) {
  .dates { grid-template-columns: 1fr; gap: 0; }
  :root { --gutter: 1.25rem; }
  h1 { font-size: clamp(2.1rem, 11vw, 2.9rem); }
  .hero__sub { font-size: 1rem; }
  .btn { padding: .95rem 1.75rem; width: 100%; text-align: center; }
}

/* Distances stack rather than stretching across on narrow screens. */
@media (max-width: 34rem) {
  .distance { flex-direction: column; gap: .1rem; padding-block: 1.1rem; }
  .distance__place { font-size: 1.05rem; }
}

/* svh is not universal; dvh avoids the mobile browser chrome jump, with a
   plain vh fallback underneath for older devices. */
.hero { min-height: 100vh; }
@supports (height: 100dvh) { .hero { min-height: 100dvh; } }

/* Very wide screens: cap the measure so lines don't sprawl. */
@media (min-width: 110rem) {
  .wrap { width: min(100%, 96rem); }
  .grid { columns: 5; }
}

/* Landscape phones: a full-height hero leaves no room for anything else. */
@media (max-height: 30rem) and (orientation: landscape) {
  .hero { min-height: 34rem; }
  .hero__scroll { display: none; }
  .masthead__nav { font-size: 1.1rem; }
}

/* Lightbox on a phone: bigger tap targets, controls clear of the image. */
@media (max-width: 48rem) {
  .lightbox { padding: 3.5rem .5rem 4rem; }
  .lightbox img { max-height: 76svh; }
  .lightbox__close,
  .lightbox__nav { padding: 1.25rem; font-size: 2.4rem; }
  .lightbox__nav--prev { left: 0; }
  .lightbox__nav--next { right: 0; }
}

/* Tables of amenities collapse to one column on the narrowest screens. */
@media (max-width: 26rem) {
  .amenities { grid-template-columns: 1fr; gap: 2.25rem; }
  .plain { columns: 1; }
}

/* Nothing should ever cause a horizontal scrollbar. */
html, body { overflow-x: hidden; max-width: 100%; }
img, video, picture { max-width: 100%; }

/* Touch devices get no hover zoom - it sticks after a tap. */
@media (hover: none) {
  .tile:hover img { transform: none; }
}

/* ========================================================================
   Video
   ===================================================================== */

.videos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  margin-top: clamp(3rem, 6vw, 5rem);
}

.video {
  position: relative;
  background: #1b1c19;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.video iframe,
.video video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

.video__caption {
  margin-top: .85rem;
  font-size: .9375rem;
  color: var(--ink-soft);
}

/* Click-to-load poster for embeds: no third-party scripts and no tracking
   until the visitor actually asks for the video, which also keeps the page
   fast on a phone. */
.video__poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: #1b1c19;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.video__poster img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .75;
  transition: opacity .4s ease, transform 1.2s cubic-bezier(.2,.7,.3,1);
}
.video__poster:hover img { opacity: .9; transform: scale(1.03); }

.video__play {
  position: relative;
  z-index: 2;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 50%;
  background: rgba(255,255,255,.92);
  display: grid;
  place-items: center;
}

.video__play::after {
  content: "";
  border-left: 1.1rem solid var(--ink);
  border-top: .7rem solid transparent;
  border-bottom: .7rem solid transparent;
  margin-left: .3rem;
}

@media (hover: none) {
  .video__poster:hover img { transform: none; }
}

/* ========================================================================
   Gallery categories
   A row of thumbnail tabs above the grid, scrollable sideways on a phone.
   ===================================================================== */

.cats {
  display: flex;
  gap: clamp(.5rem, 1vw, .85rem);
  margin-top: clamp(2rem, 4vw, 3rem);
  padding-bottom: .75rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

/* Let the row run to the screen edge on a phone so it reads as scrollable. */
@media (max-width: 48rem) {
  .cats {
    margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter);
  }
}

.cat {
  position: relative;
  flex: 0 0 auto;
  width: clamp(7rem, 13vw, 9.5rem);
  aspect-ratio: 4 / 3;
  padding: 0;
  border: 0;
  background: #e9e6df;
  overflow: hidden;
  cursor: pointer;
  scroll-snap-align: start;
  outline-offset: 2px;
}

.cat img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Tint as a compositor-friendly overlay rather than a filter on the image. */
.cat::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(12, 14, 11, .45);
  transition: opacity .3s ease;
}
.cat:hover::before { opacity: .72; }

.cat__label {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  height: 100%;
  padding: .5rem;
  color: #fff;
  font-size: clamp(.75rem, 1vw, .875rem);
  letter-spacing: .04em;
  line-height: 1.25;
  text-align: center;
  text-shadow: 0 1px 6px rgba(0,0,0,.45);
}

.cat__count {
  display: block;
  margin-top: .2rem;
  font-size: .7rem;
  opacity: .78;
  letter-spacing: .1em;
}

/* Active tab: a solid rule underneath rather than a coloured border, which
   keeps the row calm when one is selected. */
.cat[aria-pressed="true"] {
  box-shadow: inset 0 0 0 2px var(--ink);
}
.cat[aria-pressed="true"]::before { background: rgba(12, 14, 11, .68); opacity: 1; }

@media (hover: none) {
  .cat:hover::before { opacity: 1; }
}

.gallery-count strong { font-weight: 600; color: var(--ink); }

/* ---- Contact ------------------------------------------------------------ */

.contact { margin-top: clamp(2.5rem, 5vw, 3.5rem); }

.contact__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.contact__list li {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem 1.5rem;
  align-items: baseline;
  padding-block: 1.1rem;
  border-bottom: 1px solid var(--line);
}

.contact__key {
  flex: 0 0 7rem;
  font-size: .8125rem;
  letter-spacing: .12em;
  color: var(--brass);
}

.contact__val { font-size: 1.15rem; }
.contact__val a { text-decoration: none; border-bottom: 1px solid var(--line); }
.contact__val a:hover { border-bottom-color: currentColor; }

.contact__note {
  margin-top: 1.5rem;
  font-size: .9375rem;
  color: var(--ink-soft);
}

@media (max-width: 34rem) {
  .contact__key { flex: 1 0 100%; }
}

/* Footer contact detail */
.footer__contact { margin-top: .5rem; }
.footer__contact a { display: block; padding-block: .2rem; }

/* ---- Rates -------------------------------------------------------------- */

.rates { margin-top: clamp(2.5rem, 5vw, 3.5rem); }

.rates__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.rate {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .25rem 1.5rem;
  align-items: baseline;
  padding-block: 1.25rem;
  border-bottom: 1px solid var(--line);
}

.rate__label {
  font-size: 1.15rem;
  font-family: var(--display);
}

.rate__note {
  grid-column: 1;
  font-size: .875rem;
  color: var(--ink-soft);
}

.rate__price {
  grid-row: 1;
  grid-column: 2;
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  font-family: var(--display);
  font-variant-numeric: tabular-nums;
}

.rate__each {
  grid-row: 2;
  grid-column: 2;
  font-size: .875rem;
  color: var(--brass);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.rates__foot {
  margin-top: 1.5rem;
  font-size: .9375rem;
  color: var(--ink-soft);
}

/* The headline figures a guest scans for, before the detail. */
.facts {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  margin-top: clamp(2rem, 4vw, 3rem);
  padding-block: 1.5rem;
  border-block: 1px solid var(--line);
}

.fact__num {
  display: block;
  font-family: var(--display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1;
}

.fact__label {
  display: block;
  margin-top: .45rem;
  font-size: .8125rem;
  letter-spacing: .12em;
  color: var(--ink-soft);
}

.section--dark .facts { border-color: rgba(255,255,255,.24); }
.section--dark .fact__label { color: rgba(255,255,255,.7); }

/* ========================================================================
   Contact, rebuilt
   The plain label/value list read as a data table. This gives the block
   presence: a tinted panel, icons, and WhatsApp promoted to a real button
   since it is the channel most guests will actually use.
   ===================================================================== */

.contact {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding: clamp(1.75rem, 3.5vw, 2.75rem);
  background: #fff;
  box-shadow: 0 0 0 1px var(--line);
}

.contact h3 {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  margin-bottom: .6rem;
}

.contact__intro {
  color: var(--ink-soft);
  margin-bottom: 2rem;
  font-size: 1rem;
}

.contact__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: .25rem;
}

.contact__list li { display: block; padding: 0; border: 0; }

.contact__row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: .9rem .75rem;
  margin-inline: -.75rem;
  text-decoration: none;
  border-radius: 2px;
  transition: background .2s ease;
}

a.contact__row:hover { background: #f4f2ec; }

.contact__icon {
  flex: 0 0 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #f1eee6;
  color: var(--brass);
}

.contact__icon svg { width: 1.15rem; height: 1.15rem; display: block; }

.contact__text { min-width: 0; }

.contact__key {
  display: block;
  font-size: .75rem;
  letter-spacing: .14em;
  color: var(--ink-soft);
  margin-bottom: .1rem;
}

.contact__val {
  display: block;
  font-size: 1.1rem;
  color: var(--ink);
  word-break: break-word;
}

/* WhatsApp gets its own weight, being the fastest route to a booking. */
.contact__wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .7rem;
  margin-top: 1.75rem;
  padding: 1.05rem 1.5rem;
  background: var(--sage);
  color: #fff;
  text-decoration: none;
  font-size: .9375rem;
  letter-spacing: .1em;
  transition: background .25s ease;
}
.contact__wa:hover { background: var(--ink); }
.contact__wa svg { width: 1.2rem; height: 1.2rem; }

.contact__note {
  margin-top: 1.25rem;
  font-size: .875rem;
  color: var(--ink-soft);
  text-align: center;
}

/* ---- Footer contact, tidied ------------------------------------------- */

.footer__contact {
  display: grid;
  gap: .1rem;
}

.footer__contact a {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding-block: .35rem;
  color: rgba(255,255,255,.85);
}
.footer__contact a:hover { color: #fff; }
.footer__contact svg { width: .95rem; height: .95rem; opacity: .7; }

/* ---- Portrait video ------------------------------------------------------
   The property tour is 9:16, shot on a phone. Forcing it into a 16:9 frame
   would crop most of the house out, so the frame follows the file and a
   single portrait video sits centred rather than stretching full width. */

.videos:has(.video[style*="608"]) {
  grid-template-columns: minmax(0, 26rem);
  justify-content: center;
}

.video[style*="aspect-ratio"] video { object-fit: contain; background: #14150f; }

@media (max-width: 34rem) {
  .videos { grid-template-columns: 1fr; }
  .videos:has(.video[style*="608"]) { grid-template-columns: 1fr; }
}

/* ---- Sleeping arrangements note ---------------------------------------
   Sits under the headline numbers. Being straight about what is and is not
   a real bed prevents a guest arriving with eight people and an argument. */

.facts__note {
  margin-top: 1.25rem;
  max-width: 56ch;
  font-size: .9375rem;
  line-height: 1.65;
  color: var(--ink-soft);
}
