:root {
  color-scheme: light;
  --cockpit: #111a1d;
  --cockpit-raised: #192529;
  --ink: #152024;
  --muted: #667277;
  --fog: #f2f5f2;
  --paper: #ffffff;
  --lime: #88df4e;
  --lime-strong: #72cc39;
  --teal: #148d7b;
  --line: #dbe3dd;
  --soft-lime: #eef9e7;
  --soft-teal: #e7f6f2;
  --shadow: 0 24px 70px rgba(17, 26, 29, 0.12);
  font-family:
    Inter, "SF Pro Text", "PingFang SC", "Microsoft YaHei", system-ui,
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background: var(--fog);
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
  background-image:
    linear-gradient(rgba(21, 32, 36, 0.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 32, 36, 0.032) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, black, transparent 70%);
}

a {
  color: inherit;
  text-underline-offset: 3px;
}

:focus-visible {
  outline: 3px solid rgba(20, 141, 123, 0.45);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 10px;
  color: white;
  background: var(--cockpit);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: none;
}

.shell {
  width: min(1080px, calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  color: white;
  background: var(--cockpit);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  color: white;
  text-decoration: none;
}

.brand img {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 13px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.brand-name {
  display: grid;
  gap: 2px;
}

.brand-name strong {
  font-size: 16px;
  letter-spacing: 0.04em;
}

.brand-name span {
  color: rgba(255, 255, 255, 0.5);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2em;
}

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

.site-nav a {
  padding: 9px 13px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.64);
  font-size: 13px;
  font-weight: 750;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: white;
  background: rgba(255, 255, 255, 0.08);
}

.legal-hero {
  position: relative;
  overflow: hidden;
  color: white;
  background: var(--cockpit);
}

.legal-hero::after {
  position: absolute;
  right: -220px;
  bottom: -320px;
  width: 620px;
  height: 620px;
  border: 1px solid rgba(136, 223, 78, 0.16);
  border-radius: 50%;
  content: "";
  box-shadow:
    0 0 0 72px rgba(136, 223, 78, 0.025),
    0 0 0 144px rgba(136, 223, 78, 0.016);
}

.legal-hero-inner {
  position: relative;
  z-index: 1;
  padding: 76px 0 82px;
}

.eyebrow {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 0 0 20px;
  color: var(--lime);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 34px;
  height: 2px;
  background: currentColor;
  content: "";
}

h1 {
  max-width: 760px;
  margin: 0;
  font-family: "Arial Narrow", "DIN Condensed", "PingFang SC", sans-serif;
  font-size: clamp(42px, 6vw, 70px);
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1.05;
}

.hero-summary {
  max-width: 690px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 16px;
  line-height: 1.75;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 24px;
  color: rgba(255, 255, 255, 0.44);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
}

.legal-main {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
  padding: 48px 0 90px;
}

.toc {
  position: sticky;
  top: 24px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px);
}

.toc strong {
  display: block;
  margin-bottom: 14px;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.toc nav {
  display: grid;
  gap: 10px;
}

.toc a {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  text-decoration: none;
}

.toc a:hover {
  color: var(--teal);
}

.legal-card {
  padding: clamp(26px, 5vw, 54px);
  border: 1px solid var(--line);
  border-radius: 34px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.legal-card section + section {
  padding-top: 38px;
  margin-top: 38px;
  border-top: 1px solid var(--line);
}

.legal-card h2 {
  margin: 0 0 16px;
  font-size: clamp(24px, 3vw, 31px);
  letter-spacing: -0.035em;
  line-height: 1.25;
}

.legal-card h3 {
  margin: 28px 0 10px;
  font-size: 18px;
  line-height: 1.4;
}

.legal-card p,
.legal-card li,
.legal-card td,
.legal-card th {
  color: #4f5d62;
  font-size: 14px;
  line-height: 1.85;
}

.legal-card p {
  margin: 12px 0 0;
}

.legal-card ul,
.legal-card ol {
  padding-left: 22px;
  margin: 12px 0 0;
}

.legal-card li + li {
  margin-top: 8px;
}

.legal-card b,
.legal-card strong {
  color: var(--ink);
}

.legal-card a {
  color: var(--teal);
  font-weight: 750;
}

.notice {
  padding: 20px 22px;
  margin: 22px 0 0;
  border: 1px solid #cce9be;
  border-radius: 18px;
  background: var(--soft-lime);
}

.notice strong {
  display: block;
  margin-bottom: 4px;
}

.notice p {
  margin: 0;
}

.notice-teal {
  border-color: #bce3da;
  background: var(--soft-teal);
}

.data-table-wrap {
  overflow-x: auto;
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th,
.data-table td {
  padding: 15px 16px;
  text-align: left;
  vertical-align: top;
}

.data-table th {
  color: var(--ink);
  background: #f7f9f7;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.data-table tr + tr td {
  border-top: 1px solid var(--line);
}

.rights-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.right-card {
  min-height: 150px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fafcfb;
}

.right-card span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 11px;
  color: #193116;
  background: var(--lime);
  font-family: ui-monospace, monospace;
  font-size: 12px;
  font-weight: 900;
}

.right-card h3 {
  margin: 16px 0 5px;
  font-size: 17px;
}

.right-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
}

.request-panel {
  padding: clamp(24px, 4vw, 36px);
  margin-top: 22px;
  overflow: hidden;
  border-radius: 24px;
  color: white;
  background: var(--cockpit);
}

.request-panel h3,
.request-panel strong {
  color: white;
}

.request-panel h3 {
  margin: 0;
  font-size: 23px;
}

.request-panel p,
.request-panel li {
  color: rgba(255, 255, 255, 0.64);
}

.request-panel a {
  color: var(--lime);
}

.request-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 13px;
  color: white !important;
  background: rgba(255, 255, 255, 0.06);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.action-link-primary {
  border-color: var(--lime);
  color: #10200d !important;
  background: var(--lime);
}

.step-list {
  display: grid;
  gap: 12px;
  padding: 0 !important;
  margin-top: 20px !important;
  list-style: none;
  counter-reset: request-step;
}

.step-list li {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 13px;
  align-items: start;
  padding: 15px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.035);
  counter-increment: request-step;
}

