/* ============================================================
   聚数云析官网 · 工业专业风样式
   配色：深蓝 #0a2540 / 钢蓝 #1f6feb / 中性灰 / 浅底 #f4f6f8
   ============================================================ */
:root {
  --navy: #0a2540;
  --navy-2: #102a43;
  --steel: #1f6feb;
  --steel-2: #2b6cb0;
  --slate: #5a6b7b;
  --line: #e2e8f0;
  --bg: #f4f6f8;
  --white: #ffffff;
  --ink: #1a2533;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(16, 42, 67, 0.08);
  --shadow-lg: 0 14px 40px rgba(16, 42, 67, 0.14);
  --maxw: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Segoe UI", "Microsoft YaHei", -apple-system, sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 88px 0; }
.section.alt { background: var(--bg); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 56px; }
.section-head .eyebrow {
  color: var(--steel); font-weight: 600; letter-spacing: 2px;
  font-size: 13px; text-transform: uppercase;
}
.section-head h2 { font-size: 34px; color: var(--navy); margin: 12px 0 10px; }
.section-head p { color: var(--slate); font-size: 16px; }

/* ---------- 顶部导航 ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; color: var(--navy); }
.brand-logo {
  height: 40px; width: auto; border-radius: 8px;
  object-fit: contain; display: block;
  transition: transform .35s cubic-bezier(0.16, 1, 0.3, 1), filter .35s ease;
}
.brand:hover .brand-logo {
  transform: scale(1.08) rotate(-3deg);
  filter: drop-shadow(0 6px 14px rgba(20, 40, 80, 0.28));
}
.site-footer .brand-logo,
.admin-side .brand-logo {
  background: #fff; padding: 3px;
}
@media (prefers-reduced-motion: reduce) {
  .brand-logo { transition: none; }
  .brand:hover .brand-logo { transform: none; filter: none; }
}
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { color: var(--navy-2); font-weight: 500; font-size: 15px; transition: color .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--steel); }
.lang-switch {
  border: 1px solid var(--line); border-radius: 20px; padding: 6px 14px;
  font-size: 14px; color: var(--navy-2); transition: all .2s;
}
.lang-switch:hover { border-color: var(--steel); color: var(--steel); }
.nav-toggle { display: none; background: none; border: 0; font-size: 24px; color: var(--navy); cursor: pointer; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-block; padding: 13px 28px; border-radius: 8px;
  font-weight: 600; font-size: 15px; cursor: pointer; border: 0;
  transition: transform .15s, box-shadow .2s, background .2s;
}
.btn-primary { background: var(--steel); color: #fff; box-shadow: 0 6px 18px rgba(31,111,235,.35); }
.btn-primary:hover { transform: translateY(-2px); background: var(--steel-2); }
.btn-ghost { background: transparent; color: var(--navy); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--steel); color: var(--steel); }
.btn-light { background: #fff; color: var(--navy); }

/* ---------- Hero ---------- */
.hero {
  position: relative; color: #fff; overflow: hidden;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 55%, var(--steel-2) 100%);
}
/* Three.js 粒子画布：位于渐变之上、内容之下，且不拦截点击 */
#hero-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
  display: block; z-index: 0; pointer-events: none;
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: 0;
  background-image: radial-gradient(circle at 80% 20%, rgba(31,111,235,.25), transparent 40%),
                    radial-gradient(circle at 10% 90%, rgba(255,255,255,.06), transparent 35%);
}
.hero .container { position: relative; z-index: 1; padding: 120px 24px 130px; }
.hero .badge {
  display: inline-block; padding: 6px 16px; border: 1px solid rgba(255,255,255,.3);
  border-radius: 20px; font-size: 13px; letter-spacing: 1px; margin-bottom: 22px;
}
.hero h1 { font-size: 52px; line-height: 1.15; max-width: 760px; margin-bottom: 22px; }
.hero p { font-size: 18px; color: rgba(255,255,255,.85); max-width: 640px; margin-bottom: 36px; }
.hero .actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* ---------- 数据统计 ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 64px; }
.stat { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); border-radius: var(--radius); padding: 26px; }
.stat .num { font-size: 40px; font-weight: 800; color: #fff; }
.stat .label { color: rgba(255,255,255,.8); font-size: 14px; margin-top: 6px; }

/* ---------- 卡片网格 ---------- */
.grid { display: grid; gap: 28px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card .icon {
  width: 52px; height: 52px; border-radius: 12px; display: flex; align-items: center;
  justify-content: center; font-size: 24px; margin-bottom: 18px;
  background: linear-gradient(135deg, var(--navy), var(--steel)); color: #fff;
}
.card h3 { font-size: 20px; color: var(--navy); margin-bottom: 10px; }
.card p { color: var(--slate); font-size: 15px; }
.card .more { display: inline-block; margin-top: 16px; color: var(--steel); font-weight: 600; }
.card-link { color: inherit; }

/* ---------- 解决方案 ---------- */
.solution-block { margin-bottom: 48px; }
.solution-block h3 { font-size: 24px; color: var(--navy); margin-bottom: 20px; display: flex; align-items: center; gap: 12px; }
.solution-block h3::before { content: ""; width: 6px; height: 26px; background: var(--steel); border-radius: 3px; }

/* ---------- CTA ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--navy), var(--steel-2));
  color: #fff; border-radius: 20px; padding: 60px; text-align: center;
}
.cta-band h2 { font-size: 32px; margin-bottom: 14px; }
.cta-band p { color: rgba(255,255,255,.85); margin-bottom: 28px; max-width: 560px; margin-left: auto; margin-right: auto; }

/* ---------- 页脚 ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,.7); padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 36px; }
.footer-grid h4 { color: #fff; font-size: 16px; margin-bottom: 16px; }
.footer-grid a { display: block; padding: 5px 0; color: rgba(255,255,255,.7); font-size: 14px; }
.footer-grid a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-top: 20px; font-size: 13px; text-align: center; }

/* ---------- 详情页 ---------- */
.page-hero { background: var(--bg); padding: 64px 0 48px; border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: 38px; color: var(--navy); }
.page-hero p { color: var(--slate); margin-top: 10px; font-size: 17px; }
.breadcrumb { font-size: 14px; color: var(--slate); margin-bottom: 14px; }
.breadcrumb a:hover { color: var(--steel); }
.detail-body { font-size: 16px; color: var(--ink); }
.detail-body p { margin-bottom: 16px; }
.detail-body h3 { color: var(--navy); margin: 28px 0 12px; }

/* ---------- 表单 ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.field { margin-bottom: 20px; }
.field.full { grid-column: 1 / -1; }
.field label { display: block; font-weight: 600; color: var(--navy-2); margin-bottom: 8px; font-size: 14px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 15px; font-family: inherit; transition: border-color .2s;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: 0; border-color: var(--steel); }
.field textarea { min-height: 130px; resize: vertical; }
.alert-success {
  background: #e6f6ec; border: 1px solid #9fdcb4; color: #1f7a43;
  padding: 14px 18px; border-radius: 8px; margin-bottom: 24px; font-weight: 500;
}

/* ---------- 下载/列表表 ---------- */
table.list { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
table.list th, table.list td { padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--line); font-size: 15px; }
table.list th { background: var(--navy); color: #fff; font-weight: 600; }
table.list tr:hover td { background: var(--bg); }

/* ---------- 后台 ---------- */
.admin-shell { display: flex; min-height: 100vh; }
.admin-side { width: 230px; background: var(--navy); color: #fff; padding: 24px 16px; }
.admin-side .brand { color: #fff; margin-bottom: 28px; }
.admin-side a { display: block; padding: 11px 14px; border-radius: 8px; color: rgba(255,255,255,.8); margin-bottom: 4px; font-size: 14px; }
.admin-side a:hover, .admin-side a.active { background: rgba(255,255,255,.12); color: #fff; }
.admin-main { flex: 1; padding: 32px 40px; background: var(--bg); }
.admin-main h1 { color: var(--navy); font-size: 26px; margin-bottom: 24px; }
.admin-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.stat-cards { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-bottom: 28px; }
.stat-cards .sc { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.stat-cards .sc .n { font-size: 30px; font-weight: 800; color: var(--steel); }
.stat-cards .sc .t { color: var(--slate); font-size: 13px; }
.btn-sm { padding: 7px 14px; font-size: 13px; border-radius: 6px; }
.btn-danger { background: #e53e3e; color: #fff; }
.btn-danger:hover { background: #c53030; }
.tag { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 12px; background: var(--bg); color: var(--navy-2); border: 1px solid var(--line); }
.badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 600; }
.badge.ok { background: #e6f6ec; color: #1a7f37; }
.badge.warn { background: #fef3e2; color: #b7791f; }
.detail-row { display: flex; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.detail-label { width: 96px; flex-shrink: 0; color: var(--slate); font-weight: 600; }
.detail-text { white-space: pre-wrap; line-height: 1.7; }

/* ---------- 滚动揭示（.reveal） ---------- */
/* 元素进入视口前：透明 + 轻微下移；加上 .in 后归位。缓动曲线更高级。 */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal.in { opacity: 1; transform: none; }
/* 卡片揭示后仍需保留 hover 抬升：提高特异性覆盖 .reveal.in 的 transform */
.card.reveal:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
/* 减少动态偏好：直接显示，不做位移/淡入 */
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- 视差容器（[data-parallax]） ---------- */
.parallax-wrap { overflow: hidden; } /* 裁掉视差位移溢出 */
.case-cover { margin: 0; padding: 0; overflow: hidden; max-height: 360px; background: var(--navy); }
.case-cover img { width: 100%; height: 420px; object-fit: cover; display: block; will-change: transform; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 38px; }
  .nav-links { display: none; }
  .nav-links.open { display: flex; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; background: #fff; padding: 16px 24px; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: block; }
  .admin-shell { flex-direction: column; }
  .admin-side { width: 100%; display: flex; flex-wrap: wrap; gap: 4px; }
  .admin-side .brand { width: 100%; }
}
@media (max-width: 560px) {
  .stats, .footer-grid, .stat-cards { grid-template-columns: 1fr; }
  .hero h1 { font-size: 30px; }
  .section { padding: 56px 0; }
}
