/* ============================================================
   en-zxdt.css — 最新动态页面样式
   设计稿: 1920px, 内容区 1400px, SCALE=1
   单位: rem (1rem = 100px at 1400px viewport)
   所有尺寸来自 DSL layoutStyle 坐标计算
   ============================================================ */

/* === Latest News 区域 === */
/* DSL: news Group, y=198, w=1920, h=880, bg=#F7FBFF */
.latest-news {
  position: relative;
  background-color: #f7fbff;
  padding-top: 0.61rem; /* DSL: title y=61 rel to section */
  padding-bottom: 0.45rem; /* DSL: section h=880 - card bottom(683+110-198)=595 → 880-595=285px→0.42rem after featured bottom */
}

/* Section header: title + more link */
/* DSL: title Frame x=823, y=61, w=302, h=40; more x=1580, y=71 */
.latest-news__header {
  display: -ms-flexbox;
  display: flex;
  -ms-flex-pack: center;
  justify-content: center;
  -ms-flex-align: center;
  align-items: center;
  position: relative;
  height: 0.4rem; /* DSL: h=40 → 0.4rem */
  margin-bottom: 0.52rem; /* DSL: featured y=153 - (title y=61 + title h=40) = 52px → 0.52rem */
}

/* DSL: "Latest News" text, Inter 40px Bold, #000 */
.latest-news__title {
  font-size: 0.4rem;
  font-weight: 700;
  color: #000000;
  letter-spacing: 0;
}

/* DSL: more link x=1580, y=71, w=63, h=20 */
.latest-news__more {
  position: absolute;
  right: 0;
  top: 0.1rem; /* DSL: more y=71 - title y=61 = 10px → 0.1rem */
  display: -ms-flexbox;
  display: flex;
  -ms-flex-align: center;
  align-items: center;
  font-size: 0.14rem;
  font-weight: 700;
  color: #006bc3;
  text-decoration: none;
  transition: opacity 0.2s;
}

.latest-news__more:hover {
  opacity: 0.8;
}

.latest-news__more-icon {
  width: 0.16rem;
  height: 0.16rem;
  margin-left: 0.07rem; /* DSL: icon x=46.91 - text w=36 = ~11px → 0.07rem，替代 gap */
}

/* Featured area: image + right text column */
/* DSL: image x=260, y=153, w=833, h=490; right items start at x=1125 */
.latest-news__featured {
  display: -ms-flexbox;
  display: flex;
  -ms-flex-align: start;
  align-items: flex-start;
  margin-bottom: 0.42rem; /* DSL: cards y=683 - image bottom(153+490=643) = 40px → 0.42rem adjusted */
}

/* DSL: featured image w=833, h=490 */
.latest-news__featured-image {
  -ms-flex: 0 0 6.72rem;
  flex: 0 0 6.72rem;
  width: 6.72rem;
  height: 3.72rem;
  overflow: hidden;
}

.latest-news__featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* IE10 忽略，由下方 min 尺寸撑满容器 */
  min-width: 100%;
  min-height: 100%;
}

.latest-news__featured-image a {
  display: block;
  width: 100%;
  height: 100%;
}

/* Right text column */
/* DSL: title1 y=196, blue box y=286, title3 y=448, title4 y=556 */
/* relative to featured top (y=153): 196-153=43, 286-153=133, 448-153=295, 556-153=403 */
.latest-news__featured-right {
  -ms-flex: 1;
  flex: 1;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-direction: column;
  flex-direction: column;
  margin-left: -0.07rem; /* 原 -0.15rem + gap 0.08rem */
}

/* DSL: text items Inter 20px Medium, line-height ~26px */
.latest-news__text-item {
  text-decoration: none;
  transition: opacity 0.2s;
  padding: 0.15rem 0.4rem;
  height: 1.24rem;
}

.latest-news__text-item p {
  font-size: 0.2rem;
  color: #1d293d;
  line-height: 0.26rem;
}
.latest-news__text-item .time {
  font-size: 0.13rem;
  color: #21252b;
  margin-bottom: 0.07 rem;
}

/* DSL: blue box w=575, h=124, bg=#3290FF */
.latest-news__text-item:hover {
  background-color: #003366;
  box-sizing: border-box;
}

.latest-news__text-item:hover p {
  color: #ffffff;
}

