/* ============================================================
   ICShine 法务页面样式（隐私政策 / 用户服务协议 / 账号注销说明）
   2026-11-16：与 www.icshine.com 首页完全对齐
   —— 设计变量、页头结构、导航交互都照搬 site.css 的同名规则，
      这样这三个页面的顶部菜单和首页一模一样。
   注意：本文件不引用 www 的 site.css（避免跨域依赖），
        所以变量与页头规则在这里有一份副本；改首页样式时请同步这里。
   ============================================================ */

/* ---------- 1. 设计变量（与 site.css 一致） ---------- */
:root {
  --bg: #0D1113;
  --bg-soft: #101518;
  --panel: #151A1D;
  --panel-2: #1A2024;
  --line: #232A2E;
  --line-2: #313A3F;
  --text: #DDE3E6;
  --text-strong: #EDF1F3;
  --muted: #9AA6AC;
  --dim: #7C8A91;
  --faint: #5A676E;

  --brand: #1365AF;
  --brand-deep: #0F528F;
  --brand-ink: #7FBEEA;
  --accent: var(--brand-ink);
  --accent-deep: var(--brand);
  --accent-soft: rgba(19, 101, 175, .16);
  --accent-line: rgba(127, 190, 234, .30);

  --ok: #4FA98A;
  --radius: 12px;
  --radius-sm: 8px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --max: 1160px;
  --header-h: 64px;
}

/* ---------- 2. 基础 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }

a { color: var(--brand-ink); text-decoration: none; }
a:hover { color: #A8D4F2; }

h1, h2, h3, h4 { margin: 0; color: var(--text-strong); line-height: 1.3; letter-spacing: -.01em; }
p { margin: 0; }
button { font: inherit; color: inherit; }

::selection { background: rgba(19, 101, 175, .45); color: #fff; }
:focus-visible { outline: 2px solid var(--brand-ink); outline-offset: 3px; border-radius: 4px; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.lg-container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------- 3. 页头（与 site.css 同名同值） ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: var(--header-h);
}

.brand { display: inline-flex; align-items: center; gap: 11px; flex-shrink: 0; color: var(--text-strong); text-decoration: none; }
.brand:hover { color: var(--text-strong); }
.brand--logo { gap: 0; }
/* 原样输出：不加底板、不改比例，只控制高度 */
.brand--logo .brand-logo { display: block; height: 36px; width: auto; }

.site-nav { display: flex; align-items: center; gap: 2px; }

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--muted);
  font-size: .9rem;
  font-weight: 400;
  line-height: 1.4;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: color .15s ease, background-color .15s ease;
}
.nav-link:hover { background: rgba(255, 255, 255, .04); color: var(--text-strong); }
.nav-link.active { color: var(--text-strong); }
.nav-link.active::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: -1px;
  height: 2px;
  background: var(--brand);
}
.nav-login { margin-left: 6px; border: 1px solid var(--line-2); background: transparent; color: var(--text); }
.nav-login:hover { border-color: #46545C; background: rgba(255, 255, 255, .03); color: var(--text-strong); }

.caret {
  width: 5px;
  height: 5px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
  opacity: .8;
  transition: transform .15s ease;
}
.nav-item { position: relative; }
.nav-item.is-open > .menu-trigger .caret { transform: rotate(-135deg) translate(-2px, -2px); }

.nav-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 250px;
  padding: 8px;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .5);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity .15s ease, transform .15s ease, visibility .15s ease;
}
.nav-item.is-open > .nav-menu { opacity: 1; visibility: visible; transform: translateY(0); }
@media (hover: hover) and (min-width: 901px) {
  .nav-item:hover > .nav-menu { opacity: 1; visibility: visible; transform: translateY(0); }
  .nav-item::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 12px;
  }
}

.nav-menu a {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 9px 12px;
  border-radius: 6px;
  color: var(--text);
  font-size: .88rem;
  font-weight: 400;
  text-decoration: none;
}
.nav-menu a:hover { background: rgba(255, 255, 255, .04); color: var(--text-strong); }
.nav-menu a.active { background: rgba(255, 255, 255, .04); color: var(--text-strong); }
.nav-menu--legal a { flex-direction: row; align-items: center; justify-content: space-between; gap: 16px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line-2);
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
}
.nav-toggle span { display: block; width: 16px; height: 1.5px; border-radius: 2px; background: var(--text); transition: transform .15s ease, opacity .15s ease; }
.site-header.nav-open .nav-toggle span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.site-header.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-header.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

/* ---------- 4. 正文 ---------- */
.lg-main { padding: 48px 0 72px; }

.lg-doc {
  max-width: 860px;
  margin: 0 auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 44px 52px;
}

.lg-doc h1 {
  margin: 0 0 8px;
  font-size: 1.9rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.01em;
}

.lg-doc .date {
  margin: 0 0 30px;
  color: var(--dim);
  font-size: .88rem;
  font-variant-numeric: tabular-nums;
}

.lg-doc h2 {
  margin: 38px 0 14px;
  padding-left: 12px;
  font-size: 1.15rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-strong);
  border-left: 2px solid var(--brand);
}

.lg-doc h3 {
  margin: 24px 0 10px;
  font-size: 1rem;
  font-weight: 500;
}

.lg-doc p { margin: 0 0 14px; }

.lg-doc strong { color: var(--text-strong); font-weight: 500; }

.lg-doc ul, .lg-doc ol { margin: 0 0 16px; padding-left: 22px; }
.lg-doc li { margin-bottom: 8px; }

.lg-doc blockquote {
  margin: 18px 0;
  padding: 12px 18px;
  border-left: 2px solid var(--line-2);
  background: var(--bg-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--muted);
}

.lg-doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 22px;
  font-size: .94rem;
}
.lg-doc th, .lg-doc td {
  border: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.lg-doc th { background: var(--bg-soft); color: var(--text); font-weight: 500; }

.lg-doc code {
  padding: 1px 5px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--bg-soft);
  font-family: var(--mono);
  font-size: .88em;
  color: var(--text);
  word-break: break-all;
}

.lg-doc hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 32px 0;
}

/* ---------- 5. 页脚 ---------- */
.lg-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 24px 0;
  text-align: center;
  color: var(--faint);
  font-size: .82rem;
}
.lg-footer p { margin: 4px 0; }
.lg-footer a { color: var(--dim); }
.lg-footer a:hover { color: var(--text); }

/* ---------- 6. 响应式 ---------- */
@media (max-width: 900px) {
  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
    padding: 10px 16px 18px;
    border-bottom: 1px solid var(--line);
    background: var(--bg-soft);
    box-shadow: 0 12px 24px rgba(0, 0, 0, .45);
  }
  .site-header.nav-open .site-nav { display: flex; }
  .nav-link { width: 100%; justify-content: space-between; padding: 12px; font-size: .95rem; }
  .nav-link.active::after { display: none; }
  .nav-login { margin-left: 0; margin-top: 6px; }
  .nav-item { width: 100%; }
  .nav-item > .nav-menu {
    position: static;
    display: none;
    min-width: 0;
    margin: 2px 0 6px;
    padding: 4px 0 4px 12px;
    border: 0;
    border-left: 1px solid var(--line-2);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
  }
  .nav-item.is-open > .nav-menu { display: flex; }
}

@media (max-width: 768px) {
  .container, .lg-container { padding: 0 18px; }
  .lg-main { padding: 28px 0 48px; }
  .lg-doc { padding: 24px 18px; border-radius: 10px; }
  .lg-doc h1 { font-size: 1.5rem; }
  .lg-doc h2 { font-size: 1.05rem; }
  .brand--logo .brand-logo { height: 30px; }
}
