/* ============================================================
   halves-motion — utilidades de motion compartidas (marketing)
   ============================================================
   Complementa a tokens.css (no lo sustituye): asume que las
   variables de marca (--grad-brand, --accent, --accent-alt,
   --border) ya están definidas por la superficie .landing /
   .surface-editorial de tokens.css.

   Uso:
     - [data-hv-reveal]  → fade+rise al entrar en scroll. Requiere
       halves-motion.js para añadir la clase `.in`. Sin JS (o con
       prefers-reduced-motion), degrada a visible por defecto vía
       la regla @media incluida aquí + un <noscript> en la página
       que fuerce opacity:1 (ver ejemplo en halves-io/frontend/landing).
     - .hv-glow-orb, .hv-glow-orb--a / --b → orbes de luz ambiental
       de fondo, decorativos. Van dentro de un contenedor con
       position:relative y overflow:hidden.
     - .hv-text-sheen → brillo lento en degradado de marca sobre
       texto (titulares). Aplica junto a background-clip:text.
     - .hv-ticker / .hv-ticker-track → marquee horizontal infinito
       (lista duplicada dos veces en el HTML; la segunda con
       aria-hidden="true").

   Origen: extraído 2026-08-01 del brochure de Halves Platform
   (halves-io/frontend/landing/platform.html) para compartirlo
   con el tema WordPress (halves-plugins) y evitar reimplementar
   el mismo motion dos veces.

   Sincronizado a mano en:
     - halves-io/frontend/src/styles/halves-motion.css
     - halves-plugins/connectors/wordpress/halves-theme/assets/css/halves-motion.css
   vía bin/sync-design.sh (halves-plugins).
   ============================================================ */

/* ── reveal-on-scroll ─────────────────────────────────────────── */
[data-hv-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--hv-ease, cubic-bezier(.22, .61, .36, 1)),
              transform .7s var(--hv-ease, cubic-bezier(.22, .61, .36, 1));
}
[data-hv-reveal].in {
  opacity: 1;
  transform: none;
}

/* ── orbes de luz ambiental ───────────────────────────────────── */
.hv-glow-orb {
  content: "";
  position: absolute;
  width: 60vmax;
  height: 60vmax;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: -1;
}
.hv-glow-orb--a {
  background: radial-gradient(circle, color-mix(in srgb, var(--accent-color, var(--accent)) 26%, transparent), transparent 62%);
  animation: hv-drift-a 22s ease-in-out infinite alternate;
}
.hv-glow-orb--b {
  background: radial-gradient(circle, color-mix(in srgb, var(--accent-alt) 22%, transparent), transparent 62%);
  animation: hv-drift-b 26s ease-in-out infinite alternate;
}
@keyframes hv-drift-a { from { transform: translate(0, 0); } to { transform: translate(6vmax, 4vmax); } }
@keyframes hv-drift-b { from { transform: translate(0, 0); } to { transform: translate(-6vmax, -4vmax); } }

/* ── brillo en texto con degradado de marca ───────────────────── */
.hv-text-sheen {
  background: var(--grad-brand);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: hv-grad-sheen 7s ease-in-out infinite alternate;
}
@keyframes hv-grad-sheen {
  from { background-position: 0% 50%; }
  to   { background-position: 100% 50%; }
}

/* ── ticker horizontal infinito ───────────────────────────────── */
.hv-ticker {
  overflow: hidden;
}
.hv-ticker-track {
  display: flex;
  gap: 3.5rem;
  width: max-content;
  animation: hv-ticker 30s linear infinite;
}
@keyframes hv-ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ── degradación: sin motion ──────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  [data-hv-reveal] { opacity: 1; transform: none; transition: none; }
  .hv-glow-orb--a, .hv-glow-orb--b { animation: none; }
  .hv-text-sheen { animation: none; }
  .hv-ticker-track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; }
  .hv-ticker-track [aria-hidden="true"] { display: none; }
}
