/* ── Shared site stylesheet — Xiantang.life ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: #F5EFE6;
  color: #3B2A35;
  font-family: 'Noto Sans SC', -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

:root {
  --cream: #F5EFE6;
  --terracotta: #C2603F;
  --terracotta-light: rgba(194, 96, 63, 0.08);
  --sage: #8A9A82;
  --sage-light: rgba(138, 154, 130, 0.15);
  --plum: #3B2A35;
  --plum-90: rgba(59, 42, 53, 0.9);
  --honey: #C99A3F;
  --gray-1: #1A1416;
  --gray-2: #4A4045;
  --gray-3: #8A7F84;
  --gray-4: #D9CFC4;
  --section-pad: 120px;
  --section-pad-sm: 72px;
  --max-w: 1200px;
  --text-max: 680px;
  --radius-card: 16px;
  --radius-btn: 8px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

.serif { font-family: 'Noto Serif SC', serif; }
h1, h2, h3, h4 { font-family: 'Noto Serif SC', serif; line-height: 1.15; letter-spacing: 0.01em; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 48px; }
@media (max-width: 768px) {
  .container { padding: 0 24px; }
  :root { --section-pad: 72px; --section-pad-sm: 48px; }
}

.divider { width: 40px; height: 1px; background: var(--honey); opacity: 0.6; margin: 0 auto 32px; }
.divider.left { margin: 0 0 32px; }

.section-label {
  font-size: 11px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--sage); margin-bottom: 16px;
}

/* ── Buttons ── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--terracotta); color: #fff;
  font-family: 'Noto Sans SC', sans-serif; font-size: 15px; font-weight: 500;
  letter-spacing: 0.05em; padding: 14px 28px;
  border-radius: var(--radius-btn); border: none; cursor: pointer;
  text-decoration: none; transition: opacity 0.25s, transform 0.25s;
}
.btn-primary:hover { opacity: 0.88; transform: translateY(-1px); }
.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  background: transparent; color: var(--plum);
  font-family: 'Noto Sans SC', sans-serif; font-size: 15px; font-weight: 400;
  letter-spacing: 0.05em; padding: 13px 28px;
  border-radius: var(--radius-btn);
  border: 1px solid rgba(59, 42, 53, 0.25); cursor: pointer;
  text-decoration: none; transition: border-color 0.25s, color 0.25s;
}
.btn-ghost:hover { border-color: var(--terracotta); color: var(--terracotta); }
.btn-text {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--terracotta); font-size: 14px; font-weight: 500;
  letter-spacing: 0.06em; text-decoration: none;
  background: none; border: none; cursor: pointer;
  transition: gap 0.25s var(--ease-out);
}
.btn-text:hover { gap: 10px; }
.btn-text .arrow { transition: transform 0.25s var(--ease-out); }
.btn-text:hover .arrow { transform: translateX(3px); }

.img-placeholder {
  background: repeating-linear-gradient(45deg, var(--gray-4) 0px, var(--gray-4) 1px, transparent 1px, transparent 10px);
  background-color: #ede7de;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-3); font-size: 12px;
  font-family: 'Courier New', monospace; letter-spacing: 0.05em;
  text-align: center; line-height: 1.5;
}

.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out); }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ── NAV ── */
#site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 0 48px; height: 68px;
  display: flex; align-items: center; justify-content: space-between;
  transition: background 0.4s var(--ease-out), box-shadow 0.4s;
  background: rgba(245, 239, 230, 0.96); backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--gray-4);
}
#site-nav.transparent {
  background: transparent; backdrop-filter: none; box-shadow: none;
}
#site-nav.transparent:not(.scrolled) .nav-logo img { filter: brightness(0) invert(1); }
#site-nav.transparent:not(.scrolled) .nav-cta {
  background: rgba(245,239,230,0.12); border: 1px solid rgba(245,239,230,0.2);
}
#site-nav.transparent:not(.scrolled) .nav-cta:hover { background: rgba(245,239,230,0.2); }
#site-nav.transparent.scrolled {
  background: rgba(245, 239, 230, 0.96); backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--gray-4);
}
.nav-logo {
  font-family: 'Noto Serif SC', serif; font-size: 20px; font-weight: 700;
  color: var(--plum); text-decoration: none; letter-spacing: 0.05em;
}
.nav-links { display: flex; align-items: center; gap: 36px; list-style: none; }
.nav-links a {
  font-size: 14px; font-weight: 400; color: var(--plum); opacity: 0.75;
  text-decoration: none; letter-spacing: 0.06em;
  transition: color 0.3s, opacity 0.3s;
}
.nav-links a:hover { opacity: 1; }
.nav-links a.active { color: var(--terracotta); opacity: 1; }
#site-nav.transparent:not(.scrolled) .nav-links a { color: rgba(245,239,230,0.7); opacity: 1; }
#site-nav.transparent:not(.scrolled) .nav-links a:hover { color: rgba(245,239,230,1); }
#site-nav.transparent:not(.scrolled) .nav-links a.active { color: var(--terracotta); }
.nav-right { display: flex; align-items: center; gap: 16px; }
.nav-lang { font-size: 13px; color: var(--gray-3); cursor: pointer; letter-spacing: 0.06em; transition: color 0.3s; }
.nav-lang:hover { color: var(--plum); }
#site-nav.transparent:not(.scrolled) .nav-lang { color: rgba(245,239,230,0.45); }
#site-nav.transparent:not(.scrolled) .nav-lang:hover { color: rgba(245,239,230,0.9); }
.nav-cta {
  background: var(--terracotta); color: #fff; font-size: 13px; font-weight: 500;
  letter-spacing: 0.08em; padding: 9px 20px;
  border-radius: var(--radius-btn); text-decoration: none;
  transition: opacity 0.2s;
}
.nav-cta:hover { opacity: 0.88; }
@media (max-width: 900px) { .nav-links { display: none; } #site-nav { padding: 0 24px; } }

/* ── PAGE HEAD (sub-page hero) ── */
.page-head {
  padding: 168px 0 72px;
  background: var(--cream);
  position: relative; overflow: hidden;
}
.page-head::after {
  content: ''; position: absolute;
  bottom: 0; left: 0; right: 0; height: 1px;
  background: var(--gray-4);
}
.page-head-inner { max-width: 1080px; margin: 0 auto; padding: 0 48px; position: relative; }
@media (max-width: 768px) { .page-head { padding: 120px 0 48px; } .page-head-inner { padding: 0 24px; } }
.page-head-eyebrow {
  font-family: 'Courier New', monospace; font-size: 11px;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--honey); margin-bottom: 20px;
}
.page-head h1 {
  font-size: clamp(40px, 5.5vw, 76px);
  font-weight: 900; color: var(--plum);
  line-height: 1.05; max-width: 14ch; margin-bottom: 24px;
}
.page-head h1 em { font-style: normal; color: var(--terracotta); }
.page-head .lede {
  font-size: 17px; color: var(--gray-2);
  max-width: 540px; line-height: 1.7;
}

