/* ============================================================
   Legal pages — Terms of Service, Privacy Policy.

   Loads after styles.css and reuses its --pk-* tokens and the
   .brand lockup, so the pages read as part of the same product
   rather than a separate microsite.

   One column, generous measure, no decoration beyond a rule
   between sections. Legal pages on real products look like this.
   ============================================================ */

html,
body.legal-page {
  height: auto;
  min-height: 100%;
  background: #0c0e13;
}

body.legal-page {
  overflow-x: hidden;
  overflow-y: auto;
  color: var(--pk-gray-800);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

/* ── Top bar ────────────────────────────────────────────── */

.lbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: calc(12px + env(safe-area-inset-top)) clamp(16px, 4.6vw, 24px) 12px;
  background: rgba(12, 14, 19, 0.82);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--pk-border-alpha);
}

.lbar .brand {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #fff;
  text-decoration: none;
}

.lbar .brand__mark {
  display: block;
  width: 17px;
  aspect-ratio: 66 / 100;
  flex: 0 0 auto;
}

.lbar .brand__mark svg { display: block; width: 100%; height: 100%; }

.lbar .brand__word {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.014em;
}

.lbar__back {
  font-size: 13px;
  font-weight: 600;
  color: var(--pk-gray-600);
  text-decoration: none;
  transition: color 130ms linear;
}

.lbar__back:hover { color: var(--pk-content-primary); }

/* ── Document ───────────────────────────────────────────── */

.doc {
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 56px) clamp(18px, 4.6vw, 24px) 64px;
}

.doc__eyebrow {
  margin: 0 0 8px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pk-brand-400);
}

.doc__title {
  margin: 0 0 10px;
  font-size: clamp(28px, 6.4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.022em;
  line-height: 1.15;
  color: #fff;
}

.doc__meta {
  margin: 0 0 26px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--pk-gray-600);
}

.doc__lead {
  margin: 0 0 30px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--pk-border-alpha);
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--pk-gray-700);
}

/* ── Contents ───────────────────────────────────────────── */

.doc__toc {
  margin: 0 0 38px;
  padding: 16px 18px;
  border: 1px solid var(--pk-border-alpha);
  border-radius: var(--pk-radius-lg);
  background: var(--pk-alpha-100);
}

.doc__toc h2 {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pk-gray-600);
}

.doc__toc ol {
  margin: 0;
  padding-left: 20px;
  columns: 2;
  column-gap: 22px;
}

.doc__toc li {
  margin: 0 0 5px;
  font-size: 13px;
  line-height: 1.5;
  break-inside: avoid;
}

.doc__toc a {
  color: var(--pk-gray-700);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 120ms linear, border-color 120ms linear;
}

.doc__toc a:hover {
  color: #fff;
  border-bottom-color: var(--pk-alpha-400);
}

@media (max-width: 520px) {
  .doc__toc ol { columns: 1; }
}

/* ── Sections ───────────────────────────────────────────── */

.doc section { margin: 0 0 34px; }

.doc section h2 {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.012em;
  line-height: 1.3;
  color: #fff;
  scroll-margin-top: 72px;
}

.doc p {
  margin: 0 0 13px;
  font-size: 14.5px;
  line-height: 1.68;
  color: var(--pk-gray-700);
}

.doc ul {
  margin: 0 0 15px;
  padding-left: 20px;
}

.doc li {
  margin: 0 0 9px;
  font-size: 14.5px;
  line-height: 1.64;
  color: var(--pk-gray-700);
}

.doc strong {
  color: var(--pk-gray-900);
  font-weight: 600;
}

.doc a {
  color: var(--pk-brand-300);
  text-decoration: none;
  border-bottom: 1px solid var(--pk-alpha-300);
}

.doc a:hover {
  color: #fff;
  border-bottom-color: var(--pk-alpha-600);
}

.doc__foot {
  margin: 40px 0 0;
  padding-top: 22px;
  border-top: 1px solid var(--pk-border-alpha);
  font-size: 12.5px;
  font-style: italic;
  color: var(--pk-gray-600);
}

/* ── Footer ─────────────────────────────────────────────── */

.lfood {
  padding: 22px clamp(18px, 4.6vw, 24px) calc(28px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--pk-border-alpha);
  background: #0a0c11;
}

.lfood__links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  max-width: 720px;
  margin: 0 auto 10px;
}

.lfood__links a {
  font-size: 13px;
  font-weight: 600;
  color: var(--pk-gray-600);
  text-decoration: none;
  transition: color 130ms linear;
}

.lfood__links a:hover { color: var(--pk-content-primary); }

.lfood__links a[aria-current="page"] { color: var(--pk-gray-800); }

.lfood__copy {
  max-width: 720px;
  margin: 0 auto;
  font-size: 12px;
  color: var(--pk-gray-500);
}
