/* ============================================================
   九五至尊3官网 · 共享站点样式 /assets/site.css
   玄黑为底，鎏金定调，朱砂与青玉只做信号色
   ============================================================ */

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

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

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

ul, ol { list-style: none; }

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

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

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

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

/* ---------- Tokens ---------- */
:root {
  --ink: #0A0B0D;
  --jade-ink: #14161A;
  --char: #1F2228;
  --gold: #C8A24A;
  --gold-light: #E9CE84;
  --gold-deep: #A87C22;
  --cinnabar: #C0483A;
  --jade: #4E8C7A;
  --paper: #F5EFE3;
  --stone: #8C9099;

  --text: #D3D7DE;
  --text-soft: #A9AEB6;
  --text-dim: #7C8189;

  --font-serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", Georgia, serif;
  --font-sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  --font-mono: "JetBrains Mono", "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --maxw: 1280px;
  --gutter: 64px;
  --header-h: 116px;
  --hairline: rgba(200, 162, 74, 0.26);
  --hairline-soft: rgba(200, 162, 74, 0.14);
}

/* ---------- Base typography ---------- */
body {
  background-color: var(--ink);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.85;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  color: var(--paper);
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: 0.01em;
}

strong { color: var(--paper); font-weight: 600; }

::selection {
  background: rgba(200, 162, 74, 0.3);
  color: #FFF7E4;
}

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

/* ---------- Layout primitives ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: 64px; }

.section-head {
  max-width: 46em;
  margin-bottom: 32px;
}

.section-title {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.section--paper {
  background: var(--paper);
  color: #20242B;
}

.section--paper h1,
.section--paper h2,
.section--paper h3,
.section--paper .section-title { color: #171A1F; }

.section--paper .eyebrow { color: var(--gold-deep); }

.section--paper .prose { color: #2C3138; }

.section--paper .prose strong { color: #12151A; }

/* ---------- Text utilities ---------- */
.page-title {
  font-family: var(--font-serif);
  font-size: clamp(1.85rem, 3.4vw, 2.5rem);
  font-weight: 900;
  line-height: 1.3;
  letter-spacing: 0.01em;
  color: var(--paper);
  text-shadow: 0 1px 0 rgba(200, 162, 74, 0.2);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.24em;
  color: var(--gold);
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--gold);
  flex: 0 0 auto;
}

.gold-rule {
  height: 1px;
  border: 0;
  margin-block: 28px;
  background: linear-gradient(90deg, rgba(200, 162, 74, 0.8), rgba(200, 162, 74, 0.14) 58%, transparent);
}

.prose {
  font-size: 16.5px;
  line-height: 1.9;
  color: #C4C8D0;
}

.prose > * + * { margin-top: 1.05em; }

.prose p { max-width: 36em; }

.prose h2,
.prose h3 {
  margin-top: 1.9em;
  letter-spacing: 0.02em;
}

.prose h2 { font-size: clamp(1.35rem, 2.2vw, 1.65rem); font-weight: 700; }
.prose h3 { font-size: 1.15rem; font-weight: 600; }

