/* tech.css */

.tech-page .hero-section {
  position: relative;
  width: 100%;
  height: 720px;
  overflow: hidden;
}

.tech-page .hero-section .hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.tech-page .hero-section .bg-graphic {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.tech-page .hero-section .mobile-bg {
  display: none;
}

.tech-page .hero-section .hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  padding: 0 2.04rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
}

/* 系统功能区域 */
.tech-system-section {
  padding: 1.6rem 0; /* 增加上下 padding，防止图片超出截断 */
  background: #ffffff;
  position: relative;
  overflow: hidden;
}
.tech-container {
  padding: 0;
  width: 100%;
  max-width: 15.12rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1.4rem;
  position: relative;
  z-index: 2;
}

.tech-content-left {
  flex: 1;
  max-width: 50%;
}

.tech-image-right {
  flex: 1;
  max-width: 50%;
  position: relative;
}

.image-group-1 {
  position: relative;
  width: 100%;
  padding-top: 85%;
  margin-top: -10%; /* 向上偏移使图片超出蓝色背景 */
  margin-bottom: -10%; /* 向下偏移使图片超出蓝色背景 */
}

.image-group-1 img {
  position: absolute;
  width: 75%; /* 调大图片比例 */
  border-radius: 0.24rem;
}

.image-group-1 .img-top-right {
  top: 0;
  right: -5%; /* 向右超出蓝色背景 */
  z-index: 1;
}

.image-group-1 .img-bottom-left {
  bottom: -20%;
  left: -5%; /* 向左超出蓝色背景 */
  z-index: 2;
}

.tech-image-left {
  flex: 1;
  max-width: 50%;
  position: relative;
}

.image-group-2 {
  position: relative;
  width: 100%;
  padding-top: 100%;
  margin-top: -15%; /* 向上偏移使图片超出蓝色背景 */
  margin-bottom: -15%; /* 向下偏移使图片超出蓝色背景 */
}

.image-group-2 img {
  position: absolute;
  width: 65%; /* 调大图片比例 */
  border-radius: 0.24rem;
}

.image-group-2 .img-top-left {
  top: 0;
  left: -5%; /* 向左超出蓝色背景 */
  z-index: 1;
}

.image-group-2 .img-mid-right {
  top: 30%;
  right: -5%; /* 向右超出 */
  z-index: 2;
}

.image-group-2 .img-bottom-left {
  bottom: 0;
  left: -5%;
  z-index: 3;
}

.tech-content-right {
  flex: 1;
  max-width: 50%;
}

.tech-title {
  font-size: 0.64rem;
  font-weight: normal;
  color: #0037c3;
  margin-bottom: 0.16rem;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  font-family: "PangMenZhengDaoBiaoTiTiMianFeiBan-4", sans-serif;
  line-height: 1.2;
}

.tech-title span {
  color: #000000;
}

.tech-desc {
  font-size: 0.16rem;
  color: #505050;
  line-height: 1.6;
}

.bg-shape-grey-left {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 10.35rem;
  height: 5.85rem;
  background: #ececec;
  border-radius: 0;
  z-index: 0;
  border-radius: 0 300px 300px 0;
}

