/* ==========================================================================
   PROPERTY — "The residence dossier". Only property_details.html loads this
   file; the section heads, buttons and the drafting frame come from
   css/inner.css, the opening from css/elevation.css, the footer from
   css/footer.css.

   §R1 opening (elsewhere) · §R2 intro · §R3 at a glance · §R4 find your home
   §R5 interiors (plans) · §R6 gallery (elsewhere) · §R7 location (elsewhere) · §R9 closing call
   ========================================================================== */

/* --- §R1  The opening -----------------------------------------------------------------
   "Lights on" — its styles live with the component in css/elevation.css. */

/* --- shared: the section bands -------------------------------------------------------- */
.s-intro { --h: auto; --bg: var(--c-ivory); color: var(--c-ink); }
.s-resid { --h: auto; --bg: #efe9df; color: var(--c-ink); }

/* --- §R2  Intro ------------------------------------------------------------------------
   Statement, story and the navy call; three feature cards; the elevation in
   an arched window on the right. */
.intro__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: var(--sp-2xl) clamp(48px, 6vw, 120px);
  align-items: center;
  padding-block: var(--section-gap);
}

.intro__copy { display: grid; justify-items: start; gap: var(--sp-sm); align-content: start; }
.intro__h { max-width: 12ch; }

.intro__p {
  max-width: 54ch;
  margin-block-start: var(--sp-sm);
  font-size: var(--fs-text);
  line-height: 1.75;
}
.intro__btn { margin-block-start: var(--sp-sm); }

.feats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 1.2vw, 20px);
  width: 100%;
  margin-block-start: clamp(36px, 3.6vw, 60px);
}
.feat {
  position: relative;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: clamp(20px, 1.8vw, 28px);
  border: 1px solid var(--rule);
  border-radius: var(--r-card);
  background: rgb(255 255 255 / .55);
  transition: translate .5s var(--ease-css), box-shadow .5s var(--ease-css), border-color .5s var(--ease-css);
}
.feat:hover { translate: 0 -4px; border-color: rgb(127 95 40 / .35); box-shadow: 0 24px 50px -30px rgb(var(--scrim) / .4); }
.feat__icon { width: 46px; height: 46px; margin-block-end: 6px; color: var(--c-gold-ink); }
.feat__h {
  font-family: var(--font-display);
  font-size: clamp(20px, 1.5vw, 24px);
  font-weight: var(--fw-semi);
  line-height: 1.15;
  color: var(--c-navy);
}
.feat__p { font-size: var(--fs-small); line-height: 1.55; color: var(--c-slate); }

.intro__fig { margin: 0; }
.pr-arch {
  overflow: hidden;
  aspect-ratio: 4 / 5;
  max-width: 560px;
  margin-inline-start: auto;
  border-radius: 999px 999px 40px 40px;
  background: #0b1f33;
  box-shadow: 0 2px 6px rgb(var(--scrim) / .06), 0 50px 90px -40px rgb(var(--scrim) / .5);
}
.intro__plate { width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.pr-cap {
  display: flex;
  justify-content: space-between;
  gap: var(--sp-sm);
  max-width: 560px;
  margin: 18px 0 0 auto;
  font-size: var(--fs-small);
  color: var(--c-slate);
}
.pr-cap span:first-child { font-size: 11px; font-weight: var(--fw-semi); letter-spacing: .12em; text-transform: uppercase; color: var(--c-gold-ink); }

/* --- §R3  At a glance and the feature list -------------------------------------------- */
.resid__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--sp-xl) clamp(40px, 5vw, 96px);
  padding-block: var(--section-gap);
}
.resid__head { display: grid; gap: var(--sp-sm); align-content: start; }
.resid__p { align-self: end; max-width: 60ch; font-size: var(--fs-text); line-height: 1.75; }

.glance {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: stretch;
  overflow: hidden;
  border-radius: var(--r-card);
  background: var(--c-ivory);
  box-shadow: 0 2px 6px rgb(var(--scrim) / .05), 0 40px 80px -50px rgb(var(--scrim) / .45);
}
.glance__plate { width: 100%; height: 100%; min-height: 420px; object-fit: cover; }
.glance__panel { padding: clamp(24px, 3vw, 52px); }

