/* ============================================================
   武林少 · 少林禅武医 —— 禅武墨韵风设计系统
   设计规范：8px 间距 / OKLCH 色彩 / modular scale 1.25
   ============================================================ */

:root {
  /* —— 色彩系统（古色古香 · 故宫红金暖调）—— */
  --ink: #4a1a12;            /* 深酱红（红墙深色，非冷黑） */
  --ink-2: #5c2418;          /* 次级酱红 */
  --paper: #f7e8cf;          /* 暖杏米黄（主背景，非灰白） */
  --paper-2: #eed9b2;        /* 浅棕杏（次背景） */
  --gold: #d4af37;           /* 鎏金（金瓦） */
  --gold-light: #e6c76a;     /* 亮鎏金 */
  --cinnabar: #9e2f1d;       /* 故宫红（红墙主色） */
  --cinnabar-2: #b93a1f;     /* 亮故宫红 */
  --ink-soft: #5a3d2a;       /* 暖棕（正文） */
  --line: #e3cfa6;           /* 暖金棕（分隔线） */

  /* —— 字体 —— */
  --font-serif: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --font-sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;

  /* —— 间距（8px 系统）—— */
  --s1: 8px;
  --s2: 16px;
  --s3: 24px;
  --s4: 32px;
  --s5: 48px;
  --s6: 64px;
  --s7: 96px;

  /* —— 动效 —— */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 160ms;
  --dur-med: 320ms;
  --dur-slow: 500ms;
}

/* —— Reset —— */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.75;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* —— 排版比例 —— */
h1, h2, h3, h4 { font-family: var(--font-serif); font-weight: 700; line-height: 1.25; color: var(--ink); }
.display { font-size: clamp(2.25rem, 5vw, 3.75rem); letter-spacing: .06em; }
.h-xl   { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.h-lg   { font-size: clamp(1.4rem, 2.6vw, 1.9rem); }
.h-md   { font-size: 1.3rem; }
.lead   { font-size: 1.125rem; color: var(--ink-soft); }
.text-gold { color: var(--gold); }
.text-cinnabar { color: var(--cinnabar); }

/* —— 布局容器 —— */
.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 var(--s3); }
.section { padding: var(--s6) 0; }
.section--alt { background: var(--paper-2); }
.section-head { max-width: 720px; margin: 0 auto var(--s5); text-align: center; }
.section-head .eyebrow {
  display: inline-block;
  font-size: .8rem;
  letter-spacing: .32em;
  color: var(--cinnabar);
  text-transform: uppercase;
  margin-bottom: var(--s2);
  font-family: var(--font-serif);
}
.section-head .rule {
  width: 48px; height: 2px; background: var(--gold);
  margin: var(--s2) auto 0;
}

/* —— 印章元素（品牌点缀）—— */
.seal {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; flex: none;
  background: var(--cinnabar); color: var(--paper);
  font-family: var(--font-serif); font-size: 1.1rem; line-height: 1.1;
  writing-mode: vertical-rl; text-orientation: upright;
  letter-spacing: 2px; border-radius: 6px;
  box-shadow: 0 2px 8px rgba(158,47,29,.28);
}
.seal--sm { width: 40px; height: 40px; font-size: .9rem; }

/* —— 按钮 —— */
.btn {
  display: inline-flex; align-items: center; gap: var(--s1);
  padding: 14px 32px;
  font-family: var(--font-serif); font-size: 1rem; letter-spacing: .08em;
  border: 1px solid transparent; border-radius: 2px;
  cursor: pointer; transition: all var(--dur-fast) var(--ease-out);
}
.btn--gold { background: var(--gold); color: var(--ink); }
.btn--gold:hover { background: var(--gold-light); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(212,175,55,.35); }
.btn--ghost { border-color: var(--gold); color: var(--gold); background: transparent; }
.btn--ghost:hover { background: var(--gold); color: var(--ink); }
.btn--cinnabar { background: var(--cinnabar); color: var(--paper); }
.btn--cinnabar:hover { background: var(--cinnabar-2); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(158,47,29,.35); }