.step-list li::before {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 11px;
  color: #10200d;
  background: var(--lime);
  font-family: ui-monospace, monospace;
  font-size: 12px;
  font-weight: 900;
  content: "0" counter(request-step);
}

.step-list p {
  margin-top: 4px;
}

.site-footer {
  padding: 0 0 46px;
  color: var(--muted);
  font-size: 12px;
}

.site-footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 24px;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.site-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.site-footer a {
  color: var(--ink);
  font-weight: 750;
}

@media (max-width: 800px) {
  .legal-main {
    /* minmax(0,1fr)：1fr 的隐含最小值是 auto，会被 .toc 里一整排
       不换行胶囊的 min-content（约 1100px）撑爆整页宽度 */
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .toc {
    min-width: 0;
  }

  /* 目录：吸顶横滑胶囊条 —— 不再占据整块屏幕，随时可跳转章节。
     出血用负 margin（.shell 在此断点两侧留白 20px），不能用 100vw：
     grid 轨道会被撑大导致整页横向溢出。 */
  .toc {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    gap: 10px;
    align-items: center;
    margin-inline: -20px;
    padding: 10px 20px;
    border: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    background: rgba(242, 245, 242, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .toc strong {
    flex: none;
    margin: 0;
    font-size: 11px;
    letter-spacing: 0.06em;
    white-space: nowrap;
  }

  .toc nav {
    display: flex;
    grid-template-columns: none;
    flex: 1;
    /* flex 子项默认 min-width:auto 不肯收缩，会把整页撑出横向滚动 */
    min-width: 0;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding-block: 2px;
  }

  .toc nav::-webkit-scrollbar {
    display: none;
  }

  .toc a {
    flex: none;
    padding: 8px 13px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--paper);
    color: var(--ink);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
  }

  /* 锚点跳转时给吸顶目录留出空间 */
  .legal-card section {
    scroll-margin-top: 68px;
  }
}

@media (max-width: 620px) {
  .shell {
    width: min(100% - 28px, 1080px);
  }

  /* .shell 此断点两侧留白 14px，目录出血量同步收窄 */
  .toc {
    margin-inline: -14px;
    padding-inline: 14px;
  }

  .site-header-inner {
    min-height: 64px;
  }

  .brand img {
    width: 36px;
    height: 36px;
  }

  .brand-name span {
    display: none;
  }

  .site-nav a {
    padding: 8px 9px;
    font-size: 12px;
  }

  .site-nav a:first-child {
    display: none;
  }

  .legal-hero-inner {
    padding: 40px 0 44px;
  }

  .eyebrow {
    margin-bottom: 14px;
  }

  h1 {
    font-size: clamp(30px, 8.6vw, 42px);
    letter-spacing: -0.03em;
    line-height: 1.12;
  }

  .hero-summary {
    margin-top: 14px;
    font-size: 14px;
    line-height: 1.7;
  }

  .hero-meta {
    gap: 6px 16px;
    margin-top: 18px;
    font-size: 10px;
  }

  .legal-main {
    padding: 0 0 56px;
  }

  .legal-card {
    margin-top: 18px;
    padding: 22px 18px;
    border-radius: 20px;
  }

  .legal-card section + section {
    padding-top: 28px;
    margin-top: 28px;
  }

  .legal-card h2 {
    font-size: 21px;
  }

  .legal-card h3 {
    margin-top: 22px;
    font-size: 16px;
  }

  .legal-card p,
  .legal-card li,
  .legal-card td,
  .legal-card th {
    font-size: 13.5px;
    line-height: 1.8;
  }

  .legal-card ul,
  .legal-card ol {
    padding-left: 18px;
  }

  .notice {
    padding: 15px 16px;
    border-radius: 14px;
  }

  .rights-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .right-card {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 4px 14px;
    align-items: center;
    min-height: 0;
    padding: 15px 16px;
    border-radius: 16px;
  }

  .right-card h3 {
    margin: 0;
    font-size: 15px;
  }

  .right-card p {
    grid-column: 2;
    font-size: 12.5px;
  }

  /* 表格 → 堆叠卡片：每行一张卡，td 用 data-label 自带表头 */
  .data-table-wrap {
    overflow: visible;
    border: 0;
    border-radius: 0;
  }

  .data-table,
  .data-table tbody,
  .data-table tr,
  .data-table td {
    display: block;
    width: 100%;
  }

  .data-table thead {
    display: none;
  }

  .data-table tr {
    padding: 4px 16px 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fafcfb;
  }

  .data-table tr + tr {
    margin-top: 10px;
  }

  .data-table td {
    min-width: 0;
    padding: 10px 0 0;
    border: 0 !important;
  }

  .data-table td[data-label]::before {
    display: block;
    margin-bottom: 1px;
    color: var(--muted);
    content: attr(data-label);
    font-size: 10.5px;
    font-weight: 900;
    letter-spacing: 0.08em;
  }

  .request-panel {
    border-radius: 18px;
  }

  .request-panel h3 {
    font-size: 19px;
  }

  .step-list li {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 11px;
    padding: 13px;
  }

  .step-list li::before {
    width: 30px;
    height: 30px;
    font-size: 11px;
  }

  .request-actions {
    display: grid;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
