/* ============================================================
   四川集典企业管理有限公司 · 网站建设中
   深夜蓝图 × 金色奠基 — 样式表
   ============================================================ */

:root {
  --bg: #060a12;
  --bg-deep: #04070d;
  --grid-line: rgba(38, 84, 128, 0.16);
  --grid-line-strong: rgba(64, 120, 170, 0.22);
  --gold: #d4af37;
  --gold-light: #f5d67b;
  --gold-dim: rgba(212, 175, 55, 0.45);
  --text: #a8b4c5;
  --text-dim: #6b7a8f;
  --heading: #f4ead6;
  /* 字体：全部使用系统内置字体（免版权、零外部字体依赖）
     宋体 —— 大标题/衬线感；黑体 —— 正文/UI；等宽 —— 英文数字 */
  --serif: "Songti SC", "STSong", "SimSun", "Noto Serif CJK SC", serif;
  --sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --mono: "SF Mono", "JetBrains Mono", Consolas, Menlo, "Courier New",
    "PingFang SC", monospace;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  overflow: hidden;
  position: relative;
  min-height: 100vh;
}

/* ---------------- 背景层 ---------------- */

.bg-grid {
  position: fixed;
  inset: -60px;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    linear-gradient(var(--grid-line-strong) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line-strong) 1px, transparent 1px);
  background-size:
    44px 44px,
    44px 44px,
    220px 220px,
    220px 220px;
  animation: grid-drift 26s linear infinite;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 45%, #000 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 45%, #000 30%, transparent 100%);
  z-index: 0;
}

@keyframes grid-drift {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(44px, 44px, 0); }
}

.bg-noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.spotlight {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(
    circle 340px at var(--mx, 50%) var(--my, 40%),
    rgba(212, 175, 55, 0.08),
    rgba(212, 175, 55, 0.03) 40%,
    transparent 70%
  );
  transition: background 0.15s ease-out;
}

#particle-canvas {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

/* ---------------- 四角测绘括号 ---------------- */

.corner {
  position: fixed;
  width: 38px;
  height: 38px;
  z-index: 5;
  border-color: var(--gold-dim);
  border-style: solid;
  opacity: 0;
  animation: corner-in 1s ease 0.8s forwards;
}
.corner-tl { top: 22px; left: 22px; border-width: 1.5px 0 0 1.5px; }
.corner-tr { top: 22px; right: 22px; border-width: 1.5px 1.5px 0 0; }
.corner-bl { bottom: 22px; left: 22px; border-width: 0 0 1.5px 1.5px; }
.corner-br { bottom: 22px; right: 22px; border-width: 0 1.5px 1.5px 0; }

@keyframes corner-in {
  to { opacity: 1; }
}

/* ---------------- 顶栏 ---------------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 26px 48px;
  opacity: 0;
  animation: fade-down 0.9s ease 0.3s forwards;
}

@keyframes fade-down {
  to { opacity: 1; }
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-logo {
  width: 46px;
  height: 46px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  padding: 3px;
  background: rgba(10, 16, 26, 0.6);
  box-shadow: 0 0 22px rgba(212, 175, 55, 0.14);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.brand-text strong {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 15px;
  color: var(--heading);
  letter-spacing: 2px;
}
.brand-text em {
  font-style: normal;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 2.2px;
  color: var(--text-dim);
}

.domain-tag {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 1.5px;
  color: var(--text-dim);
  border: 1px solid rgba(168, 180, 197, 0.14);
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(10, 16, 26, 0.5);
}

.dot-live {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold);
  animation: pulse-dot 1.8s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.75); }
}

/* ---------------- 主舞台 ---------------- */

.stage {
  position: relative;
  z-index: 6;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 72px;
  padding: 120px 48px 110px;
  perspective: 1100px;
}

/* ---------------- 徽标 ---------------- */

.emblem-wrap {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}

.emblem {
  width: clamp(230px, 26vw, 330px);
  height: auto;
  filter: drop-shadow(0 0 30px rgba(212, 175, 55, 0.14));
}

.ring-rotate {
  transform-origin: 160px 160px;
  animation: ring-spin 30s linear infinite;
}

@keyframes ring-spin {
  to { transform: rotate(360deg); }
}

.draw-path {
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: draw-in 2.4s cubic-bezier(0.6, 0.05, 0.3, 1) 0.5s forwards;
}
.draw-path-delay {
  animation-delay: 1.1s;
}

@keyframes draw-in {
  to { stroke-dashoffset: 0; }
}

.emblem-char {
  font-family: var(--serif);
  font-weight: 900;
  font-size: 96px;
  fill: url(#goldStroke);
  opacity: 0;
  animation: char-glow 1.4s ease 2.2s forwards;
}

@keyframes char-glow {
  0% { opacity: 0; transform: scale(0.85); }
  60% { opacity: 1; transform: scale(1.04); }
  100% { opacity: 1; transform: scale(1); }
}

.emblem-caption {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--text-dim);
  opacity: 0;
  animation: fade-down 0.8s ease 2.6s forwards;
  text-align: center;
}
.emblem-caption .en {
  color: var(--gold);
}

/* ---------------- 文案区 ---------------- */