/* ============================================================
   顶栏 + 导航
   ============================================================ */
.topbar { background: var(--ink); color: rgba(247,232,207,.78); font-size: .82rem; }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; height: 40px; }
.topbar a:hover { color: var(--gold-light); }

.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(247,232,207,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow var(--dur-med) var(--ease-out);
}
.header.scrolled { box-shadow: 0 4px 24px rgba(74,26,18,.08); }
.header .wrap { display: flex; align-items: center; justify-content: space-between; height: 84px; }

.logo { display: flex; align-items: center; gap: 14px; }
.logo-mark {
  width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink); color: var(--gold);
  font-family: var(--font-serif); font-weight: 700; font-size: 1.35rem;
  border: 2px solid var(--gold);
}
.logo-text { display: flex; flex-direction: column; line-height: 1.2; }
.logo-text b { font-family: var(--font-serif); font-size: 1.45rem; letter-spacing: .12em; color: var(--ink); }
.logo-text span { font-size: .72rem; letter-spacing: .28em; color: var(--cinnabar); }

.nav { display: flex; align-items: center; gap: var(--s4); }
.nav a {
  position: relative; font-size: .98rem; letter-spacing: .04em;
  color: var(--ink-soft); padding: var(--s1) 0;
  transition: color var(--dur-fast) var(--ease-out);
}
.nav a::after {
  content: ""; position: absolute; left: 50%; bottom: 0;
  width: 0; height: 2px; background: var(--cinnabar);
  transition: all var(--dur-med) var(--ease-out); transform: translateX(-50%);
}
.nav a:hover, .nav a.active { color: var(--ink); }
.nav a:hover::after, .nav a.active::after { width: 100%; }

.header-cta { display: flex; align-items: center; gap: var(--s2); }

/* 移动端汉堡 */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: all var(--dur-fast) var(--ease-out); }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative; min-height: 620px;
  display: flex; align-items: center;
  background:
    linear-gradient(135deg, rgba(74,26,18,.92) 0%, rgba(122,42,24,.74) 45%, rgba(158,47,29,.42) 100%),
    url('../img/banner1.jpg') center/cover no-repeat;
  color: var(--paper); overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(212,175,55,.28), transparent 50%);
}
.hero .wrap { position: relative; z-index: 2; padding-top: var(--s7); padding-bottom: var(--s7); }
.hero-eyebrow { letter-spacing: .4em; color: var(--gold-light); font-size: .85rem; margin-bottom: var(--s3); font-family: var(--font-serif); }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.5rem); letter-spacing: .1em; margin-bottom: var(--s3); color: var(--paper); }
.hero h1 .accent { color: var(--gold); }
.hero-sub { max-width: 560px; font-size: 1.1rem; color: rgba(247,232,207,.85); margin-bottom: var(--s5); }
.hero-cta { display: flex; gap: var(--s2); flex-wrap: wrap; }
.hero-marks { display: flex; gap: var(--s4); margin-top: var(--s6); }
.hero-marks .item { display: flex; align-items: center; gap: 12px; color: rgba(247,232,207,.8); font-family: var(--font-serif); letter-spacing: .06em; }
.hero-marks .num { font-size: 2rem; color: var(--gold); font-weight: 700; }

/* 墨迹装饰 */
.ink-stroke { position: absolute; bottom: 0; left: 0; width: 100%; height: 60px; opacity: .15; pointer-events: none; }

/* ============================================================
   三宝（禅武医）
   ============================================================ */
