/* =========================================================
   易发游戏老版 CN官网 · 共享样式 /assets/site.css
   夜间版本档案馆：深空黑长卷 + 年度渐变色带 + 粗野主义说明牌
   ========================================================= */

/* ---------- 1. Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 110px;
}

body,
h1, h2, h3, h4, p, ul, ol, li, figure, blockquote, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

a { color: inherit; text-decoration: none; }

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

:where(a, button, [tabindex]):focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* ---------- 2. 变量 ---------- */
:root {
  --ink: #0A0C10;
  --archive: #171C23;
  --iron: #2A323C;
  --paper: #EFE7D8;
  --muted: #B9B2A4;
  --cyan: #35F0DC;
  --signal: #FF7A2B;
  --amber: #F2C14E;
  --y2021: #7A5CFF;
  --y2022: #3B8DFF;
  --y2023: #35F0DC;
  --y2024: #FF7A2B;

  --glow: rgba(53, 240, 220, .14);
  --shadow-hard: 6px 6px 0 rgba(0, 0, 0, .55);
  --shadow-hard-sm: 3px 3px 0 rgba(0, 0, 0, .5);
  --shadow-soft: 0 20px 48px -30px rgba(0, 0, 0, .95);

  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --pill: 999px;

  --display: "Archivo Black", "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --body: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;

  --maxw: 1240px;
  --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- 3. 中文排版与底色 ---------- */
body {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: .01em;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: -8px 0;
  z-index: 0;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    180deg,
    rgba(239, 231, 216, .035) 0 1px,
    rgba(239, 231, 216, 0) 1px 4px
  );
  animation: yg-scan 12s linear infinite;
}

@keyframes yg-scan {
  from { transform: translateY(0); }
  to   { transform: translateY(4px); }
}

body > * { position: relative; z-index: 1; }

p, li { text-wrap: pretty; word-break: break-word; }
h1, h2, h3 { text-wrap: balance; }

h1 {
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -.02em;
  line-height: 1.08;
  font-size: clamp(2.5rem, 7.2vw, 5.5rem);
}

h2, h3 { font-family: var(--display); font-weight: 900; letter-spacing: -.02em; line-height: 1.2; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.6rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.5rem); }

strong, b { font-weight: 800; }

::selection { background: var(--cyan); color: var(--ink); }

/* ---------- 4. 跳转链接 ---------- */
.yg-skip {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 300;
  padding: 10px 20px;
  border-radius: var(--pill);
  background: var(--cyan);
  color: var(--ink);
  font-weight: 800;
  font-size: .9rem;
  transform: translateY(-180%);
  transition: transform .18s ease;
}
.yg-skip:focus { transform: translateY(0); }

/* ---------- 5. 头部 ---------- */
.yg-header {
  position: sticky;
  top: 0;
  z-index: 80;
  padding: 12px var(--gutter) 0;
  transition: padding .26s ease;
}
.yg-header.is-scrolled { padding-top: 6px; }

.yg-progress {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  overflow: hidden;
  background: rgba(42, 50, 60, .45);
}
.yg-progress__bar {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--y2021), var(--y2022), var(--y2023), var(--y2024));
  transition: width .12s linear;
}

.yg-capsule {
  position: relative;
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.8vw, 24px);
  padding: 10px clamp(14px, 2vw, 20px);
  background: rgba(23, 28, 35, .94);
  border: 2px solid var(--iron);
  border-radius: var(--pill);
  box-shadow: inset 0 0 0 1px rgba(53, 240, 220, .06), var(--shadow-soft);
  transition: padding .26s ease, border-color .26s ease;
}
.yg-header.is-scrolled .yg-capsule { padding-block: 6px; border-color: rgba(53, 240, 220, .35); }

