@charset "utf-8";

/* =========================================================
   USB Network Gate 中文官网 — 公共样式 common.css
   主题色：#F86C14  浅色现代风格
   ========================================================= */

:root {
  --brand: #F86C14;
  --brand-dark: #d9560a;
  --brand-light: #ff8a3d;
  --brand-soft: #fff3eb;
  --ink: #1a1f29;
  --ink-soft: #5a6373;
  --line: #ececf0;
  --bg: #ffffff;
  --bg-alt: #f7f8fa;
  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(26, 31, 41, .06);
  --shadow-md: 0 12px 30px rgba(26, 31, 41, .08);
  --shadow-brand: 0 12px 26px rgba(248, 108, 20, .28);
  --maxw: 1200px;
  --font: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB",
          "Helvetica Neue", Arial, "Segoe UI", system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  font-size: 16px;
  letter-spacing: .01em;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

.cm-container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 通用按钮 ---------- */
.cm-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  white-space: nowrap;
}
.cm-btn svg { width: 18px; height: 18px; flex: none; }
.cm-btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: var(--shadow-brand);
}
.cm-btn-primary:hover { background: var(--brand-dark); transform: translateY(-2px); }
.cm-btn-ghost {
  background: transparent;
  color: var(--ink-soft);
  border-color: var(--line);
}
.cm-btn-ghost:hover { color: var(--brand); border-color: var(--brand); }

/* =========================================================
   导航 header 样式
   ========================================================= */
#site-header { display: contents; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-brand { display: flex; align-items: center; gap: 12px; }
.nav-brand img { width: 40px; height: 40px; border-radius: 10px; }
.nav-brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.nav-brand-name { font-size: 18px; font-weight: 700; color: var(--ink); }
.nav-brand-sub { font-size: 11px; color: var(--ink-soft); font-weight: 500; }

.nav-menu { display: flex; align-items: center; gap: 32px; }
.nav-menu a {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-soft);
  position: relative;
  padding: 6px 0;
  transition: color .18s ease;
}
.nav-menu a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--brand);
  transition: width .22s ease;
}
.nav-menu a:hover { color: var(--brand); }
.nav-menu a:hover::after { width: 100%; }

.nav-actions { display: flex; align-items: center; gap: 12px; }

/* 汉堡按钮 */
.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  position: relative;
}
.nav-toggle span {
  position: absolute;
  left: 12px;
  width: 20px; height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .28s ease, opacity .2s ease, top .28s ease;
}
.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 21px; }
.nav-toggle span:nth-child(3) { top: 27px; }
.nav-toggle.is-open span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { top: 21px; transform: rotate(-45deg); }

/* 移动端抽屉 */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 1000;
  pointer-events: none;
}
.mobile-drawer-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 18, 26, .42);
  opacity: 0;
  transition: opacity .3s ease;
}
.mobile-drawer-panel {
  position: absolute;
  top: 0; right: 0;
  width: min(82vw, 340px);
  height: 100%;
  background: #fff;
  box-shadow: -16px 0 40px rgba(0,0,0,.16);
  transform: translateX(100%);
  transition: transform .34s cubic-bezier(.22,.61,.36,1);
  display: flex;
  flex-direction: column;
  padding: 24px 22px;
  overflow-y: auto;
}
.mobile-drawer.is-open { pointer-events: auto; }
.mobile-drawer.is-open .mobile-drawer-overlay { opacity: 1; }
.mobile-drawer.is-open .mobile-drawer-panel { transform: translateX(0); }

.md-head {
  display: flex; align-items: center; gap: 12px;
  padding-bottom: 20px; margin-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.md-head img { width: 38px; height: 38px; border-radius: 10px; }
.md-head .nav-brand-name { font-size: 16px; }
.md-close {
  margin-left: auto;
  width: 36px; height: 36px;
  border: none; background: var(--bg-alt);
  border-radius: 10px; font-size: 20px; color: var(--ink-soft);
  cursor: pointer;
}
.md-links { display: flex; flex-direction: column; padding: 14px 0; }
.md-links a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 15px 12px;
  font-size: 16px; font-weight: 600;
  color: var(--ink);
  border-radius: 12px;
  transition: background .18s ease, color .18s ease;
}
.md-links a::after { content: "›"; color: var(--brand); font-size: 20px; }
.md-links a:hover { background: var(--brand-soft); color: var(--brand); }
.md-actions { display: flex; flex-direction: column; gap: 12px; margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); }
.md-actions .cm-btn { width: 100%; justify-content: center; }

