:root {
  /* 首页通用设计令牌，优先在这里统一尺寸与间距 */
  /* 页面与基础布局 */
  --home-stable-viewport-height: 100dvh;
  --home-stable-viewport-unit: 1dvh;
  --home-dynamic-viewport-height: 100dvh;
  --home-dynamic-viewport-unit: 1dvh;
  --default-page-height: var(--home-stable-viewport-height);
  --page-content-pad-min: 20px;
  --page-content-pad-max: 60px;
  --page-text-size: var(--font-title-lg);

  /* 首页背景素材 */
  --home-bg-fallback: #dceffd;
  --home-bg-position: center center;
  --home-bg-size: cover;
  --home-bg-repeat: no-repeat;
  --home-bg-product-image: url("../../../img/home/featuredProduct_bg.png");
  --home-bg-event-image: url("../../../img/home/event_bg.png");
  --home-bg-feature-image: url("../../../img/home/showcaseProduct_bg.png");

  /* 文化卡片模块 */
  --culture-card-height: clamp(112px, 13vh, 148px);
  --culture-card-radius: 24px;
  --culture-card-icon-size: clamp(28px, 2vw, 36px);
  --culture-card-front-bg: linear-gradient(180deg, #f2f9ff 0%, #e0f0ff 100%);
  --culture-card-front-pad-y: clamp(16px, 2vh, 24px);
  --culture-card-front-pad-x: clamp(20px, 2.4vw, 32px);
  --culture-overlay-gradient: linear-gradient(
    180deg,
    rgba(0, 136, 220, 0.76) 0%,
    rgba(68, 171, 233, 0.76) 25%,
    rgba(177, 225, 255, 0.76) 50%,
    rgba(96, 184, 239, 0.76) 75%,
    rgba(0, 136, 220, 0.76) 100%
  );

  /* 通用滚动动画（IO） */
  --io-duration-default: 700ms;
  --io-easing-default: ease;
  --io-delay-default: 0ms;
  --io-translate-zoom-in-up: 24px;
  --io-scale-zoom-in-up: 0.92;
  --io-scale-fade-zoom-in: 0.94;
  --io-translate-fade-right: 40px;
  --io-translate-fade-up: 40px;
  --io-reduced-motion-duration: 1ms;

  /* 新闻模块 */
  --news-grid-columns: 3;
  --news-grid-gap: clamp(18px, 2vw, 42px);

  /* 脚本参数（保持现有语义） */
  --wheel-scroll-step: 100;
  --io-threshold-default: 0.01;
  --page-content-padding-compensation: 15;
  --navbar-white-switch-offset: 450;
  --product-video-end-buffer: 0.05;
  --product-pin-scroll-distance: var(--home-stable-viewport-height);
  --product-observer-root-margin: 0px 0px -40% 0px;
}

/* 基础滚动与页面容器 */
html,
body {
  height: 100%;
  overflow: hidden;
}

/* 整页滚动容器 */
.fullpage-container {
  height: var(--home-stable-viewport-height);
  overflow-y: auto;
  scroll-behavior: smooth;
}

/* 通用页面层 */
.page {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: var(--page-height, var(--default-page-height));
  overflow: hidden;
}

.page-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.page-bg > :is(img, video) {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 页面内容统一入口，区块专属 padding 需要在各 section 内单独覆盖 */
.page-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  padding: var(--page-content-padding-top, 0px)
    clamp(var(--page-content-pad-min), 4vw, var(--page-content-pad-max))
    clamp(var(--page-content-pad-min), 4vw, var(--page-content-pad-max));
  text-align: center;
}

.page-text {
  width: 100%;
  max-width: min(100%, 1400px);
  margin: 0 auto;
  box-sizing: border-box;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.03em;
  font-size: var(--page-text-size);
  padding-inline: clamp(16px, 3vw, 48px);
}

/* 首屏 banner 文案以底边作为视觉基准上移，使底边落在版心中线 */
.fullpage-container > main > .page:first-child .page-text {
  transform: translateY(-50%);
}

/* 通用布局修饰类，只负责对齐，不负责具体间距 */
.page.align-left .page-content {
  justify-content: flex-start;
  text-align: left;
}

.page.align-right .page-content {
  justify-content: flex-end;
  text-align: right;
}

.page.align-top .page-content {
  align-items: flex-start;
}

.page.align-bottom .page-content {
  align-items: flex-end;
}

.footer-page {
  height: auto;
  min-height: 0;
  overflow: visible;
}

.footer-page .page-content {
  height: auto;
  min-height: 0;
  padding: 0;
}

.footer-page .page-content > * {
  width: 100%;
}

.footer {
  align-items: center;
  justify-content: center;
}

@media (max-width: 1199.98px) {
  /* 移动端继续保留 body 原生滚动，让浏览器地址栏按系统行为收起 */
  html,
  body {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
  }

  /* 移动端只保留结构包裹，不再让整页容器接管滚动 */
  .fullpage-container {
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  /* 移动端区块默认按内容撑开，避免非首屏继续占满整页 */
  .page {
    min-height: 0;
    height: auto;
    overflow: visible;
  }

  /* 首屏 Banner 继续保留一屏体感，避免品牌主视觉被内容压缩 */
  .fullpage-container > main > .page:first-child {
    min-height: var(--page-height, var(--default-page-height));
  }

  .page-content {
    min-height: inherit;
    height: auto;
    padding:
      clamp(96px, 16vw, 132px)
      clamp(16px, 5vw, 24px)
      clamp(32px, 9vw, 52px);
  }

  .page-text {
    font-size: var(--font-title-md);
    line-height: 1.18;
    white-space: normal;
    text-wrap: balance;
    padding-inline: 4px;
  }

  .page-text br {
    display: inline;
  }

  /* 页脚与联系区保持自然高度，避免被通用 page 最小高度撑出白边 */
  .footer-page,
  .section-contact {
    min-height: 0;
    height: auto;
  }

  .footer-page .page-content,
  .section-contact .page-content {
    min-height: 0;
  }
}