/* Arigato Life — Page Buffer Loader & Progressive Image Shimmer */

/* 1. Branded Full-Screen Initial Buffer / Loader */
.al-page-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  transition: opacity 0.34s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.34s ease;
  will-change: opacity;
}
.al-page-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.al-loader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 24px;
  text-align: center;
}

.al-loader-logo {
  width: 154px;
  max-width: 68vw;
  height: auto;
  display: block;
  animation: alLogoBlink 1.8s ease-in-out infinite;
  will-change: opacity, transform;
}

@keyframes alLogoBlink {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.26;
    transform: scale(0.975);
  }
}

/* Spinner ring & progress bar completely removed per user request */
.al-loader-ring,
.al-loader-bar-track {
  display: none !important;
}

.al-loader-text {
  margin: 0;
  font-family: 'Manrope', 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #071e35;
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
}

.al-loader-dots {
  display: inline-flex;
  width: 28px;
  text-align: left;
  margin-left: 3px;
  letter-spacing: 0.08em;
}

.al-dot {
  display: inline-block;
  opacity: 0;
  font-weight: 800;
  font-size: 18px;
  line-height: 1;
  transition: opacity 0.25s ease-in-out;
  will-change: opacity;
}

.al-dot.is-visible {
  opacity: 1 !important;
}

/* Fallback pure CSS animation when JS is not running */
.al-dot.dot-1 {
  animation: alDot1 1.6s infinite;
}

.al-dot.dot-2 {
  animation: alDot2 1.6s infinite;
}

.al-dot.dot-3 {
  animation: alDot3 1.6s infinite;
}

.js-dots-active .al-dot {
  animation: none !important;
}

@keyframes alDot1 {
  0%, 15% { opacity: 0; }
  28%, 88% { opacity: 1; }
  98%, 100% { opacity: 0; }
}

@keyframes alDot2 {
  0%, 42% { opacity: 0; }
  54%, 88% { opacity: 1; }
  98%, 100% { opacity: 0; }
}

@keyframes alDot3 {
  0%, 68% { opacity: 0; }
  78%, 88% { opacity: 1; }
  98%, 100% { opacity: 0; }
}

@keyframes alSpin {
  to { transform: rotate(360deg); }
}

/* 2. Progressive Image Shimmer Buffer (for lazy & below-the-fold photos) */
@keyframes alShimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.v6-product-image,
.al29-seller-photo,
.al29-cat-card-media,
.al15-featured-photo,
.pd-main-stage,
.pd-rel-photo,
.pd-diagram-media,
.al-solution-photo,
.ar21-stage,
.al-prod-slider-stage {
  background-image: linear-gradient(90deg, #eef2f6 25%, #f8fafc 50%, #eef2f6 75%);
  background-size: 200% 100%;
  animation: alShimmer 1.35s ease-in-out infinite;
}

.al-media-loaded {
  background-image: none !important;
  animation: none !important;
}

img.al-img-fade {
  opacity: 0;
  transition: opacity 0.28s ease-out;
}
img.al-img-fade.al-img-ready {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .al-loader-logo { animation: none; }
  .al-dot { opacity: 1 !important; animation: none !important; }
  .al-page-loader { transition: none; }
  .v6-product-image,
  .al29-seller-photo,
  .al29-cat-card-media,
  .al15-featured-photo,
  .pd-main-stage,
  .pd-rel-photo,
  .pd-diagram-media,
  .al-solution-photo,
  .ar21-stage,
  .al-prod-slider-stage {
    animation: none;
  }
}