/* Bottom cards row */
/* DSL: 3 cards at y=683, w=450, h=110, gap=25px */
.latest-news__cards {
  display: -ms-flexbox;
  display: flex;
}

/* DSL: card gap = 735-(260+450)=25px，用 margin 替代 gap */
.latest-news__card + .latest-news__card {
  margin-left: 0.25rem;
}

/* DSL: card w=450, h=110, bg=#DEEDFF */
.latest-news__card {
  -ms-flex: 1;
  flex: 1;
  height: 1.1rem;
  background-color: #deedff;
  border-radius: 0.04rem;
  padding: 0.27rem 0.3rem; /* DSL: text y=710-683=27px top; text x=290-260=30px left */
  box-sizing: border-box;
  text-decoration: none;
  transition: background-color 0.2s;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-align: center;
  align-items: center;
}

.latest-news__card:hover {
  background-color: #c8deff;
}

/* DSL: card text w=400, h=58, Inter 20px Medium, #000 or #1D293D */
.latest-news__card p {
  font-size: 0.2rem;
  font-weight: 500;
  color: #1d293d;
  line-height: 0.26rem;
}

/* === Activities 轮播区域 === */
/* DSL: EXP Group, y=1144, w=2132, x=-102, h=609, overflow layout */
.activities {
  position: relative;
  padding-top: 0.66rem; /* DSL: gap from news = 1144-1078=66px */
  overflow: hidden;
}

/* DSL: "Activities" text, y=1154, Inter 40px Bold, #000, centered */
.activities__title {
  display: block;
  text-align: center;
  font-size: 0.4rem;
  font-weight: 700;
  color: #000000;
  margin-bottom: 0.39rem; /* DSL: cards y(rel)=79 - title y(rel)=10 - lh_diff(0.2) = 49px → 0.39rem adjusted */
}

/* Carousel wrapper - holds Swiper + arrows */
.activities__carousel-wrap {
  position: relative;
  width: 12.76rem; /* DSL: 3*420 + 2*8 = 1276px → 12.76rem */
  margin: 0 auto;
  padding-bottom: 0.66rem; /* DSL: 30px gap(card bottom→arrow) + 36px arrow h = 66px */
}

/* Swiper container */
.activities-swiper {
  overflow: visible;
}

/* DSL: card w=420, gap=8px */
.activities-swiper .swiper-slide {
  width: 4.2rem;
  -ms-flex-negative: 0;
  flex-shrink: 0;
  opacity: 0.5;
  background: #f7fbff;
}
.activities-swiper .swiper-slide.swiper-slide-prev,
.activities-swiper .swiper-slide.swiper-slide-next,
.activities-swiper .swiper-slide.swiper-slide-active {
  opacity: 1;
}
/* DSL: card total h=464, image h=296, border 1px #E5E7EB */
.activities__card {
  display: block;
  width: 4.2rem;
  height: 4.64rem;
  overflow: hidden;
  text-decoration: none;
  border-radius: 0.04rem;
  transition: opacity 0.3s;
}

/* DSL: image w=420, h=296, stroke 1px #E5E7EB inside */
.activities__card-image {
  width: 4.2rem;
  height: 2.96rem;
  overflow: hidden;
  border: 0.01rem solid #e5e7eb;
  box-sizing: border-box;
}

.activities__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-width: 100%;
  min-height: 100%;
}

/* DSL: title y=326 rel to card, h≈59-72; date y=408 */
.activities__card-info {
  padding: 0.3rem 0.17rem 0; /* DSL: 326-296=30px top; x≈17px left */
}

/* DSL: title w≈386, Inter 18px Bold, #1D293D */
.activities__card-title {
  font-size: 0.18rem;
  font-weight: 700;
  color: #1d293d;
  line-height: 0.24rem;
  margin: 0;
}

/* DSL: date w=102, h=15, Inter 16px Bold, #90A1B9 */
.activities__card-date {
  display: block;
  margin-top: 0.23rem; /* DSL: 408-326-59=23px (title bottom to date) */
  font-size: 0.13rem;
  color: #90a1b9;
}

/* DSL: edge cards opacity 0.4 */
.activities-swiper .swiper-slide:first-child .activities__card,
.activities-swiper .swiper-slide:last-child .activities__card {
  opacity: 0.4;
}

