/**
 * 首页专属样式（仅 index.html 引入，不影响子页面）
 * 轻奢金色外贸风 · 面向西非 B 端采购商
 */

/* 香料曲线暗纹（全站 :root 已定义 --spice-pattern，首页沿用） */
body[data-page="home"] {
  --home-spice-pattern: var(--spice-pattern);
}

/* page-main 底色与暗纹已由 styles.css 全站统一 */

/* ========== 一、首屏 Banner ========== */
body[data-page="home"] .hero-banner {
  background-color: var(--color-bg);
  background-image: none;
  background-size: cover;
  background-position: center 42%;
}

body[data-page="home"] .hero-banner:not(.hero-banner--cover)::before {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.96) 0%,
    rgba(255, 255, 255, 0.9) 50%,
    rgba(247, 247, 247, 0.85) 100%
  );
}

body[data-page="home"] .hero-banner:not(.hero-banner--cover)::after {
  opacity: 0.12;
  background-image: var(--home-spice-pattern);
}

body[data-page="home"] .hero-banner.hero-banner--cover .hero-cta.cta-jump:hover {
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.38);
}

/* 品牌副标已移至全站 Header 金线下方，隐藏 Banner 重复 eyebrow 避免压线 */
body[data-page="home"] .hero-eyebrow {
  display: none;
}

body[data-page="home"] .hero-title {
  font-size: clamp(2.1rem, 5.8vw, 3.55rem);
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #111;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
  overflow-wrap: normal;
}

body[data-page="home"] .hero-subtitle {
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  color: #a88428;
  letter-spacing: 0.16em;
  font-weight: 600;
  max-width: 36rem;
  margin-left: auto;
  margin-right: auto;
  overflow-wrap: normal;
}

/* 中文：词组不断开 */
html[lang="zh-CN"] body[data-page="home"] .hero-title,
html[lang="zh-CN"] body[data-page="home"] .hero-subtitle {
  word-break: keep-all;
}

/* 英文：禁止半截单词，移动端再启用软换行 */
html[lang="en"] body[data-page="home"] .hero-title,
html[lang="en"] body[data-page="home"] .hero-subtitle {
  word-break: normal;
  hyphens: none;
}

/* 英文首屏：统一居中轴线 + 字间距疏密对齐中文视觉 */
html[lang="en"] body[data-page="home"] .hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

html[lang="en"] body[data-page="home"] .hero-eyebrow,
html[lang="en"] body[data-page="home"] .hero-title,
html[lang="en"] body[data-page="home"] .hero-subtitle {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

html[lang="en"] body[data-page="home"] .hero-eyebrow {
  letter-spacing: 0.24em;
}

html[lang="en"] body[data-page="home"] .hero-title {
  letter-spacing: 0.06em;
}

html[lang="en"] body[data-page="home"] .hero-subtitle {
  letter-spacing: 0.08em;
}

html[lang="en"] body[data-page="home"] .hero-cta {
  align-self: center;
}

/* 关键短语不拆行（如「深耕西非」「自主品牌矩阵」） */
body[data-page="home"] .hero-nowrap-phrase {
  white-space: nowrap;
}

/* 移动端预设换行点（PC 端隐藏） */
body[data-page="home"] .hero-br-mobile,
body[data-page="home"] .hero-br-mobile--narrow {
  display: none;
}

/* PC 端：主副标题完整单行居中 */
@media (min-width: 769px) {
  body[data-page="home"] .hero-content {
    max-width: min(1360px, 98vw);
    overflow: visible;
  }

  body[data-page="home"] .hero-title,
  body[data-page="home"] .hero-subtitle {
    white-space: nowrap;
    max-width: none;
    overflow: visible;
    text-overflow: clip;
  }
}

body[data-page="home"] .hero-cta.cta-jump {
  gap: 0.65rem;
  padding-right: 0.72rem;
  box-shadow: 0 8px 26px rgba(212, 175, 55, 0.36);
}

body[data-page="home"] .hero-cta.cta-jump:hover {
  box-shadow: 0 14px 36px rgba(212, 175, 55, 0.48), 0 0 24px rgba(212, 175, 55, 0.22);
}

/* Hero CTA：玻璃圆环 + 双 chevron，呼吸光晕吸引视线 */
body[data-page="home"] .hero-cta .cta-jump-arrow {
  width: 2.1rem;
  height: 2.1rem;
  margin-left: 0.05rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.08);
  animation: hero-cta-arrow-ring 2.6s ease-in-out infinite;
}

