/* 鲁班CAD快速看图 · 产品站
   配色取自 www.lubansoft.com：主色 #b19566（官网下载按钮）、悬停 #967d52、
   强调 #a98b59（下载中心当前分类）、页脚 #444、正文 #656d78、标题 #404040 */

:root {
  --brand: #b19566;
  --brand-dark: #967d52;
  --brand-deep: #a98b59;
  --brand-light: #cdae79;
  --wash: #faf8f4;
  --wash-2: #f4efe6;
  --ink: #404040;
  --ink-2: #656d78;
  --ink-3: #9a9a9a;
  --line: #e8e6e2;
  --line-2: #d9d5cd;
  --footer: #444444;
  --footer-2: #3a3a3a;
  --panel: #24262b;
  --panel-2: #1b1d21;
  --container: 1200px;
  --radius: 10px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  font: 15px/1.9 system-ui, "Microsoft YaHei", 微软雅黑, "PingFang SC", arial, tahoma, sans-serif;
  color: var(--ink-2);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

/* height:auto 不能省：img 上写了 width/height 属性，缩宽时不改高会把图压变形 */
img { max-width: 100%; height: auto; display: block; }

/* %LOCALAPPDATA%\LubanSoft\CADViewer\logs 这种长路径整体没有断点，
   320px 宽的屏上会顶破容器，允许它在放不下时折行 */
code { overflow-wrap: break-word; }
a { color: inherit; text-decoration: none; }

.wrap { max-width: var(--container); margin: 0 auto; padding: 0 20px; }

/* ---------- 顶部资讯条 ---------- */

.topbar {
  background: linear-gradient(90deg, #a4854f 0%, var(--brand) 45%, #c2aa80 100%);
  color: #fff;
  font-size: 12.5px;
  line-height: 34px;
}
.topbar .wrap { display: flex; gap: 26px; align-items: center; }
.topbar b { font-weight: 400; opacity: .92; }
.topbar .tel { margin-left: auto; letter-spacing: .3px; }
.topbar .tel span { opacity: .8; }

/* ---------- 主导航 ---------- */

.masthead {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(150%) blur(6px);
  border-bottom: 1px solid var(--line);
}
.masthead .wrap { display: flex; align-items: center; height: 76px; gap: 28px; }

.brand { display: flex; align-items: center; gap: 13px; flex: none; }
.brand .logo { width: 36px; height: 35px; flex: none; }
.brand .wordmark { line-height: 1.15; }
.brand .cn { font-size: 19px; font-weight: 700; color: #3d3a35; letter-spacing: .5px; }
.brand .en { font-size: 9.5px; letter-spacing: 2.6px; color: var(--brand-deep); }
.brand .slogan {
  padding-left: 14px; margin-left: 3px;
  border-left: 1px solid var(--line-2);
  font-size: 14.5px; color: #5c5c5c;
}

.nav { display: flex; gap: 30px; margin-left: auto; font-size: 15.5px; }
.nav a { color: #4a4a4a; padding: 4px 0; border-bottom: 2px solid transparent; transition: .2s; }
.nav a:hover { color: var(--brand-dark); }
.nav a.on { color: var(--brand-dark); border-bottom-color: var(--brand); }

.mast-cta {
  flex: none; font-size: 13.5px; padding: 8px 20px;
  border: 1px solid var(--brand); border-radius: 999px;
  color: var(--brand-dark); transition: .2s;
}
.mast-cta:hover { background: var(--brand); color: #fff; }

/* ---------- 首屏 ---------- */

.hero {
  background:
    radial-gradient(1100px 460px at 78% 8%, rgba(177, 149, 102, .22), transparent 70%),
    linear-gradient(160deg, #2b2d33 0%, var(--panel-2) 60%, #15171a 100%);
  color: #e8e6e2;
  padding: 74px 0 0;
  overflow: hidden;
}
.hero .wrap { display: grid; grid-template-columns: 1fr; gap: 40px; }
.hero h1 {
  margin: 0 0 18px; font-size: 44px; line-height: 1.28; font-weight: 700;
  color: #fff; letter-spacing: 1px;
}
.hero h1 em { font-style: normal; color: var(--brand-light); }
.hero .lead { margin: 0 0 26px; font-size: 16.5px; max-width: 680px; color: #bdbcb8; }

.meta { display: flex; flex-wrap: wrap; gap: 10px 28px; margin: 0 0 30px; font-size: 13.5px; color: #a8a6a1; }
.meta div { display: flex; gap: 8px; }
.meta span { color: #e2ded6; }

.hero-shot {
  display: block;
  position: relative;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .14);
  border-bottom: 0;
  box-shadow: 0 -2px 60px rgba(0, 0, 0, .5);
  margin-bottom: -1px;
  cursor: zoom-in;
}
.hero-shot img { border-radius: 11px 11px 0 0; }
.hero-zoom-hint {
  display: none;
  position: absolute; right: 10px; bottom: 10px;
  background: rgba(0, 0, 0, .55); color: #fff;
  font-size: 12.5px; line-height: 1.4; padding: 5px 11px;
  border-radius: 999px; pointer-events: none;
}
.shot-note { text-align: center; font-size: 12.5px; color: #8d8b87; padding: 12px 0 26px; }
.shot-note a { color: var(--brand-light); border-bottom: 1px solid rgba(205, 174, 121, .4); }
.shot-note a:hover { color: #fff; }

/* 大图页：手机上主图只有 350 宽，点进去按 1600 显示，左右滑着看细节。
   必须覆盖全局 img { max-width:100% }，否则又缩回视口宽，白走一趟。 */
.shot-page { background: #15171a; min-height: 100dvh; }
.shot-bar {
  position: sticky; top: 0; z-index: 2;
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px;
  padding: 12px 16px;
  background: rgba(21, 23, 26, .94);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  color: #a8a6a1; font-size: 13.5px;
}
.shot-bar a { color: var(--brand-light); }
.shot-bar a:hover { color: #fff; }
.shot-stage { overflow: auto; -webkit-overflow-scrolling: touch; }
.shot-stage img {
  display: block;
  width: 1600px;
  max-width: none;
  height: auto;
}
@media (min-width: 1640px) {
  .shot-stage img { width: 1600px; margin: 0 auto; }
}

/* ---------- 按钮 ---------- */

.btns { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.btn {
  display: inline-block; font-size: 16px; padding: 12px 34px;
  border-radius: var(--radius); border: 1px solid transparent;
  transition: all .3s ease; cursor: pointer;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-ghost { border-color: rgba(255, 255, 255, .3); color: #e8e6e2; }
.btn-ghost:hover { border-color: var(--brand-light); color: var(--brand-light); }
.btn-line { border-color: var(--line-2); color: var(--ink-2); background: #fff; }
.btn-line:hover { border-color: var(--brand); color: var(--brand-dark); }
.btn-sm { font-size: 14px; padding: 9px 22px; }

/* ---------- 区块 ---------- */

.section { padding: 78px 0; }
.section.alt { background: var(--wash); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.sect-head { text-align: center; margin-bottom: 46px; }
.sect-head.left { text-align: left; }
.sect-head .en {
  font-size: 12.5px; letter-spacing: 3.4px; color: var(--brand-deep);
  text-transform: uppercase; margin-bottom: 9px;
}
.sect-head h2 { margin: 0; font-size: 31px; font-weight: 700; color: var(--ink); letter-spacing: .8px; }
.sect-head h2::after {
  content: ""; display: block; width: 42px; height: 3px;
  background: var(--brand); margin: 16px auto 0;
}
.sect-head.left h2::after { margin-left: 0; }
.sect-head p { margin: 16px auto 0; max-width: 760px; font-size: 15px; color: var(--ink-2); }
.sect-head.left p { margin-left: 0; }

/* ---------- 卡片 ---------- */

.grid { display: grid; gap: 22px; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 30px 28px; transition: .28s;
}
.card:hover { border-color: var(--brand-light); box-shadow: 0 8px 26px rgba(120, 100, 66, .12); transform: translateY(-3px); }
.card .ico {
  width: 46px; height: 46px; border-radius: 8px; margin-bottom: 18px;
  background: var(--wash-2); color: var(--brand-dark);
  display: flex; align-items: center; justify-content: center;
}
.card .ico svg { width: 24px; height: 24px; }
.card h3 { margin: 0 0 10px; font-size: 17.5px; color: var(--ink); font-weight: 700; }
.card p { margin: 0; font-size: 14px; color: var(--ink-2); }

/* 导航卡 */
.mod { display: block; }
.mod .top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.mod h3 { margin: 0; }
.mod .cnt { font-size: 12px; color: var(--brand-deep); flex: none; }

/* ---------- 章节跳转条 ---------- */

.jump {
  display: flex; flex-wrap: wrap; gap: 12px 28px;
  padding: 20px 26px; background: #fff;
  border: 1px solid var(--line); border-radius: 6px;
  font-size: 14.5px;
}
.jump a { color: var(--ink-2); }
.jump a:hover { color: var(--brand-dark); }
.jump a b { color: var(--brand-deep); font-weight: 400; font-size: 12px; margin-left: 4px; }

/* ---------- 步骤 ---------- */

.steps { counter-reset: s; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.steps li { list-style: none; position: relative; padding: 28px 26px 26px; background: #fff; border: 1px solid var(--line); border-radius: 6px; }
.steps li::before {
  counter-increment: s; content: counter(s, decimal-leading-zero);
  display: block; font-size: 26px; font-weight: 700; color: var(--brand-light); margin-bottom: 8px;
}
.steps h3 { margin: 0 0 8px; font-size: 16.5px; color: var(--ink); }
.steps p { margin: 0; font-size: 14px; }
.steps code { background: var(--wash-2); padding: 1px 6px; border-radius: 3px; color: var(--brand-dark); font-size: 13px; }

/* ---------- 表格 ---------- */

.tbl { width: 100%; border-collapse: collapse; font-size: 14px; background: #fff; }
.tbl caption {
  caption-side: top; text-align: left; font-size: 16.5px; font-weight: 700;
  color: var(--ink); padding: 0 0 12px;
}
.tbl th {
  background: var(--wash-2); color: #5f5748; text-align: left; font-weight: 700;
  padding: 11px 14px; border: 1px solid var(--line); font-size: 13.5px; white-space: nowrap;
}
.tbl td { padding: 11px 14px; border: 1px solid var(--line); vertical-align: top; }
.tbl tbody tr:hover td { background: #fdfcfa; }
.tbl .k { color: var(--ink); font-weight: 700; white-space: nowrap; }
.tbl code { background: var(--wash-2); padding: 1px 6px; border-radius: 3px; font-size: 13px; color: var(--brand-dark); }

/* ---------- 下载 ---------- */

.dl-card {
  border: 1px solid var(--line); border-top: 3px solid var(--brand);
  border-radius: 4px; background: #fff; padding: 34px 36px;
  display: grid; grid-template-columns: 1fr auto; gap: 30px; align-items: center;
}
.dl-card h3 { margin: 0 0 6px; font-size: 22px; color: var(--ink); }
.dl-card .sub { font-size: 13.5px; color: var(--ink-3); margin-bottom: 18px; }
.dl-spec { display: flex; flex-wrap: wrap; gap: 8px 30px; font-size: 13.5px; }
.dl-spec div span { color: var(--ink-3); margin-right: 6px; }
.dl-spec div b { color: var(--ink); font-weight: 700; }
.hash {
  margin-top: 20px; font-size: 12.5px; color: var(--ink-3);
  word-break: break-all; font-family: Consolas, Menlo, monospace;
}
.hash b { color: var(--ink-2); font-family: inherit; }

.note {
  border-left: 3px solid var(--brand); background: var(--wash);
  padding: 16px 20px; font-size: 14px; margin: 22px 0;
}
.note.warn { border-left-color: #c9922f; background: #fdf8ef; }
.note.bad { border-left-color: #c0574b; background: #fdf3f1; }
.note b { color: var(--ink); }
.note code { background: #fff; border: 1px solid var(--line); padding: 1px 6px; border-radius: 3px; font-size: 13px; color: var(--brand-dark); }

/* ---------- Wiki ---------- */

.page-head {
  background: linear-gradient(120deg, #33353b 0%, var(--panel) 55%, #292b30 100%);
  color: #fff; padding: 52px 0;
}
.page-head .crumb { font-size: 13px; color: #a8a6a1; margin-bottom: 12px; }
.page-head .crumb a:hover { color: var(--brand-light); }
.page-head h1 { margin: 0; font-size: 33px; font-weight: 700; letter-spacing: 1px; }
.page-head p { margin: 12px 0 0; color: #bdbcb8; font-size: 15px; max-width: 780px; }

.wiki { display: grid; grid-template-columns: 236px 1fr; gap: 52px; padding: 46px 0 84px; align-items: start; }

.toc { position: sticky; top: 96px; font-size: 14px; }
.toc .search {
  width: 100%; padding: 9px 12px; font: inherit; font-size: 13.5px;
  border: 1px solid var(--line-2); border-radius: 4px; margin-bottom: 16px;
  color: var(--ink-2); background: #fff;
}
.toc .search:focus { outline: none; border-color: var(--brand); }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc a {
  display: block; padding: 7px 12px 7px 34px; color: var(--ink-2);
  border-left: 2px solid var(--line); position: relative; transition: .18s;
}
/* 章节号写在 data-n 上，过滤掉几章之后剩下的编号不会重排 */
.toc a::before {
  content: attr(data-n); position: absolute; left: 12px;
  color: var(--ink-3); font-size: 12px;
}
.toc a:hover { color: var(--brand-dark); background: var(--wash); }
.toc a.on { color: var(--brand-dark); border-left-color: var(--brand); background: var(--wash); font-weight: 700; }
.toc a.on::before { color: var(--brand); }

.doc { min-width: 0; }
.doc h2 {
  margin: 0 0 18px; padding-bottom: 12px; font-size: 25px; color: var(--ink);
  border-bottom: 1px solid var(--line); font-weight: 700;
}
.doc section { margin-bottom: 62px; }
.doc section:last-child { margin-bottom: 0; }
.doc h3 { margin: 30px 0 10px; font-size: 17.5px; color: var(--ink); font-weight: 700; }
.doc h3::before { content: "▍"; color: var(--brand); margin-right: 6px; font-size: 15px; }
.doc p { margin: 0 0 14px; }
.doc ul, .doc ol { margin: 0 0 16px; padding-left: 22px; }
.doc li { margin: 5px 0; }
.doc code { background: var(--wash-2); padding: 1px 6px; border-radius: 3px; font-size: 13px; color: var(--brand-dark); }
.doc .tbl { margin: 8px 0 20px; }
.doc kbd {
  display: inline-block; min-width: 20px; text-align: center; padding: 1px 7px;
  border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 4px;
  background: #fff; font-size: 12.5px; color: var(--ink); font-family: inherit;
}
.doc figure { margin: 18px 0; }
.doc figure img { border: 1px solid var(--line); border-radius: 4px; }
.doc figcaption { font-size: 12.5px; color: var(--ink-3); padding-top: 8px; }

/* ---------- 尾部 CTA ---------- */

.cta {
  background:
    radial-gradient(700px 300px at 20% 0%, rgba(177, 149, 102, .2), transparent 70%),
    linear-gradient(120deg, #2f3137, var(--panel-2));
  color: #fff; padding: 62px 0; text-align: center;
}
.cta h2 { margin: 0 0 12px; font-size: 29px; letter-spacing: .8px; }
.cta p { margin: 0 0 28px; color: #bdbcb8; }
.cta .btns { justify-content: center; }

/* ---------- 页脚 ---------- */

.footer { background: var(--footer); color: #b8b8b8; font-size: 13.5px; padding: 50px 0 0; }
.footer .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; padding-bottom: 38px; }
.footer h4 { margin: 0 0 16px; font-size: 15px; color: #fff; font-weight: 700; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin: 8px 0; }
.footer a:hover { color: var(--brand-light); }
.footer .contact p { margin: 8px 0; }
.footer .contact .tel { font-size: 23px; color: #fff; font-weight: 700; letter-spacing: .5px; margin: 4px 0 10px; }
.footer .bar {
  border-top: 1px solid #525252; background: var(--footer-2);
  margin-top: 0; padding: 18px 0; font-size: 12.5px; color: #999;
}
.footer .bar .wrap { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; }
.footer .bar .right { margin-left: auto; }

/* ---------- 响应式 ---------- */

/* 平板、以及桌面上把窗口拖窄 */
@media (max-width: 1040px) {
  .g3 { grid-template-columns: repeat(2, 1fr); }
  .wiki { grid-template-columns: 1fr; gap: 28px; }
  .toc { position: static; }
  .footer .cols { grid-template-columns: repeat(2, 1fr); }
  .brand .slogan { display: none; }
  .hero h1 { font-size: 33px; }

  /* 导航换到第二行横向滚动，不要整块藏起来 */
  .masthead .wrap { height: auto; flex-wrap: wrap; padding-top: 12px; padding-bottom: 0; gap: 16px; }
  .mast-cta { order: 2; }
  .nav {
    order: 3; width: 100%; margin-left: 0; gap: 22px;
    overflow-x: auto; padding-bottom: 2px;
    border-top: 1px solid var(--line);
    padding-top: 10px;
  }
  .nav a { white-space: nowrap; }
  html { scroll-padding-top: 140px; }
  .toc { top: 20px; }

  /* 目录不再吸在侧边，排成两列，别把正文推到一屏之外 */
  .toc ol { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 16px; }
}

/* 手机 */
@media (max-width: 680px) {
  .g3, .g2, .steps { grid-template-columns: 1fr; }
  .dl-card { grid-template-columns: 1fr; }
  .topbar .tel { display: none; }
  .section { padding: 52px 0; }

  .footer .cols { grid-template-columns: 1fr; gap: 26px; }
  .footer .bar .right { margin-left: 0; }

  /* 两行的吸顶导航会占掉小屏近 1/5 高度，手机上让它跟着页面滚走 */
  .masthead { position: static; }
  html { scroll-padding-top: 16px; }

  /* 全站 24 张表都是「名称 | 说明」两列。窄屏拆成上下两段读，
     比让用户左右拖表格强。表头这时没信息量，隐掉。 */
  .tbl thead { display: none; }
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; width: auto; }
  .tbl tr {
    background: #fff; border: 1px solid var(--line);
    border-radius: 4px; margin-bottom: 10px;
  }
  .tbl td { border: 0; padding: 0 15px 13px; }
  .tbl td.k {
    padding: 12px 15px 5px; font-size: 14.5px;
    white-space: normal;          /* 桌面上是 nowrap，窄屏必须能折行 */
  }
  .tbl tbody tr:hover td { background: transparent; }

  /* 工具栏截图是 15:1 的长条，压到手机宽度就完全看不清了，改成可横向滑动 */
  .toolbar-strip { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .toolbar-strip img { min-width: 680px; }

  .toc a { padding-top: 10px; padding-bottom: 10px; }   /* 手指点得中 */

  .shot-note, .doc figcaption { font-size: 13px; }      /* 12.5px 在手机上偏小 */
  .hero-zoom-hint { display: block; }
}

/* 窄手机（iPhone SE 一档） */
@media (max-width: 460px) {
  .hero { padding: 46px 0 0; }
  .hero h1 { font-size: 27px; }
  .hero .lead { font-size: 15px; }
  .sect-head { margin-bottom: 32px; }
  .sect-head h2 { font-size: 24px; }
  .page-head { padding: 38px 0; }
  .page-head h1 { font-size: 26px; }
  .cta { padding: 48px 0; }
  .cta h2 { font-size: 23px; }
  .doc h2 { font-size: 21px; }

  /* 按钮占满一行，拇指好点 */
  .btns { display: grid; grid-template-columns: 1fr; gap: 12px; }
  .btn { text-align: center; padding: 13px 20px; }
}
