/* ==========================================================================
   Ulomi Homes — Motion & Atmosphere layer
   Additive only. No changes to layout, color, typography, or spacing.
   Everything here is disabled for visitors who prefer reduced motion.
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {

  /* --- Home hero: slow cinematic zoom (Ken Burns) --------------------- */
  .hero-bg {
    animation: uh-kenburns 26s ease-in-out infinite alternate;
    transform-origin: center;
    will-change: transform;
  }
  @keyframes uh-kenburns {
    from { transform: scale(1); }
    to   { transform: scale(1.08); }
  }

  /* --- Hero content: one-time gentle fade-up on load ------------------ */
  #page-home .hero-h1,
  #page-home .hero-rule,
  #page-home .hero-actions {
    opacity: 0;
    animation: uh-heroRise 1.1s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
  }
  #page-home .hero-h1     { animation-delay: 0.25s; }
  #page-home .hero-rule   { animation-delay: 0.55s; }
  #page-home .hero-actions{ animation-delay: 0.8s; }
  @keyframes uh-heroRise {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: none; }
  }

  /* --- Community cards: gentle image zoom on hover -------------------- */
  #page-home .cc { overflow: hidden; }
  #page-home .cc-thumb {
    transition: transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform;
  }
  #page-home .cc:hover .cc-thumb { transform: scale(1.06); }

  /* --- Homes editorial rows: barely-there image zoom on hover ---------- */
  #page-home .hr-img {
    transition: transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform;
  }
  #page-home .home-row:hover .hr-img { transform: scale(1.04); }

  /* --- Scroll reveal: fade + gentle rise (all pages) ----------------- */
  .uh-reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 1s ease, transform 1s cubic-bezier(0.22, 0.61, 0.36, 1);
  }
  .uh-reveal.uh-in {
    opacity: 1;
    transform: none;
  }
}

/* --- Community hero: matching slow zoom ------------------------------
   Added as a ::before layer so it is clipped by the hero's existing
   overflow:hidden and sits behind the darkening overlay. Scoped below
   1600px so the deliberate "framed on dark mat" ultrawide treatment
   (which uses ::after) is left completely untouched. ----------------- */
@media (prefers-reduced-motion: no-preference) and (max-width: 1599px) {
  .detail-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    background-image: var(--hero-img);
    background-size: cover;
    background-position: center;
    animation: uh-kenburns 30s ease-in-out infinite alternate;
    transform-origin: center;
    will-change: transform;
  }
  .detail-hero--pointe::before  { background-position: center 35%; }
  .detail-hero--echelon::before { background-position: center 30%; }
  .detail-hero--manor::before   { background-position: center; }
  .detail-hero--estate::before  { background-position: center 40%; }
}
@media (prefers-reduced-motion: no-preference) and (min-width: 1024px) and (max-width: 1599px) {
  .detail-hero--pointe::before  { background-position: center 42%; }
  .detail-hero--echelon::before { background-position: center 47%; }
  .detail-hero--manor::before   { background-position: center; }
  .detail-hero--estate::before  { background-position: center 56%; }
}
