/* ============================================================
   壹号官网 · 共享样式 /assets/site.css
   结构：变量 → 重置 → 排版 → 布局容器 → 通用组件 → 页头 → 页脚 → 响应式
   ============================================================ */

/* ---------- 1. 设计变量 ---------- */
:root {
  /* 品牌色 */
  --ink: #0D1B2A;
  --navy-soft: #1B2E44;
  --orange: #FF5A1F;
  --orange-deep: #C93A0B;
  --cream: #F6EFE4;
  --cream-deep: #EDE3D3;
  --paper: #FFFDF8;
  --teal: #1FA88F;
  --teal-deep: #0E6B5C;
  --graphite: #242A33;
  --line: #C9BFAF;
  --burgundy: #5A1F2E;
  --indigo: #3B2B52;

  /* 字体 */
  --font-display: "HarmonyOS Sans SC", "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  /* 尺度 */
  --shell: 1260px;
  --pad: clamp(1rem, 4vw, 3rem);
  --radius: 2px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --lift-shadow: 0 14px 28px -22px rgba(13, 27, 42, .55);
  --line-soft: rgba(201, 191, 175, .22);
  --line-faint: rgba(201, 191, 175, .16);
  --cream-60: rgba(246, 239, 228, .62);
  --cream-45: rgba(246, 239, 228, .45);
}

/* ---------- 2. 重置 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--graphite);
  font-family: var(--font-body);
  font-size: clamp(1rem, .35vw + .9rem, 1.0625rem);
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.14;
  letter-spacing: -.025em;
  color: var(--ink);
}

p { margin: 0; }

ul, ol { margin: 0; padding: 0; list-style: none; }

img, svg, video { display: block; max-width: 100%; height: auto; }

a { color: var(--orange-deep); text-decoration-thickness: 1px; text-underline-offset: 3px; }

button { font: inherit; color: inherit; }

::selection { background: var(--orange); color: #fff; }

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

#main-content {
  display: block;
  scroll-margin-top: 6.5rem;
}

/* ---------- 3. 布局容器与网格 ---------- */
.yh-shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.yh-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1rem, 2.2vw, 1.75rem);
}

/* ---------- 4. 通用排版组件 ---------- */
.yh-section { padding-block: clamp(2.5rem, 6vw, 5rem); }
.yh-section--tight { padding-block: clamp(1.75rem, 4vw, 3rem); }

.yh-section--dark {
  background: var(--ink);
  color: var(--cream);
}
.yh-section--dark h1,
.yh-section--dark h2,
.yh-section--dark h3 { color: var(--cream); }

.yh-section--paper { background: var(--paper); }

.yh-section--divided { border-top: 1px solid var(--line); }

.yh-eyebrow {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: 0;
  font-family: var(--font-mono);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--orange-deep);
}
.yh-eyebrow::before {
  content: "";
  flex: none;
  width: 1.6rem;
  height: 1px;
  background: currentColor;
}

.yh-index {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .14em;
  color: var(--orange-deep);
}

.yh-rule {
  height: 1px;
  margin: 0;
  border: 0;
  background: var(--line);
}

.yh-prose {
  max-width: 44em;
  color: var(--graphite);
  font-size: 1.0625rem;
  line-height: 1.8;
}
.yh-prose > * + * { margin-top: 1.05em; }
.yh-prose h2, .yh-prose h3 { margin-top: 1.9em; color: var(--ink); }
.yh-prose ul { padding-left: 0; }
.yh-prose li { position: relative; padding-left: 1.4rem; }
.yh-prose li + li { margin-top: .45em; }
.yh-prose li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .76em;
  width: .62rem;
  height: 1px;
  background: var(--orange);
}

/* ---------- 5. 状态标签 ---------- */
.yh-tag {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .3rem .55rem;
  border: 1px solid currentColor;
  border-radius: var(--radius);
  background: transparent;
  font-family: var(--font-mono);
  font-size: .7rem;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: .1em;
  color: var(--graphite);
  white-space: nowrap;
}
.yh-tag--update {
  color: var(--teal-deep);
  background: rgba(31, 168, 143, .1);
  border-color: rgba(14, 107, 92, .38);
}
.yh-tag--notice {
  color: var(--orange-deep);
  background: rgba(255, 90, 31, .09);
  border-color: rgba(201, 58, 11, .34);
}
.yh-tag--on-dark {
  color: var(--cream);
  background: transparent;
  border-color: rgba(246, 239, 228, .4);
}

