:root {
  --color-primary: #fcae91;
  --color-secondary: #b2d3c2;
  --color-accent: #fbe0a1;
  --color-bg: #f2efe9;
  --color-card: #faf9f7;
  --color-text: #433e38;
  --color-muted: #8a8379;
  --color-doc-link: #33403a;
  --color-footer-rule: rgba(67, 62, 56, 0.1);
  --btn-primary-fg: #433e38;
  --logo-mark-shadow:
    0 4px 16px rgba(67, 62, 56, 0.12),
    0 2px 8px rgba(252, 174, 145, 0.25);
  --radius-card: clamp(1.5rem, 2vw, 2.25rem);
  --shadow-lift:
    0 0 0 1px rgba(67, 62, 56, 0.04),
    0 4px 28px rgba(67, 62, 56, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

html {
  color-scheme: light dark;
}

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

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-weight: 500;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
}

.wrap {
  max-width: 72rem;
  margin: 0 auto;
  padding: 1.75rem clamp(1.25rem, 4vw, 2.75rem) 3.5rem;
}

header.site {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}

.logo {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--color-text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-mark {
  width: 2rem;
  height: 2rem;
  border-radius: 0.625rem;
  flex-shrink: 0;
  display: block;
  object-fit: cover;
  box-shadow: var(--logo-mark-shadow);
}

nav.legal-mini {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: flex-end;
}

nav.legal-mini a {
  color: var(--color-muted);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 600;
  transition: color 0.18s var(--ease-out);
}

nav.legal-mini a:hover {
  color: var(--color-text);
}

nav.legal-mini .current {
  color: var(--color-text);
  font-weight: 700;
  font-size: 0.9375rem;
}

.doc {
  background: var(--color-card);
  border-radius: var(--radius-card);
  padding: clamp(1.65rem, 4vw, 2.75rem);
  box-shadow: var(--shadow-lift);
  max-width: 46rem;
  margin: 0 auto 3rem;
}

.doc h1 {
  font-size: clamp(1.5rem, 3.8vw, 1.95rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.22;
  margin: 0 0 0.35rem;
}

.doc .effective {
  color: var(--color-muted);
  font-weight: 600;
  font-size: 0.9375rem;
  margin: 0 0 1.65rem;
}

.doc h2 {
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 1.6rem 0 0.5rem;
}

.doc h2:first-of-type {
  margin-top: 1.35rem;
}

.doc p {
  margin: 0.65rem 0;
}

.doc ul {
  margin: 0.5rem 0 0;
  padding-left: 1.25rem;
}

.doc li {
  margin: 0.4rem 0;
  color: var(--color-muted);
  font-weight: 600;
}

.doc li::marker {
  color: var(--color-primary);
}

.doc a:not([class]) {
  color: var(--color-doc-link);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--color-primary);
  text-underline-offset: 0.14em;
  transition:
    color 0.18s var(--ease-out),
    text-decoration-color 0.18s var(--ease-out);
}

.doc a:not([class]):hover {
  color: var(--color-text);
  text-decoration-color: var(--color-secondary);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  transition:
    transform 0.18s var(--ease-out),
    box-shadow 0.18s var(--ease-out);
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--color-primary);
  color: var(--btn-primary-fg);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.55) inset,
    0 6px 22px rgba(252, 174, 145, 0.42);
}

.btn-primary:hover {
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.65) inset,
    0 10px 30px rgba(252, 174, 145, 0.48);
  transform: translateY(-2px);
}

footer.site-footer {
  padding-top: 2rem;
  border-top: 1px solid var(--color-footer-rule);
  text-align: center;
}

footer.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  justify-content: center;
  align-items: center;
  margin-bottom: 1rem;
}

footer.site-footer a.footer-link {
  color: var(--color-muted);
  font-weight: 700;
  font-size: 0.9375rem;
  text-decoration: none;
  transition: color 0.18s var(--ease-out);
}

footer.site-footer a.footer-link:hover {
  color: var(--color-text);
}

footer.site-footer small {
  display: block;
  font-size: 0.8125rem;
  color: var(--color-muted);
  font-weight: 600;
}

.apple-icon-footer {
  width: 1.15rem;
  height: 1.15rem;
  fill: currentColor;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-primary: #ffb097;
    --color-secondary: #8ebbab;
    --color-accent: #ffe4b0;
    --color-bg: #161311;
    --color-card: #26221e;
    --color-text: #f8f6f2;
    --color-muted: #aea59b;
    --color-doc-link: #b9d8cc;
    --color-footer-rule: rgba(255, 255, 255, 0.12);
    --btn-primary-fg: #2c2620;
    --logo-mark-shadow:
      0 4px 18px rgba(0, 0, 0, 0.4),
      0 2px 6px rgba(255, 180, 150, 0.15);
    --shadow-lift:
      0 0 0 1px rgba(255, 255, 255, 0.07),
      0 4px 32px rgba(0, 0, 0, 0.45),
      inset 0 1px 0 rgba(255, 255, 255, 0.05);
  }

  html {
    color-scheme: dark;
  }
}
