/* ==========================================
   基础变量与全局样式
   ========================================== */
:root {
  --primary: #f8f9fa;
  --secondary: rgb(233, 236, 239);
  --accent: #64b5f6;
  --accent-dark: #40a9ff;
  --text: #333333;
  --text-light: #6c757d;
  --card-bg: #ffffff;
  --shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  --transition: all 0.3s ease;
}

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

body {
  font-family: "Montserrat", sans-serif;
  color: var(--text);
  line-height: 1.6;
  background-color: var(--primary);
  min-height: 100vh;
  transition: var(--transition);
}

/* ==========================================
   布局结构样式
   ========================================== */
.container {
  display: flex;
  min-height: 100vh;
}

/* 侧边栏导航 */
.sidebar {
  width: 300px;
  background-color: var(--card-bg);
  padding: 2.5rem 1.5rem;
  border-right: 1px solid var(--secondary);
  position: fixed;
  height: 100vh;
  z-index: 100;
  transition: var(--transition);
}

.logo {
  font-family: "Playfair Display", serif;
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--accent);
  margin-bottom: 2.5rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.logo img {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
}

.logo i {
  font-size: 1.8rem;
}

.nav-list {
  list-style: none;
}

.nav-list li {
  margin-bottom: 1.2rem;
}

.nav-list a {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  padding: 0.8rem 1rem;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
}

.nav-list a:hover {
  color: var(--accent);
  background-color: rgba(100, 181, 246, 0.08);
}

.nav-list a.active {
  color: var(--accent);
  background-color: rgba(100, 181, 246, 0.1);
}

.nav-list a.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 4px;
  background: var(--accent);
  border-radius: 2px;
}

.social-links {
  display: flex;
  gap: 1.2rem;
  margin-top: 2.5rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: var(--secondary);
  border-radius: 50%;
  color: var(--text-light);
  transition: var(--transition);
  font-size: 1.1rem;
}

.social-links a:hover {
  background-color: var(--accent);
  color: white;
  transform: translateY(-3px);
}

/* 主内容区 */
.main-content {
  flex: 1;
  margin-left: 300px;
  padding: 2.5rem;
  overflow-y: auto;
}

/* ==========================================
   页面组件样式
   ========================================== */
/* 头部区域 */
.header {
  margin-bottom: 3.5rem;
}

.header h1 {
  font-family: "Playfair Display", serif;
  font-size: 3.2rem;
  margin-bottom: 1.2rem;
  color: var(--accent);
  line-height: 1.2;
}

.header p {
  font-size: 1.3rem;
  max-width: 700px;
  color: var(--text-light);
  margin-bottom: 2.5rem;
}

/* 章节标题 */
section {
  margin-bottom: 4.5rem;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.section-title h2 {
  font-family: "Playfair Display", serif;
  font-size: 2.2rem;
  color: var(--accent);
  position: relative;
  padding-left: 1rem;
}

.section-title h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 32px;
  width: 4px;
  background: var(--accent);
  border-radius: 2px;
}

/* 旅行卡片与轮播 */
.travel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.8rem;
}

.travel-card {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  height: 320px;
  cursor: pointer;
}

.travel-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.travel-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.travel-card:hover .travel-img {
  transform: scale(1.05);
}

.travel-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.5rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent);
  color: white;
  transform: translateY(100%);
  transition: var(--transition);
  opacity: 0;
}

.travel-card:hover .travel-info {
  transform: translateY(0);
  opacity: 1;
}
.travel-info-active {
  transform: translateY(0) !important;
  opacity: 1 !important;
}
.travel-info h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.travel-info p {
  font-size: 0.95rem;
  opacity: 0.9;
}

/* 3D轮播核心样式 */

/* 关于我们 */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: center;
}

.about-img {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  height: 500px;
  position: relative;
}

.about-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.about-img:hover img {
  transform: scale(1.04);
}

.about-text h2 {
  font-family: "Playfair Display", serif;
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: var(--accent);
}

.about-text p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  line-height: 1.7;
}

.about-text .highlight {
  color: var(--accent);
  font-weight: 600;
}

/* 统计卡片 */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
  margin-top: 2.5rem;
}

.stat-card {
  background-color: var(--card-bg);
  border-radius: 10px;
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.stat-number {
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.8rem;
}

.stat-label {
  font-size: 1.1rem;
  color: var(--text-light);
  font-weight: 500;
}

/* 页脚 */
footer {
  text-align: center;
  padding: 2.5rem 0;
  color: var(--text-light);
  font-size: 0.95rem;
  border-top: 1px solid var(--secondary);
}

/* 移动端菜单按钮 */
.menu-toggle {
  background-color: rgba(255, 255, 255, 0.5);
  display: none;
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 8px;
  box-shadow: var(--shadow);
  color: var(--accent);
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 999;
  align-items: center;
  justify-content: center;
}

/* ==========================================
   响应式样式（按屏幕尺寸从大到小）
   ========================================== */
@media (max-width: 1200px) {
  .about-content {
    grid-template-columns: 1fr;
  }

  .about-img {
    height: 450px;
  }
}

@media (max-width: 992px) {
  .travel-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 2fr));
  }

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

@media (max-width: 768px) {
  html {
    font-size: 14px;
  }
  /* 移动端样式 */
  .about-text:nth-child(2n) h2 {
    font-size: 1.5rem;
    text-align: center;
  }
  /* 基础布局调整 */
  .sidebar {
    width: 98vw;
    transform: translateX(-100%); /* 默认隐藏侧边栏 */
    z-index: 998;
  }

  .sidebar.active {
    transform: translateX(0); /* 激活时显示 */
  }

  .main-content {
    margin-left: 0;
    padding: 1.5rem;
  }
  .menu-toggle {
    display: flex; /* 显示菜单按钮 */
  }

  /* 文字样式调整 */
  .header h1 {
    font-size: 2.2rem;
    margin-top: 2rem;
  }

  .section-title h2 {
    font-size: 1.8rem;
  }

  .about-text h2 {
    font-size: 2.2rem;
  }

  /* 布局调整 */
  .stats {
    grid-template-columns: 1fr;
  }

  .about-content {
    gap: 2rem;
  }

  .about-img {
    height: 320px;
  }
  .no-scroll {
    overflow: hidden;
    height: 100vh;
    position: fixed;
    width: 100%;
  }

  /* 旅行区域改为轮播 */
  .travel-grid {
    display: block;
    overflow: hidden;
    position: relative;
    border-radius: 12px;
  }

  .travel-card {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
  }
  .travel-card:hover {
    transform: translateY(0);
  }
  /* 轮播样式 */
  .carousel-counter {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 4px 10px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  }
  /* 底部分页指示器样式 */
  .swiper-pagination {
    bottom: 0px !important;
  }

  /* 默认灰色圆点 */
  .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.6) !important; /* 灰色圆点 */
    opacity: 1 !important;
    transition: all 0.3s ease;
  }

  /* 选中状态为指定蓝色 */
  .swiper-pagination-bullet-active {
    width: 24px;
    border-radius: 4px !important;
    background: #64b5f6 !important; /* 指定的选中颜色 */
  }
}