/* ---------- 6. 卡片与按钮 ---------- */
.yh-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.1rem, 2.2vw, 1.6rem);
  transition: transform .18s var(--ease), border-color .18s var(--ease), box-shadow .18s var(--ease);
}
.yh-card:hover {
  transform: translateY(-2px);
  border-color: var(--orange);
  box-shadow: var(--lift-shadow);
}

.yh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  min-height: 46px;
  padding: .7rem 1.35rem;
  border: 1px solid var(--orange);
  border-radius: var(--radius);
  background: var(--orange);
  color: #fff;
  font-family: var(--font-body);
  font-size: .98rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background .18s var(--ease), border-color .18s var(--ease), color .18s var(--ease), transform .18s var(--ease);
}
.yh-btn:hover {
  background: var(--orange-deep);
  border-color: var(--orange-deep);
  transform: translateY(-2px);
}
.yh-btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.yh-btn--ghost:hover {
  background: var(--paper);
  color: var(--orange-deep);
  border-color: var(--orange);
}
.yh-btn--on-dark {
  background: transparent;
  color: var(--cream);
  border-color: rgba(246, 239, 228, .45);
}
.yh-btn--on-dark:hover {
  background: var(--orange);
  border-color: var(--orange);
  color: #fff;
}

/* ---------- 7. 面包屑 ---------- */
.yh-crumb {
  padding-block: 1.1rem;
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .1em;
  color: rgba(36, 42, 51, .62);
}
.yh-crumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
}
.yh-crumb__item {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}
.yh-crumb__item + .yh-crumb__item::before {
  content: "/";
  color: var(--line);
}
.yh-crumb__item a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .16s var(--ease), border-color .16s var(--ease);
}
.yh-crumb__item a:hover {
  color: var(--orange-deep);
  border-bottom-color: currentColor;
}
.yh-crumb__item[aria-current="page"] { color: var(--ink); }

/* ---------- 8. 图片容器基础规则 ---------- */
.yh-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--navy-soft);
}
.yh-media--wide { aspect-ratio: 21 / 9; }
.yh-media--square { aspect-ratio: 1 / 1; }
.yh-media--portrait { aspect-ratio: 4 / 5; }

.yh-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.96);
}

.yh-media__placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1rem;
  background:
    repeating-linear-gradient(135deg, rgba(201, 191, 175, .14) 0 1px, transparent 1px 13px),
    var(--navy-soft);
  color: rgba(246, 239, 228, .55);
  font-family: var(--font-mono);
  font-size: .72rem;
  line-height: 1.6;
  letter-spacing: .12em;
  text-align: center;
}

.yh-media__caption {
  display: block;
  margin-top: .6rem;
  font-family: var(--font-mono);
  font-size: .72rem;
  line-height: 1.6;
  letter-spacing: .06em;
  color: rgba(36, 42, 51, .6);
}

/* ---------- 9. 跳转链接与滚动进度 ---------- */
.yh-skip {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 200;
  padding: .8rem 1.25rem;
  background: var(--orange);
  color: #fff;
  font-family: var(--font-mono);
  font-size: .8rem;
  letter-spacing: .08em;
  text-decoration: none;
  transform: translateY(-130%);
  transition: transform .16s var(--ease);
}
.yh-skip:focus,
.yh-skip:focus-visible {
  transform: translateY(0);
  outline-color: var(--cream);
}

.yh-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 210;
  width: 100%;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: 0 50%;
  pointer-events: none;
}

/* ---------- 10. 页头 ---------- */
.yh-header {
  position: relative;
  z-index: 90;
  background: var(--ink);
  color: var(--cream);
  border-bottom: 1px solid var(--line-soft);
}

.yh-header__top {
  background: var(--ink);
  border-bottom: 1px solid var(--line-faint);
}
.yh-header__top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 3rem;
  padding-block: .4rem;
}

/* 品牌 */
.yh-brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}
.yh-brand__mark {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.1rem;
  height: 2.1rem;
  border: 1px solid var(--orange);
  color: var(--orange);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  border-radius: var(--radius);
  transition: background .18s var(--ease), color .18s var(--ease);
}
.yh-brand:hover .yh-brand__mark {
  background: var(--orange);
  color: var(--ink);
}
.yh-brand__text {
  display: block;
  min-width: 0;
}
.yh-brand__name {
  display: block;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: .01em;
  color: var(--cream);
}
.yh-brand__line {
  display: block;
  font-family: var(--font-body);
  font-size: .76rem;
  font-weight: 300;
  line-height: 1.5;
  letter-spacing: .04em;
  color: var(--cream-60);
}

