/* ==========================================================================
   VERA ESTATES — full-screen sheet: property detail + journal reader
   ========================================================================== */

.sheet {
  width: 100vw;
  max-width: 100vw;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--ivory);
  color: var(--char);
  overflow: hidden;
}

.sheet[open] {
  display: block;
  animation: sheet-in 1s var(--ease) both;
}

.sheet.is-closing {
  animation: sheet-out 0.6s var(--ease-in-out) both;
}

.sheet::backdrop {
  background: var(--char);
}

@keyframes sheet-in {
  from {
    clip-path: inset(100% 0 0 0);
  }
  to {
    clip-path: inset(0 0 0 0);
  }
}

@keyframes sheet-out {
  to {
    clip-path: inset(0 0 100% 0);
  }
}

.sheet__scroll {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.sheet__bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 14px var(--gutter);
  background: rgba(245, 240, 230, 0.94);
  border-bottom: 1px solid var(--line);
}

.sheet__back {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  min-height: 44px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.sheet__back svg {
  width: 16px;
  height: 16px;
  transform: scaleX(-1);
  transition: transform 0.5s var(--ease);
}

.sheet__back:hover svg {
  transform: scaleX(-1) translateX(5px);
}

.sheet__logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-serif);
  font-size: 1.3rem;
  letter-spacing: 0.34em;
  margin-right: -0.34em;
}

.sheet__nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.sheet__step {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.sheet__step:hover {
  background: var(--char);
  border-color: var(--char);
  color: var(--ivory);
}

.sheet__step svg {
  width: 16px;
  height: 16px;
}

.sheet__step--prev svg {
  transform: scaleX(-1);
}

.sheet__cta {
  display: none;
  margin-left: 0.8rem;
}

@media (max-width: 899px) {
  .sheet__logo {
    display: none;
  }
}

@media (min-width: 900px) {
  .sheet__cta {
    display: inline-flex;
  }
}

/* --------------------------------------------------------------------------
   Property detail
   -------------------------------------------------------------------------- */

.pd-hero {
  position: relative;
  height: min(82vh, 900px);
  min-height: 420px;
  overflow: hidden;
  background: var(--stone);
}

.pd-hero img {
  position: absolute;
  inset: -6% 0;
  width: 100%;
  height: 112%;
  object-fit: cover;
  object-position: var(--pos, 50% 50%);
  animation: pd-img 2.2s var(--ease) 0.3s both;
  will-change: transform;
}

@keyframes pd-img {
  from {
    transform: scale(1.1);
  }
}

.pd-hero__tag {
  position: absolute;
  left: var(--gutter);
  bottom: 22px;
  padding: 0.7em 1.1em;
  background: var(--ivory);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.pd-head {
  display: grid;
  gap: 28px;
  padding-block: clamp(40px, 6vw, 88px) clamp(32px, 4vw, 56px);
}

.pd-head__loc {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--bronze);
}

.pd-head__name {
  margin-top: 1rem;
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(3.2rem, 9vw, 9rem);
  line-height: 0.9;
  text-transform: uppercase;
}

.pd-head__price {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 3.4vw, 3rem);
  font-weight: 400;
  font-variant-numeric: lining-nums;
  line-height: 1;
}

.pd-head__price small {
  display: block;
  margin-bottom: 0.7rem;
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--mute);
}

@media (min-width: 900px) {
  .pd-head {
    grid-template-columns: 1fr auto;
    align-items: end;
    gap: 64px;
  }

  .pd-head__price {
    text-align: right;
  }
}

.pd-specs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-block: 1px solid var(--line-strong);
}

.pd-spec {
  display: flex;
  flex-direction: column-reverse;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--line);
}

.pd-spec:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.pd-spec dd {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1;
  font-variant-numeric: lining-nums;
}

.pd-spec dd small {
  font-size: 0.5em;
  color: var(--bronze);
  margin-left: 0.15em;
}

.pd-spec dt {
  margin-top: 0.7rem;
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--mute);
}

@media (min-width: 720px) {
  .pd-specs {
    grid-template-columns: repeat(5, 1fr);
  }

  .pd-spec {
    padding: 1.6rem 1.4rem;
    border-bottom: 0;
    border-left: 1px solid var(--line);
  }

  .pd-spec:first-child {
    border-left: 0;
    padding-left: 0;
  }
}

.pd-main {
  display: grid;
  gap: 56px;
  padding-block: clamp(48px, 7vw, 104px);
}

.pd-story .lede {
  margin-bottom: 1.6rem;
}

.pd-story .body-text + .body-text {
  margin-top: 1.2em;
}

.pd-features {
  margin-top: clamp(36px, 5vw, 64px);
}

