/* ===== Nikki Rubii Studio · motion layer ===== */

/* letter reveal on headings */
.m-split .m-w{ display:inline-block; white-space:nowrap; }
.m-split .m-c{ display:inline-block; transform:translateY(0.9em) rotate(6deg); opacity:0; transition:transform .9s cubic-bezier(.2,.75,.2,1), opacity .9s ease; transition-delay:calc(var(--i) * 22ms); }
.m-split.m-in .m-c{ transform:none; opacity:1; }

/* letter roll on buttons and links */
.m-roll{ display:inline-block; overflow:hidden; vertical-align:bottom; line-height:1.25; }
.m-roll > span{ display:inline-block; position:relative; transition:transform .55s cubic-bezier(.65,0,.25,1); }
.m-roll > span::after{ content:attr(data-t); position:absolute; left:0; top:100%; white-space:nowrap; }
a:hover .m-roll > span, button:hover .m-roll > span{ transform:translateY(-100%); }

/* image wipe reveal */
.m-img{ clip-path:inset(100% 0 0 0); transform:scale(1.08); transition:clip-path 1.3s cubic-bezier(.7,0,.2,1), transform 1.6s cubic-bezier(.2,.7,.2,1); }
.m-img.m-in{ clip-path:inset(0 0 0 0); transform:none; }

/* soft rise for paragraphs and cards */
.m-rise{ opacity:0; transform:translateY(26px); transition:opacity 1s ease, transform 1s cubic-bezier(.2,.7,.2,1); }
.m-rise.m-in{ opacity:1; transform:none; }

/* custom cursor */
.m-cursor, .m-dot{ position:fixed; top:0; left:0; pointer-events:none; z-index:9999; border-radius:50%; mix-blend-mode:difference; }
.m-cursor{ width:34px; height:34px; margin:-17px 0 0 -17px; border:1px solid #fff; transition:width .35s, height .35s, margin .35s, background .35s, opacity .3s; display:flex; align-items:center; justify-content:center; }
.m-dot{ width:5px; height:5px; margin:-2.5px 0 0 -2.5px; background:#fff; }
.m-cursor.is-link{ width:64px; height:64px; margin:-32px 0 0 -32px; background:#fff; }
.m-cursor.is-view{ width:92px; height:92px; margin:-46px 0 0 -46px; background:#fff; }
.m-cursor span{ font-family:'Inter',sans-serif; font-size:9px; letter-spacing:0.25em; text-transform:uppercase; color:#000; opacity:0; transition:opacity .3s; }
.m-cursor.is-view span{ opacity:1; }
.m-hide-cursor, .m-hide-cursor a, .m-hide-cursor button{ cursor:none; }

/* opening curtain */
.m-curtain{ position:fixed; inset:0; z-index:10000; background:#2E0E16; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:18px; transition:transform 1s cubic-bezier(.76,0,.24,1); }
.m-curtain.m-out{ transform:translateY(-100%); }
.m-curtain .m-word{ font-family:'Italiana',serif; font-size:clamp(22px,4vw,40px); letter-spacing:0.45em; color:#F4CFD0; padding-left:0.45em; overflow:hidden; }
.m-curtain .m-word span{ display:inline-block; transform:translateY(110%); animation:mUp .8s cubic-bezier(.2,.75,.2,1) forwards; animation-delay:calc(var(--i) * 45ms + 100ms); }
.m-curtain .m-line{ width:0; height:1px; background:#8FB4FF; animation:mLine 1s cubic-bezier(.7,0,.2,1) .35s forwards; }
@keyframes mUp{ to{ transform:none; } }
@keyframes mLine{ to{ width:140px; } }

@media (prefers-reduced-motion: reduce){
  .m-split .m-c, .m-img, .m-rise{ transition:none !important; transform:none !important; opacity:1 !important; clip-path:none !important; }
  .m-curtain{ display:none !important; }
}
