/* fxkit — shared motion layer for the rubenplayz.com sites. Everything here is zero-specificity (:where) so each site's own rules win.
   Set --fx-accent per site. Copy of record: VRFS Main Files/fxkit (copied into each site's public folder). */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: fx-vt-out .28s cubic-bezier(.4,0,1,1) both; }
::view-transition-new(root) { animation: fx-vt-in .5s cubic-bezier(.2,.8,.2,1) both; }
@keyframes fx-vt-out { to { opacity: 0; transform: scale(.985); filter: blur(6px); } }
@keyframes fx-vt-in { from { opacity: 0; transform: scale(1.015); filter: blur(8px); } }

:where(html) { --fx-accent: #f6c453; --fx-ease: cubic-bezier(.2,.8,.2,1); --fx-spring: cubic-bezier(.34,1.56,.64,1); scroll-behavior: smooth; scrollbar-color: rgba(140,150,170,.4) transparent; scrollbar-width: thin; }
::selection { background: color-mix(in srgb, var(--fx-accent) 55%, transparent); color: #fff; }
:where(a, button, input, select, textarea, summary, [role="button"], [tabindex]):focus-visible { outline: 2px solid var(--fx-accent); outline-offset: 3px; }

/* the page arrives */
:where(body) { animation: fx-page .8s ease .6s both; }
@keyframes fx-page { from { opacity: 0; } }

/* things you press feel pressed */
:where(button, .btn, [role="button"], input[type="submit"], input[type="button"]) { transition: transform .18s var(--fx-ease), background-color .2s, color .2s, border-color .2s, box-shadow .25s, opacity .2s, filter .2s; }
:where(button, .btn, [role="button"]):where(:not(:disabled)):active { transform: scale(.96); transition-duration: .06s; }
:where(input, select, textarea) { transition: border-color .2s, box-shadow .25s, background-color .2s; }
:where(a) { transition: color .2s, opacity .2s; }

/* scroll reveal (fx.js adds .fx-rv then .fx-in, then takes both off again) */
.fx-rv { opacity: 0; transform: translateY(26px) scale(.985); filter: blur(6px); transition: opacity .8s var(--fx-ease), transform .9s var(--fx-ease), filter .8s ease; transition-delay: calc(var(--fx-i, 0) * 70ms); will-change: opacity, transform; }
.fx-rv.fx-in { opacity: 1; transform: none; filter: none; }

/* pointer tilt (fx.js sets the variables) */
.fx-tilt { transform: perspective(1000px) rotateX(var(--fx-rx, 0deg)) rotateY(var(--fx-ry, 0deg)); transition: transform .5s var(--fx-ease); }
.fx-tilt.fx-live { transition: transform .08s linear; }

/* top progress line */
.fx-progress { position: fixed; left: 0; top: 0; height: 2px; width: 100%; z-index: 2147483000; pointer-events: none; transform-origin: 0 50%; transform: scaleX(var(--fx-p, 0)); background: linear-gradient(90deg, color-mix(in srgb, var(--fx-accent) 50%, transparent), var(--fx-accent)); box-shadow: 0 0 12px var(--fx-accent); }

/* reusable keyframes */
@keyframes fx-rise { from { opacity: 0; transform: translateY(16px); } }
@keyframes fx-pop { from { opacity: 0; transform: scale(.94) translateY(10px); } }
@keyframes fx-fade { from { opacity: 0; } }
@keyframes fx-drop { from { opacity: 0; transform: translateY(-12px) scale(.97); } }
@keyframes fx-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@keyframes fx-float { 50% { transform: translateY(-8px); } }
@keyframes fx-spin { to { transform: rotate(360deg); } }
@keyframes fx-shake { 20%, 60% { transform: translateX(-7px); } 40%, 80% { transform: translateX(7px); } }

@media (prefers-reduced-motion: reduce) {
  :where(html) { scroll-behavior: auto; }
  :where(body) { animation: none; }
  .fx-rv { opacity: 1; transform: none; filter: none; transition: none; }
  .fx-tilt { transform: none; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .01s; }
}


/* ================= v2: the loud layer (2026-11-10) ================= */
/* 1. every page opens behind a curtain: an accent line draws, then the curtain is cut away on a slant */
html::before { content: ""; position: fixed; inset: 0; z-index: 2147483600; pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--fx-accent), transparent) center / 0% 3px no-repeat, radial-gradient(60% 60% at 50% 50%, #141a26, #05070b);
  animation: fx-curtain 1.15s cubic-bezier(.7, 0, .2, 1) both; }
@keyframes fx-curtain {
  0% { background-size: 0% 3px, auto; clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
  42% { background-size: 62% 3px, auto; clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
  72% { background-size: 100% 3px, auto; clip-path: polygon(0 0, 100% 0, 100% 34%, 0 62%); }
  100% { background-size: 100% 3px, auto; clip-path: polygon(0 0, 100% 0, 100% 0, 0 0); visibility: hidden; }
}
/* 2. slow moving light over the whole page */
html::after { content: ""; position: fixed; inset: -25%; z-index: 2147482000; pointer-events: none; mix-blend-mode: screen; opacity: .6;
  background: radial-gradient(34% 30% at 22% 28%, color-mix(in srgb, var(--fx-accent) 30%, transparent), transparent 70%),
              radial-gradient(30% 34% at 80% 72%, rgba(70, 130, 255, .2), transparent 70%),
              radial-gradient(22% 22% at 62% 18%, rgba(255, 255, 255, .07), transparent 70%);
  animation: fx-aurora 16s ease-in-out infinite alternate; will-change: transform; }
@keyframes fx-aurora { 0% { transform: translate(-6%, -4%) rotate(0deg) scale(1); } 50% { transform: translate(7%, 5%) rotate(8deg) scale(1.15); } 100% { transform: translate(-3%, 8%) rotate(-6deg) scale(1.05); } }
/* 3. the pointer: a ring that trails the mouse and grows over things you can press; clicks throw a ripple and sparks */
.fx-cur { position: fixed; left: 0; top: 0; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; z-index: 2147483500; pointer-events: none; opacity: 0;
  border: 1.5px solid color-mix(in srgb, var(--fx-accent) 85%, #fff); box-shadow: 0 0 18px color-mix(in srgb, var(--fx-accent) 55%, transparent), inset 0 0 10px color-mix(in srgb, var(--fx-accent) 25%, transparent);
  transition: width .25s var(--fx-ease), height .25s var(--fx-ease), margin .25s var(--fx-ease), opacity .3s, background-color .25s, border-color .25s; }
.fx-cur.fx-show { opacity: .9; }
.fx-cur.fx-hot { width: 58px; height: 58px; margin: -29px 0 0 -29px; background: color-mix(in srgb, var(--fx-accent) 14%, transparent); }
.fx-cur.fx-down { width: 22px; height: 22px; margin: -11px 0 0 -11px; background: color-mix(in srgb, var(--fx-accent) 40%, transparent); }
.fx-rip { position: fixed; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; z-index: 2147483400; pointer-events: none; border: 2px solid var(--fx-accent); animation: fx-rip .7s var(--fx-ease) forwards; }
@keyframes fx-rip { to { transform: scale(9); opacity: 0; border-width: .5px; } }
.fx-spark { position: fixed; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; z-index: 2147483400; pointer-events: none; background: var(--fx-accent); box-shadow: 0 0 10px var(--fx-accent); animation: fx-spark .65s cubic-bezier(.1, .8, .3, 1) forwards; }
@keyframes fx-spark { to { transform: translate(var(--dx), var(--dy)) scale(0); opacity: 0; } }
/* 4. headlines arrive letter by letter */
.fx-ch { display: inline-block; animation: fx-char .8s var(--fx-ease) backwards; animation-delay: calc(.95s + var(--i) * 32ms); }
.fx-wd { display: inline-block; white-space: nowrap; }
@keyframes fx-char { from { opacity: 0; transform: translateY(.7em) rotate(8deg) scale(1.2); filter: blur(8px); } }
/* 5. scroll reveals travel further */
.fx-rv { transform: translateY(64px) scale(.93); filter: blur(12px); transition-duration: 1s, 1.1s, 1s; transition-delay: calc(var(--fx-i, 0) * 90ms); }
@media (prefers-reduced-motion: reduce) { html::before, html::after, .fx-cur, .fx-rip, .fx-spark { display: none; } .fx-ch { animation: none; } .fx-rv { transform: none; filter: none; } }
/* no pointer ring (removed 2026-11-11) - also hides it on any page still holding an old copy of fx.js */
.fx-cur { display: none !important; }