.pd-features h3,
.pd-enquire h3 {
  padding-bottom: 0.9rem;
  border-bottom: 1px solid var(--line-strong);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--bronze);
}

.pd-features ul {
  display: grid;
}

.pd-features li {
  padding-block: 0.9rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
}

@media (min-width: 720px) {
  .pd-features ul {
    grid-template-columns: 1fr 1fr;
    column-gap: 3rem;
  }
}

.pd-enquire {
  padding: clamp(24px, 3vw, 40px);
  background: var(--paper);
}

.pd-agent {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 16px;
  align-items: center;
  margin-top: 1.4rem;
}

.pd-agent img {
  width: 76px;
  height: 92px;
  object-fit: cover;
  filter: sepia(0.14) saturate(0.88);
}

.pd-agent b {
  display: block;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.1;
}

.pd-agent span {
  font-size: 0.86rem;
  color: var(--mute);
}

.pd-enquire form {
  display: grid;
  gap: 20px;
  margin-top: 1.6rem;
}

.pd-enquire__alt {
  margin-top: 1.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 1.4rem;
  font-size: 0.88rem;
}

.pd-enquire__alt a {
  border-bottom: 1px solid var(--line-strong);
}

.pd-enquire__alt a:hover {
  color: var(--bronze);
  border-color: var(--bronze);
}

@media (min-width: 1000px) {
  .pd-main {
    grid-template-columns: 1.55fr 1fr;
    gap: clamp(56px, 7vw, 120px);
    align-items: start;
  }

  .pd-enquire {
    position: sticky;
    top: 92px;
  }
}

/* Gallery */
.pd-gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(10px, 1.6vw, 24px);
  padding-bottom: clamp(56px, 8vw, 120px);
}

.pd-shot {
  position: relative;
  overflow: hidden;
  background: var(--stone);
  aspect-ratio: var(--ar, 4 / 3);
  grid-column: span 1;
  cursor: zoom-in;
  display: block;
  width: 100%;
}

.pd-shot--wide {
  grid-column: 1 / -1;
}

.pd-shot img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.6s var(--ease);
}

.pd-shot:hover img,
.pd-shot:focus-visible img {
  transform: scale(1.05);
}

.pd-shot span {
  position: absolute;
  left: 14px;
  bottom: 12px;
  z-index: 1;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ivory);
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.55);
}

@media (min-width: 900px) {
  .pd-gallery {
    grid-template-columns: repeat(12, 1fr);
    align-items: start;
  }

  .pd-shot {
    grid-column: span 4;
  }

  .pd-shot--wide {
    grid-column: span 8;
  }

  .pd-shot--half {
    grid-column: span 6;
  }

  .pd-shot--full {
    grid-column: 1 / -1;
  }
}

/* Next residence */
.pd-next {
  display: block;
  position: relative;
  padding: clamp(56px, 8vw, 112px) var(--gutter);
  background: var(--char);
  color: var(--ivory);
  overflow: hidden;
  isolation: isolate;
}

.pd-next__img {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.32;
  transition: opacity 0.8s var(--ease), transform 1.6s var(--ease);
}

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

.pd-next:hover .pd-next__img {
  opacity: 0.5;
  transform: scale(1.04);
}

.pd-next__in {
  max-width: calc(var(--maxw));
  margin-inline: auto;
}

.pd-next small {
  display: block;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--bronze-lt);
}

.pd-next b {
  display: block;
  margin-top: 1.2rem;
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(3rem, 9vw, 8rem);
  line-height: 0.92;
  text-transform: uppercase;
}

.pd-next span {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  margin-top: 1.6rem;
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.pd-next svg {
  width: 16px;
  height: 16px;
  transition: transform 0.5s var(--ease);
}

.pd-next:hover svg {
  transform: translateX(6px);
}

/* Sticky mobile enquiry bar */
.pd-sticky {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom));
  background: rgba(245, 240, 230, 0.97);
  border-top: 1px solid var(--line);
}

.pd-sticky b {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1;
}

.pd-sticky small {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mute);
}

.pd-sticky .btn {
  flex: none;
}

@media (min-width: 1000px) {
  .pd-sticky {
    display: none;
  }
}

@media (max-width: 999px) {
  .pd-next {
    padding-bottom: calc(clamp(56px, 8vw, 112px) + 70px);
  }
}

/* Image viewer inside the sheet */
.pd-lb {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  grid-template-rows: 1fr auto;
  background: rgba(24, 23, 20, 0.985);
  color: var(--ivory);
  animation: lb-in 0.4s var(--ease) both;
}

.pd-lb[hidden] {
  display: none;
}

@keyframes lb-in {
  from {
    opacity: 0;
  }
}

.pd-lb__stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
  overflow: hidden;
  padding: 72px clamp(16px, 8vw, 120px) 16px;
}

