/* ==========================================================================
   a8棋牌俱乐部 · 共享样式表 /assets/site.css
   高原棋牌俱乐部 × 电玩厅 —— 奶油纸张、印刷描边、叠层卡片
   ========================================================================== */

/* 1. 设计变量 -------------------------------------------------------------- */
:root {
  --lake: #1F6F8B;
  --lake-deep: #15485C;
  --ochre: #C96F3B;
  --ochre-deep: #A9542A;
  --gold: #D9A441;
  --indigo: #3A2E5C;
  --table: #2E6B57;
  --neon: #5FD3C4;
  --cream: #F7F0E2;
  --paper: #FFF9EF;
  --ink: #2B211C;
  --mist: #DCE8EA;
  --peach: #F3D9C6;

  --font-display: "Yuanti SC", "YouYuan", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;

  --maxw: 1180px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 76px;
  --radius: 16px;
  --radius-sm: 10px;

  --shadow-paper: 0 1px 0 rgba(43, 33, 28, .06), 0 14px 28px -22px rgba(43, 33, 28, .78);
  --shadow-lift: 0 22px 42px -26px rgba(21, 72, 92, .85);
}

@media (max-width: 900px) {
  :root { --header-h: 66px; }
}

/* 2. 重置与基础 ------------------------------------------------------------ */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 20px);
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--cream);
  background-image:
    radial-gradient(circle at 10% 6%, rgba(201, 111, 59, .09), transparent 44%),
    radial-gradient(circle at 92% 3%, rgba(31, 111, 139, .10), transparent 48%);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

:where(h1, h2, h3, h4, h5, h6) {
  margin: 0 0 .55em;
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.16;
  letter-spacing: .005em;
  color: var(--ink);
}

:where(p, ul, ol, dl, figure, blockquote, pre) { margin: 0 0 1.1em; }
:where(ul, ol) { padding-left: 1.35em; }
:where(button) { font: inherit; }
:where(a) { color: var(--lake); text-underline-offset: 3px; }

::selection { background: var(--gold); color: var(--ink); }

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

.site-footer :focus-visible { outline-color: var(--gold); }

/* 3. 跳转链接 -------------------------------------------------------------- */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  transform: translateY(-180%);
  padding: 11px 20px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: var(--paper);
  box-shadow: var(--shadow-paper);
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  transition: transform .2s ease;
}

.skip-link:focus,
.skip-link:focus-visible { transform: translateY(0); }

/* 4. 头部 ------------------------------------------------------------------ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  color: var(--paper);
  background: linear-gradient(180deg, rgba(21, 72, 92, .78) 0%, rgba(21, 72, 92, .38) 62%, rgba(21, 72, 92, 0) 100%);
  transition: background .3s ease, box-shadow .3s ease;
}

.site-header.is-solid,
.site-header[data-open] {
  background: var(--lake-deep);
  box-shadow: 0 16px 30px -24px rgba(0, 0, 0, .95);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2vw, 26px);
  max-width: var(--maxw);
  min-height: var(--header-h);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* 品牌 */
.brand {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 11px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  background: var(--ochre);
  box-shadow: inset 0 0 0 2px rgba(255, 249, 239, .55), 0 8px 16px -12px rgba(0, 0, 0, .95);
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -.04em;
}

.brand-text { display: block; }

.brand-name {
  display: block;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: .02em;
}

.brand-tag {
  display: block;
  margin-top: 1px;
  color: var(--gold);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .26em;
  line-height: 1.4;
}

/* 导航 */
.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.5vw, 18px);
  margin-left: auto;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-link {
  display: inline-block;
  padding: 9px 13px;
  border-radius: 999px;
  color: rgba(255, 249, 239, .9);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition: background .2s ease, color .2s ease;
}

.nav-link:hover {
  background: rgba(255, 249, 239, .15);
  color: var(--paper);
}

.nav-link[aria-current="page"] {
  background: var(--ochre);
  box-shadow: 0 8px 18px -14px rgba(0, 0, 0, .95);
  color: var(--paper);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 16px;
  border: 2px solid var(--gold);
  border-radius: 999px;
  color: var(--gold);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}

.nav-cta:hover {
  background: var(--gold);
  color: var(--lake-deep);
  transform: translateY(-1px);
}

/* 移动菜单按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  margin-left: auto;
  padding: 10px 16px;
  border: 2px solid rgba(255, 249, 239, .55);
  border-radius: 12px;
  background: rgba(21, 72, 92, .72);
  color: var(--paper);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease;
}

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

.nav-toggle-bars {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 -6px 0 currentColor, 0 6px 0 currentColor;
  transition: background .2s ease, box-shadow .2s ease;
}

.site-header[data-open] .nav-toggle-bars {
  background: transparent;
  box-shadow: none;
}

.site-header[data-open] .nav-toggle-bars::before,
.site-header[data-open] .nav-toggle-bars::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--paper);
}

.site-header[data-open] .nav-toggle-bars::before { transform: rotate(45deg); }
.site-header[data-open] .nav-toggle-bars::after { transform: rotate(-45deg); }

/* 滚动进度 */
.scroll-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  display: block;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--ochre) 0%, var(--gold) 55%, var(--neon) 100%);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform .12s linear;
}

