/* ==========================================================
   ページローダー（top_loader__）
   色はすべて common.css の :root 変数を使用
   ========================================================== */

.top_loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-white);
  opacity: 1;
  visibility: visible;
  transition: opacity 1s ease, visibility 0s linear 1s;
}

.top_loader--hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.top_loader__inner {
  width: min(320px, 70vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.top_loader--hide .top_loader__inner {
  opacity: 0;
  transform: translateY(-8px);
}

.top_loader__logo {
  width: 100%;
  height: auto;
  animation: top_loader_breathe 2.4s ease-in-out infinite;
}

.top_loader__bar {
  position: relative;
  width: 100%;
  height: 2px;
  background: var(--color-brand-pale);
  overflow: hidden;
}

.top_loader__bar-fill {
  position: absolute;
  inset: 0;
  background: var(--color-brand);
  transform: scaleX(0);
  transform-origin: left center;
}

.top_loader__text {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: 0.24em;
  color: var(--color-brand);
}

.top_loader__num {
  min-width: 2.4em;
  text-align: end;
  font-size: 15px;
  letter-spacing: 0.08em;
}

.top_loader__pct {
  margin-left: -4px;
}

@keyframes top_loader_breathe {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

@media (max-width: 767px) {
  .top_loader__inner {
    gap: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .top_loader__logo {
    animation: none;
  }
}
