/* Social Nexa — motion layer (red v2): word reveals, stickers, stats, marquee, step demos, comparison.
   Everything here is decoration on top of the real page; reduced-motion users get the static version. */

/* ---------- word-by-word headline ---------- */
.mw { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: .08em; margin-bottom: -.08em; }
.mw > span { display: inline-block; }
.mw-ready .mw > span { transform: translateY(105%) rotate(5deg); opacity: 0; }
.mw-go .mw > span { animation: mwIn .9s cubic-bezier(.2, 1.3, .4, 1) both; animation-delay: var(--d, 0ms); }
@keyframes mwIn { from { transform: translateY(105%) rotate(5deg); opacity: 0; } to { transform: none; opacity: 1; } }
.hero h1 .hl .mw > span { background: linear-gradient(100deg, #e8263e 0%, #ff4d5e 45%, #ff7a3d 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.mw-sticker { display: inline-grid; place-items: center; width: .9em; height: .9em; margin: 0 .12em; border-radius: .28em; vertical-align: -.08em;
  background: linear-gradient(140deg, #ff4d5e, #e8263e); color: #fff; font-size: .82em; line-height: 1; transform: rotate(-8deg);
  box-shadow: 0 12px 24px -12px rgba(232, 38, 62, .8); animation: mPop .9s cubic-bezier(.2, 1.2, .4, 1) .55s both; }
.mw-sticker svg { width: 55%; height: 55%; }
@keyframes mPop { 0% { opacity: 0; transform: scale(0) rotate(-30deg); } 70% { opacity: 1; transform: scale(1.1) rotate(2deg); } 100% { opacity: 1; transform: rotate(-8deg); } }

/* ---------- stickers + chips around the live profile ---------- */
.live-profile .m-stk { position: absolute; z-index: 0; display: grid; place-items: center; color: #fff; font-weight: 800; pointer-events: none;
  animation: mPop .9s cubic-bezier(.2, 1.2, .4, 1) both, mFloat 5s ease-in-out infinite; }
.live-profile .m-stk.s1 { width: 46px; height: 46px; border-radius: 15px; left: -20px; top: -26px; background: linear-gradient(140deg, #ff7a3d, #ffb45e); rotate: -10deg; animation-delay: .9s, 0s; }
.live-profile .m-stk.s2 { width: 36px; height: 36px; border-radius: 50%; left: -16px; bottom: 34px; background: linear-gradient(140deg, #ff4d8d, #e8263e); animation-delay: 1.1s, -2s; }
.live-profile .m-stk.s3 { width: 40px; height: 40px; border-radius: 13px; right: 30%; top: -30px; background: linear-gradient(140deg, #ffd166, #ffb020); color: #1a1416; rotate: 10deg; animation-delay: 1.3s, -1s; }
.live-profile .m-stk svg { width: 50%; height: 50%; }
.m-today { position: absolute; z-index: 3; left: 96px; top: -15px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 99px;
  background: #e9f8ef; color: #17733c; font-weight: 700; font-size: 13px; box-shadow: 0 10px 24px -14px rgba(23, 115, 60, .6); animation: mChip .7s cubic-bezier(.2, 1.3, .4, 1) 1.5s both; }
@keyframes mChip { from { opacity: 0; transform: translateY(8px) scale(.6); } to { opacity: 1; transform: none; } }
.m-dots { display: inline-flex; gap: 3px; margin-left: 4px; }
.m-dots i { width: 5px; height: 5px; border-radius: 50%; background: #c9b9bc; animation: mTyping 1.2s ease-in-out infinite; }
.m-dots i:nth-child(2) { animation-delay: .15s; } .m-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes mTyping { 0%, 70%, 100% { opacity: .35; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
@keyframes mFloat { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }
.live-profile::before { content: ""; position: absolute; z-index: -1; left: 50%; top: 50%; width: 320px; height: 320px; margin: -160px 0 0 -160px; opacity: .6; border-radius: 50%;
  border: 2px dashed color-mix(in srgb, var(--blue, #e8263e) 30%, transparent); animation: mRing 24s linear infinite; pointer-events: none; }
@keyframes mRing { to { rotate: 360deg; } }

/* ---------- stats strip ---------- */
.m-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 28px 0 8px; border: 1px solid var(--outline); border-radius: 22px; background: var(--surface); overflow: hidden; }
.m-stats > div { padding: 20px 16px; text-align: center; position: relative; }
.m-stats > div + div::before { content: ""; position: absolute; left: 0; top: 22%; bottom: 22%; width: 1px; background: var(--outline); }
.m-stats b { display: block; font: 800 34px/1.1 var(--font-display); letter-spacing: -.5px; color: var(--blue, #e8263e); font-variant-numeric: tabular-nums; }
.m-stats span { font-size: 14px; color: var(--muted); }
@media (max-width: 700px) { .m-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .m-stats > div:nth-child(3)::before { display: none; } .m-stats b { font-size: 26px; } }

/* ---------- marquee between sections ---------- */
.m-marquee { position: relative; overflow: hidden; padding: 18px 0; border-block: 1px solid var(--outline); background: var(--surface);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.m-track { display: flex; width: max-content; gap: 14px; animation: mScroll 38s linear infinite; }
.m-marquee:hover .m-track { animation-play-state: paused; }
.m-track span { display: inline-flex; align-items: center; gap: 10px; padding: 9px 18px; border-radius: 99px; border: 1px solid var(--outline); background: var(--bg);
  font: 600 15px var(--font-body); color: var(--fg); white-space: nowrap; }
.m-track span::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: linear-gradient(140deg, #ff4d5e, #ff7a3d); }
@keyframes mScroll { to { transform: translateX(-50%); } }

/* ---------- step demos ---------- */
.steps > li .m-demo { margin-top: 16px; padding: 12px; border-radius: 16px; background: var(--surface); border: 1px solid var(--outline); display: grid; gap: 8px; min-height: 92px; align-content: center; }
.m-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 9px 11px; border-radius: 11px; border: 1.5px solid var(--blue, #e8263e); font-size: 13px; font-weight: 700; }
.m-row em { font-style: normal; color: var(--blue-ink, #b8132a); }
.m-skel { height: 30px; border-radius: 11px; background: linear-gradient(90deg, var(--surface-2) 0%, color-mix(in srgb, var(--surface-2) 40%, #fff) 50%, var(--surface-2) 100%); background-size: 200% 100%; animation: mShimmer 1.3s linear infinite; }
.m-skel + .m-skel { animation-delay: .2s; width: 80%; }
@keyframes mShimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.m-chips { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; font-weight: 700; }
.m-chips span { padding: 5px 9px; border-radius: 9px; background: var(--blue-tint); color: var(--blue-ink); }
.m-wait { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 600; }
.m-spin { width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid color-mix(in srgb, #ff7a3d 30%, transparent); border-top-color: #ff7a3d; animation: mSpin .8s linear infinite; }
@keyframes mSpin { to { rotate: 360deg; } }
.m-ok { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; color: #17733c; }
.m-ok svg path { stroke-dasharray: 24; animation: mTick 2.8s cubic-bezier(.65, 0, .35, 1) infinite; }
@keyframes mTick { 0% { stroke-dashoffset: 24; } 30%, 88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
.m-bars { display: flex; align-items: flex-end; gap: 7px; height: 70px; }
.m-bars i { flex: 1; border-radius: 6px 6px 3px 3px; transform-origin: bottom; animation: mGrow 2.4s cubic-bezier(.2, 1, .3, 1) infinite; }
.m-bars i:nth-child(1) { height: 30%; background: #ffe2a3; } .m-bars i:nth-child(2) { height: 46%; background: #ffc56b; animation-delay: .12s; }
.m-bars i:nth-child(3) { height: 64%; background: #ff9f4a; animation-delay: .24s; } .m-bars i:nth-child(4) { height: 82%; background: #ff7a3d; animation-delay: .36s; }
.m-bars i:nth-child(5) { height: 100%; background: #e8263e; animation-delay: .48s; }
@keyframes mGrow { 0% { transform: scaleY(.2); } 60%, 100% { transform: scaleY(1); } }
.m-paused * { animation-play-state: paused !important; }

/* ---------- animated icons in value cards ---------- */
.value-grid > article > .ms { display: inline-block; }
.value-grid > article:nth-child(3n+1) > .ms { animation: mNod 2.6s ease-in-out infinite; }
.value-grid > article:nth-child(3n+2) > .ms { animation: mBreathe 2.2s ease-in-out infinite; }
.value-grid > article:nth-child(3n) > .ms { animation: mSweep 3s cubic-bezier(.65, 0, .35, 1) infinite; }
@keyframes mNod { 0%, 55%, 100% { rotate: 0deg; } 65% { rotate: -12deg; } 78% { rotate: 9deg; } 90% { rotate: -3deg; } }
@keyframes mBreathe { 0%, 100% { scale: 1; } 50% { scale: 1.15; } }
@keyframes mSweep { 0% { rotate: 0deg; } 70%, 100% { rotate: 360deg; } }

/* ---------- comparison ---------- */
.m-compare { max-width: 900px; margin: 0 auto; }
.m-compare table { width: 100%; border-collapse: separate; border-spacing: 0; border: 1px solid var(--outline); border-radius: 20px; overflow: hidden; background: var(--surface); font-size: 15px; }
.m-compare th, .m-compare td { padding: 14px 18px; border-top: 1px solid var(--outline); text-align: center; }
.m-compare thead th { border-top: 0; background: var(--bg); font: 700 16px var(--font-display); }
.m-compare thead th:nth-child(2) { color: var(--blue-ink); }
.m-compare tbody th { text-align: left; font-weight: 600; }
.m-compare .y { color: #17733c; font-weight: 800; font-size: 18px; }
.m-compare .n { color: var(--muted); font-size: 14px; }
.m-compare tbody tr { transition: background .2s; }
.m-compare tbody tr:hover { background: var(--blue-tint); }
.nx-motion .m-compare tbody tr { opacity: 0; transform: translateX(-12px); transition: opacity .5s, transform .5s cubic-bezier(.2, .9, .3, 1); transition-delay: var(--rd, 0ms); }
.nx-motion .m-compare.in tbody tr { opacity: 1; transform: none; }
@media (max-width: 600px) { .m-compare th, .m-compare td { padding: 12px 10px; font-size: 13px; } }

@media (prefers-reduced-motion: reduce) {
  .mw-ready .mw > span { transform: none; opacity: 1; }
  .mw-sticker, .live-profile .m-stk, .m-today, .m-track, .m-skel, .m-spin, .m-ok svg path, .m-bars i, .value-grid > article > .ms, .live-profile::before, .m-dots i { animation: none !important; }
  .nx-motion .m-compare tbody tr { opacity: 1; transform: none; }
}

.m-trust-note { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 10px 0 4px; font-size: 15px; color: var(--muted); text-align: center; }
.m-trust-note .m-tick { flex: none; margin-top: 1px; }
.m-trust-note b { color: var(--text, inherit); white-space: nowrap; }
@media (max-width: 700px) { .m-trust-note { font-size: 14px; align-items: flex-start; text-align: left; } }
