/* ===== 变量与基础 ===== */
:root {
  --color-bg: #faf9f7;
  --color-bg-alt: #f0ede8;
  --color-primary: #1e3a5f;
  --color-primary-light: #2d4a6f;
  --color-accent: #c9a227;
  --color-accent-soft: #e8d9a3;
  --color-text: #2c2c2c;
  --color-text-muted: #5c5c5c;
  --font-serif: 'Noto Serif SC', serif;
  --font-sans: 'Noto Sans SC', sans-serif;
  --shadow: 0 4px 24px rgba(30, 58, 95, 0.08);
  --radius: 12px;
  --header-height: 72px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.75;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s;
}
a:hover {
  color: var(--color-accent);
}

/* ===== 导航 ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-height);
  background: rgba(250, 249, 247, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(30, 58, 95, 0.06);
  transition: background 0.3s, box-shadow 0.3s;
}
.header.scrolled {
  box-shadow: var(--shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-primary);
  letter-spacing: 0.02em;
}
.logo-img {
  max-height: 48px;
  width: auto;
  display: block;
}

.nav {
  display: flex;
  gap: 32px;
}
.nav a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-text-muted);
}
.nav a:hover {
  color: var(--color-primary);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 1px;
}

/* ===== 首屏 ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--header-height);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(30, 58, 95, 0.85) 0%, rgba(45, 74, 111, 0.8) 50%, rgba(30, 58, 95, 0.9) 100%),
              url('https://trae-api-cn.mchost.guru/api/ide/v1/text_to_image?prompt=modern%20university%20campus%20scene%2C%20academic%20environment%2C%20students%20and%20professors%2C%20blurred%20background%20for%20website%20hero%20section&image_size=landscape_16_9');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.hero-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.6;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: #fff;
}

.hero-subtitle {
  font-size: 0.9rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.9;
  margin-bottom: 12px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 16px;
  letter-spacing: 0.02em;
}

.hero-desc {
  font-size: 1.05rem;
  opacity: 0.9;
  max-width: 480px;
  margin: 0 auto 32px;
}

.btn {
  display: inline-block;
  padding: 14px 32px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 8px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-primary {
  background: var(--color-accent);
  color: #1e3a5f;
  border: none;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(201, 162, 39, 0.35);
}

.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.8);
  font-size: 0.8rem;
}

.scroll-arrow {
  width: 24px;
  height: 24px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: rotate(45deg) translateY(0); }
  50% { transform: rotate(45deg) translateY(6px); }
}

/* ===== 通用区块 ===== */
.section {
  padding: 80px 0;
}
.section:nth-child(even) {
  background: var(--color-bg-alt);
}

.section-title {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-primary);
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: 0.02em;
}

/* ===== 公司简介 ===== */
.about-content {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 40px;
}

.about-img-container {
  flex: 0 0 320px;
}

.about-img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.about-text {
  flex: 1;
}

.about-text p {
  margin-bottom: 1.25em;
  color: var(--color-text-muted);
}

.about-text p:last-child {
  margin-bottom: 0;
}

.about-text strong {
  color: var(--color-primary);
  font-weight: 600;
}

/* ===== 业务介绍 ===== */
.business-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.business-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(30, 58, 95, 0.06);
  transition: transform 0.25s, box-shadow 0.25s;
}
.business-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(30, 58, 95, 0.12);
}

.business-card-wide {
  grid-column: 1 / -1;
}

.card-icon {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-accent-soft);
  line-height: 1;
  margin-bottom: 12px;
}

.card-img-container {
  margin-bottom: 16px;
  border-radius: 8px;
  overflow: hidden;
}

.card-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.3s;
}

.business-card:hover .card-img {
  transform: scale(1.02);
}

.business-card h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 16px;
}

.business-card ul {
  list-style: none;
}
.business-card li {
  position: relative;
  padding-left: 1em;
  margin-bottom: 8px;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}
.business-card li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-weight: bold;
}

/* ===== 特色服务 ===== */
.features-list {
  max-width: 720px;
  margin: 0 auto;
}

