/* ===== 基础变量 ===== */
:root {
  --bg-light: #f8f9fc;
  --bg-white: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f4ff;
  --bg-section-alt: #f0f4fa;
  --accent: #0066ff;
  --accent2: #7c3aed;
  --accent-gradient: linear-gradient(135deg, #0066ff 0%, #7c3aed 100%);
  --text: #334155;
  --text-muted: #64748b;
  --text-heading: #0f172a;
  --border: rgba(0, 0, 0, 0.08);
  --glow: 0 8px 32px rgba(0, 102, 255, 0.12);
  --shadow-card: 0 2px 16px rgba(0, 0, 0, 0.06);
  --shadow-card-hover: 0 8px 32px rgba(0, 102, 255, 0.12);
  --radius: 16px;
  --nav-h: 72px;
}

/* ===== 重置 ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }
body {
  font-family: 'Noto Sans SC', system-ui, -apple-system, sans-serif;
  background: var(--bg-light);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }
input, textarea, button { font-family: inherit; }

/* ===== 容器 ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ===== 导航栏 ===== */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h);
  display: flex; align-items: center;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: background .3s, box-shadow .3s;
}
#navbar.scrolled { background: rgba(255, 255, 255, 0.95); box-shadow: 0 4px 30px rgba(0,0,0,.08); }
.nav-container {
  max-width: 1200px; width: 100%; margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.logo { font-size: 1.25rem; font-weight: 700; color: var(--text-heading); display: flex; align-items: center; gap: 6px; }
.logo-icon { color: var(--accent); font-size: 1.4rem; }
.nav-links { display: flex; gap: 32px; }
.nav-links a {
  font-size: .9rem; font-weight: 500; color: var(--text-muted);
  position: relative; transition: color .25s;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px;
  background: var(--accent-gradient); transition: width .25s;
}
.nav-links a:hover, .nav-links a.active { color: var(--accent); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

/* 移动端菜单按钮 */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle span {
  display: block; width: 24px; height: 2px; background: var(--text-heading);
  margin: 5px 0; transition: .3s;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-block; padding: 14px 32px; border-radius: 8px;
  font-weight: 600; font-size: .95rem; cursor: pointer;
  transition: transform .2s, box-shadow .2s; border: none;
}
.btn-primary {
  background: var(--accent-gradient); color: #fff;
  box-shadow: 0 4px 24px rgba(0, 102, 255, 0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0, 102, 255, 0.35); }
.btn-outline {
  background: transparent; color: var(--accent);
  border: 1.5px solid var(--accent);
}
.btn-outline:hover { background: rgba(0, 102, 255, 0.06); transform: translateY(-2px); }
.btn-full { width: 100%; text-align: center; }

/* ===== Hero ===== */
#hero {
  position: relative; min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 120px 24px 80px;
  overflow: hidden;
  background: linear-gradient(170deg, #e8f0fe 0%, #f8f9fc 40%, #f0e8ff 100%);
}
.particle-bg {
  position: absolute; inset: 0; z-index: 0;
}
.hero-content { position: relative; z-index: 1; }
.hero-title { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 900; line-height: 1.2; margin-bottom: 20px; }
.glow {
  background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 30px rgba(0, 102, 255, 0.2));
}
.hero-title .sub { display: block; font-size: .45em; font-weight: 400; color: var(--text-muted); margin-top: 8px; -webkit-text-fill-color: var(--text-muted); }
.hero-desc { font-size: 1.15rem; color: var(--text-muted); margin-bottom: 36px; letter-spacing: .5px; }
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* 向下滚动提示 */
.scroll-hint {
  position: absolute; bottom: 32px; display: flex; flex-direction: column; align-items: center;
  color: var(--text-muted); font-size: .8rem; gap: 8px; z-index: 1;
  animation: float 2.5s ease-in-out infinite;
}
.scroll-arrow {
  width: 20px; height: 20px; border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent);
  transform: rotate(45deg);
}
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(8px)} }

/* ===== 通用段落标题 ===== */
.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; text-align: center;
  color: var(--text-heading); margin-bottom: 12px;
}
.section-title.left { text-align: left; }
.section-subtitle { text-align: center; color: var(--text-muted); margin-bottom: 48px; font-size: 1rem; }

section { padding: 100px 0; }

