/* ============================================================
   Cantonment Residences Penang — theme + layout
   Auto-derived palette: deep sea-navy, champagne gold accent,
   pearl neutrals — fitting a freehold luxury high-rise on the coast.
   ============================================================ */

:root {
  /* Palette */
  --ink: #10202b;          /* deep sea navy — primary dark */
  --ink-2: #1c3547;        /* lifted navy for panels */
  --sea: #294a5f;
  --gold: #b8863b;         /* champagne gold — accent (actions/highlights) */
  --gold-soft: #d8b271;
  --pearl: #f6f2ea;        /* warm ivory background */
  --pearl-2: #ece5d8;
  --paper: #ffffff;
  --text: #1a2b36;         /* body on light */
  --text-soft: #41505b;    /* supporting copy — darkened for ≥4.5:1 on tinted panels */
  --line: #dfd6c6;
  --on-dark: #eef3f5;
  --on-dark-soft: #a8bcc7;

  /* Category accents (amenities viz reads these on #amenities) */
  --c-education: #4a6fa5;
  --c-medical: #c1666b;
  --c-lifestyle: #2f9e72;
  --c-hotels: #b8863b;

  /* Type */
  --display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Rhythm */
  --wrap: 1160px;
  --pad: clamp(1.1rem, 4vw, 2.2rem);
  --sec-y: clamp(3.5rem, 8vw, 6.5rem);
  --radius: 14px;
  --shadow: 0 18px 46px -22px rgba(16, 32, 43, 0.45);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--text);
  background: var(--pearl);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  max-width: 100%;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.08; margin: 0 0 0.5em; letter-spacing: 0.2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-inline: var(--pad); }
.sr-only, .skip-link {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link:focus {
  position: fixed; top: 10px; left: 10px; width: auto; height: auto; clip: auto;
  background: var(--ink); color: #fff; padding: 0.6rem 1rem; border-radius: 8px; z-index: 200;
}

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--gold);
  --btn-fg: #1c150a;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-family: var(--sans); font-weight: 600; font-size: 0.98rem;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  padding: 0.8rem 1.5rem; border-radius: 999px; line-height: 1.1;
  min-height: 44px; transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.btn--primary { background: var(--btn-bg); color: var(--btn-fg); box-shadow: 0 10px 24px -12px rgba(184, 134, 59, 0.9); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -12px rgba(184, 134, 59, 0.95); }
.btn--ghost { background: transparent; color: currentColor; border-color: currentColor; }
.btn--ghost:hover { transform: translateY(-2px); background: rgba(184, 134, 59, 0.12); }
.btn--lg { padding: 0.95rem 1.8rem; font-size: 1.02rem; }
.btn--sm { padding: 0.55rem 1.1rem; min-height: 38px; font-size: 0.9rem; }
.btn:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; }

.eyebrow, .section__head .eyebrow {
  font-family: var(--sans); font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase;
  font-size: 0.74rem; color: var(--sea); margin: 0 0 0.7rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(16, 32, 43, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--on-dark);
}
.site-header__inner { display: flex; align-items: center; gap: 1.2rem; min-height: 66px; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--on-dark); font-family: var(--display); font-size: 1.35rem; }
.brand__name em { color: var(--gold-soft); font-style: italic; }
.nav { display: flex; gap: 1.4rem; margin-left: auto; }
.nav a { text-decoration: none; color: var(--on-dark-soft); font-size: 0.92rem; font-weight: 500; transition: color 0.2s ease; }
.nav a:hover { color: var(--on-dark); }
.nav a:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 4px; border-radius: 4px; }
.nav__cta { margin-left: 0.4rem; }

