/* Bit7s Legal & Info Pages - Shared Styles */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #f8fafc;
  color: #0f172a;
  line-height: 1.65;
}
a { color: #ff6b35; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Header — 标准浅色（与首页 index.css 一致） */
:root {
  --bit7s-blue: #2563eb;
  --bit7s-blue-dark: #1d4ed8;
  --bit7s-blue-soft: #eff6ff;
  --bit7s-dark: #0f172a;
  --bit7s-gray: #64748b;
  --bit7s-light-gray: #f8fafc;
  --bit7s-border: #e2e8f0;
}
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 48px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--bit7s-border);
}
.logo {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--bit7s-blue);
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.logo-img { height: 34px; width: auto; border-radius: 8px; }
nav ul { display: flex; gap: 28px; list-style: none; }
.mega ul { list-style: none; }
nav a {
  color: #334155;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
}
nav a:hover { color: var(--bit7s-blue); text-decoration: none; }
header a:hover { text-decoration: none; }
.nav-actions { display: flex; gap: 12px; align-items: center; }
.btn-primary {
  padding: 10px 24px;
  background: var(--bit7s-blue);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.2s;
  display: inline-block;
}
.btn-primary:hover { background: var(--bit7s-blue-dark); }
.btn-quote {
  padding: 10px 24px;
  background: transparent;
  color: #334155;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.2s;
}
.btn-quote:hover { border-color: var(--bit7s-blue); color: var(--bit7s-blue); }

/* Solutions Mega Menu（与首页一致） */
.has-mega { position: relative; }
.mega-trigger { display: inline-flex; align-items: center; gap: 5px; }
.mega-chevron { opacity: 0.5; transition: transform 0.2s; }
.has-mega:hover .mega-chevron { transform: rotate(180deg); }
.mega {
  display: none;
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%);
  width: 920px;
  max-width: calc(100vw - 40px);
  background: #fff;
  border: 1px solid var(--bit7s-border);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.14);
  z-index: 1002;
  overflow: hidden;
}
.has-mega:hover .mega,
.has-mega:focus-within .mega { display: flex; }
.mega::before { content: ''; position: absolute; top: -16px; left: 0; right: 0; height: 16px; }
.mega-main {
  flex: 1.7;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 40px;
  padding: 28px 36px 30px;
  align-content: start;
}
.mega-side {
  flex: 1;
  background: var(--bit7s-light-gray);
  border-left: 1px solid var(--bit7s-border);
  padding: 28px 32px 30px;
}
.mega-heading {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #94a3b8;
  margin: 22px 0 10px;
}
.mega-col > .mega-heading:first-child,
.mega-side > .mega-heading:first-child { margin-top: 0; }
.mega-heading.ghost { visibility: hidden; }
.mega-list { display: flex; flex-direction: column; gap: 2px; }
.mega-list a {
  display: block;
  padding: 7px 10px;
  margin: 0 -10px;
  border-radius: 8px;
  color: #1e293b;
  font-weight: 600;
  font-size: 0.92rem;
  transition: background 0.15s, color 0.15s;
}
.mega-list a:hover { background: var(--bit7s-blue-soft); color: var(--bit7s-blue); text-decoration: none; }
.mega-uc { display: flex; flex-direction: column; gap: 2px; }
.mega-uc a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  margin: 0 -10px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  color: #1e293b;
  transition: background 0.15s, color 0.15s;
}
.mega-uc a:hover { background: #fff; color: var(--bit7s-blue); text-decoration: none; }
.mega-uc svg { color: var(--bit7s-blue); flex: none; }
.mega-why { display: flex; flex-direction: column; gap: 4px; }
.mega-why a {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 0.92rem;
  color: #1e293b;
  padding: 5px 0;
}
.mega-why a:hover { color: var(--bit7s-blue); text-decoration: none; }
@media (max-width: 1100px) {
  .mega { width: 640px; }
  .mega-main { grid-template-columns: 1fr; }
  .mega-heading.ghost { display: none; }
}

/* Hero（fixed header 63px，顶部留白补偿） */
.legal-hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #fff;
  padding: 123px 48px 40px;
  text-align: center;
}
.legal-hero h1 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 8px;
}
.legal-hero .updated {
  color: #94a3b8;
  font-size: 0.9rem;
}

/* Content */
.legal-content {
  max-width: 820px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}
.legal-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0f172a;
  margin: 40px 0 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid #ff6b35;
  display: inline-block;
}
.legal-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1e293b;
  margin: 24px 0 12px;
}
.legal-content p { margin-bottom: 16px; color: #334155; }
.legal-content ul, .legal-content ol {
  margin: 0 0 16px 24px;
  color: #334155;
}
.legal-content li { margin-bottom: 8px; }
.legal-content code {
  background: #f1f5f9;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'SF Mono', Consolas, monospace;
  font-size: 0.9em;
  color: #0f172a;
}
.legal-content pre {
  background: #0f172a;
  color: #fff;
  padding: 20px;
  border-radius: 8px;
  overflow-x: auto;
  margin: 16px 0;
}
.legal-content pre code { background: transparent; color: #fff; padding: 0; }
.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}
.legal-content th, .legal-content td {
  border: 1px solid #e2e8f0;
  padding: 10px 14px;
  text-align: left;
  font-size: 0.92rem;
}
.legal-content th { background: #f1f5f9; font-weight: 700; }
.legal-content .callout {
  background: #fff7ed;
  border-left: 4px solid #ff6b35;
  padding: 16px 20px;
  margin: 16px 0;
  border-radius: 4px;
  color: #7c2d12;
}

/* Footer */
.legal-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 32px 48px;
  text-align: center;
  font-size: 0.88rem;
}
.legal-footer .links { margin-bottom: 16px; }
.legal-footer .links a {
  color: #cbd5e1;
  margin: 0 12px;
}
.legal-footer .links a:hover { color: #ff6b35; text-decoration: none; }

@media (max-width: 768px) {
  header { padding: 12px 20px; }
  nav { display: none; }
  .legal-hero { padding: 99px 20px 40px; }
  .legal-hero h1 { font-size: 1.8rem; }
  .legal-content { padding: 32px 16px 60px; }
}
@media (max-width: 768px) {
  .has-mega .mega { display: none !important; }
}
