:root {
  color-scheme: light;
  --ink: #161728;
  --muted: #676a7a;
  --soft: #f5f6fb;
  --line: #e1e3ed;
  --paper: #ffffff;
  --night: #080b18;
  --night-soft: #11162b;
  --violet: #7657f6;
  --blue: #427cff;
  --gold: #ffc958;
  --shadow: 0 28px 80px rgba(21, 25, 54, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 28px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--soft);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a {
  color: #315fd8;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: #1d46b1;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(66, 124, 255, 0.35);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 9px 14px;
  border-radius: 10px;
  color: white;
  background: var(--ink);
  transform: translateY(-180%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.reading-progress {
  position: fixed;
  inset: 0 auto auto 0;
  z-index: 90;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--violet), #d66de6);
}

.masthead {
  position: relative;
  overflow: hidden;
  color: var(--ink);
  background: #ffffff;
}

.masthead-inner {
  position: relative;
  z-index: 1;
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 82px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
  font-size: 16px;
  font-weight: 720;
  letter-spacing: -0.01em;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: block;
  flex: 0 0 auto;
  object-fit: contain;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.top-link,
.language-switch {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #4f5262;
  text-decoration: none;
  font-size: 13px;
  font-weight: 650;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.top-link:hover,
.language-switch:hover {
  color: var(--ink);
  border-color: #c9ccda;
  background: var(--soft);
}

.hero-copy {
  max-width: 880px;
  padding: 78px 0 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 24px;
  color: #6250d6;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 5px rgba(255, 201, 88, 0.1);
  content: "";
}

h1,
h2,
h3 {
  line-height: 1.25;
}

h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(48px, 7vw, 78px);
  letter-spacing: -0.06em;
}

.hero-deck {
  max-width: 760px;
  margin: 25px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.policy-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-top: 30px;
  color: #7c7f8f;
  font-size: 13px;
}

.policy-meta span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.policy-meta span::before {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #b9bcc8;
  content: "";
}

.page-shell {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  padding: 52px 0 84px;
}

.mobile-toc {
  display: none;
  margin: 24px 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: white;
}

.mobile-toc summary {
  padding: 15px 18px;
  cursor: pointer;
  font-weight: 750;
}

.mobile-toc ol {
  margin: 0;
  padding: 0 22px 18px 42px;
}

.document-grid {
  display: grid;
  grid-template-columns: 245px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  margin-top: 0;
}

.toc-panel {
  position: sticky;
  top: 24px;
}

.toc-label {
  display: block;
  margin: 0 0 14px 14px;
  color: #9093a4;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.toc-panel ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.toc-panel a {
  display: block;
  padding: 8px 13px;
  border-left: 2px solid transparent;
  color: #747788;
  text-decoration: none;
  font-size: 13px;
  line-height: 1.45;
  transition: color 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.toc-panel a:hover,
.toc-panel a.is-active {
  color: var(--ink);
  border-left-color: var(--violet);
  background: linear-gradient(90deg, rgba(118, 87, 246, 0.08), transparent);
}

.toc-actions {
  display: flex;
  gap: 8px;
  margin-top: 20px;
}

.print-button,
.back-top {
  appearance: none;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--muted);
  background: white;
  text-decoration: none;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.print-button:hover,
.back-top:hover {
  color: var(--ink);
  border-color: #c7cad8;
}

.policy-document {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--paper);
  box-shadow: 0 18px 60px rgba(26, 29, 58, 0.07);
}

.policy-intro {
  padding: 42px 48px 36px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(140deg, #ffffff, #f7f8fc);
}

.policy-intro strong {
  display: block;
  margin-bottom: 8px;
  font-size: 19px;
}

.policy-intro p {
  margin: 0;
  color: var(--muted);
}

.policy-section {
  padding: 44px 48px;
  scroll-margin-top: 22px;
}

.policy-section + .policy-section {
  border-top: 1px solid var(--line);
}

.section-heading {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  margin-bottom: 20px;
}

.section-index {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  color: var(--violet);
  background: rgba(118, 87, 246, 0.09);
  font-size: 12px;
  font-weight: 850;
}

.policy-section h2 {
  margin: 7px 0 0;
  font-size: 24px;
  letter-spacing: -0.035em;
}

.policy-section h3 {
  margin: 28px 0 8px;
  font-size: 17px;
  letter-spacing: -0.02em;
}

.policy-section p {
  margin: 10px 0;
}

.policy-section ul,
.policy-section ol {
  margin: 11px 0;
  padding-left: 1.45rem;
}

.policy-section li {
  margin: 8px 0;
}

.policy-section code {
  padding: 2px 5px;
  border-radius: 5px;
  color: #4e3cb0;
  background: #f0edff;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.88em;
}

.note {
  margin: 24px 0 0;
  padding: 18px 20px;
  border-left: 3px solid var(--blue);
  border-radius: 0 12px 12px 0;
  color: #55596b;
  background: #f6f8ff;
}

.permission-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0 0;
}

.permission-item {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfbfd;
}

.permission-item strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
}

.permission-item span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.58;
}

.contact-card {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 7px 18px;
  margin: 22px 0 0;
  padding: 22px;
  border-radius: 16px;
  background: var(--soft);
}

.contact-card dt {
  font-weight: 750;
}

.contact-card dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

.site-footer {
  padding: 42px 0 48px;
  color: rgba(255, 255, 255, 0.5);
  background: var(--night);
  font-size: 13px;
}

.footer-inner {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 20px;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.68);
}

