/* ==========================================================================
   华体育网入口 · 共享样式表 /assets/site.css
   1 变量 · 2 重置 · 3 中文排版 · 4 布局原语 · 5 通用组件
   6 头部 · 7 页脚 · 8 图片容器 · 9 动效 · 10 响应式 · 11 无障碍
   ========================================================================== */

/* ---------- 1 变量 ---------- */
:root {
  --ink-900: #030A07;
  --ink-800: #07130F;
  --panel: #0B1F18;
  --archive: #102A21;
  --line: #1E3B2F;
  --white: #F2F6F3;
  --mist: #C9D6CE;
  --orange: #FF6B2C;
  --orange-soft: #FF9A62;
  --grey: #8FA79C;

  --font-display: "Barlow Condensed", "Oswald", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --header-h: 72px;
  --cut: 20px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --shell-max: 1320px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--ink-800);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -.015em;
  color: var(--white);
  text-wrap: balance;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

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

a { color: inherit; }

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

button { font: inherit; color: inherit; }

table { border-collapse: collapse; }

/* ---------- 3 中文排版 ---------- */
:lang(zh) { line-break: strict; }

body { font-feature-settings: "kern" 1; }

p, li, dd, dt, figcaption, td, th { overflow-wrap: break-word; }

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
}

.diff {
  font-weight: 700;
  color: var(--orange);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

/* ---------- 4 布局原语 ---------- */
.container {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 48px);
}

.section { padding-block: clamp(40px, 6vw, 80px); }
.section--tight { padding-block: clamp(24px, 3.6vw, 44px); }

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

.stack { display: flex; flex-direction: column; gap: clamp(12px, 1.6vw, 20px); }

.rule {
  height: 1px;
  border: 0;
  margin-block: clamp(24px, 4vw, 40px);
  background: repeating-linear-gradient(90deg, var(--line) 0 10px, transparent 10px 17px);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px 32px;
  margin-bottom: clamp(18px, 3vw, 32px);
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.section-head h2 { font-size: clamp(26px, 3.4vw, 44px); }

/* ---------- 5 通用组件 ---------- */
.panel {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  padding: clamp(18px, 2.2vw, 28px);
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%);
}

.panel--archive { background: var(--archive); }

.panel--plain {
  clip-path: none;
  border: 0;
  background: transparent;
  padding: 0;
}

.index-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--grey);
}

.index-label::before {
  content: "";
  display: block;
  width: 22px;
  height: 1px;
  background: var(--orange);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border: 1px solid var(--line);
  background: rgba(16, 42, 33, .6);
  color: var(--mist);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  white-space: nowrap;
}

.chip--live {
  color: var(--orange);
  border-color: rgba(255, 107, 44, .5);
  background: rgba(255, 107, 44, .08);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border: 1px solid transparent;
  background: var(--orange);
  color: #0A0F0C;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .06em;
  text-decoration: none;
  cursor: pointer;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%);
  transition: background 180ms var(--ease), color 180ms var(--ease), border-color 180ms var(--ease);
}

.btn:hover { background: var(--orange-soft); }

.btn--ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--mist);
}

.btn--ghost:hover {
  border-color: var(--orange);
  color: var(--white);
  background: rgba(255, 107, 44, .08);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--grey);
}

.breadcrumb a {
  color: var(--mist);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 160ms var(--ease), border-color 160ms var(--ease);
}

.breadcrumb a:hover {
  color: var(--white);
  border-bottom-color: var(--orange);
}

.breadcrumb__sep { color: var(--line); }

.table-base { width: 100%; font-size: 14px; }

.table-base th,
.table-base td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.table-base thead th {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--grey);
}

.table-base tbody th { font-weight: 500; color: var(--mist); }

/* ---------- 6 头部 ---------- */
.skip-link {
  position: fixed;
  left: 12px;
  top: -140px;
  z-index: 300;
  padding: 12px 20px;
  background: var(--orange);
  color: #08100C;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .04em;
  text-decoration: none;
  transition: top 160ms var(--ease);
}

