/* ==========================================================================
   site.css — 新豪门娱乐 共享外壳
   1 Reset / 2 变量 / 3 中文排版 / 4 门牌轨道 / 5 页脚 / 6 通用组件 / 7 响应式
   ========================================================================== */

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

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

body, h1, h2, h3, h4, h5, p, figure, blockquote, ul, ol, li, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
img, svg, video { display: block; max-width: 100%; }

/* ---------- 2 变量 ---------- */
:root {
  --ink: #0A0A0C;
  --obsidian: #14141A;
  --umber: #241C18;
  --gold: #C9A86A;
  --gold-light: #E8D6AE;
  --gold-deep: #6E5635;
  --cinnabar: #CE4633;
  --cinnabar-lift: #D8523E;
  --silver: #B9C0C9;
  --smoke: #707780;
  --paper: #F3EBDD;

  --hair: rgba(201, 168, 106, .30);
  --hair-soft: rgba(201, 168, 106, .14);
  --veil: rgba(201, 168, 106, .08);
  --shadow-gold: rgba(110, 86, 53, .38);

  --font-head: "Songti SC", "Source Han Serif SC", "Noto Serif CJK SC", Georgia, "Times New Roman", serif;
  --font-body: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --rail-w: 282px;
  --rail-top-h: 66px;
  --shell-max: 1160px;
  --pad-x: clamp(20px, 4.2vw, 52px);

  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-pill: 999px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* ---------- 3 中文排版与全局底色 ---------- */
body {
  min-height: 100vh;
  background-color: var(--ink);
  background-image:
    radial-gradient(90% 60% at 86% -12%, rgba(110, 86, 53, .22), transparent 62%),
    radial-gradient(72% 52% at -4% 104%, rgba(36, 28, 24, .55), transparent 64%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: var(--silver);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.78;
  letter-spacing: .012em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-wrap: break-word;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: .01em;
  color: var(--gold-light);
}

h1 { font-size: clamp(38px, 5.4vw, 76px); }
h2 { font-size: clamp(26px, 3.4vw, 42px); }
h3 { font-size: clamp(20px, 2.2vw, 26px); }

p { text-wrap: pretty; }

strong, b { font-weight: 600; color: var(--gold-light); }

::selection { background: var(--cinnabar); color: var(--paper); }

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

#main-content:focus-visible { outline: 2px solid var(--gold); outline-offset: -4px; }

/* ---------- 4 门牌轨道（头部） ---------- */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 300;
  display: inline-block;
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  background: var(--gold-light);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .04em;
  transform: translateY(-180%);
  transition: transform .22s var(--ease);
}

.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid var(--cinnabar);
  outline-offset: 3px;
}

.site-rail {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  width: var(--rail-w);
  padding: 34px 24px 26px;
  overflow-y: auto;
  background:
    linear-gradient(180deg, rgba(36, 28, 24, .92) 0%, rgba(10, 10, 12, 0) 46%),
    var(--ink);
  border-right: 1px solid var(--hair-soft);
  scrollbar-width: thin;
  scrollbar-color: var(--gold-deep) transparent;
}

.site-rail::after {
  content: "";
  position: absolute;
  top: 0;
  right: -1px;
  width: 1px;
  height: 190px;
  background: linear-gradient(180deg, var(--gold), transparent);
  opacity: .55;
  pointer-events: none;
}

.rail-progress {
  position: fixed;
  top: 0;
  left: calc(var(--rail-w) - 2px);
  z-index: 61;
  width: 2px;
  height: 100vh;
  background: rgba(201, 168, 106, .14);
  overflow: hidden;
  pointer-events: none;
}

.rail-progress__bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleY(var(--scroll-progress, 0));
  transform-origin: 50% 0;
  background: linear-gradient(180deg, var(--gold-light), var(--gold) 56%, var(--gold-deep));
  transition: transform .14s linear;
}

.rail-top { display: block; }

.rail-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--hair-soft);
}

.rail-brand__mark {
  flex: none;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 15px;
  border: 1px solid var(--gold);
  background: linear-gradient(150deg, rgba(201, 168, 106, .26), rgba(110, 86, 53, .06));
  color: var(--gold-light);
  font-family: var(--font-head);
  font-size: 20px;
  line-height: 1;
  box-shadow: inset 0 0 0 3px rgba(10, 10, 12, .55);
}

.rail-brand__text { display: block; min-width: 0; }

.rail-brand__line {
  display: block;
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: .02em;
}

.rail-brand__tag {
  display: block;
  margin-top: 3px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .06em;
  color: var(--silver);
  opacity: .72;
}

.rail-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 8px 15px 8px 13px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-pill);
  color: var(--gold-light);
  font-size: 13px;
  letter-spacing: .08em;
  transition: border-color .2s var(--ease), background .2s var(--ease), color .2s var(--ease);
}