.bg-shape-blue-right {
  position: absolute;
  right: 0; /* 贴紧右侧 */
  top: 50%;
  transform: translateY(-50%);
  width: 7.4rem;
  height: 4.34rem;
  background: linear-gradient(270deg, #2764ff 0%, #0037c3 81%);
  border-radius: 0.48rem 0 0 0.48rem; /* 只有左侧有圆角 */
  z-index: 0;
}

.bg-shape-grey-right {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 10rem;
  height: 5.85rem;
  background: #ececec;
  border-radius: 0;
  z-index: 0;
  border-radius: 300px 0 0 300px;
}

.bg-shape-blue-left {
  position: absolute;
  left: 0; /* 贴紧左侧 */
  top: 50%;
  transform: translateY(-50%);
  width: 7.4rem;
  height: 4.34rem;
  background: linear-gradient(90deg, #2764ff 0%, #0037c3 81%);
  border-radius: 0 0.48rem 0.48rem 0; /* 只有右侧有圆角 */
  z-index: 0;
}

/* 机加工介绍 */
.machining-section {
  padding: 0.8rem 0;
  background: #ffffff;
  text-align: left;
}

.machining-container {
  padding: 0;
  width: 100%;
  max-width: 15.12rem;
  margin: 0 auto;
}

.machining-title {
  font-size: 0.64rem;
  font-weight: normal;
  color: #000000;
  margin-bottom: 0.36rem;
  font-family: "PangMenZhengDaoBiaoTiTiMianFeiBan-4", sans-serif;
  line-height: 1.2;
}

.machining-title span {
  color: #0037c3;
}

.machining-desc {
  font-size: 0.16rem;
  color: #505050;
  line-height: 1.6;
  margin-bottom: 0.72rem;
}

.machining-divider {
  width: 100%;
  height: 4px;
  background: #ececec;
  margin-bottom: 0.88rem;
}

.machine-item {
  display: flex;
  align-items: center;
  gap: 0.88rem;
  margin-bottom: 0.8rem;
  text-align: left;
}

.machine-item:nth-child(odd) {
  flex-direction: row-reverse;
}

.machine-item-switchable:nth-child(odd) {
  flex-direction: row-reverse;
}

.machine-item-switchable:nth-child(even) {
  flex-direction: row;
}

.machine-content {
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.machine-image {
  flex: 0 0 7.44rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.machine-photo {
  width: 7.44rem;
  height: 5.58rem;
  object-fit: cover;
  border-radius: 0.36rem;
  display: block;
}

.machine-image img:not(.machine-photo) {
  max-width: 100%;
  height: auto;
  border-radius: 0.36rem;
}

.machine-name-group {
  margin-bottom: 0.36rem;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.machine-name-blue {
  font-size: 0.48rem;
  font-weight: normal;
  color: #0037c3;
  font-family: "PangMenZhengDaoBiaoTiTiMianFeiBan-4", sans-serif;
  line-height: 1.2;
}

.machine-name-black {
  font-size: 0.48rem;
  font-weight: normal;
  color: #000000;
  font-family: "PangMenZhengDaoBiaoTiTiMianFeiBan-4", sans-serif;
  line-height: 1.2;
}

.machine-name-blue.single-line {
  margin-bottom: 0.36rem;
}

.machine-text {
  font-size: 0.18rem;
  color: #505050;
  line-height: 1.6;
  margin-bottom: 0.36rem;
}

.models-container {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0.24rem;
  position: relative;
}

.model-list {
  display: flex;
  flex-direction: column;
  gap: 0.24rem;
  align-items: flex-start;
  flex: 1;
  min-width: 0;
}

.model-line {
  width: 0.08rem;
  background: #ececec;
  border-radius: 0.04rem;
  flex-shrink: 0;
  position: relative;
  align-self: stretch;
  overflow: hidden;
}

.model-line::before {
  content: none;
}

.machine-item:not(.machine-item-switchable) .model-line::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0.64rem;
  background: #0037c3;
  border-radius: 0.04rem;
}

.model-line-active {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 0.56rem;
  background: #0037c3;
  border-radius: 0.04rem;
  transition: transform 0.3s ease;
}

.model-btn {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  border-radius: 0.48rem;
  padding: 0.12rem 0.48rem;
  box-sizing: border-box;
  width: 5.2rem;
  min-height: 0.56rem;
  cursor: pointer;
  background: #ffffff;
  border: 0.04rem solid #ececec;
  font: inherit;
  text-align: left;
  transition:
    background-color 0.3s ease,
    border-color 0.3s ease;
}

.model-btn.active {
  background: #0037c3;
  border-color: #0037c3;
}

.model-btn span {
  font-size: 0.2rem;
  font-family: "HarmonyOS Sans SC", sans-serif;
  line-height: 1.6;
  white-space: nowrap;
  width: 100%;
  text-align: left;
  color: #5d5d5d;
  font-weight: 400;
}

.model-btn.active span {
  color: #ffffff;
  font-weight: 700;
}

.model-btn:focus-visible {
  outline: 2px solid #0037c3;
  outline-offset: 2px;
}

.model-group {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  background: #0037c3;
  border: 0.04rem solid #0037c3;
  border-radius: 0.48rem;
  padding: 0.12rem 0.48rem;
  box-sizing: border-box;
  width: auto;
  min-height: 0.56rem;
}

.model-group-outline {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  border: 0.04rem solid #ececec;
  border-radius: 0.48rem;
  padding: 0.12rem 0.48rem;
  box-sizing: border-box;
  width: 5.2rem;
  min-height: 0.56rem;
}

.machine-model {
  color: #ffffff;
  font-size: 0.2rem;
  font-weight: 700;
  font-family: "HarmonyOS Sans SC", sans-serif;
  line-height: 1.6;
  letter-spacing: 0;
  width: 100%;
  text-align: left;
  white-space: nowrap;
}

.machine-model-outline {
  color: #5d5d5d;
  font-size: 0.2rem;
  font-weight: 400;
  font-family: "HarmonyOS Sans SC", sans-serif;
  line-height: 1.6;
  letter-spacing: 0;
  width: 100%;
  text-align: left;
  white-space: nowrap;
}

/* ==========================================================================
   移动端响应式 (<= 768px)
   ========================================================================== */
@media (max-width: 768px) {
  .models-container {
    gap: 12px;
    align-items: stretch;
  }
  .machine-model{
    font-size: .32rem;
    text-align: center;
  }
  .model-line {
    width: 4px;
    border-radius: 999px;
    background: #ececec;
  }

  .machine-item:not(.machine-item-switchable) .model-line::before {
    width: 100%;
    height: 48px;
    border-radius: 999px;
  }

  .model-line-active {
    width: 100%;
    min-height: 48px;
    border-radius: 999px;
  }

  .model-list {
    width: 100%;
    flex: 1;
    align-items: stretch;
    gap: 12px;
  }

  .model-group,
  .model-group-outline,
  .model-btn {
    width: 100%;
    height: auto;
    min-height: .96rem;
    padding: .2rem 0;
    justify-content: center;
    border-radius: .96rem;
    box-sizing: border-box;
  }

  .model-btn {
    border-width: 2px;
  }

  .model-group,
  .model-group-outline {
    border-width: 2px;
  }
  .tech-page .hero-section {
    height: 43vh;
  }
  .tech-page .hero-section .pc-bg {
    display: none;
  }
  .tech-page .hero-section .mobile-bg {
    display: block;
  }
  .tech-page .hero-section .hero-content {
    align-items: center;
    text-align: center;
  }
  .tech-page .hero-section .hero-title {
    font-size: 64px;
  }

  .tech-container {
    flex-direction: column;
    gap: 0.6rem;
    padding: 0 0.4rem; /* 增加移动端左右间距 */
  }

  .tech-content-left,
  .tech-content-right {
    order: 1;
    max-width: 100%;
    width: 100%;
  }

  .tech-image-left,
  .tech-image-right {
    order: 2;
    max-width: 100%;
    width: 100%;
  }

  .image-group-1,
  .image-group-2 {
    margin-top: 0;
    margin-bottom: 0;
  }

  .tech-title {
    font-size: .64rem;
    justify-content: flex-start;
    margin-bottom: 0.24rem;
  }

  .tech-desc {
    font-size: .28rem;
    text-align: left;
  }

  .bg-shape-grey-right,
  .bg-shape-grey-left {
    display: none;
  }

  .bg-shape-blue-right {
    display: block;
    top: 60%;
    height: 45vw;
    width: 85%;
    transform: none;
    border-radius: 0.48rem 0 0 0.48rem;
  }

  .bg-shape-blue-left {
    display: block;
    top: 55%;
    height: 45vw;
    width: 85%;
    transform: none;
    border-radius: 0 0.48rem 0.48rem 0;
  }

  .machining-container {
    padding: 0 0.4rem;
  }

  .machining-title {
    font-size: .64rem;
    margin-bottom: 0.24rem;
  }

  .machining-desc {
    font-size: .28rem;
    text-align: left;
  }

  .machine-item,
  .machine-item:nth-child(odd),
  .machine-item-switchable:nth-child(odd),
  .machine-item-switchable:nth-child(even) {
    flex-direction: column-reverse;
    gap: 0.4rem;
  }

  .machine-image {
    flex: none;
    width: 100%;
  }

  .machine-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 744 / 558;
  }

  .model-btn span {
    font-size: .32rem;
    text-align: center;
    line-height: 1.5;
    white-space: normal;
  }

  .machine-name-blue,
  .machine-name-black {
    font-size: .48rem;
  }

  .machine-text {
    font-size: .28rem;
    margin-bottom: 0.24rem;
  }
}

@media (max-width: 768px) {
  .tech-page .hero-section .hero-content {
    padding-left: 16px;
    padding-right: 16px;
  }
}
