/* ============================================================
   The Viewlands — Editorial marketing stylesheet
   Palette: charcoal #252525 · white #FFFFFF · navy #2E4159 · blush #D9CCC5
   ============================================================ */

:root {
  --charcoal: #252525;
  --white: #ffffff;
  --navy: #2e4159;
  --blush: #d9ccc5;
  --blush-deep: #c9b8ae;
  --muted: #6b6560;
  --line: rgba(37, 37, 37, 0.12);
  --line-light: rgba(255, 255, 255, 0.28);
  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;
  --nav-h: 4.5rem;
  --rail-w: 3.25rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --pad: clamp(1.25rem, 4vw, 3.5rem);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-h);
}

body {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--charcoal);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: opacity 0.25s var(--ease);
}

a:hover {
  opacity: 0.7;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 3px;
}

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul {
  list-style: none;
}

/* ---------- Typography ---------- */

.eyebrow {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 1rem;
}

.display {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.4rem, 5.5vw, 4.25rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--charcoal);
}

.display--dark {
  color: var(--charcoal);
}

.body-lg {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  line-height: 1.7;
  font-weight: 300;
  color: var(--charcoal);
  max-width: 36rem;
}

.body {
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--muted);
  max-width: 34rem;
}

.caption {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.9rem;
  color: var(--muted);
  margin-top: 0.75rem;
}

.disclaimer {
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-top: 2.5rem;
  opacity: 0.85;
}

.rule {
  width: 3rem;
  height: 1px;
  background: var(--charcoal);
  margin: 1.75rem 0;
  opacity: 0.35;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.6rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  touch-action: manipulation;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), opacity 0.3s var(--ease), transform 120ms cubic-bezier(0.23, 1, 0.32, 1);
}

.btn:hover {
  opacity: 1;
}

/* Press feedback: the interface heard the tap before anything else happens. */
.btn:active,
.nav__cta:active,
.nav__drawer-cta:active,
.link-plans:active {
  transform: scale(0.97);
}

.btn--light {
  background: var(--white);
  color: var(--charcoal);
}

.btn--light:hover {
  background: var(--blush);
}

.btn--ghost {
  background: transparent;
  color: var(--white);
  border: 1px solid var(--line-light);
}

.btn--ghost:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.btn--dark {
  background: var(--charcoal);
  color: var(--white);
  padding: 0.95rem 1.75rem;
}

.btn--dark:hover {
  background: var(--navy);
}

/* ---------- Loader ---------- */

/* ---------- Nav ---------- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: var(--rail-w);
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), box-shadow 0.25s;
  color: var(--white);
}

.nav.is-solid,
.nav.is-menu-open {
  background: rgba(255, 255, 255, 0.96);
  color: var(--charcoal);
  box-shadow: 0 1px 0 var(--line);
  backdrop-filter: blur(8px);
}

.nav:not(.is-solid):not(.is-menu-open) :focus-visible {
  outline-color: var(--white);
}

.nav__wordmark {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.nav__logo {
  text-decoration: none;
}

.nav__logo:hover {
  opacity: 1;
}

.nav__links {
  display: flex;
  gap: 2rem;
}

.nav__links a {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
}

.nav__cta {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.55rem 1rem;
  border: 1px solid currentColor;
  touch-action: manipulation;
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), transform 120ms cubic-bezier(0.23, 1, 0.32, 1);
}

.nav__cta:hover {
  opacity: 1;
  background: var(--charcoal);
  color: var(--white);
  border-color: var(--charcoal);
}

.nav.is-solid .nav__cta:hover {
  background: var(--charcoal);
  color: var(--white);
}

/* Hamburger: a 44px target around 28px of lines; the lines turn into a cross while open. */
.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  color: inherit;
  gap: 6px;
  box-sizing: content-box;
  width: 1.75rem;
  height: 1rem;
  padding: 0.9rem 0.5rem;
  margin: 0 -0.5rem;
  touch-action: manipulation;
}

.nav__toggle span {
  display: block;
  height: 1px;
  width: 100%;
  background: currentColor;
  transition: transform 220ms cubic-bezier(0.23, 1, 0.32, 1);
}

.nav__toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3.5px) rotate(45deg);
}

.nav__toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}

/* Drawer: fades and settles in from just above (@starting-style), leaves the same way, faster.
   Browsers without discrete display transitions simply cut, which is what they did before. */
.nav__drawer {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  z-index: 99;
  background: var(--white);
  display: flex;
  flex-direction: column;
  padding: 2.5rem var(--pad);
  gap: 1.5rem;
  opacity: 1;
  transform: none;
  transition: opacity 160ms cubic-bezier(0.23, 1, 0.32, 1), transform 160ms cubic-bezier(0.23, 1, 0.32, 1), display 160ms allow-discrete;
}

.nav__drawer[hidden] {
  display: none;
  opacity: 0;
  transform: translateY(-8px);
}

@starting-style {
  .nav__drawer:not([hidden]) {
    opacity: 0;
    transform: translateY(-8px);
  }
}

.nav__drawer a {
  font-family: var(--serif);
  font-size: 2rem;
  text-decoration: none;
  color: var(--charcoal);
  opacity: 1;
  transform: none;
  transition: opacity 240ms cubic-bezier(0.23, 1, 0.32, 1), transform 240ms cubic-bezier(0.23, 1, 0.32, 1);
}

/* Links arrive one after another on open only (no stagger on the way out). */
@starting-style {
  .nav__drawer:not([hidden]) a {
    opacity: 0;
    transform: translateY(8px);
  }
}

.nav__drawer a:nth-child(2) { transition-delay: 30ms; }
.nav__drawer a:nth-child(3) { transition-delay: 60ms; }
.nav__drawer a:nth-child(4) { transition-delay: 90ms; }
.nav__drawer a:nth-child(5) { transition-delay: 120ms; }
.nav__drawer a:nth-child(6) { transition-delay: 150ms; }
.nav__drawer a:nth-child(7) { transition-delay: 180ms; }

.nav__drawer-cta {
  margin-top: 1rem;
  font-family: var(--sans) !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.9rem 1.25rem;
  background: var(--charcoal);
  color: var(--white) !important;
  text-align: center;
  width: fit-content;
}

/* ---------- Scroll rail ---------- */

.rail {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: var(--rail-w);
  z-index: 110;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 0;
  pointer-events: none;
}

.rail__track {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 1.4rem;
  width: 1px;
  background: rgba(37, 37, 37, 0.12);
}

body:not(.scrolled) .rail__track {
  background: rgba(255, 255, 255, 0.25);
}

.rail__progress {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0%;
  background: var(--charcoal);
  transition: height 0.1s linear;
}

body:not(.scrolled) .rail__progress {
  background: var(--white);
}

.rail__chapters {
  margin-top: auto;
  margin-bottom: 3.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  align-items: center;
}

.rail__chapters li {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.45;
  transition: opacity 0.3s, color 0.3s;
}

.rail__chapters li.is-active {
  opacity: 1;
  color: var(--charcoal);
}

body:not(.scrolled) .rail__chapters li {
  color: rgba(255, 255, 255, 0.5);
}

body:not(.scrolled) .rail__chapters li.is-active {
  color: var(--white);
  opacity: 1;
}

.rail__pct {
  position: absolute;
  bottom: 1.25rem;
  right: 0.55rem;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--muted);
}

body:not(.scrolled) .rail__pct {
  color: rgba(255, 255, 255, 0.7);
}

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

.section {
  padding: clamp(4.5rem, 10vw, 8rem) var(--pad);
  padding-right: calc(var(--pad) + var(--rail-w));
}

.section__head {
  max-width: 40rem;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}

.section__head--row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
  max-width: none;
}

.section__lede {
  margin-top: 1.25rem;
}

/* ---------- Hero: introduction + "Elevated living." ----------
   A tall scroll track with a sticky full-screen stage. Scroll position drives scenes 1–4
   (js/hero.js, js/hero-config.js), which settle on the final sales hero; without JavaScript or with
   reduced motion the section is one screen showing that final hero. The final copy keeps its place in
   the layout throughout (so nothing moves when it appears) and stays in the accessibility tree. */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  color: var(--white);
  background: #161b19;
}

/* The track: one screen for the stage plus a step of scroll per scene change. Sized from <head>
   (html.hero-story) so anchor deep links land in the right place on first layout. */
.hero--track,
html.hero-story .hero {
  height: calc(100svh + (var(--hero-scenes, 5) - 1) * var(--hero-step, 85vh));
}

.hero__stage {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--nav-h) + 2rem) calc(var(--pad) + var(--rail-w)) clamp(2rem, 6vh, 3.75rem) var(--pad);
  overflow: hidden;
}

.hero--track .hero__stage,
html.hero-story .hero__stage {
  position: sticky;
  top: 0;
  min-height: 0;
  height: 100vh;
  height: 100dvh;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.hero__slide.is-current {
  opacity: 1;
}

/* Before js/hero.js takes over, stay dark rather than flash the final frame; the copy arrives with
   the first photo as one composed entrance. */
html.hero-story .hero__slide--final,
html.hero-story .hero__inner {
  opacity: 0;
}

.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--pos, 50% 40%);
}

/* On the track each photo fades up once decoded, so a late image arrives rather than pops. */
.hero--track .hero__img {
  opacity: 0;
  transition: opacity 900ms cubic-bezier(0.23, 1, 0.32, 1);
}

.hero--track .hero__slide.is-loaded .hero__img {
  opacity: 1;
}

@media (max-aspect-ratio: 2/3) {
  /* Phones use portrait crops cut around each subject. */
  .hero__img {
    object-position: 50% 50%;
  }
}

/* Targeted legibility: header scrim, left-to-right copy gradient, light foot for the controls. */
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 3; /* above the stacked slides, whatever order they fade in */
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(8, 14, 12, 0.66) 0, rgba(8, 14, 12, 0.3) 5rem, rgba(8, 14, 12, 0) 10rem),
    linear-gradient(90deg, rgba(8, 14, 12, 0.68) 0%, rgba(8, 14, 12, 0.42) 38%, rgba(8, 14, 12, 0.12) 72%, rgba(8, 14, 12, 0) 100%),
    linear-gradient(0deg, rgba(8, 14, 12, 0.66) 0, rgba(8, 14, 12, 0.3) 7rem, rgba(8, 14, 12, 0) 16rem);
}

.hero__inner {
  position: static;
  width: 100%;
  max-width: 40rem;
}

.hero__copy,
.hero__actions,
.hero__note {
  position: relative;
  z-index: 1;
}

/* Story caption and final copy share one cell; the cell is always sized for the final copy. */
.hero__copy {
  display: grid;
}

.hero__copy > * {
  grid-area: 1 / 1;
}