/* 品牌 */
.yg-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  min-width: 0;
}
.yg-brand__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border-radius: 11px;
  background: linear-gradient(140deg, var(--y2023), var(--y2021));
  color: var(--ink);
  font-family: var(--display);
  font-weight: 900;
  font-size: 1.05rem;
  letter-spacing: -.02em;
  box-shadow: var(--shadow-hard-sm);
}
.yg-brand__text { display: flex; flex-direction: column; line-height: 1.16; min-width: 0; }
.yg-brand__name {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(.95rem, 1.2vw, 1.1rem);
  letter-spacing: -.01em;
  color: var(--paper);
  white-space: nowrap;
}
.yg-brand__note {
  font-family: var(--mono);
  font-size: .64rem;
  letter-spacing: .1em;
  color: var(--muted);
  white-space: nowrap;
}
.yg-brand--foot .yg-brand__mark { width: 44px; height: 44px; font-size: 1.2rem; border-radius: 13px; }
.yg-brand--foot .yg-brand__name { font-size: 1.15rem; white-space: normal; }

/* 导航 */
.yg-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.4vw, 18px);
  min-width: 0;
}
.yg-nav__list { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.yg-nav__link {
  display: block;
  padding: 8px 12px;
  border-radius: var(--pill);
  border: 2px solid transparent;
  font-size: .88rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  transition: color .16s ease, border-color .16s ease, background .16s ease;
}
.yg-nav__link:hover { color: var(--paper); border-color: var(--iron); }
.yg-nav__link[aria-current="page"] {
  background: var(--cyan);
  border-color: var(--cyan);
  color: var(--ink);
  font-weight: 800;
}
.yg-nav__actions { display: flex; align-items: center; gap: 8px; margin-left: 6px; }

/* 汉堡 */
.yg-nav-toggle {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  margin-left: auto;
  border: 2px solid var(--iron);
  border-radius: var(--r-sm);
  background: rgba(10, 12, 16, .6);
  transition: border-color .18s ease;
}
.yg-nav-toggle:hover { border-color: var(--cyan); }
.yg-nav-toggle__bar {
  position: absolute;
  left: 11px;
  right: 11px;
  height: 2px;
  border-radius: 2px;
  background: var(--paper);
  transition: transform .2s ease, opacity .2s ease;
}
.yg-nav-toggle__bar:nth-child(1) { top: 14px; }
.yg-nav-toggle__bar:nth-child(2) { top: 21px; }
.yg-nav-toggle__bar:nth-child(3) { top: 28px; }
.yg-nav-toggle[aria-expanded="true"] { border-color: var(--cyan); }
.yg-nav-toggle[aria-expanded="true"] .yg-nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.yg-nav-toggle[aria-expanded="true"] .yg-nav-toggle__bar:nth-child(2) { opacity: 0; }
.yg-nav-toggle[aria-expanded="true"] .yg-nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- 6. 按钮 ---------- */
.yg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 17px;
  border-radius: var(--pill);
  border: 2px solid transparent;
  font-size: .88rem;
  font-weight: 800;
  letter-spacing: .01em;
  white-space: nowrap;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, color .16s ease, border-color .16s ease;
}
.yg-btn--primary {
  background: var(--cyan);
  color: var(--ink);
  box-shadow: var(--shadow-hard-sm);
}
.yg-btn--primary:hover { transform: translate(2px, 2px); box-shadow: 1px 1px 0 rgba(0, 0, 0, .5); }
.yg-btn--ghost {
  border-color: var(--iron);
  color: var(--paper);
}
.yg-btn--ghost:hover { border-color: var(--amber); color: var(--amber); }
.yg-btn--sm { padding: 6px 13px; font-size: .78rem; }

/* ---------- 7. 容器 / 章节 ---------- */
.yg-container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.yg-container--narrow { max-width: 880px; }

.yg-section { padding-block: clamp(56px, 8vw, 110px); }

.yg-section__head { max-width: 780px; margin-bottom: clamp(28px, 4vw, 52px); }

.yg-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--cyan);
}
.yg-eyebrow::before {
  content: "";
  width: 26px;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--y2021), var(--y2023));
}

.yg-section__title {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(1.6rem, 3.4vw, 2.6rem);
  letter-spacing: -.02em;
  line-height: 1.2;
  margin-top: 14px;
}

.yg-section__lead {
  margin-top: 14px;
  max-width: 62ch;
  color: var(--muted);
  font-size: 1rem;
}

