/* ============================================================
   米乐赛场 · /assets/site.css
   共享外壳：顶部状态条 40px + 左侧框架导航 172px（≥1024px）
   近单色深绿体系，橙红只用于可点击与当前状态，电光蓝只用于订阅与时间
   ============================================================ */

:root {
  /* 品牌色 */
  --ink-950: #070C0A;
  --turf-800: #0E1C16;
  --turf-700: #14291F;
  --turf-600: #1D3C2C;
  --line-500: #2C5A44;
  --mist-50: #E8F2EC;
  --mist-300: #A9BDB2;
  --flare-500: #FF5A1F;
  --flare-700: #D8410C;
  --signal-400: #4FC3F7;
  --shade: #040705;

  /* 骨架尺寸 */
  --statusbar-h: 40px;
  --bar-h: 60px;
  --rail-w: 172px;
  --header-h: 100px;      /* 移动端：状态条 + 品牌条 */
  --content-max: 1200px;

  /* 造型 */
  --radius: 2px;
  --stroke: 2px;
  --hard: 6px 6px 0 var(--shade);
  --hard-sm: 4px 4px 0 var(--shade);
  --pad-x: 18px;
  --gap: 20px;
  --ease: cubic-bezier(.2, .7, .3, 1);

  /* 字体 */
  --font-display: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif;
  --font-body: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  color-scheme: dark;
}

@media (min-width: 1024px) {
  :root {
    --header-h: 40px;
    --pad-x: 34px;
    --gap: 26px;
  }
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}
body {
  min-height: 100vh;
  padding-top: var(--header-h);
  background-color: var(--turf-800);
  background-image:
    repeating-linear-gradient(90deg, rgba(44, 90, 68, .22) 0 1px, transparent 1px 84px),
    repeating-linear-gradient(0deg, rgba(44, 90, 68, .16) 0 1px, transparent 1px 84px);
  background-attachment: fixed;
  color: var(--mist-50);
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; padding: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
table { border-collapse: collapse; width: 100%; }

@media (min-width: 1024px) {
  body { padding-left: var(--rail-w); }
}

::selection { background: var(--flare-500); color: #FFFFFF; }

/* ---------- 排版 ---------- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.22;
  letter-spacing: -0.02em;
  color: var(--mist-50);
  text-wrap: balance;
}
h1 { font-size: clamp(34px, 6.4vw, 62px); }
h2 { font-size: clamp(24px, 4vw, 34px); }
h3 { font-size: clamp(19px, 2.6vw, 24px); font-weight: 700; line-height: 1.3; }
h4 { font-size: 17px; font-weight: 700; }
h5 { font-size: 15px; font-weight: 700; }

p { max-width: 34em; }
p + p { margin-top: 0.9em; }

a { color: var(--flare-500); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--flare-700); }

strong, b { font-weight: 900; color: var(--mist-50); }
small { font-size: 12px; }

.mono {
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
  color: var(--mist-300);
}

.prose { max-width: 46em; }
.prose p { max-width: 34em; }
.prose p + p { margin-top: 1em; }

.rule-under::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 12px;
  background: var(--flare-500);
}

/* ---------- 焦点 ---------- */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--signal-400);
  outline-offset: 2px;
  border-radius: var(--radius);
}

/* ---------- 跳转链接 ---------- */
.skip-link {
  position: absolute;
  top: -96px;
  left: 8px;
  z-index: 200;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  background: var(--signal-400);
  color: var(--ink-950);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  border: 2px solid var(--ink-950);
  border-radius: var(--radius);
  box-shadow: var(--hard-sm);
  transition: top .16s var(--ease);
}
.skip-link:focus { top: 8px; color: var(--ink-950); }

/* ============================================================
   头部
   ============================================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 90;
}

/* 状态条 */
.header-status {
  height: var(--statusbar-h);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 14px;
  background: var(--ink-950);
  border-bottom: 2px solid var(--line-500);
  color: var(--mist-300);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
}
.header-status__item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  min-width: 0;
  max-width: none;
}
.header-status__item--brand {
  color: var(--mist-50);
  font-weight: 700;
  letter-spacing: 0.16em;
  flex: none;
}
.header-status__item--note { display: none; flex: none; }
.header-status__item--live {
  margin-left: auto;
  color: var(--signal-400);
  overflow: hidden;
  text-overflow: ellipsis;
}
.header-status__dot {
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--flare-500);
  border-radius: 50%;
}

/* 品牌条 / 左框架 */
.header-frame {
  background: var(--turf-700);
  border-bottom: 2px solid var(--line-500);
}
.header-frame__bar {
  height: var(--bar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
}

.header-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--mist-50);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.header-brand:hover { color: var(--mist-50); }
.header-brand__mark {
  position: relative;
  flex: none;
  width: 26px;
  height: 26px;
  background: var(--flare-500);
  border: 2px solid var(--ink-950);
  border-radius: var(--radius);
  box-shadow: 3px 3px 0 var(--shade);
}
.header-brand__mark::before {
  content: "";
  position: absolute;
  inset: 5px;
  border: 2px solid var(--ink-950);
  border-radius: 50%;
}
.header-brand__text { white-space: nowrap; }

