/* ============================================================
   base —— 变量、重置、基础排版
   ============================================================ */
:root {
  --navy: #1a2a3a;
  --navy-light: #24374a;
  --cyan: #00bcd4;
  --cyan-dark: #0097a7;
  --amber: #ffc107;
  --amber-dark: #e6ab00;
  --bg-light: #f5f7fa;
  --text-dark: #2b2f36;
  --text-body: #4a5568;
  --text-muted: #718096;
  --white: #ffffff;
  --border: #e2e8f0;
  --shadow-sm: 0 1px 3px rgba(26, 42, 58, 0.08);
  --shadow-md: 0 4px 12px rgba(26, 42, 58, 0.1);
  --shadow-lg: 0 8px 24px rgba(26, 42, 58, 0.12);
  --radius: 8px;
  --transition: 0.25s ease;
  --font: 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-body);
  background-color: var(--white);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--cyan-dark);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--navy);
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--navy);
  font-weight: 600;
  line-height: 1.35;
}

h1 {
  font-size: 2.1rem;
}

h2 {
  font-size: 1.6rem;
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
}

p {
  margin-bottom: 0.9rem;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-padding {
  padding: 64px 0;
}

/* ============================================================
   layout —— 顶部导航、页脚、面包屑、侧栏
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--navy);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-mark {
  width: 34px;
  height: 34px;
  background-color: var(--cyan);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 700;
  font-size: 1.1rem;
}

.logo-text {
  color: var(--white);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.logo-text span {
  color: var(--cyan);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.main-nav a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  padding: 6px 0;
  position: relative;
  transition: color 0.2s ease;
}

.main-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background-color: var(--cyan);
  transition: width 0.25s ease;
}

.main-nav a:hover {
  color: var(--white);
}

.main-nav a:hover::after {
  width: 100%;
}

.main-nav a.active {
  color: var(--white);
}

.main-nav a.active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--white);
  margin: 5px 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* 面包屑 */
.breadcrumb {
  background-color: var(--bg-light);
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.breadcrumb-list {
  display: flex;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.breadcrumb-list li + li::before {
  content: '/';
  margin: 0 8px;
  color: #cbd5e0;
}

.breadcrumb-list a {
  color: var(--text-muted);
}

.breadcrumb-list a:hover {
  color: var(--cyan-dark);
}

.breadcrumb-list li:last-child {
  color: var(--text-dark);
  font-weight: 500;
}

/* 内页布局 */
.page-layout {
  display: flex;
  gap: 32px;
  padding: 40px 0 64px;
}

.sidebar {
  width: 260px;
  flex-shrink: 0;
}

.sidebar-nav {
  background-color: var(--bg-light);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 16px 0;
  position: sticky;
  top: 80px;
}

.sidebar-nav li a {
  display: block;
  padding: 10px 20px;
  color: var(--text-body);
  font-size: 0.92rem;
  border-left: 3px solid transparent;
  transition: all 0.2s ease;
}

.sidebar-nav li a:hover {
  background-color: rgba(0, 188, 212, 0.06);
  border-left-color: var(--cyan);
  color: var(--cyan-dark);
}

.sidebar-nav li a.active {
  background-color: rgba(0, 188, 212, 0.08);
  border-left-color: var(--cyan);
  color: var(--cyan-dark);
  font-weight: 600;
}

.main-content {
  flex: 1;
  min-width: 0;
}

/* 页脚 */
.site-footer {
  background-color: var(--navy);
  color: rgba(255, 255, 255, 0.75);
  padding: 56px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer-brand p {
  margin-top: 12px;
  font-size: 0.9rem;
  line-height: 1.7;
}

.footer-title {
  color: var(--white);
  font-size: 1rem;
  margin-bottom: 16px;
  font-weight: 600;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--cyan);
}

.footer-contact p {
  font-size: 0.9rem;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-contact .btn {
  margin-top: 12px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* ============================================================
   components —— 按钮、卡片、步骤条、FAQ、表单、标签
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
  min-height: 44px;
}

.btn-primary {
  background-color: var(--amber);
  color: var(--navy);
}

.btn-primary:hover {
  background-color: var(--amber-dark);
  color: var(--navy);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background-color: transparent;
  border: 1.5px solid var(--cyan);
  color: var(--cyan);
}

.btn-outline:hover {
  background-color: var(--cyan);
  color: var(--white);
}

.btn-light {
  background-color: var(--white);
  color: var(--navy);
}

.btn-light:hover {
  background-color: var(--bg-light);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* 服务卡片 */
.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.service-card {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 22px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--cyan);
}

.service-icon {
  width: 48px;
  height: 48px;
  background-color: rgba(0, 188, 212, 0.1);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--cyan-dark);
  font-size: 1.4rem;
}

.service-card h3 {
  font-size: 1.05rem;
  margin-bottom: 10px;
}

.service-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.card-link {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--cyan-dark);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.card-link:hover {
  color: var(--navy);
}

/* 案例卡片 */
.case-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.case-card {
  background-color: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.case-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.case-media {
  position: relative;
  overflow: hidden;
}

.case-media img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.case-card:hover .case-media img {
  transform: scale(1.03);
}

.case-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background-color: var(--navy);
  color: var(--white);
  font-size: 0.78rem;
  padding: 4px 10px;
  border-radius: 4px;
}

.case-body {
  padding: 20px;
}

.case-body h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}

.case-body p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.case-stats {
  display: flex;
  gap: 24px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.case-stats span {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.case-stats strong {
  color: var(--navy);
  font-size: 1.1rem;
  display: block;
}

/* 步骤条 */
.steps-wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  position: relative;
}

.step-item {
  text-align: center;
  padding: 24px 16px;
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  position: relative;
  transition: box-shadow 0.25s ease;
}

.step-item:hover {
  box-shadow: var(--shadow-md);
}

.step-num {
  width: 40px;
  height: 40px;
  background-color: var(--navy);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  margin: 0 auto 12px;
  font-size: 0.95rem;
}

.step-item:nth-child(even) .step-num {
  background-color: var(--cyan);
}

.step-item h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.step-item p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* 优势亮点 */
.advantage-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.advantage-item {
  display: flex;
  gap: 14px;
  padding: 16px;
  background-color: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.advantage-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  background-color: rgba(255, 193, 7, 0.12);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--amber-dark);
  font-size: 1rem;
}

.advantage-item h3 {
  font-size: 0.98rem;
  margin-bottom: 4px;
}

.advantage-item p {
  font-size: 0.86rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* FAQ */
.faq-list {
  max-width: 800px;
}

.faq-item {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  color: var(--navy);
  text-align: left;
  min-height: 52px;
}

.faq-question:hover {
  background-color: rgba(0, 188, 212, 0.03);
}

.faq-icon {
  width: 20px;
  height: 20px;
  position: relative;
  flex-shrink: 0;
}

.faq-icon::before,
.faq-icon::after {
  content: '';
  position: absolute;
  background-color: var(--cyan);
  transition: transform 0.3s ease;
}

.faq-icon::before {
  width: 14px;
  height: 2px;
  top: 9px;
  left: 3px;
}

.faq-icon::after {
  width: 2px;
  height: 14px;
  top: 3px;
  left: 9px;
}

.faq-item.active .faq-icon::after {
  transform: scaleY(0);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.faq-item.active .faq-answer {
  max-height: 400px;
}

.faq-answer p {
  padding: 0 20px 18px;
  font-size: 0.92rem;
  color: var(--text-body);
  border-top: 1px solid var(--border);
  padding-top: 14px;
  margin: 0;
}

/* 表单 */
.contact-form {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: var(--font);
  background-color: var(--bg-light);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  min-height: 44px;
}

.form-control:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(0, 188, 212, 0.12);
  background-color: var(--white);
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.form-submit {
  margin-top: 8px;
}

.form-success {
  display: none;
  background-color: rgba(0, 188, 212, 0.06);
  border: 1px solid var(--cyan);
  color: var(--cyan-dark);
  padding: 16px;
  border-radius: var(--radius);
  font-size: 0.92rem;
  margin-top: 16px;
}

.form-success.visible {
  display: block;
}

/* 标签 */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-block;
  background-color: rgba(0, 188, 212, 0.08);
  color: var(--cyan-dark);
  font-size: 0.8rem;
  padding: 4px 12px;
  border-radius: 4px;
  border: 1px solid rgba(0, 188, 212, 0.15);
}

/* 表格 */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.data-table th,
.data-table td {
  padding: 14px 16px;
  text-align: left;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  background-color: var(--navy);
  color: var(--white);
  font-weight: 500;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background-color: rgba(0, 188, 212, 0.03);
}

/* ============================================================
   pages —— 首页与内页特有样式
   ============================================================ */
/* 首页首屏 */
.hero-section {
  background-color: var(--navy);
  background-image: url('/assets/media/hero.webp');
  background-size: cover;
  background-position: center;
  padding: 96px 0;
  position: relative;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(26, 42, 58, 0.82);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 640px;
}

.hero-content h1 {
  color: var(--white);
  font-size: 2.4rem;
  margin-bottom: 16px;
}

.hero-content p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.05rem;
  margin-bottom: 28px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* 区块标题 */
.section-head {
  margin-bottom: 32px;
  max-width: 720px;
}

.section-head h2 {
  margin-bottom: 8px;
}

.section-head p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* 首页各区块背景 */
.section-alt {
  background-color: var(--bg-light);
}

/* 内页通用 */
.page-title {
  font-size: 1.8rem;
  margin-bottom: 8px;
}

.page-intro {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.content-block {
  margin-bottom: 40px;
}

.content-block:last-child {
  margin-bottom: 0;
}

/* 关于页 */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
}

.about-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

.about-text h2 {
  margin-bottom: 12px;
}

/* 文章列表 */
.article-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.article-item {
  display: flex;
  gap: 20px;
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  transition: box-shadow 0.25s ease;
}

.article-item:hover {
  box-shadow: var(--shadow-md);
}

.article-thumb {
  width: 160px;
  flex-shrink: 0;
}

.article-thumb img {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: 6px;
}

.article-info h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.article-info h3 a {
  color: var(--navy);
}

.article-info h3 a:hover {
  color: var(--cyan-dark);
}

.article-meta {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.article-excerpt {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* 联系页 */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 32px;
}

.contact-info-card {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

.contact-info-item {
  display: flex;
  gap: 14px;
  margin-bottom: 20px;
}

.contact-info-item:last-child {
  margin-bottom: 0;
}

.contact-info-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  background-color: rgba(0, 188, 212, 0.08);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan-dark);
}

.contact-info-item h3 {
  font-size: 0.95rem;
  margin-bottom: 2px;
}

.contact-info-item p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* 服务详情页 */
.service-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.detail-item {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.detail-item h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1rem;
  margin-bottom: 10px;
}

.detail-item p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* ============================================================
   responsive —— 响应式适配
   ============================================================ */
@media (max-width: 1024px) {
  .service-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps-wrap {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .page-layout {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
  }

  .sidebar-nav {
    position: static;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 12px;
  }

  .sidebar-nav li a {
    padding: 8px 14px;
    border-left: none;
    border-bottom: 2px solid transparent;
    font-size: 0.88rem;
  }

  .sidebar-nav li a:hover,
  .sidebar-nav li a.active {
    border-left: none;
    border-bottom-color: var(--cyan);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }

  .section-padding {
    padding: 48px 0;
  }

  .header-inner {
    height: 56px;
  }

  .main-nav {
    position: fixed;
    top: 56px;
    left: 0;
    right: 0;
    background-color: var(--navy);
    flex-direction: column;
    align-items: flex-start;
    padding: 16px 24px 24px;
    gap: 4px;
    transform: translateY(-120%);
    transition: transform 0.3s ease;
    box-shadow: var(--shadow-lg);
  }

  .main-nav.open {
    transform: translateY(0);
  }

  .main-nav a {
    display: block;
    padding: 12px 0;
    font-size: 1rem;
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .main-nav a::after {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .hero-section {
    padding: 72px 0;
  }

  .hero-content h1 {
    font-size: 1.8rem;
  }

  .hero-content p {
    font-size: 0.95rem;
  }

  .service-grid,
  .case-grid,
  .advantage-list,
  .service-detail-grid {
    grid-template-columns: 1fr;
  }

  .steps-wrap {
    grid-template-columns: 1fr;
  }

  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .article-item {
    flex-direction: column;
  }

  .article-thumb,
  .article-thumb img {
    width: 100%;
  }

  .article-thumb img {
    height: 180px;
  }

  .section-head h2 {
    font-size: 1.35rem;
  }

  .page-title {
    font-size: 1.5rem;
  }

  .contact-form {
    padding: 24px 20px;
  }

  .data-table {
    display: block;
    overflow-x: auto;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 15px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .case-stats {
    flex-wrap: wrap;
    gap: 12px;
  }

  .step-item {
    padding: 20px 12px;
  }

  .advantage-item {
    flex-direction: column;
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* responsive guard */
html, body { max-width: 100%; overflow-x: hidden; }
img, video, canvas, svg { max-width: 100%; height: auto; }
* { min-width: 0; }
@media (max-width: 480px) {
  table { display: block; max-width: 100%; overflow-x: auto; }
}