.figs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fig {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 2px clamp(14px, 1.2vw, 20px);
  padding: clamp(14px, 1.4vw, 22px) 0;
  border-bottom: 1px solid var(--rule);
}
.fig:nth-child(even) { padding-inline-start: clamp(16px, 1.6vw, 28px); border-inline-start: 1px solid var(--rule); }
.fig:nth-last-child(-n + 2) { border-bottom: 0; }
.fig__icon { grid-row: 1 / 3; width: 40px; height: 40px; color: var(--c-gold-ink); }
.fig dt {
  grid-column: 2;
  font-size: 11px;
  font-weight: var(--fw-semi);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--c-slate);
}
.fig dd {
  grid-column: 2;
  font-family: var(--font-display);
  font-size: clamp(19px, 1.5vw, 24px);
  font-weight: var(--fw-semi);
  line-height: 1.2;
  color: var(--c-navy);
}

/* the approvals — the RAJUK approval and the construction approval letter
   (united-height.html), in navy and gold so they read before the features */
.apv {
  grid-column: 1 / -1;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  gap: var(--sp-md) clamp(32px, 5vw, 88px);
  align-items: center;
  overflow: hidden;
  padding: clamp(28px, 4vw, 64px);
  border: 1px solid rgb(208 173 103 / .4);
  border-radius: var(--r-card);
  background:
    radial-gradient(110% 90% at 100% 0%, rgb(208 173 103 / .16), transparent 60%),
    linear-gradient(160deg, var(--c-navy) 0%, var(--c-navy-deep) 100%);
  color: var(--c-ivory);
  box-shadow: 0 2px 6px rgb(var(--scrim) / .08), 0 40px 80px -46px rgb(var(--scrim) / .6);
}
.apv::before {                                /* the blueprint grid, fading in to the right */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgb(208 173 103 / .08) 1px, transparent 1px),
    linear-gradient(90deg, rgb(208 173 103 / .08) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: linear-gradient(105deg, transparent 25%, #000 85%);
  mask-image: linear-gradient(105deg, transparent 25%, #000 85%);
  pointer-events: none;
}
.apv > * { position: relative; }
.apv__intro { display: grid; justify-items: start; gap: 14px; }
.apv__seal { display: block; width: 60px; height: 60px; color: var(--c-gold); }
.apv__seal svg { display: block; width: 100%; height: 100%; }
.apv__k { font-size: 11px; font-weight: var(--fw-semi); letter-spacing: .18em; text-transform: uppercase; color: var(--c-gold); }
.apv__h { font-family: var(--font-display); font-size: clamp(30px, 3vw, 46px); font-weight: var(--fw-medium); line-height: 1.05; color: var(--c-ivory); }
.apv__h em { font-style: italic; color: #f3dfae; }
.apv__p { max-width: 46ch; font-size: var(--fs-text); line-height: 1.7; color: var(--c-mist); }

.apv__body { display: grid; gap: 16px; }
.apv__main {
  padding: clamp(20px, 2.2vw, 32px);
  border: 1px solid rgb(208 173 103 / .6);
  border-radius: var(--r-card);
  background: rgb(208 173 103 / .1);
  box-shadow: inset 0 0 0 4px rgb(208 173 103 / .06);
}
.apv__label,
.apv__row dt { font-size: 11px; font-weight: var(--fw-semi); letter-spacing: .16em; text-transform: uppercase; color: var(--c-mist); }
.apv__num {
  margin-block-start: 10px;
  font-family: var(--font-display);
  font-size: clamp(24px, 2.3vw, 36px);
  font-weight: var(--fw-semi);
  line-height: 1.15;
  font-variant-numeric: lining-nums;
  overflow-wrap: break-word;
  color: #f3dfae;
}
.apv__letter { padding: clamp(18px, 2vw, 28px); border: 1px solid var(--rule-on-dark); border-radius: var(--r-card); background: rgb(10 23 41 / .25); }
.apv__letter-h {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  padding-block-end: 14px;
  border-bottom: 1px solid var(--rule-on-dark);
  font-weight: var(--fw-semi);
  color: var(--c-ivory);
}
.apv__letter-h span { font-size: var(--fs-small); font-weight: var(--fw-medium); color: var(--c-gold); }
.apv__row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 20px;
  align-items: baseline;
  padding-block: 12px;
  border-bottom: 1px solid rgb(248 245 239 / .1);
}
.apv__row:last-child { padding-block-end: 0; border-bottom: 0; }
.apv__row dd { font-size: clamp(15px, 1.1vw, 17px); font-weight: var(--fw-semi); font-variant-numeric: lining-nums tabular-nums; text-align: end; overflow-wrap: break-word; color: var(--c-ivory); }

/* the feature list — "What the building gives you" lives in css/building-features.css */

/* --- §R4  Find your home ------------------------------------------------------------------
   The aerial at night with gold pins; a pin opens its wing in a navy glass
   panel, a residence in the panel opens its card at the foot. */

.hot__dim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgb(var(--scrim) / .55);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-base) var(--ease-css);
}