/* 上层右侧信息 */
.yh-header__meta {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .06em;
}
.yh-status {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  color: rgba(246, 239, 228, .72);
  white-space: nowrap;
}
.yh-status__dot {
  width: .45rem;
  height: .45rem;
  flex: none;
  background: var(--teal);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(31, 168, 143, .18);
}
.yh-header__link {
  color: var(--orange);
  text-decoration: none;
  padding-bottom: .12rem;
  border-bottom: 1px solid rgba(255, 90, 31, .42);
  transition: color .16s var(--ease), border-color .16s var(--ease);
}
.yh-header__link:hover {
  color: var(--cream);
  border-bottom-color: var(--cream);
}

/* 下层导航条 */
.yh-header__bar { background: var(--ink); }
.yh-header__bar-inner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-height: 3.6rem;
}

.yh-navtoggle {
  display: none;
  align-items: center;
  gap: .6rem;
  padding: .6rem .8rem;
  background: transparent;
  color: var(--cream);
  border: 1px solid rgba(201, 191, 175, .34);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .1em;
  cursor: pointer;
  transition: border-color .16s var(--ease), color .16s var(--ease);
}
.yh-navtoggle:hover {
  border-color: var(--orange);
  color: var(--orange);
}
.yh-navtoggle__bars {
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  width: 1.05rem;
  height: .72rem;
}
.yh-navtoggle__bars span {
  display: block;
  height: 1px;
  background: currentColor;
  transition: transform .18s var(--ease), opacity .18s var(--ease);
}
.yh-navtoggle[aria-expanded="true"] .yh-navtoggle__bars span:nth-child(1) {
  transform: translateY(5.5px) rotate(45deg);
}
.yh-navtoggle[aria-expanded="true"] .yh-navtoggle__bars span:nth-child(2) {
  opacity: 0;
}
.yh-navtoggle[aria-expanded="true"] .yh-navtoggle__bars span:nth-child(3) {
  transform: translateY(-5.5px) rotate(-45deg);
}
.yh-navtoggle__label { line-height: 1; }

.yh-nav { min-width: 0; }
.yh-nav__list {
  display: flex;
  align-items: center;
  gap: .1rem;
}
.yh-nav__link {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: .45rem;
  padding: .9rem .62rem;
  color: rgba(246, 239, 228, .82);
  font-family: var(--font-body);
  font-size: .95rem;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: color .16s var(--ease);
}
.yh-nav__index {
  font-family: var(--font-mono);
  font-size: .62rem;
  font-weight: 500;
  letter-spacing: .1em;
  color: rgba(246, 239, 228, .36);
  transition: color .16s var(--ease);
}
.yh-nav__link::after {
  content: "";
  position: absolute;
  left: .62rem;
  right: .62rem;
  bottom: .48rem;
  height: 1px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform .18s var(--ease);
}
.yh-nav__link:hover { color: var(--cream); }
.yh-nav__link:hover::after { transform: scaleX(1); }
.yh-nav__link:hover .yh-nav__index { color: var(--orange); }
.yh-nav__link[aria-current="page"] { color: var(--cream); }
.yh-nav__link[aria-current="page"]::after { transform: scaleX(1); }
.yh-nav__link[aria-current="page"] .yh-nav__index { color: var(--orange); }

.yh-quick {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-left: auto;
}
.yh-quick__item {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem .9rem;
  border: 1px solid rgba(201, 191, 175, .34);
  border-radius: var(--radius);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: .82rem;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color .16s var(--ease), background .16s var(--ease), color .16s var(--ease);
}
.yh-quick__item:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: rgba(255, 90, 31, .08);
}
.yh-quick__item--accent {
  background: var(--orange);
  border-color: var(--orange);
  color: #fff;
}
.yh-quick__item--accent:hover {
  background: var(--orange-deep);
  border-color: var(--orange-deep);
  color: #fff;
}

/* ---------- 11. 页脚 ---------- */
.yh-footer {
  margin-top: clamp(2.5rem, 6vw, 5rem);
  background: var(--ink);
  color: var(--cream);
  border-top: 1px solid var(--line-soft);
}

.yh-footer__inner {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(0, 2.4fr);
  gap: clamp(1.75rem, 4vw, 3.5rem);
  padding-block: clamp(2.25rem, 5vw, 3.75rem) clamp(1.75rem, 4vw, 2.75rem);
}

.yh-footer__brand { max-width: 27ch; }
.yh-footer .yh-brand__name { font-size: 1.15rem; }
.yh-footer .yh-brand__line { color: rgba(246, 239, 228, .58); }
.yh-footer .yh-brand__mark { width: 2.3rem; height: 2.3rem; }