/* Mobile nav toggle (hidden on desktop) */
.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 44px; height: 44px; margin-left: 0.2rem;
  background: transparent; border: 1px solid rgba(255, 255, 255, 0.22); border-radius: 10px;
  color: var(--on-dark); cursor: pointer;
}
.nav-toggle__box { position: relative; width: 20px; height: 14px; }
.nav-toggle__bar, .nav-toggle__bar::before, .nav-toggle__bar::after {
  content: ""; position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px;
  background: currentColor; transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle__bar { top: 50%; transform: translateY(-50%); }
.nav-toggle__bar::before { top: -6px; }
.nav-toggle__bar::after { top: 6px; }
.is-nav-open .nav-toggle__bar { background: transparent; }
.is-nav-open .nav-toggle__bar::before { transform: translateY(6px) rotate(45deg); }
.is-nav-open .nav-toggle__bar::after { transform: translateY(-6px) rotate(-45deg); }
.nav-toggle:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; }

/* ---------- Hero ---------- */
.hero { position: relative; color: var(--on-dark); overflow: hidden; isolation: isolate; }
.hero__bg {
  position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(90% 70% at 10% 90%, rgba(41, 74, 95, 0.55), transparent 60%),
    linear-gradient(160deg, #0c1a23 0%, #16303f 55%, #1d3b4d 100%);
}
.hero__img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  object-position: 70% center;
}
/* Dark scrim keeps headline, price, and CTA ≥4.5:1 over the render. */
.hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(9, 18, 25, 0.9) 0%, rgba(9, 18, 25, 0.62) 42%, rgba(9, 18, 25, 0.2) 100%),
    linear-gradient(0deg, rgba(9, 18, 25, 0.78) 0%, transparent 45%);
}
.hero__inner { padding-block: clamp(4rem, 11vw, 8rem); max-width: 760px; }
.hero__eyebrow { color: var(--gold-soft); font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; font-size: 0.8rem; margin: 0 0 1.1rem; }
.hero__title { font-size: clamp(2.9rem, 8vw, 5.4rem); font-weight: 600; margin: 0 0 1rem; }
.hero__lead { font-size: clamp(1.08rem, 2.2vw, 1.35rem); color: var(--on-dark); max-width: 60ch; margin: 0 0 1.6rem; }
.hero__price { display: flex; align-items: baseline; gap: 0.9rem; flex-wrap: wrap; margin: 0 0 1.8rem; }
.hero__price span { font-family: var(--display); font-size: clamp(1.7rem, 4vw, 2.4rem); color: #fff; }
.hero__price em { font-style: normal; color: var(--gold-soft); font-weight: 600; letter-spacing: 0.02em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-bottom: 1.6rem; }
.hero__actions .btn--ghost { color: var(--on-dark); }

/* ---------- Sections ---------- */
.section { padding-block: var(--sec-y); }
.section__head { max-width: 640px; margin: 0 auto clamp(2rem, 4vw, 3rem); text-align: center; }
.section__head h2 { font-size: clamp(1.9rem, 4.4vw, 3rem); color: var(--ink); text-wrap: balance; }
.section__sub { color: var(--text-soft); margin: 0.4rem 0 0; }

/* Story */
.story { background: var(--paper); }
.story__inner { max-width: 780px; margin: 0 auto; }
.story .section__head { text-align: left; margin-left: 0; }
.story__body { font-size: 1.08rem; color: var(--text); margin: 0 0 1.2rem; }
.story__stats { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding: 0; margin: 2rem 0 0; border-top: 1px solid var(--line); padding-top: 1.6rem; }
.story__stats strong { display: block; font-family: var(--display); font-size: clamp(1.5rem, 3.5vw, 2.2rem); color: var(--sea); line-height: 1; }
.story__stats span { font-size: 0.85rem; color: var(--text-soft); }
.story__more { margin: -0.4rem 0 0; }
.story__more > summary { font-family: var(--sans); font-size: 0.98rem; font-weight: 600; color: var(--sea); margin-bottom: 0.4rem; }
.story__more > summary::after { width: 0.55rem; height: 0.55rem; }
.story__more .story__body { margin: 0.4rem 0 0; }

/* Highlights */
.cards { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.3rem; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.7rem 1.5rem; box-shadow: var(--shadow); transition: transform 0.25s ease, box-shadow 0.25s ease; }
.card:hover { transform: translateY(-5px); box-shadow: 0 26px 50px -24px rgba(16,32,43,0.5); }
.card h3 { font-size: 1.3rem; color: var(--ink); margin-bottom: 0.5rem; }
.card p { margin: 0; color: var(--text-soft); font-size: 0.98rem; }

/* Details */
.details { background: var(--pearl-2); }
.details__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: start; }
.spec-table, .units-table { width: 100%; border-collapse: collapse; background: var(--paper); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.spec-table th, .spec-table td, .units-table th, .units-table td { text-align: left; padding: 0.72rem 1rem; border-bottom: 1px solid var(--line); font-size: 0.95rem; vertical-align: top; }
.spec-table th[scope="row"] { width: 38%; color: var(--text-soft); font-weight: 600; }
.units-table thead th { background: var(--ink); color: var(--on-dark); font-family: var(--sans); font-size: 0.82rem; letter-spacing: 0.04em; text-transform: uppercase; }
.units-table th[scope="row"] { font-family: var(--display); font-size: 1.15rem; color: var(--sea); }
.units-table tbody tr:hover { background: var(--pearl); }
.units-note { margin: 0.9rem 0 0; font-size: 0.9rem; color: var(--text-soft); }
.units-note a { color: var(--sea); font-weight: 600; text-decoration: none; }
.units-note a:hover { text-decoration: underline; }
.units-note a:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; border-radius: 4px; }