/* 中屏压缩 */
@media (min-width: 901px) and (max-width: 1080px) {
  .brand-tag { display: none; }
  .nav-link { padding: 8px 9px; font-size: 14px; }
  .nav-cta { padding: 8px 12px; font-size: 13px; }
}

/* 移动端抽屉 */
@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-left: 0;
    padding: 0 var(--gutter);
    border-top: 3px solid var(--gold);
    background: var(--lake-deep);
    box-shadow: 0 26px 36px -28px rgba(0, 0, 0, .95);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: max-height .34s ease, opacity .24s ease, visibility .24s ease, padding .24s ease;
  }

  .site-header[data-open] .site-nav {
    max-height: min(78vh, 620px);
    overflow-y: auto;
    padding-bottom: 18px;
    opacity: 1;
    visibility: visible;
  }

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

  .nav-link {
    display: block;
    padding: 15px 14px;
    border-bottom: 1px solid rgba(255, 249, 239, .14);
    border-radius: 0;
    font-size: 17px;
  }

  .nav-link[aria-current="page"] {
    border-radius: 10px;
    border-bottom-color: transparent;
    margin: 6px 0;
  }

  .nav-cta {
    margin: 16px 0 4px;
    padding: 14px;
    font-size: 16px;
  }
}

/* 5. 页脚 ------------------------------------------------------------------ */
.site-footer {
  position: relative;
  margin-top: clamp(48px, 8vw, 96px);
  border-top: 4px solid var(--gold);
  background: var(--lake-deep);
  color: rgba(255, 249, 239, .86);
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(240px, 1.6fr) minmax(140px, 1fr) minmax(140px, 1fr) minmax(200px, 1.3fr);
  gap: clamp(24px, 4vw, 52px);
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(40px, 6vw, 68px) var(--gutter) clamp(26px, 4vw, 44px);
}

.footer-brand { min-width: 0; }

.footer-mark {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
  border-radius: 16px;
  background: var(--ochre);
  box-shadow: inset 0 0 0 2px rgba(255, 249, 239, .5);
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -.04em;
}

.footer-title {
  margin: 0 0 10px;
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: .02em;
  line-height: 1.2;
}

.footer-intro {
  max-width: 34ch;
  margin: 0 0 16px;
  color: rgba(255, 249, 239, .76);
  font-size: 15px;
  line-height: 1.8;
}

.footer-stamp {
  display: inline-block;
  margin: 0;
  padding: 6px 14px;
  border: 1px dashed rgba(217, 164, 65, .75);
  border-radius: 6px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  transform: rotate(-1.2deg);
}

.footer-col { min-width: 0; }

.footer-heading {
  margin: 0 0 14px;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .24em;
  line-height: 1.4;
}

.footer-links {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a {
  display: inline-block;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  color: rgba(255, 249, 239, .88);
  font-size: 15px;
  text-decoration: none;
  transition: color .2s ease, border-color .2s ease;
}

.footer-links a:hover {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

.footer-note {
  margin: 0 0 14px;
  color: rgba(255, 249, 239, .74);
  font-size: 14px;
  line-height: 1.7;
}

.footer-contact {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 249, 239, .88);
  font-size: 14px;
  line-height: 1.6;
  word-break: break-word;
}

.footer-label {
  display: inline-block;
  min-width: 44px;
  margin-right: 8px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 26px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 16px var(--gutter) 30px;
  border-top: 1px solid rgba(217, 164, 65, .4);
  color: rgba(255, 249, 239, .62);
  font-size: 13px;
  line-height: 1.7;
}

.footer-base p { margin: 0; }

@media (max-width: 1000px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
  .footer-inner { grid-template-columns: 1fr; }
  .footer-stamp { transform: none; }
  .footer-base { flex-direction: column; }
}

/* 6. 布局工具 -------------------------------------------------------------- */
#main-content {
  display: block;
  padding-top: var(--header-h);
}

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: clamp(32px, 5.5vw, 68px); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 24px;
  margin-bottom: clamp(20px, 3vw, 34px);
}

.section-head > * { margin-bottom: 0; }

.grid {
  display: grid;
  gap: clamp(14px, 2.4vw, 26px);
}

.grid--2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }

.bento {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 22px);
}

.bento > * { min-width: 0; }

