/*
 * @pageName: yawei_text_pic2
 * @Date: 2025-06-01
 * @Author: yangheng
 * @Description: 图文展示组件2 - 基于Figma设计稿的图文布局
 */

/* Main Component Container */
.yawei-text-pic2-block {
  padding: 0; /* 全宽，移除上下padding */
  background: #ffffff;
}

/* Container Responsive Settings - Ensure it's full width */
.yawei-text-pic2-block .container-fluid {
  margin-left: auto;
  margin-right: auto;
  padding-left: 15px; /* Standard padding */
  padding-right: 15px; /* Standard padding */
  /* max-width will be set in media queries */
}

/* Responsive max-width for the container-fluid */
@media (min-width: 576px) {
  .yawei-text-pic2-block .container-fluid {
    max-width: 540px;
  }
}

@media (min-width: 768px) {
  .yawei-text-pic2-block .container-fluid {
    max-width: 720px;
  }
}

@media (min-width: 992px) {
  .yawei-text-pic2-block .container-fluid {
    max-width: 960px; /* Standard non-compensated width, as items are full-bg */
     /* If visual match to yawei_text_pic (1027px) is strict, use that. But structure is different. */
  }
}

@media (min-width: 1200px) {
  .yawei-text-pic2-block .container-fluid {
    max-width: 1200px; /* Standard non-compensated width */
    /* If visual match to yawei_text_pic (1286px) is strict, use that. */
  }
}
@media (max-width: 1920px) {
  .yawei-text-pic2-block .container {
      max-width: 1820px; /* Generic 1500px default 1440px + 31px compensation */
      
  }
}

/* Product Showcase Grid */
.yawei-text-pic2-block .product-showcase-grid {
  width: 100%;
}

/* Product Showcase Item - 每个产品独占一行，背景铺满 */
.yawei-text-pic2-block .product-showcase-item {
  display: flex;
  flex-direction: column; /* Mobile-first: stacked */
  width: 100%;
  margin-bottom: 32px; /* Gap between items */
  background: #F5F6FA; /* Default background for the item */
  /* min-height will be set in media queries, referencing yawei_text_pic image heights */
  transition: all 0.3s ease;
}

.yawei-text-pic2-block .product-showcase-item:last-child {
  margin-bottom: 0; /* No gap after the last item */
}

/* Product Image Section */
.yawei-text-pic2-block .product-image-section {
  position: relative;
  width: 100%;
  overflow: hidden; /* Important for clip-path to work correctly */
  flex: 1; /* Take available space in column layout */
  background-color: #F5F6FA; /* Ensure background for image area */
}

.yawei-text-pic2-block .product-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%; 
  /* min-height will be set in media queries, referencing yawei_text_pic image heights */
  overflow: hidden;
  background-color: transparent; /* Wrapper should be transparent if section has bg */
}

.yawei-text-pic2-block .product-image {
  /* position: absolute; */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  z-index: 0;
  transition: transform 0.3s ease;
}

.yawei-text-pic2-block .product-showcase-item:hover .product-image {
  transform: scale(1.05);
}

/* Product Content Section */
.yawei-text-pic2-block .product-content-section {
  padding: 40px 0 40px 30px;
  background: #F5F6FA; /* Content background matches item background */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center; /* Mobile: center content */
  text-align: center; /* Mobile: center text */
  flex: 1; /* Take available space in column layout */
}

.yawei-text-pic2-block .product-content-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center; /* Mobile: center align */
  gap: 25px;
  /* max-width: 500px; Limit content width on mobile */
  width: 100%; /* Ensure wrapper takes available width for alignment */
}

/* Product Title */
.yawei-text-pic2-block .product-title {
  font-family: var(--title-font-family);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.025em;
  color: #101115;
  margin: 0;
  text-align: left;
}

/* Product Action Wrapper */
.yawei-text-pic2-block .product-action-wrapper {
  display: flex;
  align-items: center;
  justify-content: center; /* Mobile: center button */
}

/* Explore Button - 参考yawei_text_pic样式 */
.yawei-text-pic2-block .explore-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--title-font-family);
  font-size: 14px; /* Mobile base size */
  line-height: 1.5; 
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 8px 20px; /* Mobile base padding */
  text-decoration: none;
  border-radius: 0;
  transition: all 0.3s ease;
  white-space: nowrap;
  background: transparent;
  color: #161616;
  border: 1px solid #000000;
}

.yawei-text-pic2-block .explore-btn:hover {
  background: #E6002D;
  color: #FFFFFF;
  border-color: #E6002D;
  text-decoration: none;
}