.pd-lb__img {
  max-width: 100%;
  max-height: calc(100dvh - 190px);
  width: auto;
  height: auto;
  object-fit: contain;
  transition: opacity 0.3s var(--ease);
}

.pd-lb__img.is-swapping {
  opacity: 0;
}

.pd-lb__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 14px var(--gutter) calc(20px + env(safe-area-inset-bottom));
}

.pd-lb__cap {
  font-family: var(--font-serif);
  font-size: 1.4rem;
}

.pd-lb__count {
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  color: rgba(245, 240, 230, 0.7);
  white-space: nowrap;
}

.pd-lb__btn {
  position: absolute;
  z-index: 2;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  color: var(--ivory);
  border: 1px solid var(--line-inv);
  background: rgba(24, 23, 20, 0.5);
  transition: background-color 0.3s, border-color 0.3s;
}

.pd-lb__btn:hover {
  background: var(--bronze);
  border-color: var(--bronze);
}

.pd-lb__btn svg {
  width: 20px;
  height: 20px;
}

.pd-lb__btn--close {
  top: 16px;
  right: 16px;
}

.pd-lb__btn--prev,
.pd-lb__btn--next {
  top: 50%;
  margin-top: -26px;
}

.pd-lb__btn--prev {
  left: 16px;
}

.pd-lb__btn--next {
  right: 16px;
}

.pd-lb__btn--prev svg {
  transform: scaleX(-1);
}

@media (max-width: 700px) {
  .pd-lb__stage {
    padding-inline: 12px;
  }

  .pd-lb__btn--prev,
  .pd-lb__btn--next {
    top: auto;
    bottom: 12px;
    margin-top: 0;
  }

  .pd-lb__btn--prev {
    left: auto;
    right: 76px;
  }

  .pd-lb__btn--next {
    right: 16px;
  }

  .pd-lb__bar {
    padding-right: 150px;
  }
}

/* --------------------------------------------------------------------------
   Journal reader
   -------------------------------------------------------------------------- */

.rd-hero {
  position: relative;
  height: min(64vh, 640px);
  min-height: 300px;
  overflow: hidden;
  background: var(--stone);
}

.rd-hero img {
  position: absolute;
  inset: -6% 0;
  width: 100%;
  height: 112%;
  object-fit: cover;
  object-position: var(--pos, 50% 50%);
  filter: sepia(0.08) saturate(0.92);
  animation: pd-img 2.2s var(--ease) 0.3s both;
}

.rd-head {
  max-width: 900px;
  margin-inline: auto;
  padding: clamp(40px, 6vw, 80px) var(--gutter) 0;
}

.rd-head .post__cat {
  display: inline-block;
  margin-bottom: 1.4rem;
}

.rd-head h2 {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 0.98;
  text-transform: uppercase;
  text-wrap: balance;
}

.rd-meta {
  margin-top: 1.6rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line-strong);
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 1.6rem;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mute);
}

.rd-body {
  max-width: 900px;
  margin-inline: auto;
  padding: clamp(32px, 5vw, 56px) var(--gutter) clamp(56px, 8vw, 96px);
}

.rd-body p {
  max-width: 34em;
  color: var(--ink-2);
  font-size: 1.1rem;
  line-height: 1.8;
}

.rd-body p + p {
  margin-top: 1.4em;
}

.rd-body p:first-child {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 2vw, 1.75rem);
  line-height: 1.45;
  color: var(--char);
}

.rd-body p:first-child::first-letter {
  float: left;
  margin: 0.08em 0.12em 0 0;
  font-size: 4.6em;
  line-height: 0.8;
  font-weight: 300;
  color: var(--bronze);
}

.rd-body blockquote {
  margin: 2.4rem 0;
  padding-left: 1.6rem;
  border-left: 1px solid var(--bronze);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  line-height: 1.25;
  max-width: 20em;
}

.rd-more {
  padding: clamp(40px, 6vw, 80px) var(--gutter) clamp(56px, 8vw, 100px);
  background: var(--paper);
}

.rd-more__in {
  max-width: var(--maxw);
  margin-inline: auto;
  display: grid;
  gap: 32px;
}

.rd-more h3 {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--bronze);
}

.rd-more ul {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line-strong);
}

.rd-more li a {
  display: grid;
  gap: 0.3rem;
  padding-block: 1.2rem;
  border-bottom: 1px solid var(--line);
  transition: padding-left 0.5s var(--ease), color 0.3s;
}

.rd-more li a:hover {
  padding-left: 0.8rem;
  color: var(--bronze);
}

.rd-more li small {
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--mute);
}

.rd-more li b {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.15;
}

@media (min-width: 900px) {
  .rd-more__in {
    grid-template-columns: 1fr 2fr;
    gap: 72px;
  }
}