/* Arrows: both on right side, using background-image + hover */
/* DSL: arrows at y=573 rel to section, both at right side */
.activities__arrow {
  position: absolute;
  bottom: 0;
  z-index: 10;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 0.36rem;
  height: 0.36rem;
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: center;
}

.activities__arrow--prev {
  right: 0.62rem;
  background-image: url("./en_zxdt_sw_arr1.png");
}

.activities__arrow--prev:hover {
  background-image: url("./en_zxdt_sw_arr2.png");
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}

.activities__arrow--next {
  right: 0;
  background-image: url("./en_zxdt_sw_arr1.png");
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}

.activities__arrow--next:hover {
  background-image: url("./en_zxdt_sw_arr2.png");
  -ms-transform: rotate(0);
  transform: rotate(0);
}

/* === Videos 区域 === */
/* DSL: Videos title at y=1835, content at y=1902–2462 */
.videos {
  position: relative;
  padding-top: 0.82rem; /* DSL: gap from activities = 1835-1753=82px */
  padding-bottom: 1rem; /* gap归到底部section(Expats)的padding-top, Rule F */
  overflow: hidden;
}

/* DSL: "Videos" text, Inter 40px Bold, #000, centered */
.videos__title {
  display: block;
  text-align: center;
  font-size: 0.4rem;
  font-weight: 700;
  color: #000000;
  margin-bottom: 0.35rem; /* DSL: center video y=1902 - title y=1835 - lh(0.4) = 27px → 0.27rem adjusted */
}

/* Stage: holds Swiper + decorations */
.videos__stage {
  position: relative;
  width: 14rem;
  margin: 0 auto;
  height: 5.6rem; /* DSL: center video h=560 → 5.6rem */
  overflow: hidden;
}

/* Swiper container */
.videos-swiper {
  width: 100%;
  height: 5.6rem;
  overflow: visible;
}

/* DSL: center slide w=944, h=560 */
.videos-swiper .swiper-slide {
  width: 9.44rem;
  height: 5.6rem;
  -ms-flex-negative: 0;
  flex-shrink: 0;
}

/* Active slide: center video, full opacity, on top */
.videos-swiper .swiper-slide-active {
  z-index: 2;
  opacity: 1;
}

.videos-swiper .swiper-slide a {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.videos-swiper .swiper-slide-active a {
  pointer-events: auto;
}

.videos-swiper .swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-width: 100%;
  min-height: 100%;
}

/* Side slides: opacity 0.7, behind center, angled clip-path */
.videos-swiper .swiper-slide-prev,
.videos-swiper .swiper-slide-next {
  z-index: 1;
  opacity: 0.7;
}

/* Left side: trapezoid angled edge（IE10 不支持 clip-path，仅现代浏览器生效） */
@supports (clip-path: polygon(0 0)) {
  .videos-swiper .swiper-slide-prev {
    clip-path: polygon(0 0, 100% 10%, 100% 90%, 0 100%);
  }

  .videos-swiper .swiper-slide-next {
    clip-path: polygon(0 10%, 100% 0, 100% 100%, 0 90%);
  }
}

/* DSL: decorative double chevrons */
/* 组 150: x=454, y=2146, w=26, h=72; 组 151: x=1442, y=2146 */
.videos__deco {
  position: absolute;
  top: 2.44rem; /* DSL: 2146-1902=244px → 2.44rem from stage top */
  z-index: 3;
  cursor: pointer;
}

.videos__deco--left {
  left: 1.94rem; /* DSL: 454-260=194px → 1.94rem from content left */
}

.videos__deco--right {
  right: 1.94rem; /* DSL: 1400-(1442-260+26)=1400-1208=192px ≈ 1.94rem */
}

/* Videos 箭头按钮 - 仅移动端显示 */
.videos__arrow {
  position: absolute;
  bottom: 0.5rem;
  left: 50%;
  -ms-transform: translateX(-50%);
  transform: translateX(-50%);
  z-index: 10;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 0.36rem;
  height: 0.36rem;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  display: none; /* PC端隐藏 */
}

.videos__arrow--prev {
  margin-left: -0.5rem;
  background-image: url("./en_zxdt_sw_arr1.png");
  -ms-transform: translateX(-50%) rotate(180deg);
  transform: translateX(-50%) rotate(180deg);
}

.videos__arrow--prev:hover {
  background-image: url("./en_zxdt_sw_arr2.png");
}