/* Layout / plans */
.layout { background: var(--paper); }
.plan-block { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; margin-bottom: clamp(2.5rem, 6vw, 4rem); }
.plan-figure { margin: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--pearl); box-shadow: var(--shadow); }
.plan-figure__zoom { display: block; width: 100%; padding: 0; border: 0; background: #fff; cursor: zoom-in; }
.plan-figure__zoom:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: -3px; }
.plan-figure img { width: 100%; height: auto; display: block; background: #fff; }
.plan-figure figcaption { padding: 0.7rem 1rem; font-size: 0.85rem; color: var(--text-soft); border-top: 1px solid var(--line); }
.plan-block__cta h3 { color: var(--ink); font-size: clamp(1.3rem, 2.6vw, 1.6rem); }
.plan-block__cta p { color: var(--text-soft); font-size: 0.98rem; margin: 0 0 1.3rem; }
.plan-grid__title { text-align: center; color: var(--ink); font-size: clamp(1.3rem, 2.6vw, 1.7rem); margin: 0 0 1.4rem; }
.plan-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 1.2rem; }
.plan-thumb { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--pearl); box-shadow: var(--shadow); transition: transform 0.25s ease, box-shadow 0.25s ease; }
.plan-thumb:hover { transform: translateY(-4px); box-shadow: 0 26px 50px -24px rgba(16,32,43,0.5); }
.plan-thumb__zoom { display: block; width: 100%; padding: 0; border: 0; background: #fff; cursor: zoom-in; }
.plan-thumb__zoom:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: -3px; }
.plan-thumb img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #fff; }
.plan-thumb span { display: block; padding: 0.7rem 0.9rem; font-size: 0.88rem; color: var(--text-soft); border-top: 1px solid var(--line); margin-top: auto; }
.plan-thumb strong { display: block; font-family: var(--display); font-size: 1.15rem; color: var(--ink); line-height: 1.1; margin-bottom: 0.1rem; }
.plan-grid__cta { text-align: center; margin: 1.8rem 0 0; }

/* Gallery */
.gallery { background: var(--pearl-2); }
.gallery__grid { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 160px; gap: 1rem; }
.gtile { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: var(--ink-2); }
.gtile__zoom { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.gtile__zoom:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: -3px; }
.gtile img { width: 100%; height: 100%; object-fit: cover; }
.gtile--wide { grid-column: span 2; grid-row: span 2; }
.gtile figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 0.7rem 0.9rem; color: #fff; font-size: 0.85rem; font-weight: 500; background: linear-gradient(transparent, rgba(10,20,27,0.82)); }
.gallery__cta { text-align: center; margin: 1.8rem 0 0; display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }
.gallery__cta a:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; }