.triple { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s4); }
.triple-card {
  background: #fffaf0; border: 1px solid var(--line);
  padding: var(--s5) var(--s4); text-align: center;
  transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
  position: relative; overflow: hidden;
}
.triple-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: var(--gold); transform: scaleX(0); transform-origin: left;
  transition: transform var(--dur-slow) var(--ease-out);
}
.triple-card:hover { transform: translateY(-8px); box-shadow: 0 24px 48px rgba(74,26,18,.1); }
.triple-card:hover::before { transform: scaleX(1); }
.triple-card .char {
  font-family: var(--font-serif); font-size: 4rem; line-height: 1;
  color: var(--cinnabar); margin-bottom: var(--s3);
}
.triple-card h3 { font-size: 1.6rem; margin-bottom: var(--s2); }
.triple-card p { color: var(--ink-soft); font-size: .95rem; }

/* ============================================================
   关于 / 两栏
   ============================================================ */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); align-items: center; }
.split-media { position: relative; }
.split-media img { border-radius: 4px; box-shadow: 0 24px 48px rgba(74,26,18,.18); }
.split-media .seal { position: absolute; top: -20px; right: -20px; }
.split-body .eyebrow { display: block; color: var(--cinnabar); letter-spacing: .32em; font-size: .8rem; margin-bottom: var(--s2); font-family: var(--font-serif); }
.split-body p { margin-bottom: var(--s3); color: var(--ink-soft); }
.split-body ul { margin: var(--s3) 0; }
.split-body ul li { padding: var(--s1) 0; padding-left: 24px; position: relative; color: var(--ink-soft); }
.split-body ul li::before { content: "◆"; position: absolute; left: 0; color: var(--gold); font-size: .7rem; top: 50%; transform: translateY(-50%); }

/* ============================================================
   产品
   ============================================================ */
.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s4); }
.product-card {
  background: #fffaf0; border: 1px solid var(--line); overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}
.product-card:hover { transform: translateY(-8px); box-shadow: 0 24px 48px rgba(74,26,18,.12); }
.product-media { aspect-ratio: 4/3; overflow: hidden; background: var(--paper-2); position: relative; }
.product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-out); }
.product-card:hover .product-media img { transform: scale(1.06); }
.product-tag { position: absolute; top: 16px; left: 16px; background: var(--cinnabar); color: var(--paper); font-size: .75rem; letter-spacing: .12em; padding: 4px 12px; border-radius: 2px; }
.product-body { padding: var(--s3); display: flex; flex-direction: column; flex: 1; }
.product-body h3 { font-size: 1.35rem; margin-bottom: var(--s2); }
.product-body p { color: var(--ink-soft); font-size: .92rem; flex: 1; }
.product-meta { display: flex; gap: var(--s1); flex-wrap: wrap; margin-top: var(--s3); }
.product-meta span { font-size: .78rem; color: var(--ink-soft); border: 1px solid var(--line); padding: 2px 10px; border-radius: 20px; }

/* ============================================================
   荣誉
   ============================================================ */
.honors { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s3); }
.honor-item {
  display: flex; gap: var(--s3); align-items: flex-start;
  background: #fffaf0; border: 1px solid var(--line); padding: var(--s3);
  transition: transform var(--dur-fast) var(--ease-out);
}
.honor-item:hover { transform: translateX(4px); border-color: var(--gold); }
.honor-year { font-family: var(--font-serif); font-size: 1.6rem; font-weight: 700; color: var(--gold); min-width: 84px; }
.honor-item h4 { font-size: 1.05rem; margin-bottom: 4px; }
.honor-item p { color: var(--ink-soft); font-size: .9rem; }

/* ============================================================
   渠道
   ============================================================ */
