/* =====================================================
   BAPP 免费体育赛事专区 — 全站共享样式
   File: /assets/site.css
   设计坐标：赛事数据控制台 / 展览画册 / 坐标索引
   ===================================================== */

/* ---------- Reset & Design Tokens ---------- */
:root {
  --primary-navy: #0B1F3A;
  --primary-green: #00E39A;
  --accent-gold: #F5C518;
  --bg-light: #F4F7FA;
  --bg-dark: #0A1428;
  --text-main: #1A2A3A;
  --text-sub: #5A6B7B;
  --border-light: #D0DCE4;
  --highlight-blue: #4D7CFE;
  --surface-card: #FFFFFF;
  --font-sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Roboto Mono", "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --container-width: 1240px;
  --container-pad: clamp(16px, 3vw, 32px);
  --radius-sm: 4px;
  --radius-md: 10px;
  --shadow-md: 0 8px 24px rgba(11, 31, 58, 0.12);
  --shadow-lg: 0 16px 40px rgba(11, 31, 58, 0.18);
  --header-z: 200;
}

*, *::before, *::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-main);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: 800;
  line-height: 1.25;
  color: var(--primary-navy);
  margin: 0 0 0.5em;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--highlight-blue);
}

a:hover {
  color: var(--primary-navy);
}

ul, ol {
  padding-left: 1.25em;
}

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

main {
  flex: 1 0 auto;
}

#main-content {
  scroll-margin-top: 150px;
  min-height: 60vh;
}

:target {
  scroll-margin-top: 150px;
}

:focus-visible {
  outline: 3px solid var(--primary-green);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- Layout Utilities ---------- */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.grid {
  display: grid;
  gap: clamp(16px, 2.5vw, 28px);
}

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

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

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

@media (max-width: 991px) {
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border: 2px solid transparent;
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
  background: var(--primary-green);
  color: var(--primary-navy);
  border-color: var(--primary-green);
}

.btn-primary:hover {
  background: #00ce8b;
  color: var(--primary-navy);
  box-shadow: 0 8px 20px rgba(0, 227, 154, 0.32);
  transform: translateY(-2px);
}

.btn-gold {
  background: var(--accent-gold);
  color: var(--primary-navy);
  border-color: var(--accent-gold);
}

.btn-gold:hover {
  background: #ffe056;
  color: var(--primary-navy);
  box-shadow: 0 8px 20px rgba(245, 197, 24, 0.35);
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--primary-navy);
  border-color: var(--primary-navy);
}

.btn-ghost:hover {
  background: var(--primary-navy);
  color: #fff;
  box-shadow: 0 8px 20px rgba(11, 31, 58, 0.22);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  font-size: 13px;
  color: var(--text-sub);
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
}

.breadcrumb li + li::before {
  content: "/";
  margin: 0 10px;
  color: var(--border-light);
  font-weight: 700;
}

.breadcrumb a {
  color: var(--text-sub);
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb a:hover {
  color: var(--primary-navy);
}

.breadcrumb [aria-current="page"] {
  color: var(--primary-navy);
  font-weight: 800;
}

/* ---------- Page Head ---------- */
.page-head {
  padding: clamp(36px, 6vw, 72px) 0 clamp(28px, 4vw, 48px);
  margin-bottom: clamp(32px, 5vw, 56px);
  border-bottom: 3px solid var(--primary-navy);
  position: relative;
}

.page-title {
  margin: 0;
  font-size: clamp(30px, 4.5vw, 44px);
  font-weight: 900;
  line-height: 1.2;
  color: var(--primary-navy);
  letter-spacing: -0.01em;
}

.page-desc {
  margin: 12px 0 0;
  font-size: 15px;
  color: var(--text-sub);
  max-width: 62ch;
}

/* ---------- Section Head ---------- */
.section-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.section-index {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
  color: var(--primary-green);
  background: var(--primary-navy);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  flex: 0 0 auto;
}

.section-title {
  margin: 0;
  font-size: clamp(22px, 2.6vw, 30px);
  font-weight: 900;
  line-height: 1.25;
}

.section-lead {
  margin: -8px 0 32px;
  font-size: 15px;
  color: var(--text-sub);
  max-width: 64ch;
}

/* ---------- Card ---------- */
.card {
  position: relative;
  display: block;
  background: var(--surface-card);
  border: 2px solid var(--primary-navy);
  border-radius: var(--radius-md);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translate(-3px, -3px);
  box-shadow: 8px 8px 0 var(--primary-navy);
  color: inherit;
}

/* ---------- Tag ---------- */
.tag {
  display: inline-block;
  padding: 3px 12px;
  border: 1px solid var(--border-light);
  background: var(--surface-card);
  color: var(--text-sub);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.6;
}

.tag-green {
  background: var(--primary-green);
  border-color: var(--primary-green);
  color: var(--primary-navy);
}

.tag-gold {
  background: var(--accent-gold);
  border-color: var(--accent-gold);
  color: var(--primary-navy);
}

.tag-navy {
  background: var(--primary-navy);
  border-color: var(--primary-navy);
  color: #fff;
}

/* ---------- Media Frame ---------- */
.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--border-light);
  border: 2px solid var(--primary-navy);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  aspect-ratio: 16 / 10;
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.media-frame:hover img {
  transform: scale(1.03);
}