.rail-toggle:hover { border-color: var(--gold); background: var(--veil); }

.rail-toggle__bars {
  display: grid;
  gap: 4px;
  width: 16px;
}

.rail-toggle__bars span {
  display: block;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .26s var(--ease), opacity .2s var(--ease);
}

.site-rail[data-open] .rail-toggle {
  border-color: var(--gold);
  color: var(--gold-light);
  background: var(--veil);
}

.site-rail[data-open] .rail-toggle__bars span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.site-rail[data-open] .rail-toggle__bars span:nth-child(2) { opacity: 0; }
.site-rail[data-open] .rail-toggle__bars span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

.rail-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 24px;
}

.rail-nav__label {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: .8;
}

.rail-nav__list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rail-link {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 11px 15px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  color: var(--silver);
  font-size: 15px;
  line-height: 1.4;
  transition: color .2s var(--ease), background .2s var(--ease), border-color .2s var(--ease);
}

.rail-link__idx {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--gold-deep);
  transition: color .2s var(--ease);
}

.rail-link__name { font-weight: 500; }

.rail-link:hover {
  color: var(--gold-light);
  background: var(--veil);
  border-color: var(--hair-soft);
}

.rail-link:hover .rail-link__idx { color: var(--gold); }

.rail-link[aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
  background: linear-gradient(118deg, var(--gold-light), var(--gold));
  border-color: var(--gold);
  box-shadow: 0 8px 22px rgba(110, 86, 53, .34);
}

.rail-link[aria-current="page"] .rail-link__idx {
  color: var(--ink);
  opacity: .62;
}

.rail-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  margin-top: 20px;
  padding: 0 22px;
  border-radius: var(--radius-pill);
  background: var(--cinnabar);
  color: #FBF3E6;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .06em;
  box-shadow: 0 10px 24px rgba(206, 70, 51, .26);
  transition: transform .2s var(--ease), background .2s var(--ease), box-shadow .2s var(--ease);
}

.rail-cta:hover {
  transform: translateY(-2px);
  background: var(--cinnabar-lift);
  box-shadow: 0 14px 30px rgba(206, 70, 51, .34);
}

.rail-meta {
  display: grid;
  gap: 2px;
  margin-top: auto;
  padding-top: 26px;
  border-top: 1px solid var(--hair-soft);
}

.rail-meta__k {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--smoke);
}

.rail-meta__k:first-child { margin-top: 0; }

.rail-meta__v {
  font-size: 13px;
  line-height: 1.6;
  color: var(--silver);
  opacity: .92;
}

.rail-meta__v--mono {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .02em;
}

/* ---------- 5 页脚 ---------- */
.site-foot {
  margin-top: clamp(56px, 8vw, 112px);
  padding: clamp(44px, 6vw, 78px) var(--pad-x) 30px;
  background: linear-gradient(180deg, var(--obsidian) 0%, var(--umber) 100%);
  border-top: 1px solid var(--hair-soft);
}

.foot-shell {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
}

.foot-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.35fr;
  gap: clamp(24px, 3.6vw, 54px);
}

.foot-brand__mark {
  font-family: var(--font-head);
  font-size: clamp(24px, 2.8vw, 32px);
  font-weight: 700;
  line-height: 1.2;
  color: var(--gold-light);
  letter-spacing: .05em;
}

.foot-brand__line {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .14em;
  color: var(--gold);
}

.foot-brand__summary {
  margin-top: 16px;
  max-width: 34ch;
  font-size: 14px;
  line-height: 1.82;
  color: var(--silver);
}

.foot-col__title {
  margin-bottom: 15px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: .86;
}

.foot-list {
  display: grid;
  gap: 10px;
}

.foot-list a {
  font-size: 14.5px;
  color: var(--silver);
  transition: color .2s var(--ease), padding-left .2s var(--ease);
}

.foot-list a:hover {
  color: var(--gold-light);
  padding-left: 4px;
}

.foot-meta {
  display: grid;
  gap: 13px;
}

.foot-meta li { display: grid; gap: 2px; }

.foot-meta__k {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--smoke);
}

.foot-meta__v {
  font-size: 14px;
  line-height: 1.6;
  color: var(--silver);
  overflow-wrap: anywhere;
}

.foot-note {
  margin-top: clamp(28px, 4vw, 46px);
  padding-top: 20px;
  border-top: 1px solid var(--hair-soft);
  font-size: 13px;
  line-height: 1.8;
  color: var(--silver);
  opacity: .84;
}

.foot-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 28px;
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid var(--hair-soft);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--silver);
}

.foot-bar__copy,
.foot-bar__icp { opacity: .72; }

.foot-bar__icp { color: var(--gold); opacity: .8; }

.foot-bar__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.foot-bar__links a {
  color: var(--silver);
  transition: color .2s var(--ease);
}