.skip-link:focus,
.skip-link:focus-visible { top: 12px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: linear-gradient(180deg, #07130F 0%, rgba(7, 19, 15, .96) 100%);
  border-bottom: 1px solid var(--line);
  transition: border-color 200ms var(--ease);
}

.site-header[data-scrolled] { border-bottom-color: rgba(255, 107, 44, .42); }

.masthead {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  grid-template-areas: "brand nav search toggle";
  align-items: center;
  column-gap: clamp(10px, 2vw, 32px);
  min-height: var(--header-h);
  max-width: 1360px;
  margin-inline: auto;
  padding-inline: clamp(14px, 3vw, 40px);
}

.brand {
  grid-area: brand;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--white);
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  background: var(--orange);
  color: #08100C;
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 700;
  clip-path: polygon(0 0, 100% 0, 100% 72%, 72% 100%, 0 100%);
  transition: background 180ms var(--ease);
}

.brand:hover .brand__mark { background: var(--orange-soft); }

.brand__text { display: flex; flex-direction: column; gap: 2px; }

.brand__name {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .03em;
  line-height: 1.2;
}

.brand__sub {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--grey);
  line-height: 1.2;
}

.site-nav { grid-area: nav; justify-self: end; }

.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(0px, .6vw, 10px);
  counter-reset: navi;
}

.nav-item { counter-increment: navi; }

.nav-link {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 10px 12px 13px;
  color: var(--mist);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: .03em;
  text-decoration: none;
  transition: color 180ms var(--ease);
}

.nav-link::before {
  content: "0" counter(navi);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .2em;
  color: var(--grey);
  transition: color 180ms var(--ease);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 5px;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 200ms var(--ease), background 200ms var(--ease);
}

.nav-link:hover { color: var(--white); }
.nav-link:hover::before { color: var(--orange-soft); }
.nav-link:hover::after { transform: scaleX(1); background: var(--orange-soft); }

.nav-link[aria-current="page"] { color: var(--white); }
.nav-link[aria-current="page"]::before { color: var(--orange); }
.nav-link[aria-current="page"]::after { transform: scaleX(1); }

.masthead__search {
  grid-area: search;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  background: rgba(16, 42, 33, .55);
  color: var(--mist);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-decoration: none;
  white-space: nowrap;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%);
  transition: color 180ms var(--ease), border-color 180ms var(--ease), background 180ms var(--ease);
}

.masthead__search-label { letter-spacing: .16em; }

.masthead__search-arrow {
  color: var(--orange);
  font-size: 12px;
  transition: transform 180ms var(--ease);
}

.masthead__search:hover {
  color: var(--white);
  border-color: var(--orange);
  background: rgba(255, 107, 44, .1);
}

.masthead__search:hover .masthead__search-arrow { transform: translate(2px, -2px); }

.nav-toggle {
  grid-area: toggle;
  display: none;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--white);
  font-size: 12px;
  letter-spacing: .16em;
  cursor: pointer;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%);
  transition: color 180ms var(--ease), border-color 180ms var(--ease);
}

.nav-toggle:hover { border-color: var(--orange); color: var(--orange); }

.nav-toggle__bars {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  width: 16px;
}

.nav-toggle__bars i {
  display: block;
  height: 1.5px;
  background: currentColor;
  transition: transform 180ms var(--ease), opacity 180ms var(--ease);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(1) { transform: translateY(4.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars i:nth-child(3) { transform: translateY(-4.5px) rotate(-45deg); }

.read-progress {
  position: relative;
  height: 2px;
  background: rgba(30, 59, 47, .65);
  overflow: hidden;
}

.read-progress__bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--orange) 0%, var(--orange-soft) 100%);
  will-change: transform;
}

body[data-nav-open] { overflow: hidden; }

