/* ========== 全局样式重置与基础配置 ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  background: #F6FAFF;
  color: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  padding-top: 120px;
  scroll-behavior: smooth;
}

/* ========== 头部导航样式 ========== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  z-index: 999;
  padding: 15px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.header-inner {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px;
}

.logo-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  margin-bottom: 10px;
  width: 100%;
}

.top-logo {
  width: 80px;
  height: 48px;
  object-fit: contain;
}

.logo {
  color: #000;
  font-size: 18px;
  font-weight: bold;
  text-decoration: none;
  cursor: default;
  user-select: none;
  font-size: 18px;
  margin: 0;
}

a.logo { display: none; }

/* 导航菜单 */
.nav {
  display: flex;
  gap: 2px;
  justify-content: center;
  width: 100%;
}

.nav-tab {
  color: #000;
  text-decoration: none;
  cursor: pointer;
  padding: 8px 20px;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-size: 14px;
}

.nav-tab.active {
  background: #3498db;
  color: #fff;
}

.nav-tab:hover:not(.active) { 
  background: rgba(255,255,255,0.1); 
}

/* ========== 核心内容区 ========== */
.anchor-container {
  width: 100%;
  max-width: 1400px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.section-content {
  width: 100%;
  max-width: 1000px;
  padding: 20px;
  border-radius: 8px;
  line-height: 2;
  font-size: 16px;
  scroll-margin-top: 140px;
  margin: 20px auto 0;
}

/* ========== 轮播图样式 ========== */
.carousel {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9比例 */
  height: auto;
  margin: 0 auto 20px;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.carousel-slides {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.carousel-slide {
  width: 100%;
  height: 100%;
  display: none;
}

.carousel-slide.active { 
  display: block; 
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: fill;
}


/* 轮播按钮 */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.7);
  border: none;
  border-radius: 50%;
  font-size: 20px;
  color: #333;
  cursor: pointer;
  z-index: 10;
  transition: background 0.3s ease;
  -webkit-transition: background 0.3s ease; /* 兼容webkit内核 */
}

.carousel-btn.prev { left: 10px; }
.carousel-btn.next { right: 10px; }

.carousel-btn:hover { 
  background: rgba(255,255,255,0.9); 
}

/* 轮播指示器 */
.carousel-indicators {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: background 0.3s ease;
  -webkit-transition: background 0.3s ease;
}

.indicator.active { 
  background: #fff; 
}

/* ========== 关于我们区域 ========== */
#about {
  width: 100%;
}

.about-container {
  display: flex;
  flex-wrap: wrap;
  gap: 100px;
  align-items: center;
  width: 100%;
}

.about-text {
  flex: 1;
  min-width: 300px;
  text-align: left;
}

.about-text h2 { 
  margin-bottom: -20px; 
}

.about-text h4 { 
  margin-bottom: 40px; 
}

.about-img {
  flex: 0 0 300px;
  text-align: center;
  display: flex;
  justify-content: flex-end;
}

.about-img img {
  width: 100%;
  height: auto;
  max-width: 300px;
  display: block;
}

.about-tip {
  font-size: 12px; 
  color: #666; 
  margin-top: 20px; 
  line-height: 1.5;
  width: 100%;
}

/* ========== 马术服务样式 ========== */
.service-layout {
  display: flex;
  gap: 20px;
  margin: 20px 0;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: flex-start;
}

.service-btn-col {
  flex: 1 0 100%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 0 0 20px 0;
  padding: 0;
}

.service-btn {
  padding: 12px 15px;
  background: #ffffff;
  border: none;
  border-radius: 4px;
  color: #000;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  font-weight: bold;
  margin: 0;
  line-height: 2.5;
  -webkit-transition: all 0.3s ease;
}

.service-btn.active {
  background: #3498db;
  color: #fff;
}

.service-btn:hover:not(.active) { 
  background: #f8fbff; 
}

