/* ============ 全局基础 ============ */
:root {
  --primary: #1a56db;
  --primary-dark: #1240a8;
  --primary-light: #3b82f6;
  --accent: #0ea5e9;
  --text: #0f172a;
  --text-light: #475569;
  --muted: #94a3b8;
  --bg: #ffffff;
  --bg-soft: #f8fafc;
  --bg-deep: #0b1020;
  --border: #e2e8f0;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 60px rgba(15, 23, 42, 0.12);
  --max-w: 1200px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei",
               "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ 顶部导航 ============ */
.navbar {
  position: fixed; top: 0; left: 0; right: 0;
  background: rgba(255,255,255,0.9);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  z-index: 100;
  transition: all .25s ease;
}
.navbar.scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 20px; color: var(--text);
}
.logo-mark {
  width: 36px; height: 36px; border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 18px; letter-spacing: -1px;
}
.nav-links { display: flex; gap: 8px; list-style: none; }
.nav-links a {
  padding: 10px 18px; border-radius: var(--radius-sm);
  color: var(--text-light); font-size: 15px; font-weight: 500;
  transition: all .2s;
}
.nav-links a:hover { color: var(--primary); background: rgba(26,86,219,.06); }
.nav-links a.active { color: var(--primary); background: rgba(26,86,219,.08); }
.nav-cta {
  padding: 10px 22px !important;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff !important;
}
.nav-cta:hover { opacity: .92; color: #fff !important; }
.nav-links a.nav-cta.active { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: #fff !important; }
.nav-links a.nav-cta:hover { background: linear-gradient(135deg, var(--primary), var(--primary-light)); }

.mobile-toggle {
  display: none; background: none; border: none;
  width: 40px; height: 40px; font-size: 24px; color: var(--text);
}

/* ============ Hero ============ */
.hero {
  position: relative;
  padding: 160px 0 120px;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(26,86,219,.12), transparent 50%),
    radial-gradient(ellipse at 80% 30%, rgba(14,165,233,.10), transparent 50%),
    linear-gradient(180deg, #f0f5ff 0%, #ffffff 100%);
  overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(26,86,219,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(26,86,219,.04) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
}
.hero-inner { position: relative; z-index: 1; text-align: center; max-width: 900px; margin: 0 auto; }
.hero-badge {
  display: inline-block; padding: 6px 16px; border-radius: 999px;
  background: rgba(26,86,219,.08); color: var(--primary);
  font-size: 13px; font-weight: 500; margin-bottom: 24px;
}
.hero h1 {
  font-size: 54px; line-height: 1.15; font-weight: 800;
  color: var(--text); letter-spacing: -1px; margin-bottom: 20px;
}
.hero h1 .grad {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p { font-size: 18px; color: var(--text-light); margin-bottom: 40px; }
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ============ 按钮 ============ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 32px; border-radius: 50px; font-weight: 600;
  font-size: 15px; border: none; transition: all .25s ease;
}
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff; box-shadow: 0 8px 24px rgba(26,86,219,.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(26,86,219,.38); }
.btn-ghost {
  background: #fff; color: var(--text); border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

/* ============ Section 通用 ============ */
.section { padding: 100px 0; }
.section-alt { background: var(--bg-soft); }
.section-head { text-align: center; margin-bottom: 60px; }
.section-tag {
  display: inline-block; color: var(--primary); font-weight: 600;
  font-size: 14px; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 12px;
}
.section-title { font-size: 36px; font-weight: 800; color: var(--text); margin-bottom: 12px; letter-spacing: -0.5px; }
.section-sub { color: var(--text-light); font-size: 16px; }

/* ============ 服务卡片 ============ */
.services-grid {
  display: grid; gap: 24px;
  grid-template-columns: repeat(3, 1fr);
}
.service-card {
  background: #fff; border-radius: var(--radius); padding: 32px;
  border: 1px solid var(--border); transition: all .3s ease;
  position: relative; overflow: hidden;
}
.service-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform: scaleX(0); transform-origin: left; transition: transform .3s ease;
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.service-card:hover::before { transform: scaleX(1); }
.service-icon { font-size: 40px; margin-bottom: 16px; }
.service-card h3 { font-size: 20px; margin-bottom: 12px; }
.service-card p { color: var(--text-light); font-size: 14px; margin-bottom: 16px; }
.service-features { display: flex; flex-wrap: wrap; gap: 8px; }
.service-features span {
  font-size: 12px; padding: 4px 12px; border-radius: 999px;
  background: var(--bg-soft); color: var(--text-light);
}

/* ============ 关于我们 ============ */
.about-wrap {
  display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center;
}
.about-text h2 { font-size: 36px; font-weight: 800; margin-bottom: 20px; }
.about-text p { color: var(--text-light); margin-bottom: 16px; }
.about-stats {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin-top: 40px;
}
.stat-item { padding: 20px; background: var(--bg-soft); border-radius: var(--radius-sm); }
.stat-num { font-size: 36px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 14px; color: var(--text-light); }

.about-visual {
  position: relative; height: 420px;
  background: linear-gradient(135deg, #1a56db 0%, #0ea5e9 100%);
  border-radius: 24px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
}
.about-visual::before {
  content: ''; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 30px 30px;
}
.about-visual-content { position: relative; text-align: center; padding: 40px; }
.about-visual-content .big { font-size: 100px; font-weight: 900; line-height: 1; }
.about-visual-content .slogan { font-size: 18px; margin-top: 12px; opacity: .9; }

/* ============ 案例 ============ */
.cases-grid {
  display: grid; gap: 24px;
  grid-template-columns: repeat(3, 1fr);
}
.case-card {
  background: #fff; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border); transition: all .3s ease;
}
.case-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.case-cover {
  height: 200px; position: relative;
  display: flex; align-items: center; justify-content: center;
  font-size: 60px; color: #fff;
}
.case-cover[data-cover="finance"]   { background: linear-gradient(135deg, #0f766e, #14b8a6); }
.case-cover[data-cover="government"] { background: linear-gradient(135deg, #b45309, #f59e0b); }
.case-cover[data-cover="retail"]    { background: linear-gradient(135deg, #7c3aed, #a78bfa); }
.case-cover[data-cover="manufacture"]{ background: linear-gradient(135deg, #0369a1, #38bdf8); }
.case-cover[data-cover="knowledge"] { background: linear-gradient(135deg, #be185d, #f472b6); }
.case-cover[data-cover="ecommerce"] { background: linear-gradient(135deg, #059669, #34d399); }
.case-body { padding: 24px; }
.case-tag { font-size: 12px; color: var(--primary); font-weight: 600; }
.case-card h3 { font-size: 18px; margin: 8px 0 12px; }
.case-card p { color: var(--text-light); font-size: 14px; }

/* ============ 技术栈 ============ */
.tech-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.tech-tag {
  padding: 14px 28px; border-radius: 50px;
  background: #fff; border: 1px solid var(--border);
  font-size: 14px; font-weight: 500; color: var(--text-light);
  transition: all .2s;
}
.tech-tag:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); }

/* ============ 联系方式 ============ */
.contact-wrap {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 60px;
  background: #fff; border-radius: 20px; padding: 60px;
  box-shadow: var(--shadow-lg);
}
.contact-info h2 { font-size: 28px; margin-bottom: 12px; }
.contact-info > p { color: var(--text-light); margin-bottom: 32px; }
.contact-item { display: flex; gap: 16px; margin-bottom: 24px; }
.contact-item-icon {
  width: 44px; height: 44px; border-radius: 10px;
  background: rgba(26,86,219,.08); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
}
.contact-item-label { font-size: 13px; color: var(--muted); }
.contact-item-value { font-size: 16px; font-weight: 500; margin-top: 2px; }

.form-group { margin-bottom: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 8px; color: var(--text); }
.form-group input, .form-group textarea {
  width: 100%; padding: 12px 16px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-size: 14px; font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(26,86,219,.08);
}
.form-group textarea { resize: vertical; min-height: 120px; }

.form-msg {
  margin-top: 16px; padding: 12px 16px; border-radius: var(--radius-sm);
  font-size: 14px; display: none;
}
.form-msg.success { background: #ecfdf5; color: #047857; display: block; }
.form-msg.error { background: #fef2f2; color: #b91c1c; display: block; }

/* ============ 底部 ============ */
.footer {
  background: var(--bg-deep); color: #cbd5e1; padding: 80px 0 0;
}
.footer-grid {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 60px;
}
.footer-brand .logo { color: #fff; margin-bottom: 16px; }
.footer-brand p { font-size: 14px; color: #94a3b8; max-width: 320px; }
.footer-col h4 { color: #fff; font-size: 16px; margin-bottom: 20px; }
.footer-col a { display: block; padding: 6px 0; color: #94a3b8; font-size: 14px; transition: color .2s; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  margin-top: 60px; padding: 24px 0; text-align: center;
  color: #64748b; font-size: 13px;
}

/* ============ 页面容器（page 切换） ============ */
.page { display: none; animation: fadeIn .35s ease; }
.page.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.page-header {
  padding: 140px 0 60px; background: linear-gradient(180deg, #f0f5ff 0%, #fff 100%);
  text-align: center;
}
.page-header h1 { font-size: 40px; font-weight: 800; margin-bottom: 12px; }
.page-header p { color: var(--text-light); font-size: 16px; }

/* ============ 响应式 ============ */
@media (max-width: 1024px) {
  .services-grid, .cases-grid { grid-template-columns: repeat(2, 1fr); }
  .about-wrap { grid-template-columns: 1fr; gap: 40px; }
  .contact-wrap { grid-template-columns: 1fr; padding: 40px; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 40px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; position: absolute; top: 72px; left: 0; right: 0;
               background: #fff; flex-direction: column; padding: 16px;
               border-bottom: 1px solid var(--border); box-shadow: var(--shadow); }
  .nav-links.open { display: flex; }
  .mobile-toggle { display: block; }

  .hero h1 { font-size: 36px; }
  .hero { padding: 130px 0 80px; }
  .section { padding: 70px 0; }
  .section-title { font-size: 28px; }
  .services-grid, .cases-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .contact-wrap { padding: 28px; }
  .page-header { padding: 120px 0 40px; }
  .page-header h1 { font-size: 28px; }
}
