/* 大榆「平台介绍」模块（原 CoreAi Why 位）— 全部作用域在 .coreai-why-scope */

.coreai-why-scope {
  --cai-text: #292e36;
  --cai-muted: #6b7485;
  --cai-red-deep: #cc2017;
  --cai-red: #e24737;
  --why-graphic-scale: clamp(0.34, 0.34 + (100vw - 480px) * 0.00035, 0.68);
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  color: var(--cai-muted);
  font-size: 15px;
  line-height: 1.75;
  font-weight: 400;
  background: #fbfbfc;
}

.coreai-why-scope *,
.coreai-why-scope *::before,
.coreai-why-scope *::after {
  box-sizing: border-box;
}

.coreai-why-scope.section_why {
  padding: clamp(2.5rem, 5vw, 5.5rem) 0 clamp(2rem, 4vw, 4rem);
}

.coreai-why-scope .padding-global {
  padding-left: clamp(16px, 4vw, 48px);
  padding-right: clamp(16px, 4vw, 48px);
}

.coreai-why-scope .container-large {
  width: 100%;
  max-width: min(1344px, 100%);
  margin: 0 auto;
}

.coreai-why-scope .why_flex-wrap {
  display: flex;
  flex-direction: column;
  gap: clamp(1.75rem, 3.5vw, 3rem);
  width: 100%;
}

/* 桌面：左文案 + 右趋势图；核心数据在下方整行（对齐 CoreAI why_btm） */
.coreai-why-scope .why_top-wrap {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: clamp(1.5rem, 3vw, 2rem);
  width: 100%;
}

@media screen and (min-width: 769px) and (max-width: 1199px) {
  .coreai-why-scope .why_title,
  .feature-section .section-heading .why_title,
  .metrics-section .metrics-heading .why_title,
  .about-section .section-heading .why_title,
  .biz-models-section .section-heading .why_title,
  .cases-section .section-heading .why_title {
    font-size: min(calc(clamp(40px, 5vw, 52px) - 1px), calc(min(500px, 50vw - 32px) * 0.08));
  }
}

@media screen and (min-width: 992px) {
  .coreai-why-scope .why_top-wrap {
    flex-direction: row;
    align-items: center;
    gap: clamp(1.5rem, 3.5vw, 3rem);
  }
}

.coreai-why-scope .why_content-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
  flex: 1 1 42%;
  max-width: 36rem;
  min-width: 0;
}

.coreai-why-scope .why_title,
.feature-section .section-heading .why_title,
.metrics-section .metrics-heading .why_title,
.about-section .section-heading .why_title,
.biz-models-section .section-heading .why_title,
.cases-section .section-heading .why_title {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin: 0;
  font-size: min(calc(clamp(42px, 4.2vw, 58px) - 1px), calc(min(620px, 50vw - max(48px, (100vw - 1440px) / 2)) * 0.08));
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: 0;
  color: #080808;
}

.cases-section .section-heading .why_title {
  align-items: flex-start;
  width: 100%;
}

.feature-section .section-heading .why_title {
  align-items: flex-start;
  width: auto;
}

#coreai-why-heading {
  display: block;
}

#coreai-why-heading .why_title-lead {
  display: inline;
}

#coreai-why-heading .why_title-mgroup {
  display: contents;
}

#coreai-why-heading .why_title-bridge {
  display: inline;
  color: #080808;
}

.coreai-why-scope .why_title-lead,
.coreai-why-scope .why_title-accent,
.feature-section .why_title-lead,
.feature-section .why_title-accent,
.metrics-section .why_title-lead,
.metrics-section .why_title-accent,
.about-section .why_title-lead,
.about-section .why_title-accent,
.biz-models-section .why_title-lead,
.biz-models-section .why_title-accent,
.cases-section .why_title-lead,
.cases-section .why_title-accent {
  display: block;
}

