:root {
  --primary: #ff4b2b;
  --primary-deep: #ed361d;
  --primary-soft: #fff0ec;
  --accent: #2f80ed;
  --success: #18a77c;
  --bg: #f4f6f9;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-solid: #fff;
  --text: #18202c;
  --muted: #7b8495;
  --border: rgba(29, 32, 48, 0.08);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 15% 8%, rgba(255, 75, 43, 0.11), transparent 33%),
    radial-gradient(circle at 88% 75%, rgba(47, 128, 237, 0.1), transparent 34%),
    var(--bg);
  color: var(--text);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
}

#ambientCanvas { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.page-shell { position: relative; z-index: 1; display: flex; width: min(100%, 920px); min-height: 100dvh; flex-direction: column; margin: 0 auto; padding: max(20px, env(safe-area-inset-top)) 24px max(22px, env(safe-area-inset-bottom)); }
.brand-bar { display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand-mark { display: grid; width: 46px; height: 46px; place-items: center; border-radius: 15px; background: linear-gradient(145deg, var(--primary), #ff8064); font-size: 23px; }
.brand-mark span { filter: grayscale(1) brightness(0) invert(1); }
.brand-copy { display: flex; flex-direction: column; gap: 3px; }
.brand-copy strong { font-size: 18px; letter-spacing: 0.04em; }
.brand-copy small { color: var(--muted); font-size: 9px; font-weight: 700; letter-spacing: 0.24em; }
.secure-badge { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border: 1px solid rgba(24, 167, 124, 0.15); border-radius: 999px; background: rgba(255, 255, 255, 0.68); color: var(--success); font-size: 12px; font-weight: 700; backdrop-filter: blur(12px); }
.secure-badge i { width: 7px; height: 7px; border: 4px solid rgba(24, 167, 124, 0.1); border-radius: 50%; background: var(--success); animation: pulse 1.8s ease-in-out infinite; }

.redirect-card { position: relative; display: flex; width: min(100%, 520px); flex-direction: column; align-items: center; margin: auto; padding: 38px 36px 30px; overflow: hidden; border: 1px solid rgba(29, 32, 48, 0.1); border-radius: 32px; background: var(--surface); text-align: center; backdrop-filter: blur(22px); }
.redirect-card::before { position: absolute; top: 0; left: 50%; width: 62%; height: 3px; border-radius: 0 0 8px 8px; background: linear-gradient(90deg, transparent, var(--primary), transparent); content: ""; transform: translateX(-50%); }
.visual-stage { position: relative; display: grid; width: 168px; height: 168px; place-items: center; margin-bottom: 20px; }
.visual-stage::before { position: absolute; width: 116px; height: 116px; border-radius: 50%; background: radial-gradient(circle, rgba(255, 75, 43, 0.18), rgba(255, 75, 43, 0.03) 60%, transparent 70%); content: ""; animation: breathe 2.8s ease-in-out infinite; }
.orbit { position: absolute; border: 1px solid rgba(47, 128, 237, 0.23); border-radius: 50%; }
.orbit::after { position: absolute; top: 50%; left: -4px; width: 8px; height: 8px; border: 3px solid rgba(47, 128, 237, 0.15); border-radius: 50%; background: var(--accent); content: ""; }
.orbit--outer { inset: 4px; animation: rotate 8s linear infinite; }
.orbit--middle { inset: 25px; border-color: rgba(255, 75, 43, 0.28); animation: rotate 5s linear infinite reverse; }
.orbit--middle::after { right: -4px; left: auto; border-color: rgba(255, 75, 43, 0.15); background: var(--primary); }
.core-ball { position: relative; z-index: 2; display: grid; width: 78px; height: 78px; place-items: center; border: 1px solid rgba(29, 32, 48, 0.1); border-radius: 24px; background: linear-gradient(145deg, #fff, #f1f3f8); font-size: 38px; transform: rotate(-4deg); }
.scan-line { position: absolute; z-index: 3; width: 112px; height: 2px; background: linear-gradient(90deg, transparent, rgba(255, 75, 43, 0.8), transparent); animation: scan 2.4s ease-in-out infinite; }
.data-node { position: absolute; width: 8px; height: 8px; border: 3px solid rgba(255, 75, 43, 0.1); border-radius: 50%; background: var(--primary); }
.data-node--one { top: 28px; right: 28px; }.data-node--two { bottom: 22px; left: 44px; background: var(--accent); }.data-node--three { top: 65px; left: 4px; width: 4px; height: 4px; }
.status-chip { display: inline-flex; align-items: center; gap: 8px; color: var(--primary); font-size: 11px; font-weight: 800; letter-spacing: 0.18em; }
.status-chip span { width: 18px; height: 2px; border-radius: 2px; background: var(--primary); }
h1 { margin: 13px 0 9px; font-size: clamp(25px, 6vw, 34px); line-height: 1.25; letter-spacing: -0.03em; }
.description { min-height: 24px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.progress { width: 100%; height: 5px; margin-top: 28px; overflow: hidden; border-radius: 6px; background: #eceff5; }
.progress span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--primary), #ff8b65); transition: width 0.1s linear; }
.countdown { display: flex; align-items: baseline; gap: 7px; margin: 12px 0 22px; color: var(--muted); font-size: 13px; }
.countdown strong { color: var(--primary); font-size: 21px; font-variant-numeric: tabular-nums; }
button { font: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.primary-button:disabled { cursor: wait; opacity: 0.68; }
.primary-button { display: flex; width: 100%; height: 56px; align-items: center; justify-content: center; gap: 12px; border: 0; border-radius: 18px; background: linear-gradient(135deg, var(--primary), var(--primary-deep)); color: #fff; font-size: 16px; font-weight: 750; transition: transform 0.18s ease, filter 0.18s ease; }
.primary-button b { font-size: 20px; transition: transform 0.18s ease; }.primary-button:hover { filter: brightness(1.04); transform: translateY(-2px); }.primary-button:hover b { transform: translateX(3px); }.primary-button:active { transform: scale(0.985); }
.text-button { margin-top: 8px; padding: 9px 16px; border: 0; background: transparent; color: var(--muted); font-size: 13px; }
.security-note { display: flex; width: 100%; align-items: flex-start; gap: 12px; margin-top: 18px; padding: 15px 16px; border: 1px solid var(--border); border-radius: 17px; background: rgba(244, 246, 249, 0.78); text-align: left; }
.shield { display: grid; width: 27px; height: 27px; flex: none; place-items: center; border-radius: 9px; background: rgba(24, 167, 124, 0.12); color: var(--success); font-weight: 900; }
.security-note p { display: flex; flex-direction: column; gap: 4px; margin: 0; }.security-note strong { font-size: 13px; }.security-note small { color: var(--muted); font-size: 11px; line-height: 1.55; }
footer { display: flex; align-items: center; justify-content: space-between; padding-top: 22px; color: var(--muted); font-size: 11px; letter-spacing: 0.05em; } footer p { margin: 0; }

.is-paused .orbit, .is-paused .scan-line, .is-paused .visual-stage::before { animation-play-state: paused; }
.is-paused .status-chip { color: var(--muted); }.is-paused .status-chip span { background: var(--muted); }

@keyframes rotate { to { transform: rotate(360deg); } }
@keyframes scan { 0%, 100% { transform: translateY(-34px); opacity: 0.2; } 50% { transform: translateY(34px); opacity: 1; } }
@keyframes breathe { 0%, 100% { transform: scale(0.92); opacity: 0.65; } 50% { transform: scale(1.08); opacity: 1; } }
@keyframes pulse { 0%, 100% { opacity: 0.65; transform: scale(0.85); } 50% { opacity: 1; transform: scale(1); } }

@media (max-width: 560px) {
  .page-shell { padding-right: 18px; padding-left: 18px; }
  .redirect-card { margin-top: 34px; margin-bottom: 28px; padding: 30px 22px 24px; border-radius: 28px; }
  .visual-stage { width: 150px; height: 150px; margin-bottom: 14px; }
  .secure-badge { padding: 7px 10px; font-size: 11px; }
  footer { flex-direction: column; gap: 6px; padding-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
