/* ==========================================================================
   百博sports 共享样式 /assets/site.css
   夜场战术笔记本：深墨绿底 + 荧光青柠数据高亮 + 暖橙时间刻度 + 浅沙呼吸区
   ========================================================================== */

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

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

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

ul, ol { list-style: none; }

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

button, input, select, textarea { font: inherit; color: inherit; }

button { background: none; border: 0; cursor: pointer; }

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

table { border-collapse: collapse; width: 100%; }

/* ---------- tokens ---------- */
:root {
  --bb-night: #0E241E;
  --bb-deep: #081713;
  --bb-lime: #B8FF3C;
  --bb-orange: #FF8A3D;
  --bb-sand: #E8E0CE;
  --bb-mist: #F4F6F2;
  --bb-sage: #8AA097;
  --bb-line: #1E3A31;
  --bb-turf: #2F5A45;
  --bb-coral: #FF6B5A;

  --bb-ease: cubic-bezier(.2, .7, .3, 1);
  --bb-max: 1280px;
  --bb-gutter: clamp(16px, 4vw, 28px);
  --bb-radius: 16px;
  --bb-radius-sm: 10px;
  --bb-progress: 0;

  --bb-font-display: "Archivo Narrow", "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --bb-font-body: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --bb-font-mono: ui-monospace, "JetBrains Mono", "IBM Plex Mono", "SFMono-Regular", Menlo, Consolas, monospace;
}

/* ---------- 页面基底：草皮颗粒 + 球场网格 ---------- */
body {
  min-height: 100vh;
  background-color: var(--bb-night);
  background-image:
    radial-gradient(1100px 640px at 8% -12%, rgba(184, 255, 60, .07), transparent 62%),
    radial-gradient(900px 560px at 102% 2%, rgba(255, 138, 61, .06), transparent 58%);
  background-repeat: no-repeat;
  color: var(--bb-mist);
  font-family: var(--bb-font-body);
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(0deg, rgba(244, 246, 242, .028) 0 1px, transparent 1px 5px),
    repeating-linear-gradient(90deg, rgba(47, 90, 69, .16) 0 1px, transparent 1px 108px);
  opacity: .85;
}

/* ---------- 中文排版 ---------- */
h1, h2, h3, h4 {
  font-family: var(--bb-font-display);
  font-weight: 400;
  letter-spacing: -.02em;
  line-height: 1.12;
  color: var(--bb-mist);
}

h1 { font-size: clamp(40px, 6vw, 72px); }
h2 { font-size: clamp(28px, 3.6vw, 40px); }
h3 { font-size: clamp(20px, 2.2vw, 24px); }
h4 { font-size: 17px; }

p { max-width: 68ch; }

strong { color: var(--bb-lime); font-weight: 500; }

