/* 搜索弹窗 Overlay & 内容 */
.c-search-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  z-index: 999999;
  display: flex;
  justify-content: center;
  align-items: center;
}

.c-search-modal-content {
  position: relative;
  background: #fff;
  padding: 60px;
  border-radius: 1px;
  width: 90%;
  max-width: 900px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  animation: c-btn-anmation 0.3s ease-out;
}

.c-close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  background: none;
  border: none;
  color: #132169;
  font-size: 60px;
  cursor: pointer;
}

.c-search-form {
  display: flex;
  gap: 10px;
}

@keyframes c-btn-anmation {
  0% {
    transform: translateY(10px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

.c-search-input {
  flex: 1;
  padding: 17px 16px;
  border-radius: 5px;
  border: 1px solid #ececec;
  background: #ececec;
  color: #000;
  font-size: 16px;
  outline: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.c-search-input:focus {
  background: #fff;
  box-shadow: 0 0 10px 4px rgba(19, 33, 105, 0.15),
    0 4px 12px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.c-search-submit {
  padding: 17px 34px;
  background: #132169;
  color: #fff;
  border: none;
  border-radius: 5px;
  font-weight: bold;
  cursor: pointer;
}

.open-search-modal-btn {
  cursor: pointer !important;
}

/* 语言切换器与下拉层修复 */
.lang-switcher-wrapper {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
}

.lang-switcher-trigger {
  cursor: pointer !important;
  transition: transform 0.2s ease;
}

.lang-switcher-trigger:hover {
  transform: scale(1.1);
}

.custom-lang-panel {
  background-color: #ffffff !important;
  color: #132169 !important;
  padding: 15px !important;
  position: absolute !important;
  top: 100% !important; /* 修正：让面板完美贴合在图标正下方 */
  right: 0 !important;
  margin-top: 10px !important;
  z-index: 99999 !important;
  border-radius: 6px !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
  min-width: 180px !important;

  /* 初始隐藏状态 */
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transform: translateY(-10px) !important;

  /* 过渡动画 */
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease !important;
}

.custom-lang-panel.is-active {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
  transform: translateY(0) !important;
}

/* GTranslate 下拉样式纠正 */
#customLangPanel ul {
  list-style: none !important;
  list-style-type: none !important;
  margin: 0 !important;
  padding: 8px 0 !important;
}

#customLangPanel li,
#customLangPanel li.c-font-color {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}
#customLangPanel a,
#customLangPanel li a,
#customLangPanel li .glink,
#customLangPanel li.c-font-color a {
  color: #132169 !important;
  text-decoration: none !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px;
  padding: 8px 16px !important;
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s ease, color 0.2s ease;
}
#customLangPanel a:hover,
#customLangPanel li a:hover,
#customLangPanel li .glink:hover,
#customLangPanel li.c-font-color a:hover {
  background-color: #f5f5f5 !important;
  color: #000000 !important;
}

#customLangPanel li img {
  margin-right: 6px;
  vertical-align: middle;
  display: inline-block;
}

/* 1. 强制重置首个区块（Header）的顶部边距 */
body .wp-site-blocks > *:first-child,
body :where(.wp-site-blocks) > *:first-child,
header.wp-block-template-part,
.wp-block-group.has-background {
  margin-block-start: 0 !important;
  margin-top: 0 !important;
}

/* 2. 重置首个元素的顶部 blockGap 间距变量 */
body .wp-site-blocks > *:first-child {
  --wp--style--block-gap: 0 !important;
}

.custom-header-top-bar {
  display: block;
  width: 100%;
}

/* 1. Header 基础样式与过渡定义 */
.custom-header-style {
  transition: all 0.3s ease;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.3s ease;
  background-color: #132169;
}

/* 适配已登录 WordPress 管理员工具栏的偏移 */
body.admin-bar .custom-header-style {
  position: relative;
  height: 100px;
}

/* 2. 页面滚动后激活的样式（缩小高度） */
.custom-header-style.is-scrolled {
  transition: all 0.3s ease;
}

/* 3. （可选）滚动时同步缩小内部 Logo 大小 */
.custom-header-style img.custom-logo,
.custom-header-style .wp-block-site-logo img {
  transition: max-height 0.3s ease, width 0.3s ease, transform 0.3s ease;
  max-height: 100px;
}

.custom-header-style.is-scrolled {
  height: 90px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  transition: max-height 0.3s ease, width 0.3s ease;
  max-height: 70px;
}

.custom-header-style.is-scrolled .wp-block-site-logo img {
  filter: brightness(0) saturate(100%) invert(100%) sepia(100%) saturate(100%)
    hue-rotate(5deg);
  transition: filter 0.3s ease;
  /* transform: scale(0.8); */
  transform-origin: left top;
}

.custom-header-style .custom-memnu-main-style {
  width: 100%;
  display: flex;
  justify-content: space-between;
}

.custom-header-style.is-scrolled .custom-memnu-main-style {
  width: 100%;
}

/* 针对外层自动生成的 header 标签设置吸顶 */
header.wp-block-template-part {
  position: sticky !important;
  top: 32px !important;
  z-index: 10 !important;
  width: 100%;
}

.widget_product_categories a,
.wp-block-categories a,
ul.product-categories a {
  border-left: 3px solid transparent !important;
  border-radius: 0 !important;
}

/* 调整菜单样式 */
.wpb_category_n_menu_accordion .wpb_category_n_menu_accordion_list a {
  border-left: 3px solid #0e1952 !important;
  background-color: #fff !important;
  border-radius: 0 !important;
  transition: all 0.3s ease-in-out !important;
}

.wpb_category_n_menu_accordion .wpb_category_n_menu_accordion_list a:hover {
  background-color: #ececec !important;
  border-left: 3px solid #0e1952 !important;
}

.wpb_category_n_menu_accordion_list {
  display: flex !important;
  flex-direction: column !important;
  gap: 10px;
}
.wpb_category_n_menu_accordion_list .menu-item .sub-menu {
  margin-left: 0 !important;
  padding-inline-start: 0 !important;
}

.wpb_category_n_menu_accordion_list .menu-item .sub-menu .menu-item a {
  border-left: 3px solid #ececec !important;
}

.wpb_category_n_menu_accordion_list .menu-item .sub-menu .menu-item a:hover {
  border-left: 3px solid #12248b !important;
}

/* ==========================================================产品分类简码部份进行样式调整 ==========================================================*/
.woocommerce ul.products li.product-category {
  transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  overflow: hidden !important;
  background: #fff !important;
}

.woocommerce ul.products li.product-category:hover {
  transform: translateY(-5px) !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1) !important;
}