.hero__story {
  align-self: end;
  padding-bottom: 1.75rem;
}

.hero__story[hidden] {
  display: none;
}

/* During the story the final copy and its footnote are faded by scroll (inline opacity from
   js/hero.js); keep them out of the way should the script never arrive on a story visit. */
html.hero-story .hero__final,
html.hero-story .hero__note {
  opacity: 0;
}

html.hero-story .hero__secondary {
  visibility: hidden;
}

.hero__scene-title {
  max-width: 12.5em;
  text-wrap: balance;
  font-family: var(--serif);
  font-size: clamp(2.35rem, 6vw, 4.6rem);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.015em;
  text-shadow: 0 1px 18px rgba(8, 14, 12, 0.25);
}

.hero__scene-text {
  max-width: 30rem;
  text-wrap: pretty;
  margin-top: 1rem;
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  font-weight: 300;
  line-height: 1.55;
  text-shadow: 0 1px 10px rgba(8, 14, 12, 0.35);
}

.hero__br {
  display: none;
}

.hero__eyebrow {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}

.hero__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(3rem, 7.5vw, 5.5rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.hero__lede {
  max-width: 32rem;
  text-wrap: pretty;
  margin-bottom: 1rem;
  font-size: clamp(1rem, 1.4vw, 1.125rem);
  font-weight: 300;
  line-height: 1.6;
}

.hero__status {
  margin-bottom: 1.75rem;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.hero .btn {
  min-height: 3rem;
}

.hero__note {
  max-width: 32rem;
  margin-top: 1.1rem;
  font-size: 0.75rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.86);
}

/* Controls: their own row, reserved from the start whenever JavaScript runs. */
.hero__controls {
  display: none;
}

.js .hero__controls {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 2.75rem;
  margin-top: 1.4rem;
  text-shadow: 0 1px 6px rgba(8, 14, 12, 0.4);
}

.js .hero__controls[hidden] {
  display: none !important;
}

.hero__ctl {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.75rem;
  min-height: 2.75rem;
  color: var(--white);
  touch-action: manipulation;
  transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1), background-color 150ms ease;
}

.hero__ctl[hidden] {
  display: none;
}

.hero__play {
  width: 2.75rem;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
}

.hero__play .icon {
  width: 0.85rem;
  height: 0.85rem;
  fill: currentColor;
  stroke: none;
}

.hero__ctl:active {
  transform: scale(0.95);
}

.hero__pos {
  min-width: 2.75em;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
}

.hero__markers {
  display: flex;
  gap: 0.3rem;
}

.hero__marker {
  position: relative;
  width: 2.1rem;
  height: 2.75rem;
  touch-action: manipulation;
}

.hero__marker::before,
.hero__marker-fill {
  content: "";
  position: absolute;
  left: 0.15rem;
  right: 0.15rem;
  top: 50%;
  height: 2px;
  margin-top: -1px;
}

.hero__marker::before {
  background: rgba(255, 255, 255, 0.38);
}

.hero__marker-fill {
  background: var(--white);
  transform: scaleX(0);
  transform-origin: 0 50%;
}

.hero__skip {
  margin-left: 0.4rem;
  padding: 0 0.3rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.5);
  text-underline-offset: 0.35em;
}

.hero__controls[data-state="final"] .hero__markers,
.hero__controls[data-state="final"] .hero__pos {
  display: none;
}

.hero__controls[data-state="final"] .hero__skip {
  margin-left: 0;
}

.hero :focus-visible {
  outline-color: var(--white);
}

@media (hover: hover) and (pointer: fine) {
  .hero__play:hover {
    background: rgba(255, 255, 255, 0.12);
  }

  .hero__marker:hover::before {
    background: rgba(255, 255, 255, 0.7);
  }

  .hero__skip:hover {
    text-decoration-color: var(--white);
  }
}

@media (min-width: 721px) {
  .hero__br {
    display: inline;
  }
}

/* Wide screens: controls sit bottom-right, clear of the copy and the scroll rail. */
@media (min-width: 1180px) {
  .js .hero__controls {
    position: absolute;
    right: calc(var(--pad) + var(--rail-w));
    bottom: clamp(2rem, 6vh, 3.75rem);
    margin: 0;
    padding: 0 0.6rem 0 0;
    background: rgba(8, 14, 12, 0.34);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }

  .js .hero__controls[data-state="final"] {
    padding: 0 0.6rem;
  }
}

/* Phones: stronger foot scrim behind the full-width copy; the header protected separately. */
@media (max-width: 720px) {
  .hero__stage {
    padding: calc(var(--nav-h) + 1.5rem) var(--pad) calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }

  .hero__scrim {
    background:
      linear-gradient(180deg, rgba(8, 14, 12, 0.72) 0, rgba(8, 14, 12, 0.35) 4.5rem, rgba(8, 14, 12, 0) 8.5rem),
      linear-gradient(0deg, rgba(8, 14, 12, 0.9) 0%, rgba(8, 14, 12, 0.76) 38%, rgba(8, 14, 12, 0.32) 62%, rgba(8, 14, 12, 0) 80%),
      linear-gradient(90deg, rgba(8, 14, 12, 0.25) 0%, rgba(8, 14, 12, 0) 70%);
  }

  .hero__story {
    padding-bottom: 1.4rem;
  }

  .hero__status {
    margin-bottom: 1.4rem;
  }

  .hero__actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero__primary {
    align-self: stretch;
  }

  .js .hero__controls {
    gap: 0.35rem;
    margin-top: 1rem;
  }

  .hero__markers {
    flex: 1;
    gap: 0.15rem;
  }

  .hero__marker {
    flex: 1;
    width: auto;
    min-width: 1.6rem;
  }

  .hero__skip {
    margin-left: 0.2rem;
  }
}

/* ---------- Intro / Vision ---------- */

.intro__grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
}

.intro__copy .body-lg {
  margin-bottom: 1.25rem;
}

.intro__credit {
  margin-top: 1rem;
  font-size: 0.8rem;
}

.progress {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  background: #faf8f6;
  border: 1px solid var(--line);
  border-left: 2px solid var(--navy);
  max-width: 44rem;
}

.progress__title {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.8vw, 2.1rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
  margin-bottom: 0.6rem;
}

.progress__body {
  max-width: none;
  color: var(--charcoal);
  margin-bottom: 0.6rem;
}

.progress__note {
  font-size: 0.72rem;
  line-height: 1.55;
  color: var(--muted);
}

.intro__figure img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

/* ---------- Homes ---------- */

.homes {
  background: #faf8f6;
}

.typology {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
}

.typology__card {
  background: var(--white);
}

.typology__media {
  overflow: hidden;
}

.typology__media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  transition: transform 0.4s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
  .typology__card:hover .typology__media img {
    transform: scale(1.03);
  }
}

.typology__body {
  padding: 1.75rem 1.5rem 2rem;
  border-top: 1px solid var(--line);
}

.typology__tag {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

.typology__title {
  font-family: var(--sans);
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 0.35rem;
}

.typology__meta {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

.typology__intro {
  font-size: 0.92rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--charcoal);
  margin: -0.5rem 0 1.25rem;
}

.typology__list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 1rem;
}

.typology__list li {
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--charcoal);
  padding-left: 0.85rem;
  position: relative;
}

.typology__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 4px;
  height: 1px;
  background: var(--navy);
}

.homes__note {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.homes__note a {
  color: var(--navy);
}

/* ---------- Place ---------- */

.place__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.amenities {
  border-top: 1px solid var(--line);
}

.amenities li {
  display: grid;
  grid-template-columns: 7rem 1fr;
  gap: 1rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}

.amenities__label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
}

.amenities__item {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
}

/* ---------- Area guide (within Place) ---------- */

.area {
  margin-top: clamp(3.5rem, 8vw, 6rem);
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
}

.area [hidden] {
  display: none !important;
}

.area__title {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 3.5vw, 2.75rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
  margin-bottom: 1.5rem;
}

.area__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: clamp(1.75rem, 4vw, 2.5rem);
}

.area__filter {
  min-height: 2.75rem;
  padding: 0 1rem;
  border: 1px solid rgba(46, 65, 89, 0.35);
  background: var(--white);
  color: var(--navy);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease,
    transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}

.area__filter.is-active {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

.area__filter:active {
  transform: scale(0.97);
}

@media (hover: hover) and (pointer: fine) {
  .area__filter:not(.is-active):hover {
    border-color: var(--navy);
    background: rgba(46, 65, 89, 0.05);
  }
}

/* The list is a swipe surface on touch screens (js/area.js): we handle sideways, the browser keeps vertical. */
.area__places {
  touch-action: pan-y;
}

.area__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.75rem, 3vw, 2.5rem) clamp(1.25rem, 2.5vw, 2rem);
}

.area__group {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.area__media {
  margin: 0 0 1.1rem;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f1ede9;
}

.area__media img,
.area__regional-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.area__group-title {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 500;
  line-height: 1.15;
  color: var(--charcoal);
}

.area__near {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  margin-top: 0.3rem;
}

.area__list,
.area__regional-list {
  list-style: none;
  margin-top: 0.85rem;
  border-top: 1px solid var(--line);
}

.area__venue {
  display: grid;
  gap: 0.2rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--line);
}

.area__venue-name {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--charcoal);
}

.area__venue-text,
.area__venue-meta {
  font-size: 0.85rem;
  font-weight: 300;
  line-height: 1.55;
  color: var(--muted);
}

.area__travel {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
}

/* Single category: image beside a readable list */
.area__grid.is-single {
  grid-template-columns: minmax(0, 1fr);
}

.area__grid.is-single .area__group {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: start;
}

.area__grid.is-single .area__media {
  margin: 0;
  aspect-ratio: 4 / 3;
}

.area__grid.is-single .area__group-title {
  font-size: clamp(1.9rem, 3vw, 2.4rem);
}

.area__regional {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding: clamp(1.25rem, 3vw, 2rem);
  background: #faf8f6;
  border: 1px solid var(--line);
}

.area__regional-media {
  margin: 0;
  aspect-ratio: 3 / 2;
  overflow: hidden;
}

.area__regional-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 2rem;
}

@media (max-width: 1100px) {
  .area__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .area__grid,
  .area__grid.is-single .area__group,
  .area__regional,
  .area__regional-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .area__filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin-inline: calc(var(--pad) * -1);
    padding-inline: var(--pad);
    scrollbar-width: none;
  }

  .area__filter {
    flex: 0 0 auto;
  }
}

/* Icons (Lucide sprite) */
.icon {
  width: 1rem;
  height: 1rem;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.area__head-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin-bottom: 1.5rem;
}

.area__head-row .area__title {
  margin-bottom: 0;
}

.area__views {
  display: inline-flex;
  border: 1px solid var(--navy);
}