.yg-divider {
  height: 1px;
  border: 0;
  margin: 0;
  background: var(--iron);
}

/* ---------- 8. 网格与卡片 ---------- */
.yg-grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.yg-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.yg-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.yg-card {
  position: relative;
  background: var(--archive);
  border: 2px solid var(--iron);
  border-radius: var(--r-md);
  padding: clamp(18px, 2.4vw, 26px);
  box-shadow: var(--shadow-hard);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.yg-card:hover {
  transform: translate(3px, 3px);
  box-shadow: 2px 2px 0 rgba(0, 0, 0, .55);
  border-color: var(--cyan);
}

.yg-note {
  border-left: 3px solid var(--signal);
  background: rgba(255, 122, 43, .08);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  padding: 14px 18px;
  color: var(--paper);
  font-size: .95rem;
}

/* ---------- 9. 数据 / 标签 ---------- */
.yg-mono {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
}

.yg-stat {
  font-family: var(--mono);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -.03em;
  color: var(--cyan);
}

.yg-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border: 1px solid var(--iron);
  border-radius: var(--pill);
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .07em;
  color: var(--muted);
  white-space: nowrap;
}
.yg-tag--2021 { background: linear-gradient(90deg, #A38BFF, #7A5CFF); border-color: transparent; color: var(--ink); font-weight: 800; }
.yg-tag--2022 { background: linear-gradient(90deg, #7FB6FF, #3B8DFF); border-color: transparent; color: var(--ink); font-weight: 800; }
.yg-tag--2023 { background: linear-gradient(90deg, #7BFFF0, #35F0DC); border-color: transparent; color: var(--ink); font-weight: 800; }
.yg-tag--2024 { background: linear-gradient(90deg, #FFB27A, #FF7A2B); border-color: transparent; color: var(--ink); font-weight: 800; }

/* ---------- 10. 面包屑 ---------- */
.yg-breadcrumb {
  padding-block: clamp(20px, 3vw, 34px);
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .06em;
  color: var(--muted);
}
.yg-breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.yg-breadcrumb li + li::before { content: "/"; margin-right: 8px; color: var(--iron); }
.yg-breadcrumb a:hover { color: var(--cyan); }
.yg-breadcrumb [aria-current="page"] { color: var(--paper); }

/* ---------- 11. 图片容器 ---------- */
.yg-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 2px solid var(--iron);
  border-radius: var(--r-md);
  background:
    linear-gradient(160deg, rgba(53, 240, 220, .07), rgba(10, 12, 16, .2)),
    var(--archive);
}
.yg-media img,
.yg-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.yg-media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(53, 240, 220, .09) 0 1px,
    rgba(53, 240, 220, 0) 1px 7px
  );
}
.yg-media--card { aspect-ratio: 4 / 3; }
.yg-media--wide { aspect-ratio: 21 / 9; }
.yg-media--square { aspect-ratio: 1 / 1; }

/* ---------- 12. 锚点目录 ---------- */
.yg-anchor-nav {
  position: sticky;
  top: 118px;
  font-family: var(--mono);
  font-size: .78rem;
}
.yg-anchor-nav a {
  display: block;
  padding: 8px 0 8px 14px;
  border-left: 2px solid var(--iron);
  color: var(--muted);
  transition: color .16s ease, border-color .16s ease;
}
.yg-anchor-nav a:hover { color: var(--paper); border-left-color: var(--cyan); }
.yg-anchor-nav a.is-current { color: var(--cyan); border-left-color: var(--cyan); }

/* ---------- 13. 入场显现 ---------- */
.yg-reveal { opacity: 1; transform: none; }
.js .yg-reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .32s ease, transform .32s ease;
}
.js .yg-reveal.is-visible { opacity: 1; transform: none; }

/* ---------- 14. 页脚 ---------- */
.yg-footer {
  position: relative;
  margin-top: clamp(64px, 10vw, 140px);
  background: var(--archive);
  border-top: 2px solid var(--iron);
}
.yg-footer::before {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--y2021), var(--y2022), var(--y2023), var(--y2024));
}

.yg-footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 2fr) minmax(0, 1.25fr);
  gap: clamp(28px, 4vw, 56px);
  padding: clamp(40px, 6vw, 76px) 0 clamp(28px, 4vw, 46px);
}