body[data-page="home"] .hero-cta .cta-jump-arrow::before {
  left: 0.52rem;
}

body[data-page="home"] .hero-cta .cta-jump-arrow::after {
  left: 0.86rem;
}

body[data-page="home"] .hero-cta.cta-jump:hover .cta-jump-arrow {
  animation: none;
  background: rgba(255, 255, 255, 0.17);
  border-color: rgba(255, 255, 255, 0.46);
  box-shadow: 0 0 18px rgba(212, 175, 55, 0.38);
}

@keyframes hero-cta-arrow-ring {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.22);
    transform: scale(1);
  }

  50% {
    box-shadow:
      0 0 0 5px rgba(255, 255, 255, 0.05),
      0 0 14px rgba(212, 175, 55, 0.28);
    border-color: rgba(255, 255, 255, 0.4);
    transform: scale(1.04);
  }
}

@media (prefers-reduced-motion: reduce) {
  body[data-page="home"] .hero-cta .cta-jump-arrow {
    animation: none;
  }
}

/* 首屏底部：三层向下箭头滚动提示（间距分明，避免叠成「双 V」） */
body[data-page="home"] .hero-scroll-hint {
  position: absolute;
  bottom: 1.25rem;
  left: 50%;
  z-index: 2;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 2rem;
  height: auto;
  min-height: 3.1rem;
  padding: 0.2rem 0.45rem;
  border: none;
  border-radius: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.95);
  text-decoration: none;
  animation: hero-scroll-hint-bounce 2.4s ease-in-out infinite;
  transition: color 0.25s ease, transform 0.25s ease;
}

body[data-page="home"] .hero-scroll-hint:hover {
  color: #fff;
  animation: none;
  transform: translateX(-50%) translateY(3px);
}

body[data-page="home"] .hero-scroll-hint-chevrons {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.22rem;
  line-height: 0;
}

body[data-page="home"] .hero-scroll-hint-chevron {
  display: block;
  width: 0.68rem;
  height: 0.68rem;
  margin-top: 0;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.5;
  animation: hero-scroll-hint-chevron-fade 2.4s ease-in-out infinite;
}

body[data-page="home"] .hero-scroll-hint-chevron:first-child {
  animation-delay: 0s;
}

body[data-page="home"] .hero-scroll-hint-chevron:nth-child(2) {
  animation-delay: 0.2s;
}

body[data-page="home"] .hero-scroll-hint-chevron:nth-child(3) {
  animation-delay: 0.4s;
}

body[data-page="home"] .hero-banner:not(.hero-banner--cover) .hero-scroll-hint {
  color: var(--color-gold-dark);
}

@keyframes hero-scroll-hint-bounce {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(6px);
  }
}

@keyframes hero-scroll-hint-chevron-fade {
  0%, 100% {
    opacity: 0.42;
  }
  45%, 55% {
    opacity: 1;
  }
}

body[data-page="home"] #home-stats-panel {
  scroll-margin-top: calc(var(--nav-height) + 0.5rem);
}