.yawei-text-pic2-block .explore-btn span {
  position: relative;
  z-index: 1;
}
.yawei-text-pic2-block .product-showcase-left .product-image-wrapper {
  aspect-ratio: 309/239;
  /* min-height: 320px; yawei_text_pic height for this breakpoint */
}
/* Desktop Layout - 左右交替布局 (min-width: 992px) */
@media (min-width: 992px) {
  .yawei-text-pic2-block .product-showcase-item {
    display: flex !important; /* Force flex display for items */
    align-items: stretch; 
    /* min-height: 720px; Reference: yawei_text_pic default image wrapper height */
  }

  .yawei-text-pic2-block .product-image-section {
    flex: 0 0 52%; 
    max-width: 52%;
    min-height: 100%; 
  }

  .yawei-text-pic2-block .product-image-wrapper {
    min-height: 100%; /* Ensure it fills the section */
  }

  .yawei-text-pic2-block .product-content-section {
    flex: 0 0 48%; 
    max-width: 48%;
    padding: 80px 0 80px 60px;
    align-items: flex-start; 
    text-align: left; 
  }
  
  .yawei-text-pic2-block .product-content-wrapper {
    align-items: flex-start; 
    /* max-width: 450px;  */
  }

  /* Item 1 (Text Left, Image Right) */
  .yawei-text-pic2-block .product-showcase-left {
    flex-direction: row-reverse !important; 
  }

  /* Item 2 (Image Left, Text Right) */
  .yawei-text-pic2-block .product-showcase-right {
    flex-direction: row !important; 
  }

  /* Conditional Trapezoid for Item 1 (Image on RIGHT, slant on its LEFT edge) */
  .yawei-text-pic2-block .product-showcase-left.item1-clipping-active .product-image-section {
     clip-path: polygon(15% 0%, 100% 0%, 100% 100%, 0% 100%); 
     
  }

  /* Conditional Trapezoid for Item 2 (Image on LEFT, slant on its RIGHT edge) */
  .yawei-text-pic2-block .product-showcase-right.item2-clipping-active .product-image-section {
     clip-path: polygon(0% 0%, 100% 0%, 85% 100%, 0% 100%); 
     max-width: 60%;
    flex: 0 0 60%;
  }
  .yawei-text-pic2-block .product-showcase-right.item2-clipping-active .product-content-section {
    max-width: 40%;
   flex: 0 0 40%;
 }

  
  
  .yawei-text-pic2-block .explore-btn {
    font-size: 16px;
    padding: 10px 25px;
  }
}



/* Large Desktop Adjustments (min-width: 1200px) */
@media (min-width: 1200px) {
  .yawei-text-pic2-block .product-showcase-item {
    /* min-height: 720px; Consistent with 992px or could be yawei_text_pic's 360px if preferred for this view */
  }
  .yawei-text-pic2-block .product-content-section {
    padding: 100px 0 100px 100px;
  }
   .yawei-text-pic2-block .product-content-wrapper {
    /* max-width: 500px;  */
  }
  .yawei-text-pic2-block .product-title {
    font-size: 40px;
  }
}
@media (min-width: 1900px) {
  .yawei-text-pic2-block .product-title {
    font-size: 40px; 
  }
}

/* Mobile and Tablet Heights, referencing yawei_text_pic image heights */
/* These apply to .product-image-wrapper as it dictates visible image height on mobile */

@media (max-width: 1199px) and (min-width: 992px) { /* Large tablets / Small desktops */
    .yawei-text-pic2-block .product-showcase-item {
        /* min-height: 500px; */
    }
}

@media (max-width: 991px) { /* Tablets and below - stacked view */
  .yawei-text-pic2-block .product-showcase-item {
    flex-direction: column !important; /* Ensure stacking */
    min-height: auto; /* Reset min-height, let content dictate */
  }
  .yawei-text-pic2-block .product-showcase-left .product-image-wrapper {
    aspect-ratio: 309/239;
    /* min-height: 320px; yawei_text_pic height for this breakpoint */
  }
  .yawei-text-pic2-block .product-showcase-left .product-image-section,
  .yawei-text-pic2-block .product-showcase-right .product-image-section {
    clip-path: none !important; /* Remove trapezoid on mobile/tablet stack */
  }
  .yawei-text-pic2-block .product-image-section,
  .yawei-text-pic2-block .product-content-section {
    max-width: 100%; 
    flex-basis: auto; 
  }
  .yawei-text-pic2-block .product-action-wrapper{
    justify-content: flex-start;
  }
  .yawei-text-pic2-block .product-showcase-left .product-image-section{
    width: 45%;
  }
  .yawei-text-pic2-block .product-content-section {
    padding: 30px 0 30px 24px;
  }
  .yawei-text-pic2-block .product-showcase-item.product-showcase-left{
    flex-direction: row-reverse !important;
    margin-right: -15px;
    margin-left: -15px;
    width: calc(100% + 30px);
  }
  .yawei-text-pic2-block .product-showcase-left .product-content-wrapper{
    align-items: baseline;
  }
  .yawei-text-pic2-block .product-showcase-right .product-content-section{
    background-color: #fff;
  }
  .yawei-text-pic2-block .product-content-wrapper{
    gap: 15px;
  }
  .yawei-text-pic2-block .product-title {
    font-size: 26px; 
  }
}

@media (max-width: 767px) { /* Mobile phones */
  .yawei-text-pic2-block .product-image-wrapper {
    /* min-height: 280px; yawei_text_pic height */
  }
  .yawei-text-pic2-block .product-content-section{padding:25px 0 0;}
  .yawei-text-pic2-block .product-showcase-left .product-content-section{padding:0 0 0 15px;}
  .yawei-text-pic2-block .product-title {
    font-size: 20px;
  }
  .yawei-text-pic2-block .explore-btn {
    font-size: 13px;
    padding: 7px 18px;
  }
}

@media (max-width: 575px) {
   .yawei-text-pic2-block .product-image-wrapper {
    /* min-height: 240px; yawei_text_pic height */
  }
   .yawei-text-pic2-block .product-title {
    font-size: 18px;
  }
  .yawei-text-pic2-block .explore-btn {
    font-size: 12px;
    padding: 6px 15px;
  }
  .yawei-text-pic2-block .product-showcase-left .product-image-section{
    width: 60%;
  }
  
}

@media screen and (max-width:480px) {
.yawei-text-pic2-block .product-title{font-size:17px;}
}	

.yawei-text-pic-2 {
  padding: 80px 0;
  background-color: var(--bg-color);
} 