/* ============================================================
   coming-soon.css — 暫時上線前著陸頁（點陣風格）
   ============================================================ */

.page-coming-soon {
  position: relative;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-8) var(--sp-4);
  background-color: var(--color-bg);
  background-image:
    linear-gradient(rgba(0, 200, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139, 47, 255, 0.06) 1px, transparent 1px);
  background-size: 6px 6px;
  overflow: hidden;
}

.page-coming-soon::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse 80% 60% at 50% 40%,
    rgba(0, 200, 255, 0.08) 0%,
    transparent 55%
  );
  z-index: 0;
}

/* 細掃描線（低對比，不干擾閱讀） */
.cs-scanlines {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.12;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.45) 2px,
    rgba(0, 0, 0, 0.45) 3px
  );
}

.cs-main {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-10);
  text-align: center;
  max-width: 100%;
}

/* Logo 多層底卡：週期性疊合 → 展開 */
.cs-logo-stack {
  display: inline-block;
}

.cs-logo-stack__inner {
  position: relative;
  display: inline-block;
}

.cs-logo-card {
  position: absolute;
  z-index: 0;
  inset: 0;
  box-sizing: border-box;
  border: 3px solid #222;
  pointer-events: none;
  will-change: transform;
}

.cs-logo-card--1 {
  z-index: 1;
  background: rgba(0, 210, 255, 0.22);
  border-color: var(--color-blue);
  animation: cs-logo-deck-1 4.8s cubic-bezier(0.45, 0, 0.2, 1) infinite;
}

.cs-logo-card--2 {
  z-index: 0;
  background: rgba(160, 80, 255, 0.18);
  border-color: rgba(160, 100, 255, 0.85);
  animation: cs-logo-deck-2 4.8s cubic-bezier(0.45, 0, 0.2, 1) infinite;
}

.cs-logo-wrap {
  position: relative;
  z-index: 2;
  padding: var(--sp-5) var(--sp-8);
  background: rgba(250, 250, 252, 0.97);
  border: 3px solid #222;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  image-rendering: pixelated;
  will-change: transform;
  animation: cs-logo-deck-front 4.8s cubic-bezier(0.45, 0, 0.2, 1) infinite;
  
}

/*
  時間軸（4.8s 一輪）：
  展開停頓 → 疊合 → 疊合停頓 → 展開 → 展開停頓
  Logo 白卡往左上（-x,-y）；底層彩色卡往右下（+x,+y）；收合皆回到疊合
*/
@keyframes cs-logo-deck-front {
  0%,
  10% {
    transform: translate(-6px, -6px);
  }
  22%,
  32% {
    transform: translate(0, 0);
  }
  48%,
  58% {
    transform: translate(0, 0);
  }
  70%,
  100% {
    transform: translate(-6px, -6px);
  }
}

@keyframes cs-logo-deck-1 {
  0%,
  10% {
    transform: translate(0px, 0px);
  }
  22%,
  32% {
    transform: translate(0, 0);
  }
  48%,
  58% {
    transform: translate(0, 0);
  }
  70%,
  100% {
    transform: translate(0px, 0px);
  }
}

@keyframes cs-logo-deck-2 {
  0%,
  10% {
    transform: translate(6px, 6px);
  }
  22%,
  32% {
    transform: translate(0, 0);
  }
  48%,
  58% {
    transform: translate(0, 0);
  }
  70%,
  100% {
    transform: translate(6px, 6px);
  }
}

.cs-logo {
  display: block;
  width: min(160px, 35vw);
  height: auto;
  vertical-align: middle;
}

/* 點陣標題：Cubic 11 + 像素感強化 */
.cs-title {
  margin: 0;
  font-family: 'Cubic 11', var(--font-zh);
  font-size: clamp(1.35rem, 5.5vw, 2.25rem);
  font-weight: var(--fw-black);
  line-height: 1.15;
  letter-spacing: var(--ls-widest);
  text-transform: uppercase;
  color: var(--color-text);
  text-shadow:
    0 0 20px var(--color-blue-glow),
    2px 2px 0 rgba(0, 0, 0, 0.85);
}

.cs-title__fx {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0;
}

.cs-char {
  display: inline-block;
  will-change: transform;
  animation: cs-char-hop 2.2s cubic-bezier(0.34, 1.35, 0.64, 1) infinite;
  animation-delay: calc(var(--i) * 0.12s);
}

.cs-char--space {
  width: 0.45em;
  animation: none;
}

@keyframes cs-char-hop {
  0%,
  14%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  7% {
    transform: translate3d(0, -0.38em, 0);
  }
}

.cs-sub {
  margin: 0;
  font-family: 'Cubic 11', var(--font-zh);
  font-size: var(--fs-sm);
  letter-spacing: var(--ls-wide);
  color: var(--color-text-muted);
  text-transform: uppercase;
}

/* CTA：沿用 base.css 的 .btn / .btn--primary */
.cs-actions {
  margin-top: var(--sp-2);
}

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

  .cs-logo-wrap {
    animation: none;
    transform: translate(-6px, -6px);
  }

  .cs-logo-card--1,
  .cs-logo-card--2 {
    animation: none;
  }

  .cs-logo-card--1 {
    transform: translate(6px, 6px);
  }

  .cs-logo-card--2 {
    transform: translate(12px, 12px);
  }
}