/* 汉堡 */
.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 13px;
  background: var(--turf-600);
  color: var(--mist-50);
  border: 2px solid var(--line-500);
  border-radius: var(--radius);
  box-shadow: 3px 3px 0 var(--shade);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: border-color .16s var(--ease), background .16s var(--ease);
}
.nav-toggle:hover { border-color: var(--flare-500); }
.nav-toggle__icon {
  position: relative;
  display: block;
  width: 18px;
  height: 14px;
  flex: none;
}
.nav-toggle__icon span {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--mist-50);
  transition: transform .2s var(--ease), opacity .2s var(--ease);
}
.nav-toggle__icon span:nth-child(1) { top: 0; }
.nav-toggle__icon span:nth-child(2) { top: 6px; }
.nav-toggle__icon span:nth-child(3) { top: 12px; }
.site-header[data-open] .nav-toggle__icon span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.site-header[data-open] .nav-toggle__icon span:nth-child(2) { opacity: 0; }
.site-header[data-open] .nav-toggle__icon span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* 导航（移动端抽屉） */
.site-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: calc(100vh - var(--header-h));
  overflow-y: auto;
  padding: 8px 12px 18px;
  background: var(--turf-700);
  border-bottom: 2px solid var(--line-500);
  box-shadow: 0 8px 0 rgba(4, 7, 5, .6);
  display: flex;
  flex-direction: column;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s linear .18s;
}
.site-header[data-open] .site-nav {
  visibility: visible;
  opacity: 1;
  transform: none;
  transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s;
}

.site-nav__list {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.site-nav__link {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 14px;
  color: var(--mist-50);
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.005em;
  border: 2px solid transparent;
  border-radius: var(--radius);
  transition: background .16s var(--ease), border-color .16s var(--ease), transform .16s var(--ease), color .16s var(--ease);
}
.site-nav__link:hover {
  color: var(--mist-50);
  background: var(--turf-600);
  border-color: var(--line-500);
  transform: translateX(2px);
}
.site-nav__link[aria-current="page"] {
  background: var(--flare-500);
  border-color: var(--flare-500);
  color: #FFFFFF;
}
.site-nav__link[aria-current="page"]:hover {
  background: var(--flare-700);
  border-color: var(--flare-700);
  color: #FFFFFF;
  transform: none;
}

.site-nav__foot {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 2px dashed var(--line-500);
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 18px;
  border: 2px solid var(--ink-950);
  border-radius: var(--radius);
  box-shadow: var(--hard-sm);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform .16s var(--ease), box-shadow .16s var(--ease),
              background-color .16s var(--ease), color .16s var(--ease), border-color .16s var(--ease);
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: var(--hard); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--shade); }

.btn--flare { background: var(--flare-500); color: #FFFFFF; }
.btn--flare:hover { background: var(--flare-700); color: #FFFFFF; }

.btn--ghost { background: var(--turf-600); color: var(--mist-50); border-color: var(--line-500); }
.btn--ghost:hover { border-color: var(--flare-500); color: var(--mist-50); }

/* ---------- 内容容器 ---------- */
.wrap {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: var(--pad-x);
  padding-right: var(--pad-x);
}
#main-content { display: block; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 16px 0 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  color: var(--mist-300);
}
.crumbs a { color: var(--mist-300); text-decoration: none; border-bottom: 2px solid transparent; }
.crumbs a:hover { color: var(--mist-50); border-bottom-color: var(--flare-500); }
.crumbs__sep { color: var(--line-500); }
.crumbs [aria-current="page"] { color: var(--signal-400); }

/* ---------- 卡片 / 网格 ---------- */
.grid { display: grid; gap: var(--gap); }
.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
@media (min-width: 640px) {
  .grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.card {
  position: relative;
  padding: 20px;
  background: var(--turf-600);
  border: 2px solid var(--line-500);
  border-radius: var(--radius);
  box-shadow: var(--hard);
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease), transform .16s var(--ease);
}
.card:hover {
  border-color: var(--flare-500);
  box-shadow: 8px 8px 0 var(--shade);
  transform: translateY(-2px);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  background: var(--turf-700);
  border: 2px solid var(--line-500);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  color: var(--mist-300);
  white-space: nowrap;
}
.tag--flare { color: var(--flare-500); border-color: var(--flare-500); }
.tag--signal { color: var(--signal-400); border-color: var(--signal-400); }

/* ---------- 图片容器（页面阶段放置图片/SVG） ---------- */
.media {
  position: relative;
  overflow: hidden;
  background: var(--turf-700);
  border: 2px solid var(--line-500);
  border-radius: var(--radius);
  box-shadow: var(--hard);
}
.media > img,
.media > svg,
.media > picture > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media--wide { aspect-ratio: 16 / 9; }
.media--tall { aspect-ratio: 3 / 4; }
.media--square { aspect-ratio: 1 / 1; }
.media--band { aspect-ratio: 21 / 9; }
.media__cap {
  position: absolute;
  left: 0;
  bottom: 0;
  max-width: 100%;
  padding: 6px 10px;
  background: var(--ink-950);
  border-top: 2px solid var(--line-500);
  color: var(--mist-300);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  line-height: 1.4;
}

/* ---------- 滚动进度 ---------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--signal-400);
  z-index: 150;
  pointer-events: none;
}

/* ---------- 滚动显现 ---------- */
.is-pending {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .34s var(--ease), transform .34s var(--ease);
}
.is-pending.is-in { opacity: 1; transform: none; }

/* ============================================================
   页脚
   ============================================================ */
.site-footer {
  margin-top: 56px;
  background: var(--ink-950);
  border-top: 2px solid var(--line-500);
  color: var(--mist-300);
}
.footer-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 42px var(--pad-x) 28px;
  display: grid;
  gap: 32px;
}
.footer-lead { display: grid; gap: 10px; align-content: start; }
.footer-brand {
  max-width: 22em;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(19px, 3vw, 26px);
  line-height: 1.32;
  letter-spacing: -0.02em;
  color: var(--mist-50);
}
.footer-icp { margin: 0; color: var(--mist-300); }

