/* =========================================================
   大赢家CN · /assets/site.css
   共享外壳：reset / 变量 / 中文排版 / 头部轨道 / 页脚 / 通用组件
   ========================================================= */

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

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

body { margin: 0; }

h1, h2, h3, h4, h5, p, figure, blockquote, ul, ol, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }

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

button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; }
a { color: inherit; }
table { border-collapse: collapse; width: 100%; }

/* ---------- 2. 设计变量 ---------- */
:root {
  --ink-deep: #0A1030;
  --navy: #131A45;
  --cyan: #2BE7E0;
  --gold: #FFC130;
  --magenta: #FF3D8B;
  --paper: #F4EDE0;
  --paper-ink: #1B1410;
  --alert: #FF5A2B;
  --white: #EAF2FF;
  --muted: #9FB3D9;
  --ok: #3DD68C;

  --line: rgba(159, 179, 217, 0.18);
  --line-cyan: rgba(43, 231, 224, 0.32);
  --panel-top: rgba(19, 26, 69, 0.94);
  --panel-btm: rgba(13, 19, 52, 0.94);

  --font-head: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif;
  --font-body: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Source Han Sans SC", -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", "Courier New", monospace;

  --rail-w: 88px;
  --bar-h: 60px;
  --shell: 1280px;
  --gap: 24px;
  --unit: 8px;
  --radius: 2px;
  --cut: 8deg;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --progress: 0;
}

/* ---------- 3. 基础排版 ---------- */
body {
  min-height: 100vh;
  background-color: var(--ink-deep);
  background-image:
    radial-gradient(1100px 560px at 88% -8%, rgba(43, 231, 224, 0.13), transparent 62%),
    radial-gradient(820px 520px at 2% 104%, rgba(255, 61, 139, 0.10), transparent 66%),
    linear-gradient(rgba(43, 231, 224, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(43, 231, 224, 0.035) 1px, transparent 1px);
  background-size: auto, auto, 64px 64px, 64px 64px;
  background-attachment: fixed, fixed, fixed, fixed;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: 0.02em;
}
h1 { font-size: clamp(34px, 6.2vw, 64px); letter-spacing: 0.01em; }
h2 { font-size: clamp(24px, 3.6vw, 34px); }
h3 { font-size: clamp(19px, 2.4vw, 24px); }
h4 { font-size: 17px; letter-spacing: 0.06em; }

time, code, kbd, samp, .mono {
  font-family: var(--font-mono);
  font-size: 0.92em;
  letter-spacing: 0.04em;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

/* ---------- 4. 头部：左侧固定轨道 / 移动吸顶条 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: linear-gradient(180deg, rgba(10, 16, 48, 0.92), rgba(10, 16, 48, 0.55));
  border-bottom: 1px solid var(--line-cyan);
  transition: background-color 0.24s var(--ease), box-shadow 0.24s var(--ease), border-color 0.24s var(--ease);
}
.site-header[data-scrolled] {
  background: linear-gradient(180deg, rgba(13, 19, 52, 0.98), rgba(10, 16, 48, 0.98));
  border-bottom-color: rgba(43, 231, 224, 0.45);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.55);
}

.header-rail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 10px 16px;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 50%;
  z-index: 140;
  padding: 10px 16px;
  transform: translate(-50%, -220%);
  background: var(--gold);
  color: var(--paper-ink);
  border: 1px solid var(--paper-ink);
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-decoration: none;
  transition: transform 0.2s var(--ease);
}
.skip-link:focus { transform: translate(-50%, 0); }

/* 品牌 */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
}
.brand-mark {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  background: var(--gold);
  color: var(--paper-ink);
  border: 2px solid var(--paper-ink);
  border-radius: var(--radius);
  box-shadow: 3px 3px 0 rgba(255, 61, 139, 0.9);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 19px;
  line-height: 1;
}
.brand-stack { display: flex; flex-direction: column; min-width: 0; }
.brand-name {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 15px;
  letter-spacing: 0.14em;
  white-space: nowrap;
}
.brand-tag {
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--muted);
  white-space: nowrap;
}