.foot-bar__links a:hover { color: var(--gold-light); }

/* ---------- 6 通用组件 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.section { padding-block: clamp(48px, 7vw, 92px); }

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

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

.card {
  position: relative;
  padding: clamp(20px, 3vw, 30px);
  border: 1px solid var(--hair-soft);
  border-radius: var(--radius-lg);
  background: var(--obsidian);
  overflow: hidden;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(148deg, rgba(201, 168, 106, .10), transparent 48%);
  opacity: 0;
  transition: opacity .3s var(--ease);
}

.card:hover::after { opacity: 1; }

.media-frame {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--hair-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 18% 0%, rgba(201, 168, 106, .18), transparent 60%),
    linear-gradient(160deg, #1B1A20 0%, #0D0D11 58%, var(--umber) 100%);
}

.media-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(90deg, rgba(201, 168, 106, .10) 1px, transparent 1px),
    linear-gradient(0deg, rgba(201, 168, 106, .07) 1px, transparent 1px);
  background-size: 52px 52px, 52px 52px;
  opacity: .55;
}

.media-frame > img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .05em;
  transition: transform .2s var(--ease), background .2s var(--ease), border-color .2s var(--ease), box-shadow .2s var(--ease), color .2s var(--ease);
}

.btn--primary {
  background: var(--cinnabar);
  color: #FBF3E6;
  box-shadow: 0 10px 26px rgba(206, 70, 51, .26);
}

.btn--primary:hover {
  transform: translateY(-2px);
  background: var(--cinnabar-lift);
  box-shadow: 0 14px 30px rgba(206, 70, 51, .34);
}

.btn--ghost {
  border-color: var(--hair);
  color: var(--gold-light);
  background: transparent;
}

.btn--ghost:hover {
  border-color: var(--gold);
  background: var(--veil);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
}

.pill--live {
  border-color: rgba(206, 70, 51, .5);
  background: rgba(206, 70, 51, .12);
  color: #F0A08F;
}

.eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
}

.section-title {
  font-family: var(--font-head);
  font-size: clamp(26px, 3.4vw, 42px);
  color: var(--gold-light);
}

.divider {
  height: 1px;
  border: 0;
  background: linear-gradient(90deg, var(--hair), transparent);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .08em;
  color: var(--smoke);
}

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

.breadcrumb li + li::before {
  content: "›";
  color: var(--gold-deep);
}

.breadcrumb a { color: var(--silver); transition: color .2s var(--ease); }
.breadcrumb a:hover { color: var(--gold-light); }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ---------- 7 响应式 ---------- */
@media (max-width: 1080px) {
  .foot-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .foot-col:last-child { grid-column: 1 / -1; }
}

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

  body {
    background-attachment: scroll;
    padding-left: 0;
  }

  .site-rail {
    position: sticky;
    inset: auto;
    top: 0;
    display: block;
    width: 100%;
    max-height: 100dvh;
    padding: 0;
    overflow-y: auto;
    background: rgba(10, 10, 12, .96);
    border-right: 0;
    border-bottom: 1px solid var(--hair-soft);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
  }

  .site-rail::after { display: none; }

  .rail-progress {
    position: absolute;
    top: auto;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
  }

  .rail-progress__bar {
    transform: scaleX(var(--scroll-progress, 0));
    transform-origin: 0 50%;
    background: linear-gradient(90deg, var(--gold-deep), var(--gold) 55%, var(--gold-light));
  }

  .rail-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: var(--rail-top-h);
    padding: 10px var(--pad-x);
  }

  .rail-brand {
    gap: 10px;
    padding-bottom: 0;
    border-bottom: 0;
    min-width: 0;
  }

  .rail-brand__mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: 17px;
  }

  .rail-brand__line { font-size: 13.5px; }
  .rail-brand__tag { font-size: 10px; letter-spacing: .04em; }

  .rail-toggle { display: inline-flex; flex: none; }

  .rail-nav {
    display: none;
    gap: 4px;
    margin-top: 0;
    padding: 14px var(--pad-x) 20px;
    border-top: 1px solid var(--hair-soft);
  }

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

  .rail-nav__list {
    grid-template-columns: 1fr;
  }

  .rail-link {
    padding: 12px 16px;
    font-size: 15.5px;
  }

  .rail-cta { margin-top: 16px; }

  .rail-meta {
    display: none;
    margin-top: 0;
    padding: 0 var(--pad-x) 24px;
    border-top: 0;
  }

  .site-rail[data-open] .rail-meta { display: grid; }

  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .media-frame--wide { aspect-ratio: 16 / 9; }
}

@media (max-width: 860px) {
  .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-col:last-child { grid-column: 1 / -1; }
  .foot-brand { grid-column: 1 / -1; }
}

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

  .foot-grid { grid-template-columns: 1fr; }

  .foot-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

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

@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;
  }
}
