/* ============================================================
   往台酒业 · 网站加载欢迎样式
   明亮科技风 · 全屏覆盖 · 平滑淡出
   ============================================================ */

/* ---------- 加载器全屏遮罩 ---------- */
.wt-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  padding: 24px;
  background:
    radial-gradient(ellipse at 50% 38%, rgba(255, 252, 248, 1) 0%, rgba(240, 235, 227, 1) 55%, rgba(229, 223, 214, 1) 100%);
  transition: opacity 0.55s ease, visibility 0.55s ease;
  will-change: opacity;
}

.wt-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* ---------- 旋转环 + 中心 Logo ---------- */
.wt-loader__ring {
  position: relative;
  width: 108px;
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wt-loader__ring::before,
.wt-loader__ring::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid transparent;
}

/* 外环：黄铜色弧线旋转 */
.wt-loader__ring::before {
  border-top-color: var(--wt-brass, #A68953);
  border-right-color: var(--wt-brass-light, #C4A574);
  animation: wt-loader-spin 1.1s cubic-bezier(0.5, 0.1, 0.5, 0.9) infinite;
}

/* 内环：酒红色反向旋转 */
.wt-loader__ring::after {
  inset: 14px;
  border-bottom-color: var(--wt-wine, #6B1D28);
  border-left-color: var(--wt-wine-deep, #4A1219);
  animation: wt-loader-spin-reverse 1.4s cubic-bezier(0.5, 0.1, 0.5, 0.9) infinite;
}

.wt-loader__logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
  opacity: 0.92;
  animation: wt-loader-breathe 2s ease-in-out infinite;
}

/* ---------- 品牌文字 ---------- */
.wt-loader__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.wt-loader__name {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--wt-ink, #1C2228);
}

.wt-loader__tagline {
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--wt-muted, rgba(28, 34, 40, 0.62));
  white-space: nowrap;
}

/* ---------- 底部进度条 ---------- */
.wt-loader__bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(166, 137, 83, 0.12);
  overflow: hidden;
}

.wt-loader__bar::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 40%;
  background: linear-gradient(90deg, transparent, var(--wt-brass, #A68953), var(--wt-wine, #6B1D28), transparent);
  animation: wt-loader-progress 1.6s ease-in-out infinite;
}

/* ---------- 动画关键帧 ---------- */
@keyframes wt-loader-spin {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes wt-loader-spin-reverse {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(-360deg); }
}

@keyframes wt-loader-breathe {
  0%, 100% { transform: scale(1);    opacity: 0.92; }
  50%      { transform: scale(1.08); opacity: 1; }
}

@keyframes wt-loader-progress {
  0%   { left: -40%; }
  100% { left: 100%; }
}

/* ---------- 减少动画偏好（无障碍） ---------- */
@media (prefers-reduced-motion: reduce) {
  .wt-loader__ring::before,
  .wt-loader__ring::after,
  .wt-loader__logo,
  .wt-loader__bar::after {
    animation-duration: 0.01ms;
    animation-iteration-count: 1;
  }
}

/* ---------- 移动端紧凑适配 ---------- */
@media (max-width: 480px) {
  .wt-loader { gap: 18px; }
  .wt-loader__ring { width: 92px; height: 92px; }
  .wt-loader__ring::after { inset: 12px; }
  .wt-loader__logo { width: 36px; height: 36px; }
  .wt-loader__name { font-size: 15px; letter-spacing: 1.5px; }
  .wt-loader__tagline { font-size: 11px; }
}