.area__view {
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1.15rem;
  color: var(--navy);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background-color 150ms ease, color 150ms ease, transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}

.area__view + .area__view {
  border-left: 1px solid var(--navy);
}

.area__view.is-active {
  background: var(--navy);
  color: var(--white);
}

.area__view:active {
  transform: scale(0.97);
}

.area__filter {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.area__filter .icon {
  width: 0.95rem;
  height: 0.95rem;
}

.area__group-title,
.area__regional-body .eyebrow {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.area__group-icon {
  width: 1.15rem;
  height: 1.15rem;
  color: var(--navy);
}

.area__venue-name {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
}

.area__venue-icon {
  width: 0.9rem;
  height: 0.9rem;
  margin-top: 0.18em;
  color: var(--navy);
}

.area__venue.is-selected {
  background: linear-gradient(90deg, rgba(217, 204, 197, 0.45), rgba(217, 204, 197, 0));
  box-shadow: inset 2px 0 0 var(--navy);
  padding-left: 0.6rem;
}

.area__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1rem;
}

.area__action {
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  text-decoration: underline;
  text-decoration-color: rgba(46, 65, 89, 0.3);
  text-underline-offset: 0.35em;
  transition: text-decoration-color 150ms ease;
}

.area__action .icon {
  width: 0.85rem;
  height: 0.85rem;
}

@media (hover: hover) and (pointer: fine) {
  .area__action:hover {
    text-decoration-color: var(--navy);
  }
}

.area__venue .area__actions {
  margin-top: -0.35rem;
  margin-bottom: -0.6rem;
}

/* Map view */
.area__map {
  display: grid;
  grid-template-columns: minmax(0, 1.85fr) minmax(0, 1fr);
  gap: clamp(1rem, 2vw, 1.5rem);
  align-items: stretch;
}

.area__map-frame {
  position: relative;
  height: clamp(26rem, 68vh, 40rem);
  background: #f4f0eb;
  border: 1px solid var(--line);
  overflow: hidden;
}

.area__map-frame .area__map-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.area__map-tools {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.area__tool {
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0 0.9rem;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(46, 65, 89, 0.25);
  box-shadow: 0 1px 3px rgba(37, 37, 37, 0.08);
  color: var(--navy);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background-color 150ms ease, color 150ms ease, transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}

.area__tool[aria-pressed="true"] {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.area__tool:active {
  transform: scale(0.97);
}

.area__map-status {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0.5rem;
  padding: 2rem;
  text-align: center;
  background: #f4f0eb;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--muted);
}

.area__panel {
  height: clamp(26rem, 68vh, 40rem);
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: #faf8f6;
  border: 1px solid var(--line);
}

.area__panel-list-wrap {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1;
}

.area__panel-title {
  padding: 1.1rem 1.25rem 0;
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--charcoal);
}

.area__panel-count {
  padding: 0.15rem 1.25rem 0.75rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.area__panel-list {
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;
  flex: 1;
  min-height: 0;
}

.area__panel-empty {
  padding: 1.25rem;
  font-family: var(--serif);
  font-style: italic;
  color: var(--muted);
}

.area__row {
  width: 100%;
  min-height: 3.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 1.25rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  transition: background-color 150ms ease;
}

.area__row.is-active {
  background: rgba(217, 204, 197, 0.5);
}

@media (hover: hover) and (pointer: fine) {
  .area__row:hover {
    background: rgba(217, 204, 197, 0.3);
  }
}

.area__row-icon,
.area__card-badge {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid rgba(46, 65, 89, 0.3);
  color: var(--navy);
}

.area__row-icon .icon {
  width: 0.95rem;
  height: 0.95rem;
}

.area__row-text {
  display: grid;
  gap: 0.1rem;
  min-width: 0;
}

.area__row-name {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--charcoal);
}

.area__row-cat {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.area__card {
  padding: 0.5rem 1.4rem 1.4rem;
  overflow-y: auto;
}

.area__card-badge {
  width: 3.25rem;
  height: 3.25rem;
  margin: 0.5rem 0 0.9rem;
  background: var(--blush);
  border-color: transparent;
}

.area__card-badge .icon {
  width: 1.45rem;
  height: 1.45rem;
  stroke-width: 1.5;
}

.area__card-cat {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.35rem;
}

.area__card-name {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.4vw, 2rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
  margin-bottom: 0.75rem;
}

.area__card-name:focus {
  outline: none;
}

.area__card-text {
  font-size: 0.92rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--charcoal);
  margin-bottom: 0.65rem;
}

.area__card-meta {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.area__card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.25rem;
  margin-top: 0.5rem;
  padding-top: 0.25rem;
  border-top: 1px solid var(--line);
}

/* Markers: 44px hit target, smaller visible symbol */
.pin {
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  padding: 0;
  cursor: pointer;
}

.pin[hidden],
.pin.is-clustered {
  display: none;
}

.pin__dot {
  width: 1.75rem;
  height: 1.75rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fffcf8;
  border: 1.5px solid var(--navy);
  color: var(--navy);
  box-shadow: 0 1px 3px rgba(37, 37, 37, 0.18);
  transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1), background-color 150ms ease, color 150ms ease,
    box-shadow 150ms ease;
}

.pin__dot .icon {
  width: 0.9rem;
  height: 0.9rem;
}

.pin.is-selected {
  z-index: 3;
}

.pin.is-selected .pin__dot {
  background: var(--navy);
  color: var(--white);
  box-shadow: 0 0 0 4px var(--blush), 0 2px 6px rgba(37, 37, 37, 0.25);
  transform: scale(1.12);
}

@media (hover: hover) and (pointer: fine) {
  .pin:not(.is-selected):hover .pin__dot {
    transform: scale(1.08);
  }
}

.pin:focus-visible {
  outline: none;
}

.pin:focus-visible .pin__dot {
  box-shadow: 0 0 0 3px var(--white), 0 0 0 5px var(--navy);
}

.pin--cluster .pin__dot {
  width: 2rem;
  height: 2rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 600;
  box-shadow: 0 0 0 3px rgba(255, 252, 248, 0.95), 0 1px 4px rgba(37, 37, 37, 0.25);
}

.pin--cluster {
  z-index: 1;
}

.is-far .pin__label {
  display: none;
}

.pin--home {
  z-index: 4;
  width: auto;
  grid-auto-flow: column;
  gap: 0.35rem;
  padding: 0 0.25rem;
}

.pin--home .pin__dot {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.35rem;
  background: var(--charcoal);
  border-color: var(--charcoal);
  color: var(--white);
  box-shadow: 0 0 0 3px #fffcf8, 0 2px 6px rgba(37, 37, 37, 0.3);
}

.pin--home .pin__dot .icon {
  width: 1.1rem;
  height: 1.1rem;
}

.pin--home.is-selected .pin__dot {
  box-shadow: 0 0 0 4px var(--blush), 0 2px 6px rgba(37, 37, 37, 0.3);
}

.pin__label {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 600;
  color: var(--charcoal);
  text-shadow: 0 0 3px #fffcf8, 0 0 3px #fffcf8, 0 0 6px #fffcf8;
  white-space: nowrap;
}

.area__map .maplibregl-ctrl-attrib {
  font-family: var(--sans);
  font-size: 0.66rem;
}

.area__map .maplibregl-cooperative-gesture-screen {
  font-family: var(--sans);
}

@media (max-width: 960px) {
  .area__map {
    grid-template-columns: minmax(0, 1fr);
  }

  .area__map-frame {
    height: clamp(22rem, 62vh, 32rem);
  }

  .area__panel {
    height: auto;
    max-height: 28rem;
  }
}

@media (max-width: 720px) {
  .area__head-row {
    align-items: stretch;
  }

  .area__views {
    width: 100%;
  }

  .area__view {
    flex: 1;
    justify-content: center;
  }

  .area__tool {
    padding: 0 0.7rem;
  }
}

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

.gallery__aside {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--muted);
  padding-bottom: 0.35rem;
}

.gallery__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1rem;
}

.gallery__item {
  overflow: hidden;
  background: #eee;
}

.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
  transition: transform 0.4s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
  .gallery__item:hover img {
    transform: scale(1.025);
  }
}

.gallery__item--wide img {
  aspect-ratio: 16 / 9;
}

.gallery__item--wide:nth-child(1) {
  grid-column: 1 / -1;
}

.gallery__item--wide:last-of-type {
  grid-column: 1 / -1;
}

/* ---------- Enquire ---------- */

.enquire {
  display: block;
  padding: 0;
  padding-right: var(--rail-w);
}

.enquire__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  min-height: 70vh;
}

.enquire__intro {
  padding: clamp(4rem, 8vw, 6.5rem) var(--pad);
  background: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.enquire__lede {
  margin-top: 1.5rem;
  margin-bottom: 2.5rem;
}

.enquire__facts {
  display: grid;
  gap: 1.25rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.enquire__facts p {
  font-size: 0.9rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.55;
}

.enquire__facts strong {
  font-family: var(--sans);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  display: block;
  margin-bottom: 0.35rem;
}

.enquire__panel {
  background: var(--blush);
  padding: clamp(3.5rem, 7vw, 5.5rem) clamp(1.75rem, 4vw, 3.5rem);
  display: flex;
  align-items: center;
}

/* ---------- Form ---------- */

.form {
  width: 100%;
  max-width: 28rem;
}

.form__row {
  margin-bottom: 1.75rem;
}

.form__hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form__row label {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--charcoal);
  margin-bottom: 0.55rem;
}

.form__row input,
.form__row select,
.form__row textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(37, 37, 37, 0.45);
  padding: 0.55rem 0;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 300;
  color: var(--charcoal);
  border-radius: 0;
  appearance: none;
  transition: border-color 0.25s;
}

.form__row textarea {
  resize: vertical;
  min-height: 4rem;
}

/* Focus thickens the underline to 2px (a shadow, so nothing shifts) instead of removing all cue. */
.form__row input:focus,
.form__row select:focus,
.form__row textarea:focus {
  outline: none;
  border-bottom-color: var(--charcoal);
  box-shadow: inset 0 -1px 0 var(--charcoal);
}

/* Only after the visitor has interacted with the field, never on first paint. */
.form.is-checked .form__row :invalid {
  border-bottom-color: #b4352f;
  box-shadow: inset 0 -1px 0 #b4352f;
}

.form.is-checked .form__row :invalid + .form__hint {
  opacity: 1;
  transform: none;
}

/* Kept as separate rules: a browser without :user-invalid drops the whole selector list. */
.form__row :user-invalid {
  border-bottom-color: #b4352f;
  box-shadow: inset 0 -1px 0 #b4352f;
}

.form__row :user-invalid + .form__hint {
  opacity: 1;
  transform: none;
}