.channel { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s4); }
.channel-card { text-align: center; padding: var(--s5) var(--s3); background: #fffaf0; border: 1px solid var(--line); }
.channel-card .icon { width: 72px; height: 72px; margin: 0 auto var(--s3); border-radius: 50%; background: var(--paper-2); display: grid; place-items: center; font-size: 2rem; }
.channel-card h3 { margin-bottom: var(--s2); }
.channel-card p { color: var(--ink-soft); font-size: .92rem; }

/* ============================================================
   底部 CTA + 页脚
   ============================================================ */
.cta-band { background: var(--ink); color: var(--paper); text-align: center; padding: var(--s6) 0; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 50% 0%, rgba(212,175,55,.2), transparent 60%); }
.cta-band h2 { color: var(--paper); margin-bottom: var(--s2); }
.cta-band p { color: rgba(247,232,207,.7); margin-bottom: var(--s4); }
.cta-band .phone { font-family: var(--font-serif); font-size: 2rem; color: var(--gold-light); letter-spacing: .08em; display: block; margin-bottom: var(--s4); }

.footer { background: #3a1a12; color: rgba(247,232,207,.66); font-size: .88rem; padding: var(--s6) 0 var(--s3); }
.footer .wrap { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: var(--s5); }
.footer h4 { color: var(--paper); font-size: 1.05rem; margin-bottom: var(--s3); }
.footer a { display: block; padding: 6px 0; transition: color var(--dur-fast) var(--ease-out); }
.footer a:hover { color: var(--gold-light); }
.footer .logo-text b { color: var(--paper); }
.footer-bottom { border-top: 1px solid rgba(247,232,207,.12); margin-top: var(--s5); padding-top: var(--s3); display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--s2); }

/* ============================================================
   内页 hero
   ============================================================ */
.page-hero {
  background: linear-gradient(135deg, rgba(74,26,18,.94), rgba(122,42,24,.80)),
    url('../img/banner1.jpg') center/cover no-repeat;
  color: var(--paper); padding: var(--s6) 0; text-align: center;
}
.page-hero h1 { color: var(--paper); margin-bottom: var(--s2); }
.page-hero p { color: rgba(247,232,207,.7); }

/* 面包屑 */
.breadcrumb { font-size: .85rem; color: var(--ink-soft); padding: var(--s3) 0; border-bottom: 1px solid var(--line); margin-bottom: var(--s5); }
.breadcrumb a { color: var(--cinnabar); }
.breadcrumb span { margin: 0 8px; color: var(--line); }

/* ============================================================
   传承谱系（时间线）
   ============================================================ */
.lineage { position: relative; max-width: 760px; margin: 0 auto; padding-left: 32px; }
.lineage::before { content: ""; position: absolute; left: 8px; top: 0; bottom: 0; width: 2px; background: var(--line); }
.lineage-item { position: relative; padding-bottom: var(--s4); }
.lineage-item::before { content: ""; position: absolute; left: -30px; top: 6px; width: 14px; height: 14px; border-radius: 50%; background: var(--cinnabar); border: 3px solid var(--paper); box-shadow: 0 0 0 2px var(--cinnabar); }
.lineage-gen { font-family: var(--font-serif); color: var(--cinnabar); font-size: .85rem; letter-spacing: .2em; margin-bottom: 4px; }
.lineage-item h3 { font-size: 1.35rem; margin-bottom: 4px; }
.lineage-item .years { color: var(--gold); font-family: var(--font-serif); font-size: .9rem; }
.lineage-item p { color: var(--ink-soft); margin-top: var(--s1); }

/* ============================================================
   响应式
   ============================================================ */
@media (max-width: 1024px) {
  .triple, .products, .channel { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .footer .wrap { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav { display: none; position: absolute; top: 84px; left: 0; right: 0; background: var(--paper); flex-direction: column; padding: var(--s3); gap: 0; box-shadow: 0 16px 32px rgba(74,26,18,.12); }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: block; }
  .triple, .products, .channel, .honors { grid-template-columns: 1fr; }
  .hero { min-height: 520px; }
  .header-cta .btn { display: none; }
  .footer .wrap { grid-template-columns: 1fr; }
}

/* —— 动效：入场 —— */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }

/* —— 尊重减弱动效偏好 —— */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