.media-frame-ratio-4-3 {
  aspect-ratio: 4 / 3;
}

.media-frame-ratio-1-1 {
  aspect-ratio: 1 / 1;
}

.media-frame-ratio-21-9 {
  aspect-ratio: 21 / 9;
}

/* ---------- Legend ---------- */
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  font-size: 13px;
  color: var(--text-sub);
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.legend-swatch {
  width: 12px;
  height: 12px;
  border: 2px solid var(--primary-navy);
  border-radius: 50%;
  background: var(--primary-green);
  flex: 0 0 auto;
}

.legend-swatch.gold {
  background: var(--accent-gold);
}

.legend-swatch.navy {
  background: var(--primary-navy);
}

.legend-swatch.blue {
  background: var(--highlight-blue);
}

/* ---------- Vertical Label ---------- */
.v-label {
  writing-mode: vertical-rl;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.32em;
  color: var(--text-sub);
  text-transform: uppercase;
  white-space: nowrap;
}

/* ---------- Stat Number ---------- */
.stat-num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 900;
  font-size: 1.4em;
  line-height: 1;
  color: var(--primary-navy);
}

/* ---------- Scroll Reveal ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--header-z);
  background: var(--primary-navy);
  color: #fff;
  border-bottom: 3px solid var(--primary-green);
  box-shadow: 0 6px 24px rgba(4, 10, 20, 0.32);
}

.site-header::before {
  content: "";
  display: block;
  height: 5px;
  background: linear-gradient(90deg, var(--primary-green) 0%, var(--primary-green) 72%, var(--accent-gold) 72%, var(--accent-gold) 100%);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 10px;
  z-index: calc(var(--header-z) + 10);
  display: inline-block;
  padding: 10px 18px;
  background: var(--accent-gold);
  color: var(--primary-navy);
  font-weight: 800;
  font-size: 14px;
  text-decoration: none;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
}

.skip-link:focus {
  left: 10px;
}

.masthead {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  padding-top: 16px;
  padding-bottom: 14px;
}

.header-live {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  justify-self: start;
}

.live-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--primary-green);
  box-shadow: 0 0 0 0 rgba(0, 227, 154, 0.5);
  animation: live-pulse 2s ease-out infinite;
}

@keyframes live-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 227, 154, 0.5);
  }
  70% {
    box-shadow: 0 0 0 9px rgba(0, 227, 154, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(0, 227, 154, 0);
  }
}

.live-text {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.68);
}

.brand {
  justify-self: center;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  line-height: 1.1;
}

.brand-name {
  font-size: clamp(26px, 2.8vw, 34px);
  font-weight: 900;
  letter-spacing: 0.04em;
  color: #fff;
  position: relative;
  transition: color 0.2s ease;
}

.brand:hover .brand-name {
  color: var(--primary-green);
}

.brand-name::after {
  content: "●";
  position: absolute;
  right: -16px;
  bottom: 3px;
  font-size: 9px;
  color: var(--accent-gold);
}

.brand-tagline {
  margin-top: 7px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.36em;
  padding-left: 0.36em;
  color: rgba(255, 255, 255, 0.5);
}

.header-actions {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.header-hot {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.header-hot::before {
  content: "◈";
  color: var(--accent-gold);
  font-size: 11px;
}

.header-hot:hover {
  color: #fff;
  border-color: var(--accent-gold);
  background: rgba(245, 197, 24, 0.08);
}

.site-nav {
  display: block;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.nav-list {
  display: flex;
  justify-content: center;
  align-items: stretch;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-item {
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-item:first-child {
  border-left: none;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px 22px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  border-bottom: 3px solid transparent;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.nav-index {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 4px 6px;
  border-radius: 3px;
  color: var(--primary-green);
  background: rgba(0, 227, 154, 0.12);
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-label {
  display: inline-block;
  line-height: 1.2;
}

.nav-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
  border-bottom-color: var(--accent-gold);
}

.nav-link[aria-current="page"] {
  color: #fff;
  background: rgba(0, 227, 154, 0.14);
  border-bottom-color: var(--primary-green);
}

.nav-link[aria-current="page"] .nav-index {
  background: var(--primary-green);
  color: var(--primary-navy);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 6px;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

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

.nav-toggle-box {
  width: 20px;
  height: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.nav-toggle-line {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--primary-green);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.nav-toggle-text {
  letter-spacing: 0.08em;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-dark);
  color: rgba(255, 255, 255, 0.72);
  border-top: 4px solid var(--primary-green);
  position: relative;
}

.site-footer::after {
  content: "";
  display: block;
  height: 4px;
  background: repeating-linear-gradient(90deg, var(--accent-gold) 0 20px, transparent 20px 34px);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr 1fr 1.6fr;
  gap: clamp(28px, 4vw, 56px);
  padding-top: clamp(48px, 6vw, 72px);
  padding-bottom: clamp(40px, 5vw, 56px);
}

.footer-col {
  min-width: 0;
}

.footer-brand {
  display: flex;
  flex-direction: column;
}

.footer-logo {
  display: inline-flex;
  flex-direction: column;
  text-decoration: none;
  margin-bottom: 18px;
}

.footer-brand-name {
  font-size: 32px;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: #fff;
  line-height: 1;
}

.footer-brand-tagline {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.36em;
  padding-left: 0.36em;
  color: rgba(255, 255, 255, 0.5);
}

.footer-trust {
  margin: 0;
  font-size: 13px;
  line-height: 1.85;
  color: rgba(255, 255, 255, 0.5);
  max-width: 44ch;
}

.footer-heading {
  margin: 0 0 20px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.26em;
  color: var(--primary-green);
}

.footer-heading::before {
  content: "//";
  color: var(--accent-gold);
  margin-right: 8px;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.68);
  font-size: 14px;
  text-decoration: none;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.footer-links a:hover {
  color: var(--primary-green);
  padding-left: 6px;
}

.footer-links [aria-current="page"] {
  color: var(--primary-green);
}

.footer-contact .contact-list {
  display: grid;
  gap: 14px;
  margin: 0;
}

.contact-row {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 14px;
  font-size: 13px;
  line-height: 1.6;
}

.contact-row dt {
  color: rgba(255, 255, 255, 0.42);
}

.contact-row dd {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
}

.contact-row a {
  color: var(--primary-green);
  text-decoration: none;
}

.contact-row a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 0 28px;
  font-size: 13px;
}

.footer-bottom-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  color: rgba(255, 255, 255, 0.45);
}

.footer-copyright {
  color: rgba(255, 255, 255, 0.35);
}

.footer-icp {
  color: rgba(255, 255, 255, 0.42);
  letter-spacing: 0.04em;
}

.footer-meta {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-meta a {
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-meta a:hover {
  color: var(--primary-green);
}

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 860px) {
  .masthead {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 78px;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .header-live {
    display: none;
  }

  .header-actions {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
  }

  .header-hot {
    display: none;
  }

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

  .site-nav {
    display: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--bg-dark);
  }

  .site-nav[data-open] {
    display: block;
    max-height: calc(100vh - 78px);
    overflow-y: auto;
  }

  .nav-list {
    flex-direction: column;
    padding: 10px 16px 18px;
    gap: 2px;
  }

  .nav-item {
    border-left: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-item:last-child {
    border-bottom: none;
  }

  .nav-link {
    justify-content: space-between;
    padding: 13px 10px;
    border-bottom: none;
    border-radius: var(--radius-sm);
  }
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-brand {
    grid-column: auto;
  }

  .footer-bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-meta {
    gap: 14px;
  }
}

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

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

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

  .live-dot {
    box-shadow: none;
  }

  .media-frame img {
    transition: none;
  }

  .media-frame:hover img {
    transform: none;
  }
}
