/* Legal pages share the ivory system of the homepage (styles.css). */

:root {
  --canvas: #fbfaf6;
  --surface: #ffffff;
  --ink: #092449;
  --text: #3b4f6c;
  --muted: #6b7c93;
  --line: rgba(9, 36, 73, 0.1);
  --line-strong: rgba(9, 36, 73, 0.18);
  --brand: #126dcc;
  --brand-strong: #0b5eb6;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "PingFang SC",
    "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--canvas);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--brand);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--brand-strong);
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 6px;
}

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

.legal-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgba(251, 250, 246, 0.86);
  -webkit-backdrop-filter: saturate(1.6) blur(18px);
  backdrop-filter: saturate(1.6) blur(18px);
}

.legal-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
}

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

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

.brand img {
  border-radius: 8px;
  box-shadow: 0 0 0 1px var(--line);
}

.back-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

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

.legal-document {
  padding-block: clamp(56px, 9vw, 104px) clamp(80px, 10vw, 128px);
}

.legal-kicker {
  margin: 0;
  color: var(--brand);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

h1 {
  max-width: 16em;
  margin: 14px 0 0;
  color: var(--ink);
  font-size: clamp(2.25rem, 1.4rem + 3.4vw, 3.5rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.effective {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 14px;
}

h2 {
  margin: 48px 0 10px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

p,
li {
  max-width: 68ch;
}

p {
  margin: 0 0 14px;
}

ol {
  margin: 0 0 14px;
  padding-left: 22px;
}

li + li {
  margin-top: 6px;
}

strong {
  color: var(--ink);
  font-weight: 600;
}

.legal-footer {
  border-top: 1px solid var(--line);
}

.legal-footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 28px;
  padding-block: 32px;
  color: var(--muted);
  font-size: 13px;
}

.legal-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

.legal-footer a {
  color: var(--text);
  text-decoration: none;
}

.legal-footer a:hover {
  color: var(--ink);
}

@media (forced-colors: active) {
  .legal-header,
  .legal-footer,
  h2 {
    border-color: CanvasText;
  }
}