::selection { background: var(--bb-lime); color: #08130F; }

:focus-visible {
  outline: 2px solid var(--bb-lime);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 跳转链接 ---------- */
.skip-link {
  position: absolute;
  left: 50%;
  top: 8px;
  z-index: 200;
  transform: translate(-50%, -180%);
  padding: 10px 18px;
  border-radius: 999px;
  background-color: var(--bb-lime);
  color: #08130F;
  font-size: 13px;
  letter-spacing: .08em;
  transition: transform .18s var(--bb-ease);
}

.skip-link:focus { transform: translate(-50%, 0); }

/* ---------- 悬浮胶囊页头 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  padding: 14px clamp(12px, 3vw, 28px) 0;
}

.header-shell {
  max-width: var(--bb-max);
  margin-inline: auto;
}

.nav-island {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2vw, 24px);
  padding: 9px 10px 9px 18px;
  border: 1px solid var(--bb-line);
  border-radius: 999px;
  background-color: rgba(8, 23, 19, .78);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 16px 40px -30px #000;
  transition:
    background-color .18s var(--bb-ease),
    border-color .18s var(--bb-ease),
    box-shadow .18s var(--bb-ease);
}

.site-header[data-scrolled] .nav-island {
  background-color: rgba(8, 23, 19, .96);
  border-color: #2B4E41;
  box-shadow: 0 22px 50px -30px #000, inset 0 0 0 1px rgba(184, 255, 60, .05);
}

.brand-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1px;
  min-width: 0;
}

.brand-mark {
  font-family: var(--bb-font-display);
  font-size: 19px;
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -.01em;
  color: var(--bb-mist);
  white-space: nowrap;
  transition: color .18s var(--bb-ease);
}

.brand-tagline {
  font-family: var(--bb-font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--bb-sage);
  white-space: nowrap;
}

.brand-block:hover .brand-mark { color: var(--bb-lime); }

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

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

.nav-pill {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 14px;
  color: var(--bb-sage);
  white-space: nowrap;
  transition:
    color .18s var(--bb-ease),
    background-color .18s var(--bb-ease),
    border-color .18s var(--bb-ease);
}

.nav-pill:hover {
  color: var(--bb-mist);
  background-color: rgba(47, 90, 69, .42);
}

.nav-pill[aria-current="page"] {
  color: var(--bb-mist);
  border-color: var(--bb-lime);
  background-color: rgba(184, 255, 60, .09);
}

.nav-pill[aria-current="page"]::after {
  content: "";
  width: 5px;
  height: 5px;
  margin-left: 8px;
  border-radius: 50%;
  background-color: var(--bb-lime);
  box-shadow: 0 0 10px rgba(184, 255, 60, .9);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 17px;
  border-radius: 999px;
  background-color: var(--bb-lime);
  color: #08130F;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .02em;
  white-space: nowrap;
  transition: background-color .18s var(--bb-ease), transform .18s var(--bb-ease);
}

.nav-cta::after {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg) translate(-1px, -1px);
}

.nav-cta:hover {
  background-color: #CBFF6B;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  margin-left: auto;
  padding: 9px 15px;
  border: 1px solid var(--bb-line);
  border-radius: 999px;
  background-color: rgba(47, 90, 69, .28);
  color: var(--bb-mist);
  transition: border-color .18s var(--bb-ease), background-color .18s var(--bb-ease);
}

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

.nav-toggle-text {
  font-family: var(--bb-font-mono);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.nav-toggle-bars {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 10px;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 1.5px;
  background-color: var(--bb-lime);
  transition: transform .18s var(--bb-ease), top .18s var(--bb-ease);
}

.nav-toggle-bars::before { top: 2px; }
.nav-toggle-bars::after { top: 7px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before {
  top: 5px;
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after {
  top: 5px;
  transform: rotate(-45deg);
}

.scroll-progress {
  display: block;
  height: 2px;
  margin: 8px 6px 0;
  border-radius: 2px;
  background-image: linear-gradient(90deg, var(--bb-lime), var(--bb-orange));
  transform: scaleX(var(--bb-progress));
  transform-origin: 0 50%;
  transition: transform .12s linear;
}

/* ---------- 容器与栅格 ---------- */
.container {
  width: 100%;
  max-width: var(--bb-max);
  margin-inline: auto;
  padding-inline: var(--bb-gutter);
}

.page-shell {
  width: 100%;
  max-width: var(--bb-max);
  margin-inline: auto;
  padding: clamp(24px, 4vw, 44px) var(--bb-gutter) clamp(48px, 7vw, 96px);
}

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

.grid--split {
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  align-items: start;
}

/* ---------- 卡片与色块 ---------- */
.card {
  position: relative;
  padding: clamp(16px, 2.4vw, 26px);
  border: 1px solid var(--bb-line);
  border-radius: var(--bb-radius);
  background-image: linear-gradient(180deg, rgba(47, 90, 69, .26), rgba(8, 23, 19, .55));
  transition: border-color .18s var(--bb-ease), background-color .18s var(--bb-ease);
}

.card:hover { border-color: var(--bb-turf); }

.card--sand {
  background-image: none;
  background-color: var(--bb-sand);
  border-color: transparent;
  color: var(--bb-night);
}

.card--sand h2,
.card--sand h3,
.card--sand h4 { color: var(--bb-night); }

.card--outline {
  background-image: none;
  background-color: transparent;
}

/* ---------- 标签与数字 ---------- */
.label {
  display: inline-block;
  font-family: var(--bb-font-mono);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--bb-sage);
}

.label--lime { color: var(--bb-lime); }
.label--orange { color: var(--bb-orange); }

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

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: .02em;
  transition:
    background-color .18s var(--bb-ease),
    border-color .18s var(--bb-ease),
    color .18s var(--bb-ease),
    transform .18s var(--bb-ease);
}

.btn--primary { background-color: var(--bb-lime); color: #08130F; }
.btn--primary:hover { background-color: #CBFF6B; transform: translateY(-1px); }

.btn--ghost {
  border-color: var(--bb-line);
  background-color: rgba(8, 23, 19, .6);
  color: var(--bb-mist);
}

.btn--ghost:hover { border-color: var(--bb-lime); color: var(--bb-lime); }

.btn--sand { background-color: var(--bb-sand); color: var(--bb-night); }
.btn--sand:hover { background-color: #F1EADA; transform: translateY(-1px); }

/* ---------- 链接下划线 ---------- */
.link-underline {
  position: relative;
  display: inline-block;
}

.link-underline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1px;
  background-color: currentColor;
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform .18s var(--bb-ease);
}

.link-underline:hover::after,
.link-underline:focus-visible::after { transform: scaleX(1); }

/* ---------- 面包屑 ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  font-family: var(--bb-font-mono);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--bb-sage);
}

.breadcrumb a {
  color: var(--bb-sage);
  transition: color .18s var(--bb-ease);
}

.breadcrumb a:hover { color: var(--bb-lime); }

.breadcrumb-sep { color: var(--bb-turf); }

.breadcrumb [aria-current="page"] { color: var(--bb-mist); }

/* ---------- 响应式图片容器（供页面阶段使用） ---------- */
.media-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--bb-line);
  border-radius: var(--bb-radius);
  background-color: var(--bb-deep);
}

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

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.72) contrast(1.06) brightness(.9);
}