/* ===== 服务卡片 ===== */
.services-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}
.service-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 36px 28px;
  box-shadow: var(--shadow-card);
  transition: transform .3s, box-shadow .3s, border-color .3s;
  opacity: 0; transform: translateY(30px);
}
.service-card.visible { opacity: 1; transform: translateY(0); transition: opacity .6s, transform .6s; }
.service-card:hover {
  transform: translateY(-6px); border-color: rgba(0, 102, 255, 0.15);
  box-shadow: var(--shadow-card-hover);
}
.card-icon { width: 56px; height: 56px; color: var(--accent); margin-bottom: 20px; }
.card-icon svg { width: 100%; height: 100%; }
.service-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 10px; color: var(--text-heading); }
.service-card p { color: var(--text-muted); font-size: .92rem; }

/* ===== 案例展示 ===== */
#cases { background: var(--bg-section-alt); }

/* 子标题（精选 / 更多案例） */
.cases-subhead {
  display: flex; align-items: center; gap: 16px;
  font-size: 1.1rem; font-weight: 700; color: var(--text-heading);
  margin: 16px 0 24px;
}
.cases-subhead::after {
  content: ''; flex: 1; height: 1px;
  background: linear-gradient(to right, rgba(0,102,255,0.25), transparent);
}
.cases-subhead span {
  position: relative; padding-left: 14px;
}
.cases-subhead span::before {
  content: ''; position: absolute; left: 0; top: 50%;
  transform: translateY(-50%);
  width: 4px; height: 18px; border-radius: 2px;
  background: var(--accent-gradient);
}

/* 精选大卡区 */
.cases-featured {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 32px; margin-bottom: 56px;
}

/* 更多案例小卡区 */
.cases-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.case-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform .3s, box-shadow .3s;
  opacity: 0; transform: translateY(30px);
  position: relative;
}
.case-card.visible { opacity: 1; transform: translateY(0); transition: opacity .6s, transform .6s; }
.case-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card-hover);
}
.case-img {
  width: 100%; height: 220px; object-fit: cover;
  transition: transform .4s;
}
.case-card:hover .case-img { transform: scale(1.05); }
.case-img-wrapper { overflow: hidden; }
.case-body { padding: 24px; }
.case-tag {
  display: inline-block; padding: 4px 12px; border-radius: 20px;
  font-size: .75rem; font-weight: 600; color: var(--accent);
  background: rgba(0, 102, 255, 0.08); margin-bottom: 12px;
}
.case-body h3 { font-size: 1.1rem; font-weight: 700; color: var(--text-heading); margin-bottom: 8px; }
.case-body p { color: var(--text-muted); font-size: .88rem; line-height: 1.6; }

