/* ===== 四川耐思魔方企业官网 - 全局样式 ===== */

/* 字体引入 */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;600;700&display=swap');

/* CSS 变量 */
:root {
  --primary: #1a56db;
  --primary-dark: #1040a8;
  --primary-light: #e8f0fe;
  --accent: #f97316;
  --text-dark: #1a1a2e;
  --text-body: #374151;
  --text-muted: #6b7280;
  --border: #e5e7eb;
  --bg-light: #f9fafb;
  --bg-white: #ffffff;
  --gradient: linear-gradient(135deg, #1a56db 0%, #0ea5e9 100%);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 20px;
}

/* 全局重置 */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: var(--text-body);
  background: var(--bg-white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; transition: all 0.3s; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.3s;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 15px rgba(26,86,219,0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(26,86,219,0.45);
  color: #fff;
}
.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}
.btn-white {
  background: #fff;
  color: var(--primary);
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}
.btn-lg { padding: 16px 36px; font-size: 16px; }

/* ===== 导航栏 ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(229,231,235,0.6);
  transition: all 0.3s;
}
.navbar.scrolled {
  box-shadow: 0 2px 20px rgba(0,0,0,0.08);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}
/* Logo 图片样式 */
.nav-logo .logo-img {
  height: 65px;
  width: auto;
  display: block;
}
.footer-logo {
  height: 40px;
  width: auto;
  margin-bottom: 16px;
  display: block;
}

/* 导航栏 logo 容器 */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.nav-logo .logo-icon {
  width: 40px;
  height: 40px;
  background: var(--gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -1px;
}
.nav-logo .logo-text {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-dark);
}
.nav-logo .logo-text span { color: var(--primary); }
.nav-menu {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-menu a {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 15px;
  color: var(--text-body);
  position: relative;
}
.nav-menu a:hover, .nav-menu a.active {
  color: var(--primary);
  background: var(--primary-light);
}
.nav-menu .has-dropdown {
  position: relative;
}
.nav-menu .has-dropdown > a::after {
  content: '▾';
  margin-left: 4px;
  font-size: 12px;
}
.dropdown {
  position: absolute;
  top: 100%; 
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  padding: 8px;
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  pointer-events: none;
  z-index: 999;
  margin-top: -2px; 
}
/* 空的下拉菜单不显示 */
.dropdown:empty {
  display: none;
}
.has-dropdown:hover .dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}
.dropdown a {
  display: block;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  white-space: nowrap;
}
.dropdown a:hover { background: var(--primary-light); color: var(--primary); }
.nav-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav-phone {
  font-size: 14px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav-phone i { color: var(--primary); }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: all 0.3s;
}

/* ===== 移动端导航（桌面端默认隐藏）===== */
.mobile-nav {
  display: none;
}

/* ===== 页脚 ===== */
.footer {
  background: #0f172a;
  color: rgba(255,255,255,0.7);
  padding: 60px 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand .logo-text {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}
.footer-brand .logo-text span { color: #60a5fa; }
.footer-brand p {
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 20px;
  color: rgba(255,255,255,0.6);
}
.footer-social {
  display: flex;
  gap: 10px;
}
.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  transition: all 0.3s;
}
.footer-social a:hover { background: var(--primary); color: #fff; }
.footer-col h4 {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 20px;
}
.footer-col ul li {
  margin-bottom: 10px;
}
.footer-col ul li a {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  transition: all 0.3s;
}
.footer-col ul li a:hover { color: #fff; padding-left: 4px; }
.footer-contact-info {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-contact-info .item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
}
.footer-contact-info .item i {
  color: #60a5fa;
  margin-top: 2px;
  flex-shrink: 0;
}
.footer-bottom {
  padding: 20px 0;
  text-align: center;
  font-size: 13px;
  color: rgba(255,255,255,0.4);
}

/* ===== 区块标题 ===== */
.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-tag {
  display: inline-block;
  padding: 6px 18px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.3;
  margin-bottom: 16px;
}
.section-title em {
  font-style: normal;
  color: var(--primary);
}
.section-desc {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== 分页间距 ===== */
.section { padding: 80px 0; }
.section-gray { background: var(--bg-light); }

/* ===== 卡片 ===== */
.card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 32px;
  transition: all 0.3s;
  border: 1px solid var(--border);
}
.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: transparent;
}
.card-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 20px;
}

/* ===== 页面Banner ===== */
.page-banner {
  background: var(--gradient);
  padding: 120px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(255,255,255,0.05) 0%, transparent 60%),
              radial-gradient(circle at 70% 80%, rgba(255,255,255,0.05) 0%, transparent 50%);
  pointer-events: none;
}
.page-banner h1 {
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 700;
  color: #fff;
  margin-bottom: 16px;
}
.page-banner p {
  font-size: 16px;
  color: rgba(255,255,255,0.8);
  max-width: 600px;
  margin: 0 auto 24px;
}
.breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  color: rgba(255,255,255,0.7);
}
.breadcrumb a { color: rgba(255,255,255,0.7); }
.breadcrumb a:hover { color: #fff; }
.breadcrumb .sep { opacity: 0.5; }

/* ===== 数字统计 ===== */
.stat-item {
  text-align: center;
}
.stat-number {
  font-size: 42px;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 14px;
  color: var(--text-muted);
}

/* ===== 流程步骤 ===== */
.step-item {
  display: flex;
  gap: 20px;
}
.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-menu, .nav-cta .btn { display: none; }
  .nav-phone { display: none; }
  .hamburger { display: flex; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .section { padding: 60px 0; }
  .section-header { margin-bottom: 40px; }
  
  /* Mobile menu */
  .mobile-nav {
    display: block;
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
    padding: 16px;
    z-index: 999;
    transform: translateY(-100%);
    opacity: 0;
    transition: all 0.3s;
    pointer-events: none;
  }
  .mobile-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
  .mobile-nav a {
    display: block;
    padding: 12px 16px;
    border-radius: 8px;
    color: var(--text-body);
    font-size: 15px;
  }
  .mobile-nav a:hover { background: var(--primary-light); color: var(--primary); }
  .mobile-nav .sub-links {
    padding-left: 16px;
  }
  .mobile-nav .sub-title {
    font-size: 12px;
    color: var(--text-muted);
    padding: 8px 16px 4px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
  }
  .mobile-nav .mobile-cta {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
  }
  .mobile-nav .mobile-cta a {
    background: var(--gradient);
    color: #fff;
    text-align: center;
    border-radius: 50px;
  }
}

/* ===== 动画 ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.animate-fadeInUp { animation: fadeInUp 0.7s ease both; }
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }

/* ===== 辅助工具类 ===== */
.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.fw-700 { font-weight: 700; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }

/* 网格布局 */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 576px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* ===== 联系浮动按钮 ===== */
.float-contact {
  position: fixed;
  right: 24px;
  bottom: 80px;
  z-index: 900;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.float-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 4px 15px rgba(26,86,219,0.4);
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
}
.float-btn:hover { transform: scale(1.1); }
.float-btn .tooltip {
  position: absolute;
  right: 60px;
  background: #0f172a;
  color: #fff;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s;
}
.float-btn:hover .tooltip { opacity: 1; }
.float-btn.top-btn { background: rgba(255,255,255,0.9); color: var(--primary); box-shadow: 0 4px 15px rgba(0,0,0,0.1); }
.float-btn.top-btn:hover { background: #fff; }

/* ===== 标签样式 ===== */
.tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.03em;
}
.tag-primary { background: var(--primary-light); color: var(--primary); }
.tag-orange { background: #fff7ed; color: #f97316; }
.tag-green { background: #f0fdf4; color: #16a34a; }
.tag-purple { background: #faf5ff; color: #7c3aed; }