.yh-footer__note {
  margin-top: 1.15rem;
  font-size: .875rem;
  line-height: 1.75;
  color: var(--cream-60);
}

.yh-footer__groups {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.6vw, 2rem);
}
.yh-footer__group { min-width: 0; }

.yh-footer__title {
  margin: 0 0 .85rem;
  padding-bottom: .6rem;
  border-bottom: 1px solid var(--line-soft);
  font-family: var(--font-mono);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .14em;
  color: var(--orange);
}

.yh-footer__list { display: grid; gap: .5rem; }
.yh-footer__link {
  display: inline-block;
  color: rgba(246, 239, 228, .8);
  font-family: var(--font-body);
  font-size: .95rem;
  line-height: 1.55;
  text-decoration: none;
  transition: color .16s var(--ease);
}
.yh-footer__link:hover { color: var(--orange); }

.yh-footer__datum {
  margin-top: 1rem;
  display: grid;
  gap: .6rem;
  font-family: var(--font-mono);
  font-size: .74rem;
  line-height: 1.7;
  letter-spacing: .02em;
  color: rgba(246, 239, 228, .72);
  overflow-wrap: anywhere;
}
.yh-footer__label {
  display: block;
  font-size: .64rem;
  letter-spacing: .16em;
  color: var(--cream-45);
}

.yh-footer__base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1.5rem;
  padding-block: 1.1rem;
  border-top: 1px solid var(--line-faint);
}
.yh-footer__meta {
  margin: 0;
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .08em;
  color: rgba(246, 239, 228, .48);
}

/* ---------- 12. 滚动显现 ---------- */
.yh-js [data-reveal] {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .42s var(--ease), transform .42s var(--ease);
}
.yh-js [data-reveal][data-revealed] {
  opacity: 1;
  transform: none;
}

/* ---------- 13. 响应式：平板 ---------- */
@media (max-width: 1080px) {
  .yh-nav__link { padding-inline: .48rem; font-size: .9rem; }
  .yh-nav__link::after { left: .48rem; right: .48rem; }
  .yh-quick__item { padding: .5rem .7rem; font-size: .78rem; }
  .yh-footer__groups { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.6rem 1.25rem; }
}

/* ---------- 14. 响应式：移动导航断点 ---------- */
@media (max-width: 899px) {
  .yh-header__bar-inner {
    flex-wrap: wrap;
    gap: .6rem;
    padding-block: .65rem;
  }
  .yh-navtoggle { display: inline-flex; }

  .yh-nav {
    order: 3;
    flex: 1 0 100%;
    display: none;
    margin-top: .35rem;
    border-top: 1px solid var(--line-faint);
    padding-top: .35rem;
  }
  .yh-nav[data-open] { display: block; }

  .yh-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .yh-nav__item + .yh-nav__item { border-top: 1px solid var(--line-faint); }
  .yh-nav__link {
    width: 100%;
    justify-content: space-between;
    align-items: center;
    padding: .95rem .2rem;
    font-size: 1rem;
  }
  .yh-nav__link::after { display: none; }
  .yh-nav__link[aria-current="page"] {
    color: var(--orange);
    background: rgba(255, 90, 31, .07);
  }
  .yh-nav__link[aria-current="page"] .yh-nav__index { color: var(--orange); }

  .yh-footer__inner { grid-template-columns: 1fr; }
  .yh-footer__brand { max-width: none; }
}

/* ---------- 15. 响应式：手机 ---------- */
@media (max-width: 640px) {
  .yh-brand__mark { width: 1.9rem; height: 1.9rem; font-size: .9rem; }
  .yh-brand__name { font-size: .98rem; }
  .yh-brand__line { font-size: .72rem; }
  .yh-header__meta { gap: .7rem; font-size: .7rem; }
  .yh-status { display: none; }
  .yh-quick { gap: .4rem; }
  .yh-quick__item { padding: .48rem .6rem; font-size: .75rem; }
  .yh-navtoggle { padding: .55rem .65rem; }
  .yh-footer__groups { grid-template-columns: 1fr; gap: 1.6rem; }
  .yh-footer__base { flex-direction: column; align-items: flex-start; }
  .yh-crumb { font-size: .68rem; }
}

@media (max-width: 400px) {
  .yh-navtoggle__label { display: none; }
  .yh-brand__line { display: none; }
}

/* ---------- 16. 减少动效 ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }

  .yh-js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  .yh-card:hover,
  .yh-btn:hover,
  .yh-quick__item:hover {
    transform: none;
  }
}
