/* Home, rodada 5 do feedback do Carlos (27/11, iPhone em produção). Por cima do v3/r3/r4. Movimento em r5.js.
   1 a frase do prisma: probabilidade → realidade · 5 rastreamento com campanhas e origens (logos em preto e branco).
   Base preto e branco; nada de arco-íris. Com "reduzir movimento": tudo no estado final. */

/* ---------- 1. a frase do prisma: palavras em várias posições que "decidem" quando a luz passa ---------- */
/* o gradiente da rodada 4 sai: agora quem acende é cada palavra */
.js .r3-pr.is-q .r3-pr__t { color: #f4f4f2; background: none; -webkit-background-clip: border-box; background-clip: border-box; transition: none; }
.r5-q { display: inline; }
.r5-w { position: relative; display: inline-block; white-space: nowrap; }
.r5-w__r { display: inline-block; opacity: .28; transition: opacity .55s cubic-bezier(.2, .7, .2, 1); transition-delay: 0s; }
.r5-w__g { position: absolute; left: 0; top: 0; pointer-events: none; opacity: var(--go, .12);
  transform: translate3d(var(--gx, 0), var(--gy, 0), 0);
  animation: r5Drift var(--dt, 3.4s) ease-in-out var(--dd, 0s) infinite alternate;
  transition: transform 1s cubic-bezier(.7, 0, .2, 1), opacity .8s ease; transition-delay: 0s; }
@keyframes r5Drift { to { translate: var(--dx, 0) var(--dy, 0); } }
/* a luz passou: os fantasmas caem na palavra e ela acende */
.r3-pr.is-q.is-lit .r5-w__g { transform: none; opacity: 0; animation: none; transition-delay: var(--d, .4s), calc(var(--d, .4s) + .45s); }
.r3-pr.is-q.is-lit .r5-w__r { opacity: 1; transition-delay: calc(var(--d, .4s) + .55s); }
/* o leque de caminhos (canvas): fica atrás do texto, transborda um pouco para a esquerda, some quando termina */
.r5-fan { position: absolute; z-index: -1; left: -28px; top: -46px; width: calc(100% + 28px); height: calc(100% + 64px); pointer-events: none; opacity: 1; transition: opacity 1.2s ease .3s; }
.r3-pr.is-q { isolation: isolate; }
.r3-pr.is-done .r5-fan { opacity: 0; }
@media (max-width: 768px) { .r5-fan { left: calc(var(--gut, 16px) * -1); width: calc(100% + var(--gut, 16px)); } }
html.is-still .r5-w__g, html.is-still .r5-fan { display: none; }
html.is-still .r5-w__r { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .r5-w__g, .r5-fan { display: none; } .r5-w__r { opacity: 1; } }

/* ---------- 5. rastreamento: a campanha em cada venda e as origens com logo ---------- */
.r5-spr { position: absolute; width: 0; height: 0; overflow: hidden; }
.r4-trk { position: relative; }
.r4-c .r5-src, .r4-c .r5-lg { display: inline-grid; place-items: center; flex: none; border-radius: 9px; background: #0B0C0E; color: #fff; }
.r4-c .r5-src { width: 28px; height: 28px; }
.r4-c .r5-src svg, .r4-c .r5-lg svg { width: 14px; height: 14px; fill: currentColor; stroke: none; }
.r4-trk__feed li { grid-template-columns: 28px 1fr auto; }
.r4-trk__feed small { color: #3A3D44; font-weight: 500; }

.r4-trk__src { gap: 10px; }
.r5-row { display: grid; grid-template-columns: 32px minmax(0, 1.3fr) minmax(40px, .8fr) 38px; gap: 9px; align-items: center; font-size: 12.5px; }
.r5-row__n { min-width: 0; display: grid; line-height: 1.15; }
.r5-row__n b { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.r5-row__n small { font-size: 10.5px; color: #5A5D65; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.r5-row__n--wm { grid-column: 1 / 3; }
.r5-wm { width: 62px; height: 15px; fill: #4A4D55; }
.r5-row__p { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.r4-c .r5-lg { width: 26px; height: 26px; border-radius: 8px; background: #EEEEEC; color: #4A4D55; }
.r4-c .r5-lg svg { width: 13px; height: 13px; }
.r5-bar { display: block; height: 6px; border-radius: 6px; background: #EEEEEC; overflow: hidden; }
.r5-bar > i { display: block; height: 100%; width: var(--w); border-radius: inherit; background: #9A9CA2; transform-origin: 0 50%; transition: transform 1.2s cubic-bezier(.6, .05, .2, 1); }
.js .r4-c--trk:not(.is-in) .r5-bar > i { transform: scaleX(0); }
.r5-row:nth-of-type(3) .r5-bar > i { transition-delay: .12s; } .r5-row:nth-of-type(4) .r5-bar > i { transition-delay: .24s; }
.r5-row:nth-of-type(5) .r5-bar > i { transition-delay: .36s; } .r5-row:nth-of-type(6) .r5-bar > i { transition-delay: .48s; }
/* Meta e TikTok: as origens que mais vendem, em destaque */
.r5-row--top { font-size: 13.5px; }
.r4-c .r5-row--top .r5-lg { width: 32px; height: 32px; border-radius: 10px; background: #0B0C0E; color: #fff; }
.r4-c .r5-row--top .r5-lg svg { width: 17px; height: 17px; }
.r5-row--top .r5-row__n b { font-weight: 600; }
.r5-row--top .r5-bar { height: 9px; }
.r5-row--top .r5-bar > i { background: #0B0C0E; }
.r5-row--top .r5-row__p { font: 600 15px/1 var(--display); letter-spacing: -.01em; }
.r5-row--top + .r5-row:not(.r5-row--top) { margin-top: 4px; padding-top: 10px; border-top: 1px solid rgba(11, 12, 14, .07); }
@media (max-width: 420px) {
  .r5-row { grid-template-columns: 30px minmax(0, 1.35fr) minmax(34px, .7fr) 36px; gap: 8px; }
}
