/* ==========================================================================
   Responsive enhancements (min-width, progressive) + reduced motion
   ========================================================================== */

/* ≥ 480px — large phones */
@media (min-width: 480px) {
  .hero-ctas { grid-template-columns: auto auto; justify-content: start; }
  .hero-stats { grid-template-columns: repeat(4, auto); justify-content: start; border-top: 0; }
  .hero-stats li, .hero-stats li:nth-child(odd), .hero-stats li:nth-child(even) {
    padding: 0 22px; border: 0; border-left: 1px solid var(--line-light);
  }
  .hero-stats li:first-child { padding-left: 0; border-left: 0; }
  .amenity-icons { grid-template-columns: repeat(3, 1fr); }
  .slider-track { grid-auto-columns: 60%; }
  .gallery-grid { grid-auto-rows: 190px; }
}

/* ≥ 640px — small tablets */
@media (min-width: 640px) {
  :root { --gutter: 24px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .stat { padding: 36px 28px 36px 0; }
  .stat:nth-child(even) { padding-left: 28px; border-left: 1px solid var(--line-light); }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .plan-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .g-item.g-tall { grid-row: span 2; }
  .developer-logo { padding: 40px; }
  .developer-logo img { width: 160px; }
  .specs-items { grid-template-columns: repeat(2, 1fr); gap: 16px 32px; }
  .spec-list { grid-template-columns: repeat(3, 1fr); }
  .spec-list > div:nth-child(odd) { padding-right: 0; }
  .spec-list > div { padding-right: 12px !important; }
  .dev-stats { grid-template-columns: repeat(4, 1fr); }
  .dev-stats li { padding-right: 12px; }
  .modal { place-items: center; padding: 24px; }
  .modal-dialog { border-radius: var(--radius-lg); max-width: 480px; }
  .modal-body { padding: 40px 36px 36px; }
  .contact-card, .hero-form-card { padding: 36px 32px; }
  .hero-copy { padding: 36px 32px; }
  .hero-media { height: calc(var(--header-h) + 52vw); max-height: min(60svh, 520px); }
  .section-head-split { grid-template-columns: 1fr auto; align-items: end; gap: 2rem; }
  .map-wrap { aspect-ratio: 16 / 10; }
}

/* ≥ 900px — tablets landscape / small laptops */
@media (min-width: 900px) {
  :root { --header-h: 84px; --gutter: 32px; }
  .brand-logo { width: 40px; }
  .site-header.is-scrolled { height: 72px; }
  .site-header.is-scrolled .brand-logo { width: 34px; }
  .header-cta { display: inline-flex; }

  /* Hero: two equal cards pinned to the left and right edges along the bottom,
     so the towers stay visible above and between them */
  .hero { min-height: 100vh; min-height: 100svh; justify-content: flex-end; }
  .hero-media { position: absolute; inset: 0; height: auto; max-height: none; }
  .hero-grid {
    margin-top: 0;
    grid-template-columns: minmax(0, 390px) minmax(0, 390px); justify-content: space-between;
    align-items: stretch; gap: 24px;
    padding-top: calc(var(--header-h) + 20px); padding-bottom: 32px;
  }
  .hero-img { object-position: 50% 40%; }
  /* The cards are opaque, so only the header band and the bottom edge need darkening */
  .hero-scrim {
    background:
      linear-gradient(to bottom, rgba(10, 19, 28, 0.6) 0%, rgba(10, 19, 28, 0) 22%),
      linear-gradient(to top, rgba(10, 19, 28, 0.45) 0%, rgba(10, 19, 28, 0) 35%);
  }
  .hero-form-card { background: rgba(247, 244, 238, 0.96); backdrop-filter: blur(10px); }

  /* Compact hero card: same width as the form card */
  .hero-copy, .hero-form-card { padding: 24px 28px; display: flex; flex-direction: column; justify-content: center; }
  .hero-copy { max-width: none; }
  .hero-copy .eyebrow, .hero-form-card .eyebrow { margin-bottom: .5rem; font-size: .7rem; letter-spacing: .16em; }
  .hero-copy .hero-kicker { font-size: 1.05rem; margin-bottom: .15rem; }
  .hero-copy .hero-title { font-size: 2.6rem; margin-bottom: .5rem; }
  .hero-copy .hero-title-pre { font-size: .4em; margin-bottom: .25em; }
  .hero-copy .hero-lede { font-size: .95rem; max-width: none; }
  .hero-copy .hero-stats {
    grid-template-columns: repeat(4, auto); justify-content: space-between; margin: .9rem 0;
    padding: 10px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  }
  .hero-copy .hero-stats li, .hero-copy .hero-stats li:nth-child(odd), .hero-copy .hero-stats li:nth-child(even) {
    padding: 0 0 0 12px; border: 0; border-left: 1px solid var(--line);
  }
  .hero-copy .hero-stats li:first-child { padding-left: 0; border-left: 0; }
  .hero-copy .hero-stats strong { font-size: 1.3rem; }
  .hero-copy .hero-stats span { font-size: .62rem; letter-spacing: .12em; }
  .hero-copy .hero-ctas { grid-template-columns: 1fr; gap: 8px; }
  .hero-copy .hero-ctas .btn { min-height: 44px; padding-block: 10px; }

  /* Hero form: name + mobile on one row, email below */
  .hero-form-card .hero-form-title { font-size: 1.45rem; margin-bottom: .7rem; }
  .hero-form-card .lead-form { gap: 12px; }
  .hero-form-card .lf-grid { grid-template-columns: 1fr 1fr; gap: 8px 16px; }
  .hero-form-card .field input { font-size: .95rem; min-height: 42px; }
  .hero-form-card .lf-alt { font-size: .8rem; }
  .hero-form-card .field[data-field="email"] { grid-column: 1 / -1; }
  .hero-scroll {
    display: block; position: absolute; left: 50%; bottom: 24px; width: 1px; height: 48px; overflow: hidden;
    background: var(--line-light); transform: translateX(-50%);
  }
  .hero-scroll span { position: absolute; left: 0; top: -50%; width: 1px; height: 50%; background: var(--gold-soft); animation: scrollCue 2s var(--ease) infinite; }
  @keyframes scrollCue { to { top: 100%; } }

  .overview-grid { grid-template-columns: 1fr 1.08fr; gap: 72px; align-items: center; }
  .overview-media { padding-bottom: 96px; padding-left: 40px; }
  .overview-inset { width: 52%; right: -16px; }
  .overview-badge { left: 0; bottom: 24px; }

  .stat-grid { grid-template-columns: repeat(3, 1fr); }
  .stat, .stat:nth-child(even) { padding: 44px 32px; border-left: 1px solid var(--line-light); }
  .stat:nth-child(3n + 1) { padding-left: 0; border-left: 0; }

  .amenity-feature { grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: start; }
  .amenity-feature-media { aspect-ratio: 5 / 6; position: sticky; top: calc(var(--header-h) + 24px); }
  .amenity-hero-callout { padding: 36px 32px; }
  .amenity-icons { grid-template-columns: repeat(2, 1fr); }
  .slider-track { grid-auto-columns: calc((100% - 32px) / 3); }

  .price-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }

  .plan-grid { grid-template-columns: repeat(3, 1fr); }

  .gallery-grid { grid-template-columns: repeat(4, 1fr); grid-auto-rows: 200px; gap: 14px; }

  .location-grid { grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
  .tab-list { flex-wrap: wrap; overflow: visible; margin-inline: 0; padding: 0; -webkit-mask-image: none; mask-image: none; }

  .developer-grid { grid-template-columns: 0.8fr 1.2fr; gap: 72px; }
  .developer-logo { padding: 64px; }
  .developer-logo img { width: 200px; }

  .contact-grid { grid-template-columns: 1fr 460px; gap: 80px; }

  .faq-grid { grid-template-columns: 0.8fr 1.4fr; gap: 80px; align-items: start; }
  .faq-head { position: sticky; top: calc(var(--header-h) + 32px); }
  .acc-btn { font-size: 1.5rem; }

  .footer-top { grid-template-columns: 1.2fr 1.4fr auto; align-items: center; }
  .site-footer { padding-bottom: 40px; }

  .mobile-bar { display: none; }
  .fab-whatsapp { display: grid; }

  /* Simple single-column form modal */
  .modal-dialog { max-width: 480px; overflow: hidden; max-height: 90vh; }
  .modal-body { overflow-y: auto; max-height: 90vh; }
  .lb-prev { left: 24px; }
  .lb-next { right: 24px; }
  .lb-stage { padding: 0 96px; }
}

/* ≥ 1200px — desktop: full inline navigation */
@media (min-width: 1200px) {
  .nav-toggle { display: none; }
  .primary-nav {
    position: static; inset: auto; padding: 0; background: none; opacity: 1; visibility: visible;
    flex-direction: row; overflow: visible;
  }
  .primary-nav ul { flex-direction: row; gap: 4px; }
  .primary-nav li a {
    font-family: var(--font-sans); font-size: 0.8125rem; font-weight: 500; letter-spacing: .06em;
    padding: 8px 10px; border: 0; position: relative; color: rgba(247, 244, 238, .86);
  }
  .primary-nav li a::after {
    content: ''; position: absolute; left: 10px; right: 10px; bottom: 2px; height: 1px; background: var(--gold-soft);
    transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease);
  }
  .primary-nav li a:hover, .primary-nav li a.is-active { color: var(--white); }
  .primary-nav li a:hover::after, .primary-nav li a.is-active::after { transform: scaleX(1); }
  .nav-mobile-foot { display: none; }
  .header-phone { display: inline-flex; }

  .hero-grid { grid-template-columns: minmax(0, 420px) minmax(0, 420px); }
  .hero-copy, .hero-form-card { padding: 26px 32px; }
  .price-grid { gap: 24px; }
  .price-card { padding: 34px 30px; }
  .gallery-grid { grid-auto-rows: 230px; }
}

/* ≥ 1600px — large screens */
@media (min-width: 1600px) {
  :root { --container: 1400px; }
  .gallery-grid { grid-auto-rows: 270px; }
}

/* Short, wide viewports (e.g. 1366×650 laptops): keep the hero compact */
@media (min-width: 900px) and (max-height: 760px) {
  .hero-grid { padding-top: calc(var(--header-h) + 12px); padding-bottom: 16px; }
  .hero-copy, .hero-form-card { padding-block: 20px; }
  .hero-copy .hero-title { font-size: clamp(2.1rem, 6.5vh, 2.6rem); }
  .hero-copy .hero-stats { margin: .7rem 0; padding: 8px 0; }
  .hero-copy .hero-ctas .btn { min-height: 40px; padding-block: 8px; }
  .hero-form-card .hero-form-title { font-size: 1.3rem; margin-bottom: .5rem; }
  .hero-form-card .lead-form { gap: 10px; }
  .hero-form-card .lf-grid { gap: 4px 16px; }
  .hero-form-card .field input { min-height: 38px; }
  .hero-scroll { display: none; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .hero-img { transform: none; }
  .js .reveal { opacity: 1; transform: none; }
  .js .img-reveal img { transform: none; }
}