.service-detail-col {
  flex: 1;
  min-width: 300px;
  padding: 0 40px;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.detail-item {
  display: none;
  margin: 0;
  padding: 0;
}

.detail-item.active { 
  display: block; 
}

.detail-item h3 {
  color: #05204C;
  margin: 0 0 10px 0;
  padding: 0;
  line-height: 1.2;
  font-size: 14px;
}

.detail-item p {
  line-height: 1.8;
  color: #333;
  margin: 0 0 10px 0;
  padding: 0;
}

/* ========== 企业信息栏 ========== */
.company-info {
  width: 100vw;           
  max-width: 100%;        
  background: #05204C;
  padding: 40px 0;
  margin-top: 30px;
}

.company-info-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
}

.info-text {
  color: #fff;
  font-size: 16px;
  margin: 5px 0;
  line-height: 1.3;
}

.info-qrcode {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.qrcode-img {
  width: 120px;
  height: 120px;
  border: 4px solid #fff;
  border-radius: 8px;
}

.qrcode-desc {
  color: #fff;
  font-size: 14px;
  margin: 0;
  text-align: center;
}

/* ========== ICP备案栏 ========== */
.icp-footer {
  width: 100%;
  background: #ffffff;
  padding: 15px 0;
  margin-top: 0;
  text-align: center;
  font-size: 14px;
  color: #666;
}

.icp-footer a {
  text-decoration: none;
  color: #666;
  display: inline !important;
  margin-top: 0 !important;
}

.icp-footer a:hover { 
  text-decoration: underline;
  color: #3498db;
}

/* ========== 响应式适配 ========== */
/* 移动端 (<=768px) */
@media (max-width: 768px) {
  /* 头部导航 */
  .header { 
    padding: 10px 0; 
  }
  
  .header-inner {
    flex-direction: column;
    gap: 8px;
  }
  
  .logo-container {
    flex-direction: row;
    justify-content: center;
    gap: 10px;
    margin-bottom: 8px;
  }
  
  .top-logo {
    width: 70px;
    height: 42px;
  }
  
  .logo { 
    font-size: 16px; 
  }
  
  .nav {
    justify-content: center;
    gap: 5px;
    width: 100%;
    font-weight: bold;
  }
  
  .nav-tab {
    padding: 6px 15px;
    font-size: 13px;
  }

  /* 轮播图 */
  .carousel-btn {
    width: 30px;
    height: 30px;
    font-size: 16px;
  }
  
  .indicator {
    width: 10px;
    height: 10px;
  }

  /* About区域 */
  .about-container {
    flex-direction: column;
    gap: 20px;
  }
  
  .about-img {
    flex: 1;
    width: 100%;
    justify-content: center;
  }
  
  .about-img img { 
    max-width: 100%; 
  }
  
  .about-text h2 {
    margin-bottom: 10px;
    font-size: 18px;
  }
  
  .about-text h4 {
    margin-bottom: 20px;
    font-size: 14px;
  }

  /* 马术服务 */
  .service-btn-col {
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
  }
  
  .service-btn {
    font-size: 13px;
    padding: 10px 8px;
    line-height: 2;
  }
  
  .service-detail-col {
    padding: 0 20px;
    width: 100%;
  }

  /* 企业信息 */
  .company-info-inner {
    flex-direction: column;
    gap: 20px;
    text-align: left;
    padding: 0 20px;
  }
  
  .info-text { 
    font-size: 14px; 
  }
  
  .qrcode-img {
    width: 100px;
    height: 100px;
  }

  /* 锚点区域 */
  .section-content {
    scroll-margin-top: 120px;
    padding: 15px;
  }

  /* ICP备案 */
  .icp-footer {
    padding: 15px 20px;
    text-align: center;
    line-height: 1.8;
  }
  
  .icp-footer .copyright-line,
  .icp-footer .icp-line {
    display: block;
  }
}

/* PC端 (>=769px) */
@media (min-width: 769px) {
  .header-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  
  .logo-container {
    margin-bottom: 0;
    justify-content: flex-start;
  }
  
  .nav { 
    justify-content: flex-end; 
  }
  
  .service-btn-col {
    flex: 0 0 220px;
    display: flex;
    flex-direction: column;
  }
  
  .mobile-br { 
    display: none; 
  }
  
  .pc-inline { 
    display: inline; 
  }
}