/* ==========================================================
   Iremia FX — interaction, motion & sound layer
   Drop-in for iremiatechnologies.co.za (hand-coded HTML)
   Tweak the brand tokens below to match your exact gold.
   ========================================================== */
:root{
  --fx-gold:#e0b04a;
  --fx-gold-2:#f6d27a;
  --fx-gold-deep:#b8862b;
  --fx-ink:#1a1c1a;
  --fx-glass:rgba(26,28,26,.72);
  --fx-ease:cubic-bezier(.2,.8,.2,1);
  --fx-spring:cubic-bezier(.34,1.56,.64,1);
}

/* ---------- Page enter / leave ---------- */
html.fx-ready body{animation:fx-enter .55s var(--fx-ease) both}
@keyframes fx-enter{from{opacity:0}to{opacity:1}}
html.fx-leaving body{opacity:0;transition:opacity .2s ease}

/* ---------- Scroll progress bar ---------- */
.fx-progress{position:fixed;top:0;left:0;height:3px;width:100%;z-index:10000;pointer-events:none;
  transform-origin:0 50%;transform:scaleX(var(--fx-p,0));
  background:linear-gradient(90deg,var(--fx-gold-deep),var(--fx-gold),var(--fx-gold-2));
  box-shadow:0 0 12px rgba(224,176,74,.7)}

/* ---------- Scroll reveal ---------- */
.fx-reveal{opacity:0;translate:0 22px;
  transition:opacity .75s var(--fx-ease) var(--fx-d,0s),translate .75s var(--fx-ease) var(--fx-d,0s)}
.fx-reveal.fx-in{opacity:1;translate:0 0}

/* ---------- Hero: shimmer headline, particles, sunburst decal ---------- */
.fx-hero{isolation:isolate;overflow:hidden}
.fx-hero-static{position:relative}
.fx-particles{position:absolute;inset:0;width:100%;height:100%;z-index:-1;pointer-events:none}
.fx-sunburst{position:absolute;z-index:-1;pointer-events:none;width:min(560px,90vw);aspect-ratio:1;
  right:-14%;top:-22%;opacity:.13;color:var(--fx-gold);animation:fx-spin 90s linear infinite}