/* ── FOOTER ── */
#footer { background: var(--plum); padding: 64px 0 40px; }
.footer-top {
  display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px; padding-bottom: 48px;
  border-bottom: 1px solid rgba(245, 239, 230, 0.08); margin-bottom: 32px;
}
@media (max-width: 900px) { .footer-top { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .footer-top { grid-template-columns: 1fr; gap: 32px; } }
.footer-brand .logo {
  font-family: 'Noto Serif SC', serif; font-size: 22px; font-weight: 700;
  color: var(--cream); margin-bottom: 12px; display: block;
}
.footer-brand p { font-size: 13px; color: rgba(245, 239, 230, 0.45); line-height: 1.7; max-width: 240px; }
.footer-col h5 {
  font-family: 'Noto Serif SC', serif; font-size: 13px;
  color: var(--cream); letter-spacing: 0.08em; margin-bottom: 20px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col ul a {
  font-size: 13px; color: rgba(245, 239, 230, 0.45);
  text-decoration: none; transition: color 0.2s;
}
.footer-col ul a:hover { color: var(--cream); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
}
.footer-copy { font-size: 12px; color: rgba(245, 239, 230, 0.3); }
.footer-legal { display: flex; gap: 20px; }
.footer-legal a { font-size: 12px; color: rgba(245, 239, 230, 0.3); text-decoration: none; transition: color 0.2s; }
.footer-legal a:hover { color: rgba(245, 239, 230, 0.6); }

/* ── Mobile fixed CTA ── */
#mobile-cta {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  padding: 12px 20px 20px; background: rgba(245, 239, 230, 0.96);
  backdrop-filter: blur(16px); border-top: 1px solid var(--gray-4);
}
@media (max-width: 768px) { #mobile-cta { display: block; } body { padding-bottom: 76px; } }
.mobile-cta-inner { display: flex; gap: 10px; }
.btn-wa {
  display: inline-flex; align-items: center; gap: 10px;
  background: #25D366; color: #fff; font-size: 14px; font-weight: 500;
  padding: 13px 24px; border-radius: var(--radius-btn);
  text-decoration: none; transition: opacity 0.2s;
}
.btn-wa:hover { opacity: 0.9; }
.btn-wechat {
  display: inline-flex; align-items: center; gap: 10px;
  background: rgba(245, 239, 230, 0.1); color: var(--cream);
  font-size: 14px; font-weight: 400; padding: 13px 24px;
  border-radius: var(--radius-btn);
  border: 1px solid rgba(245, 239, 230, 0.15); cursor: pointer;
  text-decoration: none; transition: background 0.2s;
}
.btn-wechat:hover { background: rgba(245, 239, 230, 0.15); }
.mobile-cta-inner .btn-wa, .mobile-cta-inner .btn-wechat {
  flex: 1; justify-content: center; font-size: 14px;
}
.mobile-cta-inner .btn-wechat {
  background: var(--plum); color: var(--cream); border-color: transparent;
}

/* ── WeChat modal ── */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(59, 42, 53, 0.6);
  backdrop-filter: blur(4px); z-index: 500;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.3s;
}
.modal-backdrop.open { opacity: 1; pointer-events: all; }
.modal-box {
  background: var(--cream); border-radius: 20px; padding: 40px 36px;
  max-width: 320px; width: 90%; text-align: center;
  transform: translateY(16px) scale(0.97);
  transition: transform 0.3s var(--ease-out);
}
.modal-backdrop.open .modal-box { transform: translateY(0) scale(1); }
.modal-box h3 { font-size: 20px; color: var(--plum); margin-bottom: 8px; }
.modal-box p { font-size: 14px; color: var(--gray-3); margin-bottom: 28px; }
.modal-qr { width: 160px; height: 160px; margin: 0 auto 20px; border-radius: 8px; }
.modal-close {
  margin-top: 16px; background: none; border: none;
  font-size: 13px; color: var(--gray-3); cursor: pointer; letter-spacing: 0.06em;
}
.modal-close:hover { color: var(--plum); }

/* ── Page CTA section (shared) ── */
.cta-band {
  padding: var(--section-pad-sm) 0;
  background: var(--plum); color: var(--cream);
  text-align: center;
}
.cta-band h2 { font-size: clamp(28px, 3vw, 40px); color: var(--cream); margin-bottom: 12px; }
.cta-band p { color: rgba(245,239,230,0.55); font-size: 15px; max-width: 480px; margin: 0 auto 28px; }
.cta-band-btns {
  display: flex; justify-content: center; gap: 16px; flex-wrap: wrap;
}

/* ── Mobile nav (hamburger + drawer) ───────────────────────────────── */
.nav-toggle {
  display: none;
  align-items: center; justify-content: center;
  background: none; border: none; cursor: pointer; padding: 0;
  width: 40px; height: 40px; margin-right: 4px;
  color: rgba(245,239,230,0.92);
}
#site-nav.scrolled .nav-toggle { color: var(--plum); }
.nav-toggle-icon { display: block; }
.nav-toggle-icon .bar {
  transform-origin: center;
  transition: transform 0.25s, opacity 0.2s;
}
.nav-toggle[aria-expanded="true"] .bar-1 { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bar-2 { opacity: 0; }
.nav-toggle[aria-expanded="true"] .bar-3 { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .nav-lang { display: none; }
  .nav-links.open {
    display: flex !important;
    position: fixed; top: 68px; left: 0; right: 0;
    flex-direction: column; gap: 0;
    padding: 12px 24px 28px;
    background: rgba(245,239,230,0.98);
    backdrop-filter: blur(12px);
    box-shadow: 0 8px 24px rgba(59,42,53,0.10);
    border-top: 1px solid rgba(59,42,53,0.06);
    list-style: none;
  }
  .nav-links.open li { padding: 14px 0; border-bottom: 1px solid rgba(59,42,53,0.06); }
  .nav-links.open li:last-child { border-bottom: none; }
  .nav-links.open a {
    color: var(--plum) !important;
    opacity: 1 !important;
    font-size: 16px;
    display: block; letter-spacing: 0.04em;
  }
  .nav-links.open a.active { color: var(--terracotta) !important; font-weight: 600; }
}
