/* ==========================================================================
   DRAGON MOTION KIT — dragon-motion.css
   House upgrade style: premium animated scroll + 3D motion for Dragon
   fleet sites and data views. Dragon-branded, $0, our own wording, our
   own code. Source: reference-ledger entry (Viktor / MotionSites reel
   DdpN5LRAFYm) — the reel's STYLE only (scroll animation, 3D motion,
   premium animated site). No prompt, library, file, or content of his
   was used, seen, or copied; his claims are HIS, UNVERIFIED.
   Pairs with: Textura memorable-moment standard (M1-M9), Dragon MDX
   Design System (entry 808), Dragon UI Colour Bank (entry 807).
   Rules: dependency-free. No external URLs, no webfonts, no images,
   no WebGL required (flat is the fallback, never a blank box).
   Presentation only — never touches forms, capture endpoints, or
   money rails. One palette per surface (bank 807); gold #d4af37 stays
   the house accent. Reduced-motion is respected (M6).
   Scoping: every rule lives under .dm-motion (added to <html> by
   dragon-motion.js). No global resets — existing page styles win.
   ========================================================================== */

.dm-motion .dm-reveal {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.7s ease,
    transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
  will-change: opacity, transform;
}

.dm-motion .dm-reveal.dm-in {
  opacity: 1;
  transform: none;
}

/* Stagger: children of [data-dm-stagger] reveal in sequence. */
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(1) { transition-delay: 0.05s; }
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(2) { transition-delay: 0.14s; }
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(3) { transition-delay: 0.23s; }
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(4) { transition-delay: 0.32s; }
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(5) { transition-delay: 0.41s; }
.dm-motion [data-dm-stagger] > .dm-reveal:nth-child(6) { transition-delay: 0.5s; }

/* 3D tilt cards: pointer-reactive, small angles, settles back. */
.dm-motion .dm-tilt {
  transform-style: preserve-3d;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  will-change: transform;
}

.dm-motion .dm-tilt:hover {
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(212, 175, 55, 0.35);
}

/* Gold glow wash for a hero or moment band. Opt-in only. */
.dm-motion .dm-glow {
  position: relative;
  isolation: isolate;
}

.dm-motion .dm-glow::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 45% at 50% 0%, rgba(212, 175, 55, 0.16) 0%, rgba(212, 175, 55, 0) 70%);
}

/* Animated counters on data views. */
.dm-motion [data-dm-count] {
  font-variant-numeric: tabular-nums;
}

/* Subtle scroll parallax. Opt-in only, small distances. */
.dm-motion [data-dm-parallax] {
  will-change: transform;
}

/* Reduced motion: everything visible, nothing moves. */
@media (prefers-reduced-motion: reduce) {
  .dm-motion .dm-reveal,
  .dm-motion [data-dm-stagger] > .dm-reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .dm-motion .dm-tilt {
    transition: none !important;
  }
  .dm-motion [data-dm-parallax] {
    transform: none !important;
  }
}
