/* Lenis smooth scroll */
html.lenis,html.lenis body{height:auto;}
.lenis.lenis-smooth{scroll-behavior:auto !important;}
.lenis.lenis-smooth [data-lenis-prevent]{overscroll-behavior:contain;}
.lenis.lenis-stopped{overflow:hidden;}

/* ---- Page loader ---- */
#loader{position:fixed;inset:0;z-index:11000;background:#0e0e0e;display:flex;align-items:center;justify-content:center;transition:opacity .6s ease,visibility .6s ease;}
#loader.done{opacity:0;visibility:hidden;}
#loader .mk{position:relative;width:62px;height:68px;animation:ldIn .8s cubic-bezier(.2,.8,.2,1) both,ldFloat 1.4s ease-in-out .8s infinite alternate;}
#loader .mk img{display:block;width:100%;height:100%;}
#loader .mk::after{content:"";position:absolute;inset:-40px;border-radius:50%;background:radial-gradient(circle,rgba(176,226,23,.28),transparent 65%);filter:blur(14px);z-index:-1;animation:ldGlow 1.4s ease-in-out infinite alternate;}
@keyframes ldIn{0%{opacity:0;transform:scale(.55) rotate(-22deg);}60%{opacity:1;}100%{opacity:1;transform:scale(1) rotate(0);}}
@keyframes ldFloat{to{transform:translateY(-7px) scale(1.05);}}
@keyframes ldGlow{from{opacity:.5;}to{opacity:1;}}

/* ---- Soft lens cursor ---- */
#cursor-dot{position:fixed;top:0;left:0;width:6px;height:6px;border-radius:50%;background:#B0E217;z-index:10000;pointer-events:none;opacity:0;transform:translate3d(-50px,-50px,0);will-change:transform,opacity;}
#cursor-lens{position:fixed;top:0;left:0;width:46px;height:46px;border-radius:999px;border:1px solid rgba(176,226,23,.5);background:rgba(176,226,23,.10);backdrop-filter:blur(2px);-webkit-backdrop-filter:blur(2px);z-index:9999;pointer-events:none;display:flex;align-items:center;justify-content:center;opacity:0;will-change:transform,width,height;transition:width .28s cubic-bezier(.2,.8,.2,1),height .28s cubic-bezier(.2,.8,.2,1),background .28s,border-color .28s,opacity .3s;}
#cursor-lens .lab{font-family:'Switzer',sans-serif;font-size:12px;font-weight:500;color:#141414;opacity:0;white-space:nowrap;transition:opacity .18s;}
body.cursor-ready{cursor:none;}
body.cursor-ready a,body.cursor-ready button,body.cursor-ready input,body.cursor-ready textarea,body.cursor-ready .mag{cursor:none;}
body.cursor-ready.cursor-active #cursor-dot,body.cursor-ready.cursor-active #cursor-lens{opacity:1;}

/* Magnetic targets */
.mag{transition:transform .25s cubic-bezier(.2,.8,.2,1);}

/* ---- Hero blur-up entrance ---- */
.hrv{opacity:0;transform:translateY(20px);filter:blur(10px);}
.hrv.in{opacity:1;transform:none;filter:none;transition:opacity .9s cubic-bezier(.2,.75,.2,1),transform .9s cubic-bezier(.2,.75,.2,1),filter .9s cubic-bezier(.2,.75,.2,1);}