/* 移动菜单按钮 */
.nav-toggle {
  position: relative;
  z-index: 80;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  background: rgba(19, 26, 69, 0.7);
  color: var(--cyan);
  border: 1px solid var(--line-cyan);
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.16em;
  cursor: pointer;
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.nav-toggle-icon { display: grid; gap: 4px; width: 16px; }
.nav-toggle-icon span {
  display: block;
  height: 2px;
  background: currentColor;
  transition: transform 0.24s var(--ease), opacity 0.24s var(--ease);
}
.nav-toggle[aria-expanded="true"] {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--paper-ink);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* 导航面板 */
.rail-nav {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 70;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: min(340px, 88vw);
  padding: 76px 20px 28px;
  overflow-y: auto;
  background: linear-gradient(160deg, var(--navy), var(--ink-deep) 62%);
  border-right: 1px solid var(--line-cyan);
  box-shadow: 24px 0 60px rgba(0, 0, 0, 0.6);
  visibility: hidden;
  transform: translateX(-104%);
  transition: transform 0.32s var(--ease), visibility 0.32s var(--ease);
}
.rail-nav[data-open] { visibility: visible; transform: translateX(0); }

.nav-scrim {
  position: fixed;
  inset: 0;
  z-index: 65;
  background: rgba(5, 8, 25, 0.72);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s var(--ease);
}
.nav-scrim[data-visible] { opacity: 1; pointer-events: auto; }

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

.rail-list { display: flex; flex-direction: column; gap: 6px; }

.rail-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  color: var(--muted);
  text-decoration: none;
  border-left: 2px solid transparent;
  border-radius: var(--radius);
  transition: color 0.2s var(--ease), background-color 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.rail-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 3px;
  background: var(--gold);
  opacity: 0;
  transition: opacity 0.2s var(--ease);
}
.rail-link:hover {
  color: var(--cyan);
  background: rgba(43, 231, 224, 0.07);
}
.rail-link[aria-current="page"] {
  color: var(--gold);
  background: rgba(255, 193, 48, 0.09);
  border-color: rgba(255, 193, 48, 0.5);
  box-shadow: inset 0 0 22px rgba(255, 193, 48, 0.08);
}
.rail-link[aria-current="page"]::before { opacity: 1; }

.rail-glyph {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: rgba(159, 179, 217, 0.65);
}
.rail-link:hover .rail-glyph,
.rail-link[aria-current="page"] .rail-glyph { color: inherit; }

.rail-label {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.12em;
}

.rail-foot {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
}
.rail-cta { width: 100%; }

.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  overflow: hidden;
  background: rgba(43, 231, 224, 0.12);
  pointer-events: none;
}
.scroll-progress-fill {
  display: block;
  width: calc(var(--progress) * 100%);
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--gold) 68%, var(--magenta));
  transition: width 0.12s linear;
}

/* ---------- 5. 头部：桌面轨道 ---------- */
@media (min-width: 1024px) {
  body { padding-left: var(--rail-w); }

  .site-header {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--rail-w);
    background: transparent;
    border-bottom: 0;
    border-right: 1px solid transparent;
  }
  .site-header[data-scrolled] {
    background: linear-gradient(180deg, rgba(19, 26, 69, 0.97), rgba(10, 16, 48, 0.99));
    border-right-color: rgba(43, 231, 224, 0.34);
    box-shadow: 8px 0 34px rgba(0, 0, 0, 0.5);
  }

  .header-rail {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    max-width: none;
    height: 100%;
    padding: 20px 0 18px;
  }

  .brand { flex-direction: column; gap: 10px; }
  .brand-mark { width: 52px; height: 52px; font-size: 22px; }
  .brand-stack { align-items: center; }
  .brand-name { writing-mode: vertical-rl; font-size: 13px; letter-spacing: 0.2em; }
  .brand-tag { display: none; }

  .nav-toggle { display: none; }
  .nav-scrim { display: none; }

  .rail-nav {
    position: static;
    flex: 1 1 auto;
    min-height: 0;
    width: auto;
    padding: 0;
    gap: 12px;
    overflow-y: auto;
    overflow-x: hidden;
    background: none;
    border: 0;
    box-shadow: none;
    visibility: visible;
    transform: none;
    scrollbar-width: thin;
    scrollbar-color: rgba(43, 231, 224, 0.35) transparent;
  }
  .rail-nav::-webkit-scrollbar { width: 4px; }
  .rail-nav::-webkit-scrollbar-thumb { background: rgba(43, 231, 224, 0.35); }

  .rail-list { align-items: center; gap: 4px; }

  .rail-link {
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    gap: 4px;
    width: 66px;
    padding: 10px 4px 12px;
    border-left: 0;
    border-top: 2px solid transparent;
  }
  .rail-link::before {
    left: auto;
    right: -12px;
    top: 10px;
    bottom: 10px;
  }
  .rail-link[aria-current="page"] { border-color: rgba(255, 193, 48, 0.45); }

  .rail-glyph {
    position: absolute;
    top: 3px;
    right: 3px;
    font-size: 9px;
    letter-spacing: 0;
  }

  .rail-label {
    writing-mode: vertical-rl;
    font-size: 12px;
    letter-spacing: 0.18em;
  }

  .rail-foot { align-items: center; width: 100%; padding-bottom: 2px; }
  .rail-cta {
    writing-mode: vertical-rl;
    width: auto;
    padding: 14px 10px;
    font-size: 13px;
    letter-spacing: 0.18em;
  }
  .rail-foot .btn-ghost { display: none; }

  .scroll-progress {
    left: auto;
    top: 0;
    bottom: 0;
    width: 3px;
    height: auto;
  }
  .scroll-progress-fill {
    width: 100%;
    height: calc(var(--progress) * 100%);
    background: linear-gradient(180deg, var(--cyan), var(--gold) 68%, var(--magenta));
    transition: height 0.12s linear;
  }
}