.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(90deg, rgba(184, 255, 60, .10) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(0deg, rgba(244, 246, 242, .05) 0 1px, transparent 1px 56px);
}

.media-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(180deg, transparent 55%, rgba(8, 23, 19, .85));
}

.media-frame__tag {
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 2;
  padding: 6px 12px;
  border: 1px solid var(--bb-line);
  border-radius: 999px;
  background-color: rgba(8, 23, 19, .8);
  font-family: var(--bb-font-mono);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--bb-lime);
}

.media-caption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--bb-sage);
}

/* ---------- 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(48px, 8vw, 110px);
  border-top: 1px solid var(--bb-line);
  background-color: var(--bb-deep);
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background-image: linear-gradient(90deg, transparent, rgba(184, 255, 60, .5), transparent);
}

.footer-shell {
  display: flex;
  flex-direction: column;
  gap: clamp(24px, 4vw, 40px);
  max-width: var(--bb-max);
  margin-inline: auto;
  padding: clamp(32px, 5vw, 64px) var(--bb-gutter) 26px;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.6fr);
  gap: clamp(20px, 3vw, 48px);
}

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

.footer-brand .brand-mark { font-size: 22px; }

.footer-note {
  max-width: 34ch;
  font-size: 13px;
  color: var(--bb-sage);
}

.footer-note--dim { color: #5E7A6E; }

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

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col-title {
  margin: 0;
  font-family: var(--bb-font-mono);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--bb-lime);
}

.footer-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-link {
  font-size: 14px;
  color: var(--bb-mist);
  transition: color .18s var(--bb-ease);
}

.footer-link:hover { color: var(--bb-lime); }

.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: clamp(18px, 2.6vw, 26px);
  border-radius: var(--bb-radius);
  background-color: var(--bb-sand);
  color: var(--bb-night);
}

.footer-contact p {
  max-width: none;
  font-size: 14px;
  line-height: 1.7;
}

.footer-contact-label {
  margin: 0;
  font-family: var(--bb-font-mono);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #5A6B4A;
}

.footer-contact-note { color: #41503C; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  padding-top: 20px;
  border-top: 1px solid var(--bb-line);
  font-size: 13px;
  color: var(--bb-sage);
}

.footer-bottom p { max-width: none; }

/* ---------- 工具类 ---------- */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ---------- 响应式：平板 ---------- */
@media (max-width: 1100px) {
  .grid--split { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
}

@media (max-width: 960px) {
  .footer-top { grid-template-columns: minmax(0, 1fr); }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- 响应式：移动端抽屉导航 ---------- */
@media (max-width: 900px) {
  .nav-island {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background-color: rgba(8, 23, 19, .96);
  }

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

  .nav-pills {
    position: fixed;
    left: clamp(12px, 4vw, 24px);
    right: clamp(12px, 4vw, 24px);
    top: 86px;
    z-index: 90;
    display: grid;
    gap: 6px;
    margin: 0;
    padding: 14px;
    border: 1px solid var(--bb-line);
    border-radius: 20px;
    background-color: rgba(8, 23, 19, .99);
    box-shadow: 0 30px 70px -30px #000;
    max-height: calc(100vh - 120px);
    overflow: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition:
      opacity .18s var(--bb-ease),
      transform .18s var(--bb-ease),
      visibility .18s;
  }

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

  .nav-list {
    display: grid;
    gap: 6px;
  }

  .nav-pill {
    width: 100%;
    justify-content: flex-start;
    padding: 12px 15px;
    border-color: var(--bb-line);
    background-color: rgba(47, 90, 69, .16);
    font-size: 15px;
  }

  .nav-pill[aria-current="page"] {
    border-color: var(--bb-lime);
    background-color: rgba(184, 255, 60, .1);
  }

  .nav-cta {
    justify-content: center;
    padding: 13px 17px;
  }
}

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

/* ---------- 响应式：手机 ---------- */
@media (max-width: 560px) {
  .brand-tagline { display: none; }
  .footer-cols { grid-template-columns: minmax(0, 1fr); }
  .nav-island { padding: 8px 8px 8px 15px; }
}

/* ---------- 减动效 ---------- */
@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-progress { transition: none; }
}