/* ---- Blur-morph rotating word (brand gradient) ---- */
.morph{display:inline-block;position:relative;}
.morph .w{display:inline-block;background:linear-gradient(92deg,#E4FEAC,#A5C826);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;color:transparent;}
.morph .w.out{position:absolute;left:0;top:0;white-space:nowrap;}
.morph .w.din{opacity:.001;filter:blur(14px);transform:scale(1.07);}
.morph .w.din.go{opacity:1;filter:blur(0);transform:none;transition:opacity .6s cubic-bezier(.2,.7,.2,1),filter .6s cubic-bezier(.2,.7,.2,1),transform .6s cubic-bezier(.2,.7,.2,1);}
.morph .w.dout.go{opacity:0;filter:blur(14px);transform:scale(.94);transition:opacity .45s,filter .45s,transform .45s;}

/* ---- Kinetic marquee (JS-driven for scroll velocity) ---- */
.marquee{margin-top:120px;overflow:hidden;-webkit-mask:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent);mask:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent);}
.marquee .track{display:inline-flex;align-items:center;white-space:nowrap;font-family:'Cabinet Grotesk',sans-serif;font-weight:500;font-size:15px;letter-spacing:.16em;text-transform:uppercase;color:#5d5d56;will-change:transform;}
.marquee .track span{padding:0 28px;}
.marquee .track b{color:#A5C826;font-weight:500;}

/* ---- Sticky compact nav ---- */
#topbar{position:fixed;top:18px;left:50%;z-index:60;display:flex;align-items:center;gap:30px;padding:8px 8px 8px 22px;background:rgba(18,18,18,.6);backdrop-filter:blur(18px);-webkit-backdrop-filter:blur(18px);border:0.5px solid rgba(255,255,255,.1);border-radius:999px;transform:translate(-50%,-160%);opacity:0;transition:transform .55s cubic-bezier(.2,.8,.2,1),opacity .4s;}
#topbar.show{transform:translate(-50%,0);opacity:1;}
#topbar .tb-brand{display:flex;align-items:center;gap:9px;flex:none;white-space:nowrap;font-family:'Cabinet Grotesk',sans-serif;font-weight:700;font-size:15px;letter-spacing:.03em;color:#fff;}
#topbar .tb-brand img{display:block;}
#topbar .tb-links{display:flex;align-items:center;gap:26px;}
#topbar .tb-links a{font-family:'Switzer',sans-serif;font-size:13px;color:#cfcfca;text-decoration:none;transition:color .2s;}
#topbar .tb-links a:hover{color:#fff;}
#topbar .tb-cta{display:flex;align-items:center;gap:7px;flex:none;white-space:nowrap;background:#A5C826;border:none;border-radius:999px;padding:9px 18px;font-family:'Switzer',sans-serif;font-weight:500;font-size:14px;color:#141414;cursor:pointer;}

/* ---- Scroll reveals (non-hero sections + footer) ---- */
.js-ready .wrap > section:not(:first-of-type),.js-ready .wrap > footer{opacity:0;transform:translateY(28px);}
.js-ready .wrap > section.in,.js-ready .wrap > footer.in{opacity:1;transform:none;transition:opacity .9s cubic-bezier(.2,.7,.2,1),transform .9s cubic-bezier(.2,.7,.2,1);}

/* ---- Divider draw-in ---- */
.js-ready img[src*="ivider"],.js-ready img[src*="ivder"]{clip-path:inset(0 100% 0 0);}
img[src*="ivider"].in,img[src*="ivder"].in{clip-path:inset(0 0 0 0);transition:clip-path 1.1s cubic-bezier(.5,.05,.1,1);}

/* ---- Portfolio cards: lift + tilt ---- */
#folio{perspective:1200px;}
.pcard{will-change:transform;transition:transform .4s cubic-bezier(.2,.8,.2,1);transform-style:preserve-3d;}

/* ---- Imagery: grayscale -> colour reveal ---- */
.ph{overflow:hidden;position:relative;background:#242424;}
.ph-img{display:block;width:100%;height:100%;object-fit:cover;transition:transform .9s cubic-bezier(.2,.7,.2,1);}
.ph:hover .ph-img,.pcard:hover .ph-img{transform:scale(1.06);}
.t-photo{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:50% 28%;filter:grayscale(1) contrast(1.06);z-index:0;}

/* ---- Hero spiral background ---- */
#herospiral{position:absolute;top:50%;left:50%;width:1180px;height:1180px;transform:translate(-50%,-52%);pointer-events:none;z-index:-2;opacity:.92;}
#herohaze{position:absolute;inset:0;z-index:-1;pointer-events:none;background:radial-gradient(58% 48% at 50% 44%,rgba(14,14,14,.55),rgba(14,14,14,.18) 62%,rgba(14,14,14,0) 100%);}
.wrap > section:first-of-type{overflow:visible;}
.wrap > section:first-of-type h1{text-shadow:0 2px 40px rgba(0,0,0,.5);}

/* ---- Heading scroll reveal (clip wipe) ---- */
.js-ready .wrap h2,.js-ready .wrap h3{clip-path:inset(0 0 108% 0);opacity:0;transform:translateY(14px);}
.wrap h2.in,.wrap h3.in{clip-path:inset(0 0 -12% 0);opacity:1;transform:none;transition:clip-path 1s cubic-bezier(.2,.8,.2,1),opacity 1s ease,transform 1s cubic-bezier(.2,.8,.2,1);}

/* ---- Living details ---- */
@keyframes ctaPulse{0%,100%{box-shadow:0 0 0 0 rgba(176,226,23,0);}50%{box-shadow:0 0 34px 2px rgba(176,226,23,.32);}}
.pulse{animation:ctaPulse 3.4s ease-in-out 1.8s infinite;}
#loader .ld-tag{position:absolute;left:50%;bottom:-44px;transform:translateX(-50%);white-space:nowrap;font-family:'Switzer',sans-serif;font-size:11px;letter-spacing:.16em;text-transform:uppercase;color:#6f6f68;opacity:0;animation:ldTag .6s ease .5s forwards;}
@keyframes ldTag{to{opacity:1;}}

@media (prefers-reduced-motion:reduce){
  .hrv,.js-ready .wrap > section,.js-ready .wrap > footer{opacity:1 !important;transform:none !important;filter:none !important;}
  .js-ready img[src*="ivider"],.js-ready img[src*="ivder"]{clip-path:none !important;}
  .js-ready .wrap h2,.js-ready .wrap h3{clip-path:none !important;opacity:1 !important;transform:none !important;}
  #loader{display:none !important;}
  .marquee .track{transform:none !important;}
  #herospiral{display:none !important;}
}
@media (hover:none),(max-width:1024px){
  #cursor-dot,#cursor-lens{display:none !important;}
  body.cursor-ready,body.cursor-ready a,body.cursor-ready button,body.cursor-ready .mag{cursor:auto;}
}
