/*
Theme Name:  Theme
Text Domain:  main-themes
*/

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

body {
  margin: 0px auto;
  /* 宽度保持不变 */
  /*font-family: "Microsoft YaHei", sans-serif;*/
  font-family: "MyCustomFont", sans-serif;
  color: #333;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}
.content {
  margin: 0px auto;
  max-width: 1200px;
  /* 宽度保持不变 */
  /*font-family: "Microsoft YaHei", sans-serif;*/
  font-family: "MyCustomFont", sans-serif;
  color: #333;
  /*box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);*/
}
a {
  text-decoration: none;
  color: #333;
}

/* ========== 顶部横幅 ========== */
.top-banner {
  width: 100%;
  background-image: url("./res/img/head_bg.png");
  background-size: cover;
  background-position: center;
  padding: 15px 20px; /* 上下留白，左右适配 */
  box-sizing: border-box;
}

/* 容器：使用 Flex 布局 */
.head_place {
  display: flex;
  justify-content: space-between; /* 桌面端：Logo 左，语言右 */
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  flex-wrap: wrap; /* 允许换行 */
}

/* Logo 样式 */
.logo img {
  height: 80px; /* 桌面适中高度 */
  transition: height 0.3s ease;
}

/* 语言切换样式 */
.lang-switcher {
  text-align: right;
}

.lang-switcher a {
  font-size: 14px;
  text-decoration: none;
  margin: 0 5px;
}

.lang-switcher a:hover {
  text-decoration: underline;
}

.lang-switcher .active {
  font-weight: bold;
  pointer-events: none;
  cursor: default;
}

/* ========== 桌面端：正常显示水平导航 ========== */
@media (min-width: 769px) {
  .desktop-menu {
    display: flex;
  }

  .menu-toggle {
    display: none;
  }

  .mobile-sidebar,
  .sidebar-overlay {
    display: none !important;
  }
}

.nav {
  background: #e6492d;
  background-image: url("./res/img/nav_bg.png");
  background-size: cover;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  position: relative;
}

.nav ul {
  list-style-type: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.nav li {
  padding: 10px 20px;
}

.nav li a {
  color: #fff;
  font-size: 26px;
  white-space: nowrap;
}

/* ========== 汉堡菜单按钮 ========== */
.menu-toggle {
  display: none; /* 默认隐藏 */
  flex-direction: column;
  cursor: pointer;
  width: 40px;
  height: 40px;
  justify-content: space-around;
  margin-left: auto;
  margin-right: 20px;
}

.menu-toggle span {
  width: 100%;
  height: 4px;
  background: #fff;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* 幻灯片容器 - 调整高度 */
.slideshow-section {
  margin: 5px 0px 0px 0px;
  /*max-width: 1200px;*/
  /* 宽度保持不变 */
  padding: 0;
}

.slideshow-container {
  position: relative;
  margin: auto;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  /* 设置固定高度，并隐藏溢出内容 */
  /*height: 414px;*/
  /* 假设原始高度约为600px，减半为300px */
  overflow: hidden;
}

.slide {
  display: none;
  /* 保持图片宽度100%，但允许高度自动调整并在容器内裁剪 */
}

.slide img {
  width: 100%;
  /* 高度自动调整，保持宽高比 */
  height: auto;
  /* 关键：确保图片在容器内垂直居中显示，如果图片高度超过容器，则裁剪上下 */
  display: block;
  /* 使用 object-fit 可以更精确地控制图片显示 */
  object-fit: cover;
  /* 覆盖模式，裁剪以填充容器 */
  /* object-position 可以调整图片在容器内的焦点，默认是 center */
  /* object-position: center top; */
  /* 例如，优先显示图片顶部 */
}

.slide-text {
  color: #ffffff;
  font-size: 20px;
  padding: 12px 24px;
  position: absolute;
  bottom: 0;
  width: 100%;
  text-align: left;
  background-color: rgba(0, 0, 0, 0.5);
}

.dot-container {
  text-align: center;
  padding: 10px 0px 10px 0px;
  background-color: #f6f6f6;
  /* 与页面背景一致 */
}

.dot {
  cursor: pointer;
  height: 15px;
  width: 15px;
  margin: 0 2px;
  background-color: #bbb;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.3s ease;
}

.active,
.dot:hover {
  background-color: #ffa500;
  /* 点的颜色与导航栏呼应 */
}

.fade {
  animation-name: fade;
  animation-duration: 1.5s;
}

@keyframes fade {
  from {
    opacity: 0.4;
  }

  to {
    opacity: 1;
  }
}

.prev,
.next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  width: auto;
  padding: 16px;
  margin-top: -22px;
  color: white;
  font-weight: bold;
  font-size: 18px;
  transition: 0.3s ease;
  border-radius: 0 3px 3px 0;
  user-select: none;
  background-color: rgba(0, 0, 0, 0.3);
}

.next {
  right: 0;
  border-radius: 3px 0 0 3px;
}

.prev:hover,
.next:hover {
  background-color: rgba(0, 0, 0, 0.8);
}

/* 底部信息 */
.footer {
  background-image: url("./res/img/foot_bg2.png");
  width: 100%;
  height: 200px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  padding-left: 0;

  /* 可选：让 img 居中 */
  display: flex;
  justify-content: left;
  align-items: left;
  box-sizing: border-box;
}

/* 重置与基础样式 */
.site-footer {
  background-color: #f8f8f8; /* 可选：添加背景色 */
}

/* Logo 区域 */
.footer-image-dev {
  flex: 0 0 auto;
  margin-top: 20px;
  margin-left: 20px;
}

.footer-image-dev img {
  height: 150px; /* 增加高度 */
  width: auto;
  max-width: 300px; /* 增加最大宽度 */
}

/* 联系方式区域 */
.footer-contact {
  flex: 1;
  min-width: 300px; /* 小屏时最小宽度 */
  margin-left: 30px;
}

.footer-contact p {
  font-size: 20px;
  margin-bottom: 10px;
  color: #333;
  line-height: 1.6;
}

.footer-contact p:last-child {
  margin-bottom: 0;
}

.footer_div {
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  background-image: url("./res/img/nav_bg.png");
  background-size: cover;
  text-align: center;
  padding: 20px 20px 20px 20px;
  margin-bottom: 50px;
}

.page-header {
  /* text-align: center;*/
  width: 100%;
  margin: 20px 0;
}

.page-header h1 {
  font-size: 28px;
  color: #2c3e50;
  margin: 0;
  padding: 0;
  display: inline-block; /* 可选：避免默认 margin 扩散 */
}

.logo {
  padding-top: 20px;
  padding-bottom: 20px;
}
.logo img {
  width: 350px;
  height: auto;
  object-fit: contain; /* 保持比例，填满区域 */
  display: block;
}

/* 响应式：小屏幕（手机）变为上下布局 */
@media (max-width: 768px) {
  .head_place {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px; /* Logo 和语言之间留空 */
  }

  .logo img {
    height: 60px; /* 更小的 Logo */
    margin-left: 0 !important; /* 覆盖旧样式 */
  }

  .lang-switcher {
    order: 2; /* 确保在 Logo 下方（可选） */
  }

  .lang-switcher a {
    font-size: 13px;
    margin: 0 4px;
  }

  .desktop-menu {
    display: none !important;
  }

  .menu-toggle {
    display: flex;
  }

  .mobile-sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100%;
    background: #e6492d;
    background-image: url("./res/img/nav_bg.png");
    background-size: cover;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: right 0.3s ease;
    padding-top: 60px;
    overflow-y: auto;
  }

  .mobile-sidebar.active {
    right: 0;
  }

  .sidebar-header {
    padding: 10px 20px;
    text-align: right;
  }

  .close-btn {
    font-size: 30px;
    color: #fff;
    cursor: pointer;
  }

  .sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
  }

  .sidebar-menu li {
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .sidebar-menu a {
    color: #fff;
    font-size: 18px;
    text-decoration: none;
    display: block;
  }

  .sidebar-menu a:hover {
    color: #ffa500;
  }

  /* 遮罩层 */
  .sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
  }

  .sidebar-overlay.active {
    display: block;
  }

.slideshow-container {
  position: relative;
  margin: auto;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  /* 设置固定高度，并隐藏溢出内容 */
  height: 200px;
  /* 假设原始高度约为600px，减半为300px */
  overflow: hidden;
}

  .footer-contact {
    margin-left: 0;
    text-align: center;
    min-width: auto;
  }

  .footer-contact p {
    font-size: 16px; /* 小一点更合适 */
    margin-bottom: 8px;
    text-align: center;
  }

  /* 版权区域：保持居中，调整间距 */
  .footer_div {
    padding: 15px 10px;
    margin-bottom: 30px;
  }

  .footer_div p {
    font-size: 14px;
  }

  .footer_div a {
    font-size: 14px;
    display: block;
    margin-top: 6px;
  }
}