/* Location */
.location { background: var(--paper); }
.map-frame { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line); aspect-ratio: 16 / 8; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.map-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Location tables */
.loc-tables { display: grid; grid-template-columns: 1fr; gap: 1.4rem; margin-top: clamp(2rem, 5vw, 3.5rem); align-items: start; }
@media (min-width: 861px) { .loc-tables { grid-template-columns: repeat(3, 1fr); } }
.loc-table { background: var(--pearl); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem; transition: background 0.2s ease, border-color 0.2s ease; }
.loc-table:not([open]) { background: transparent; border-color: transparent; padding: 0.3rem 0; }
.loc-table:not([open]) > summary { margin-bottom: 0; }
.loc-table h3 { color: var(--ink); font-size: 1.3rem; margin-bottom: 0.7rem; }
.loc-table table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.loc-table th, .loc-table td { text-align: left; padding: 0.45rem 0.5rem; border-bottom: 1px solid var(--line); font-size: 0.86rem; vertical-align: top; overflow-wrap: break-word; }
.loc-table th:nth-child(1), .loc-table td:nth-child(1) { width: 38%; }
.loc-table th:nth-child(2), .loc-table td:nth-child(2) { width: 30%; }
.loc-table th:nth-child(3), .loc-table td:nth-child(3) { width: 32%; }
.loc-table thead th { color: var(--sea); font-family: var(--sans); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; white-space: normal; }
.loc-table td:nth-child(2) { color: var(--sea); font-weight: 600; }

/* Contact */
.contact { background: var(--ink); color: var(--on-dark); text-align: center; }
.contact__inner { max-width: 720px; margin: 0 auto; }
.contact .eyebrow { color: var(--gold-soft); }
.contact h2 { color: #fff; font-size: clamp(1.9rem, 4.4vw, 2.8rem); }
.contact__lead { color: var(--on-dark); font-size: 1.05rem; margin: 0 auto 1.8rem; max-width: 60ch; }
.contact__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; justify-content: center; margin-bottom: 1rem; }
.contact__actions .btn--ghost { color: var(--on-dark); }
.contact__reassure { color: var(--on-dark-soft); font-size: 0.9rem; margin: 0 0 2rem; }
.contact__meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1.2rem; text-align: left; border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1.8rem; margin: 0; }
.contact__meta dt { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold-soft); margin-bottom: 0.25rem; }
.contact__meta dd { margin: 0; font-size: 0.95rem; color: var(--on-dark); }

