/* ==========================================================================
   AWCompany ApS — Premium load / motion system (2026-09-16)
   The intro loader overlay only. Scroll-reveal, hero entrance and Ken
   Burns drift already live in css/animations.css + js/animations.js —
   this file adds the missing first-paint loader and session-gates it via
   js/motion.js. Kept in its own file/pair rather than folded into the
   existing animations.* files so the two concerns (one-time load intro
   vs. ongoing in-page motion) stay easy to reason about and remove
   independently once no longer wanted.
   ========================================================================== */

#aw-loader{
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1B1A17;
  opacity: 1;
  transition: opacity 320ms var(--ease-premium, cubic-bezier(0.16,1,0.3,1));
}
#aw-loader.is-hiding{ opacity: 0; pointer-events: none; }

/* Reuses the site's real .logo-mark wordmark styling (see css/style.css)
   rather than an image — no extra network request, no risk of drifting
   out of sync with the real logo. */
#aw-loader__mark{
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 1.35rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fff;
  opacity: 0;
  transform: scale(0.94);
  transition: opacity 480ms var(--ease-premium, cubic-bezier(0.16,1,0.3,1)) 140ms,
              transform 480ms var(--ease-premium, cubic-bezier(0.16,1,0.3,1)) 140ms;
}
#aw-loader.is-visible #aw-loader__mark{
  opacity: 1;
  transform: scale(1);
}

/* Body scroll lock only while the loader is actually on screen — never
   depends on JS to become scrollable again (removed together with the
   loader element itself, see js/motion.js). */
.aw-loader-lock{ overflow: hidden; }

@media (prefers-reduced-motion: reduce){
  #aw-loader{ transition: opacity 1ms linear; }
  #aw-loader__mark{ transition: none; opacity: 1; transform: none; }
}
