/* ==========================================================================
   微馨生物 WEIXIN BIOTECH — 子页面扩展样式（产品中心 / 新闻动态 / 创始人 / 首页增量）
   依赖 style.css 设计变量与基础组件
   ========================================================================== */

/* ------------------------------------------------------------------
   1. 产品中心
   ------------------------------------------------------------------ */
.prod-subnav {
  position: sticky;
  top: var(--header-h);
  z-index: 40;
  background: rgba(251, 249, 244, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.prod-subnav__track {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 14px 0;
  scrollbar-width: none;
}

.prod-subnav__track::-webkit-scrollbar {
  display: none;
}

.prod-subnav__track a {
  flex: 0 0 auto;
  font-size: 13px;
  letter-spacing: 0.06em;
  padding: 8px 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  transition: all 0.25s var(--ease-soft);
  white-space: nowrap;
}

.prod-subnav__track a:hover {
  border-color: var(--gold-deep);
  color: var(--gold-deep);
}

.prod-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: clamp(36px, 5vw, 60px);
}

.prod-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.3s;
}

.prod-card:hover {
  transform: translateY(-5px);
  border-color: var(--line-gold);
  box-shadow: 0 22px 44px -22px rgba(6, 23, 29, 0.28);
}

.prod-card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--ivory);
}

.prod-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.prod-card:hover .prod-card__media img {
  transform: scale(1.04);
}

.prod-card__cat {
  position: absolute;
  top: 14px;
  left: 14px;
  font-size: 11px;
  letter-spacing: 0.14em;
  padding: 5px 12px;
  background: rgba(6, 23, 29, 0.78);
  color: var(--gold-light);
  border-radius: 999px;
}

.prod-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 24px 24px 22px;
}

.prod-card__title {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.35;
  color: var(--ink);
}

.prod-card__en {
  margin-top: 6px;
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.prod-card__desc {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
}

.prod-card__spec {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--line-strong);
  display: grid;
  gap: 8px;
}

.prod-card__spec li {
  position: relative;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
}

.prod-card__spec li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 7px;
  height: 7px;
  border: 1px solid var(--gold-deep);
  transform: rotate(45deg);
}

.spec-fold {
  margin-top: auto;
  padding-top: 16px;
}

.spec-fold summary {
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--gold-deep);
  border-bottom: 1px solid var(--line-gold);
  padding-bottom: 3px;
  transition: color 0.2s;
}

.prod-card__body .spec-fold {
  margin-top: 16px;
}

.spec-fold summary::-webkit-details-marker {
  display: none;
}

.spec-fold summary::after {
  content: "+";
  font-size: 15px;
  transition: transform 0.25s var(--ease-soft);
}

.spec-fold[open] summary::after {
  transform: rotate(45deg);
}

.spec-fold table {
  width: 100%;
  margin-top: 12px;
  border-collapse: collapse;
  font-size: 12.5px;
}

.spec-fold th,
.spec-fold td {
  border: 1px solid var(--line);
  padding: 6px 9px;
  text-align: left;
  vertical-align: top;
  line-height: 1.55;
}

.spec-fold th {
  background: var(--ivory);
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

.spec-fold td {
  color: var(--muted);
}

.spec-fold .reg-note {
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted-2);
}

.prod-note {
  margin-top: clamp(28px, 4vw, 44px);
  padding: 16px 20px;
  border-left: 2px solid var(--gold);
  background: var(--white);
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
}

/* 单品横向大卡：图左文右（--rev 为图右文左） */
.prod-card--wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 44fr) minmax(0, 56fr);
  align-items: stretch;
}

.prod-card--wide .prod-card__media {
  aspect-ratio: auto;
  min-height: 360px;
}

.prod-card--wide .prod-card__media img {
  position: absolute;
  inset: 0;
}

.prod-card--wide .prod-card__body {
  justify-content: center;
  padding: clamp(28px, 4vw, 52px) clamp(26px, 4.5vw, 58px);
}

.prod-card--wide .prod-card__title {
  font-size: clamp(21px, 2vw, 26px);
}

.prod-card--wide .prod-card__desc {
  font-size: 15px;
  max-width: 62ch;
}

.prod-card--wide--rev {
  grid-template-columns: minmax(0, 56fr) minmax(0, 44fr);
}

.prod-card--wide--rev .prod-card__media {
  order: 2;
}

.prod-card--wide--rev .prod-card__body {
  order: 1;
}

/* 产品演示视频 */
.prod-video {
  margin-top: clamp(36px, 5vw, 56px);
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(0, 5fr) minmax(0, 4fr);
  align-items: center;
}

.prod-video__frame {
  border: 1px solid var(--line-strong);
  background: var(--ink);
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.prod-video__frame video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.prod-video__body h3 {
  font-family: var(--serif);
  font-size: 24px;
  color: var(--ink);
}

.prod-video__body p {
  margin-top: 12px;
  font-size: 14px;
  line-height: 1.85;
  color: var(--muted);
}

/* 合作品牌 */
.brand-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: clamp(36px, 5vw, 60px);
}