.footer-grid { display: grid; gap: 26px; grid-template-columns: 1fr; }
@media (min-width: 560px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.footer-col__title {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--mist-300);
}
.footer-col__list { display: grid; gap: 2px; }
.footer-col__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--mist-50);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color .16s var(--ease), border-color .16s var(--ease), transform .16s var(--ease);
}
.footer-col__link:hover {
  color: var(--flare-500);
  border-bottom-color: var(--flare-500);
  transform: translateX(3px);
}
.footer-col__link[aria-current="page"] { color: var(--flare-500); }

.footer-contact {
  display: grid;
  gap: 9px;
  padding: 18px;
  background: var(--turf-800);
  border: 2px solid var(--line-500);
  border-radius: var(--radius);
  box-shadow: var(--hard-sm);
}
.footer-contact__row {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
}
.footer-contact__key {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--mist-300);
}
.footer-contact__val {
  color: var(--mist-50);
  font-size: 14px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.footer-contact__note {
  margin: 6px 0 0;
  padding-top: 10px;
  border-top: 2px dashed var(--line-500);
  font-size: 13px;
  line-height: 1.7;
  color: var(--mist-300);
  max-width: 34em;
}

.footer-base { border-top: 2px solid var(--line-500); }
.footer-base__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 14px var(--pad-x) 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  color: var(--mist-300);
}
.footer-base__copy,
.footer-base__meta,
.footer-base__icp { margin: 0; max-width: none; }

/* ============================================================
   桌面 / 平板横屏：框架式导航
   ============================================================ */
@media (min-width: 1024px) {
  .header-status__item--brand { display: none; }
  .header-status__item--note { display: flex; }

  .site-header { height: var(--statusbar-h); }

  .header-frame {
    position: fixed;
    top: var(--statusbar-h);
    left: 0;
    bottom: 0;
    width: var(--rail-w);
    display: flex;
    flex-direction: column;
    background: var(--turf-700);
    border-right: 2px solid var(--line-500);
    border-bottom: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .header-frame__bar {
    height: auto;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 20px 14px 16px;
    border-bottom: 2px solid var(--line-500);
  }
  .header-brand { font-size: 19px; }
  .nav-toggle { display: none; }

  .site-nav {
    position: static;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    max-height: none;
    overflow: visible;
    padding: 14px 12px 20px;
    background: transparent;
    border-bottom: 0;
    box-shadow: none;
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: none;
  }
  .site-nav__link { min-height: 46px; padding: 0 12px; font-size: 15px; }
  .site-nav__foot { margin-top: auto; }

  .footer-inner {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.5fr) minmax(0, 1fr);
    grid-template-areas:
      "lead grid contact";
    align-items: start;
    gap: 30px;
    padding-top: 52px;
    padding-bottom: 36px;
  }
  .footer-lead { grid-area: lead; }
  .footer-grid { grid-area: grid; }
  .footer-contact { grid-area: contact; }
}

@media (min-width: 1360px) {
  .footer-inner {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.65fr) minmax(0, 1fr);
  }
}

/* ============================================================
   无障碍：减少动效
   ============================================================ */
@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;
  }
  .is-pending { opacity: 1; transform: none; }
  .scroll-progress { transition: none; }
  .card:hover, .btn:hover, .btn:active,
  .site-nav__link:hover, .footer-col__link:hover { transform: none; }
}