.prose a {
  color: var(--gold-light);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: rgba(200, 162, 74, 0.45);
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.prose a:hover { color: #FFF0C8; text-decoration-color: var(--gold-light); }

.prose ul,
.prose ol {
  max-width: 36em;
  padding-left: 1.15em;
}

.prose ul li { position: relative; padding-left: 0.2em; list-style: none; }

.prose ul li::before {
  content: "";
  position: absolute;
  left: -0.85em;
  top: 0.85em;
  width: 5px;
  height: 1px;
  background: var(--gold);
}

.prose ol { list-style: decimal; }

.prose blockquote {
  border-left: 1px solid rgba(200, 162, 74, 0.5);
  padding-left: 20px;
  color: var(--text-soft);
  font-family: var(--font-serif);
}

/* ---------- Badges & marks ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  font-size: 12px;
  letter-spacing: 0.08em;
  line-height: 1.5;
  color: var(--gold);
  border: 1px solid rgba(200, 162, 74, 0.42);
  border-radius: 2px;
  background: rgba(200, 162, 74, 0.06);
}

.seal {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(192, 72, 58, 0.55);
  color: var(--cinnabar);
  font-family: var(--font-serif);
  font-size: 14px;
  letter-spacing: 0;
  line-height: 1;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.4;
  border: 1px solid transparent;
  border-radius: 2px;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease,
    background-color 0.2s ease, border-color 0.2s ease;
}

.btn-gold {
  background-image: linear-gradient(120deg, var(--gold-light), var(--gold) 48%, var(--gold-deep));
  color: #1A1206;
  border-color: rgba(233, 206, 132, 0.7);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 10px 24px -16px rgba(200, 162, 74, 0.95);
}

.btn-gold:hover {
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 14px 28px -14px rgba(200, 162, 74, 0.8);
}

.btn-ghost {
  color: var(--gold-light);
  border-color: rgba(200, 162, 74, 0.5);
  background-color: rgba(200, 162, 74, 0.04);
}

.btn-ghost:hover {
  background-color: rgba(200, 162, 74, 0.13);
  border-color: var(--gold);
}

.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 10px 20px;
  background: var(--gold);
  color: #1A1206;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  border-radius: 2px;
  transition: top 0.2s ease;
}

.skip-link:focus { top: 16px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background-color: rgba(10, 11, 13, 0.96);
  color: var(--paper);
  border-bottom: 1px solid var(--hairline);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.header-utility {
  background-color: var(--jade-ink);
  border-bottom: 1px solid var(--hairline-soft);
  font-size: 13px;
  color: var(--stone);
}

.header-utility-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 40px;
  padding-block: 6px;
}

.header-tagline {
  font-size: 12.5px;
  letter-spacing: 0.16em;
  color: var(--stone);
  white-space: nowrap;
}

.header-utility-links {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.utility-link {
  font-size: 12.5px;
  letter-spacing: 0.06em;
  color: #9BA0A9;
  transition: color 0.2s ease;
}

.utility-link:hover { color: var(--gold-light); }

.header-mail {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.01em;
  color: var(--text-dim);
}

.copy-btn {
  padding: 3px 9px;
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: 0.06em;
  color: var(--gold);
  border: 1px solid rgba(200, 162, 74, 0.42);
  border-radius: 2px;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.copy-btn:hover {
  color: var(--gold-light);
  background-color: rgba(200, 162, 74, 0.13);
}

.copy-btn.is-copied {
  color: var(--jade);
  border-color: rgba(78, 140, 122, 0.65);
  background-color: rgba(78, 140, 122, 0.1);
}

.header-main {
  background-image: linear-gradient(180deg, rgba(20, 22, 26, 0.98), rgba(10, 11, 13, 0.98));
}

.header-main-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 76px;
  padding-block: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
}

.brand-mark {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  writing-mode: vertical-rl;
  font-family: var(--font-serif);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  line-height: 1;
  color: var(--gold-light);
  border: 1px solid rgba(200, 162, 74, 0.55);
  background-image: linear-gradient(150deg, rgba(200, 162, 74, 0.18), rgba(200, 162, 74, 0.02));
  flex: 0 0 auto;
}

.brand-mark::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(200, 162, 74, 0.22);
  pointer-events: none;
}

.brand-text { display: block; }

.brand-lockup {
  display: block;
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.2;
  color: var(--paper);
}

.brand-sub {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  letter-spacing: 0.09em;
  line-height: 1.4;
  color: var(--stone);
}

/* ---------- Navigation ---------- */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  font-size: 13px;
  letter-spacing: 0.16em;
  color: var(--gold-light);
  border: 1px solid rgba(200, 162, 74, 0.42);
  border-radius: 2px;
}

.nav-toggle-bar {
  position: relative;
  display: block;
  width: 18px;
  height: 1px;
  background-color: var(--gold-light);
  transition: background-color 0.2s ease;
}

.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 1px;
  background-color: var(--gold-light);
  transition: transform 0.25s ease;
}