/* Footer */
.site-footer { background: #0b171f; color: var(--on-dark-soft); padding-block: clamp(2.4rem, 5vw, 3.4rem); }
.footer__brand { font-family: var(--display); font-size: 1.4rem; color: var(--on-dark); margin: 0 0 0.9rem; }
.footer__brand em { color: var(--gold-soft); font-style: italic; }
.footer__disclaimer { font-size: 0.8rem; line-height: 1.7; max-width: 90ch; margin: 0 0 1rem; text-wrap: pretty; }
@media (min-width: 1120px) { .footer__disclaimer { white-space: nowrap; max-width: none; font-size: 0.72rem; } }
.footer__disclaimer-cta { margin: 0 0 1.2rem; }
.footer__copy { font-size: 0.8rem; margin: 0; opacity: 0.75; }

/* Floating WhatsApp */
.wa-float {
  position: fixed; right: clamp(1rem, 3vw, 1.6rem); bottom: clamp(1rem, 3vw, 1.6rem); z-index: 120;
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: #25d366; color: #073b1f; text-decoration: none; font-weight: 700; font-size: 0.95rem;
  padding: 0.7rem 1.1rem; border-radius: 999px; box-shadow: 0 14px 30px -10px rgba(37,211,102,0.7);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.wa-float:hover { transform: translateY(-3px); box-shadow: 0 20px 36px -10px rgba(37,211,102,0.85); }
.wa-float:focus-visible { outline: 3px solid #073b1f; outline-offset: 3px; }

/* ============================================================
   Amenities visualization (radial ring map)
   Positioning here; motion.css handles reveal/hover/filter.
   ============================================================ */
#amenities {
  --cat-education: var(--c-education);
  --cat-medical: var(--c-medical);
  --cat-lifestyle: var(--c-lifestyle);
  --cat-hotels: var(--c-hotels);
  margin-top: clamp(1rem, 3vw, 2rem);
}
.amenities__intro { text-align: center; max-width: 620px; margin: 0 auto 1.4rem; }
.amenities__title { color: var(--ink); font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
.amenities__lead { color: var(--text-soft); margin: 0; }
.amenities__legend { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; margin-bottom: 1.4rem; }
.legend__item {
  font-family: var(--sans); font-weight: 600; font-size: 0.85rem;
  border: 1.5px solid var(--pin-accent, var(--sea)); color: var(--pin-accent, var(--sea));
  background: transparent; border-radius: 999px; padding: 0.4rem 1rem; min-height: 38px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 0.4rem; transition: background 0.2s ease, color 0.2s ease;
}
.legend__item::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--pin-accent, var(--sea)); }
.legend__item[aria-pressed="true"] { background: var(--pin-accent, var(--sea)); color: #fff; }
.legend__item[aria-pressed="true"]::before { background: #fff; }

.amenities__map {
  position: relative; width: min(560px, 92vw); aspect-ratio: 1 / 1; margin: 0 auto;
  color: var(--sea);
}
.map__base { position: absolute; inset: 0; color: var(--sea); }
.map__base svg { width: 100%; height: 100%; }
.map__hub {
  position: absolute; left: 50%; top: 50%; width: 44px; margin: -34px 0 0 -22px;
  color: var(--gold); z-index: 4; filter: drop-shadow(0 4px 8px rgba(184,134,59,0.4));
}
.map__hub svg { width: 100%; height: auto; }

.map__pins { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; }
.map__pin { position: absolute; width: 44px; height: 44px; margin: -22px 0 0 -22px; color: var(--pin-accent, var(--sea)); }
.pin__icon {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--pin-accent, var(--sea)); color: var(--pin-accent, var(--sea));
  box-shadow: 0 6px 14px -6px rgba(16,32,43,0.5); cursor: pointer;
}
.pin__icon svg { width: 22px; height: 22px; }
.pin__label {
  position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%);
  width: max-content; max-width: 220px; background: var(--ink); color: #fff;
  font-size: 0.78rem; line-height: 1.35; padding: 0.5rem 0.7rem; border-radius: 8px;
  box-shadow: var(--shadow); z-index: 6; pointer-events: none; text-align: center;
}
.pin__label::after { content: ""; position: absolute; left: 50%; top: 100%; transform: translateX(-50%); border: 6px solid transparent; border-top-color: var(--ink); }
@media (max-width: 520px) { .pin__label { max-width: min(200px, 62vw); } }
.pin__dist { display: block; font-style: normal; color: var(--gold-soft); font-weight: 600; margin-top: 0.15rem; }

/* Ring placement (0.5 km r=11.25%, 1 km r=22.5%, 1.5 km r=33.75%, 2 km r=45%) */
#pin-disted     { left: 58%; top: 42%; }   /* 0.5 ring */
#pin-island     { left: 58%; top: 58%; }
#pin-market     { left: 42%; top: 58%; }
#pin-lohguanlye { left: 42%; top: 42%; }
#pin-gleneagles { left: 71%; top: 42%; }   /* 1 ring */
#pin-gurney     { left: 29%; top: 58%; }
#pin-marriott   { left: 82%; top: 61%; }   /* 1.5 ring */
#pin-adventist  { left: 18%; top: 39%; }
#pin-wawasan    { left: 76%; top: 87%; }   /* 2 ring */

/* ============================================================
   Scroll reveal
   ============================================================ */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .nav__cta { margin-left: auto; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; margin-left: 0;
    background: rgba(12, 26, 35, 0.98); backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.4rem var(--pad) 0.8rem;
    max-height: 0; overflow: hidden; opacity: 0; visibility: hidden;
    transition: max-height 0.3s ease, opacity 0.25s ease, visibility 0.25s ease;
  }
  .is-nav-open .nav { max-height: 70vh; opacity: 1; visibility: visible; }
  .nav a { display: block; padding: 0.85rem 0.2rem; min-height: 44px; font-size: 1rem; border-bottom: 1px solid rgba(255, 255, 255, 0.07); }
  .details__grid { grid-template-columns: 1fr; }
  .plan-block { grid-template-columns: 1fr; }
  .story__stats { grid-template-columns: repeat(2, 1fr); }
  .gallery__grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 140px; }
  .gtile--wide { grid-column: span 2; grid-row: span 1; }
}
@media (max-width: 520px) {
  .brand { font-size: 1.05rem; white-space: nowrap; }
  .nav__cta { display: none; }
  .nav-toggle { flex: 0 0 44px; margin-left: auto; }
  .hero__price { gap: 0.4rem; }
  .story__stats { grid-template-columns: 1fr 1fr; }
  .wa-float span { display: none; }
  .wa-float { padding: 0.75rem; }
  .map__pin, .pin__icon { width: 38px; height: 38px; }
  .map__pin { margin: -19px 0 0 -19px; }
  .pin__icon { margin: 0; }
}