.yg-footer__summary {
  margin-top: 18px;
  max-width: 34ch;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.75;
}

.yg-footer__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }

.yg-footer__nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.4vw, 32px);
}

.yg-footer__title {
  font-family: var(--mono);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--paper);
  margin-bottom: 14px;
}

.yg-footer__list li + li { margin-top: 10px; }
.yg-footer__list a {
  color: var(--muted);
  font-size: .94rem;
  border-bottom: 1px solid transparent;
  transition: color .16s ease, border-color .16s ease;
}
.yg-footer__list a:hover { color: var(--cyan); border-bottom-color: var(--cyan); }

.yg-contact-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  margin-bottom: 9px;
  background: rgba(10, 12, 16, .55);
  border: 1px solid var(--iron);
  border-radius: var(--r-sm);
}
.yg-contact-row__label {
  font-family: var(--mono);
  font-size: .68rem;
  letter-spacing: .1em;
  color: var(--muted);
}
.yg-contact-row__value {
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--paper);
  word-break: break-all;
  min-width: 0;
}
.yg-copy {
  flex: 0 0 auto;
  padding: 5px 9px;
  border: 1px solid var(--iron);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: .68rem;
  letter-spacing: .06em;
  color: var(--muted);
  transition: color .16s ease, border-color .16s ease, background .16s ease;
}
.yg-copy:hover { color: var(--cyan); border-color: var(--cyan); }
.yg-copy.is-copied { background: var(--cyan); border-color: var(--cyan); color: var(--ink); }

.yg-footer__address {
  margin-top: 12px;
  color: var(--muted);
  font-size: .85rem;
  line-height: 1.7;
}

.yg-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 22px;
  padding: 18px 0 30px;
  border-top: 1px solid var(--iron);
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--muted);
}
.yg-footer__copy { margin-right: auto; }
.yg-footer__icp { color: var(--muted); }

.yg-totop {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 15px;
  border: 2px solid var(--iron);
  border-radius: var(--pill);
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .06em;
  color: var(--paper);
  transition: transform .16s ease, color .16s ease, border-color .16s ease;
}
.yg-totop:hover { color: var(--cyan); border-color: var(--cyan); transform: translateY(-2px); }

/* ---------- 15. 响应式 ---------- */
@media (max-width: 1080px) {
  .yg-nav__link { padding: 7px 10px; font-size: .84rem; }
  .yg-footer__top { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); }
  .yg-footer__contact { grid-column: 1 / -1; }
}

@media (max-width: 960px) {
  .yg-nav-toggle { display: block; }

  .yg-nav {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    right: 0;
    margin-left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 14px;
    background: var(--archive);
    border: 2px solid var(--iron);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-hard);
  }
  .yg-nav[data-open] { display: flex; }
  .yg-nav__list { flex-direction: column; align-items: stretch; gap: 4px; }
  .yg-nav__link {
    padding: 12px 14px;
    border-radius: var(--r-sm);
    font-size: .95rem;
  }
  .yg-nav__actions { flex-direction: column; align-items: stretch; margin-left: 0; }
  .yg-nav__actions .yg-btn { width: 100%; }

  .yg-footer__top { grid-template-columns: minmax(0, 1fr); }
  .yg-footer__nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  h1 { font-size: clamp(2.1rem, 10vw, 3rem); }

  .yg-grid--2,
  .yg-grid--3 { grid-template-columns: minmax(0, 1fr); }

  .yg-brand__note { display: none; }
  .yg-footer__nav { grid-template-columns: minmax(0, 1fr); }
  .yg-footer__bottom { flex-direction: column; align-items: flex-start; }
  .yg-footer__copy { margin-right: 0; }
  .yg-anchor-nav { position: static; }
}

/* ---------- 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;
  }
  body::before { animation: none; }
  .js .yg-reveal { opacity: 1; transform: none; }
  .yg-card:hover,
  .yg-btn--primary:hover { transform: none; }
}