.woocommerce ul.products li.product-category img {
  transition: transform 0.5s ease !important;
  width: 100% !important;
  height: auto !important;
  margin: 0 auto !important;
}

.woocommerce ul.products li.product-category:hover img {
  transform: scale(1.08) !important;
}

.woocommerce ul.products li.product-category .woocommerce-loop-category__title {
  padding: 50px 15px 90px 15px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  text-align: center !important;
  color: #222 !important;
  position: relative !important;
  display: -webkit-box !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 2 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  height: 4em !important;
  box-sizing: border-box !important;
}

.woocommerce
  ul.products
  li.product-category
  .woocommerce-loop-category__title::after {
  content: "" !important;
  display: block !important;
  width: 50px !important;
  height: 2px !important;
  background-color: #0e1952 !important;
  position: absolute !important;
  bottom: 10px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
}

/* ================= 2. 邮件订阅表单样式 ================= */
.custom-newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 320px;
}

.custom-newsletter-form .form-label {
  font-size: 14px;
  color: #ffffff;
  font-weight: 500;
}

.custom-newsletter-form input[type="email"] {
  width: 100%;
  padding: 10px 14px;
  background-color: #fff;
  border: 1px solid #fff;
  border-radius: 4px;
  color: #333;
  font-size: 14px;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.custom-newsletter-form input[type="email"]:focus {
  border-color: #0073aa;
}

.custom-newsletter-form .custom-submit-btn {
  align-self: flex-start;
  padding: 12px 20px;
  background-color: #0e1952;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s, opacity 0.2s;
  color: #ffffff !important;
  white-space: nowrap !important;
}

.custom-newsletter-form .custom-submit-btn:hover {
  opacity: 0.9;
}

.custom-newsletter-form p {
  margin: 0;
  padding: 0;
  display: contents;
}

.custom-newsletter-row {
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
}

/* ================= 3. 关于我们 / 视差时间轴（等高对齐） ================= */
.timeline-section {
  position: relative;
  background-image: url(https://everrising.net/wp-content/uploads/2026/09/pexels-daniel-1547741-scaled.jpg);
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
  padding: 80px 20px;
}

.timeline-container {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: repeating-linear-gradient(
    to bottom,
    #ffffff,
    #ffffff 6px,
    transparent 6px,
    transparent 12px
  );
  transform: translateX(-50%);
}

/* 关键：启用 stretch 让左右卡片自动拉伸至等高 */
.timeline-item {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  margin-bottom: 60px;
  position: relative;
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.timeline-item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.timeline-item:nth-child(even) {
  transition-delay: 0.15s;
}

/* 左右两侧卡片：开启 flex 保证内部居中或撑满 */
.timeline-content {
  width: 45%;
  background: #ffffff;
  /* border-radius: 4px; */
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}

/* 绿色背景卡片样式 */
.timeline-content.green-bg {
  background-color: #132169 !important;
  color: #fff5c8;
  padding: 30px;
}

.timeline-content.green-bg .date {
  font-size: 28px;
  font-weight: bold;
  display: block;
  margin-bottom: 10px;
  font-family: "DIN", sans-serif !important;
}

/* 图片卡片等高铺满裁剪 */
.timeline-content img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.timeline-node {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 16px;
  background: #ffffff;
  border: 3px solid #0e1952;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
}
/* ================= 移动端响应式彻底修复（支持交错 DOM 顺序） ================= */
@media screen and (max-width: 768px) {
  /* 1. 外层容器调整 */
  .timeline-section {
    padding: 40px 15px !important;
  }

  .timeline-container {
    position: relative !important;
    width: 100% !important;
  }

  /* 2. 隐藏时间轴中间的主竖线和圆点 */
  .timeline-line,
  .timeline-node {
    display: none !important;
  }

  /* 3. 每一行时间轴变成普通的块级容器 */
  .timeline-item {
    position: relative !important;
    display: block !important;
    width: 100% !important;
    margin-bottom: 30px !important;
    height: auto !important;
    float: none !important;
    transform: none !important;
    opacity: 1 !important;
    clear: both !important;
  }

  /* 4. 强制所有左右卡片在手机端通栏显示，并取消绝对定位、浮动和偏移 */
  .timeline-item .timeline-content,
  .timeline-content,
  .timeline-item .left-card,
  .timeline-item .right-card {
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    bottom: auto !important;
    transform: none !important;
    float: none !important;
    display: block !important;
    margin: 0 0 15px 0 !important; /* 每个子卡片之间留出 15px 间距 */
    box-sizing: border-box !important;
    height: auto !important;
  }

  .timeline-item {
    display: flex !important;
    flex-direction: column !important;
  }

  /* 针对奇数行（默认：图在上，文在下）：保持原样 */
  .timeline-item .timeline-content:not(.green-bg) {
    order: 1 !important; /* 图片卡片排在第一位 */
    margin-bottom: 12px !important;
  }

  .timeline-item .timeline-content.green-bg {
    order: 2 !important; /* 绿色文字卡片排在第二位 */
    margin-bottom: 0 !important;
  }

  /* 6. 手机端图片与文字样式细节 */
  .timeline-content img {
    width: 100% !important;
    height: 220px !important;
    object-fit: cover !important;
    display: block !important;
    /* border-radius: 8px !important; */
  }

  .timeline-content.green-bg {
    padding: 20px !important;
    white-space: normal !important;
    /* border-radius: 8px !important; */
  }

  .timeline-content.green-bg .date {
    font-size: 20px !important;
    margin-bottom: 6px !important;
    display: block !important;
  }

  .timeline-content.green-bg p {
    font-size: 14px !important;
    line-height: 1.4 !important;
    display: block !important;
    margin: 0 !important;
  }
}

/* about-us-top-img */
.custom-top img {
  opacity: 0.5;
  overflow: hidden;
}

.custom-team img {
  width: 100px;
  height: 100px;
}

/* 文章页面布局  */
.custom-new-flex {
  display: flex;
  align-items: left;
  justify-content: space-between;
  flex-direction: column;
}

/* 文章右侧查看其它文章样式 */
.custom-new-line li {
  position: relative;
  padding-bottom: 20px;
}
.custom-new-line li::after {
  display: block;
  content: "";
  height: 1px;
  width: 100%;
  background-color: #ffffff28;
  position: absolute;
  bottom: 0;
}

.custom-footer-ad {
  border-radius: 5px !important;
}

/*======================================== 修改首页产品卡片样式 ========================================*/

/* 1. 强制卡片容器隐藏溢出并相对定位 */
.custom-pro-part .custom-view-more-card {
  overflow: hidden !important;
  position: relative !important;
}

.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container {
  justify-content: end;
  align-items: center;
  padding: 0 !important;
  overflow: hidden;
  border: 1px solid #ececec !important;
  border-radius: 5px !important;
}

/* 2. 图片默认状态与平滑过渡 */
.custom-pro-part .custom-view-more-card a img {
  transition: transform 0.4s ease-in-out !important;
  transform: scale(1) !important;
}

/* 3. 鼠标悬停卡片时，图片整体放大 */
.custom-pro-part .custom-view-more-card:hover a img {
  transform: scale(1.08) !important;
}

/* 标题栏基础样式 */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2 {
  margin-bottom: 0 !important;
  display: flex;
  width: 100%;
  padding: 20px;
  background-color: transparent;
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), #00000094);
  transition: padding 0.3s ease-in-out;
  position: absolute;
  bottom: 0;
  z-index: 2;
  justify-content: space-between !important ;
  align-items: center;
  flex-direction: column !important;
}

/* 鼠标悬停时，改变标题区域上下内边距来调整高度 */
.custom-pro-part
  .custom-view-more-card:hover
  .wc-block-components-product-image__inner-container
  h2 {
  padding-top: 28px;
  padding-bottom: 28px;
}

/* 最后一个链接（包含右侧圆圈按钮） */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  > a:last-child {
  display: flex;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  text-decoration: none;
  text-align: left;
}

/* 右侧圆圈伪元素 */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  > a:last-child::after {
  display: flex;
  justify-content: center;
  align-items: center;
  content: ">";
  height: 40px;
  width: 40px;
  background-color: #12248b;
  color: #fcffd3;
  font-size: 12px;
  border-radius: 100px;
  transition: all 0.3s ease-in-out;
  flex-shrink: 0; /* 防止圆圈被挤压 */
}

/* 鼠标悬停圆圈时的动效（已修正，不再撑满整行） */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  > a:last-child:hover::after {
  background-color: #12248b;
  transform: scale(1.1);
}

/* 第一个链接（标题文字）：限制宽度并超出显示省略号 */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  > a:first-child,
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  > a:not(:last-child) {
  max-width: calc(100% - 55px);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* 统一文字颜色 */
.custom-pro-part
  .custom-view-more-card
  .wc-block-components-product-image__inner-container
  h2
  a {
  color: #fff !important;
}

.custom-view-more-card a {
  width: 100% !important;
  height: 100% !important;
  cursor: pointer !important;
}

/* 语言切换 */

.gt_options {
  position: absolute !important;
  background-color: rgb(255, 255, 255) !important;
  right: 0px !important;
  top: 70px !important;
  font-size: 12px !important;
}
.nturl img {
  width: 20px !important;
  height: 20px !important;
}

.gt-current-lang img {
  width: 20px !important;
}

.gt-selected {
  font-size: 14px !important;
  background-color: transparent !important;
  color: #fff !important;
}
.gt_float_switcher {
  background-color: transparent !important;
  box-shadow: none !important;
  color: #fff !important;
}

.gt-lang-code {
  color: #fff !important;
}

.gt_float_switcher-arrow {
  color: #fff !important;
}

#gt_float_wrapper {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

/* ========================================产品分类样式====================================== */

.custom-pro-categories {
  display: flex !important;
  flex-direction: row !important;
  justify-content: end !important;
  position: relative !important;
  width: 100%;
  cursor: pointer;
  overflow: hidden !important;
}

.custom-pro-categories img {
  transition: all 0.3s ease !important;
}

/* 鼠标悬停时的状态 */
.custom-pro-categories:hover img {
  transform: scale(1.08) !important;
}

.custom-pro-categories:hover p {
  min-height: 120px !important;
}

.custom-pro-categories p {
  display: flex;
  gap: 15px;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  position: absolute !important;
  bottom: 0 !important;
  background-color: #00000041;
  padding: 20px;
  box-sizing: border-box !important;
  min-height: 90px;
  transition: all 0.3s ease !important;
}

.custom-pro-categories p::after {
  display: flex;
  content: ">";
  background-color: #132169;
  width: 40px;
  height: 40px;
  color: #fff;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  flex-shrink: 0;
}

.custom-pro-categories p a {
  display: flex;
  color: #fff;
  flex: 1; /* 占据剩余空间 */
  min-width: 0 !important; /* 【核心】防止 Flex 子元素被内部文本撑开失效 */
  word-break: break-all !important; /* 防止长单词或英文把容器撑破 */
}