.error-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 28px;
  color: white;
  background:
    radial-gradient(circle at 70% 25%, rgba(118, 87, 246, 0.35), transparent 30%),
    var(--night);
}

.error-card {
  width: min(570px, 100%);
  text-align: center;
}

.error-card .brand,
.error-card .brand:hover {
  color: white;
}

.error-code {
  display: block;
  margin-bottom: 10px;
  color: #aab6ff;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.2em;
}

.error-card h1 {
  font-size: clamp(48px, 11vw, 86px);
}

.error-card p {
  margin: 20px auto 32px;
  color: rgba(255, 255, 255, 0.58);
}

.home-button {
  display: inline-flex;
  padding: 11px 18px;
  border-radius: 999px;
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--violet));
  text-decoration: none;
  font-weight: 750;
}

.home-button:hover {
  color: white;
}

@media (max-width: 940px) {
  .document-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .toc-panel {
    display: none;
  }

  .mobile-toc {
    display: block;
  }
}

@media (max-width: 640px) {
  .masthead-inner,
  .page-shell,
  .footer-inner {
    width: min(100% - 28px, 1160px);
  }

  .masthead-inner {
    padding-top: 18px;
    padding-bottom: 66px;
  }

  .topbar {
    align-items: flex-start;
  }

  .top-link {
    display: none;
  }

  .language-switch {
    min-height: 36px;
    padding: 6px 12px;
  }

  .hero-copy {
    padding-top: 68px;
  }

  h1 {
    font-size: 48px;
  }

  .hero-deck {
    font-size: 16px;
  }

  .page-shell {
    padding-top: 30px;
  }

  .policy-document {
    border-radius: 18px;
  }

  .policy-intro,
  .policy-section {
    padding: 30px 24px;
  }

  .section-heading {
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 12px;
  }

  .section-index {
    width: 36px;
    height: 36px;
    border-radius: 11px;
  }

  .policy-section h2 {
    margin-top: 4px;
    font-size: 21px;
  }

  .permission-list {
    grid-template-columns: 1fr;
  }

  .contact-card {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .contact-card dd + dt {
    margin-top: 9px;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

@media print {
  :root {
    --ink: #000000;
    --muted: #333333;
    --line: #cccccc;
  }

  body {
    background: white;
    font-size: 11pt;
  }

  .reading-progress,
  .skip-link,
  .top-actions,
  .mobile-toc,
  .toc-panel,
  .site-footer {
    display: none !important;
  }

  .masthead {
    color: black;
    background: white;
  }

  .masthead-inner {
    width: 100%;
    padding: 0 0 20px;
  }

  .brand {
    color: black;
  }

  .brand-mark,
  .eyebrow {
    display: none;
  }

  h1 {
    font-size: 32pt;
  }

  .hero-copy {
    padding-top: 30px;
  }

  .hero-deck,
  .policy-meta {
    color: #333333;
  }

  .page-shell {
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .document-grid {
    display: block;
    margin: 0;
  }

  .policy-document {
    border: 0;
    box-shadow: none;
  }

  .policy-intro,
  .policy-section {
    padding: 22px 0;
    break-inside: avoid-page;
  }

  a {
    color: inherit;
  }
}