.hero {
  max-width: 560px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 4px;
  color: var(--gold);
  margin-bottom: 22px;
  opacity: 0;
  animation: fade-down 0.8s ease 0.9s forwards;
}
.eyebrow .line {
  width: 42px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dim));
}
.eyebrow .line:last-child {
  background: linear-gradient(90deg, var(--gold-dim), transparent);
}

.title {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(44px, 6vw, 76px);
  color: var(--heading);
  letter-spacing: 10px;
  line-height: 1.15;
  margin-bottom: 20px;
}

.title .ch {
  display: inline-block;
  opacity: 0;
  transform: scale(0.94);
  animation: ch-rise 0.55s ease-out forwards;
  text-shadow: 0 0 30px rgba(212, 175, 55, 0.18);
}

@keyframes ch-rise {
  to { opacity: 1; transform: scale(1); }
}

.subtitle {
  font-size: 15px;
  line-height: 1.9;
  color: var(--text);
  height: 30px;
  margin-bottom: 30px;
  letter-spacing: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.caret {
  color: var(--gold);
  font-weight: 300;
  animation: blink 0.9s steps(1) infinite;
}
@keyframes blink {
  50% { opacity: 0; }
}

/* ---------------- 进度条 ---------------- */

.progress-block {
  margin-bottom: 32px;
  opacity: 0;
  animation: fade-down 0.8s ease 1.8s forwards;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--text-dim);
  margin-bottom: 10px;
}
.progress-percent {
  font-family: var(--mono);
  font-size: 22px;
  font-weight: 500;
  color: var(--gold-light);
  letter-spacing: 1px;
  min-width: 74px;
  text-align: right;
}

.progress-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(168, 180, 197, 0.09);
  overflow: hidden;
  position: relative;
}

.progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #8a6d1f, var(--gold) 55%, var(--gold-light));
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.5);
  position: relative;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    transparent 20%,
    rgba(255, 255, 255, 0.55) 50%,
    transparent 80%
  );
  animation: shimmer 1.8s ease-in-out infinite;
}

@keyframes shimmer {
  from { transform: translateX(-100%); }
  to { transform: translateX(100%); }
}

/* ---------------- 构建日志终端 ---------------- */

.terminal {
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 10px;
  background: rgba(6, 12, 20, 0.72);
  backdrop-filter: blur(6px);
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  animation: fade-down 0.8s ease 2.1s forwards;
}

.terminal-head {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  background: rgba(212, 175, 55, 0.06);
  border-bottom: 1px solid rgba(212, 175, 55, 0.12);
}
.t-btn {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(212, 175, 55, 0.25);
}
.t-btn:first-child { background: rgba(212, 175, 55, 0.6); }
.t-title {
  margin-left: 10px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.6px;
  color: var(--text-dim);
}

.terminal-body {
  list-style: none;
  padding: 12px 18px;
  min-height: 112px;
  max-height: 112px;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.8;
}
.terminal-body li {
  color: var(--text);
  white-space: nowrap;
  opacity: 0;
  animation: line-in 0.35s ease forwards;
}
.terminal-body li .ts { color: var(--text-dim); }
.terminal-body li .ok { color: var(--gold); }
.terminal-body li .cursor-line::after {
  content: "▍";
  color: var(--gold);
  animation: blink 0.9s steps(1) infinite;
}

@keyframes line-in {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ---------------- 页脚 ---------------- */

.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  text-align: center;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  opacity: 0;
  animation: fade-down 0.9s ease 2.8s forwards;
}

.footer-company {
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 3px;
  color: var(--text-dim);
}

.footer-links {
  font-size: 12px;
  letter-spacing: 1.2px;
  color: var(--text-dim);
}
.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}
.footer-links a:hover {
  color: var(--gold-light);
  text-shadow: 0 0 12px rgba(212, 175, 55, 0.4);
}
.footer-links .sep {
  margin: 0 12px;
  opacity: 0.4;
}

/* ---------------- 响应式 ---------------- */

@media (max-width: 900px) {
  body { overflow: auto; }
  .stage {
    flex-direction: column;
    gap: 36px;
    padding: 110px 24px 130px;
    text-align: center;
  }
  .eyebrow { justify-content: center; }
  .hero { max-width: 520px; }
  .title { letter-spacing: 6px; }
  .site-header { padding: 20px 24px; }
  .brand-text em { display: none; }
  .terminal-body { white-space: normal; }
  .terminal-body li { white-space: normal; word-break: break-all; }
}

@media (max-width: 520px) {
  .domain-tag { display: none; }
  .title { letter-spacing: 4px; }
  .corner { width: 26px; height: 26px; }
}

/* ---------------- 减弱动效偏好 ---------------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .bg-grid,
  .ring-rotate,
  .progress-bar::after,
  .dot-live {
    animation: none !important;
  }
  #particle-canvas {
    display: none;
  }
  .title .ch,
  .draw-path,
  .emblem-char,
  .corner,
  .site-header,
  .eyebrow,
  .progress-block,
  .terminal,
  .emblem-caption,
  .site-footer {
    opacity: 1 !important;
    transform: none !important;
    stroke-dashoffset: 0 !important;
  }
}