/* ---------- 6. 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: 64px;
  background: linear-gradient(180deg, #0d1440, #070b22 70%);
  border-top: 1px solid var(--line-cyan);
  color: var(--white);
}

.footer-cut {
  height: 56px;
  background: linear-gradient(100deg, rgba(43, 231, 224, 0.18), rgba(255, 61, 139, 0.12) 58%, rgba(10, 16, 48, 0));
  clip-path: polygon(0 0, 100% 0, 100% 20%, 0 100%);
}

.footer-shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 48px 16px 0;
}

.footer-top {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.brand-footer { gap: 12px; }

.footer-note {
  max-width: 46ch;
  font-size: 15px;
  line-height: 1.8;
  color: var(--muted);
}

.footer-cols {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

.footer-col-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 14px;
  letter-spacing: 0.16em;
  color: var(--white);
}
.footer-col-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--gold);
  border: 1px solid rgba(255, 193, 48, 0.45);
  border-radius: var(--radius);
  padding: 1px 5px;
}

.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a {
  display: inline-block;
  font-size: 15px;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.footer-links a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
  transform: translateX(3px);
}

.footer-contact { display: flex; flex-direction: column; }
.contact-list { display: flex; flex-direction: column; gap: 14px; }
.contact-list li { display: flex; flex-direction: column; gap: 2px; }
.contact-key {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(159, 179, 217, 0.75);
}
.contact-val { font-size: 15px; color: var(--white); word-break: break-word; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 48px;
  padding: 20px 0 28px;
  border-top: 1px solid var(--line);
}
.footer-legal { font-size: 13px; color: var(--muted); }
.footer-copy { font-size: 13px; color: rgba(159, 179, 217, 0.8); }

@media (min-width: 640px) {
  .footer-cols { grid-template-columns: repeat(3, 1fr); gap: 24px; }
}

@media (min-width: 1024px) {
  .footer-shell { padding: 56px 40px 0; }
  .footer-top {
    grid-template-columns: 1.15fr 1.75fr 1.05fr;
    gap: 48px;
  }
  .brand-footer { flex-direction: row; align-items: center; }
}

/* ---------- 7. 通用布局 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 16px;
}

.section {
  position: relative;
  padding: 64px 0;
}

.section-head { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--cyan);
}

.section-title { margin: 0; }

.section-lead {
  max-width: 62ch;
  font-size: 16px;
  color: var(--muted);
}

.divider-cut {
  height: 2px;
  border: 0;
  background: linear-gradient(90deg, var(--cyan), rgba(43, 231, 224, 0) 64%);
  transform: skewY(-1.2deg);
  transform-origin: left center;
}

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gap);
}
.span-12 { grid-column: span 12; }
.span-8 { grid-column: span 12; }
.span-6 { grid-column: span 12; }
.span-4 { grid-column: span 12; }

.bento {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gap);
}

@media (min-width: 768px) {
  .shell { padding: 0 24px; }
  .section { padding: 80px 0; }
  .span-8 { grid-column: span 8; }
  .span-6 { grid-column: span 6; }
  .span-4 { grid-column: span 4; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento > .is-wide { grid-column: span 2; }
}

@media (min-width: 1024px) {
  .shell { padding: 0 40px; }
  .section { padding: 96px 0; }
  .bento { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- 8. 通用组件 ---------- */
