/* =====================================================
   LEGAL PAGES (Privacy policy) — readable long-form text on the dark skin.
   Base page (header/footer, dark body, title eyebrow) comes from order-flow.css.
   ===================================================== */
body.mf-legal-page { --mf-of-w: 1100px; }
body.mf-legal-page .wp-block-post-content { padding-left: 24px !important; padding-right: 24px !important; }

.mf-legal {
  max-width: 1100px;
  margin: 0 auto 80px !important;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  color: var(--mf-cream);
}
.mf-legal > * { margin-top: 0 !important; }

/* "On this page" */
.mf-legal__toc {
  position: sticky;
  top: calc(var(--wp-admin--admin-bar--height, 0px) + var(--mf-header-h, 96px) + 24px);
  padding: 18px 20px !important;
  background: var(--mf-surface);
  border: 1px solid var(--mf-line);
  border-radius: 6px;
}
.mf-legal__toc-title {
  margin: 0 0 10px !important;
  font: 500 12px/1 'Oswald', sans-serif !important;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--mf-red-text) !important;
}
.mf-legal__toc ol { list-style: none; margin: 0 !important; padding: 0 !important; counter-reset: toc; }
.mf-legal__toc li { margin: 0; counter-increment: toc; }
.mf-legal__toc a {
  display: flex; gap: 10px;
  padding: 6px 0;
  font-size: 14px; line-height: 1.35;
  color: var(--mf-muted) !important; text-decoration: none !important;
  transition: color .2s ease;
}
.mf-legal__toc a::before { content: counter(toc, decimal-leading-zero); font: 500 12px/1.6 'Oswald', sans-serif; color: var(--mf-gold); }
.mf-legal__toc a:hover { color: var(--mf-cream) !important; }

/* Body copy */
.mf-legal__body { max-width: 760px; font-size: 16px; line-height: 1.75; }
.mf-legal__body > * + * { margin-top: 0; }
.mf-legal__summary {
  margin: 0 0 32px !important;
  padding: 20px 22px !important;
  background: var(--mf-surface);
  border: 1px solid var(--mf-line);
  border-left: 3px solid var(--mf-red);
  border-radius: 6px;
  color: var(--mf-cream);
}
.mf-legal__summary p { margin: 0 0 8px !important; }
.mf-legal__summary p:last-child { margin-bottom: 0 !important; }
.mf-legal__updated { color: var(--mf-muted) !important; font-size: 14px; }

.mf-legal__body h2 {
  margin: 44px 0 14px !important;
  padding-top: 20px;
  border-top: 1px solid var(--mf-line);
  font: 600 22px/1.25 'Oswald', sans-serif !important;
  letter-spacing: .03em; text-transform: uppercase;
  color: var(--mf-cream) !important;
  scroll-margin-top: calc(var(--wp-admin--admin-bar--height, 0px) + var(--mf-header-h, 96px) + 24px);
}
.mf-legal__body h2:first-of-type { border-top: 0; padding-top: 0; margin-top: 0 !important; }
.mf-legal__body h3 {
  margin: 24px 0 8px !important;
  font: 500 16px/1.3 'Oswald', sans-serif !important;
  letter-spacing: .05em; text-transform: uppercase;
  color: var(--mf-gold) !important;
}
.mf-legal__body p { margin: 0 0 14px !important; color: #E4DCD2; }
.mf-legal__body ul { margin: 0 0 16px !important; padding-left: 0 !important; list-style: none; }
.mf-legal__body li { position: relative; margin: 0 0 8px; padding-left: 22px; color: #E4DCD2; }
.mf-legal__body li::before {
  content: ""; position: absolute; left: 4px; top: .72em;
  width: 6px; height: 6px; border-radius: 50%; background: var(--mf-gold);
}
.mf-legal__body strong { color: var(--mf-cream); }
.mf-legal__body a { color: var(--mf-gold) !important; text-decoration: underline; text-underline-offset: 3px; }
.mf-legal__body a:hover { color: var(--mf-cream) !important; }

/* Tablet / phone: contents list above the text */
@media (max-width: 1024px) {
  .mf-legal { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .mf-legal__toc { position: static; }
  .mf-legal__toc ol { columns: 2; column-gap: 24px; }
}
@media (max-width: 767px) {
  body.mf-legal-page .wp-block-post-content { padding-left: 16px !important; padding-right: 16px !important; }
  .mf-legal__toc ol { columns: 1; }
  .mf-legal__body { font-size: 15px; }
  .mf-legal__body h2 { font-size: 19px !important; }
}

@media print {
  body.mf-legal-page .mf-shared, body.mf-legal-page #wpadminbar, .mf-legal__toc { display: none !important; }
  .mf-legal { display: block; }
  .mf-legal__body, .mf-legal__body p, .mf-legal__body li, .mf-legal__body h2, .mf-legal__body h3, body.mf-legal-page main .wp-block-post-title { color: #111 !important; }
  .mf-legal__summary { background: #fff; border-color: #ccc; }
}
