/* ============================================================
   米兰体育 MILAN · 共享站点样式 /assets/site.css
   暖纸 × 深墨 × 米兰红 × 荧光绿数据高亮
   ============================================================ */

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

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

body, h1, h2, h3, h4, h5, h6, p, ul, ol, li, figure, blockquote, dl, dd {
  margin: 0;
  padding: 0;
}

ul, ol { list-style: none; }

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

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

/* ---------- 2. 变量 ---------- */
:root {
  --milan-red: #9B1B30;
  --ink: #151515;
  --paper: #F3EDE1;
  --paper-white: #FFFDF8;
  --graphite: #2E2C2A;
  --steel: #736E66;
  --volt: #B8F24B;
  --amber: #C98A1E;
  --vermilion: #D34A3F;
  --grid: #D8CFC0;

  --font-display: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", sans-serif;
  --font-body: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", "Roboto Mono", ui-monospace, monospace;

  --fs-display-xl: clamp(44px, 7vw, 84px);
  --fs-display-l: clamp(34px, 4.4vw, 56px);
  --fs-heading-m: clamp(24px, 2.4vw, 34px);
  --fs-data-xl: clamp(40px, 6vw, 72px);
  --fs-body: clamp(16px, 1.05vw, 18px);
  --fs-small: 13px;

  --bw: 3px;
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 4px 4px 0 var(--ink);
  --r: 14px;
  --r-pill: 999px;
  --maxw: 1320px;
  --gutter: clamp(16px, 3.6vw, 40px);
  --ease: cubic-bezier(.22, .68, .24, 1);
}

/* ---------- 3. 基础与中文排版 ---------- */
body {
  min-height: 100vh;
  background-color: var(--paper);
  background-image:
    linear-gradient(to right, rgba(21, 21, 21, .045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(21, 21, 21, .045) 1px, transparent 1px);
  background-size: 72px 72px;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  text-underline-offset: 3px;
}

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

a { color: inherit; }

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

#main-content {
  display: block;
  scroll-margin-top: 110px;
}

/* ---------- 4. 布局骨架 ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.side-grid {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
}

.grid {
  display: grid;
  gap: clamp(16px, 2vw, 24px);
}

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

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 20px;
  flex-wrap: wrap;
  margin-bottom: clamp(18px, 2.4vw, 28px);
}

.section-head__title {
  font-size: var(--fs-heading-m);
  letter-spacing: -.015em;
}

/* ---------- 5. 排版工具 ---------- */
.display-xl {
  font-size: var(--fs-display-xl);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.035em;
}

.display-l {
  font-size: var(--fs-display-l);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -.025em;
}

.tilt { transform: skewX(-2deg); }

.mono,
[data-mono] {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: .02em;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.prose {
  max-width: 70ch;
  font-size: var(--fs-body);
  line-height: 1.78;
  color: var(--graphite);
}

.prose p + p { margin-top: 1em; }
.prose h2, .prose h3 { margin-block: 1.6em .6em; }
.prose a { color: var(--milan-red); text-decoration: underline; text-decoration-thickness: 2px; }

/* ---------- 6. 通用组件 ---------- */
.panel {
  background: var(--paper-white);
  border: var(--bw) solid var(--ink);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  padding: clamp(16px, 2.2vw, 26px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 22px;
  border: var(--bw) solid var(--ink);
  border-radius: var(--r-pill);
  background: var(--milan-red);
  color: var(--paper-white);
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: .01em;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform .16s var(--ease), box-shadow .16s var(--ease),
              background .16s var(--ease), color .16s var(--ease);
}

.btn:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }

.btn--ghost { background: var(--paper-white); color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--paper-white); }
.btn--ink { background: var(--ink); color: var(--paper-white); }
.btn--ink:hover { background: var(--milan-red); color: var(--paper-white); }
.btn--sm { padding: 9px 16px; font-size: 13px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 2px solid var(--ink);
  border-radius: var(--r-pill);
  background: var(--paper-white);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.chip--volt { background: var(--volt); }
.chip--amber { background: var(--amber); color: var(--paper-white); }
.chip--red { background: var(--vermilion); color: var(--paper-white); }
.chip--ink { background: var(--ink); color: var(--paper-white); }

.crumbs { font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em; }

.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.crumbs li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--steel);
}

.crumbs li + li::before { content: "/"; color: var(--grid); }

.crumbs a {
  color: var(--graphite);
  text-decoration: none;
  border-bottom: 2px solid var(--grid);
  transition: color .16s var(--ease), border-color .16s var(--ease);
}

.crumbs a:hover { color: var(--milan-red); border-color: var(--milan-red); }

.crumbs [aria-current="page"] {
  color: var(--ink);
  font-weight: 700;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--graphite);
}

.kicker::before {
  content: "";
  width: 18px;
  height: 3px;
  background: var(--milan-red);
}

.kicker--rail {
  writing-mode: vertical-rl;
  letter-spacing: .34em;
  padding-block: 6px;
}

.kicker--rail::before { width: 3px; height: 18px; }

