/* ==========================================================================
   Instrument 主题 - 完整样式表（手写，无需构建）
   ========================================================================== */

:root {
  --primary: #1e3a8a;
  --primary-2: #2563eb;
  --accent: #0ea5e9;
  --text: #1f2937;
  --text-2: #4b5563;
  --muted: #6b7280;
  --border: #e5e7eb;
  --bg: #f8fafc;
  --white: #ffffff;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
  --shadow: 0 4px 14px rgba(15, 23, 42, .08);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, .14);
  --container: 1180px;
  --header-h: 68px;
  --ease: .22s ease;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.3; margin: 0; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
button { font: inherit; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .68rem 1.35rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .95rem;
  line-height: 1.2;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--ease), color var(--ease), border-color var(--ease), transform var(--ease), box-shadow var(--ease);
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #16296b; box-shadow: var(--shadow); }
.btn-ghost { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.5); }
.btn-ghost:hover { background: rgba(255,255,255,.22); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-light { background: #fff; color: var(--primary); }
.btn-light:hover { background: #eef2ff; }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.65); }
.btn-outline-light:hover { background: rgba(255,255,255,.15); }
.btn-sm { padding: .45rem 1rem; font-size: .875rem; }
.btn-lg { padding: .85rem 1.8rem; font-size: 1.02rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--ease);
}
.site-header.is-scrolled { box-shadow: var(--shadow); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
}
.brand { display: flex; align-items: center; gap: .6rem; flex-shrink: 0; }
.brand-logo { height: 36px; width: auto; }
.brand-mark { color: var(--primary); display: inline-flex; }
.brand-text { font-size: 1.22rem; font-weight: 800; letter-spacing: .2px; color: var(--text); }
.site-nav { display: flex; align-items: center; gap: .35rem; }
.nav-link {
  padding: .5rem .8rem;
  border-radius: var(--radius-sm);
  color: var(--text-2);
  font-weight: 500;
  font-size: .95rem;
  transition: color var(--ease), background var(--ease);
}
.nav-link:hover { color: var(--primary); background: #eef2ff; }
.nav-link.is-active { color: var(--primary); background: #eef2ff; font-weight: 600; }
.nav-cta { margin-left: .6rem; }
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 0 10px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: transform var(--ease), opacity var(--ease); }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(37, 99, 235, .45), transparent 60%),
    linear-gradient(135deg, #0b1a45 0%, #14296e 55%, #1d3f9e 100%);
  color: #fff;
  padding: 5.5rem 0 4.5rem;
}
.hero-inner { max-width: 900px; }
.hero-eyebrow {
  display: inline-block;
  font-size: .82rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #bfd3ff;
  margin-bottom: 1rem;
  padding: .25rem .75rem;
  border: 1px solid rgba(191, 211, 255, .35);
  border-radius: 999px;
}
.hero-title { font-size: clamp(2rem, 4.6vw, 3.4rem); font-weight: 800; letter-spacing: .5px; }
.hero-subtitle { margin-top: 1rem; font-size: clamp(1rem, 2vw, 1.18rem); color: #d7e3ff; max-width: 720px; }
.hero-actions { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 2rem; }
.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 3.2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,.18);
}
.hero-stats li { display: flex; flex-direction: column; gap: .15rem; }
.hero-stats strong { font-size: 1.5rem; font-weight: 800; }
.hero-stats span { font-size: .85rem; color: #bfd3ff; }

/* ---------- Page hero ---------- */
.page-hero {
  background: linear-gradient(135deg, #0b1a45 0%, #1d3f9e 100%);
  color: #fff;
  padding: 3.4rem 0;
}
.page-hero-compact { padding: 1.2rem 0; }
.page-hero-compact .breadcrumb { color: #c9d8ff; }
.page-title { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 800; }
.page-subtitle { margin-top: .7rem; color: #d7e3ff; font-size: 1.05rem; max-width: 760px; }

/* ---------- Sections ---------- */
.section { padding: 4.2rem 0; }
.section-alt { background: var(--white); }
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}
.section-title { font-size: 1.6rem; font-weight: 800; position: relative; padding-bottom: .55rem; }
.section-title::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 46px; height: 3px;
  background: var(--primary);
  border-radius: 3px;
}
.link-more { font-weight: 600; color: var(--primary); font-size: .95rem; }
.link-more:hover { text-decoration: underline; }

/* ---------- Series cards ---------- */
.series-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1rem;
}
.series-card {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  padding: 1.6rem 1.4rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}
.series-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #c7d4f5; }
.series-name { font-weight: 700; font-size: 1.05rem; }
.series-count { color: var(--muted); font-size: .875rem; }

/* ---------- Product grid / cards ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 1.4rem;
}
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--ease), box-shadow var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-link { display: block; height: 100%; }
.card-media { position: relative; aspect-ratio: 4 / 3; background: #eef2f7; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.card:hover .card-media img { transform: scale(1.04); }
.card-media-placeholder {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b6c2d9;
}
.card-badge {
  position: absolute;
  top: .7rem; left: .7rem;
  background: rgba(30, 58, 138, .92);
  color: #fff;
  font-size: .72rem;
  font-weight: 600;
  padding: .18rem .55rem;
  border-radius: 999px;
}
.card-body { padding: 1.15rem 1.2rem 1.25rem; display: flex; flex-direction: column; gap: .35rem; }
.card-title { font-size: 1.04rem; font-weight: 700; }
.card-model { color: var(--muted); font-size: .85rem; }
.card-summary { color: var(--text-2); font-size: .9rem; }
.card-keys { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .35rem; }
.key-item {
  font-size: .74rem;
  color: var(--primary);
  background: #eef2ff;
  border-radius: 4px;
  padding: .12rem .45rem;
}
.card-more { margin-top: .55rem; font-size: .86rem; font-weight: 600; color: var(--primary); }

/* ---------- Filter ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .55rem;
  margin-bottom: 2rem;
}
.filter-chip {
  padding: .5rem 1rem;
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: 999px;
  font-size: .9rem;
  color: var(--text-2);
  cursor: pointer;
  transition: all var(--ease);
}
.filter-chip:hover { border-color: var(--primary); color: var(--primary); }
.filter-chip.is-active { background: var(--primary); border-color: var(--primary); color: #fff; }
.filter-search { margin-left: auto; }
.filter-search input {
  width: 260px;
  max-width: 60vw;
  padding: .55rem .9rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: .9rem;
  outline: none;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.filter-search input:focus { border-color: var(--primary-2); box-shadow: 0 0 0 3px rgba(37,99,235,.14); }
.empty-hint { text-align: center; color: var(--muted); padding: 3rem 0; }

/* ---------- Product detail ---------- */
.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: 3rem;
  align-items: start;
}
.gallery-main {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.gallery-placeholder { color: #b6c2d9; }
.gallery-thumbs { display: flex; gap: .6rem; margin-top: .7rem; flex-wrap: wrap; }
.thumb {
  width: 74px; height: 74px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--white);
  cursor: pointer;
  transition: border-color var(--ease);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb:hover { border-color: var(--primary); }

.product-title { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; }
.product-meta { display: flex; flex-wrap: wrap; gap: 1.2rem; margin-top: 1rem; padding: 1rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.meta-item { font-size: .92rem; color: var(--text-2); }
.meta-item b { display: block; font-size: .75rem; color: var(--muted); font-weight: 500; letter-spacing: .04em; }
.product-summary { margin-top: 1.1rem; color: var(--text-2); }
.cert-row { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.1rem; }
.cert-badge {
  font-size: .78rem;
  font-weight: 700;
  padding: .28rem .65rem;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--text-2);
}
.cert-ce { color: #0b5ed7; border-color: #bfd3f8; background: #eef4ff; }
.cert-ul { color: #b45309; border-color: #fde68a; background: #fffbeb; }
.cert-csa, .cert-ccc { color: #047857; border-color: #a7f3d0; background: #ecfdf5; }
.cert-sil { color: #7c3aed; border-color: #ddd6fe; background: #f5f3ff; }
.cert-iso { color: #0369a1; border-color: #bae6fd; background: #f0f9ff; }
.cert-ex, .cert-metrology { color: #b91c1c; border-color: #fecaca; background: #fef2f2; }
.cert-marine { color: #155e75; border-color: #a5f3fc; background: #ecfeff; }
.product-cta { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.6rem; }

/* ---------- Specs ---------- */
.spec-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 1.6rem; }
.spec-group { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem 1.4rem; }
.spec-group h3 { font-size: 1.02rem; margin-bottom: .8rem; color: var(--primary); }
.spec-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.spec-table th, .spec-table td { text-align: left; padding: .55rem .3rem; border-bottom: 1px dashed var(--border); vertical-align: top; }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: none; }
.spec-table th { width: 42%; color: var(--muted); font-weight: 500; }
.spec-table td { color: var(--text); }

.spec-empty {
  background: var(--white);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 1.4rem 1.6rem;
  color: var(--text-2);
  font-size: .95rem;
}
.spec-empty a { color: var(--primary); font-weight: 600; text-decoration: underline; }

/* ---------- Docs ---------- */
.doc-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: .9rem; }
.doc-item {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .9rem 1rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.doc-item:hover { border-color: var(--primary-2); box-shadow: var(--shadow-sm); }
.doc-item a { display: flex; align-items: center; gap: .8rem; width: 100%; }
.doc-icon { color: var(--primary); flex-shrink: 0; display: inline-flex; }
.doc-body { display: flex; flex-direction: column; gap: .1rem; min-width: 0; }
.doc-name { font-weight: 600; font-size: .94rem; }
.doc-meta { font-size: .78rem; color: var(--muted); }

/* ---------- Info strip ---------- */
.info-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
}
.info-cell { display: flex; flex-direction: column; gap: .2rem; }
.info-label { font-size: .78rem; color: var(--muted); letter-spacing: .05em; }
.info-value { font-weight: 700; font-size: 1.05rem; }

/* ---------- CTA ---------- */
.cta-section { background: linear-gradient(135deg, #0b1a45, #1d3f9e); color: #fff; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta-text h2 { font-size: 1.55rem; font-weight: 800; }
.cta-text p { margin-top: .5rem; color: #c9d8ff; }
.cta-actions { display: flex; gap: .8rem; flex-wrap: wrap; }
.cta-inner-compact .cta-text h2 { font-size: 1.35rem; }
.cta-inner-compact .cta-text p { color: var(--text-2); }
.cta-inner-compact { color: var(--text); }

/* ---------- Breadcrumb ---------- */
.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; font-size: .88rem; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb .sep { opacity: .5; }
.breadcrumb .current { font-weight: 600; }

/* ---------- Rich text ---------- */
.rich-text { max-width: 860px; }
.rich-text h2 { margin: 2rem 0 .9rem; font-size: 1.45rem; }
.rich-text h3 { margin: 1.5rem 0 .7rem; font-size: 1.15rem; }
.rich-text p { margin: 0 0 1rem; }
.rich-text ul, .rich-text ol { margin: 0 0 1rem 1.3rem; list-style: disc; }
.rich-text ol { list-style: decimal; }
.rich-text li { margin: .25rem 0; }
.rich-text img { border-radius: var(--radius); margin: 1.2rem 0; }
.rich-text table { width: 100%; border-collapse: collapse; margin: 1rem 0 1.4rem; font-size: .93rem; }
.rich-text th, .rich-text td { border: 1px solid var(--border); padding: .55rem .7rem; text-align: left; }
.rich-text th { background: #f1f5f9; }
.rich-text blockquote { margin: 1.2rem 0; padding: .8rem 1.1rem; border-left: 3px solid var(--primary); background: #eef2ff; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.rich-text pre { background: #0f172a; color: #e2e8f0; padding: 1rem 1.2rem; border-radius: var(--radius-sm); overflow-x: auto; font-size: .86rem; }
.rich-text code { background: #eef2f7; padding: .1rem .35rem; border-radius: 4px; font-size: .88em; }
.rich-text pre code { background: transparent; padding: 0; }
.rich-text a { color: var(--primary); text-decoration: underline; }

/* ---------- Forms (Grav Form plugin) ---------- */
form, .form { max-width: 720px; }
.form-group { margin-bottom: 1.1rem; }
.form-label, form label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .4rem; }
.form-control, form input[type="text"], form input[type="email"], form input[type="tel"], form input[type="number"], form select, form textarea {
  width: 100%;
  padding: .65rem .85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font: inherit;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--ease), box-shadow var(--ease);
}
form input:focus, form select:focus, form textarea:focus {
  outline: none;
  border-color: var(--primary-2);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .13);
}
form textarea { min-height: 120px; resize: vertical; }
form .form-actions { margin-top: 1.3rem; }
.form-message { padding: .9rem 1.1rem; border-radius: var(--radius-sm); margin-bottom: 1.2rem; background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }

/* Grav Form plugin 渲染结构补充 */
.form-panel {
  max-width: 760px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 2rem 2.2rem;
  box-shadow: var(--shadow-sm);
}
.form-wrapper { max-width: 100%; }
.form-field { margin-bottom: 1.1rem; }
.form-data { margin-top: .35rem; }
.form-actions { margin-top: 1.4rem; }
.form-actions .btn { min-width: 140px; }
.form-message {
  padding: .8rem 1rem;
  border-radius: var(--radius-sm);
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  margin-bottom: 1.2rem;
}
.form-errors { color: #b91c1c; font-size: .85rem; margin-top: .3rem; }
.form-field .required { color: #dc2626; }

/* ---------- Footer ---------- */
.site-footer { background: #0b1424; color: #cbd5e1; margin-top: 0; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.3fr;
  gap: 2.2rem;
  padding: 3.4rem 0 2.6rem;
}
.footer-brand { color: #fff; font-size: 1.15rem; font-weight: 800; margin-bottom: .7rem; }
.footer-desc { font-size: .9rem; color: #94a3b8; max-width: 340px; }
.footer-title { color: #fff; font-size: .95rem; font-weight: 700; margin-bottom: .9rem; letter-spacing: .04em; }
.footer-links { display: flex; flex-direction: column; gap: .5rem; }
.footer-links a { color: #94a3b8; font-size: .9rem; transition: color var(--ease); }
.footer-links a:hover { color: #fff; }
.footer-line { display: flex; gap: .6rem; font-size: .9rem; color: #94a3b8; margin-bottom: .55rem; }
.footer-label { color: #64748b; flex-shrink: 0; }
.footer-line a { color: #cbd5e1; }
.footer-line a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(148, 163, 184, .18); }
.footer-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 1.1rem 0;
  font-size: .82rem;
  color: #64748b;
}
.footer-bottom-inner a { color: #94a3b8; }
.footer-bottom-inner a:hover { color: #fff; }

/* ---------- Back to top ---------- */
.back-top {
  position: fixed;
  right: 1.2rem;
  bottom: 1.2rem;
  z-index: 90;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: background var(--ease), transform var(--ease), opacity var(--ease);
}
.back-top:hover { background: #16296b; transform: translateY(-2px); }
.back-top[hidden] { display: none; }

/* ---------- 关注我们（二维码页） ---------- */
.qr-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.6rem;
  max-width: 820px;
  margin: 0 auto;
}
.qr-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.6rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.qr-media {
  width: 220px;
  height: 220px;
  margin: 0 auto 1.2rem;
  border: 1px dashed #cbd5e1;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  overflow: hidden;
}
.qr-img { width: 100%; height: 100%; object-fit: contain; }
.qr-placeholder {
  color: #94a3b8;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  font-size: .8rem;
}
.qr-title { font-size: 1.15rem; font-weight: 700; }
.qr-desc { margin-top: .5rem; color: var(--text-2); font-size: .92rem; }
.qr-hint { text-align: center; margin-top: 2rem; color: var(--muted); font-size: .9rem; }

/* ---------- 选型对照表 ---------- */
.filter-compare { margin-left: .4rem; font-size: .88rem; white-space: nowrap; }
.table-scroll {
  overflow-x: auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 940px;
  font-size: .9rem;
}
.compare-table th,
.compare-table td {
  padding: .8rem .9rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  white-space: nowrap;
}
.compare-table thead th {
  background: #f1f5f9;
  font-weight: 700;
  font-size: .82rem;
  color: var(--text-2);
}
.compare-table tbody tr:hover { background: #f8fafc; }
.cmp-model a { font-weight: 700; color: var(--primary); }
.cmp-name {
  display: block;
  font-size: .78rem;
  color: var(--muted);
  white-space: normal;
  max-width: 220px;
}
.cmp-tag {
  display: inline-block;
  margin-left: .3rem;
  font-size: .72rem;
  color: #b91c1c;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 4px;
  padding: .05rem .35rem;
}
.cmp-docs { color: var(--text-2); }
.cmp-link { font-weight: 600; color: var(--primary); }
.compare-table .cert-badge {
  font-size: .7rem;
  padding: .12rem .4rem;
  margin-right: .25rem;
  border-radius: 4px;
}

/* ---------- 移动端底部快捷栏 ---------- */
.mobile-actions { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .product-layout { grid-template-columns: 1fr; gap: 2rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .site-nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: .2rem;
    padding: .8rem 1.25rem 1.2rem;
    background: #fff;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  .site-nav.is-open { display: flex; }
  .nav-link { padding: .75rem .6rem; border-radius: var(--radius-sm); }
  .nav-cta { margin: .5rem 0 0; }
  .nav-toggle { display: flex; }
  .hero { padding: 4rem 0 3.2rem; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: .9rem 1.2rem; }
  .filter-search { margin-left: 0; width: 100%; }
  .filter-search input { max-width: 100%; width: 100%; }

  /* 移动端底部操作栏 */
  .mobile-actions {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 95;
    gap: .6rem;
    padding: .55rem .8rem calc(.55rem + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .97);
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 14px rgba(15, 23, 42, .08);
  }
  .ma-btn {
    flex: 1;
    text-align: center;
    padding: .72rem .5rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: .95rem;
    color: var(--primary);
    background: #eef2ff;
    border: 1px solid var(--primary);
  }
  .ma-btn.ma-primary {
    background: var(--primary);
    color: #fff;
  }
  body { padding-bottom: 70px; }
  .back-top { bottom: 86px; }
}

@media (max-width: 620px) {
  .section { padding: 3rem 0; }
  .section-head { flex-direction: column; align-items: flex-start; gap: .5rem; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
  .series-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .footer-grid { grid-template-columns: 1fr; gap: 1.8rem; padding: 2.6rem 0 2rem; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
  .hero-actions .btn { width: 100%; }
  .product-cta .btn { flex: 1; }
}

/* ---------- 登录页居中 ---------- */
body.login-page #main-content {
  min-height: calc(100vh - var(--header-h) - 320px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem 4rem;
}
#grav-login {
  width: 100%;
  max-width: 440px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 2.2rem 2rem 2.4rem;
}
#grav-login h1 {
  text-align: center;
  font-size: 1.35rem;
  margin-bottom: 1.5rem;
}
#grav-login .login-form .form-group { margin-bottom: 1rem; }
#grav-login .login-form .btn,
#grav-login .login-form button[type="submit"] { width: 100%; }
#grav-login .login-form hr {
  margin: 1.2rem 0;
  border: 0;
  border-top: 1px solid var(--border);
}
#grav-login .login-form p { text-align: center; font-size: .9rem; }

/* ---------- 登录页标题中文化 ---------- */
#grav-login > h1 { display: none; }
#grav-login::before {
  content: "管理员登录";
  display: block;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--text);
}

/* ---------- 建站工具页 ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.4rem; }
.tool-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm); }
.tool-card h2 { font-size: 1.1rem; margin-bottom: .6rem; }
.tool-card p { color: var(--text-2); font-size: .92rem; margin-bottom: 1rem; }
.tool-label { display: block; font-size: .9rem; font-weight: 600; margin-bottom: .6rem; }
.tool-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }
.tool-result { border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 1.6rem; border: 1px solid; }
.tool-ok { background: #ecfdf5; border-color: #a7f3d0; color: #047857; }
.tool-err { background: #fef2f2; border-color: #fecaca; color: #b91c1c; }
.tool-result pre { white-space: pre-wrap; word-break: break-all; font-size: .82rem; margin-top: .6rem; max-height: 260px; overflow: auto; background: rgba(0,0,0,.04); padding: .6rem; border-radius: 6px; }
.tool-login { max-width: 520px; }

/* ---------- FAQ 常见问题 ---------- */
.faq-wrap { max-width: 860px; margin: 0 auto; }
.faq-item { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: .9rem; box-shadow: var(--shadow-sm); overflow: hidden; }
.faq-q { cursor: pointer; padding: 1.05rem 2.8rem 1.05rem 1.3rem; font-weight: 700; font-size: 1rem; list-style: none; position: relative; }
.faq-q::-webkit-details-marker { display: none; }
.faq-q::after { content: "+"; position: absolute; right: 1.2rem; top: 50%; transform: translateY(-50%); font-size: 1.25rem; color: var(--primary); }
.faq-item[open] .faq-q::after { content: "−"; }
.faq-a { padding: 0 1.3rem 1.2rem; color: var(--text-2); font-size: .95rem; line-height: 1.75; }
.faq-more { text-align: center; margin-top: 2.4rem; }
.faq-more p { margin-bottom: .8rem; color: var(--muted); }

/* ---------- 管理员快捷操作 ---------- */
.admin-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.2rem; }

/* ---------- 产品编辑图册预览 ---------- */
.edit-gallery { display: flex; gap: .6rem; flex-wrap: wrap; margin: .5rem 0 1rem; }
.edit-gallery img { width: 88px; height: 88px; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); }

/* ---------- 产品中心内嵌管理面板 ---------- */
.admin-panel-head { display: flex; align-items: baseline; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.admin-panel-head h2 { font-size: 1.3rem; font-weight: 800; margin: 0; }
.admin-panel-head span { color: var(--muted); font-size: .88rem; }
.admin-box { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem 1.5rem; margin-bottom: 1.2rem; box-shadow: var(--shadow-sm); }
.admin-box-title { font-weight: 700; font-size: 1.02rem; margin-bottom: 1rem; cursor: pointer; }
details.admin-box > summary { list-style: none; }
details.admin-box > summary::-webkit-details-marker { display: none; }
.admin-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 .9rem; }

/* ---------- 图册管理 ---------- */
.image-manage { margin-top: 1.4rem; border-top: 1px dashed var(--border); padding-top: 1.2rem; }
.image-manage-title { font-weight: 700; margin-bottom: .9rem; }
.image-manage-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; }
.image-manage-item { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .6rem; background: var(--white); }
.image-manage-item img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }
.image-manage-name { font-size: .75rem; color: var(--muted); margin: .4rem 0; word-break: break-all; }
.image-manage-ops { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.image-manage-ops .btn-sm { padding: .25rem .5rem; font-size: .75rem; }

/* ---------- 管理员登录提示 ---------- */
.admin-login-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: .6rem 1rem;
  margin-bottom: 1rem;
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  background: #f1f5f9;
  color: var(--muted);
  font-size: .88rem;
}

/* ---------- 知识库 / 文章 ---------- */
.article-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.2rem; }
.article-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s; }
.article-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.article-card-link { display: block; color: inherit; text-decoration: none; }
.article-date { font-size: .78rem; color: var(--muted); }
.article-card-title { font-size: 1.2rem; font-weight: 800; margin: .4rem 0 .6rem; }
.article-card-summary { color: var(--muted); font-size: .92rem; line-height: 1.7; }
.article-body { max-width: 820px; }
.article-body h2 { margin: 2rem 0 .8rem; font-size: 1.4rem; }
.article-body h3 { margin: 1.4rem 0 .5rem; font-size: 1.15rem; }
.article-body p, .article-body li { line-height: 1.9; color: #334155; }
.article-body ul, .article-body ol { padding-left: 1.4rem; }
.article-body table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.article-body th, .article-body td { border: 1px solid var(--border); padding: .55rem .7rem; text-align: left; font-size: .92rem; }
.article-body blockquote { border-left: 3px solid var(--primary); margin: 1.2rem 0; padding: .4rem 1rem; background: #f8fafc; color: #475569; }
.article-cta { margin-top: 2.5rem; padding: 1.6rem; border: 1px solid var(--border); border-radius: var(--radius); background: #f8fafc; }
