/* ============================================================
   Enhance — lapisan "mewah tapi minimalis": motion halus,
   micro-interaction, dan perbaikan ergonomi/aksesibilitas.
   Semua animasi dibungkus prefers-reduced-motion.
   ============================================================ */

/* ---------- Smooth scroll + offset untuk sticky nav ---------- */
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 96px; }

/* ---------- Eyebrow refined: garis aksen oranye + label kontras ---------- */
/* Latar terang: label navy (lolos kontras), aksen garis oranye. */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
  font-size: 0.72rem;
  color: var(--cp-primary, #1e3c66);
}
.eyebrow::before {
  content: "";
  width: 1.75rem;
  height: 2px;
  background: #eda12b;
  flex: none;
}
/* Latar gelap (hero, header, testimoni): label oranye tetap, garis oranye. */
.eyebrow-invert { color: #eda12b; }
.eyebrow-invert::before { background: currentColor; opacity: 0.9; }
/* Versi rata-tengah (mis. heading section testimoni) */
.eyebrow-center { justify-content: center; }

/* ---------- Panjang baris nyaman ---------- */
.measure { max-width: 62ch; }

/* ---------- Reveal: variasi lebih kaya ---------- */
@media (prefers-reduced-motion: no-preference) {
  /* image wipe untuk ilustrasi fitur */
  .reveal-img {
    transition: clip-path 1.1s cubic-bezier(0.22, 0.61, 0.36, 1),
      transform 1.2s cubic-bezier(0.22, 0.61, 0.36, 1);
    clip-path: inset(0 0 0 0);
  }
  .reveal:not(.in) .reveal-img {
    clip-path: inset(0 100% 0 0);
    transform: scale(1.06);
  }

  /* Ken Burns pada slide hero aktif */
  [data-carousel="hero"] [data-slide] { transform: scale(1.02); transform-origin: center; }
  [data-carousel="hero"] [data-slide].active {
    animation: cp-kenburns 7s ease-out forwards;
  }
  @keyframes cp-kenburns {
    from { transform: scale(1.02); }
    to { transform: scale(1.12); }
  }
}

/* ---------- Hover lift kartu (mewah, halus) ---------- */
#property-list a,
#home-promos a,
#home-promos article {
  transition: transform 0.45s cubic-bezier(0.22, 0.61, 0.36, 1),
    box-shadow 0.45s cubic-bezier(0.22, 0.61, 0.36, 1);
}
@media (prefers-reduced-motion: no-preference) {
  #property-list a:hover,
  #home-promos a:hover {
    transform: translateY(-6px);
    box-shadow: 0 26px 50px -28px rgba(30, 60, 102, 0.45);
  }
}

/* ---------- Tombol: micro-lift + panah geser ---------- */
.btn,
a.bg-secondary,
a.bg-primary {
  transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}
@media (prefers-reduced-motion: no-preference) {
  a.bg-secondary:hover,
  a.bg-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px -16px rgba(30, 60, 102, 0.5);
  }
}

/* ---------- Kartu statis: hover halus ---------- */
.card-soft {
  transition: transform 0.4s cubic-bezier(0.22, 0.61, 0.36, 1),
    box-shadow 0.4s ease, border-color 0.4s ease;
}
@media (prefers-reduced-motion: no-preference) {
  .card-soft:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 46px -30px rgba(30, 60, 102, 0.45);
    border-color: rgba(30, 60, 102, 0.3);
  }
}

/* ---------- Empty state ---------- */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 3.5rem 1rem;
}
.empty-state svg { width: 3rem; height: 3rem; color: var(--cp-outline, #dadada); margin-bottom: 1rem; }

/* ---------- Navbar: bayangan halus saat scroll ---------- */
#site-nav nav {
  transition: box-shadow 0.35s ease, background-color 0.35s ease;
}
#site-nav nav.nav-scrolled {
  box-shadow: 0 12px 34px -22px rgba(0, 0, 0, 0.4);
  background-color: rgba(255, 255, 255, 0.97);
}

/* ---------- Aksesibilitas: focus terlihat ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid #eda12b;
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---------- Showcase cluster: gambar fade saat ganti tipe ---------- */
@media (prefers-reduced-motion: no-preference) {
  .cp-img-fade { animation: cp-img-fade 0.5s ease both; }
  @keyframes cp-img-fade {
    from { opacity: 0; transform: scale(1.03); }
    to { opacity: 1; transform: none; }
  }
}

/* ---------- Detail properti: fade-up saat konten dimuat ---------- */
@media (prefers-reduced-motion: no-preference) {
  #detail-root.detail-in { animation: cp-detail-rise 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) both; }
  @keyframes cp-detail-rise {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: none; }
  }
}

/* ---------- Carousel hero: transisi sedikit lebih panjang utk kesan kalem ---------- */
[data-carousel="hero"] .carousel-slide { transition: opacity 1s ease; }