/* 图片容器基础规则（页面阶段放置图片或占位） */
.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: var(--bw) solid var(--ink);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  background: var(--paper-white);
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame--square { aspect-ratio: 1 / 1; }
.media-frame--wide { aspect-ratio: 21 / 9; }
.media-frame--tall { aspect-ratio: 3 / 4; }

.media-frame__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(155, 27, 48, .1) 0 50%, transparent 50% 100%),
    repeating-linear-gradient(90deg, transparent 0 31px, var(--grid) 31px 32px),
    repeating-linear-gradient(0deg, transparent 0 31px, var(--grid) 31px 32px),
    var(--paper);
  color: var(--steel);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.media-frame__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 6px 12px;
  background: var(--ink);
  color: var(--paper-white);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  border-top-right-radius: 8px;
}

/* 滚动显现（由 JS 开启 html[data-js="on"] 后生效） */
html[data-js="on"] [data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}

html[data-js="on"] [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ---------- 7. 跳至正文 ---------- */
.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 12px 18px;
  background: var(--ink);
  color: var(--paper-white);
  border: var(--bw) solid var(--volt);
  border-radius: 10px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: top .18s var(--ease);
}

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

/* ---------- 8. 页头 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  padding: 14px var(--gutter) 18px;
  background:
    linear-gradient(to bottom,
      var(--paper) 0%,
      var(--paper) 58%,
      rgba(243, 237, 225, .86) 84%,
      rgba(243, 237, 225, 0) 100%);
}

.nav-shell {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: nowrap;
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  gap: 1px;
  flex: 0 0 auto;
  padding: 8px 16px 9px;
  background: var(--milan-red);
  color: var(--paper-white);
  border: var(--bw) solid var(--ink);
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}

.brand:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }

.brand__mark {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: .02em;
  transform: skewX(-3deg);
}

.brand__latin {
  margin-left: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  opacity: .92;
}

.brand__tag {
  font-size: 10.5px;
  letter-spacing: .06em;
  color: rgba(255, 253, 248, .92);
}

.nav-panel {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.nav {
  display: flex;
  align-items: center;
  padding: 6px;
  background: var(--paper-white);
  border: var(--bw) solid var(--ink);
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-sm);
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav__link {
  display: inline-block;
  padding: 9px 14px;
  border-radius: var(--r-pill);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--graphite);
  text-decoration: none;
  white-space: nowrap;
  transition: background .18s var(--ease), color .18s var(--ease), box-shadow .18s var(--ease);
}

.nav__link:hover { background: rgba(21, 21, 21, .07); color: var(--ink); }

.nav__link[aria-current="page"] {
  background: var(--ink);
  color: var(--paper-white);
  box-shadow: inset 0 -3px 0 var(--volt);
}

.nav__utility {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chip-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 15px;
  border: 2px solid var(--ink);
  border-radius: var(--r-pill);
  background: var(--paper-white);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
  text-decoration: none;
  white-space: nowrap;
  transition: transform .16s var(--ease), background .16s var(--ease), color .16s var(--ease);
}

.chip-btn:hover { background: var(--ink); color: var(--paper-white); transform: translateY(-1px); }

.chip-btn--accent { background: var(--volt); color: var(--ink); }
.chip-btn--accent:hover { background: var(--ink); color: var(--volt); }

.nav__toggle {
  display: none;
  align-items: center;
  gap: 9px;
  margin-left: auto;
  padding: 10px 16px;
  border: var(--bw) solid var(--ink);
  border-radius: var(--r-pill);
  background: var(--paper-white);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform .16s var(--ease), background .16s var(--ease);
}

.nav__toggle:active { transform: translate(2px, 2px); }

.nav__toggle-bars {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  background: var(--ink);
  transition: background .18s var(--ease);
}

.nav__toggle-bars::before,
.nav__toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  background: var(--ink);
  transition: transform .2s var(--ease), top .2s var(--ease);
}

.nav__toggle-bars::before { top: -5px; }
.nav__toggle-bars::after { top: 5px; }

.nav__toggle[aria-expanded="true"] .nav__toggle-bars { background: transparent; }
.nav__toggle[aria-expanded="true"] .nav__toggle-bars::before { top: 0; transform: rotate(45deg); }
.nav__toggle[aria-expanded="true"] .nav__toggle-bars::after { top: 0; transform: rotate(-45deg); }

.scroll-meter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 4px;
  pointer-events: none;
}

.scroll-meter__bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--milan-red) 0%, var(--vermilion) 55%, var(--volt) 100%);
  transition: transform .12s linear;
}

/* ---------- 9. 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(56px, 9vw, 120px);
  padding: clamp(36px, 5vw, 64px) var(--gutter) 0;
  background-color: var(--ink);
  background-image:
    linear-gradient(to right, rgba(216, 207, 192, .1) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(216, 207, 192, .1) 1px, transparent 1px);
  background-size: 56px 56px;
  color: var(--paper-white);
  border-top: 6px solid var(--milan-red);
  overflow: hidden;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr .8fr .8fr .8fr 1.3fr;
  gap: clamp(20px, 3vw, 40px);
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
}

.footer-brand__mark {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--paper-white);
  font-family: var(--font-display);
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 800;
  letter-spacing: -.02em;
  text-decoration: none;
  transform: skewX(-4deg);
}

.footer-brand__mark span {
  margin-left: 8px;
  color: var(--volt);
  font-family: var(--font-mono);
  font-size: .48em;
  font-weight: 600;
  letter-spacing: .18em;
  vertical-align: middle;
}

.footer-brand__note {
  max-width: 30ch;
  font-size: 13.5px;
  line-height: 1.75;
  color: #D6D0C4;
}

.footer-brand__tag {
  display: inline-block;
  margin-top: 14px;
  padding: 5px 12px;
  border: 2px solid rgba(184, 242, 75, .55);
  border-radius: var(--r-pill);
  color: var(--volt);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
}

.footer-col__title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--paper-white);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
}

.footer-col__title::before {
  content: "";
  width: 12px;
  height: 3px;
  background: var(--volt);
}

.footer-col__list { display: grid; gap: 2px; }

.footer-link {
  display: inline-block;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  color: #DAD4C9;
  font-size: 14px;
  text-decoration: none;
  transition: color .16s var(--ease), border-color .16s var(--ease), transform .16s var(--ease);
}

.footer-link:hover {
  color: var(--volt);
  border-color: var(--volt);
  transform: translateX(3px);
}

.footer-contact { display: grid; gap: 10px; }

.footer-contact__row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 13.5px;
  color: #DAD4C9;
}

.footer-contact__label {
  min-width: 34px;
  color: #A8A094;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.footer-contact__value { word-break: break-word; }

.footer-contact__note {
  margin-top: 2px;
  color: #A8A094;
  font-size: 12px;
  line-height: 1.6;
}

.copy-btn {
  padding: 4px 10px;
  border: 2px solid rgba(243, 237, 225, .35);
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--paper-white);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  cursor: pointer;
  transition: background .16s var(--ease), color .16s var(--ease), border-color .16s var(--ease);
}

.copy-btn:hover,
.copy-btn[data-copied="true"] {
  background: var(--volt);
  border-color: var(--volt);
  color: var(--ink);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  width: 100%;
  max-width: var(--maxw);
  margin: clamp(28px, 4vw, 48px) auto 0;
  padding-block: 18px 26px;
  border-top: 2px solid rgba(243, 237, 225, .18);
  color: #B9B2A6;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .04em;
}

.footer-legal--note { color: #8F887D; }

/* ---------- 10. 返回顶部 ---------- */
.to-top {
  position: fixed;
  right: clamp(14px, 3vw, 28px);
  bottom: clamp(14px, 3vw, 28px);
  z-index: 70;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 9px 12px;
  border: var(--bw) solid var(--paper-white);
  border-radius: 12px;
  background: var(--milan-red);
  color: var(--paper-white);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .12em;
  cursor: pointer;
  box-shadow: 4px 4px 0 rgba(21, 21, 21, .85);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity .2s var(--ease), transform .2s var(--ease),
              visibility .2s, background .16s var(--ease), color .16s var(--ease);
}