/* ========== 二、数据实力栏 + 品牌矩阵（统一模块） ========== */
body[data-page="home"] .home-stats-panel {
  position: relative;
  padding: 3.5rem 1.5rem;
  background: linear-gradient(180deg, #fafaf8 0%, var(--page-surface) 100%);
  border-top: 1px solid rgba(212, 175, 55, 0.18);
  border-bottom: 1px solid rgba(212, 175, 55, 0.12);
  overflow: hidden;
}

/* 数据区不再叠暗纹 */
body[data-page="home"] .home-stats-panel::before {
  display: none;
}

body[data-page="home"] .home-stats-panel-inner {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
}

/* 四栏等宽数据网格 */
body[data-page="home"] .home-stats-panel .stats-bar-inner {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  max-width: 100%;
  margin: 0 auto 2.75rem;
  padding: 0 clamp(0.5rem, 2vw, 1.25rem);
  text-align: center;
}

body[data-page="home"] .home-stats-panel .stat-item {
  position: relative;
  padding: 0.75rem clamp(0.65rem, 1.6vw, 1.15rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  min-height: 6.25rem;
}

/* 细金色竖向分隔线：固定高度、垂直居中 */
body[data-page="home"] .home-stats-panel .stat-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 3.25rem;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(212, 175, 55, 0.45) 50%,
    transparent 100%
  );
}

/* 大号金色加粗数字（四栏完全一致） */
body[data-page="home"] .home-stats-panel .stat-value {
  display: block;
  width: 100%;
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 4.8vw, 2.85rem);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #b8962e;
  letter-spacing: 0.06em;
  line-height: 1.15;
  margin-bottom: 0.45rem;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
}

/* 小号灰金色说明（字号、行高统一，栏宽内自适应换行） */
body[data-page="home"] .home-stats-panel .stat-label {
  display: block;
  width: 100%;
  font-size: 0.84rem;
  font-weight: 400;
  color: #9a8b6a;
  letter-spacing: 0.05em;
  line-height: 1.5;
  min-height: calc(0.84rem * 1.5 * 2);
  margin: 0;
  padding: 0 0.15rem;
  word-break: keep-all;
  overflow-wrap: break-word;
}

/* 自主品牌矩阵区块 */
body[data-page="home"] .home-brands-block {
  text-align: center;
  padding: 0 1rem;
}

body[data-page="home"] .home-brands-eyebrow {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.32em;
  color: var(--color-gold-dark);
}

/* 极细金色装饰横线 */
body[data-page="home"] .home-brands-rule {
  width: min(320px, 72%);
  height: 1px;
  margin: 0 auto 1.25rem;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.55), transparent);
}

body[data-page="home"] .home-brands-rule--bottom {
  margin: 1.25rem auto 0;
  width: min(200px, 48%);
  opacity: 0.75;
}

/* 四品牌名一行 · 分隔 */
body[data-page="home"] .home-brands-names {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(0.95rem, 2.2vw, 1.22rem);
  font-weight: 600;
  letter-spacing: 0.14em;
  color: #1a1a1a;
  line-height: 1.8;
}

body[data-page="home"] .home-brands-sep {
  margin: 0 0.65rem;
}

/* ========== 三、关于我们 ========== */
body[data-page="home"] .section-about {
  padding-top: 4.25rem;
  padding-bottom: 4.25rem;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border-light);
}

body[data-page="home"] .section-about::before,
body[data-page="home"] .section-about::after {
  display: none;
}

body[data-page="home"] .about-copy {
  max-width: 44rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

body[data-page="home"] .about-body {
  width: 100%;
}

body[data-page="home"] .about-para {
  font-size: 1.02rem;
  line-height: 2.2;
  margin-bottom: 1.85rem;
  text-align: center;
  text-align-last: center;
}

body[data-page="home"] .about-headline {
  margin-bottom: 2.5rem;
}

/* 分隔线 + 居中 CTA，与上文轴线对齐 */
body[data-page="home"] .about-cta-bar {
  width: 100%;
  margin-top: 2.25rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(212, 175, 55, 0.22);
  display: flex;
  justify-content: center;
}

body[data-page="home"] .about-read-more {
  margin: 0;
}

/* ========== 四、核心优势 ========== */
body[data-page="home"] .section-alt {
  padding: 4rem 1.5rem;
  background: var(--page-surface);
  border-top: 1px solid var(--color-border-light);
}

body[data-page="home"] .advantage-grid {
  max-width: 1120px;
  margin: 0 auto;
  gap: 1.75rem;
}

body[data-page="home"] .advantage-card {
  border-radius: 4px;
  border: 1px solid var(--color-border);
  background: var(--color-bg);
  box-shadow: var(--shadow-soft);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

body[data-page="home"] .advantage-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(26, 26, 26, 0.06);
  border-color: var(--color-border-gold);
}

body[data-page="home"] .advantage-icon {
  background: var(--color-bg);
  border-color: var(--color-border-gold);
  box-shadow: none;
}

body[data-page="home"] .advantage-card p {
  line-height: 1.85;
}

body[data-page="home"] .adv-highlight {
  color: var(--color-gold-dark);
  font-weight: 600;
}

/* ========== 六、商务合作 ========== */
body[data-page="home"] .section-contact {
  padding: 3.25rem 1.5rem 4rem;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border-light);
}