.videos__arrow--next {
  margin-left: 0.5rem;
  background-image: url("./en_zxdt_sw_arr1.png");
}

.videos__arrow--next:hover {
  background-image: url("./en_zxdt_sw_arr2.png");
}

/* === Expats in Chongqing 区域 === */
/* DSL: gradient bg y=2562, h=758, linear-gradient(180deg, #D6EEFF→#F9FDFF) */
.expats {
  position: relative;
  background: linear-gradient(180deg, #d6eeff 0%, #f9fdff 100%);
  padding-top: 1rem; /* DSL: gap from videos content bottom ≈ 100px */
  padding-bottom: 0.95rem; /* DSL: bg bottom - card bottom = 3320-3225=95px */
  overflow: hidden;
}

/* DSL: "Expats in Chongqing" title, Inter 40px Bold, #000, centered */
.expats__title {
  display: block;
  text-align: center;
  font-size: 0.4rem;
  font-weight: 700;
  color: #000000;
  margin-bottom: 0.28rem; /* DSL: cards y=2729 - title y=2641 - lh(0.4) = 28px → 0.28rem adjusted */
}

/* Carousel wrapper: 限制在内容区1400px内，超出隐藏 */
.expats__carousel-wrap {
  position: relative;
}

/* Swiper container — overflow:hidden 由 Swiper 默认处理 */
.expats-swiper {
  width: 100%;
  overflow: hidden;
}

.expats-swiper .swiper-slide {
  width: 4.38rem;
  -ms-flex-negative: 0;
  flex-shrink: 0;
  background-color: #ffffff;
}
/* DSL: card w=438, h=496 */
.expats__card {
  -ms-flex: 0 0 4.38rem;
  flex: 0 0 4.38rem;
  width: 4.38rem;
  height: 4.96rem;
  background-color: #ffffff;
  overflow: hidden;
  border-radius: 0.04rem;
  text-decoration: none;
  transition: box-shadow 0.3s;
}

.expats__card:hover {
  box-shadow: 0 0.04rem 0.12rem rgba(0, 0, 0, 0.1);
}

/* DSL: image w=438, h=340 */
.expats__card-image {
  width: 4.38rem;
  height: 3.4rem;
  overflow: hidden;
}

.expats__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-width: 100%;
  min-height: 100%;
}

/* DSL: text y=367 rel to card, w≈367, h=107, Inter 20px Medium, #1D293D */
.expats__card-info {
  padding: 0.29rem 0.39rem; /* DSL: 367-340=27px top; 42px left from card edge */
}

.expats__card-title {
  font-size: 0.2rem;
  font-weight: 500;
  color: #1d293d;
  line-height: 0.32rem;
  margin: 0;
}

/* DSL: pill arrows, w=46, h=80, bg=#94D4FF, borderRadius 102px */
/* 组 152: x=189, y=2937; 组 154: x=1678, y=2937 */
.expats__arrow {
  position: absolute;
  top: 50%;
  -ms-transform: translateY(-50%);
  transform: translateY(-50%);
  z-index: 10;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: opacity 0.2s;
}

.expats__arrow:hover {
  opacity: 0.8;
}

.expats__arrow-pill {
  display: -ms-flexbox;
  display: flex;
  -ms-flex-align: center;
  align-items: center;
  -ms-flex-pack: center;
  justify-content: center;
  width: 0.46rem;
  height: 0.8rem;
  background-color: #94d4ff;
  border-radius: 1.02rem;
}

.expats__arrow--prev {
  left: -0.65rem;
}

.expats__arrow--next {
  right: -0.65rem;
  left: auto;
}

/* === Swiper 通用覆盖 === */
.activities-swiper .swiper-wrapper,
.videos-swiper .swiper-wrapper,
.expats-swiper .swiper-wrapper {
  transition-timing-function: ease-out;
}
.expats-swiper .expats__card-info {
  height: 1.56rem;
}