.to-top.is-on { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--ink); border-color: var(--volt); color: var(--volt); }
.to-top__arrow { font-size: 15px; line-height: 1; }

/* ---------- 11. 焦点 ---------- */
:focus-visible {
  outline: 3px solid var(--milan-red);
  outline-offset: 3px;
  border-radius: 4px;
}

.site-footer :focus-visible,
.to-top:focus-visible {
  outline: 3px solid var(--volt);
  outline-offset: 3px;
}

/* ---------- 12. 响应式 ---------- */
@media (max-width: 1180px) {
  .nav__link { padding: 9px 11px; font-size: 13.5px; }
  .chip-btn { padding: 8px 12px; font-size: 12.5px; }
}

@media (max-width: 1080px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
  .footer-brand__note { max-width: 44ch; }
}

@media (max-width: 1000px) {
  .nav__toggle { display: inline-flex; }

  .nav-panel {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    right: 0;
    z-index: 90;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    margin-left: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .2s var(--ease), transform .2s var(--ease), visibility .2s;
  }

  .nav-panel[data-open="true"] {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav {
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    border-radius: var(--r);
    box-shadow: var(--shadow);
  }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .nav__link {
    display: block;
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 15px;
  }

  .nav__link[aria-current="page"] { box-shadow: inset 3px 0 0 var(--volt); }

  .nav__utility {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .chip-btn { padding: 12px 14px; box-shadow: var(--shadow-sm); }

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

@media (max-width: 860px) {
  .grid--2,
  .grid--3 { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .site-header { padding-top: 10px; }
  .brand { padding: 7px 12px 8px; }
  .brand__mark { font-size: 17px; }
  .brand__tag { font-size: 9.5px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { justify-content: flex-start; }
  .display-xl { letter-spacing: -.04em; }
  .media-frame { aspect-ratio: 4 / 3; }
}

/* ---------- 13. 减少动态 ---------- */
@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;
  }

  html[data-js="on"] [data-reveal] { opacity: 1; transform: none; }
}