/* ============================================================
   Lightbox (shared: floor plans, site plan, gallery)
   ============================================================ */
.lightbox {
  position: fixed; inset: 0; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  padding: clamp(1.5rem, 5vw, 4rem);
  background: rgba(10, 20, 27, 0.92);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}
.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
.lightbox__img {
  max-width: min(1200px, 94vw); max-height: 88vh;
  width: auto; height: auto; object-fit: contain;
  border-radius: var(--radius); box-shadow: 0 30px 80px -20px rgba(0,0,0,0.8);
  background: #fff;
  transform: scale(0.96); transition: transform 0.35s ease;
}
.lightbox.is-open .lightbox__img { transform: scale(1); }
.lightbox__caption {
  position: absolute; left: 0; right: 0; bottom: clamp(1rem, 3vw, 2rem);
  text-align: center; color: rgba(255,255,255,0.82);
  font-size: 0.85rem; letter-spacing: 0.03em; padding: 0 1.5rem;
}
.lightbox__close, .lightbox__nav {
  position: absolute; z-index: 2; width: 46px; height: 46px; border-radius: 50%;
  background: rgba(16, 32, 43, 0.6); border: 1px solid rgba(255, 255, 255, 0.55);
  color: #fff; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  transition: background 0.3s ease, border-color 0.3s ease;
}
.lightbox__close { top: clamp(1rem, 3vw, 2rem); right: clamp(1rem, 3vw, 2rem); font-size: 1.5rem; }
.lightbox__nav { top: 50%; transform: translateY(-50%); font-size: 2rem; }
.lightbox__nav--prev { left: clamp(0.8rem, 3vw, 2.2rem); }
.lightbox__nav--next { right: clamp(0.8rem, 3vw, 2.2rem); }
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(16, 32, 43, 0.85); border-color: var(--gold-soft); }
.lightbox__close:focus-visible, .lightbox__nav:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; }
@media (max-width: 520px) { .lightbox__nav { width: 40px; height: 40px; font-size: 1.6rem; } }

/* ============================================================
   Collapsible detail (open on desktop, collapsed on mobile)
   ============================================================ */
.disclose { border: 0; }
.disclose > summary {
  display: flex; align-items: center; justify-content: space-between; gap: 0.8rem;
  min-height: 44px; cursor: pointer; list-style: none;
  font-family: var(--display); font-size: 1.3rem; color: var(--ink);
  padding: 0.3rem 0; margin-bottom: 0.7rem;
}
.disclose > summary::-webkit-details-marker { display: none; }
.disclose > summary::after {
  content: ""; flex: none; width: 0.7rem; height: 0.7rem;
  border-right: 2px solid var(--sea); border-bottom: 2px solid var(--sea);
  transform: rotate(45deg); transition: transform 0.25s ease;
}
.disclose[open] > summary::after { transform: rotate(-135deg); }
.disclose > summary:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 3px; border-radius: 4px; }

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .wa-float, .plan-thumb, .nav { transition: none; }
  .lightbox, .lightbox__img { transition: none; }
  .lightbox__img { transform: none; }
  .disclose > summary::after { transition: none; }
}