/* =========================================================
   页脚 footer 样式
   ========================================================= */
.site-footer {
  background: #14181f;
  color: #c4cad6;
  padding: 64px 0 30px;
  margin-top: 80px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-links h4 { font-size: 15px; color: #fff; margin-bottom: 18px; font-weight: 600; }
.footer-links a {
  display: block; font-size: 14px; color: #9aa3b2;
  padding: 6px 0; transition: color .18s ease;
}
.footer-links a:hover { color: var(--brand-light); }
.footer-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.footer-brand img { width: 46px; height: 46px; border-radius: 12px; }
.footer-brand-name { font-size: 20px; font-weight: 700; color: #fff; }
.footer-brand-sub { font-size: 12px; color: #8b93a3; }
.footer-desc { font-size: 14px; line-height: 1.8; color: #9aa3b2; max-width: 460px; }
.footer-reseller {
  margin-top: 26px;
  padding-bottom: 26px;
  border-bottom: 1px solid rgba(255, 255, 255, .07);
  font-size: 12.5px;
  line-height: 1.9;
  color: #6c7484;
  text-align: center;
}
.footer-reseller strong { color: #8b93a3; font-weight: 600; }

.footer-contact h4 {
  font-size: 15px; color: #fff; margin-bottom: 18px; font-weight: 600;
}
.footer-contact-item {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 16px; font-size: 14px;
}
.footer-contact-item .fc-icon {
  width: 40px; height: 40px; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.06);
  border-radius: 12px;
  color: var(--brand-light);
}
.footer-contact-item .fc-icon svg { width: 20px; height: 20px; }
.footer-contact-item span small { display: block; color: #7f8798; font-size: 12px; }
.footer-contact-item a:hover { color: var(--brand-light); }

.footer-bottom {
  padding-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  font-size: 13px;
  color: #7f8798;
}

/* =========================================================
   响应式
   ========================================================= */
@media (max-width: 980px) {
  .footer-top { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 860px) {
  .nav-menu, .nav-actions { display: none; }
  .nav-toggle { display: block; }
}

/* =========================================================
   法律 / EULA 页面样式
   ========================================================= */
.legal-hero {
  background: linear-gradient(180deg, #fffaf6 0%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
  padding: 56px 0 44px;
}
.legal-hero .cm-container { max-width: 880px; }
.legal-hero .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; color: var(--brand);
  background: var(--brand-soft); padding: 7px 14px; border-radius: 999px;
}
.legal-hero .eyebrow svg { width: 15px; height: 15px; }
.legal-hero h1 { font-size: 34px; font-weight: 800; color: var(--ink); margin: 18px 0 10px; letter-spacing: -.4px; }
.legal-hero p { font-size: 15px; color: var(--ink-soft); }

.legal-section { padding: 50px 0 70px; }
.legal-section .cm-container { max-width: 880px; }
.legal-card {
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  box-shadow: var(--shadow-sm); padding: 44px 48px;
}
.legal-card h2 { font-size: 19px; font-weight: 800; color: var(--ink); margin: 32px 0 14px; }
.legal-card h2:first-child { margin-top: 0; }
.legal-card p { font-size: 15px; line-height: 1.9; color: var(--ink-soft); margin-bottom: 16px; }
.legal-card ol, .legal-card ul { margin: 0 0 16px; padding-left: 4px; counter-reset: legal; list-style: none; }
.legal-card ol li, .legal-card ul li {
  position: relative; font-size: 15px; line-height: 1.9; color: var(--ink-soft);
  padding: 0 0 14px 34px;
}
.legal-card ol li::before {
  counter-increment: legal; content: counter(legal);
  position: absolute; left: 0; top: 2px;
  width: 24px; height: 24px; border-radius: 7px;
  background: var(--brand-soft); color: var(--brand);
  font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.legal-card ul li::before {
  content: ""; position: absolute; left: 7px; top: 11px;
  width: 7px; height: 7px; border-radius: 2px; background: var(--brand);
}
.legal-card strong { color: var(--ink); font-weight: 700; }
.legal-note {
  margin-top: 28px; padding: 16px 20px; border-radius: 12px;
  background: var(--bg-alt); border: 1px solid var(--line);
  font-size: 13.5px; color: var(--ink-soft); line-height: 1.8;
}
.legal-full {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 28px;
  font-size: 14.5px; font-weight: 600; color: var(--brand);
}
.legal-full svg { width: 16px; height: 16px; }
.legal-nav { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 10px; }
.legal-nav a {
  font-size: 13px; font-weight: 600; color: var(--ink-soft);
  background: #fff; border: 1px solid var(--line); padding: 8px 14px;
  border-radius: 999px; box-shadow: var(--shadow-sm); transition: all .18s ease;
}
.legal-nav a:hover { color: var(--brand); border-color: var(--brand); }
.legal-nav a.current { background: var(--brand); color: #fff; border-color: var(--brand); }
@media (max-width: 640px) {
  .legal-card { padding: 30px 22px; }
  .legal-hero h1 { font-size: 26px; }
}

/* =========================================================
   帮助中心 样式
   ========================================================= */
.help-hero {
  background: linear-gradient(180deg, #fffaf6 0%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
  padding: 64px 0 56px; text-align: center;
}
.help-hero h1 { font-size: 38px; font-weight: 800; color: var(--ink); margin-bottom: 12px; letter-spacing: -.5px; }
.help-hero p { font-size: 16px; color: var(--ink-soft); margin-bottom: 28px; }
.help-search {
  position: relative; max-width: 620px; margin: 0 auto;
}
.help-search svg {
  position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; color: var(--ink-soft); pointer-events: none;
}
.help-search input {
  width: 100%; font-size: 16px; font-family: inherit; color: var(--ink);
  padding: 16px 20px 16px 52px; border: 1px solid var(--line); border-radius: 14px;
  background: #fff; box-shadow: var(--shadow-sm); transition: border-color .18s ease, box-shadow .18s ease;
}
.help-search input:focus { outline: none; border-color: var(--brand); box-shadow: var(--shadow-brand); }

.help-section { padding: 56px 0 72px; }
.help-cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.help-cat-card {
  display: block; background: #fff; border: 1px solid var(--line); border-radius: 18px;
  padding: 28px 24px; box-shadow: var(--shadow-sm); transition: transform .2s ease, box-shadow .2s ease;
}
.help-cat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.help-cat-card[href="#cat-kb"] { grid-column: 1 / -1; }
.help-cat-ico {
  width: 52px; height: 52px; border-radius: 14px; background: var(--brand-soft); color: var(--brand);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.help-cat-ico svg, .help-cat-ico img { width: 26px; height: 26px; }
.help-cat-card h3 { font-size: 18px; font-weight: 800; color: var(--ink); margin-bottom: 6px; }
.help-cat-card p { font-size: 13.5px; color: var(--ink-soft); }
.help-cat-count { font-size: 12.5px; color: var(--brand); font-weight: 600; margin-top: 12px; display: inline-block; }

#catBlocks { margin-top: 56px; }
.help-cat-block { margin-top: 52px; }
.help-cat-block:first-child { margin-top: 0; }
.help-cat-title { display: flex; align-items: center; gap: 12px; font-size: 22px; font-weight: 800; color: var(--ink); margin-bottom: 20px; }
.help-cat-title .help-cat-ico { width: 38px; height: 38px; border-radius: 10px; margin: 0; }
.help-cat-title .help-cat-ico svg, .help-cat-title .help-cat-ico img { width: 20px; height: 20px; }
.help-art-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.help-art-item {
  display: flex; align-items: flex-start; gap: 14px; background: #fff;
  border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px;
  box-shadow: var(--shadow-sm); transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.help-art-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--brand); }
.help-art-item .doc-ico { width: 18px; height: 18px; color: var(--brand); flex: none; margin-top: 3px; }
.help-art-item h4 { font-size: 15px; font-weight: 700; color: var(--ink); margin-bottom: 4px; line-height: 1.5; }
.help-art-item p { font-size: 13px; color: var(--ink-soft); line-height: 1.6; }
.help-empty { text-align: center; color: var(--ink-soft); font-size: 15px; padding: 60px 0; }
.help-empty b { color: var(--ink); }
.help-results-head { font-size: 14px; color: var(--ink-soft); margin-bottom: 20px; }
mark { background: #ffe08a; color: inherit; padding: 0 2px; border-radius: 3px; }

/* 文章页 */
.article-layout { display: grid; grid-template-columns: 1fr 280px; gap: 48px; align-items: start; }
.article-main { min-width: 0; }
.breadcrumb { font-size: 13px; color: var(--ink-soft); margin-bottom: 18px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.breadcrumb a { color: var(--ink-soft); }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb span.sep { color: #c4cad6; }
.article-title { font-size: 30px; font-weight: 800; color: var(--ink); line-height: 1.3; margin-bottom: 10px; letter-spacing: -.4px; }
.article-cat-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; color: var(--brand); background: var(--brand-soft); padding: 5px 12px; border-radius: 999px; margin-bottom: 24px; }
.article-cat-badge svg, .article-cat-badge img { width: 15px; height: 15px; flex: none; }
.article-body { font-size: 15.5px; line-height: 1.9; color: #3a4250; }
.article-body p { margin-bottom: 18px; }
.article-body h2 { font-size: 21px; font-weight: 800; color: var(--ink); margin: 36px 0 14px; }
.article-body h3 { font-size: 17px; font-weight: 700; color: var(--ink); margin: 26px 0 12px; }
.article-body ul, .article-body ol { margin: 0 0 18px; padding-left: 0; list-style: none; counter-reset: art; }
.article-body li { position: relative; padding: 0 0 12px 32px; }
.article-body ol > li::before {
  counter-increment: art; content: counter(art);
  position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 6px;
  background: var(--brand-soft); color: var(--brand); font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.article-body ul > li::before {
  content: ""; position: absolute; left: 7px; top: 11px; width: 7px; height: 7px;
  border-radius: 2px; background: var(--brand);
}
.article-body img { max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: 12px; margin: 8px 0 20px; box-shadow: var(--shadow-sm); }
.article-body a { color: var(--brand); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.article-body strong { color: var(--ink); font-weight: 700; }
.article-body .note {
  background: var(--brand-soft); border-left: 3px solid var(--brand); border-radius: 0 12px 12px 0;
  padding: 14px 18px; margin: 0 0 18px; font-size: 14.5px; color: #5a4636;
}
.article-body .note strong { color: var(--brand-dark); }
.article-body code { background: var(--bg-alt); border: 1px solid var(--line); border-radius: 6px; padding: 2px 7px; font-size: 13.5px; color: var(--brand-dark); }
.article-body pre { background: #14181f; color: #e6e9ee; border-radius: 12px; padding: 18px 20px; overflow-x: auto; margin: 0 0 18px; font-size: 13.5px; line-height: 1.7; }
.article-body pre code { background: none; border: none; color: inherit; padding: 0; }

.article-aside { position: sticky; top: 90px; }
.aside-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 22px; box-shadow: var(--shadow-sm); }
.aside-card h4 { font-size: 13px; font-weight: 700; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 14px; }
.aside-card a { display: block; font-size: 14px; color: var(--ink); padding: 8px 0; line-height: 1.5; border-top: 1px solid var(--line); }
.aside-card a:first-of-type { border-top: none; }
.aside-card a:hover { color: var(--brand); }
.aside-card a.current { color: var(--brand); font-weight: 700; }
.article-back { display: inline-flex; align-items: center; gap: 8px; margin-top: 40px; font-size: 14px; font-weight: 600; color: var(--brand); }
.article-back svg { width: 16px; height: 16px; }

@media (max-width: 980px) {
  .help-cat-grid { grid-template-columns: repeat(2, 1fr); }
  .article-layout { grid-template-columns: 1fr; }
  .article-aside { position: static; }
}
@media (max-width: 640px) {
  .help-cat-grid { grid-template-columns: 1fr; }
  .help-art-list { grid-template-columns: 1fr; }
  .help-hero h1 { font-size: 28px; }
  .article-title { font-size: 24px; }
}