/* ---------- 7 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(48px, 8vw, 96px);
  background: var(--ink-900);
  border-top: 1px solid var(--line);
  color: var(--mist);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: min(340px, 48%);
  height: 2px;
  background: linear-gradient(90deg, var(--orange), rgba(255, 107, 44, 0));
}

.footer__inner {
  max-width: var(--shell-max);
  margin-inline: auto;
  padding: clamp(36px, 5vw, 64px) clamp(16px, 4vw, 48px) clamp(28px, 4vw, 48px);
  display: grid;
  grid-template-columns: 1.1fr .8fr 1.4fr;
  gap: clamp(28px, 4vw, 56px);
}

.footer__mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  background: var(--archive);
  color: var(--orange);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  clip-path: polygon(0 0, 100% 0, 100% 70%, 70% 100%, 0 100%);
}

.footer__name {
  margin: 14px 0 6px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: .04em;
  color: var(--white);
}

.footer__tag {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--grey);
}

.footer__nav { display: flex; flex-direction: column; gap: 10px; }

.footer__nav-title {
  margin: 0 0 4px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--grey);
}

.footer__link {
  width: fit-content;
  color: var(--mist);
  font-size: 14px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 160ms var(--ease), border-color 160ms var(--ease);
}

.footer__link:hover { color: var(--white); border-bottom-color: var(--orange); }

.footer__meta { display: grid; gap: 14px; margin: 0; }

.footer__meta-item {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.footer__meta-item:first-child { padding-top: 0; border-top: 0; }

.footer__meta dt {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--grey);
}

.footer__meta dd {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--mist);
}

.footer__base {
  max-width: var(--shell-max);
  margin-inline: auto;
  padding: 18px clamp(16px, 4vw, 48px) 28px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 28px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .1em;
}

.footer__legal { margin: 0; color: var(--grey); }
.footer__note { margin: 0; color: #6E8B7E; }

/* ---------- 8 图片容器 ---------- */
.figure {
  position: relative;
  display: block;
  margin: 0;
  overflow: hidden;
  background: var(--archive);
  aspect-ratio: var(--figure-ratio, 16 / 9);
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%);
}

.figure img,
.figure__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: saturate(.68) contrast(1.08) brightness(.82);
  transition: transform 420ms var(--ease), filter 420ms var(--ease);
}

.figure::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(3, 10, 7, 0) 42%, rgba(3, 10, 7, .78) 100%);
}

.figure:hover img,
.figure:hover .figure__img {
  transform: scale(1.02);
  filter: saturate(.86) contrast(1.06) brightness(.92);
}

.figure__caption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 1;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mist);
}

.figure--wide { --figure-ratio: 16 / 9; }
.figure--square { --figure-ratio: 1 / 1; }
.figure--tall { --figure-ratio: 3 / 4; }
.figure--banner { --figure-ratio: 21 / 9; }
.figure--plain::after { display: none; }

/* ---------- 9 动效 ---------- */
[data-js] [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 240ms var(--ease), transform 240ms var(--ease);
}

[data-js] [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@keyframes navPanelIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: none; }
}

/* ---------- 10 响应式 ---------- */
@media (min-width: 1180px) {
  body::before,
  body::after {
    content: "";
    position: fixed;
    top: 0;
    bottom: 0;
    width: 1px;
    background: var(--line);
    opacity: .75;
    pointer-events: none;
    z-index: 40;
  }
  body::before { left: 14px; }
  body::after { right: 14px; }
}

@media (max-width: 1180px) {
  :root { --header-h: 68px; }
  .nav-link { padding-inline: 9px; font-size: 13px; }
  .nav-link::after { left: 9px; right: 9px; }
}

@media (max-width: 1024px) {
  .footer__inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer__meta { grid-column: 1 / -1; }
}

@media (max-width: 899px) {
  :root { --header-h: 64px; --cut: 16px; }

  .masthead {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "brand toggle";
    min-height: var(--header-h);
  }

  .masthead__search { display: none; }

  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: fixed;
    inset: 0;
    z-index: 55;
    display: none;
    justify-self: stretch;
    background: var(--ink-900);
    border-top: 1px solid var(--line);
    padding: calc(var(--header-h) + 24px) clamp(18px, 6vw, 32px) 48px;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .site-nav[data-open] {
    display: block;
    animation: navPanelIn 200ms var(--ease) both;
  }

  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }

  .nav-link {
    flex-direction: row;
    align-items: baseline;
    gap: 16px;
    padding: 18px 2px;
    border-bottom: 1px solid var(--line);
    font-size: 20px;
    font-weight: 600;
    color: var(--white);
  }

  .nav-link::before { font-size: 11px; min-width: 26px; }
  .nav-link::after { display: none; }
  .nav-link[aria-current="page"] { color: var(--orange); }
  .nav-link[aria-current="page"]::before { color: var(--orange); }

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

  .brand__sub { display: none; }
}

@media (max-width: 720px) {
  .footer__inner { grid-template-columns: minmax(0, 1fr); }
  .footer__meta { grid-column: auto; }
  .footer__meta-item { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .footer__base { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 420px) {
  .brand__name { font-size: 14px; }
  .nav-toggle__label { display: none; }
}

/* ---------- 11 无障碍 ---------- */
:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

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

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

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

  [data-js] [data-reveal] { opacity: 1; transform: none; }
  .figure:hover img,
  .figure:hover .figure__img { transform: none; }
}
