/* ============================================
   富县木启未来木业有限公司 — 网站样式
   ============================================ */

/* --- CSS Variables --- */
:root {
  --color-primary: #8B5E3C;
  --color-primary-dark: #6D4A2E;
  --color-secondary: #4A7C59;
  --color-accent: #D4A574;
  --color-text: #2D2D2D;
  --color-text-light: #666666;
  --color-bg: #FAF7F2;
  --color-white: #FFFFFF;
  --color-overlay: rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);
  --radius: 12px;
  --transition: 0.3s ease;
  --font-zh: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  --font-en: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 70px;
}

body {
  font-family: var(--font-zh);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

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

/* --- Fade-in Animation --- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   导航栏
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-img {
  height: 44px;
  width: auto;
}

.logo-text-group {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.logo-name {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: 4px;
}

.logo-name-en {
  font-size: 0.7rem;
  font-family: var(--font-en);
  color: var(--color-text-light);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-text-light);
  position: relative;
  padding: 4px 0;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.hamburger {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  position: relative;
  transition: background var(--transition);
}

.hamburger::before,
.hamburger::after {
  content: "";
  position: absolute;
  left: 0;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: transform var(--transition);
}

.hamburger::before {
  top: -7px;
}

.hamburger::after {
  top: 7px;
}

.nav-toggle.open .hamburger {
  background: transparent;
}

.nav-toggle.open .hamburger::before {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open .hamburger::after {
  transform: translateY(-7px) rotate(-45deg);
}

/* ============================================
   Hero 区域
   ============================================ */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Slide container */
.hero-slides {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1.5s ease;
}

.hero-slide.active {
  opacity: 1;
}

/* Hero overlay for readability */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(61, 43, 31, 0.55) 0%,
    rgba(45, 80, 22, 0.45) 50%,
    rgba(0, 0, 0, 0.55) 100%
  );
  z-index: 1;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: var(--color-white);
  padding: 0 20px;
  max-width: 800px;
}

.hero-title {
  font-size: clamp(1.8rem, 5vw, 3.2rem);
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.3;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  font-weight: 400;
  margin-bottom: 40px;
  opacity: 0.9;
  letter-spacing: 2px;
}

/* Slide dots */
.hero-slide-dots {
  position: absolute;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 12px;
  z-index: 3;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid rgba(255, 255, 255, 0.6);
}

.dot:hover {
  background: rgba(255, 255, 255, 0.7);
}

.dot.active {
  background: var(--color-accent);
  border-color: var(--color-accent);
  transform: scale(1.2);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}

.scroll-arrow {
  display: block;
  width: 24px;
  height: 24px;
  border-right: 2px solid rgba(255, 255, 255, 0.7);
  border-bottom: 2px solid rgba(255, 255, 255, 0.7);
  transform: rotate(45deg);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: rotate(45deg) translateY(0);
  }
  40% {
    transform: rotate(45deg) translateY(-10px);
  }
  60% {
    transform: rotate(45deg) translateY(-5px);
  }
}

/* ============================================
   按钮
   ============================================ */
.btn {
  display: inline-block;
  padding: 14px 36px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-white);
}

.btn-primary:hover {
  background: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(139, 94, 60, 0.4);
}

/* ============================================
   Section 通用
   ============================================ */
.section {
  padding: 100px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-title {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  color: var(--color-primary);
  margin-bottom: 16px;
}

.section-divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  margin: 0 auto 16px;
  border-radius: 2px;
}

.section-desc {
  color: var(--color-text-light);
  font-size: 1.05rem;
}

/* ============================================
   关于我们
   ============================================ */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.about-text p {
  margin-bottom: 16px;
  font-size: 1.05rem;
  line-height: 1.9;
}

.about-scope {
  background: var(--color-white);
  padding: 20px 24px;
  border-radius: var(--radius);
  border-left: 4px solid var(--color-secondary);
  box-shadow: var(--shadow-sm);
}

.about-images {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-image-main {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.about-image-main img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.about-image-main:hover img {
  transform: scale(1.03);
}

.about-image-sub {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.about-image-sub img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.about-image-sub:hover img {
  transform: scale(1.03);
}

.about-image-tag {
  background: var(--color-white);
  padding: 14px 20px;
  border-radius: var(--radius);
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-secondary);
  font-weight: 500;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--color-secondary);
}

.tag-icon {
  font-size: 1.1rem;
  margin-right: 6px;
}

/* ============================================
   业务领域
   ============================================ */
.services {
  background: var(--color-white);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.service-card {
  background: var(--color-bg);
  padding: 40px 28px;
  border-radius: var(--radius);
  text-align: center;
  transition: all var(--transition);
  border: 1px solid transparent;
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-accent);
}

.service-icon {
  font-size: 3rem;
  margin-bottom: 20px;
  display: block;
}

.service-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.service-desc {
  font-size: 0.95rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* ============================================
   联系我们
   ============================================ */
.contact-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.contact-item {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.contact-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-white);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.contact-detail h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.contact-detail p {
  font-size: 0.95rem;
  color: var(--color-text-light);
  line-height: 1.6;
}

.contact-detail a {
  color: var(--color-primary);
  font-weight: 500;
}

.contact-detail a:hover {
  color: var(--color-accent);
}

.contact-map {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.map-container {
  width: 100%;
  height: 400px;
}

/* ============================================
   页脚
   ============================================ */
.footer {
  background: var(--color-primary-dark);
  color: rgba(255, 255, 255, 0.85);
  padding: 50px 0 30px;
}

.footer-content {
  text-align: center;
}

.footer-brand {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 20px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 20px;
}

.footer-bottom p {
  font-size: 0.85rem;
  margin-bottom: 4px;
}

.footer-icp a {
  color: rgba(255, 255, 255, 0.6);
}

.footer-icp a:hover {
  color: var(--color-accent);
}

/* ============================================
   返回顶部
   ============================================ */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-white);
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition);
  box-shadow: var(--shadow-md);
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--color-accent);
  transform: translateY(-3px);
}

/* ============================================
   响应式设计
   ============================================ */

/* Tablet */
@media (max-width: 992px) {
  .about-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-images {
    order: -1;
    gap: 14px;
  }

  .about-image-main img {
    height: 220px;
  }

  .about-image-sub img {
    height: 150px;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .logo-name {
    font-size: 0.95rem;
    letter-spacing: 2px;
  }

  .logo-name-en {
    font-size: 0.6rem;
    letter-spacing: 0.5px;
  }

  .logo-img {
    height: 36px;
  }

  .section {
    padding: 70px 0;
  }

  .map-container {
    height: 300px;
  }

  .section-header {
    margin-bottom: 40px;
  }

  /* Mobile nav */
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--color-white);
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, box-shadow 0.3s ease;
    box-shadow: none;
  }

  .nav-links.open {
    max-height: 300px;
    box-shadow: var(--shadow-md);
  }

  .nav-link {
    display: block;
    padding: 16px 0;
    width: 100%;
    text-align: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  }

  .nav-link::after {
    display: none;
  }

  .services-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .service-card {
    padding: 30px 24px;
  }

  .about-image-main img {
    height: 200px;
  }

  .about-image-sub img {
    height: 140px;
  }

  .stat-card {
    padding: 20px 16px;
  }

  .hero-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
    font-size: 1.2rem;
  }
}

/* Small mobile */
@media (max-width: 480px) {
  .about-image-main img {
    height: 180px;
  }

  .footer-links {
    gap: 16px;
  }

  .hero-subtitle {
    letter-spacing: 1px;
  }
}