body[data-page="home"] .section-contact .section-subtitle {
  margin-bottom: 1rem;
}

body[data-page="home"] .contact-cta {
  text-align: center;
  font-size: 0.98rem;
  color: #a88428;
  letter-spacing: 0.06em;
  line-height: 1.85;
  margin: 0 auto 1.75rem;
  max-width: 520px;
}

body[data-page="home"] .contact-box {
  padding: 2.25rem 2rem;
  border-radius: 4px;
  border: 1px solid var(--color-border);
  background: var(--color-bg);
  box-shadow: var(--shadow-soft);
}

body[data-page="home"] .contact-value {
  font-size: 1.2rem;
  font-weight: 700;
}

body[data-page="home"] .contact-value a {
  color: var(--color-gold-dark);
  text-shadow: 0 0 20px rgba(212, 175, 55, 0.25);
  transition: color var(--transition), text-shadow var(--transition);
}

body[data-page="home"] .contact-value a:hover {
  color: #a88428;
  text-shadow: 0 0 28px rgba(212, 175, 55, 0.4);
}

/* ========== 七、页脚（仅首页 enhanced 类） ========== */
body[data-page="home"] .site-footer--home {
  position: relative;
  overflow: hidden;
  border-top: 2px solid rgba(212, 175, 55, 0.35);
  padding: 3.5rem 1.5rem 2.75rem;
}

body[data-page="home"] .site-footer--home::before {
  display: none;
}

body[data-page="home"] .site-footer--home > * {
  position: relative;
  z-index: 1;
}