.brand-cell {
  padding: 30px 28px;
  border: 1px solid var(--line-light);
  background: rgba(247, 244, 237, 0.03);
  transition: border-color 0.3s, transform 0.35s var(--ease);
}

.brand-cell:hover {
  border-color: var(--line-gold);
  transform: translateY(-4px);
}

.brand-cell__name {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--ivory);
}

.brand-cell__en {
  margin-top: 4px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.brand-cell__desc {
  margin-top: 14px;
  font-size: 13.5px;
  line-height: 1.8;
  color: rgba(247, 244, 237, 0.66);
}

/* ------------------------------------------------------------------
   2. 新闻动态
   ------------------------------------------------------------------ */
.news-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.news-meta__chip {
  font-size: 12px;
  letter-spacing: 0.1em;
  padding: 5px 14px;
  border: 1px solid var(--line-gold);
  color: var(--gold-deep);
  border-radius: 999px;
}

.news-meta__src {
  font-size: 12.5px;
  color: var(--muted-2);
  letter-spacing: 0.04em;
}

.news-article {
  max-width: 880px;
  margin: 0 auto;
}

.news-article__title {
  font-family: var(--serif);
  font-size: clamp(26px, 3.4vw, 38px);
  line-height: 1.4;
  color: var(--ink);
}

.news-article__rule {
  width: 64px;
  height: 3px;
  background: var(--gold);
  margin: 26px 0 34px;
}

.news-article__body p {
  font-size: 15.5px;
  line-height: 2.05;
  color: var(--text);
  margin-top: 18px;
  text-align: justify;
}

.news-article__body p strong {
  color: var(--ink);
}

.news-figure {
  margin: 30px 0 8px;
}

.news-figure img {
  width: 100%;
  display: block;
  border: 1px solid var(--line);
}

.news-figure figcaption {
  margin-top: 10px;
  font-size: 12.5px;
  color: var(--muted-2);
  letter-spacing: 0.03em;
  text-align: center;
}

.news-source {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px dashed var(--line-strong);
  font-size: 13px;
  color: var(--muted);
  line-height: 1.9;
}

.news-source a {
  color: var(--gold-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 动态图集 */
.news-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: clamp(36px, 5vw, 56px);
}

.news-shot {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--white);
}

.news-shot img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
  transition: transform 0.6s var(--ease);
}

.news-shot:hover img {
  transform: scale(1.05);
}

.news-shot figcaption {
  padding: 13px 16px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  border-top: 1px solid var(--line);
}

/* ------------------------------------------------------------------
   3. 创始人板块（关于微馨）
   ------------------------------------------------------------------ */
.founder-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
  margin-top: clamp(36px, 5vw, 60px);
}

.founder-figure {
  position: relative;
}

.founder-figure img {
  width: 100%;
  display: block;
  border: 1px solid var(--line-strong);
}

.founder-figure::after {
  content: "";
  position: absolute;
  inset: 14px -14px -14px 14px;
  border: 1px solid var(--line-gold);
  z-index: -1;
}

.founder-figure figcaption {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--muted-2);
  letter-spacing: 0.03em;
}

.founder-copy .quote-mark {
  font-family: var(--serif);
  font-size: 54px;
  line-height: 1;
  color: var(--gold);
}

.founder-copy h3 {
  font-family: var(--serif);
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 1.5;
  color: var(--ink);
  margin-top: 6px;
}

.founder-copy p {
  margin-top: 16px;
  font-size: 14.5px;
  line-height: 2;
  color: var(--muted);
  text-align: justify;
}

.founder-sign {
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.founder-sign__name {
  font-family: var(--serif);
  font-size: 17px;
  color: var(--ink);
}

.founder-sign__role {
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--gold-deep);
  border-left: 1px solid var(--line-strong);
  padding-left: 14px;
}

/* ------------------------------------------------------------------
   4. 首页增量：产品速览 + 新闻预览
   ------------------------------------------------------------------ */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
  margin-top: clamp(36px, 5vw, 60px);
}

.cat-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 26px 22px 24px;
  background: var(--white);
  border: 1px solid var(--line);
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.3s, box-shadow 0.4s var(--ease);
}

.cat-card:hover {
  transform: translateY(-5px);
  border-color: var(--line-gold);
  box-shadow: 0 20px 40px -22px rgba(6, 23, 29, 0.25);
}

.cat-card__num {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--gold-deep);
}

.cat-card__title {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--ink);
  line-height: 1.4;
}

.cat-card__count {
  margin-top: auto;
  font-size: 12.5px;
  color: var(--muted-2);
}

.cat-card__more {
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--gold-deep);
}

.news-preview {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(28px, 4vw, 52px);
  margin-top: clamp(36px, 5vw, 60px);
  align-items: stretch;
}