.form__hint {
  margin-top: 0.4rem;
  font-size: 0.75rem;
  color: #b4352f;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 160ms cubic-bezier(0.23, 1, 0.32, 1), transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}

.form__row select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23252525' stroke-width='1' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.25rem center;
  padding-right: 1.5rem;
}

.form__success {
  margin-top: 1.5rem;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--navy);
  line-height: 1.5;
}

.form.is-sent .form__row,
.form.is-sent .btn {
  display: none;
}

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

.footer {
  background: var(--charcoal);
  color: var(--white);
  padding: 3.5rem var(--pad) 2rem;
  padding-right: calc(var(--pad) + var(--rail-w));
}

.footer__top {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.footer__logo {
  width: auto;
  height: 58px;
}

.footer__powered {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.footer__name {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.footer__addr {
  font-size: 0.85rem;
  font-weight: 300;
  opacity: 0.65;
}

.footer__meta {
  text-align: right;
  font-size: 0.8rem;
  font-weight: 300;
  opacity: 0.65;
  line-height: 1.7;
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  font-size: 0.75rem;
  opacity: 0.5;
}

.footer__top-link {
  flex-shrink: 0;
  margin-left: 1.25rem;
  white-space: nowrap;
  text-decoration: none;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.65rem;
  font-weight: 500;
}

/* ---------- Reveal motion ---------- */

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.45s var(--ease), transform 0.45s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

.reveal--item {
  transform: translateY(0.6rem);
  transition: opacity 260ms cubic-bezier(0.23, 1, 0.32, 1), transform 260ms cubic-bezier(0.23, 1, 0.32, 1);
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  :root {
    --rail-w: 0px;
  }

  .rail {
    display: none;
  }

  .nav {
    right: 0;
  }

  .intro__grid,
  .place__grid,
  .typology,
  .enquire__grid {
    grid-template-columns: 1fr;
  }

  .gallery__grid {
    grid-template-columns: 1fr 1fr;
  }

  .gallery__item--wide:nth-child(1),
  .gallery__item--wide:last-of-type {
    grid-column: 1 / -1;
  }

  .section__head--row {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer__meta {
    text-align: left;
  }

  .enquire {
    padding-right: 0;
  }

  .enquire__panel {
    min-height: auto;
  }
}

@media (max-width: 720px) {
  .nav__links,
  .nav__cta {
    display: none;
  }

  .nav__toggle {
    display: flex;
  }

  .typology {
    grid-template-columns: 1fr;
  }

  .gallery__grid {
    grid-template-columns: 1fr;
  }

  .amenities li {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .btn {
    text-align: center;
  }

  .typology__list {
    grid-template-columns: 1fr;
  }

  .footer__brand {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ---------- At a glance ---------- */

.glance {
  background: var(--charcoal);
  color: var(--white);
  padding: 1.35rem var(--pad);
  padding-right: calc(var(--pad) + var(--rail-w));
}

.glance__list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.25rem 2rem;
  max-width: 72rem;
  margin: 0 auto;
}

.glance__value {
  display: block;
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  font-weight: 500;
  letter-spacing: 0.01em;
  margin-bottom: 0.2rem;
}

.glance__label {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blush);
  opacity: 0.9;
}

.glance__note {
  max-width: 72rem;
  margin: 0.9rem auto 0;
  font-size: 0.66rem;
  letter-spacing: 0.02em;
  color: var(--blush);
  opacity: 0.8;
}

/* ---------- Spec strip & mini gallery ---------- */

.typology__media {
  position: relative;
}

.typology__status {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 1;
  pointer-events: none;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.94);
  color: var(--navy);
  padding: 0.45rem 0.75rem;
}

.spec-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 0 0 1.35rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.spec-strip li {
  flex: 1 1 auto;
  min-width: 4.5rem;
  text-align: center;
  padding: 0.25rem 0.35rem;
}

/* Phosphor Light glyphs (filled paths, 256 grid) from assets/icons/sprite.svg (`ph-*`). */
.spec-strip .icon {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
  margin: 0 auto 0.35rem;
  color: var(--navy);
  fill: currentColor;
  stroke: none;
}

.spec-strip span {
  display: block;
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.25rem;
}

.spec-strip strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--charcoal);
}

.mini-gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  margin: 1.5rem 0 1.25rem;
}

.mini-gallery figure {
  overflow: hidden;
  background: #eee;
}

.mini-gallery img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 0.4s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
  .mini-gallery figure:hover img {
    transform: scale(1.04);
  }
}

.mini-gallery figcaption {
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.4rem 0 0;
}

.typology__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 0.5rem;
}

.typology__cta .btn {
  padding: 0.75rem 1.25rem;
}

.link-plans {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  text-decoration: none;
  border-bottom: 1px solid rgba(46, 65, 89, 0.35);
  padding-bottom: 0.15rem;
  transition: border-color 0.25s var(--ease), transform 120ms cubic-bezier(0.23, 1, 0.32, 1);
}

.link-plans:hover {
  opacity: 1;
  border-bottom-color: var(--navy);
}

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

.gallery__item {
  position: relative;
}

.gallery__cap {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.88rem;
  color: var(--muted);
  margin-top: 0.65rem;
}

.gallery__grid {
  grid-template-columns: 1.2fr 1fr 1fr;
}

.gallery__item--wide:nth-child(1) {
  grid-column: 1 / -1;
}

.gallery__item--wide:nth-child(4) {
  grid-column: 1 / -1;
}

.gallery__item--wide:last-of-type {
  grid-column: 1 / -1;
}

/* ---------- FAQ ---------- */

.faq {
  background: #faf8f6;
}

.faq__list {
  max-width: 44rem;
}

.faq__item {
  border-top: 1px solid var(--line);
}

.faq__item:last-child {
  border-bottom: 1px solid var(--line);
}

.faq__item summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  font-weight: 500;
  padding: 1.35rem 2rem 1.35rem 0;
  position: relative;
  color: var(--charcoal);
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

.faq__item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--sans);
  font-size: 1.1rem;
  font-weight: 300;
  color: var(--navy);
}

.faq__item[open] summary::after {
  content: "–";
}

/* The answer settles in as it is revealed (opacity + 4px), rather than popping under the question. */
.faq__item p {
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.7;
  padding: 0 0 1.5rem;
  max-width: 36rem;
  opacity: 1;
  transform: none;
  transition: opacity 180ms cubic-bezier(0.23, 1, 0.32, 1), transform 180ms cubic-bezier(0.23, 1, 0.32, 1);
}

@starting-style {
  .faq__item[open] p {
    opacity: 0;
    transform: translateY(-4px);
  }
}

/* ---------- Form dual CTAs ---------- */

.form__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.btn--outline {
  background: transparent;
  color: var(--charcoal);
  border: 1px solid rgba(37, 37, 37, 0.45);
  padding: 0.9rem 1.4rem;
}

.btn--outline:hover {
  opacity: 1;
  border-color: var(--charcoal);
  background: rgba(37, 37, 37, 0.06);
}

.form.is-sent .form__actions {
  display: none;
}

/* ---------- Responsive additions ---------- */

@media (max-width: 960px) {
  .glance__list {
    grid-template-columns: 1fr 1fr;
  }

  .gallery__grid {
    grid-template-columns: 1fr 1fr;
  }

  .gallery__item--wide:nth-child(4) {
    grid-column: 1 / -1;
  }

  .mini-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .glance__list {
    grid-template-columns: 1fr 1fr;
    gap: 1.1rem;
  }

  .gallery__grid {
    grid-template-columns: 1fr;
  }

  .form__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .typology__cta {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ---------- Homes atlas (interactive unit picker) ---------- */

.atlas {
  background: var(--white);
  border-top: 1px solid var(--line);
}








.atlas__lot-tag {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.45rem;
}

.atlas__lot-no {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 4vw, 3.25rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--charcoal);
  margin-bottom: 0.5rem;
}

.atlas__pricing {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 1.15rem;
}

.atlas__specs {
  margin-bottom: 1.15rem;
}

.atlas__notes {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 1rem;
}

.atlas__notes li {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--charcoal);
  padding-left: 0.85rem;
  position: relative;
}

.atlas__notes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 4px;
  height: 1px;
  background: var(--navy);
}


.atlas__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}

.atlas__cta .btn {
  padding: 0.75rem 1.25rem;
}

.atlas__plan-frame {
  background: transparent;
  border: none;
  padding: 0;
}

.atlas__plan-frame svg {
  width: 100%;
  height: auto;
  display: block;
}

.atlas__plan-caption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem 1.5rem;
  margin-top: 0.85rem;
  font-family: var(--serif);
  font-size: 0.9rem;
  color: var(--muted);
}

.atlas__plan-key {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--sans);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-style: normal;
}

.atlas__key-swatch {
  display: inline-block;
  width: 0.85rem;
  height: 0.85rem;
  border: 1.5px solid var(--navy);
  vertical-align: middle;
}

.atlas__key-swatch--selected {
  background: var(--navy);
}

.atlas__key-swatch--outline {
  background: transparent;
  margin-left: 0.35rem;
}

.atlas__lot-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1.15rem;
}