@keyframes fx-spin{to{rotate:360deg}}
.fx-h1{background:linear-gradient(100deg,var(--fx-h1c,#fff) 0 38%,var(--fx-gold-2) 47%,var(--fx-gold) 50%,var(--fx-h1c,#fff) 62% 100%);
  background-size:260% 100%;-webkit-background-clip:text;background-clip:text;color:transparent;
  animation:fx-shimmer 7s var(--fx-ease) infinite}
@keyframes fx-shimmer{0%,55%{background-position:100% 0}100%{background-position:0 0}}

/* ---------- Section heading decals ---------- */
.fx-h2::before{content:"✦";display:inline-block;color:var(--fx-gold);margin-right:.45em;font-size:.7em;
  vertical-align:.12em;animation:fx-twinkle 3.2s ease-in-out infinite}
@keyframes fx-twinkle{0%,100%{opacity:.55;scale:.85;rotate:0deg}50%{opacity:1;scale:1.15;rotate:45deg}}
.fx-h2::after{content:"";display:block;width:56px;height:3px;border-radius:3px;margin:.55em 0 0;
  background:linear-gradient(90deg,var(--fx-gold),var(--fx-gold-2));
  transform:scaleX(0);transform-origin:left;transition:transform .9s var(--fx-ease) .25s}
.fx-h2.fx-center::after{margin-inline:auto;transform-origin:center}
.fx-h2.fx-in::after{transform:scaleX(1)}

/* ---------- Cards: spotlight + tilt + glow ---------- */
.fx-card{transition:transform .35s var(--fx-ease),box-shadow .35s ease,border-color .35s ease;will-change:transform}
.fx-card-pos{position:relative}
.fx-card::after{content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;opacity:0;
  transition:opacity .3s ease;
  background:radial-gradient(260px circle at var(--mx,50%) var(--my,50%),rgba(224,176,74,.18),transparent 62%)}
.fx-card:hover::after{opacity:1}
.fx-card:hover{box-shadow:0 18px 40px -18px rgba(0,0,0,.6),0 0 0 1px rgba(224,176,74,.35)}

/* ---------- Buttons: shine, lift, ripple, press ---------- */
.fx-btn{overflow:hidden;transition:translate .25s var(--fx-ease),scale .18s var(--fx-spring),box-shadow .3s ease,filter .3s}
.fx-btn-pos{position:relative}
.fx-btn::before{content:"";position:absolute;top:0;left:-75%;width:50%;height:100%;pointer-events:none;
  background:linear-gradient(105deg,transparent,rgba(255,255,255,.45),transparent);transform:skewX(-20deg);
  transition:left .7s var(--fx-ease)}
.fx-btn:hover::before{left:130%}
.fx-btn:hover{box-shadow:0 12px 30px -10px rgba(224,176,74,.65);filter:saturate(1.15)}
.fx-btn:active{scale:.96}
.fx-btn.fx-primary{animation:fx-breathe 3.6s ease-in-out infinite}
@keyframes fx-breathe{0%,100%{box-shadow:0 0 0 0 rgba(224,176,74,0)}50%{box-shadow:0 0 26px 2px rgba(224,176,74,.35)}}
.fx-ripple{position:absolute;border-radius:50%;pointer-events:none;width:12px;height:12px;margin:-6px 0 0 -6px;
  background:rgba(255,255,255,.55);animation:fx-ripple .65s ease-out forwards}
@keyframes fx-ripple{to{transform:scale(28);opacity:0}}

/* Arrow links ("Explore all services →") */
.fx-arrow .fx-arrow-i{display:inline-block;transition:translate .3s var(--fx-spring)}
.fx-arrow:hover .fx-arrow-i{translate:6px 0}

/* Nav underline slide */
.fx-nav a{background-image:linear-gradient(90deg,var(--fx-gold),var(--fx-gold-2));background-repeat:no-repeat;
  background-position:0 100%;background-size:0 2px;transition:background-size .35s var(--fx-ease),color .2s}
.fx-nav a:hover,.fx-nav a[aria-current="page"]{background-size:100% 2px}

/* Images */
.fx-img{transition:translate .45s var(--fx-ease),box-shadow .45s ease,filter .45s}
.fx-img:hover{translate:0 -6px;box-shadow:0 24px 50px -20px rgba(224,176,74,.45);filter:brightness(1.05)}

/* ---------- Process step badges ---------- */
.fx-step{display:inline-grid!important;place-items:center!important;text-align:center;line-height:1!important;padding:0!important;
  width:2.6em!important;height:2.6em!important;border-radius:50%;font-weight:800;
  color:var(--fx-ink)!important;background:radial-gradient(circle at 30% 30%,var(--fx-gold-2),var(--fx-gold) 60%,var(--fx-gold-deep));
  box-shadow:0 0 0 6px rgba(224,176,74,.12),0 8px 20px -6px rgba(224,176,74,.6)}
.fx-step.fx-reveal{translate:0 0;scale:.3;transition:opacity .5s ease var(--fx-d,0s),scale .7s var(--fx-spring) var(--fx-d,0s)}
.fx-step.fx-reveal.fx-in{scale:1}

/* ---------- FAQ accordion ---------- */
.fx-faq-q{cursor:pointer;display:flex;justify-content:space-between;align-items:center;gap:1em;user-select:none}
.fx-faq-q::after{content:"+";flex:none;display:grid;place-items:center;width:1.6em;height:1.6em;border-radius:50%;
  border:1px solid rgba(224,176,74,.5);color:var(--fx-gold);font-weight:400;transition:rotate .35s var(--fx-spring),background .3s}
.fx-faq-q[aria-expanded="true"]::after{rotate:45deg;background:rgba(224,176,74,.15)}
.fx-faq-q:focus-visible{outline:2px solid var(--fx-gold);outline-offset:4px;border-radius:6px}
.fx-faq-a{overflow:hidden;transition:max-height .45s var(--fx-ease),opacity .35s ease,margin .35s ease}
.fx-faq-a[hidden-fx]{max-height:0!important;opacity:0;margin-top:0;margin-bottom:0}

/* ---------- WhatsApp pulse ---------- */
.fx-wa{animation:fx-wa 2.4s ease-out infinite}
@keyframes fx-wa{0%{box-shadow:0 0 0 0 rgba(37,211,102,.55)}80%,100%{box-shadow:0 0 0 16px rgba(37,211,102,0)}}

/* Footer social links bounce */
.fx-social{display:inline-block;transition:translate .3s var(--fx-spring),color .2s}
.fx-social:hover{translate:0 -3px;color:var(--fx-gold)}

/* ---------- Floating controls ---------- */
.fx-fab{position:fixed;left:16px;z-index:9998;width:44px;height:44px;border-radius:50%;border:1px solid rgba(224,176,74,.45);
  background:var(--fx-glass);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);color:var(--fx-gold);
  display:grid;place-items:center;cursor:pointer;padding:0;
  transition:translate .3s var(--fx-spring),opacity .3s,border-color .3s,scale .15s}
.fx-fab:hover{border-color:var(--fx-gold);translate:0 -2px}
.fx-fab:active{scale:.92}
.fx-fab svg{width:20px;height:20px}
.fx-sound{bottom:16px}
.fx-top{bottom:70px;opacity:0;pointer-events:none;translate:0 12px}
.fx-top.fx-show{opacity:1;pointer-events:auto;translate:0 0}
.fx-sound .fx-wave{transition:opacity .25s}
.fx-sound[aria-pressed="false"] .fx-wave{opacity:0}
.fx-sound[aria-pressed="false"] .fx-x{opacity:1}
.fx-sound .fx-x{opacity:0;transition:opacity .25s}

/* Toast */
.fx-toast{position:fixed;left:70px;bottom:20px;z-index:9999;max-width:min(320px,calc(100vw - 90px));
  padding:9px 14px;border-radius:12px;font:500 13px/1.35 system-ui,sans-serif;color:#f5ecd6;
  background:var(--fx-glass);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);
  border:1px solid rgba(224,176,74,.4);opacity:0;translate:-8px 0;transition:opacity .3s,translate .4s var(--fx-spring)}
.fx-toast.fx-show{opacity:1;translate:0 0}

/* Confetti canvas */
.fx-confetti{position:fixed;inset:0;width:100vw;height:100vh;pointer-events:none;z-index:10001}

/* ---------- Respect reduced-motion ---------- */
@media (prefers-reduced-motion:reduce){
  html.fx-ready body{animation:none}
  .fx-reveal,.fx-step.fx-reveal{opacity:1;translate:0 0;scale:1;transition:none}
  .fx-h1,.fx-sunburst,.fx-h2::before,.fx-btn.fx-primary,.fx-wa{animation:none}
  .fx-h1{color:var(--fx-h1c,#fff);background:none}
  .fx-h2::after{transform:scaleX(1);transition:none}
}