.news-feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  background: var(--white);
  border: 1px solid var(--line);
  text-decoration: none;
  overflow: hidden;
  transition: border-color 0.3s, transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.news-feature:hover {
  border-color: var(--line-gold);
  transform: translateY(-4px);
  box-shadow: 0 22px 44px -24px rgba(6, 23, 29, 0.28);
}

.news-feature__media img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  display: block;
}

.news-feature__body {
  padding: 26px 28px 28px;
}

.news-feature__meta {
  display: flex;
  gap: 14px;
  align-items: center;
  font-size: 12px;
  color: var(--muted-2);
  letter-spacing: 0.06em;
}

.news-feature__meta b {
  color: var(--gold-deep);
  font-weight: 600;
}

.news-feature__title {
  margin-top: 12px;
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.55;
  color: var(--ink);
}

.news-feature__desc {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-side {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 18px;
}

.news-thumb {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
}

.news-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-thumb figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 26px 16px 12px;
  font-size: 12.5px;
  color: var(--white);
  background: linear-gradient(to top, rgba(4, 17, 22, 0.82), transparent);
}

/* ------------------------------------------------------------------
   6. 首页灵动动效
   ------------------------------------------------------------------ */
html {
  scroll-behavior: smooth;
}

/* 顶部金色阅读进度条 */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 130;
  background: linear-gradient(90deg, var(--gold), var(--gold-light, #e2c9a0));
  transform: scaleX(0);
  transform-origin: 0 50%;
  pointer-events: none;
}

/* 章节编号入场金线扫过（绝对定位，不影响布局） */
.eyebrow__num {
  position: relative;
}

.eyebrow__num::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 0.7s var(--ease-soft) 0.15s;
}

.is-in .eyebrow__num::after {
  transform: scaleX(1);
}

/* 头条新闻：日期呼吸圆点 + 图片缓慢呼吸缩放 + 悬停放大 */
.news-feature__meta b {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.news-feature__meta b::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  animation: pulseDot 2.4s var(--ease-soft) infinite;
}

.news-feature__media img {
  animation: kenburns 18s var(--ease-soft) infinite alternate;
  transition: transform 0.6s var(--ease-soft);
  will-change: transform;
}

.news-feature:hover .news-feature__media img {
  animation: none;
  transform: scale(1.1);
}

.news-feature:hover .news-feature__title {
  color: var(--gold-deep);
}

.news-feature__title {
  transition: color 0.3s;
}

/* 侧栏缩略图：错峰轻微浮动 */
.news-side .news-thumb img {
  animation: thumbFloat 6.5s var(--ease-soft) infinite alternate;
}

.news-side .news-thumb:nth-child(2) img {
  animation-delay: -3.2s;
}

/* 分类卡「查看产品 →」悬停右移 */
.cat-card__more {
  transition: transform 0.3s var(--ease-soft);
}

.cat-card:hover .cat-card__more {
  transform: translateX(5px);
}

@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 rgba(200, 168, 120, 0.55); }
  70% { box-shadow: 0 0 0 9px rgba(200, 168, 120, 0); }
  100% { box-shadow: 0 0 0 0 rgba(200, 168, 120, 0); }
}

@keyframes kenburns {
  from { transform: scale(1); }
  to { transform: scale(1.06); }
}

@keyframes thumbFloat {
  from { transform: translateY(0); }
  to { transform: translateY(-5px); }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .scroll-progress {
    display: none;
  }

  .news-feature__media img,
  .news-side .news-thumb img,
  .news-feature__meta b::before {
    animation: none;
  }

  .eyebrow__num::after {
    transition: none;
  }
}

/* ------------------------------------------------------------------
   5. 响应式
   ------------------------------------------------------------------ */
@media (max-width: 1080px) {
  .prod-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .brand-strip {
    grid-template-columns: 1fr;
  }

  .cat-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .news-preview {
    grid-template-columns: 1fr;
  }

  .news-side {
    grid-template-rows: none;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 220px;
  }
}

@media (max-width: 760px) {
  .prod-grid {
    grid-template-columns: 1fr;
  }

  .prod-card--wide,
  .prod-card--wide--rev {
    grid-template-columns: 1fr;
  }

  .prod-card--wide .prod-card__media {
    aspect-ratio: 4 / 3;
    min-height: 0;
  }

  .prod-card--wide--rev .prod-card__media,
  .prod-card--wide--rev .prod-card__body {
    order: 0;
  }

  .prod-video {
    grid-template-columns: 1fr;
  }

  .cat-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .founder-grid {
    grid-template-columns: 1fr;
  }

  .founder-figure::after {
    display: none;
  }

  .news-gallery {
    grid-template-columns: 1fr;
  }

  .news-side {
    grid-template-columns: 1fr;
    grid-auto-rows: 220px;
  }

  .prod-subnav {
    top: calc(var(--header-h) - 8px);
  }
}