body[data-page="home"] .site-footer--home .footer-tagline {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  margin-bottom: 2rem;
  background: linear-gradient(145deg, #e8c84a, #d4af37);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

body[data-page="home"] .site-footer--home .footer-nav {
  gap: 2.5rem;
  margin-bottom: 1.75rem;
}

body[data-page="home"] .site-footer--home .footer-nav a {
  font-size: 0.92rem;
  letter-spacing: 0.08em;
}

body[data-page="home"] .site-footer--home .footer-copy {
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

/* ========== 首页区块统一留白 ========== */
body[data-page="home"] .section {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

body[data-page="home"] .section-inner {
  max-width: 1120px;
}

/* ========== 移动端 ========== */
@media (max-width: 768px) {
  body[data-page="home"] .hero-content {
    max-width: 100%;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  body[data-page="home"] .hero-title,
  body[data-page="home"] .hero-subtitle {
    white-space: normal;
    line-height: 1.65;
  }

  /* 启用均衡换行点 */
  body[data-page="home"] .hero-br-mobile {
    display: block;
  }

  body[data-page="home"] .hero-title {
    letter-spacing: 0.08em;
  }

  body[data-page="home"] .hero-subtitle {
    letter-spacing: 0.1em;
    font-size: 0.92rem;
    max-width: 22rem;
  }

  /* 英文移动端：仅在预设断点换行，避免半截单词 */
  html[lang="en"] body[data-page="home"] .hero-title,
  html[lang="en"] body[data-page="home"] .hero-subtitle {
    overflow-wrap: break-word;
  }

  html[lang="en"] body[data-page="home"] .hero-title {
    letter-spacing: 0.05em;
  }

  html[lang="en"] body[data-page="home"] .hero-subtitle {
    letter-spacing: 0.06em;
    max-width: 24rem;
  }

  html[lang="en"] body[data-page="home"] .hero-eyebrow {
    letter-spacing: 0.2em;
  }

  /* 极窄屏：副标题三段均衡拆分 */
  @media (max-width: 380px) {
    body[data-page="home"] .hero-br-mobile--narrow {
      display: block;
    }
  }

  body[data-page="home"] .home-stats-panel {
    padding: 2.75rem 1rem;
  }

  body[data-page="home"] .home-stats-panel .stats-bar-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 2.25rem;
    row-gap: 1.5rem;
  }

  /* 手机端：仅每行左栏右侧显示竖线 */
  body[data-page="home"] .home-stats-panel .stat-item:nth-child(2)::after,
  body[data-page="home"] .home-stats-panel .stat-item:nth-child(4)::after {
    display: none;
  }

  body[data-page="home"] .home-stats-panel .stat-item:not(:last-child)::after {
    height: 2.75rem;
  }

  body[data-page="home"] .home-stats-panel .stat-value {
    font-size: 2rem;
  }

  body[data-page="home"] .home-stats-panel .stat-label {
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    min-height: calc(0.8rem * 1.5 * 2);
  }

  body[data-page="home"] .home-brands-block {
    padding: 0 0.5rem;
  }

  /* 手机端：2×2 对称网格，避免 3+1 错落换行 */
  body[data-page="home"] .home-brands-names {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem 0.65rem;
    max-width: 17.5rem;
    margin: 0 auto;
    font-size: 0.84rem;
    letter-spacing: 0.1em;
    line-height: 1.45;
  }

  body[data-page="home"] .home-brands-names > span:not(.home-brands-sep) {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 2rem;
    padding: 0.15rem 0.2rem;
    text-align: center;
  }

  body[data-page="home"] .home-brands-sep {
    display: none;
  }

  html[lang="en"] body[data-page="home"] .home-brands-names {
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    max-width: 18rem;
  }

  body[data-page="home"] .about-cta-bar {
    margin-top: 1.75rem;
    padding-top: 1.5rem;
  }

  body[data-page="home"] .about-para {
    text-align: left;
    text-align-last: left;
    font-size: 0.98rem;
    line-height: 2.05;
  }

  body[data-page="home"] .section-about,
  body[data-page="home"] .section-alt,
  body[data-page="home"] .section-contact {
    padding-top: 3.25rem;
    padding-bottom: 3.25rem;
  }

  body[data-page="home"] .contact-box {
    padding: 1.75rem 1.25rem;
  }
}

/* ---------- Hero CTA ---------- */
body[data-page="home"] .hero-cta-row {
  display: flex;
  justify-content: center;
  margin-top: 0.25rem;
}

/* ---------- 首页私人订制 Teaser ---------- */
body[data-page="home"] .home-bespoke-teaser {
  background: linear-gradient(165deg, #12100d 0%, #1c1814 48%, #14110e 100%);
  border-top: 1px solid rgba(212, 175, 55, 0.2);
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  padding: 3.75rem 1.25rem;
  position: relative;
  overflow: hidden;
}

body[data-page="home"] .home-bespoke-teaser::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 70% 80% at 50% 0%, rgba(212, 175, 55, 0.1) 0%, transparent 65%);
  pointer-events: none;
}

body[data-page="home"] .home-bespoke-teaser-inner {
  position: relative;
  max-width: 40rem;
  margin: 0 auto;
  text-align: center;
}

body[data-page="home"] .home-bespoke-eyebrow {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  color: rgba(212, 175, 55, 0.9);
  text-transform: uppercase;
}

body[data-page="home"] .home-bespoke-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.65rem, 4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.96);
}

body[data-page="home"] .home-bespoke-desc {
  margin: 1.25rem auto 0;
  max-width: 34rem;
  font-size: clamp(0.92rem, 2vw, 1rem);
  line-height: 1.9;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.78);
}

body[data-page="home"] .home-bespoke-cta {
  margin-top: 2rem;
}

@media (max-width: 768px) {
  body[data-page="home"] .home-bespoke-teaser {
    padding: 3rem 1.15rem;
  }
}