.atlas__chip {
  min-width: 2.4rem;
  height: 2.4rem;
  padding: 0 0.65rem;
  border: 1px solid rgba(46, 65, 89, 0.35);
  color: var(--navy);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  background: var(--white);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.atlas__chip:hover {
  border-color: var(--navy);
  background: rgba(46, 65, 89, 0.06);
}

.atlas__chip.is-active {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

.atlas__chip:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}


@media (max-width: 720px) {
  .atlas__cta {
    flex-direction: column;
    align-items: flex-start;
  }

  .atlas__plan-caption {
    flex-direction: column;
    align-items: flex-start;
  }
}


/* SVG lot interaction (user site plan, restyled) */
.atlas__plan-frame .viewlands-siteplan {
  width: 100%;
  height: auto;
  display: block;
}
.atlas__plan-frame .sp-drive {
  fill: #d9ccc5;
  opacity: 0.72;
}
.atlas__plan-frame .sp-drive-label {
  fill: #2e4159;
  font-family: var(--sans);
  font-size: 9.94px;
  font-weight: 500;
  letter-spacing: 0.12em;
  pointer-events: none;
}
.atlas__plan-frame .sp-bldg {
  pointer-events: none;
}
.atlas__plan-frame .sp-bldg rect {
  fill: none;
  stroke: #252525;
  stroke-width: 1.35;
  opacity: 0.7;
  transition: stroke 0.25s var(--ease), opacity 0.25s var(--ease);
}
.atlas__plan-frame .sp-bldg.is-selected rect {
  stroke: #ffffff;
  opacity: 1;
  stroke-width: 1.6;
}
.atlas__plan-frame .sp-boundary {
  fill: none;
  stroke: #252525;
  stroke-width: 2.5;
  stroke-miterlimit: 10;
  pointer-events: none;
}
.atlas__plan-frame .sp-street {
  fill: #2e4159;
  opacity: 0.18;
  pointer-events: none;
}
.atlas__plan-frame .sp-street-label {
  fill: #2e4159;
  font-family: var(--sans);
  font-size: 9.94px;
  font-weight: 500;
  letter-spacing: 0.08em;
  pointer-events: none;
}
.atlas__plan-frame .sp-lot {
  fill: rgba(217, 204, 197, 0.35);
  stroke: #2e4159;
  stroke-width: 1.25;
  cursor: pointer;
  transition: fill 0.25s var(--ease), stroke 0.25s var(--ease), stroke-width 0.25s var(--ease);
}
.atlas__plan-frame .sp-lot:hover,
.atlas__plan-frame .sp-lot:focus {
  fill: rgba(46, 65, 89, 0.22);
  stroke: #252525;
  stroke-width: 1.75;
  outline: none;
}
.atlas__plan-frame .sp-lot:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 3px;
}
.atlas__plan-frame .sp-lot.is-selected {
  fill: #2e4159;
  stroke: #2e4159;
  stroke-width: 1.75;
}
.atlas__plan-frame .sp-lot.is-selected:hover {
  fill: #252525;
  stroke: #252525;
}
.atlas__plan-frame .sp-label {
  font-family: var(--sans);
  font-size: 9.94px;
  font-weight: 600;
  fill: #2e4159;
  pointer-events: none;
  letter-spacing: 0.04em;
}
.atlas__plan-frame .sp-label-on-selected {
  fill: #ffffff;
}

/* Phones scale the plan to ~40%: "LOT 8" at 10 units becomes 4px. Show just the number, larger. */
@media (max-width: 720px) {
  .atlas__plan-frame .sp-label {
    font-size: 26px;
    font-weight: 500;
    letter-spacing: 0;
  }

  .atlas__plan-frame .sp-label-word {
    display: none;
  }

  .atlas__plan-frame .sp-drive-label,
  .atlas__plan-frame .sp-street-label {
    font-size: 14px;
  }
}

/* ---------- Homes explorer (site → lot → floor → room → view) ---------- */

.explorer {
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --panel: #faf8f6;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.9fr);
  gap: clamp(1.5rem, 3.5vw, 3rem);
  align-items: start;
}

.explorer[data-mode="site"] {
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 0.75fr);
}

.explorer [hidden] {
  display: none !important;
}

.explorer__workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "site site";
  gap: 1.25rem 1.75rem;
  align-items: start;
  min-width: 0;
}

.explorer:not([data-mode="site"]) .explorer__workspace {
  grid-template-columns: auto auto minmax(0, 1fr);
  grid-template-areas:
    "site trail ."
    "bar bar bar"
    "stage stage stage"
    "rooms rooms rooms";
}

.explorer__site {
  grid-area: site;
  min-width: 0;
}

.explorer:not([data-mode="site"]) .explorer__site {
  width: clamp(18rem, 28vw, 24rem);
}

.explorer:not([data-mode="site"]) .atlas__plan-caption,
.explorer:not([data-mode="site"]) .atlas__lot-nav,
.explorer[data-mode="site"] .explorer__site-cap {
  display: none;
}

.atlas__chip {
  min-height: 2.75rem;
  min-width: 2.75rem;
}

/* Image breadcrumb: site plan (home) › all-floors plan (floor) */
.explorer__site-cap {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.25rem 1rem;
  margin-top: 0.55rem;
}

.explorer__trail-cap {
  display: grid;
  gap: 0.1rem;
  text-align: left;
}

.explorer__trail-title {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
  line-height: 1.15;
  color: var(--charcoal);
}

.explorer__trail-sub {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.explorer__site-cap .explorer__link {
  min-height: auto;
  padding-top: 0.2rem;
}

.explorer__trail-floors {
  grid-area: trail;
  position: relative;
  display: grid;
  gap: 0.55rem;
  margin-left: 1.75rem;
  padding: 0;
  text-align: left;
}

.explorer__trail-floors::before {
  content: "";
  position: absolute;
  left: -1.3rem;
  top: 3.3rem;
  width: 0.5rem;
  height: 0.5rem;
  border-top: 1.5px solid var(--muted);
  border-right: 1.5px solid var(--muted);
  transform: rotate(45deg);
  opacity: 0.6;
}

.explorer__trail-thumb {
  position: relative;
  display: block;
  height: 7.25rem;
  aspect-ratio: 2000 / 1414;
  background: var(--panel);
  border: 1px solid var(--line);
  transition: border-color 150ms ease, transform 160ms var(--ease-out);
}

.explorer__trail-thumb img,
.explorer__trail-hot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.explorer__trail-thumb img {
  object-fit: contain;
}

.explorer__trail-hot polygon {
  fill: transparent;
  stroke: transparent;
}

.explorer__trail-hot polygon.is-current {
  fill: rgba(46, 65, 89, 0.16);
  stroke: var(--navy);
  stroke-width: 1.5;
}

.explorer__trail-floors:active .explorer__trail-thumb {
  transform: scale(0.98);
}

@media (hover: hover) and (pointer: fine) {
  .explorer__trail-floors:hover .explorer__trail-thumb {
    border-color: var(--navy);
  }

  .explorer__trail-floors:hover .explorer__trail-title {
    text-decoration: underline;
    text-decoration-color: rgba(46, 65, 89, 0.35);
    text-underline-offset: 0.3em;
  }
}

/* Step prompt + floor selector */
.explorer__bar {
  grid-area: bar;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  min-width: 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}

.explorer__step {
  display: grid;
  gap: 0.3rem;
}

.explorer__step-no {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
}

.explorer__step-text {
  font-family: var(--serif);
  font-size: clamp(1.45rem, 2.4vw, 1.9rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
}

.explorer__floors {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

/* Floor names: "Lower" / "Mid" / "Upper" lead; "floor" sits beneath in a smaller, lighter line. */
.floor-name {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  line-height: 1;
}

.floor-name__main {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.floor-name__sub {
  font-size: 0.52rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  opacity: 0.7;
}

.explorer__floor,
.explorer__room,
.explorer__thumb,
.atlas__chip {
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease, opacity 150ms ease,
    transform 160ms var(--ease-out);
}

.explorer__floor {
  min-height: 2.75rem;
  padding: 0 1rem;
  border: 1px solid rgba(46, 65, 89, 0.35);
  background: var(--white);
  color: var(--navy);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.explorer__floor.is-active,
.explorer__room.is-active {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

.explorer__floor:active,
.explorer__room:active,
.explorer__thumb:active,
.atlas__chip:active {
  transform: scale(0.97);
}

@media (hover: hover) and (pointer: fine) {
  .explorer__floor:not(.is-active):hover,
  .explorer__room:not(.is-active):hover {
    border-color: var(--navy);
    background: rgba(46, 65, 89, 0.05);
  }

  .explorer__hotspot:hover {
    fill: rgba(46, 65, 89, 0.08);
    stroke: rgba(46, 65, 89, 0.6);
    stroke-dasharray: none;
  }

  .explorer__thumb:not(.is-active):hover {
    opacity: 1;
  }
}

/* Stage: overview / floor plan */

.explorer__stage {
  grid-area: stage;
  min-width: 0;
}

.explorer__plan {
  margin: 0;
}

/* The plan is zoomed to its drawn area (the asset's contentBox): the inner layer keeps the full
   canvas, so the hotspots still line up, and is offset/scaled by the box. */
.explorer__plan-box {
  --ratio: 1.414;
  --bx: 0;
  --by: 0;
  --bw: 1;
  --bh: 1;
  position: relative;
  aspect-ratio: var(--ratio);
  width: min(100%, calc(72vh * var(--ratio)));
  margin-inline: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  overflow: hidden;
}

.explorer__plan-inner {
  position: absolute;
  left: calc(var(--bx) / var(--bw) * -100%);
  top: calc(var(--by) / var(--bh) * -100%);
  width: calc(100% / var(--bw));
  height: calc(100% / var(--bh));
}

.explorer__plan-img,
.explorer__view-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 180ms var(--ease-out);
}

.explorer__plan-img {
  object-fit: fill;
}

/* The interior view fills its frame (no letterbox). Whatever is cropped is revealed by scrolling:
   js/explorer.js sets --view-pan (0% → 100%) as the frame travels up the screen, sliding a tall photo
   top → bottom and a wide one left → right. Opening it shows the whole picture. */
.explorer__view-img {
  object-fit: cover;
  object-position: var(--view-pan, 50%) var(--view-pan, 50%);
}

/* Colour-way mood boards are shown whole on their own paper colour: no crop, no scroll pan. */
.explorer__view-frame.is-board {
  background: #f7f5f2;
}

.explorer__view-frame.is-board .explorer__view-img {
  object-fit: contain;
  object-position: 50% 50%;
}

.is-loading .explorer__plan-img,
.is-loading > .explorer__view-img {
  opacity: 0;
  transition: none;
}

.explorer__hotspots {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.explorer__hotspot {
  fill: rgba(46, 65, 89, 0);
  stroke: rgba(46, 65, 89, 0.28);
  stroke-width: 1.25;
  stroke-dasharray: 4 3;
  cursor: pointer;
  transition: fill 150ms ease, stroke 150ms ease;
}

.explorer__hotspot.is-selected {
  fill: rgba(46, 65, 89, 0.16);
  stroke: var(--navy);
  stroke-width: 2;
  stroke-dasharray: none;
}

.explorer__plan-cap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.25rem 1.5rem;
  margin-top: 0.5rem;
  font-family: var(--serif);
  font-size: 0.9rem;
  color: var(--muted);
}

.explorer__link {
  min-height: 2.75rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  text-decoration: underline;
  text-decoration-color: rgba(46, 65, 89, 0.35);
  text-underline-offset: 0.35em;
}

.explorer__soon {
  padding: clamp(2rem, 5vw, 3.5rem);
  background: var(--panel);
  border: 1px solid var(--line);
}

.explorer__soon-title,
.explorer__intro-title {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
  margin-bottom: 0.85rem;
}

/* Room list */

.explorer__rooms {
  grid-area: rooms;
}

.explorer__label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.6rem;
}

.explorer__rooms-head {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.explorer__rooms-head .explorer__label {
  margin-bottom: 0;
}

.explorer__rooms-current {
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--charcoal);
}

.explorer__rooms-current::before {
  content: "·";
  margin-right: 0.5rem;
  color: var(--muted);
}

/* The list toggle only exists on the phone layout. */
.explorer__rooms-toggle {
  display: none;
}

@media (max-width: 960px) {
  .explorer__rooms-toggle {
    display: inline-flex;
    align-items: center;
    min-height: 2.75rem;
    margin: -0.9rem 0 -0.9rem auto;
    font-size: 0.62rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--navy);
    text-decoration: underline;
    text-decoration-color: rgba(46, 65, 89, 0.35);
    text-underline-offset: 0.35em;
    touch-action: manipulation;
  }

  .explorer__rooms.is-collapsed .explorer__rooms-head {
    margin-bottom: 0;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid var(--line);
  }
}

.explorer__room-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
  gap: 0.45rem;
}

.explorer__room {
  width: 100%;
  min-height: 2.75rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--charcoal);
  text-align: left;
}

.explorer__room-name {
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.15;
}

.explorer__room-meta {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.explorer__room.is-active .explorer__room-meta {
  color: rgba(255, 255, 255, 0.75);
}

/* Side: intro, view, facts */

.explorer__side {
  display: grid;
  gap: 1.25rem;
  min-width: 0;
}

.explorer__intro {
  padding: clamp(1.5rem, 3vw, 2.25rem);
  background: var(--panel);
  border: 1px solid var(--line);
}

.explorer__view-frame {
  position: relative;
  aspect-ratio: 3 / 2;
  background: #f1ede9;
  overflow: hidden;
}

.explorer__view-open {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: zoom-in;
}

.explorer__view-open:focus-visible {
  outline-offset: -4px;
}

.explorer__view-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 2rem;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--muted);
}