/* 精选大卡专属样式 */
.case-featured {
  border: 1.5px solid rgba(0, 102, 255, 0.18);
  box-shadow: 0 8px 40px rgba(0, 102, 255, 0.12);
}
.case-featured:hover {
  box-shadow: 0 16px 56px rgba(0, 102, 255, 0.18);
  border-color: rgba(0, 102, 255, 0.32);
}
.case-featured .case-img-wrapper { background: #0f172a; }
.case-featured .carousel-track { height: 420px; }
.case-featured .case-body { padding: 32px 32px 36px; }
.case-featured .case-body h3 { font-size: 1.5rem; margin-bottom: 12px; }
.case-featured .case-body p { font-size: .98rem; line-height: 1.75; color: var(--text); }
.case-featured .case-tag {
  font-size: .8rem; padding: 6px 14px; margin-bottom: 16px;
  background: var(--accent-gradient); color: #fff;
}

.featured-badge {
  position: absolute; top: 16px; left: 16px; z-index: 3;
  padding: 6px 14px; border-radius: 20px;
  font-size: .78rem; font-weight: 700; color: #fff;
  background: var(--accent-gradient);
  box-shadow: 0 4px 16px rgba(0, 102, 255, 0.4);
  letter-spacing: .5px;
}

.case-more-hint {
  display: inline-block; margin-top: 18px;
  font-size: .88rem; font-weight: 600; color: var(--accent);
  transition: transform .25s;
}
.case-featured:hover .case-more-hint { transform: translateX(4px); }

/* ===== 案例卡片：图片轮播 ===== */
.case-carousel { position: relative; cursor: zoom-in; background: #0f172a; }
.case-carousel .carousel-track {
  position: relative; width: 100%; height: 260px;
}
.case-featured .case-carousel .carousel-track { height: 420px; }
.carousel-slide {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: contain;
  padding: 8px;
  opacity: 0; transition: opacity .7s ease;
}
.carousel-slide.active { opacity: 1; }
.carousel-dots {
  position: absolute; left: 0; right: 0; bottom: 10px;
  display: flex; justify-content: center; gap: 6px; z-index: 2;
}
.carousel-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
  transition: width .3s, background .3s;
}
.carousel-dot.active { width: 18px; border-radius: 3px; background: #fff; }
.case-card[data-lightbox] { cursor: pointer; }

/* ===== 图片灯箱 ===== */
.lightbox {
  position: fixed; inset: 0; z-index: 2000;
  display: none; align-items: center; justify-content: center;
  padding: 24px;
}
.lightbox.open { display: flex; }
.lightbox-backdrop {
  position: absolute; inset: 0;
  background: rgba(15, 23, 42, 0.88);
  backdrop-filter: blur(6px);
  animation: lbFade .25s ease;
}
.lightbox-content {
  position: relative; z-index: 1;
  width: min(100%, 1100px); max-height: calc(100vh - 48px);
  display: flex; flex-direction: column; align-items: center;
  animation: lbPop .3s ease;
}
@keyframes lbFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lbPop { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: scale(1); } }
.lightbox-stage {
  position: relative; width: 100%;
  display: flex; flex-direction: column; align-items: center;
  flex: 1; min-height: 0;
}
.lightbox-img {
  max-width: 100%; max-height: calc(100vh - 220px);
  object-fit: contain; border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  background: #fff;
}
.lightbox-caption {
  margin-top: 14px; text-align: center; color: #f1f5f9;
}
.lightbox-caption h4 { font-size: 1rem; font-weight: 600; margin-bottom: 4px; }
.lightbox-caption span { font-size: .82rem; color: #94a3b8; }
.lightbox-close, .lightbox-nav {
  position: absolute; background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, transform .2s;
}
.lightbox-close {
  top: 16px; right: 16px;
  width: 44px; height: 44px; border-radius: 50%;
  font-size: 1.8rem; line-height: 1;
  z-index: 10;
}
.lightbox-nav {
  top: 50%; transform: translateY(-50%);
  width: 48px; height: 48px; border-radius: 50%;
  font-size: 1rem;
}
.lightbox-prev { left: -8px; }
.lightbox-next { right: -8px; }
.lightbox-close:hover, .lightbox-nav:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox-nav:hover { transform: translateY(-50%) scale(1.08); }
.lightbox-thumbs {
  display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; justify-content: center;
}
.lightbox-thumb {
  width: 64px; height: 64px; object-fit: cover; border-radius: 6px;
  border: 2px solid transparent; opacity: .55; cursor: pointer;
  transition: opacity .2s, border-color .2s;
}
.lightbox-thumb:hover { opacity: .85; }
.lightbox-thumb.active { opacity: 1; border-color: var(--accent); }
body.lightbox-open { overflow: hidden; }

@media (max-width: 768px) {
  .lightbox { padding: 12px; }
  .lightbox-img { max-height: calc(100vh - 260px); }
  .lightbox-nav { width: 40px; height: 40px; }
  .lightbox-prev { left: 4px; }
  .lightbox-next { right: 4px; }
  .lightbox-thumb { width: 48px; height: 48px; }
}

/* ===== 关于我们 ===== */
#about { background: var(--bg-white); }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.about-desc { color: var(--text-muted); margin-bottom: 16px; font-size: .95rem; }
.about-desc strong { color: var(--text-heading); }
.about-highlights { display: flex; flex-direction: column; gap: 16px; margin-top: 24px; }
.about-highlight-item { display: flex; align-items: flex-start; gap: 12px; }
.highlight-icon { color: var(--accent); font-size: .5rem; margin-top: 6px; flex-shrink: 0; }
.about-highlight-item strong { display: block; font-size: .92rem; color: var(--text-heading); margin-bottom: 2px; }
.about-highlight-item span { font-size: .85rem; color: var(--text-muted); }
.about-stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 40px;
}
.about-office-img {
  width: 100%; height: auto; object-fit: contain; border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}
.stat {
  background: var(--bg-light); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 20px; text-align: center;
  box-shadow: var(--shadow-card);
  transition: border-color .3s, box-shadow .3s;
}
.stat:hover { border-color: rgba(0, 102, 255, 0.2); box-shadow: var(--shadow-card-hover); }
.stat-number {
  font-size: 2.4rem; font-weight: 900;
  background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.stat-suffix {
  font-size: 1.6rem; font-weight: 700;
  background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.stat-label { display: block; color: var(--text-muted); font-size: .85rem; margin-top: 4px; }

/* ===== 核心优势 ===== */
.advantages-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.adv-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 36px 28px;
  box-shadow: var(--shadow-card);
  transition: transform .3s, box-shadow .3s, border-color .3s;
  opacity: 0; transform: translateY(30px);
}
.adv-card.visible { opacity: 1; transform: translateY(0); transition: opacity .6s, transform .6s; }
.adv-card:hover { transform: translateY(-4px); border-color: rgba(124, 58, 237, 0.2); box-shadow: 0 8px 32px rgba(124, 58, 237, 0.1); }
.adv-number {
  font-size: 2.2rem; font-weight: 900;
  background: var(--accent-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  margin-bottom: 12px;
}
.adv-card h3 { font-size: 1.1rem; font-weight: 700; color: var(--text-heading); margin-bottom: 8px; }
.adv-card p { color: var(--text-muted); font-size: .9rem; }

/* ===== 联系我们 ===== */
#contact { background: var(--bg-section-alt); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: stretch; }
.contact-info { display: flex; flex-direction: column; gap: 28px; }
.contact-card {
  background: #fff; border-radius: 20px; padding: 40px;
  box-shadow: 0 4px 24px rgba(0,102,255,0.08); border: 1px solid var(--border);
}
.contact-card-title { font-size: 1.1rem; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.info-item { display: flex; align-items: flex-start; gap: 16px; }
.info-icon { width: 44px; height: 44px; min-width: 44px; color: var(--accent); background: rgba(0, 102, 255, 0.08); border-radius: 10px; display: flex; align-items: center; justify-content: center; padding: 10px; }
.info-icon svg { width: 100%; height: 100%; }
.info-item h4 { font-size: .95rem; font-weight: 600; color: var(--text-heading); margin-bottom: 2px; }
.info-item p { color: var(--text-muted); font-size: .9rem; }

/* 联系表单 */
.contact-form { display: flex; flex-direction: column; gap: 16px; }
.wechat-contact { display: flex; align-items: center; justify-content: center; }
.wechat-qr-placeholder {
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.wechat-qr-header {
  display: flex; align-items: center; gap: 8px;
  font-size: 1rem; font-weight: 600; color: #07C160;
}
.wechat-qr-img {
  width: 200px; height: 200px; object-fit: contain;
  border-radius: 12px; border: 1px solid var(--border);
}
.wechat-qr-tip { color: var(--text-muted); font-size: 0.85rem; margin: 0; }
.form-row { display: flex; gap: 16px; }
.form-row input { flex: 1; }
input, textarea {
  width: 100%; padding: 14px 18px; border-radius: 8px;
  background: var(--bg-white); border: 1px solid var(--border);
  color: var(--text); font-size: .92rem; outline: none;
  transition: border-color .25s, box-shadow .25s;
}
input:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1); }
input::placeholder, textarea::placeholder { color: #94a3b8; }
textarea { resize: vertical; min-height: 120px; }

/* ===== 页脚 ===== */
footer { background: #0f172a; padding: 60px 0 0; border-top: 1px solid var(--border); color: #cbd5e1; }
footer .logo { color: #f8fafc; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 48px; padding-bottom: 40px; }
.footer-brand p { color: #94a3b8; font-size: .9rem; margin-top: 12px; max-width: 300px; }
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links h4 { font-size: .95rem; font-weight: 600; color: #f1f5f9; margin-bottom: 6px; }
.footer-links a { color: #94a3b8; font-size: .88rem; transition: color .2s; }
.footer-links a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08); padding: 20px 0; text-align: center;
  color: #64748b; font-size: .82rem;
}

/* ===== 粒子 canvas ===== */
#particles canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ===== 响应式 ===== */
@media (max-width: 900px) {
  .about-grid, .contact-grid, .footer-grid { grid-template-columns: 1fr; }
  .about-stats { grid-template-columns: 1fr 1fr; }
  .cases-grid { grid-template-columns: 1fr; }
  .cases-featured { grid-template-columns: 1fr; gap: 24px; }
  .case-featured .case-carousel .carousel-track { height: 320px; }
  .case-featured .case-body { padding: 24px; }
  .case-featured .case-body h3 { font-size: 1.25rem; }
}
@media (max-width: 768px) {
  .nav-links { display: none; position: fixed; top: var(--nav-h); left: 0; right: 0; background: rgba(255,255,255,.98); flex-direction: column; padding: 24px; gap: 20px; border-bottom: 1px solid var(--border); box-shadow: 0 8px 24px rgba(0,0,0,.08); }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
  .nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
  .nav-toggle.active span:nth-child(2) { opacity: 0; }
  .nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
  .services-grid { grid-template-columns: 1fr; }
  .advantages-grid { grid-template-columns: 1fr; }
  .cases-grid { grid-template-columns: 1fr; }
  .form-row { flex-direction: column; }
  .hero-title { font-size: 2rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}