.coreai-why-scope .why_title-accent,
.feature-section .why_title-accent,
.metrics-section .why_title-accent,
.about-section .why_title-accent,
.biz-models-section .why_title-accent,
.cases-section .why_title-accent {
  background: linear-gradient(100deg, #cc2017 0%, #e24737 28%, #f3a18a 50%, #e24737 72%, #cc2017 100%);
  background-size: 200% 100%;
  animation: hero-subtitle-gradient-flow 5s ease-in-out infinite alternate;
  background-clip: text;
  color: transparent;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.coreai-why-scope .why_content-wrap > p {
  margin: 0;
  max-width: 54em;
  color: #626974;
  font-size: 16px;
  line-height: 1.75;
}

.coreai-why-scope .why_cta-row {
  margin-top: 0.35rem;
}

.coreai-why-scope .button.button-gradient {
  justify-content: center;
  gap: 12px;
  min-width: 0;
  min-height: 50px;
  padding: 6px 12px;
  background: linear-gradient(100deg, #cc2017 0%, #e24737 100%);
  box-shadow: 0 8px 22px rgba(204, 32, 23, .26);
}

.coreai-why-scope .button.button-gradient:hover {
  box-shadow: 0 12px 28px rgba(204, 32, 23, .36);
}

/* 右侧 2.5D 生态看板自适应容器 */
.coreai-why-scope .why_visual-panel {
  flex: 1 1 54%;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  background: transparent;
}

.coreai-why-scope .hero-highlights.coreai-why-highlights {
  position: static;
  top: auto;
  left: auto;
  right: auto;
  z-index: auto;
  transform: none;
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  width: 100%;
  max-width: 100%;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.coreai-why-scope .highlights-track,
.coreai-why-scope .highlights-marquee-group {
  display: contents;
}

.coreai-why-scope .highlights-marquee-group--clone {
  display: none;
}

@keyframes coreai-highlights-marquee {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}

.coreai-why-scope .hero-highlight__content strong,
.coreai-why-scope .hero-highlight__content span {
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

@media screen and (max-width: 768px) {
  .coreai-why-scope .why_visual-panel {
    order: 0;
    width: 100%;
  }

  .coreai-why-scope .why_content-wrap {
    max-width: none;
    flex: none;
  }

  .coreai-why-scope .hero-highlights.coreai-why-highlights {
    display: flex;
    align-items: center;
    overflow: hidden;
    width: calc(100% + 2 * clamp(16px, 4vw, 48px));
    max-width: none;
    margin: 0 calc(-1 * clamp(16px, 4vw, 48px));
    padding: 0.75rem 0 0.85rem;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 7%, #000 93%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 7%, #000 93%, transparent 100%);
  }

  .coreai-why-scope .highlights-track {
    display: flex;
    align-items: stretch;
    width: max-content;
    animation: coreai-highlights-marquee 24s linear infinite;
    will-change: transform;
  }

  .coreai-why-scope .highlights-marquee-group,
  .coreai-why-scope .highlights-marquee-group--clone {
    display: flex;
    flex-shrink: 0;
    align-items: center;
  }

  .coreai-why-scope .hero-highlight {
    flex: 0 0 auto;
    grid-column: auto !important;
    grid-template-columns: 28px auto 28px;
    width: auto;
    min-width: 176px;
    min-height: 82px;
    padding: 10px 18px;
  }

  .coreai-why-scope .hero-highlight::after {
    display: block !important;
    height: 38px;
  }

  @media (prefers-reduced-motion: reduce) {
    .coreai-why-scope .hero-highlights.coreai-why-highlights {
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
    }

    .coreai-why-scope .highlights-track {
      animation: none;
    }

    .coreai-why-scope .highlights-marquee-group--clone {
      display: none;
    }
  }

  .coreai-why-scope .hero-highlight__content strong {
    font-size: clamp(22px, 6.5vw, 30px);
  }

  .coreai-why-scope .hero-highlight__content span {
    font-size: 12px;
  }

  .coreai-why-scope .wheat-sprig {
    width: 26px;
    height: 26px;
  }

  .coreai-why-scope.section_why {
    padding-top: 2rem;
    padding-bottom: 1.5rem;
  }

  .coreai-why-scope .why_title,
  .feature-section .section-heading .why_title,
  .metrics-section .metrics-heading .why_title,
  .about-section .section-heading .why_title,
  .biz-models-section .section-heading .why_title,
  .cases-section .section-heading .why_title {
    font-size: min(calc(clamp(36px, 10vw, 48px) - 1px), calc((100vw - 32px) * 0.08));
  }

  .cases-section .section-heading .why_title {
    align-items: flex-start;
  }

  /* 行业痛点下半句在手机上保持一行；字号按标题栏宽度装下「保险+金融服务面临多重挑战」（12汉字+加号） */
  .work-flow .section-heading {
    container-type: inline-size;
  }

  .work-flow .why_title-accent {
    white-space: nowrap;
    font-size: calc(100cqi / 12.6);
  }

  /* 生态介绍在手机端按「专业赋能」后断行，下半句「构建保险+金融综合服务生态」（12汉字+加号）单行展示 */
  #coreai-why-heading {
    display: flex;
    flex-direction: column;
    width: 100%;
    container-type: inline-size;
  }

  #coreai-why-heading .why_title-lead {
    display: block;
  }

  #coreai-why-heading .why_title-mgroup {
    display: block;
    white-space: nowrap;
    font-size: min(calc(clamp(36px, 10vw, 48px) - 1px), calc(100cqi / 12.6));
    background: linear-gradient(100deg, #cc2017 0%, #e24737 28%, #f3a18a 50%, #e24737 72%, #cc2017 100%);
    background-size: 200% 100%;
    animation: hero-subtitle-gradient-flow 5s ease-in-out infinite alternate;
    background-clip: text;
    color: transparent;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
  }

  #coreai-why-heading .why_title-bridge {
    display: inline;
    color: inherit;
  }

  #coreai-why-heading .why_title-accent {
    display: inline;
    background: none;
    -webkit-text-fill-color: inherit;
    color: inherit;
    animation: none;
    font-size: inherit;
  }

  /* 业务模式下半句「直客服务与渠道协同双轮驱动」（13字）在手机上保持一行 */
  .biz-models-section .section-heading {
    container-type: inline-size;
    width: 100%;
  }

  .biz-models-section .why_title-accent {
    white-space: nowrap;
    font-size: min(calc(clamp(36px, 10vw, 48px) - 1px), calc(100cqi / 13));
  }

  /* 服务流程下半句按容器右缘断行，与下方流程卡片右缘对齐（不用 balance 提前折行） */
  .about-section .why_title-accent {
    text-wrap: wrap;
  }

  .coreai-why-scope .why_content-wrap > p {
    width: 100%;
    font-size: 14px;
    line-height: 1.7;
    text-align: justify;
    text-align-last: left;
    text-justify: inter-ideograph;
    line-break: strict;
  }

  .coreai-why-scope .button.button-gradient {
    min-width: 0;
    min-height: 42px;
    gap: 10px;
    padding: 5px 10px;
    font-size: 12px;
  }

  .coreai-why-scope .button.button-gradient .button-arrow {
    width: 30px;
    height: 30px;
  }
}