.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after { top: 6px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background-color: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateY(-6px) rotate(-45deg); }

.nav-toggle-text { line-height: 1; }

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

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

.nav-item { flex: 0 0 auto; }

.nav-link {
  position: relative;
  display: block;
  padding: 10px 13px;
  font-size: 15px;
  letter-spacing: 0.02em;
  line-height: 1.5;
  color: #BFC3CA;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 13px;
  right: 13px;
  bottom: 5px;
  height: 1px;
  background-image: linear-gradient(90deg, var(--gold), rgba(200, 162, 74, 0));
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.28s ease;
}

.nav-link:hover { color: var(--gold-light); }
.nav-link:hover::after { transform: scaleX(1); }

.nav-link[aria-current="page"] {
  color: var(--gold-light);
  font-weight: 600;
}

.nav-link[aria-current="page"]::after {
  transform: scaleX(1);
  background-image: linear-gradient(90deg, var(--gold), rgba(200, 162, 74, 0.15));
}

.nav-cta { margin-left: 14px; }

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background-image: linear-gradient(90deg, var(--gold-deep), var(--gold-light));
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.1s linear;
  pointer-events: none;
  z-index: 2;
}

/* ---------- Breadcrumb ---------- */
.breadcrumb { margin-bottom: 20px; }

.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--stone);
}

.breadcrumb-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb-list li + li::before {
  content: "／";
  color: rgba(200, 162, 74, 0.5);
  font-size: 12px;
}

.breadcrumb-list a {
  color: #A7ACB4;
  transition: color 0.2s ease;
}

.breadcrumb-list a:hover { color: var(--gold-light); }

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

/* ---------- Figure (reusable image container) ---------- */
.figure {
  --figure-ratio: 4 / 3;
  position: relative;
  margin: 0;
  padding: 6px;
  border: 1px solid rgba(200, 162, 74, 0.32);
  background-image: linear-gradient(160deg, rgba(200, 162, 74, 0.08), rgba(10, 11, 13, 0) 62%);
}

.figure-img {
  aspect-ratio: var(--figure-ratio);
  overflow: hidden;
  background-image: linear-gradient(150deg, #15181D, #0C0E11);
}

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

.figure-caption {
  margin-top: 10px;
  padding: 0 2px 2px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--stone);
}

.figure--portrait { --figure-ratio: 3 / 4; }
.figure--wide { --figure-ratio: 16 / 9; }
.figure--square { --figure-ratio: 1 / 1; }

/* ---------- Reveal ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

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

/* ---------- Anchor list highlight ---------- */
[data-toc] a[aria-current="true"] {
  color: var(--gold-light);
  font-weight: 600;
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  margin-top: 0;
  padding-top: 64px;
  background-image: linear-gradient(180deg, #0F1114, #0A0B0D 62%);
  border-top: 1px solid var(--hairline);
  color: #B9BDC5;
}

.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background-image: linear-gradient(90deg, transparent, rgba(233, 206, 132, 0.7), transparent);
  pointer-events: none;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 2fr;
  gap: 56px;
  padding-bottom: 44px;
}

.footer-brand { max-width: 34em; }

.footer-lockup {
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 900;
  letter-spacing: 0.12em;
  line-height: 1.2;
  color: var(--paper);
}

.footer-tagline {
  margin-top: 10px;
  font-size: 12.5px;
  letter-spacing: 0.18em;
  color: var(--gold);
}

.footer-note {
  margin-top: 16px;
  max-width: 32em;
  font-size: 14px;
  line-height: 1.85;
  color: #8F949D;
}

