:root {
  --ink: #102033;
  --muted: #586779;
  --night: #07111f;
  --night-soft: #0e1b2e;
  --paper: #f6f3ea;
  --sheet: #fffdf7;
  --line: #d5d0c4;
  --cyan: #1abcaf;
  --cyan-bright: #38d6c7;
  --gold: #c88917;
  --shadow: 0 34px 90px rgb(0 0 0 / 18%);
  --serif: "Iowan Old Style", "Palatino Linotype", "Noto Serif CJK SC", "Songti SC", Georgia, serif;
  --sans: "Avenir Next", "Segoe UI Variable", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--night); font-family: var(--sans); }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button { font: inherit; }
[hidden] { display: none !important; }

.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; transform: translateY(-160%); padding: 10px 16px; border-radius: 8px; color: var(--night); background: var(--cyan-bright); font-weight: 700; }
.skip-link:focus { transform: translateY(0); }

.sky { position: fixed; z-index: 0; inset: 0; overflow: hidden; pointer-events: none; background: radial-gradient(circle at 72% 8%, rgb(26 188 175 / 14%), transparent 31%), radial-gradient(circle at 18% 40%, rgb(120 104 230 / 10%), transparent 25%), linear-gradient(150deg, #07111f 0%, #0a1728 54%, #07111f 100%); }
.sky::after { content: ""; position: absolute; inset: 0; opacity: .24; background-image: radial-gradient(circle, #f6f3ea 0 1px, transparent 1.5px); background-size: 57px 57px; mask-image: linear-gradient(to bottom, #000, transparent 68%); }
.orbit { position: absolute; border: 1px solid rgb(56 214 199 / 18%); border-radius: 50%; transform: rotate(-18deg); }
.orbit-one { width: 620px; height: 290px; top: 120px; right: -180px; }
.orbit-two { width: 940px; height: 480px; top: 20px; right: -340px; border-color: rgb(246 243 234 / 8%); }
.star { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--cyan-bright); box-shadow: 0 0 24px var(--cyan-bright); animation: pulse 4s ease-in-out infinite; }
.star-one { top: 16%; right: 16%; }.star-two { top: 32%; left: 8%; animation-delay: -1s; }.star-three { top: 49%; right: 5%; animation-delay: -2.5s; }.star-four { top: 9%; left: 43%; width: 4px; height: 4px; animation-delay: -.5s; }

.site-header, main, .site-footer { position: relative; z-index: 1; }
.site-header { width: min(1240px, calc(100% - 40px)); margin: 0 auto; min-height: 90px; display: flex; align-items: center; justify-content: space-between; color: var(--paper); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { border-radius: 13px; box-shadow: 0 8px 28px rgb(0 0 0 / 25%); }
.brand span { display: grid; gap: 2px; }.brand b { letter-spacing: .24em; font-size: .82rem; }.brand small { color: #a7b5c9; }
.header-actions { display: flex; gap: 10px; align-items: center; }
.segmented { display: flex; gap: 4px; padding: 4px; border-radius: 13px; background: rgb(255 255 255 / 7%); border: 1px solid rgb(255 255 255 / 11%); }
.segmented button { border: 0; border-radius: 9px; color: #a7b5c9; background: transparent; cursor: pointer; font-weight: 700; }
.segmented button[aria-pressed="true"] { color: var(--night); background: var(--cyan-bright); box-shadow: 0 5px 14px rgb(26 188 175 / 20%); }
.compact button { min-width: 40px; min-height: 34px; }
.icon-button { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid rgb(255 255 255 / 11%); border-radius: 13px; color: var(--paper); background: rgb(255 255 255 / 7%); cursor: pointer; }
.icon-button svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--cyan-bright); outline-offset: 3px; }

.hero { width: min(1120px, calc(100% - 40px)); margin: 74px auto 110px; color: var(--paper); animation: rise .8s cubic-bezier(.2,.8,.2,1) both; }
.eyebrow { display: flex; align-items: center; gap: 12px; color: var(--cyan-bright); font-size: .72rem; letter-spacing: .18em; font-weight: 800; }
.eyebrow > span:first-child { width: 40px; height: 1px; background: var(--cyan-bright); }
.hero h1 { max-width: 900px; margin: 25px 0 24px; font: 400 clamp(3rem, 8vw, 7.4rem)/.98 var(--serif); letter-spacing: -.055em; }
.hero h1 span, .hero h1 em { display: block; }.hero h1 em { color: var(--cyan-bright); font-style: italic; }
.hero-copy { max-width: 680px; margin: 0; color: #a7b5c9; font-size: clamp(1rem, 2vw, 1.2rem); line-height: 1.9; }
.facts { display: flex; gap: clamp(24px, 6vw, 80px); margin: 48px 0 0; }
.facts div { display: grid; gap: 7px; }.facts dt { color: #7f91a9; font-size: .75rem; letter-spacing: .08em; }.facts dd { margin: 0; font-family: var(--serif); font-size: 1.1rem; }

.legal-shell { width: min(1320px, calc(100% - 28px)); margin: 0 auto 70px; background: var(--paper); border-radius: 28px; overflow: clip; box-shadow: var(--shadow); animation: rise .8s .15s cubic-bezier(.2,.8,.2,1) both; }
.document-toolbar { min-height: 78px; padding: 16px 24px; display: flex; align-items: center; gap: 14px; border-bottom: 1px solid var(--line); background: #ede9de; }
.document-switch { background: #dedaCF; border-color: transparent; }.document-switch button { min-height: 40px; padding: 0 20px; color: var(--muted); }.document-switch button[aria-pressed="true"] { color: var(--night); background: var(--sheet); box-shadow: 0 3px 12px rgb(16 32 51 / 8%); }
.tool-actions { display: flex; gap: 8px; margin-left: auto; }
.text-button { min-height: 40px; padding: 0 15px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: transparent; cursor: pointer; }
.text-button:hover { border-color: var(--cyan); background: rgb(26 188 175 / 8%); }
.copy-status { margin: 0; color: #176f68; font-size: .82rem; }
.document-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); }
.contents { padding: 44px 26px; border-right: 1px solid var(--line); background: #f0ede4; }
.contents-label { margin: 0 0 20px; color: var(--gold); font-size: .7rem; letter-spacing: .16em; font-weight: 800; }
.contents nav { position: sticky; top: 24px; display: grid; gap: 4px; }
.contents nav a { padding: 7px 0 7px 13px; border-left: 2px solid transparent; color: var(--muted); font-size: .84rem; line-height: 1.35; text-decoration: none; }
.contents nav a:hover { color: var(--ink); border-color: var(--cyan); }
.local-seal { margin-top: 46px; padding-top: 22px; border-top: 1px solid var(--line); display: flex; gap: 10px; color: #176f68; }
.local-seal > span { font-size: 1.45rem; }.local-seal p { margin: 0; display: grid; gap: 3px; }.local-seal b { font-size: .8rem; }.local-seal small { color: var(--muted); font-size: .7rem; line-height: 1.5; }
.document-card { min-width: 0; padding: clamp(36px, 7vw, 86px) clamp(26px, 9vw, 120px) 38px; background: var(--sheet); }
.doc-panel { max-width: 780px; margin: 0 auto; }
.doc-heading { margin-bottom: 46px; padding-bottom: 31px; border-bottom: 1px solid var(--line); }
.doc-heading p { margin: 0 0 16px; color: var(--cyan); font-size: .7rem; letter-spacing: .18em; font-weight: 800; }
.doc-heading h2 { margin: 0 0 13px; font: 500 clamp(2.1rem, 5vw, 4.1rem)/1.1 var(--serif); letter-spacing: -.035em; }
.doc-heading span { color: var(--muted); font-size: .82rem; }
.lead { margin: 0 0 48px; font: 400 clamp(1.15rem, 2.4vw, 1.4rem)/1.8 var(--serif); color: #24384e; }
.doc-panel section { scroll-margin-top: 24px; margin: 0 0 42px; }
.doc-panel h3 { margin: 0 0 13px; font: 700 1.08rem/1.5 var(--sans); color: var(--ink); }
.doc-panel p { margin: 0 0 12px; color: #465568; font-size: .98rem; line-height: 1.95; }
.doc-panel code { padding: 2px 6px; border-radius: 5px; background: #ede9de; font-size: .9em; }
.doc-panel a, .document-footer a { color: #087f75; text-underline-offset: 3px; }
.document-footer { max-width: 780px; margin: 70px auto 0; padding-top: 24px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 20px; color: var(--muted); font-size: .76rem; }
.document-footer p { margin: 0; font-family: var(--serif); font-style: italic; }
.site-footer { width: min(1240px, calc(100% - 40px)); margin: 0 auto; padding: 10px 0 38px; display: flex; justify-content: space-between; color: #7f91a9; font-size: .78rem; }

html[data-theme="dark"] .legal-shell, html[data-theme="dark"] .document-card { background: var(--night-soft); color: var(--paper); }
html[data-theme="dark"] .document-toolbar, html[data-theme="dark"] .contents { background: #0b1728; border-color: #28405f; }
html[data-theme="dark"] .document-switch { background: #14243a; }
html[data-theme="dark"] .document-switch button[aria-pressed="true"] { color: var(--paper); background: #28405f; }
html[data-theme="dark"] .text-button { color: var(--paper); border-color: #28405f; }
html[data-theme="dark"] .contents, html[data-theme="dark"] .doc-heading, html[data-theme="dark"] .document-footer { border-color: #28405f; }
html[data-theme="dark"] .doc-heading h2, html[data-theme="dark"] .doc-panel h3 { color: var(--paper); }
html[data-theme="dark"] .lead { color: #dbe3ee; }
html[data-theme="dark"] .doc-panel p { color: #a7b5c9; }
html[data-theme="dark"] .doc-panel code { background: #14243a; }
html[data-theme="dark"] .contents nav a { color: #a7b5c9; }
html[data-theme="dark"] .contents nav a:hover { color: var(--paper); }

@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] .legal-shell, html[data-theme="auto"] .document-card { background: var(--night-soft); color: var(--paper); }
  html[data-theme="auto"] .document-toolbar, html[data-theme="auto"] .contents { background: #0b1728; border-color: #28405f; }
  html[data-theme="auto"] .document-switch { background: #14243a; }
  html[data-theme="auto"] .document-switch button[aria-pressed="true"] { color: var(--paper); background: #28405f; }
  html[data-theme="auto"] .text-button { color: var(--paper); border-color: #28405f; }
  html[data-theme="auto"] .contents, html[data-theme="auto"] .doc-heading, html[data-theme="auto"] .document-footer { border-color: #28405f; }
  html[data-theme="auto"] .doc-heading h2, html[data-theme="auto"] .doc-panel h3 { color: var(--paper); }
  html[data-theme="auto"] .lead { color: #dbe3ee; }
  html[data-theme="auto"] .doc-panel p { color: #a7b5c9; }
  html[data-theme="auto"] .doc-panel code { background: #14243a; }
  html[data-theme="auto"] .contents nav a { color: #a7b5c9; }
  html[data-theme="auto"] .contents nav a:hover { color: var(--paper); }
}

@media (max-width: 760px) {
  .site-header { min-height: 76px; }.brand small { display: none; }
  .hero { margin-top: 50px; margin-bottom: 72px; }.hero h1 { font-size: clamp(2.8rem, 14vw, 5rem); }.facts { flex-wrap: wrap; }
  .legal-shell { width: calc(100% - 16px); border-radius: 20px; }
  .document-toolbar { align-items: stretch; flex-wrap: wrap; padding: 12px; }.document-switch { flex: 1; }.document-switch button { flex: 1; padding-inline: 12px; }.tool-actions { margin-left: 0; }.copy-status { width: 100%; }
  .document-layout { display: block; }.contents { padding: 19px; border-right: 0; border-bottom: 1px solid var(--line); }.contents nav { position: static; display: flex; gap: 5px; overflow-x: auto; scrollbar-width: thin; }.contents nav a { flex: 0 0 auto; padding: 8px 11px; border: 1px solid var(--line); border-radius: 999px; }.contents-label, .local-seal { display: none; }
  .document-card { padding: 38px 22px 28px; }.doc-heading { margin-bottom: 34px; }.doc-panel section { margin-bottom: 34px; }
  .site-footer { display: block; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 0%, 100% { opacity: .35; transform: scale(.8); } 50% { opacity: 1; transform: scale(1.3); } }

@media print {
  .sky, .site-header, .hero, .document-toolbar, .contents, .site-footer { display: none !important; }
  body, .legal-shell, .document-card { color: #111 !important; background: #fff !important; box-shadow: none; }
  .legal-shell { width: 100%; margin: 0; border-radius: 0; }.document-layout { display: block; }.document-card { padding: 0; }.doc-panel p { color: #222 !important; }.doc-panel section { break-inside: avoid; }.document-footer { color: #444; }
}