.explorer__view-loading {
  position: absolute;
  left: 1rem;
  top: 1rem;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
}

.is-loading > .explorer__view-loading {
  opacity: 1;
  transition-delay: 150ms;
}

/* Swipe surfaces: the browser keeps vertical scroll and pinch-zoom; horizontal drags are ours. */
.explorer__plan-box,
.explorer__view-frame {
  touch-action: pan-y pinch-zoom;
}

/* Prev/next on the interior view: a plain arrow within an area; names the destination when the
   step moves to another area or floor. */
.explorer__nav-btn {
  position: absolute;
  bottom: 0.6rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  max-width: calc(50% - 0.9rem);
  min-width: 2.75rem;
  height: 2.75rem;
  padding: 0 0.85rem;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  backdrop-filter: blur(12px) saturate(160%);
  box-shadow: 0 1px 3px rgba(37, 37, 37, 0.14);
  color: var(--navy);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: transform 160ms var(--ease-out), background-color 150ms ease;
}

.explorer__nav-btn:not(.has-label) {
  padding: 0;
}

.explorer__dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1.85rem;
  z-index: 1;
}

@media (max-width: 960px) {
  /* Phones: dots and swipe replace the thumbnail strip. */
  .explorer__view .explorer__thumbs {
    display: none;
  }
}

.explorer__nav-btn.is-prev {
  left: 0.6rem;
}

.explorer__nav-btn.is-next {
  right: 0.6rem;
}

.explorer__nav-btn.is-next .icon {
  transform: rotate(180deg);
}

.explorer__nav-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.explorer__nav-label:empty {
  display: none;
}

.explorer__nav-btn:active {
  transform: scale(0.95);
}

@media (hover: hover) and (pointer: fine) {
  .explorer__nav-btn:hover {
    background: var(--white);
  }
}

@media (prefers-reduced-transparency: reduce) {
  .explorer__nav-btn,
  .explorer__floorbar {
    background: var(--white) !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
}

/* Wayfinding bar (phone layout only): back one step + floors as a segmented control. */
.explorer__floorbar {
  display: none;
}

.explorer__back {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0 0.5rem 0 0;
  color: var(--navy);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: transform 160ms var(--ease-out);
}

.explorer__back:active {
  transform: scale(0.96);
}

.explorer__seg {
  --count: 3;
  position: relative;
  flex: 1;
  min-width: 0;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  padding: 3px;
  background: rgba(46, 65, 89, 0.08);
}

.explorer__seg-thumb {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 3px;
  width: calc((100% - 6px) / var(--count));
  background: var(--navy);
  transition: transform 280ms var(--ease-out), opacity 180ms ease;
  will-change: transform;
}

.explorer__seg-btn {
  position: relative;
  z-index: 1;
  min-width: 0;
  min-height: 2.6rem;
  padding: 0 0.25rem;
  color: var(--navy);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: color 200ms ease;
}

.explorer__seg-btn.is-active {
  color: var(--white);
}

.explorer__view-cap {
  margin-top: 0.65rem;
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.explorer__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.75rem;
}

.explorer__thumb {
  width: 4.75rem;
  aspect-ratio: 3 / 2;
  min-height: 2.75rem;
  padding: 0;
  border: 1.5px solid transparent;
  opacity: 0.72;
  overflow: hidden;
  background: #f1ede9;
}

.explorer__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.explorer__thumb.is-active {
  border-color: var(--navy);
  opacity: 1;
}

.explorer__facts {
  padding: 1.25rem 1.5rem 1.5rem;
  background: var(--panel);
  border: 1px solid var(--line);
}

.explorer__facts-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 1rem;
}

.explorer__facts .atlas__lot-no {
  font-size: clamp(2rem, 3vw, 2.6rem);
}

.explorer__facts .atlas__pricing {
  margin-bottom: 0.5rem;
}

.explorer__status {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 1rem;
}

@media (min-width: 961px) {
  .explorer:not([data-mode="site"]) .explorer__side {
    position: sticky;
    top: calc(var(--nav-h) + 1rem);
  }
}

@media (max-width: 960px) {
  .explorer,
  .explorer[data-mode="site"] {
    grid-template-columns: minmax(0, 1fr);
  }

  .explorer__workspace,
  .explorer:not([data-mode="site"]) .explorer__workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .explorer:not([data-mode="site"]) .explorer__workspace {
    grid-template-areas:
      "site"
      "trail"
      "bar"
      "floorbar"
      "stage"
      "rooms";
  }

  /* The sticky floor bar replaces the inline floor buttons on phones. */
  .explorer__floors {
    display: none;
  }

  .explorer__floorbar:not([hidden]) {
    grid-area: floorbar;
    position: sticky;
    top: var(--nav-h);
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin: -0.5rem calc(var(--pad) * -1) 0;
    padding: 0.4rem var(--pad);
    background: rgba(255, 255, 255, 0.86);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    backdrop-filter: blur(16px) saturate(160%);
    box-shadow: 0 1px 0 var(--line);
  }

  .explorer:not([data-mode="site"]) .explorer__site {
    width: 100%;
  }

  .explorer__trail-floors {
    grid-auto-flow: column;
    justify-content: start;
    align-items: center;
    gap: 0.85rem;
    margin-left: 0;
  }

  .explorer__trail-floors::before {
    display: none;
  }

  .explorer__trail-thumb {
    height: 4.5rem;
  }

  .explorer__plan-box {
    width: 100%;
  }

  /* Compact area buttons: name and view count on one line, so the plan and list share the screen. */
  .explorer__room-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .explorer__room {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.3rem 0.7rem;
  }

  .explorer__room-name {
    min-width: 0;
    font-size: 1.05rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .explorer__room-meta {
    flex: none;
    letter-spacing: 0.08em;
  }
}

@media (max-width: 359px) {
  /* Very narrow phones: the back button keeps its arrow and accessible name only. */
  #explorerBackLabel {
    display: none;
  }
}

/* ---------- Gallery click affordance ---------- */

.is-gallery {
  cursor: pointer;
}

.is-gallery:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 3px;
}

.intro__figure .is-gallery,
.typology__media .is-gallery,
.mini-gallery .is-gallery,
.gallery__item .is-gallery {
  transition: transform 0.4s var(--ease), opacity 0.35s var(--ease), filter 0.35s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
  .intro__figure:hover .is-gallery,
  .typology__media:hover .is-gallery,
  .mini-gallery figure:hover .is-gallery,
  .gallery__item:hover .is-gallery {
    filter: brightness(1.03);
  }
}

/* Subtle zoom cue on hover for series thumbs */
.mini-gallery figure,
.gallery__item,
.intro__figure {
  position: relative;
}

.mini-gallery .is-gallery::after,
.gallery__item .is-gallery::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 0 transparent;
  transition: box-shadow 0.3s var(--ease);
}

.mini-gallery figure:hover .is-gallery,
.gallery__item:hover .is-gallery {
  cursor: zoom-in;
}

/* Components below set their own display; the hidden attribute must still win. */
.typology__tour[hidden],
.tour__end[hidden],
.tour__nav[hidden],
.tour__img[hidden],
.tour__overlay[hidden],
.tour__dots[hidden],
.tour__blurb[hidden],
.tour__fin-btn[hidden],
.tour__finishes[hidden],
.tour__about-text[hidden],
.tour__sheet[hidden],
.tour__sheet-scrim[hidden],
.explorer__dots[hidden],
.explorer__nav-btn[hidden],
.explorer__rooms-current[hidden] {
  display: none !important;
}

/* ---------- Typology: start tour ---------- */

.typology__tag-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.typology__tag-row .typology__tag {
  margin-bottom: 0;
}

.typology__tour {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0 1.05rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  touch-action: manipulation;
  transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1), background-color 150ms ease;
}

.typology__tour .icon {
  width: 0.8rem;
  height: 0.8rem;
  fill: currentColor;
}

.typology__tour:active:not(:disabled) {
  transform: scale(0.97);
}

.typology__tour:disabled {
  background: transparent;
  color: var(--muted);
  box-shadow: inset 0 0 0 1px var(--line);
  cursor: default;
}

.typology__tour:disabled .icon {
  display: none;
}

@media (hover: hover) and (pointer: fine) {
  .typology__tour:not(:disabled):hover {
    background: var(--charcoal);
  }
}

/* ---------- Guided tour ----------
   Phones: one screen, no scrolling. Dark photo on top (the contrast switch on entering), the
   area blurb over its foot on a soft vignette, and a light full-bleed guide panel with the floor
   plan below. Wide screens: dark photo column + white sidebar (brand, plan, blurb, finishes). */

body.tour-open {
  overflow: hidden;
}

.tour {
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --tour-dark: #1e1e1e;
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr) auto;
  grid-template-areas: "progress" "main" "guide";
  background: var(--tour-dark);
  color: var(--white);
}

.tour[hidden] {
  display: none !important;
}

.tour__progress {
  grid-area: progress;
  height: 2px;
  margin-top: env(safe-area-inset-top, 0px);
  background: rgba(255, 255, 255, 0.14);
}

.tour__progress-bar {
  display: block;
  height: 100%;
  background: var(--blush);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 260ms var(--ease-out);
}

.tour__main {
  grid-area: main;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
}