/* === 响应式 === */
@media (max-width: 1445px) {
  .expats__arrow--prev {
    left: 0.3rem;
  }

  .expats__arrow--next {
    left: auto;
    right: 0.3rem;
  }
}
@media (max-width: 1024px) {
  .latest-news {
    padding: 0.5rem 0;
  }
  .latest-news__featured {
    -ms-flex-direction: column;
    flex-direction: column;
  }

  .latest-news__featured-image {
    -ms-flex: none;
    flex: none;
    width: 100%;
  }

  .latest-news__featured-right {
    margin-left: 0;
    margin-top: 0.08rem;
  }

  .latest-news__cards {
    -ms-flex-direction: column;
    flex-direction: column;
  }

  .latest-news__card + .latest-news__card {
    margin-left: 0;
    margin-top: 0.25rem;
  }

  .latest-news__card {
    width: 100%;
  }

  .expats__carousel-wrap {
    overflow: hidden;
  }

  .expats-swiper .swiper-slide {
    width: 100%;
  }

  .expats__card {
    width: 100%;
  }

  .videos-swiper .swiper-slide a {
    pointer-events: auto;
  }

  /* Activities 移动端一屏展示两项 */
  .activities__carousel-wrap {
    width: 100%;
    padding: 0 0.25rem;
    box-sizing: border-box;
    text-align: center; /* 居中子元素 */
  }

  .activities-swiper {
    overflow: hidden;
    width: 100%;
    margin-bottom: 0.5rem;
  }

  .activities-swiper .swiper-slide {
    width: calc(50% - 0.08rem) !important; /* 一屏展示两项 */
  }
  .activities-swiper .swiper-slide.swiper-slide-prev,
  .activities-swiper .swiper-slide.swiper-slide-next {
    opacity: 0.5;
  }
  .activities__card {
    width: 100%;
  }

  /* 导航按钮在一行居中 */
  .activities__arrow {
    position: static !important;
    display: inline-block;
    margin: 0 0.1rem;
  }

  .activities__arrow--prev,
  .activities__arrow--next {
    right: auto !important;
  }
  .activities__arrow--next {
    -ms-transform: rotate(180deg);
    transform: rotate(180deg);
  }

  /* Videos 移动端一页展示 */
  .videos__stage {
    width: 100%;
    height: auto;
    padding: 0 0.25rem;
    box-sizing: border-box;
  }

  .videos-swiper {
    height: auto;
    overflow: hidden;
  }

  .videos-swiper .swiper-slide {
    width: 100% !important;
    height: auto;
  }

  /* .videos-swiper .swiper-slide-prev,
  .videos-swiper .swiper-slide-next {
    display: none;
  } */

  /* Videos 移动端装饰箭头大小适配 */
  .videos__deco {
    width: 0.4rem;
    height: 0.6rem;
  }
  .videos__deco--left {
    left: 0.4rem;
  }
  .videos__deco--right {
    right: 0.4rem;
  }
  .videos__deco svg {
    width: 100%;
    height: 100%;
  }

  /* Expats 移动端一页展示 */
  .expats__carousel-wrap {
    width: 100%;
    padding: 0 0.25rem;
    box-sizing: border-box;
  }

  .expats-swiper .swiper-slide {
    width: 100% !important;
  }

  .expats__card {
    width: 100%;
    height: auto;
  }

  .expats__card-image {
    width: 100%;
    height: auto;
  }

  /* Expats 移动端调整箭头位置 */
  .expats__arrow {
    width: 0.46rem;
    height: 0.8rem;
    top: 50%;
    -ms-transform: translateY(-50%);
    transform: translateY(-50%);
  }
  .expats__arrow svg {
    width: 0.2rem;
    height: 0.4rem;
  }
  .expats__arrow-pill {
    width: 0.46rem;
    height: 0.8rem;
  }

  .expats__arrow--prev {
    left: 0.5rem;
  }

  .expats__arrow--next {
    left: auto;
    right: 0.5rem;
  }
  .latest-news__header {
    padding: 0 0.25rem;
    box-sizing: border-box;
    margin-bottom: 0.3rem;
  }
  .latest-news__more {
    right: 0.25rem;
    font-size: 0.25rem;
  }
  .latest-news__text-item p,
  .latest-news__card p {
    font-size: 0.28rem;
    line-height: 0.4rem;
  }
  .latest-news__text-item .time {
    font-size: 0.2rem;
  }
  .latest-news__text-item {
    height: auto;
  }
  .activities {
    padding-top: 0.5rem;
  }
  .videos,
  .expats {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }
  .expats__card-info {
    padding: 0.25rem;
  }
  .expats__card-title {
    font-size: 0.28rem;
    line-height: 0.4rem;
  }
}