.pin {
  position: absolute;
  inset-inline-start: var(--x);
  inset-block-start: var(--y);
  z-index: 2;
  translate: -50% -100%;
  display: grid;
  justify-items: center;
  gap: 10px;
}

.wing {
  position: absolute;
  inset-block: 0;
  inset-inline-end: 0;
  z-index: 3;
  width: min(38%, 600px);
  padding: clamp(80px, 9vh, 110px) clamp(24px, 2.4vw, 44px) clamp(24px, 2.4vw, 44px);
  overflow-y: auto;
  border-inline-start: 1px solid rgb(208 173 103 / .3);
  background: rgb(11 25 40 / .9);
  backdrop-filter: blur(16px);
  color: var(--c-ivory);
}
.wing__h {
  margin-block-end: var(--sp-md);
  font-family: var(--font-display);
  font-size: clamp(36px, 3.4vw, 60px);
  font-weight: var(--fw-medium);
  line-height: 1.05;
  color: var(--c-ivory);
}
.wing__h:focus { outline: none; }

.unit {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--r-card);
  text-align: start;
  outline: 2px solid transparent;
  outline-offset: 3px;
  transition: outline-color var(--dur-fast) var(--ease-css);
}
.unit img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(.66);
  transition: filter var(--dur-base) var(--ease-css), scale var(--dur-slow) var(--ease-css);
}
.unit:hover img,
.unit.is-active img { filter: brightness(.82); scale: 1.04; }
.unit.is-active { outline-color: var(--c-gold); }

@media (prefers-reduced-motion: reduce) {
  .hot__dim, .unit, .unit img { transition: none; }
}

/* --- §R5  Masterful interiors ------------------------------------------------------------
   "The plan room" — its styles live with the component in css/plan-room.css. */

/* --- §R6  Gallery ------------------------------------------------------------------------
   "The viewing room" — its styles live with the component in css/viewing-room.css. */

/* --- §R7  Location ------------------------------------------------------------------------
   "The way to Beam Skyline" — its styles live with the component in css/wayfinder.css. */

/* --- narrow --------------------------------------------------------------------------------- */
@media (max-width: 959px) {
  .intro__grid,
  .resid__grid { grid-template-columns: minmax(0, 1fr); }
  .intro__fig { order: -1; }
  .pr-arch { margin-inline: auto; max-width: 440px; }
  .pr-cap { margin-inline: auto; max-width: 440px; }
  .feats { grid-template-columns: minmax(0, 1fr); }

  .glance { grid-template-columns: minmax(0, 1fr); }
  .glance__plate { min-height: 0; aspect-ratio: 16 / 10; }
  .apv { grid-template-columns: minmax(0, 1fr); }
  .wing { width: 100%; inset-block-start: 18%; padding-block-start: var(--sp-xl); }
}

@media (max-width: 639px) {
  .figs { grid-template-columns: minmax(0, 1fr); }
  .fig:nth-child(even) { padding-inline-start: 0; border-inline-start: 0; }
  .fig:nth-last-child(2) { border-bottom: 1px solid var(--rule); }
  .apv__row { grid-template-columns: minmax(0, 1fr); }
  .apv__row dd { text-align: start; }
}