.tour__head {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.7rem calc(var(--pad) + 3.25rem) 0.7rem var(--pad);
}

.tour__heading {
  flex: 1;
  min-width: 0;
}

.tour__eyebrow {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tour__where {
  margin-top: 0.15rem;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tour__count {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.7);
}

.tour__close {
  position: absolute;
  top: calc(env(safe-area-inset-top, 0px) + 0.75rem);
  right: var(--pad);
  z-index: 3;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  color: var(--white);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  touch-action: manipulation;
  transition: transform 160ms var(--ease-out), background-color 150ms ease;
}

.tour__close .icon {
  width: 1.15rem;
  height: 1.15rem;
}

.tour__close:active {
  transform: scale(0.95);
}

.tour__stage {
  position: relative;
  min-height: 0;
  overflow: hidden;
  touch-action: pan-y pinch-zoom;
}

.tour__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: 50% 100%;
  transition: opacity 180ms var(--ease-out);
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
}

.tour__stage.is-loading > .tour__img {
  opacity: 0;
  transition: none;
}

/* Phones, "look around": the photo fills the stage (sized inline by js/explorer.js to cover it) and
   is panned by the phone's tilt, or drifts slowly when there is no motion data. transform only. */
.tour[data-fit="fill"] .tour__img {
  inset: auto;
  max-width: none; /* the inline cover size is wider than the stage on purpose */
  will-change: transform;
}

/* The finger moves the photo in every direction (js/swipe.js pan) and up / down closes full screen,
   so the browser gets no pans here. */
.tour[data-fit="fill"] .tour__stage,
.tour--immersive .tour__stage,
.lightbox.is-screen .lightbox__frame,
.lightbox.is-screen .lightbox__img {
  touch-action: none;
}

.tour[data-fit="fill"] .tour__ambient {
  display: none;
}

/* A mood board is read, not explored: whole, centred above the caption, on a quiet backdrop. */
.tour--board .tour__img {
  object-position: 50% 38%;
}

.tour--board .tour__ambient {
  opacity: 0.25;
}

/* Immersive: a tap on the picture clears everything away; the stage becomes the whole screen. */
.tour--immersive .tour__progress,
.tour--immersive .tour__head,
.tour--immersive .tour__overlay,
.tour--immersive .tour__guide,
.tour--immersive .tour__nav,
.tour--immersive .tour__close {
  display: none;
}

.tour--immersive .tour__main {
  grid-template-rows: minmax(0, 1fr);
}

.tour--immersive .tour__img {
  object-position: 50% 50%; /* no caption to clear: the whole image sits centred */
}

.tour__immersive-bar {
  position: absolute;
  left: var(--pad);
  right: var(--pad);
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  opacity: 1;
  transform: none;
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out), display 200ms allow-discrete;
}

.tour__immersive-bar[hidden] {
  display: none;
  opacity: 0;
  transform: translateY(8px);
}

@starting-style {
  .tour__immersive-bar:not([hidden]) {
    opacity: 0;
    transform: translateY(8px);
  }
}

.tour__fit,
.lightbox__fit {
  display: inline-flex;
  padding: 0.2rem;
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  backdrop-filter: blur(12px) saturate(160%);
}

.tour__fit-btn,
.lightbox__fit-btn,
.tour__immersive-done {
  min-height: 2.35rem;
  padding: 0 0.85rem;
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: transform 120ms var(--ease-out), background-color 150ms ease, color 150ms ease;
}

.tour__fit-btn,
.lightbox__fit-btn {
  color: var(--navy);
}

.tour__fit-btn[aria-pressed="true"],
.lightbox__fit-btn[aria-pressed="true"] {
  background: var(--navy);
  color: var(--white);
}

.tour__immersive-done {
  color: var(--white);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.tour__fit-btn:active,
.lightbox__fit-btn:active,
.tour__immersive-done:active {
  transform: scale(0.96);
}

/* The plan follows the swipe (scales with the drag) and settles smaller once the visitor is walking
   through, giving the photo the height. Tapping the plan or a floor brings it back. */
.tour__plan {
  transition: width 260ms var(--ease-out), transform 200ms var(--ease-out);
  transform-origin: 50% 100%;
}

.tour--compact .tour__plan {
  width: min(100%, calc(14dvh * var(--ratio)));
}

.tour__ambient {
  position: absolute;
  inset: -8%;
  width: 116%;
  height: 116%;
  object-fit: cover;
  filter: blur(28px) brightness(0.5) saturate(1.1);
  opacity: 0.85;
  pointer-events: none;
}

.tour__ambient:not([src]) {
  display: none;
}

/* Caption over the foot of the photo: a gradual vignette keeps the blurb legible on any render. */
.tour__overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  display: grid;
  gap: 0.65rem;
  padding: 4.5rem var(--pad) 0.95rem;
  background: linear-gradient(
    to top,
    rgba(18, 18, 18, 0.78) 0%,
    rgba(18, 18, 18, 0.55) 38%,
    rgba(18, 18, 18, 0.2) 72%,
    rgba(18, 18, 18, 0) 100%
  );
  pointer-events: none;
}

.tour__overlay-row {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
}

.tour__blurb {
  flex: 1;
  min-width: 0;
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.005em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.tour__fin-btn {
  flex: none;
  min-height: 2.75rem;
  margin-left: auto;
  padding: 0 0.9rem;
  color: var(--white);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  pointer-events: auto;
  touch-action: manipulation;
  transition: transform 160ms var(--ease-out), background-color 150ms ease;
}

.tour__fin-btn:active {
  transform: scale(0.96);
}

.tour__dots,
.explorer__dots {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  pointer-events: none;
}

.tour__dots span,
.explorer__dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
  transition: transform 200ms var(--ease-out), background-color 200ms ease;
}

.tour__dots span.is-active,
.explorer__dots span.is-active {
  background: var(--white);
  transform: scale(1.35);
}

/* Prev/next. On phones they sit mid-height as quiet icon buttons (swiping is primary); on wide
   screens they name the destination. */
.tour__nav {
  position: absolute;
  top: calc(50% - 1.375rem);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  max-width: calc(50% - 1rem);
  min-width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  backdrop-filter: blur(12px) saturate(160%);
  color: var(--navy);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  transition: transform 160ms var(--ease-out), background-color 150ms ease;
}

.tour__nav.is-prev {
  left: 0.6rem;
}

.tour__nav.is-next {
  right: 0.6rem;
}

.tour__nav.is-next .icon {
  transform: rotate(180deg);
}

.tour__nav-label {
  display: none;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tour__nav:active {
  transform: scale(0.95);
}

.tour__end {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0.9rem;
  padding: 2rem var(--pad) 4rem;
  text-align: center;
}

.tour__end-eyebrow {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blush);
}

.tour__end-title {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 500;
  line-height: 1.05;
}

.tour__end-text {
  max-width: 26rem;
  font-weight: 300;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.75);
}

.tour__end-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.tour__link {
  min-height: 2.75rem;
  padding: 0 0.5rem;
  color: var(--white);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.4);
  text-underline-offset: 0.35em;
}

/* Guide: light, full-bleed. */
.tour__guide {
  grid-area: guide;
  display: grid;
  justify-items: center;
  gap: 0.55rem;
  min-height: 0;
  padding: 0.7rem var(--pad) calc(0.8rem + env(safe-area-inset-bottom, 0px));
  background: var(--white);
  color: var(--charcoal);
}

.tour__brand,
.tour__about,
.tour__finishes {
  display: none;
}

.tour__floors {
  display: flex;
  gap: 0.25rem;
}

.tour__floor {
  min-height: 2.5rem;
  padding: 0 0.85rem;
  color: var(--navy);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  touch-action: manipulation;
  transition: color 150ms ease, background-color 150ms ease;
}

.tour__floor.is-active {
  color: var(--white);
  background: var(--navy);
}

.tour__floor:disabled {
  opacity: 0.35;
}

/* The plan is zoomed to its drawn area: the inner layer keeps the full canvas (so the area
   outlines still line up) and is offset/scaled by the content box. */
.tour__plan {
  --ratio: 1.414;
  --bx: 0;
  --by: 0;
  --bw: 1;
  --bh: 1;
  position: relative;
  width: min(100%, calc(28dvh * var(--ratio)));
  aspect-ratio: var(--ratio);
  overflow: hidden;
}

.tour__plan-inner {
  position: absolute;
  left: calc(var(--bx) / var(--bw) * -100%);
  top: calc(var(--by) / var(--bh) * -100%);
  width: calc(100% / var(--bw));
  height: calc(100% / var(--bh));
}

.tour__plan-img,
.tour__hot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.tour__plan-img {
  object-fit: fill;
}

.tour__area {
  fill: rgba(46, 65, 89, 0);
  stroke: rgba(46, 65, 89, 0.3);
  stroke-width: 1;
  stroke-dasharray: 3 3;
  cursor: pointer;
  transition: fill 200ms ease, stroke 200ms ease;
}

.tour__area.is-current {
  fill: rgba(46, 65, 89, 0.28);
  stroke: var(--navy);
  stroke-width: 2;
  stroke-dasharray: none;
}

.tour__area.is-empty {
  stroke: transparent;
  pointer-events: none;
}

.tour__cap {
  font-size: 0.68rem;
  letter-spacing: 0.02em;
  color: var(--muted);
  text-align: center;
}

/* Finishes sheet (phones). */
.tour__sheet-scrim {
  position: absolute;
  inset: 0;
  z-index: 4;
  background: rgba(18, 18, 18, 0.5);
}

.tour__sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  max-height: 80dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0.75rem var(--pad) calc(1.25rem + env(safe-area-inset-bottom, 0px));
  background: var(--white);
  color: var(--charcoal);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.18);
}

.tour__sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.tour__sheet-title {
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 500;
}

.tour__sheet-close {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  color: var(--charcoal);
  box-shadow: inset 0 0 0 1px var(--line);
}

.tour__sheet-img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 60dvh;
  margin: 0 auto;
}

@media (hover: hover) and (pointer: fine) {
  .tour__nav:hover {
    background: var(--white);
  }

  .tour__close:hover {
    background: rgba(255, 255, 255, 0.1);
  }

  .tour__floor:not(.is-active):not(:disabled):hover {
    background: rgba(46, 65, 89, 0.06);
  }

  .tour__area:not(.is-current):hover {
    fill: rgba(46, 65, 89, 0.1);
    stroke: rgba(46, 65, 89, 0.7);
  }
}