.feature-item {
  display: flex;
  gap: 24px;
  padding: 24px 0;
  border-bottom: 1px solid rgba(30, 58, 95, 0.08);
  align-items: flex-start;
}
.feature-item:last-child {
  border-bottom: none;
}

.feature-num {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border-radius: 50%;
  margin-top: 8px;
}

.feature-img-container {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  margin-right: 16px;
}

.feature-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.feature-text {
  flex: 1;
}

.feature-text h4 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.feature-text p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

/* ===== 服务理念 ===== */
.philosophy-content {
  max-width: 840px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 40px;
}

.philosophy-img-container {
  flex: 0 0 280px;
}

.philosophy-img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.philosophy-text {
  flex: 1;
  text-align: left;
}

.philosophy-text p {
  margin-bottom: 1.25em;
  color: var(--color-text-muted);
}

.philosophy-text strong {
  color: var(--color-primary);
}

.philosophy-cta {
  font-weight: 500;
  color: var(--color-primary) !important;
  margin-top: 1.5em;
}

/* ===== 联系我们 ===== */
.contact-card {
  max-width: 560px;
  margin: 0 auto;
  background: #fff;
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(30, 58, 95, 0.06);
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 24px;
}

.contact-item {
  display: flex;
  align-items: baseline;
  gap: 16px;
}
.contact-label {
  flex-shrink: 0;
  width: 56px;
  font-weight: 600;
  color: var(--color-primary);
}
.contact-item a {
  font-size: 1.05rem;
}

.contact-tagline {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid rgba(30, 58, 95, 0.08);
}

/* ===== 页脚 ===== */
.footer {
  padding: 24px 0;
  background: var(--color-primary); /* 深蓝色背景 */
  color: #ffffff !important; /* 强制设为白色 */
  text-align: center;
  font-size: 0.9rem;
}

/* 页脚备案号链接样式 - 增强优先级 */
.footer > .container > p > a {
  color: #ffffff !important; /* 强制白色，覆盖全局样式 */
  text-decoration: none; /* 移除下划线 */
  display: inline-block; /* 确保点击区域正常 */
}

/* 可选：鼠标悬停效果 */
.footer > .container > p > a:hover {
  color: #f0f0f0 !important; /* 悬停时浅白色 */
  text-decoration: underline; /* 悬停显示下划线 */
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
  .business-grid {
    grid-template-columns: 1fr;
  }
  .business-card-wide {
    grid-column: 1;
  }
}

@media (max-width: 768px) {
  .nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 24px;
    background: rgba(250, 249, 247, 0.98);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(30, 58, 95, 0.08);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s, opacity 0.3s, visibility 0.3s;
  }
  .nav.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav a {
    padding: 12px 0;
    border-bottom: 1px solid rgba(30, 58, 95, 0.06);
  }
  .nav a:last-child {
    border-bottom: none;
  }

  .nav-toggle {
    display: flex;
  }
  .nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }
  .nav-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  .nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }
  .nav-toggle span {
    transition: transform 0.3s, opacity 0.3s;
  }

  .section {
    padding: 56px 0;
  }
  .section-title {
    margin-bottom: 32px;
    font-size: 1.5rem;
  }
  .hero-title {
    font-size: 1.5rem;
  }
  .about-content {
    flex-direction: column;
    text-align: center;
  }
  .about-img-container {
    flex: 0 0 100%;
    max-width: 320px;
    margin: 0 auto;
  }
  .feature-item {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
  .feature-img-container {
    margin: 0 auto 12px;
  }
  .feature-num {
    margin: 0 auto 12px;
  }
  .philosophy-content {
    flex-direction: column;
    text-align: center;
  }
  .philosophy-img-container {
    flex: 0 0 100%;
    max-width: 280px;
    margin: 0 auto;
  }
  .philosophy-text {
    text-align: center;
  }
  .business-card {
    padding: 20px;
  }
  .card-img-container {
    margin-bottom: 12px;
  }
  .contact-card {
    padding: 28px 20px;
  }
  .contact-item {
    flex-direction: column;
    gap: 4px;
  }
}