.prose {
  max-width: 68ch;
  font-size: 17px;
  line-height: 1.85;
  color: var(--white);
}
.prose p { margin: 0 0 20px; }
.prose h2, .prose h3 { margin: 40px 0 14px; }
.prose strong { font-weight: 800; color: #ffffff; }
.prose a {
  color: var(--cyan);
  text-decoration: none;
  border-bottom: 1px solid var(--line-cyan);
}
.prose a:hover { border-bottom-color: var(--cyan); }

.panel {
  position: relative;
  padding: 24px;
  background: linear-gradient(180deg, var(--panel-top), var(--panel-btm));
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.card {
  position: relative;
  padding: 24px;
  background: linear-gradient(180deg, var(--panel-top), var(--panel-btm));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.24s var(--ease), border-color 0.24s var(--ease), box-shadow 0.24s var(--ease);
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(43, 231, 224, 0.55);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 22px rgba(43, 231, 224, 0.16);
}
.card-cut::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  width: 26px;
  height: 26px;
  background: var(--ink-deep);
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
  pointer-events: none;
}
.card-title {
  margin: 12px 0 8px;
  font-size: clamp(18px, 2.2vw, 22px);
  letter-spacing: 0.04em;
}
.card-meta { font-size: 13px; color: var(--muted); }

.paper-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: var(--paper);
  color: var(--paper-ink);
  border: 1px solid var(--paper-ink);
  border-radius: var(--radius);
  box-shadow: 3px 3px 0 rgba(27, 20, 16, 0.55);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border: 1px solid currentColor;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.tag-cyan { color: var(--cyan); }
.tag-gold { color: var(--gold); }
.tag-magenta { color: var(--magenta); }
.tag-alert { color: var(--alert); }
.tag-ok { color: var(--ok); }
.tag-paper {
  background: var(--paper);
  color: var(--paper-ink);
  border-color: var(--paper-ink);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.1em;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.btn-gold {
  background: var(--gold);
  color: var(--paper-ink);
  box-shadow: 3px 3px 0 rgba(255, 61, 139, 0.9);
}
.btn-gold:hover {
  transform: translate(-1px, -1px);
  box-shadow: 5px 5px 0 rgba(255, 61, 139, 1), 0 0 20px rgba(255, 193, 48, 0.35);
}

.btn-cyan {
  background: transparent;
  color: var(--cyan);
  border-color: var(--cyan);
}
.btn-cyan:hover {
  background: rgba(43, 231, 224, 0.12);
  box-shadow: 0 0 20px rgba(43, 231, 224, 0.38);
}

.btn-ghost {
  background: rgba(19, 26, 69, 0.55);
  color: var(--white);
  border-color: rgba(159, 179, 217, 0.42);
}
.btn-ghost:hover {
  color: var(--cyan);
  border-color: var(--cyan);
  box-shadow: 0 0 16px rgba(43, 231, 224, 0.26);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 16px 0 0;
  font-size: 13px;
  color: var(--muted);
}
.breadcrumb li { display: inline-flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before {
  content: "/";
  color: rgba(159, 179, 217, 0.5);
}
.breadcrumb a {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid rgba(159, 179, 217, 0.35);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.breadcrumb a:hover { color: var(--cyan); border-bottom-color: var(--cyan); }

.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-value {
  font-family: var(--font-mono);
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: var(--gold);
}
.stat-label {
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

/* 图片容器基础规则（页面阶段直接放置 <img>） */
.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(140deg, var(--navy), var(--ink-deep));
  border: 1px solid var(--line-cyan);
  border-radius: var(--radius);
}
.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(10, 16, 48, 0.24) 0 1px, transparent 1px 3px);
}
.media-frame-wide { aspect-ratio: 21 / 9; }
.media-frame-square { aspect-ratio: 1 / 1; }
.media-frame-tall { aspect-ratio: 3 / 4; }

/* 筛选控件：只筛选当前页面已有内容 */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}
.filter-set {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(19, 26, 69, 0.62);
  color: var(--muted);
  border: 1px solid var(--line-cyan);
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: color 0.2s var(--ease), background-color 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.filter-btn:hover { color: var(--cyan); border-color: var(--cyan); }
.filter-btn[aria-pressed="true"] {
  background: var(--cyan);
  border-color: var(--cyan);
  color: var(--ink-deep);
  box-shadow: 0 0 18px rgba(43, 231, 224, 0.42);
}
.filter-item[hidden] { display: none !important; }
.filter-empty {
  padding: 24px;
  border: 1px dashed var(--line-cyan);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
}
.filter-count {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

/* ---------- 9. 工具类 ---------- */
.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;
}

html.js [data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
html.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- 10. 响应式与动效降级 ---------- */
@media (max-width: 639px) {
  body { background-attachment: scroll, scroll, scroll, scroll; }
  .filter-bar { gap: 10px 14px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  html.js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .scroll-progress-fill { transition: none; }
}