/* Wide screens: dark photo column, white sidebar with brand, plan, blurb and finishes. */
@media (min-width: 961px) {
  .tour {
    grid-template-columns: minmax(0, 1fr) 26rem;
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-areas: "progress progress" "main guide";
  }

  .tour__head {
    padding: 1rem 2rem;
  }

  .tour__eyebrow-brand {
    display: none;
  }

  .tour__img {
    object-position: 50% 50%;
  }

  .tour__overlay {
    padding: 0 2rem 1.9rem;
    background: none;
  }

  .tour__overlay-row {
    display: none;
  }

  .tour__nav {
    top: auto;
    bottom: 1rem;
    padding: 0 0.9rem;
  }

  .tour__nav:not(.has-label) {
    padding: 0;
  }

  .tour__nav.is-prev {
    left: 1.25rem;
  }

  .tour__nav.is-next {
    right: 1.25rem;
  }

  .tour__nav-label {
    display: block;
  }

  .tour__nav-label:empty {
    display: none;
  }

  .tour__close {
    top: 1.1rem;
    right: 1.5rem;
    color: var(--charcoal);
    box-shadow: inset 0 0 0 1px var(--line);
  }

  .tour__guide {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 1.25rem;
    padding: 1.35rem 2rem 2rem;
    overflow-y: auto;
  }

  .tour__brand {
    display: block;
    min-height: 2.75rem;
    padding-right: 3.5rem;
    font-family: var(--serif);
    font-size: 1.45rem;
    font-weight: 500;
    line-height: 2.75rem;
    letter-spacing: 0.01em;
    color: var(--charcoal);
  }

  .tour__floors {
    align-self: flex-start;
  }

  .tour__plan {
    width: 100%;
  }

  .tour__about {
    display: grid;
    gap: 0.5rem;
  }

  .tour__about-title {
    font-family: var(--serif);
    font-size: 1.75rem;
    font-weight: 500;
    line-height: 1.1;
  }

  .tour__about-text {
    font-size: 0.95rem;
    font-weight: 300;
    line-height: 1.65;
    color: var(--muted);
  }

  .tour__finishes {
    display: grid;
    gap: 0.5rem;
    margin: 0;
  }

  .tour__finishes-img {
    width: 100%;
    max-height: 13rem;
    object-fit: contain;
    object-position: 0 50%;
  }

  .tour__finishes-cap {
    order: -1;
    font-size: 0.62rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--navy);
  }

  .tour__cap {
    margin-top: auto;
    text-align: left;
  }

  @media (hover: hover) and (pointer: fine) {
    .tour__close:hover {
      background: rgba(37, 37, 37, 0.05);
    }
  }
}

@media (prefers-reduced-transparency: reduce) {
  .tour__nav {
    background: var(--white);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

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

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.lightbox[hidden] {
  display: none !important;
}

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(37, 37, 37, 0.92);
  cursor: zoom-out;
}

.lightbox__frame {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: min(96vw, 1100px);
  max-height: 92vh;
  outline: none;
}

.lightbox__figure {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  max-height: calc(92vh - 4rem);
}

.lightbox__img {
  max-width: 100%;
  max-height: calc(92vh - 5.5rem);
  width: auto;
  height: auto;
  object-fit: contain;
  background: #1a1a1a;
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
  user-select: none;
  -webkit-user-drag: none;
  touch-action: pan-y;
}

.lightbox__cap {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--blush);
  text-align: center;
  margin-top: 0.85rem;
  max-width: 36rem;
  padding: 0 2.5rem;
}

.lightbox__counter {
  position: absolute;
  bottom: -0.15rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  white-space: nowrap;
}

.lightbox__close,
.lightbox__nav {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: rgba(46, 65, 89, 0.55);
  border: 1px solid rgba(217, 204, 197, 0.28);
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), opacity 0.25s var(--ease);
  -webkit-tap-highlight-color: transparent;
}

.lightbox__close:hover,
.lightbox__nav:hover {
  background: var(--navy);
  border-color: var(--blush);
}

.lightbox__close:focus-visible,
.lightbox__nav:focus-visible {
  outline: 2px solid var(--blush);
  outline-offset: 3px;
}

.lightbox__close {
  top: 0;
  right: 0;
  width: 2.75rem;
  height: 2.75rem;
  font-size: 1.75rem;
  line-height: 1;
}

.lightbox__nav {
  top: 50%;
  transform: translateY(-50%);
  width: 2.75rem;
  height: 2.75rem;
  font-size: 1.85rem;
  line-height: 1;
  border-radius: 0;
}

.lightbox__nav--prev {
  left: 0;
}

.lightbox__nav--next {
  right: 0;
}

.lightbox__nav[disabled] {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
}

body.lightbox-open {
  overflow: hidden;
  touch-action: none;
}

@media (max-width: 720px) {
  .lightbox {
    padding: 0.5rem;
  }

  .lightbox__frame {
    width: 100%;
    max-height: 100vh;
  }

  .lightbox__img {
    max-height: calc(100vh - 7rem);
  }

  .lightbox__close {
    top: 0.35rem;
    right: 0.35rem;
  }

  .lightbox__nav {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.6rem;
  }

  .lightbox__nav--prev {
    left: 0.15rem;
  }

  .lightbox__nav--next {
    right: 0.15rem;
  }

  .lightbox__cap {
    font-size: 0.85rem;
    padding: 0 1rem;
  }

  .lightbox__counter {
    bottom: 0.25rem;
  }
}

@media (min-width: 900px) {
  .lightbox__nav--prev {
    left: -3.25rem;
  }

  .lightbox__nav--next {
    right: -3.25rem;
  }

  .lightbox__close {
    top: -0.25rem;
    right: -0.25rem;
  }
}

/* Full screen, like the tour (.is-screen: always on phones; on wide screens for photos that can be
   looked around). "Look around" (data-fit="fill") sizes the photo inline to cover the screen; tilting
   (phones) or the mouse (desktop) pans across it (js/look.js). "Whole image" letterboxes it.
   A tap on the picture (.is-bare) clears the caption and controls away. */
.lightbox.is-screen {
  padding: 0;
}

.lightbox.is-screen .lightbox__backdrop {
  background: #141414;
}

.lightbox.is-screen .lightbox__frame {
  position: absolute;
  inset: 0;
  width: 100%;
  max-height: none;
  overflow: hidden;
}

.lightbox.is-screen .lightbox__figure {
  position: absolute;
  inset: 0;
  max-height: none;
  justify-content: center;
}

.lightbox.is-screen .lightbox__img {
  max-height: 100%;
  box-shadow: none;
  transition: opacity 180ms var(--ease-out);
}

.lightbox.is-screen[data-fit="fill"] .lightbox__img {
  position: absolute;
  max-width: none; /* the inline cover size is wider than the screen on purpose */
  max-height: none;
  will-change: transform;
}

.lightbox.is-screen.is-loading .lightbox__img {
  opacity: 0;
  transition: none;
}

.lightbox.is-screen .lightbox__cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  max-width: none;
  padding: 4rem 1.25rem calc(4.5rem + env(safe-area-inset-bottom, 0px));
  color: var(--white);
  text-align: left;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0));
  pointer-events: none;
}

.lightbox.is-screen:has(.lightbox__bar[hidden]) .lightbox__cap {
  padding-bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
}

.lightbox.is-screen .lightbox__counter {
  top: calc(1.2rem + env(safe-area-inset-top, 0px));
  bottom: auto;
  left: 1.25rem;
  transform: none;
}

.lightbox.is-screen .lightbox__close {
  top: calc(0.5rem + env(safe-area-inset-top, 0px));
  right: 0.5rem;
}

.lightbox.is-screen .lightbox__close,
.lightbox.is-screen .lightbox__nav {
  background: rgba(20, 20, 20, 0.45);
  border-color: rgba(255, 255, 255, 0.22);
}

.lightbox.is-screen .lightbox__nav--prev {
  left: 0.5rem;
}

.lightbox.is-screen .lightbox__nav--next {
  right: 0.5rem;
}

.lightbox.is-screen .lightbox__bar {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  z-index: 2;
  display: flex;
  justify-content: center;
}

.lightbox.is-screen .lightbox__cap,
.lightbox.is-screen .lightbox__counter,
.lightbox.is-screen .lightbox__bar,
.lightbox.is-screen .lightbox__nav {
  transition: opacity 200ms var(--ease-out);
}

.lightbox.is-screen.is-bare .lightbox__cap,
.lightbox.is-screen.is-bare .lightbox__counter,
.lightbox.is-screen.is-bare .lightbox__bar,
.lightbox.is-screen.is-bare .lightbox__nav,
.lightbox.is-dismissing .lightbox__cap,
.lightbox.is-dismissing .lightbox__counter,
.lightbox.is-dismissing .lightbox__bar,
.lightbox.is-dismissing .lightbox__nav,
.lightbox.is-dismissing .lightbox__close {
  opacity: 0;
  pointer-events: none;
}

.lightbox.is-screen .lightbox__frame {
  -webkit-user-select: none;
  user-select: none;
}

@media (min-width: 961px) {
  .lightbox.is-screen .lightbox__cap {
    padding: 6rem 2.5rem 5rem;
    font-size: 1.05rem;
  }

  .lightbox.is-screen .lightbox__counter {
    left: 2.5rem;
  }

  .lightbox.is-screen .lightbox__nav--prev {
    left: 1.25rem;
  }

  .lightbox.is-screen .lightbox__nav--next {
    right: 1.25rem;
  }

  .lightbox.is-screen .lightbox__close {
    top: 1.25rem;
    right: 1.25rem;
  }
}

/* Full screen keeps the brand: the wordmark sits top-centre over the photo on a soft top vignette.
   Shown in the full-screen lightbox and the tour's picture-only mode; it stays when the controls are
   tapped away and fades only while the view is being swiped closed. */
.fs-wordmark {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  margin: 0;
  padding: calc(1.05rem + env(safe-area-inset-top, 0px)) 4rem 2.5rem;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1;
  text-align: center;
  color: var(--white);
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0));
  pointer-events: none;
  transition: opacity 200ms var(--ease-out);
}

.lightbox.is-screen .fs-wordmark,
.tour--immersive .fs-wordmark {
  display: block;
}

.lightbox.is-dismissing .fs-wordmark {
  opacity: 0;
}

@media (min-width: 961px) {
  .fs-wordmark {
    padding-top: 1.6rem;
    font-size: 1.6rem;
  }
}

.lightbox__bar[hidden],
.lightbox__nav[hidden] {
  display: none !important;
}

/* ---------- Copy update additions ---------- */

.section__fact {
  margin-top: 0.85rem;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.place__body {
  margin-top: 1rem;
}

.explorer__note {
  margin-top: 1rem;
  font-size: 0.7rem;
  line-height: 1.55;
  color: var(--muted);
}

.form__success[data-kind="error"],
.form__success[data-kind="blocked"] {
  color: var(--charcoal);
  font-style: normal;
  font-family: var(--sans);
  font-size: 0.9rem;
}
