:root {
  --legal-bg: #f6f7fb;
  --legal-border: #dfe6ef;
  --legal-muted: #64748b;
  --legal-text: #172033;
}

* { box-sizing: border-box; }

body {
  background: var(--legal-bg);
  color: var(--legal-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  margin: 0;
}

.legal-topbar {
  background: #0d6efd;
  height: 52px;
  padding: 0 max(18px, calc((100vw - 980px) / 2));
}

.legal-topbar a {
  align-items: center;
  color: #fff;
  display: inline-flex;
  font-size: .9rem;
  font-weight: 650;
  gap: 7px;
  height: 52px;
  text-decoration: none;
}

.legal-shell {
  margin: 24px auto 20px;
  max-width: 980px;
  padding: 0 18px;
}

.legal-shell article {
  background: #fff;
  border: 1px solid var(--legal-border);
  border-radius: 10px;
  padding: 30px 36px;
}

.legal-heading {
  border-bottom: 1px solid #e8edf3;
  margin-bottom: 20px;
  padding-bottom: 18px;
}

.legal-heading h1 {
  font-size: 1.55rem;
  font-weight: 750;
  margin: 0 0 7px;
}

.legal-heading p {
  color: var(--legal-muted);
  font-size: .82rem;
  margin: 0;
}

.legal-lead {
  color: #334155 !important;
  font-weight: 550;
}

.legal-note {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #3b82f6;
  border-radius: 7px;
  color: #334155;
  display: grid;
  font-size: .86rem;
  gap: 5px;
  line-height: 1.75;
  margin-top: 18px;
  padding: 13px 15px;
}

.legal-note strong { color: #1e3a5f; }
.legal-shell section { margin-top: 25px; }

.legal-shell h2 {
  color: #172033;
  font-size: 1rem;
  font-weight: 730;
  margin: 0 0 9px;
}

.legal-shell p,
.legal-list {
  color: #475569;
  font-size: .9rem;
  line-height: 1.85;
}

.legal-shell p { margin: 0; }
.legal-shell p + p { margin-top: 9px; }
.legal-shell a { text-decoration: none; }

.legal-list {
  margin: 0;
  padding-left: 1.2rem;
}

.legal-list li + li { margin-top: 5px; }

.legal-table-wrap {
  border: 1px solid var(--legal-border);
  border-radius: 7px;
  margin: 11px 0 12px;
  overflow-x: auto;
}

.legal-table {
  border-collapse: collapse;
  color: #475569;
  font-size: .82rem;
  line-height: 1.65;
  min-width: 700px;
  width: 100%;
}

.legal-table--compact { min-width: 560px; }

.legal-table th,
.legal-table td {
  border-bottom: 1px solid #e8edf3;
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.legal-table th {
  background: #f8fafc;
  color: #334155;
  font-weight: 700;
  white-space: nowrap;
}

.legal-table tr:last-child td { border-bottom: 0; }

.legal-table code {
  background: #f1f5f9;
  border-radius: 4px;
  color: #334155;
  font-size: .78rem;
  padding: 2px 4px;
}

.legal-footer {
  color: var(--legal-muted);
  display: flex;
  flex-wrap: wrap;
  font-size: .78rem;
  gap: 8px 18px;
  justify-content: center;
  margin: 0 auto 32px;
  max-width: 980px;
  padding: 0 18px;
}

@media (max-width: 600px) {
  .legal-shell { margin-top: 14px; padding: 0 12px; }
  .legal-shell article { padding: 22px 18px; }
  .legal-heading h1 { font-size: 1.3rem; }
  .legal-shell section { margin-top: 21px; }
  .legal-shell p, .legal-list { font-size: .86rem; line-height: 1.75; }
  .legal-note { font-size: .82rem; }
  .legal-table { font-size: .78rem; }
  .legal-table th, .legal-table td { padding: 9px 10px; }
  .legal-footer { justify-content: flex-start; padding: 0 14px; }
}