.footer-seal {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-top: 24px;
  border: 1px solid rgba(192, 72, 58, 0.55);
  border-radius: 50%;
  color: var(--cinnabar);
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 1;
  opacity: 0.85;
}

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

.footer-col-title {
  margin-bottom: 16px;
  padding-bottom: 10px;
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.16em;
  line-height: 1.4;
  color: var(--paper);
  border-bottom: 1px solid rgba(200, 162, 74, 0.22);
}

.footer-col-list li + li { margin-top: 10px; }

.footer-col-list a {
  font-size: 14px;
  line-height: 1.7;
  color: #A2A7B0;
  transition: color 0.2s ease;
}

.footer-col-list a:hover { color: var(--gold-light); }

.footer-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 40px;
  padding-top: 26px;
  padding-bottom: 26px;
  border-top: 1px solid var(--hairline-soft);
  font-size: 13px;
}

.footer-contact-line {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.footer-contact-label {
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--gold);
}

.footer-contact-value {
  font-size: 13px;
  letter-spacing: 0.02em;
  color: #A9AEB6;
}

.footer-legal {
  padding-block: 18px;
  background-color: #08090B;
  border-top: 1px solid var(--hairline-soft);
}

.footer-legal-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 28px;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: #6E737C;
}

.footer-copy,
.footer-hours { color: #6E737C; }

.footer-icp {
  font-family: var(--font-mono);
  font-size: 12px;
  color: #7C8189;
}

/* ---------- Back to top ---------- */
.to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 80;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(200, 162, 74, 0.5);
  border-radius: 50%;
  background-color: rgba(10, 11, 13, 0.88);
  color: var(--gold-light);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease,
    border-color 0.2s ease, background-color 0.2s ease;
}

.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.to-top:hover {
  border-color: var(--gold-light);
  background-color: rgba(20, 22, 26, 0.96);
}

.to-top-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(200, 162, 74, 0.07);
  pointer-events: none;
}

.to-top-arrow {
  font-size: 16px;
  line-height: 1;
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .header-mail { display: none; }
}

@media (max-width: 1080px) {
  .nav-link { padding: 10px 9px; font-size: 14px; }
  .nav-link::after { left: 9px; right: 9px; }
  .nav-cta { margin-left: 8px; }
}

@media (max-width: 1024px) {
  :root { --gutter: 32px; }

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

  .footer-brand { max-width: none; }
}

@media (max-width: 900px) {
  html { scroll-padding-top: 88px; }

  .header-utility { display: none; }

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

  .site-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 6px 20px 22px;
    background-image: linear-gradient(180deg, #14161A, #0A0B0D);
    border-top: 1px solid rgba(200, 162, 74, 0.25);
    border-bottom: 1px solid rgba(200, 162, 74, 0.25);
    box-shadow: 0 26px 42px -26px rgba(0, 0, 0, 0.95);
    max-height: calc(100vh - 80px);
    overflow-y: auto;
  }

  .site-nav[data-open] { display: flex; }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav-link {
    padding: 14px 4px;
    font-size: 16px;
    border-bottom: 1px solid rgba(200, 162, 74, 0.12);
  }

  .nav-link::after {
    left: 4px;
    right: auto;
    width: 22px;
    bottom: 9px;
  }

  .nav-cta {
    margin: 20px 0 0;
    width: 100%;
  }

  .section { padding-block: 44px; }
}

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

@media (max-width: 640px) {
  :root { --gutter: 20px; }

  .brand-sub { display: none; }
  .brand-lockup { font-size: 18px; }
  .brand-mark { width: 38px; height: 38px; }

  .prose { font-size: 16px; }

  .site-footer { padding-top: 44px; }

  .footer-top { padding-bottom: 32px; }

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

  .footer-contact {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .footer-legal-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .to-top {
    right: 16px;
    bottom: 16px;
    width: 42px;
    height: 42px;
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

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

  .scroll-progress { transition: none; }
}