@media (max-width: 700px) {
  .bento { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

.rail {
  display: flex;
  gap: 16px;
  padding-bottom: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--ochre) transparent;
  -webkit-overflow-scrolling: touch;
}

.rail > * {
  flex: 0 0 clamp(240px, 72vw, 340px);
  scroll-snap-align: start;
}

.rail::-webkit-scrollbar { height: 8px; }
.rail::-webkit-scrollbar-track { background: var(--mist); border-radius: 999px; }
.rail::-webkit-scrollbar-thumb { background: var(--ochre); border-radius: 999px; }

/* 7. 排版工具 -------------------------------------------------------------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--lake);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .2em;
  line-height: 1.4;
}

.eyebrow::before {
  content: "";
  width: 26px;
  height: 3px;
  border-radius: 2px;
  background: var(--ochre);
}

.section-num {
  display: block;
  color: var(--ochre);
  font-family: var(--font-display);
  font-size: clamp(38px, 6vw, 64px);
  font-weight: 900;
  letter-spacing: -.03em;
  line-height: .92;
}

.prose {
  max-width: 72ch;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.85;
}

.prose > :last-child { margin-bottom: 0; }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  color: rgba(43, 33, 28, .8);
  font-size: 14px;
}

.breadcrumbs a {
  color: var(--lake);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.breadcrumbs a:hover { color: var(--ochre); }

.breadcrumbs li:not(:first-child)::before {
  content: "/";
  margin: 0 8px;
  color: var(--ochre);
  font-weight: 800;
}

/* 8. 按钮 ------------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: 2px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
}

.btn--primary {
  background: var(--ochre);
  color: var(--paper);
  box-shadow: 0 12px 24px -16px rgba(201, 111, 59, .95);
}

.btn--primary:hover {
  background: var(--ochre-deep);
  transform: translateY(-2px);
}

.btn--lake {
  background: var(--lake);
  color: var(--paper);
  box-shadow: 0 12px 24px -16px rgba(31, 111, 139, .95);
}

.btn--lake:hover {
  background: var(--lake-deep);
  transform: translateY(-2px);
}

.btn--outline {
  border-color: var(--ink);
  background: transparent;
  color: var(--ink);
}

.btn--outline:hover {
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-2px);
}

.btn--gold {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--lake-deep);
}

.btn--gold:hover {
  background: #c8912f;
  transform: translateY(-2px);
}

.btn--sm {
  padding: 9px 18px;
  font-size: 14px;
}

/* 9. 标签 ------------------------------------------------------------------ */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--mist);
  color: var(--lake-deep);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.7;
}

.tag--ochre { background: var(--peach); color: #8A431C; }
.tag--gold { background: rgba(217, 164, 65, .26); color: #7E5A10; }
.tag--table { background: rgba(46, 107, 87, .16); color: var(--table); }
.tag--neon { background: rgba(95, 211, 196, .3); color: #14545C; }

/* 10. 卡片 ---------------------------------------------------------------- */
.card {
  position: relative;
  padding: clamp(18px, 2.6vw, 28px);
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-paper);
}

.card--lift { transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; }

.card--lift:hover {
  border-color: var(--gold);
  box-shadow: var(--shadow-lift);
  transform: translateY(-4px);
}

.paper-stack { position: relative; z-index: 0; }

.paper-stack::before {
  content: "";
  position: absolute;
  inset: 10px -8px -8px 10px;
  z-index: -1;
  border: 2px solid rgba(21, 72, 92, .26);
  border-radius: var(--radius);
  background: rgba(255, 249, 239, .55);
}

/* 11. 图片容器基础 --------------------------------------------------------- */
.media {
  position: relative;
  display: block;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--mist);
}

.media > img,
.media > picture > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media--16x9 { aspect-ratio: 16 / 9; }
.media--4x3 { aspect-ratio: 4 / 3; }
.media--1x1 { aspect-ratio: 1 / 1; }
.media--wide { aspect-ratio: 21 / 9; }

.media__caption {
  margin: 10px 0 0;
  color: rgba(43, 33, 28, .72);
  font-size: 13px;
  line-height: 1.7;
}

@media (max-width: 700px) {
  .media--wide { aspect-ratio: 16 / 9; }
}

/* 12. 封面首屏基础 --------------------------------------------------------- */
.hero-cover {
  position: relative;
  margin-top: calc(var(--header-h) * -1);
  padding-top: calc(var(--header-h) + clamp(48px, 9vw, 96px));
  padding-bottom: clamp(48px, 8vw, 92px);
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 84% 6%, rgba(95, 211, 196, .22), transparent 58%),
    radial-gradient(90% 80% at 8% 92%, rgba(201, 111, 59, .32), transparent 62%),
    linear-gradient(155deg, var(--lake-deep) 0%, var(--indigo) 62%, #241D3D 100%);
  color: var(--paper);
}

.hero-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 249, 239, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 249, 239, .07) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none;
}

.hero-cover > * {
  position: relative;
  z-index: 1;
}

.hero-cover :where(h1, h2, h3, p, li) { color: inherit; }

/* 13. 动效 ---------------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .55s ease, transform .55s ease;
}

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

.to-top {
  position: fixed;
  right: clamp(14px, 3vw, 28px);
  bottom: clamp(14px, 3vw, 28px);
  z-index: 90;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  box-shadow: var(--shadow-paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  cursor: pointer;
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease, background .2s ease, color .2s ease, border-color .2s ease;
}

.to-top.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.to-top:hover {
  border-color: var(--ochre);
  background: var(--ochre);
  color: var(--paper);
}

/* 14. 减少动态 ------------------------------------------------------------ */
@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;
  }

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

  .to-top { transition: none; }
}
